[cmake-commits] king committed cmake_uninstall.cmake.in 1.2 1.3

cmake-commits at cmake.org cmake-commits at cmake.org
Mon Jan 22 10:39:18 EST 2007


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

Modified Files:
	cmake_uninstall.cmake.in 
Log Message:
BUG: Patch from bug#4312 to make uninstall work with DESTDIR.


Index: cmake_uninstall.cmake.in
===================================================================
RCS file: /cvsroot/CMake/CMake/cmake_uninstall.cmake.in,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -d -r1.2 -r1.3
--- cmake_uninstall.cmake.in	5 Jun 2006 18:13:03 -0000	1.2
+++ cmake_uninstall.cmake.in	22 Jan 2007 15:39:16 -0000	1.3
@@ -5,18 +5,18 @@
 FILE(READ "@CMAKE_CURRENT_BINARY_DIR@/install_manifest.txt" files)
 STRING(REGEX REPLACE "\n" ";" files "${files}")
 FOREACH(file ${files})
-  MESSAGE(STATUS "Uninstalling \"${file}\"")
-  IF(EXISTS "${file}")
+  MESSAGE(STATUS "Uninstalling \"$ENV{DESTDIR}${file}\"")
+  IF(EXISTS "$ENV{DESTDIR}${file}")
     EXEC_PROGRAM(
-      "@CMAKE_COMMAND@" ARGS "-E remove \"${file}\""
+      "@CMAKE_COMMAND@" ARGS "-E remove \"$ENV{DESTDIR}${file}\""
       OUTPUT_VARIABLE rm_out
       RETURN_VALUE rm_retval
       )
     IF("${rm_retval}" STREQUAL 0)
     ELSE("${rm_retval}" STREQUAL 0)
-      MESSAGE(FATAL_ERROR "Problem when removing \"${file}\"")
+      MESSAGE(FATAL_ERROR "Problem when removing \"$ENV{DESTDIR}${file}\"")
     ENDIF("${rm_retval}" STREQUAL 0)
-  ELSE(EXISTS "${file}")
-    MESSAGE(STATUS "File \"${file}\" does not exist.")
-  ENDIF(EXISTS "${file}")
+  ELSE(EXISTS "$ENV{DESTDIR}${file}")
+    MESSAGE(STATUS "File \"$ENV{DESTDIR}${file}\" does not exist.")
+  ENDIF(EXISTS "$ENV{DESTDIR}${file}")
 ENDFOREACH(file)



More information about the Cmake-commits mailing list