diff options
author | Brad King <brad.king@kitware.com> | 2006-02-20 00:29:30 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2006-02-20 00:29:30 (GMT) |
commit | 3ca9ef09b72612bd48438701c03ebadc1295441e (patch) | |
tree | ca05f85f942668a1f3bce0cabd2164e1827faeb6 /Source/cmFileCommand.cxx | |
parent | c21287552bd262a60c38e495b75c91888882e681 (diff) | |
download | CMake-3ca9ef09b72612bd48438701c03ebadc1295441e.zip CMake-3ca9ef09b72612bd48438701c03ebadc1295441e.tar.gz CMake-3ca9ef09b72612bd48438701c03ebadc1295441e.tar.bz2 |
BUG: Fixed optional file install support for multi-configuration generators.
Diffstat (limited to 'Source/cmFileCommand.cxx')
-rw-r--r-- | Source/cmFileCommand.cxx | 29 |
1 files changed, 8 insertions, 21 deletions
diff --git a/Source/cmFileCommand.cxx b/Source/cmFileCommand.cxx index 188af27..36d309e 100644 --- a/Source/cmFileCommand.cxx +++ b/Source/cmFileCommand.cxx @@ -290,13 +290,6 @@ bool cmFileCommand::HandleInstallCommand( const char* destdir = cmSystemTools::GetEnv("DESTDIR"); - std::string extra_dir = ""; - if ( build_type ) - { - extra_dir = build_type; - std::string btype = cmSystemTools::LowerCase(build_type); - } - std::vector<std::string> files; int itype = cmTarget::INSTALL_FILES; @@ -553,14 +546,9 @@ bool cmFileCommand::HandleInstallCommand( } // Reconstruct the source file path taking into account the - // extra directory and possible new file name. + // possibly new file name. cmOStringStream str; - str << cmSystemTools::GetFilenamePath(ctarget) << "/"; - if ( extra_dir.size() > 0 ) - { - str << extra_dir << "/"; - } - str << fname; + str << cmSystemTools::GetFilenamePath(ctarget) << "/" << fname; ctarget = str.str(); } break; @@ -597,23 +585,22 @@ bool cmFileCommand::HandleInstallCommand( } // Reconstruct the source file path taking into account the - // extra directory and possible new file name. + // possibly new file name. cmOStringStream str; - str << cmSystemTools::GetFilenamePath(ctarget) << "/"; - if ( extra_dir.size() > 0 ) - { - str << extra_dir << "/"; - } - str << fname; + str << cmSystemTools::GetFilenamePath(ctarget) << "/" << fname; ctarget = str.str(); } break; } + std::string message; if ( !cmSystemTools::SameFile(ctarget.c_str(), destfile.c_str()) ) { if ( cmSystemTools::FileExists(ctarget.c_str()) ) { + message = "Installing "; + message += destfile.c_str(); + m_Makefile->DisplayStatus(message.c_str(), -1); cmSystemTools::RemoveFile(destfile.c_str()); if ( !cmSystemTools::CopyFileAlways(ctarget.c_str(), destination.c_str()) ) |