From 2edf0fc6d73510f4e93e2750bc0dbc8c6c376633 Mon Sep 17 00:00:00 2001 From: Matthew Woehlke Date: Tue, 13 Sep 2022 10:07:56 -0400 Subject: Modules: Use new keyword-dispatched try_compile signature Modify most of the modules that ship with CMake to use the new try_compile / try_run signatures added by commit aa9220d3a0 (try_compile: Add keyword-dispatched signature, 2022-09-02). This improves debugging by each invocation using its own directory so that the results of multiple invocations can be retained. This does not cover any invocations which provide an entire project, as that flavor of try_compile has not yet been updated. --- Modules/TestBigEndian.cmake | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'Modules/TestBigEndian.cmake') diff --git a/Modules/TestBigEndian.cmake b/Modules/TestBigEndian.cmake index ea8ca73b35..e738d3259b 100644 --- a/Modules/TestBigEndian.cmake +++ b/Modules/TestBigEndian.cmake @@ -89,8 +89,7 @@ macro(__TEST_BIG_ENDIAN_LEGACY_IMPL VARIABLE) file(READ ${_test_file} TEST_ENDIANESS_FILE_CONTENT) try_compile(HAVE_${VARIABLE} - "${CMAKE_BINARY_DIR}" - ${_test_file} + SOURCES ${_test_file} OUTPUT_VARIABLE OUTPUT COPY_FILE "${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/TestEndianess.bin" ) -- cgit v1.2.1