summaryrefslogtreecommitdiffstats
path: root/Tests/RunCMake/execute_process/WindowsNoExtensionRunScript.cmake
diff options
context:
space:
mode:
Diffstat (limited to 'Tests/RunCMake/execute_process/WindowsNoExtensionRunScript.cmake')
-rw-r--r--Tests/RunCMake/execute_process/WindowsNoExtensionRunScript.cmake17
1 files changed, 17 insertions, 0 deletions
diff --git a/Tests/RunCMake/execute_process/WindowsNoExtensionRunScript.cmake b/Tests/RunCMake/execute_process/WindowsNoExtensionRunScript.cmake
new file mode 100644
index 0000000..8e640a0
--- /dev/null
+++ b/Tests/RunCMake/execute_process/WindowsNoExtensionRunScript.cmake
@@ -0,0 +1,17 @@
+file(COPY_FILE "${exe_no_extension}" "${CMAKE_CURRENT_BINARY_DIR}/exe" INPUT_MAY_BE_RECENT)
+execute_process(
+ COMMAND "${CMAKE_CURRENT_BINARY_DIR}/exe"
+ COMMAND_ERROR_IS_FATAL ANY
+ )
+
+file(COPY_FILE "${exe_extension}" "${CMAKE_CURRENT_BINARY_DIR}/exe.exe" INPUT_MAY_BE_RECENT)
+execute_process(
+ COMMAND "${CMAKE_CURRENT_BINARY_DIR}/exe"
+ COMMAND_ERROR_IS_FATAL ANY
+ )
+
+file(REMOVE "${CMAKE_CURRENT_BINARY_DIR}/exe")
+execute_process(
+ COMMAND "${CMAKE_CURRENT_BINARY_DIR}/exe"
+ COMMAND_ERROR_IS_FATAL ANY
+ )