summaryrefslogtreecommitdiffstats
path: root/Tests
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2015-08-10 18:06:09 (GMT)
committerBrad King <brad.king@kitware.com>2015-08-11 14:18:04 (GMT)
commit586b2e5e3633db1e1749dc2bdd69f6240b714139 (patch)
treed4ca10077125fb33d5aba0127e32faca2848da06 /Tests
parent422d3f68de6bfa5c3fad68d2b030f2a618a821a2 (diff)
downloadCMake-586b2e5e3633db1e1749dc2bdd69f6240b714139.zip
CMake-586b2e5e3633db1e1749dc2bdd69f6240b714139.tar.gz
CMake-586b2e5e3633db1e1749dc2bdd69f6240b714139.tar.bz2
Tests: Fix CMAKE_MAKE_PROGRAM selection in CMakeOnly tests
Use the explicitly-tested make program, if any.
Diffstat (limited to 'Tests')
-rw-r--r--Tests/CMakeOnly/Test.cmake.in6
1 files changed, 6 insertions, 0 deletions
diff --git a/Tests/CMakeOnly/Test.cmake.in b/Tests/CMakeOnly/Test.cmake.in
index 8d3258b..0ae8af1 100644
--- a/Tests/CMakeOnly/Test.cmake.in
+++ b/Tests/CMakeOnly/Test.cmake.in
@@ -2,6 +2,11 @@ if (NOT TEST_SOURCE)
set(TEST_SOURCE "${TEST}")
endif ()
+set(make_program "@CMake_TEST_EXPLICIT_MAKE_PROGRAM@")
+if(make_program)
+ set(maybe_make_program "-DCMAKE_MAKE_PROGRAM=${make_program}")
+endif()
+
set(source_dir "@CMAKE_CURRENT_SOURCE_DIR@/${TEST_SOURCE}")
set(binary_dir "@CMAKE_CURRENT_BINARY_DIR@/${TEST}-build")
file(REMOVE_RECURSE "${binary_dir}")
@@ -11,6 +16,7 @@ execute_process(
"${source_dir}" -G "@CMAKE_GENERATOR@"
-A "@CMAKE_GENERATOR_PLATFORM@"
-T "@CMAKE_GENERATOR_TOOLSET@"
+ ${maybe_make_program}
WORKING_DIRECTORY "${binary_dir}"
RESULT_VARIABLE result
)