summaryrefslogtreecommitdiffstats
path: root/Source/cmGlobalGenerator.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'Source/cmGlobalGenerator.cxx')
-rw-r--r--Source/cmGlobalGenerator.cxx15
1 files changed, 13 insertions, 2 deletions
diff --git a/Source/cmGlobalGenerator.cxx b/Source/cmGlobalGenerator.cxx
index 7552c99..46ef2f3 100644
--- a/Source/cmGlobalGenerator.cxx
+++ b/Source/cmGlobalGenerator.cxx
@@ -1091,6 +1091,18 @@ void cmGlobalGenerator::ClearEnabledLanguages()
return this->CMakeInstance->GetState()->ClearEnabledLanguages();
}
+void cmGlobalGenerator::CreateLocalGenerators()
+{
+ cmDeleteAll(this->LocalGenerators);
+ this->LocalGenerators.clear();
+ this->LocalGenerators.reserve(this->Makefiles.size());
+ for (std::vector<cmMakefile*>::const_iterator it = this->Makefiles.begin();
+ it != this->Makefiles.end(); ++it)
+ {
+ this->LocalGenerators.push_back(this->CreateLocalGenerator(*it));
+ }
+}
+
void cmGlobalGenerator::Configure()
{
this->FirstTimeProgress = 0.0f;
@@ -1112,8 +1124,7 @@ void cmGlobalGenerator::Configure()
// now do it
this->ConfigureDoneCMP0026 = false;
dirMf->Configure();
- this->LocalGenerators.insert(this->LocalGenerators.begin(),
- this->CreateLocalGenerator(dirMf));
+ this->CreateLocalGenerators();
dirMf->EnforceDirectoryLevelRules();
this->ConfigureDoneCMP0026 = true;