diff options
author | Yury G. Kudryashov <urkud.urkud@gmail.com> | 2012-02-26 21:04:43 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2012-09-28 13:21:39 (GMT) |
commit | e846e7031fd16ac3e3418ca3a6871aa3f1b6a822 (patch) | |
tree | bd8059fc07adc3ad590075f6f66d6f0a50b76161 /Source/cmInstallCommand.cxx | |
parent | 81c66c8b88d756a1605aa1aac1de49df77feecdd (diff) | |
download | CMake-e846e7031fd16ac3e3418ca3a6871aa3f1b6a822.zip CMake-e846e7031fd16ac3e3418ca3a6871aa3f1b6a822.tar.gz CMake-e846e7031fd16ac3e3418ca3a6871aa3f1b6a822.tar.bz2 |
exports: Remove cmTargetExport constructor
The constructor was used exactly once.
Setting members explicitly makes the code more readable.
Diffstat (limited to 'Source/cmInstallCommand.cxx')
-rw-r--r-- | Source/cmInstallCommand.cxx | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/Source/cmInstallCommand.cxx b/Source/cmInstallCommand.cxx index 4016734..de92538 100644 --- a/Source/cmInstallCommand.cxx +++ b/Source/cmInstallCommand.cxx @@ -17,6 +17,7 @@ #include "cmInstallTargetGenerator.h" #include "cmInstallExportGenerator.h" #include "cmInstallCommandArguments.h" +#include "cmTargetExport.h" #include <cmsys/Glob.hxx> @@ -735,6 +736,24 @@ bool cmInstallCommand::HandleTargetsMode(std::vector<std::string> const& args) // this is not a namelink-only rule. if(!exports.GetString().empty() && !namelinkOnly) { + cmTargetExport *te = new cmTargetExport; + te->Target = ⌖ + te->ArchiveGenerator = archiveGenerator; + te->BundleGenerator = bundleGenerator; + te->FrameworkGenerator = frameworkGenerator; + te->HeaderGenerator = publicHeaderGenerator; + te->LibraryGenerator = libraryGenerator; + te->RuntimeGenerator = runtimeGenerator; + this->Makefile->GetLocalGenerator()->GetGlobalGenerator() + ->AddTargetToExports(exports.GetCString(), te); + } + } + + + // Add this install rule to an export if one was specified and + // this is not a namelink-only rule. + if(!exports.GetString().empty() && !namelinkOnly) + { this->Makefile->GetLocalGenerator()->GetGlobalGenerator() ->AddTargetToExports(exports.GetCString(), &target, archiveGenerator, runtimeGenerator, @@ -743,6 +762,7 @@ bool cmInstallCommand::HandleTargetsMode(std::vector<std::string> const& args) } } + // Tell the global generator about any installation component names // specified if (installsArchive) |