[Cmake-commits] [cmake-commits] king committed cmFileCommand.cxx 1.124 1.125

cmake-commits at cmake.org cmake-commits at cmake.org
Wed Apr 29 08:47:00 EDT 2009


Update of /cvsroot/CMake/CMake/Source
In directory public:/mounts/ram/cvs-serv30760/Source

Modified Files:
	cmFileCommand.cxx 
Log Message:
BUG: Error when install dir cannot be created

This teaches the undocumented file(INSTALL) command to report an error
when it cannot create the destination directory.


Index: cmFileCommand.cxx
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/cmFileCommand.cxx,v
retrieving revision 1.124
retrieving revision 1.125
diff -C 2 -d -r1.124 -r1.125
*** cmFileCommand.cxx	29 Apr 2009 12:46:36 -0000	1.124
--- cmFileCommand.cxx	29 Apr 2009 12:46:56 -0000	1.125
***************
*** 1193,1196 ****
--- 1193,1200 ----
    if(!cmSystemTools::MakeDirectory(destination))
      {
+     cmOStringStream e;
+     e << "INSTALL cannot make directory \"" << destination << "\": "
+       << cmSystemTools::GetLastSystemError();
+     this->FileCommand->SetError(e.str().c_str());
      return false;
      }



More information about the Cmake-commits mailing list