Skip to content

Commit 6957065

Browse files
committed
Fix uninstallation random failures on Windows
On Windows, the 'uninstall' target failed randomly. The CMake command used for deleting files, 'cmake -E remove' seems to be not reliable. Changing the tool used for files deletion to 'rm'.
1 parent e17a0ad commit 6957065

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

cmake/cmake_uninstall.cmake.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ foreach(file ${files})
1010
message(STATUS "Uninstalling $ENV{DESTDIR}${file}")
1111
if(IS_SYMLINK "$ENV{DESTDIR}${file}" OR EXISTS "$ENV{DESTDIR}${file}")
1212
execute_process(
13-
COMMAND @CMAKE_COMMAND@ -E remove $ENV{DESTDIR}${file}
13+
COMMAND rm -f $ENV{DESTDIR}${file}
1414
OUTPUT_VARIABLE rm_out
1515
RESULT_VARIABLE rm_retval
1616
)

0 commit comments

Comments
 (0)