summaryrefslogtreecommitdiffstats
path: root/Source/cmLocalGenerator.cxx
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2019-10-04 14:13:13 (GMT)
committerKitware Robot <kwrobot@kitware.com>2019-10-04 14:15:08 (GMT)
commit395e5f77fcd900b4a7a48eaa2da2e3554b694cf1 (patch)
tree62863c7b211c308143a33de309a7311192f67cfc /Source/cmLocalGenerator.cxx
parenta988cc8789bf00dd8783192f95e02ccbfea78302 (diff)
parent83c1657ff7fda3dc86b49bc9039f59449f2d8ae4 (diff)
downloadCMake-395e5f77fcd900b4a7a48eaa2da2e3554b694cf1.zip
CMake-395e5f77fcd900b4a7a48eaa2da2e3554b694cf1.tar.gz
CMake-395e5f77fcd900b4a7a48eaa2da2e3554b694cf1.tar.bz2
Merge topic 'unity-step'
83c1657ff7 Unity build: Generate sources during Compute step Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !3884
Diffstat (limited to 'Source/cmLocalGenerator.cxx')
-rw-r--r--Source/cmLocalGenerator.cxx9
1 files changed, 7 insertions, 2 deletions
diff --git a/Source/cmLocalGenerator.cxx b/Source/cmLocalGenerator.cxx
index ae5139a..ccd70a3 100644
--- a/Source/cmLocalGenerator.cxx
+++ b/Source/cmLocalGenerator.cxx
@@ -2452,13 +2452,18 @@ void cmLocalGenerator::AddPchDependencies(cmGeneratorTarget* target,
}
}
-void cmLocalGenerator::AddUnityBuild(cmGeneratorTarget* target,
- const std::string& config)
+void cmLocalGenerator::AddUnityBuild(cmGeneratorTarget* target)
{
if (!target->GetPropertyAsBool("UNITY_BUILD")) {
return;
}
+ // FIXME: Handle all configurations in multi-config generators.
+ std::string config;
+ if (!this->GetGlobalGenerator()->IsMultiConfig()) {
+ config = this->Makefile->GetSafeDefinition("CMAKE_BUILD_TYPE");
+ }
+
const std::string buildType = cmSystemTools::UpperCase(config);
std::string filename_base =