Skip to content

Commit

Permalink
Fixing write of the protocol option script for earlier versions of cm…
Browse files Browse the repository at this point in the history
…ake.
  • Loading branch information
arobenko committed Dec 30, 2023
1 parent f6f20eb commit c4d5c27
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions client/lib/script/WriteProtocolOptions.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,12 @@ file (WRITE "${OUT_FILE}.tmp" "${text}")
execute_process(
COMMAND ${CMAKE_COMMAND} -E copy_if_different "${OUT_FILE}.tmp" "${OUT_FILE}")

execute_process(
COMMAND ${CMAKE_COMMAND} -E rm -rf "${OUT_FILE}.tmp")
if(CMAKE_VERSION VERSION_LESS "3.8.0")
execute_process(
COMMAND ${CMAKE_COMMAND} -E remove -f "${OUT_FILE}.tmp")
else ()
execute_process(
COMMAND ${CMAKE_COMMAND} -E rm -rf "${OUT_FILE}.tmp")
endif()


0 comments on commit c4d5c27

Please sign in to comment.