summaryrefslogtreecommitdiffstats
path: root/Source/cmGlobalXCodeGenerator.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'Source/cmGlobalXCodeGenerator.cxx')
-rw-r--r--Source/cmGlobalXCodeGenerator.cxx22
1 files changed, 9 insertions, 13 deletions
diff --git a/Source/cmGlobalXCodeGenerator.cxx b/Source/cmGlobalXCodeGenerator.cxx
index 33babec..3d52e3a 100644
--- a/Source/cmGlobalXCodeGenerator.cxx
+++ b/Source/cmGlobalXCodeGenerator.cxx
@@ -376,14 +376,8 @@ cmGlobalXCodeGenerator::CreateLocalGenerator(cmMakefile* mf)
return new cmLocalXCodeGenerator(this, mf);
}
-//----------------------------------------------------------------------------
-bool cmGlobalXCodeGenerator::Compute()
+void cmGlobalXCodeGenerator::AddExtraIDETargets()
{
- if (!cmGlobalGenerator::Compute())
- {
- return false;
- }
-
std::map<std::string, std::vector<cmLocalGenerator*> >::iterator it;
// make sure extra targets are added before calling
// the parent generate which will call trace depends
@@ -394,7 +388,6 @@ bool cmGlobalXCodeGenerator::Compute()
// add ALL_BUILD, INSTALL, etc
this->AddExtraTargets(root, it->second);
}
- return true;
}
void cmGlobalXCodeGenerator::Generate()
@@ -470,7 +463,7 @@ cmGlobalXCodeGenerator::AddExtraTargets(cmLocalGenerator* root,
std::string listfile = mf->GetCurrentSourceDirectory();
listfile += "/";
listfile += "CMakeLists.txt";
- allbuild->AddSourceCMP0049(listfile.c_str());
+ allBuildGt->AddSource(listfile.c_str());
// Add XCODE depend helper
std::string dir = mf->GetCurrentBinaryDirectory();
@@ -560,11 +553,13 @@ cmGlobalXCodeGenerator::AddExtraTargets(cmLocalGenerator* root,
allbuild->AddUtility(target.GetName());
}
+ cmGeneratorTarget* targetGT = this->GetGeneratorTarget(&target);
+
// Refer to the build configuration file for easy editing.
listfile = lg->GetMakefile()->GetCurrentSourceDirectory();
listfile += "/";
listfile += "CMakeLists.txt";
- target.AddSourceCMP0049(listfile.c_str());
+ targetGT->AddSource(listfile.c_str());
}
}
}
@@ -1408,7 +1403,7 @@ void cmGlobalXCodeGenerator::ForceLinkerLanguage(cmTarget& cmtarget)
if(cmSourceFile* sf = mf->GetOrCreateSource(fname.c_str()))
{
sf->SetProperty("LANGUAGE", llang.c_str());
- cmtarget.AddSource(fname);
+ gtgt->AddSource(fname);
}
}
@@ -3076,17 +3071,18 @@ bool cmGlobalXCodeGenerator::CreateGroups(cmLocalGenerator* root,
continue;
}
+ cmGeneratorTarget* gtgt = this->GetGeneratorTarget(&cmtarget);
+
// add the soon to be generated Info.plist file as a source for a
// MACOSX_BUNDLE file
if(cmtarget.GetPropertyAsBool("MACOSX_BUNDLE"))
{
std::string plist = this->ComputeInfoPListLocation(cmtarget);
mf->GetOrCreateSource(plist, true);
- cmtarget.AddSource(plist);
+ gtgt->AddSource(plist);
}
std::vector<cmSourceFile*> classes;
- cmGeneratorTarget* gtgt = this->GetGeneratorTarget(&cmtarget);
if (!gtgt->GetConfigCommonSourceFiles(classes))
{
return false;