diff options
author | Brad King <brad.king@kitware.com> | 2007-06-28 20:11:18 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2007-06-28 20:11:18 (GMT) |
commit | fdf7b203af156f08bf149b35d0b54573d4b25abf (patch) | |
tree | d73c95726631536288f9efd46a704f2d5b11b3c8 /Source/cmInstallFilesGenerator.cxx | |
parent | 33e9becd6f1a8343d347611c2037bd980ea41690 (diff) | |
download | CMake-fdf7b203af156f08bf149b35d0b54573d4b25abf.zip CMake-fdf7b203af156f08bf149b35d0b54573d4b25abf.tar.gz CMake-fdf7b203af156f08bf149b35d0b54573d4b25abf.tar.bz2 |
ENH: First step of install script generator cleanup. Each configuration to be installed is now separately handled instead of using variables to store per-configuration names. For targets the component and configuration install-time tests are now done in the install script instead of in the FILE(INSTALL) command. This cleans things up like not trying to strip a file that was optionally not installed. It also simplifies the code for install_name adjustment on OSX. This commit is surrounded by the tags CMake-InstallGeneratorCleanup1-pre and CMake-InstallGeneratorCleanup1-post.
Diffstat (limited to 'Source/cmInstallFilesGenerator.cxx')
-rw-r--r-- | Source/cmInstallFilesGenerator.cxx | 27 |
1 files changed, 12 insertions, 15 deletions
diff --git a/Source/cmInstallFilesGenerator.cxx b/Source/cmInstallFilesGenerator.cxx index 76cdaa5..d487aba 100644 --- a/Source/cmInstallFilesGenerator.cxx +++ b/Source/cmInstallFilesGenerator.cxx @@ -43,19 +43,16 @@ cmInstallFilesGenerator void cmInstallFilesGenerator::GenerateScript(std::ostream& os) { // Write code to install the files. - for(std::vector<std::string>::const_iterator fi = this->Files.begin(); - fi != this->Files.end(); ++fi) - { - const char* no_properties = 0; - const char* no_dir_permissions = 0; - this->AddInstallRule(os, this->Destination.c_str(), - (this->Programs - ? cmTarget::INSTALL_PROGRAMS - : cmTarget::INSTALL_FILES), fi->c_str(), - this->Optional, no_properties, - this->FilePermissions.c_str(), no_dir_permissions, - this->Configurations, - this->Component.c_str(), - this->Rename.c_str()); - } + const char* no_properties = 0; + const char* no_dir_permissions = 0; + this->AddInstallRule(os, this->Destination.c_str(), + (this->Programs + ? cmTarget::INSTALL_PROGRAMS + : cmTarget::INSTALL_FILES), + this->Files, + this->Optional, no_properties, + this->FilePermissions.c_str(), no_dir_permissions, + this->Configurations, + this->Component.c_str(), + this->Rename.c_str()); } |