Makefiles: Deduplicate variable

This commit is contained in:
Stephen Kelly 2016-08-27 13:44:53 +02:00
parent fbd8394867
commit cd351ef2c4
1 changed files with 5 additions and 4 deletions

View File

@ -638,19 +638,20 @@ void cmLocalUnixMakefileGenerator3::WriteMakeVariables(
#endif
}
std::string cmakeShellCommand = this->ConvertShellCommand(
cmSystemTools::GetCMakeCommand(), cmOutputConverter::FULL);
/* clang-format off */
makefileStream
<< "# The CMake executable.\n"
<< "CMAKE_COMMAND = "
<< this->ConvertShellCommand(cmSystemTools::GetCMakeCommand(),
cmOutputConverter::FULL)
<< cmakeShellCommand
<< "\n"
<< "\n";
makefileStream
<< "# The command to remove a file.\n"
<< "RM = "
<< this->ConvertShellCommand(cmSystemTools::GetCMakeCommand(),
cmOutputConverter::FULL)
<< cmakeShellCommand
<< " -E remove -f\n"
<< "\n";
makefileStream