diff options
Diffstat (limited to 'Source/cmGlobalGenerator.cxx')
-rw-r--r-- | Source/cmGlobalGenerator.cxx | 26 |
1 files changed, 23 insertions, 3 deletions
diff --git a/Source/cmGlobalGenerator.cxx b/Source/cmGlobalGenerator.cxx index a42ea22..1142ddd 100644 --- a/Source/cmGlobalGenerator.cxx +++ b/Source/cmGlobalGenerator.cxx @@ -1199,6 +1199,27 @@ void cmGlobalGenerator::CreateGenerationObjects(TargetTypes targetTypes) cmDeleteAll(this->GeneratorTargets); this->GeneratorTargets.clear(); this->CreateGeneratorTargets(targetTypes); + this->ComputeBuildFileGenerators(); +} + +void cmGlobalGenerator::CreateImportedGenerationObjects(cmMakefile* mf, + const std::vector<std::string>& targets, + std::vector<const cmGeneratorTarget*>& exports) +{ + this->CreateGenerationObjects(ImportedOnly); + std::vector<cmMakefile*>::iterator mfit = + std::find(this->Makefiles.begin(), this->Makefiles.end(), mf); + cmLocalGenerator* lg = + this->LocalGenerators[std::distance(this->Makefiles.begin(), mfit)]; + for (std::vector<std::string>::const_iterator it = targets.begin(); + it != targets.end(); ++it) + { + cmGeneratorTarget* gt = lg->FindGeneratorTargetToUse(*it); + if (gt) + { + exports.push_back(gt); + } + } } cmExportBuildFileGenerator* @@ -1279,8 +1300,6 @@ bool cmGlobalGenerator::Compute() this->CreateQtAutoGeneratorsTargets(); #endif - this->ComputeBuildFileGenerators(); - unsigned int i; // Add generator specific helper commands @@ -2189,7 +2208,8 @@ cmGlobalGenerator::NameResolvesToFramework(const std::string& libname) const if(cmTarget* tgt = this->FindTarget(libname)) { - if(tgt->IsFrameworkOnApple()) + cmGeneratorTarget* gt = this->GetGeneratorTarget(tgt); + if(gt->IsFrameworkOnApple()) { return true; } |