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

Method AppendLinkFlagsWithParsing

Source/cmLocalGenerator.cxx:2586–2603  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2584}
2585
2586void cmLocalGenerator::AppendLinkFlagsWithParsing(
2587 std::string& flags, std::string const& newFlags,
2588 cmGeneratorTarget const* target, std::string const& language)
2589{
2590 std::vector<std::string> options;
2591 cmSystemTools::ParseUnixCommandLine(newFlags.c_str(), options);
2592 this->SetLinkScriptShell(this->GlobalGenerator->GetUseLinkScript());
2593 std::vector<BT<std::string>> optionsWithBT{ options.size() };
2594 std::transform(options.cbegin(), options.cend(), optionsWithBT.begin(),
2595 [](std::string const& item) -> BT<std::string> {
2596 return BT<std::string>{ item };
2597 });
2598 target->ResolveLinkerWrapper(optionsWithBT, language);
2599 for (auto const& item : optionsWithBT) {
2600 this->AppendFlagEscape(flags, item.Value);
2601 }
2602 this->SetLinkScriptShell(false);
2603}
2604
2605void cmLocalGenerator::AppendFlags(std::string& flags,
2606 std::string const& newFlags,

Callers 2

AppendFlagsMethod · 0.95

Calls 9

AppendFlagEscapeMethod · 0.95
transformFunction · 0.85
c_strMethod · 0.80
SetLinkScriptShellMethod · 0.80
GetUseLinkScriptMethod · 0.80
cbeginMethod · 0.80
cendMethod · 0.80
sizeMethod · 0.45
beginMethod · 0.45

Tested by

no test coverage detected