diff options
author | Stephen Kelly <steveire@gmail.com> | 2014-11-25 21:47:44 (GMT) |
---|---|---|
committer | Stephen Kelly <steveire@gmail.com> | 2015-03-09 19:48:57 (GMT) |
commit | 5c559f11137dcb14113a3c5df99ff896c65c7596 (patch) | |
tree | 63e0fcb01e959715cd0eca161ec799f5e1048fb2 /Source/cmTarget.cxx | |
parent | e387ce7d681f9bd6c90c41f34b7500dfeb3b32ba (diff) | |
download | CMake-5c559f11137dcb14113a3c5df99ff896c65c7596.zip CMake-5c559f11137dcb14113a3c5df99ff896c65c7596.tar.gz CMake-5c559f11137dcb14113a3c5df99ff896c65c7596.tar.bz2 |
Genex: Enable use of COMPILE_LANGUAGE for compile options.
Follow-ups will allow the use of the generator expression
for compile definitions and include directories for non-IDE
generators.
Diffstat (limited to 'Source/cmTarget.cxx')
-rw-r--r-- | Source/cmTarget.cxx | 26 |
1 files changed, 17 insertions, 9 deletions
diff --git a/Source/cmTarget.cxx b/Source/cmTarget.cxx index e046bef..c54d694 100644 --- a/Source/cmTarget.cxx +++ b/Source/cmTarget.cxx @@ -2192,7 +2192,8 @@ static void processCompileOptionsInternal(cmTarget const* tgt, std::vector<std::string> &options, UNORDERED_SET<std::string> &uniqueOptions, cmGeneratorExpressionDAGChecker *dagChecker, - const std::string& config, bool debugOptions, const char *logName) + const std::string& config, bool debugOptions, const char *logName, + std::string const& language) { cmMakefile *mf = tgt->GetMakefile(); @@ -2204,7 +2205,8 @@ static void processCompileOptionsInternal(cmTarget const* tgt, config, false, tgt, - dagChecker), + dagChecker, + language), entryOptions); std::string usedOptions; for(std::vector<std::string>::iterator @@ -2238,10 +2240,12 @@ static void processCompileOptions(cmTarget const* tgt, std::vector<std::string> &options, UNORDERED_SET<std::string> &uniqueOptions, cmGeneratorExpressionDAGChecker *dagChecker, - const std::string& config, bool debugOptions) + const std::string& config, bool debugOptions, + std::string const& language) { processCompileOptionsInternal(tgt, entries, options, uniqueOptions, - dagChecker, config, debugOptions, "options"); + dagChecker, config, debugOptions, "options", + language); } //---------------------------------------------------------------------------- @@ -2271,7 +2275,8 @@ void cmTarget::GetAutoUicOptions(std::vector<std::string> &result, //---------------------------------------------------------------------------- void cmTarget::GetCompileOptions(std::vector<std::string> &result, - const std::string& config) const + const std::string& config, + const std::string& language) const { UNORDERED_SET<std::string> uniqueOptions; @@ -2303,7 +2308,8 @@ void cmTarget::GetCompileOptions(std::vector<std::string> &result, uniqueOptions, &dagChecker, config, - debugOptions); + debugOptions, + language); std::vector<cmTargetInternals::TargetPropertyEntry*> linkInterfaceCompileOptionsEntries; @@ -2318,7 +2324,8 @@ void cmTarget::GetCompileOptions(std::vector<std::string> &result, uniqueOptions, &dagChecker, config, - debugOptions); + debugOptions, + language); deleteAndClear(linkInterfaceCompileOptionsEntries); } @@ -2333,7 +2340,7 @@ static void processCompileDefinitions(cmTarget const* tgt, { processCompileOptionsInternal(tgt, entries, options, uniqueOptions, dagChecker, config, debugOptions, - "definitions"); + "definitions", std::string()); } //---------------------------------------------------------------------------- @@ -2431,7 +2438,8 @@ static void processCompileFeatures(cmTarget const* tgt, const std::string& config, bool debugOptions) { processCompileOptionsInternal(tgt, entries, options, uniqueOptions, - dagChecker, config, debugOptions, "features"); + dagChecker, config, debugOptions, "features", + std::string()); } //---------------------------------------------------------------------------- |