summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlexander Neundorf <neundorf@kde.org>2008-01-07 19:52:45 (GMT)
committerAlexander Neundorf <neundorf@kde.org>2008-01-07 19:52:45 (GMT)
commit9f2790d3e7e5a1e8e564d7f670fe2ff8b28cf6e6 (patch)
tree440b99f3f5b24967cb919207d2588e4c38a96ee1
parente73508aa652d6d91d9e2fae18649b6023e2e851d (diff)
downloadCMake-9f2790d3e7e5a1e8e564d7f670fe2ff8b28cf6e6.zip
CMake-9f2790d3e7e5a1e8e564d7f670fe2ff8b28cf6e6.tar.gz
CMake-9f2790d3e7e5a1e8e564d7f670fe2ff8b28cf6e6.tar.bz2
BUG: with cmake 2.4 INSTALL_FILES() with no files was accepted by cmake,
with cmake cvs without this patch an invalid cmake_install.cmake script was generated in this case, it failed with an error if no files were given. So just do nothing if no files are listed to make it compatible. http://lists.kde.org/?l=kde-commits&m=119965185114478&w=2 Alex
-rw-r--r--Source/cmFileCommand.cxx8
1 files changed, 5 insertions, 3 deletions
diff --git a/Source/cmFileCommand.cxx b/Source/cmFileCommand.cxx
index 6186596..c03bf71 100644
--- a/Source/cmFileCommand.cxx
+++ b/Source/cmFileCommand.cxx
@@ -1614,9 +1614,11 @@ bool cmFileCommand::ParseInstallArgs(std::vector<std::string> const& args,
// now check and postprocess what has been parsed
if ( files.size() == 0 )
{
- this->SetError(
- "called with inapropriate arguments. No FILES provided.");
- return false;
+ // nothing to do, no files were listed.
+ // if this is handled as error, INSTALL_FILES() creates an invalid
+ // cmake_install.cmake script with no FILES() arguments if no files were
+ // given to INSTALL_FILES(). This was accepted with CMake 2.4.x.
+ return true;
}
// Check rename form.