cmGlobalGenerator: Implement FillProjectMap in terms of cmState.

This commit is contained in:
Stephen Kelly 2015-08-02 09:41:11 +02:00
parent b3f2299e06
commit 637c56b4e0
1 changed files with 6 additions and 5 deletions

View File

@ -2102,18 +2102,19 @@ void cmGlobalGenerator::FillProjectMap()
for(i = 0; i < this->LocalGenerators.size(); ++i)
{
// for each local generator add all projects
cmLocalGenerator *lg = this->LocalGenerators[i];
cmState::Snapshot snp = this->LocalGenerators[i]->GetStateSnapshot();
std::string name;
do
{
if (name != lg->GetMakefile()->GetProjectName())
std::string snpProjName = snp.GetProjectName();
if (name != snpProjName)
{
name = lg->GetMakefile()->GetProjectName();
name = snpProjName;
this->ProjectMap[name].push_back(this->LocalGenerators[i]);
}
lg = lg->GetParent();
snp = snp.GetBuildsystemDirectoryParent();
}
while (lg);
while (snp.IsValid());
}
}