diff options
author | Stephen Kelly <steveire@gmail.com> | 2015-10-17 13:01:25 (GMT) |
---|---|---|
committer | Stephen Kelly <steveire@gmail.com> | 2015-10-18 14:29:30 (GMT) |
commit | 2b9cc1e24871c6b527900e119640ef0adf706f0d (patch) | |
tree | 3f0507a829506cddce87533adb6541c956ce1c6f /Source | |
parent | 97062ac268d1bcc62a528aea2e22a7dd6f6efa8f (diff) | |
download | CMake-2b9cc1e24871c6b527900e119640ef0adf706f0d.zip CMake-2b9cc1e24871c6b527900e119640ef0adf706f0d.tar.gz CMake-2b9cc1e24871c6b527900e119640ef0adf706f0d.tar.bz2 |
Export: Port some API to cmGlobalGenerator.
Diffstat (limited to 'Source')
-rw-r--r-- | Source/cmExportBuildFileGenerator.cxx | 12 | ||||
-rw-r--r-- | Source/cmExportBuildFileGenerator.h | 3 | ||||
-rw-r--r-- | Source/cmExportFileGenerator.cxx | 1 | ||||
-rw-r--r-- | Source/cmExportFileGenerator.h | 1 | ||||
-rw-r--r-- | Source/cmExportInstallFileGenerator.cxx | 8 | ||||
-rw-r--r-- | Source/cmExportInstallFileGenerator.h | 3 | ||||
-rw-r--r-- | Source/cmExportTryCompileFileGenerator.h | 1 |
7 files changed, 13 insertions, 16 deletions
diff --git a/Source/cmExportBuildFileGenerator.cxx b/Source/cmExportBuildFileGenerator.cxx index 194d9a2..c24138f 100644 --- a/Source/cmExportBuildFileGenerator.cxx +++ b/Source/cmExportBuildFileGenerator.cxx @@ -235,14 +235,17 @@ cmExportBuildFileGenerator //---------------------------------------------------------------------------- void cmExportBuildFileGenerator::HandleMissingTarget( - std::string& link_libs, std::vector<std::string>& missingTargets, - cmMakefile* mf, cmTarget* depender, cmTarget* dependee) + std::string& link_libs, + std::vector<std::string>& missingTargets, + cmTarget* depender, + cmTarget* dependee) { // The target is not in the export. if(!this->AppendMode) { const std::string name = dependee->GetName(); - std::vector<std::string> namespaces = this->FindNamespaces(mf, name); + cmGlobalGenerator* gg = dependee->GetMakefile()->GetGlobalGenerator(); + std::vector<std::string> namespaces = this->FindNamespaces(gg, name); int targetOccurrences = (int)namespaces.size(); if (targetOccurrences == 1) @@ -287,10 +290,9 @@ void cmExportBuildFileGenerator //---------------------------------------------------------------------------- std::vector<std::string> cmExportBuildFileGenerator -::FindNamespaces(cmMakefile* mf, const std::string& name) +::FindNamespaces(cmGlobalGenerator* gg, const std::string& name) { std::vector<std::string> namespaces; - cmGlobalGenerator* gg = mf->GetGlobalGenerator(); std::map<std::string, cmExportBuildFileGenerator*>& exportSets = gg->GetBuildExportSets(); diff --git a/Source/cmExportBuildFileGenerator.h b/Source/cmExportBuildFileGenerator.h index 16695f1..c7d317f 100644 --- a/Source/cmExportBuildFileGenerator.h +++ b/Source/cmExportBuildFileGenerator.h @@ -54,7 +54,6 @@ protected: std::vector<std::string> &missingTargets); virtual void HandleMissingTarget(std::string& link_libs, std::vector<std::string>& missingTargets, - cmMakefile* mf, cmTarget* depender, cmTarget* dependee); @@ -72,7 +71,7 @@ protected: const std::string& config); std::vector<std::string> - FindNamespaces(cmMakefile* mf, const std::string& name); + FindNamespaces(cmGlobalGenerator* gg, const std::string& name); std::vector<std::string> Targets; cmExportSet *ExportSet; diff --git a/Source/cmExportFileGenerator.cxx b/Source/cmExportFileGenerator.cxx index 0985542..192a932 100644 --- a/Source/cmExportFileGenerator.cxx +++ b/Source/cmExportFileGenerator.cxx @@ -661,7 +661,6 @@ cmExportFileGenerator::AddTargetNamespace(std::string &input, { std::string namespacedTarget; this->HandleMissingTarget(namespacedTarget, missingTargets, - target->Target->GetMakefile(), target->Target, tgt->Target); if (!namespacedTarget.empty()) { diff --git a/Source/cmExportFileGenerator.h b/Source/cmExportFileGenerator.h index 3280a03..e1ff83d 100644 --- a/Source/cmExportFileGenerator.h +++ b/Source/cmExportFileGenerator.h @@ -119,7 +119,6 @@ protected: * export set. */ virtual void HandleMissingTarget(std::string& link_libs, std::vector<std::string>& missingTargets, - cmMakefile* mf, cmTarget* depender, cmTarget* dependee) = 0; void PopulateInterfaceProperty(const std::string&, diff --git a/Source/cmExportInstallFileGenerator.cxx b/Source/cmExportInstallFileGenerator.cxx index 67697f8..48f92b0 100644 --- a/Source/cmExportInstallFileGenerator.cxx +++ b/Source/cmExportInstallFileGenerator.cxx @@ -455,10 +455,11 @@ cmExportInstallFileGenerator void cmExportInstallFileGenerator::HandleMissingTarget( std::string& link_libs, std::vector<std::string>& missingTargets, - cmMakefile* mf, cmTarget* depender, cmTarget* dependee) + cmTarget* depender, cmTarget* dependee) { const std::string name = dependee->GetName(); - std::vector<std::string> namespaces = this->FindNamespaces(mf, name); + cmGlobalGenerator* gg = dependee->GetMakefile()->GetGlobalGenerator(); + std::vector<std::string> namespaces = this->FindNamespaces(gg, name); int targetOccurrences = (int)namespaces.size(); if (targetOccurrences == 1) { @@ -479,10 +480,9 @@ cmExportInstallFileGenerator::HandleMissingTarget( //---------------------------------------------------------------------------- std::vector<std::string> cmExportInstallFileGenerator -::FindNamespaces(cmMakefile* mf, const std::string& name) +::FindNamespaces(cmGlobalGenerator* gg, const std::string& name) { std::vector<std::string> namespaces; - cmGlobalGenerator* gg = mf->GetGlobalGenerator(); const cmExportSetMap& exportSets = gg->GetExportSets(); for(cmExportSetMap::const_iterator expIt = exportSets.begin(); diff --git a/Source/cmExportInstallFileGenerator.h b/Source/cmExportInstallFileGenerator.h index b06fee5..b1fa70e 100644 --- a/Source/cmExportInstallFileGenerator.h +++ b/Source/cmExportInstallFileGenerator.h @@ -57,7 +57,6 @@ protected: std::vector<std::string> &missingTargets); virtual void HandleMissingTarget(std::string& link_libs, std::vector<std::string>& missingTargets, - cmMakefile* mf, cmTarget* depender, cmTarget* dependee); @@ -67,7 +66,7 @@ protected: cmTarget* dependee, int occurrences); - std::vector<std::string> FindNamespaces(cmMakefile* mf, + std::vector<std::string> FindNamespaces(cmGlobalGenerator* gg, const std::string& name); diff --git a/Source/cmExportTryCompileFileGenerator.h b/Source/cmExportTryCompileFileGenerator.h index 19d8024..50c3187 100644 --- a/Source/cmExportTryCompileFileGenerator.h +++ b/Source/cmExportTryCompileFileGenerator.h @@ -37,7 +37,6 @@ protected: std::vector<std::string>&) {} virtual void HandleMissingTarget(std::string&, std::vector<std::string>&, - cmMakefile*, cmTarget*, cmTarget*) {} |