summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2019-03-15 14:27:48 +0000
committerKitware Robot <kwrobot@kitware.com>2019-03-15 10:27:55 -0400
commita6d8165dd2abe81dd133d188c8fe81323944c469 (patch)
tree685de106d51a37831d06c4bf8eb6bac944843a7c
parent5940d18e49fd7269e611fd020b97279a2c9e1942 (diff)
parent76e6e01c6ca67f1449a2bcd1f434657de7f0240b (diff)
downloadcmake-a6d8165dd2abe81dd133d188c8fe81323944c469.tar.gz
Merge topic 'ninja-dyndep-touchups'
76e6e01c6c cmNinjaTargetGenerator: use a different depfile for preprocessing 414332ff57 cmake_ninja_dyndep: don't duplicate slashes Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !3093
-rw-r--r--Source/cmGlobalNinjaGenerator.cxx2
-rw-r--r--Source/cmNinjaTargetGenerator.cxx2
2 files changed, 2 insertions, 2 deletions
diff --git a/Source/cmGlobalNinjaGenerator.cxx b/Source/cmGlobalNinjaGenerator.cxx
index 841587cce7..e443678d76 100644
--- a/Source/cmGlobalNinjaGenerator.cxx
+++ b/Source/cmGlobalNinjaGenerator.cxx
@@ -1997,7 +1997,7 @@ int cmcmd_cmake_ninja_dyndep(std::vector<std::string>::const_iterator argBeg,
std::string const dir_top_bld = tdi["dir-top-bld"].asString();
std::string const dir_top_src = tdi["dir-top-src"].asString();
std::string module_dir = tdi["module-dir"].asString();
- if (!module_dir.empty()) {
+ if (!module_dir.empty() && !cmHasLiteralSuffix(module_dir, "/")) {
module_dir += "/";
}
std::vector<std::string> linked_target_dirs;
diff --git a/Source/cmNinjaTargetGenerator.cxx b/Source/cmNinjaTargetGenerator.cxx
index 8d11408325..1ad26dde7a 100644
--- a/Source/cmNinjaTargetGenerator.cxx
+++ b/Source/cmNinjaTargetGenerator.cxx
@@ -1113,7 +1113,7 @@ void cmNinjaTargetGenerator::WriteObjectBuildStatement(
// Explicit preprocessing always uses a depfile.
ppVars["DEP_FILE"] = this->GetLocalGenerator()->ConvertToOutputFormat(
- objectFileName + ".d", cmOutputConverter::SHELL);
+ objectFileName + ".pp.d", cmOutputConverter::SHELL);
if (compilePP) {
// The actual compilation does not need a depfile because it
// depends on the already-preprocessed source.