diff options
author | Stephen Kelly <steveire@gmail.com> | 2015-07-28 17:49:16 (GMT) |
---|---|---|
committer | Stephen Kelly <steveire@gmail.com> | 2015-07-30 06:28:31 (GMT) |
commit | e5e529701812bdfe7ea1c3ffe682bd576b9c05a8 (patch) | |
tree | 846381455e6517a9895a57c0683878460f8e5a6e /Source | |
parent | 3ef8aaaa71786b32ed88a29e48dd17d32f5a8a79 (diff) | |
download | CMake-e5e529701812bdfe7ea1c3ffe682bd576b9c05a8.zip CMake-e5e529701812bdfe7ea1c3ffe682bd576b9c05a8.tar.gz CMake-e5e529701812bdfe7ea1c3ffe682bd576b9c05a8.tar.bz2 |
cmInstallGenerator: Add a Compute() virtual hook.
Diffstat (limited to 'Source')
-rw-r--r-- | Source/cmGlobalGenerator.cxx | 12 | ||||
-rw-r--r-- | Source/cmInstallGenerator.h | 2 |
2 files changed, 14 insertions, 0 deletions
diff --git a/Source/cmGlobalGenerator.cxx b/Source/cmGlobalGenerator.cxx index 463f526..1d6608b 100644 --- a/Source/cmGlobalGenerator.cxx +++ b/Source/cmGlobalGenerator.cxx @@ -34,6 +34,7 @@ #include "cmExportBuildFileGenerator.h" #include "cmCPackPropertiesGenerator.h" #include "cmAlgorithms.h" +#include "cmInstallGenerator.h" #include <cmsys/Directory.hxx> #include <cmsys/FStream.hxx> @@ -1260,6 +1261,17 @@ bool cmGlobalGenerator::Compute() } #endif + for (i = 0; i < this->LocalGenerators.size(); ++i) + { + cmMakefile* mf = this->LocalGenerators[i]->GetMakefile(); + std::vector<cmInstallGenerator*>& gens = mf->GetInstallGenerators(); + for (std::vector<cmInstallGenerator*>::const_iterator git = gens.begin(); + git != gens.end(); ++git) + { + (*git)->Compute(this->LocalGenerators[i]); + } + } + return true; } diff --git a/Source/cmInstallGenerator.h b/Source/cmInstallGenerator.h index c4191e4..b8e5b53 100644 --- a/Source/cmInstallGenerator.h +++ b/Source/cmInstallGenerator.h @@ -62,6 +62,8 @@ public: /** Select message level from CMAKE_INSTALL_MESSAGE or 'never'. */ static MessageLevel SelectMessageLevel(cmMakefile* mf, bool never = false); + virtual void Compute(cmLocalGenerator*) {} + protected: virtual void GenerateScript(std::ostream& os); |