diff options
-rw-r--r-- | Source/cmLocalUnixMakefileGenerator3.cxx | 27 |
1 files changed, 5 insertions, 22 deletions
diff --git a/Source/cmLocalUnixMakefileGenerator3.cxx b/Source/cmLocalUnixMakefileGenerator3.cxx index d629e71..f6ab0d0 100644 --- a/Source/cmLocalUnixMakefileGenerator3.cxx +++ b/Source/cmLocalUnixMakefileGenerator3.cxx @@ -1961,34 +1961,17 @@ void cmLocalUnixMakefileGenerator3 } // Build a list of preprocessor definitions for the target. - std::vector<std::string> defines; - { - std::string defPropName = "COMPILE_DEFINITIONS_"; - defPropName += cmSystemTools::UpperCase(this->ConfigurationName); - if(const char* ddefs = this->Makefile->GetProperty("COMPILE_DEFINITIONS")) - { - cmSystemTools::ExpandListArgument(ddefs, defines); - } - if(const char* cdefs = target.GetProperty("COMPILE_DEFINITIONS")) - { - cmSystemTools::ExpandListArgument(cdefs, defines); - } - if(const char* dcdefs = this->Makefile->GetProperty(defPropName.c_str())) - { - cmSystemTools::ExpandListArgument(dcdefs, defines); - } - if(const char* ccdefs = target.GetProperty(defPropName.c_str())) - { - cmSystemTools::ExpandListArgument(ccdefs, defines); - } - } + std::set<std::string> defines; + this->AppendDefines(defines, target.GetCompileDefinitions()); + this->AppendDefines(defines, target.GetCompileDefinitions( + this->ConfigurationName.c_str())); if(!defines.empty()) { cmakefileStream << "\n" << "# Preprocessor definitions for this target.\n" << "SET(CMAKE_TARGET_DEFINITIONS\n"; - for(std::vector<std::string>::const_iterator di = defines.begin(); + for(std::set<std::string>::const_iterator di = defines.begin(); di != defines.end(); ++di) { cmakefileStream |