diff options
author | Brad King <brad.king@kitware.com> | 2012-09-28 21:15:03 (GMT) |
---|---|---|
committer | CMake Topic Stage <kwrobot@kitware.com> | 2012-09-28 21:15:03 (GMT) |
commit | 103d99338a11b7e35c9a1a9382e56aa3d43c468d (patch) | |
tree | 51811cff589bab5929202d07c1cf969eaae889e6 /Source/cmGlobalXCodeGenerator.cxx | |
parent | 908f46a161683ed2cb0de61eb54f74ae665511ef (diff) | |
parent | 083de7ed35b26dceff6edeb4fc8f9d2500855a9b (diff) | |
download | CMake-103d99338a11b7e35c9a1a9382e56aa3d43c468d.zip CMake-103d99338a11b7e35c9a1a9382e56aa3d43c468d.tar.gz CMake-103d99338a11b7e35c9a1a9382e56aa3d43c468d.tar.bz2 |
Merge topic 'generator-expression-target-properties'
083de7e Process generator expressions in the COMPILE_DEFINITIONS target property.
08cb4fa Process generator expressions in the INCLUDE_DIRECTORIES property.
0ef091d Early return if there is no target.
eb250cd Add a self-reference check for target properties.
7e80747 Add API to check that dependent target properties form a DAG.
239ac84 Add a generator expression for target properties.
e028381 Extend the generator expression language with more logic.
b8e61d6 Refactor GetCompileDefinitions a bit.
2c2b25b Return a std::string from GetCompileDefinitions.
b7e48e0 Add an AppendDefines std::string overload.
9a16087 Convert paths in INCLUDE_DIRECTORIES property to Unix slashes.
4557c8d Don't prepend a path before generator expressions in include_directories.
c6abc41 Add include guard for cmGeneratorExpression.
0ff4e3f Port remaining code to GetCompileDefinitions().
f178d53 Fix indentation in the code blocks generator.
Diffstat (limited to 'Source/cmGlobalXCodeGenerator.cxx')
-rw-r--r-- | Source/cmGlobalXCodeGenerator.cxx | 17 |
1 files changed, 5 insertions, 12 deletions
diff --git a/Source/cmGlobalXCodeGenerator.cxx b/Source/cmGlobalXCodeGenerator.cxx index 39b0ffe..95c6807 100644 --- a/Source/cmGlobalXCodeGenerator.cxx +++ b/Source/cmGlobalXCodeGenerator.cxx @@ -1647,16 +1647,12 @@ void cmGlobalXCodeGenerator::CreateBuildSettings(cmTarget& target, // Add the export symbol definition for shared library objects. this->AppendDefines(ppDefs, exportMacro); } - this->AppendDefines - (ppDefs, this->CurrentMakefile->GetProperty("COMPILE_DEFINITIONS")); - this->AppendDefines(ppDefs, target.GetProperty("COMPILE_DEFINITIONS")); + cmGeneratorTarget *gtgt = this->GetGeneratorTarget(&target); + this->AppendDefines(ppDefs, gtgt->GetCompileDefinitions().c_str()); if(configName) { - std::string defVarName = "COMPILE_DEFINITIONS_"; - defVarName += cmSystemTools::UpperCase(configName); - this->AppendDefines - (ppDefs, this->CurrentMakefile->GetProperty(defVarName.c_str())); - this->AppendDefines(ppDefs, target.GetProperty(defVarName.c_str())); + this->AppendDefines(ppDefs, + gtgt->GetCompileDefinitions(configName).c_str()); } buildSettings->AddAttribute ("GCC_PREPROCESSOR_DEFINITIONS", ppDefs.CreateList()); @@ -1713,10 +1709,8 @@ void cmGlobalXCodeGenerator::CreateBuildSettings(cmTarget& target, // Set target-specific architectures. std::vector<std::string> archs; - { - cmGeneratorTarget *gtgt = this->GetGeneratorTarget(&target); gtgt->GetAppleArchs(configName, archs); - } + if(!archs.empty()) { // Enable ARCHS attribute. @@ -1953,7 +1947,6 @@ void cmGlobalXCodeGenerator::CreateBuildSettings(cmTarget& target, BuildObjectListOrString dirs(this, this->XcodeVersion >= 30); BuildObjectListOrString fdirs(this, this->XcodeVersion >= 30); std::vector<std::string> includes; - cmGeneratorTarget *gtgt = this->GetGeneratorTarget(&target); this->CurrentLocalGenerator->GetIncludeDirectories(includes, gtgt); std::set<cmStdString> emitted; emitted.insert("/System/Library/Frameworks"); |