summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2020-01-24 14:16:46 (GMT)
committerKitware Robot <kwrobot@kitware.com>2020-01-24 14:17:07 (GMT)
commit89a93348d514ff8c4233d8e25ebe2ff65e26c446 (patch)
treee2910bd730a2f18619552949b8465cfcbce4411e
parent1397b3d26e4553a70f92e5340fcdbb63d173909d (diff)
parent6cc74b614049bd2fce53675f1a11eecec3e1e079 (diff)
downloadCMake-89a93348d514ff8c4233d8e25ebe2ff65e26c446.zip
CMake-89a93348d514ff8c4233d8e25ebe2ff65e26c446.tar.gz
CMake-89a93348d514ff8c4233d8e25ebe2ff65e26c446.tar.bz2
Merge topic 'multi-ninja-no-cleandead'
6cc74b6140 cmGlobalNinjaGenerator: avoid cleandead and recompact in Ninja-Multi Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !4261
-rw-r--r--Source/cmGlobalNinjaGenerator.cxx13
1 files changed, 11 insertions, 2 deletions
diff --git a/Source/cmGlobalNinjaGenerator.cxx b/Source/cmGlobalNinjaGenerator.cxx
index 0911cd0..308644e 100644
--- a/Source/cmGlobalNinjaGenerator.cxx
+++ b/Source/cmGlobalNinjaGenerator.cxx
@@ -549,10 +549,19 @@ void cmGlobalNinjaGenerator::Generate()
}
};
- if (this->NinjaSupportsCleanDeadTool) {
+ // The `cleandead` tool needs to know about all outputs in the build we just
+ // wrote out. Ninja-Multi doesn't have a single `build.ninja` we can use that
+ // is the union of all generated configurations, so we can't run it reliably
+ // in that case.
+ if (this->NinjaSupportsCleanDeadTool && !this->IsMultiConfig()) {
run_ninja_tool({ "cleandead" });
}
- if (this->NinjaSupportsUnconditionalRecompactTool) {
+ // The `recompact` tool loads the manifest. As above, we don't have a single
+ // `build.ninja` to load for this in Ninja-Multi. This may be relaxed in the
+ // future pending further investigation into how Ninja works upstream
+ // (ninja#1721).
+ if (this->NinjaSupportsUnconditionalRecompactTool &&
+ !this->IsMultiConfig()) {
run_ninja_tool({ "recompact" });
}
if (this->NinjaSupportsRestatTool) {