From fdf7b203af156f08bf149b35d0b54573d4b25abf Mon Sep 17 00:00:00 2001 From: Brad King Date: Thu, 28 Jun 2007 16:11:18 -0400 Subject: 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. --- Source/cmInstallFilesGenerator.cxx | 27 ++++++++++++--------------- 1 file changed, 12 insertions(+), 15 deletions(-) (limited to 'Source/cmInstallFilesGenerator.cxx') diff --git a/Source/cmInstallFilesGenerator.cxx b/Source/cmInstallFilesGenerator.cxx index 76cdaa5277..d487aba3db 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::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()); } -- cgit v1.2.1