diff options
-rw-r--r-- | Source/cmLocalNinjaGenerator.cxx | 13 | ||||
-rw-r--r-- | Source/cmLocalUnixMakefileGenerator3.cxx | 12 |
2 files changed, 15 insertions, 10 deletions
diff --git a/Source/cmLocalNinjaGenerator.cxx b/Source/cmLocalNinjaGenerator.cxx index 46d7e18..58c336d 100644 --- a/Source/cmLocalNinjaGenerator.cxx +++ b/Source/cmLocalNinjaGenerator.cxx @@ -486,12 +486,13 @@ std::string cmLocalNinjaGenerator::MakeCustomLauncher( std::string output; const std::vector<std::string>& outputs = ccg.GetOutputs(); if (!outputs.empty()) { - cmOutputConverter::RelativeRoot relative_root = - ccg.GetWorkingDirectory().empty() ? cmOutputConverter::START_OUTPUT - : cmOutputConverter::NONE; - - output = - this->Convert(outputs[0], relative_root, cmOutputConverter::SHELL); + if (ccg.GetWorkingDirectory().empty()) { + output = this->Convert(outputs[0], cmOutputConverter::START_OUTPUT, + cmOutputConverter::SHELL); + } else { + output = this->Convert(outputs[0], cmOutputConverter::NONE, + cmOutputConverter::SHELL); + } } vars.Output = output.c_str(); diff --git a/Source/cmLocalUnixMakefileGenerator3.cxx b/Source/cmLocalUnixMakefileGenerator3.cxx index 53c9aa1..917d8d5 100644 --- a/Source/cmLocalUnixMakefileGenerator3.cxx +++ b/Source/cmLocalUnixMakefileGenerator3.cxx @@ -990,10 +990,14 @@ void cmLocalUnixMakefileGenerator3::AppendCustomCommand( std::string output; const std::vector<std::string>& outputs = ccg.GetOutputs(); if (!outputs.empty()) { - output = this->Convert(outputs[0], workingDir.empty() - ? cmOutputConverter::START_OUTPUT - : cmOutputConverter::NONE, - cmOutputConverter::SHELL); + if (workingDir.empty()) { + output = this->Convert(outputs[0], cmOutputConverter::START_OUTPUT, + cmOutputConverter::SHELL); + + } else { + output = this->Convert(outputs[0], cmOutputConverter::NONE, + cmOutputConverter::SHELL); + } } vars.Output = output.c_str(); |