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

Method DiscoverSyntheticTargets

Source/cmGlobalGenerator.cxx:1872–1898  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1870}
1871
1872bool cmGlobalGenerator::DiscoverSyntheticTargets()
1873{
1874 cmSyntheticTargetCache cache;
1875
1876 for (auto const& gen : this->LocalGenerators) {
1877 // Because DiscoverSyntheticTargets() adds generator targets, we need to
1878 // cache the existing list of generator targets before starting.
1879 std::vector<cmGeneratorTarget*> genTargets;
1880 genTargets.reserve(gen->GetGeneratorTargets().size());
1881 for (auto const& tgt : gen->GetGeneratorTargets()) {
1882 genTargets.push_back(tgt.get());
1883 }
1884
1885 for (auto* tgt : genTargets) {
1886 std::vector<std::string> const& configs =
1887 tgt->Makefile->GetGeneratorConfigs(cmMakefile::IncludeEmptyConfig);
1888
1889 for (auto const& config : configs) {
1890 if (!tgt->DiscoverSyntheticTargets(cache, config)) {
1891 return false;
1892 }
1893 }
1894 }
1895 }
1896
1897 return true;
1898}
1899
1900bool cmGlobalGenerator::AddHeaderSetVerification()
1901{

Callers 1

ComputeMethod · 0.95

Calls 5

reserveMethod · 0.80
push_backMethod · 0.80
GetGeneratorConfigsMethod · 0.80
sizeMethod · 0.45
getMethod · 0.45

Tested by

no test coverage detected