diff options
author | Kyle Edwards <kyle.edwards@kitware.com> | 2020-02-26 18:22:32 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2020-02-27 14:22:08 (GMT) |
commit | 7a63dafafbc666a184a007adca5b138796384f77 (patch) | |
tree | 5589a3106c1cbeea58d06e9c3fc5dab3c82a9cf9 /Source | |
parent | 93287e34bcdd1ad3a945e24cea591cbd60f9df3b (diff) | |
download | CMake-7a63dafafbc666a184a007adca5b138796384f77.zip CMake-7a63dafafbc666a184a007adca5b138796384f77.tar.gz CMake-7a63dafafbc666a184a007adca5b138796384f77.tar.bz2 |
Ninja Multi-Config: Remove "NMC" from variable names
Also rename `..._DEFAULT_BUILD_FILE_CONFIG` to `..._DEFAULT_BUILD_TYPE`.
These name changes make the variables meaningful for future use by other
generators.
Diffstat (limited to 'Source')
-rw-r--r-- | Source/cmGlobalNinjaGenerator.cxx | 20 |
1 files changed, 9 insertions, 11 deletions
diff --git a/Source/cmGlobalNinjaGenerator.cxx b/Source/cmGlobalNinjaGenerator.cxx index b1e26b2..27c28fe 100644 --- a/Source/cmGlobalNinjaGenerator.cxx +++ b/Source/cmGlobalNinjaGenerator.cxx @@ -2489,7 +2489,7 @@ bool cmGlobalNinjaMultiGenerator::OpenBuildFileStreams() } *this->DefaultFileStream << "# This file is a convenience file generated by\n" - << "# CMAKE_NMC_DEFAULT_BUILD_FILE_CONFIG.\n\n" + << "# CMAKE_DEFAULT_BUILD_TYPE.\n\n" << "include " << GetNinjaImplFilename(this->DefaultFileConfig) << "\n\n"; } @@ -2624,12 +2624,12 @@ bool cmGlobalNinjaMultiGenerator::ReadCacheEntriesForBuild( std::set<std::string> configs(configsVec.cbegin(), configsVec.cend()); this->DefaultFileConfig = - state.GetSafeCacheEntryValue("CMAKE_NMC_DEFAULT_BUILD_FILE_CONFIG"); + state.GetSafeCacheEntryValue("CMAKE_DEFAULT_BUILD_TYPE"); if (!this->DefaultFileConfig.empty() && !configs.count(this->DefaultFileConfig)) { std::ostringstream msg; msg << "The configuration specified by " - << "CMAKE_NMC_DEFAULT_BUILD_FILE_CONFIG (" << this->DefaultFileConfig + << "CMAKE_DEFAULT_BUILD_TYPE (" << this->DefaultFileConfig << ") is not present in CMAKE_CONFIGURATION_TYPES"; this->GetCMakeInstance()->IssueMessage(MessageType::FATAL_ERROR, msg.str()); @@ -2637,12 +2637,12 @@ bool cmGlobalNinjaMultiGenerator::ReadCacheEntriesForBuild( } std::vector<std::string> crossConfigsVec; - cmExpandList(state.GetSafeCacheEntryValue("CMAKE_NMC_CROSS_CONFIGS"), + cmExpandList(state.GetSafeCacheEntryValue("CMAKE_CROSS_CONFIGS"), crossConfigsVec); auto crossConfigs = ListSubsetWithAll(configs, configs, crossConfigsVec); if (!crossConfigs) { std::ostringstream msg; - msg << "CMAKE_NMC_CROSS_CONFIGS is not a subset of " + msg << "CMAKE_CROSS_CONFIGS is not a subset of " << "CMAKE_CONFIGURATION_TYPES"; this->GetCMakeInstance()->IssueMessage(MessageType::FATAL_ERROR, msg.str()); @@ -2651,7 +2651,7 @@ bool cmGlobalNinjaMultiGenerator::ReadCacheEntriesForBuild( this->CrossConfigs = *crossConfigs; auto defaultConfigsString = - state.GetSafeCacheEntryValue("CMAKE_NMC_DEFAULT_CONFIGS"); + state.GetSafeCacheEntryValue("CMAKE_DEFAULT_CONFIGS"); if (defaultConfigsString.empty()) { defaultConfigsString = this->DefaultFileConfig; } @@ -2659,9 +2659,8 @@ bool cmGlobalNinjaMultiGenerator::ReadCacheEntriesForBuild( defaultConfigsString != this->DefaultFileConfig && (this->DefaultFileConfig.empty() || this->CrossConfigs.empty())) { std::ostringstream msg; - msg << "CMAKE_NMC_DEFAULT_CONFIGS cannot be used without " - << "CMAKE_NMC_DEFAULT_BUILD_FILE_CONFIG or " - << "CMAKE_NMC_CROSS_CONFIGS"; + msg << "CMAKE_DEFAULT_CONFIGS cannot be used without " + << "CMAKE_DEFAULT_BUILD_TYPE or CMAKE_CROSS_CONFIGS"; this->GetCMakeInstance()->IssueMessage(MessageType::FATAL_ERROR, msg.str()); return false; @@ -2675,8 +2674,7 @@ bool cmGlobalNinjaMultiGenerator::ReadCacheEntriesForBuild( this->CrossConfigs, defaultConfigsVec); if (!defaultConfigs) { std::ostringstream msg; - msg << "CMAKE_NMC_DEFAULT_CONFIGS is not a subset of " - << "CMAKE_NMC_CROSS_CONFIGS"; + msg << "CMAKE_DEFAULT_CONFIGS is not a subset of CMAKE_CROSS_CONFIGS"; this->GetCMakeInstance()->IssueMessage(MessageType::FATAL_ERROR, msg.str()); return false; |