mirror of
https://github.com/Kitware/CMake.git
synced 2026-03-14 21:41:06 -05:00
Tests: Move RunCMake option construction closer to use
This commit is contained in:
@@ -64,15 +64,6 @@ function(run_cmake test)
|
||||
else()
|
||||
include(${top_src}/${test}-prep.cmake OPTIONAL)
|
||||
endif()
|
||||
if(NOT DEFINED RunCMake_TEST_OPTIONS)
|
||||
set(RunCMake_TEST_OPTIONS "")
|
||||
endif()
|
||||
if(APPLE)
|
||||
list(APPEND RunCMake_TEST_OPTIONS -DCMAKE_POLICY_DEFAULT_CMP0025=NEW)
|
||||
endif()
|
||||
if(RunCMake_MAKE_PROGRAM)
|
||||
list(APPEND RunCMake_TEST_OPTIONS "-DCMAKE_MAKE_PROGRAM=${RunCMake_MAKE_PROGRAM}")
|
||||
endif()
|
||||
if(RunCMake_TEST_OUTPUT_MERGE)
|
||||
set(actual_stderr_var actual_stdout)
|
||||
set(actual_stderr "")
|
||||
@@ -92,6 +83,15 @@ function(run_cmake test)
|
||||
set(maybe_input_file "")
|
||||
endif()
|
||||
if(NOT RunCMake_TEST_COMMAND)
|
||||
if(NOT DEFINED RunCMake_TEST_OPTIONS)
|
||||
set(RunCMake_TEST_OPTIONS "")
|
||||
endif()
|
||||
if(APPLE)
|
||||
list(APPEND RunCMake_TEST_OPTIONS -DCMAKE_POLICY_DEFAULT_CMP0025=NEW)
|
||||
endif()
|
||||
if(RunCMake_MAKE_PROGRAM)
|
||||
list(APPEND RunCMake_TEST_OPTIONS "-DCMAKE_MAKE_PROGRAM=${RunCMake_MAKE_PROGRAM}")
|
||||
endif()
|
||||
if(RunCMake_GENERATOR_INSTANCE)
|
||||
set(_D_CMAKE_GENERATOR_INSTANCE "-DCMAKE_GENERATOR_INSTANCE=${RunCMake_GENERATOR_INSTANCE}")
|
||||
else()
|
||||
|
||||
Reference in New Issue
Block a user