| 2087 | } |
| 2088 | |
| 2089 | void cmMakefileTargetGenerator::CreateLinkScript( |
| 2090 | char const* name, std::vector<std::string> const& link_commands, |
| 2091 | std::vector<std::string>& makefile_commands, |
| 2092 | std::vector<std::string>& makefile_depends) |
| 2093 | { |
| 2094 | // Create the link script file. |
| 2095 | std::string linkScriptName = |
| 2096 | cmStrCat(this->TargetBuildDirectoryFull, '/', name); |
| 2097 | cmGeneratedFileStream linkScriptStream(linkScriptName); |
| 2098 | linkScriptStream.SetCopyIfDifferent(true); |
| 2099 | for (std::string const& link_command : link_commands) { |
| 2100 | // Do not write out empty commands or commands beginning in the |
| 2101 | // shell no-op ":". |
| 2102 | if (!link_command.empty() && link_command[0] != ':') { |
| 2103 | linkScriptStream << link_command << "\n"; |
| 2104 | } |
| 2105 | } |
| 2106 | |
| 2107 | // Create the makefile command to invoke the link script. |
| 2108 | std::string link_command = |
| 2109 | cmStrCat("$(CMAKE_COMMAND) -E cmake_link_script ", |
| 2110 | this->LocalGenerator->ConvertToOutputFormat( |
| 2111 | this->LocalGenerator->MaybeRelativeToCurBinDir(linkScriptName), |
| 2112 | cmOutputConverter::SHELL), |
| 2113 | " --verbose=$(VERBOSE)"); |
| 2114 | makefile_commands.push_back(std::move(link_command)); |
| 2115 | makefile_depends.push_back(std::move(linkScriptName)); |
| 2116 | } |
| 2117 | |
| 2118 | bool cmMakefileTargetGenerator::CheckUseResponseFileForObjects( |
| 2119 | std::string const& l) const |
no test coverage detected