Skip to content

Commit 425374c

Browse files
committed
fix uninstall script by replacing deprecated exec_program()
1 parent aa73d58 commit 425374c

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

cmake/cmake_uninstall.cmake.in

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,10 @@ string(REGEX REPLACE "\n" ";" files "${files}")
1010
foreach(file ${files})
1111
message(STATUS "Uninstalling $ENV{DESTDIR}${file}")
1212
if(IS_SYMLINK "$ENV{DESTDIR}${file}" OR EXISTS "$ENV{DESTDIR}${file}")
13-
exec_program(
14-
"@CMAKE_COMMAND@" ARGS "-E remove \"$ENV{DESTDIR}${file}\""
13+
execute_process(
14+
COMMAND "@CMAKE_COMMAND@" -E remove "$ENV{DESTDIR}${file}"
1515
OUTPUT_VARIABLE rm_out
16-
RETURN_VALUE rm_retval
16+
RESULT_VARIABLE rm_retval
1717
)
1818
if(NOT "${rm_retval}" STREQUAL 0)
1919
message(FATAL_ERROR "Problem when removing $ENV{DESTDIR}${file}")

0 commit comments

Comments
 (0)