MCPcopy Create free account
hub / github.com/Kitware/CMake / ComputeRPath

Method ComputeRPath

Source/cmLinkLineComputer.cxx:174–201  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

172}
173
174std::string cmLinkLineComputer::ComputeRPath(cmComputeLinkInformation& cli)
175{
176 std::string rpath;
177 // Check what kind of rpath flags to use.
178 if (cli.GetRuntimeSep().empty()) {
179 // Each rpath entry gets its own option ("-R a -R b -R c")
180 std::vector<std::string> runtimeDirs;
181 cli.GetRPath(runtimeDirs, this->Relink);
182
183 for (std::string const& rd : runtimeDirs) {
184 rpath += cli.GetRuntimeFlag();
185 rpath += this->ConvertToOutputFormat(rd);
186 rpath += " ";
187 }
188 } else {
189 // All rpath entries are combined ("-Wl,-rpath,a:b:c").
190 std::string rpathString = cli.GetRPathString(this->Relink);
191
192 // Store the rpath option in the stream.
193 if (!rpathString.empty()) {
194 rpath += cli.GetRuntimeFlag();
195 rpath +=
196 this->OutputConverter->EscapeForShell(rpathString, !this->ForResponse);
197 rpath += " ";
198 }
199 }
200 return rpath;
201}
202
203std::string cmLinkLineComputer::ComputeFrameworkPath(
204 cmComputeLinkInformation& cli, cmValue fwSearchFlag)

Callers 2

ComputeLinkLibrariesMethod · 0.95

Calls 5

ConvertToOutputFormatMethod · 0.95
GetRPathStringMethod · 0.80
EscapeForShellMethod · 0.80
emptyMethod · 0.45
GetRPathMethod · 0.45

Tested by

no test coverage detected