summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2021-07-19 19:09:36 (GMT)
committerBrad King <brad.king@kitware.com>2021-07-19 19:28:14 (GMT)
commitf75610d49245b1ffac7526e1fc8b55080669dad7 (patch)
treeaaf4afb9308ab44d80d3165611ef25fe4de710a5
parent4ff651eb52215ca0e1ffe5e5356b56b57913fee0 (diff)
downloadCMake-f75610d49245b1ffac7526e1fc8b55080669dad7.zip
CMake-f75610d49245b1ffac7526e1fc8b55080669dad7.tar.gz
CMake-f75610d49245b1ffac7526e1fc8b55080669dad7.tar.bz2
CMakeDetermineCompilerId: Fix CMAKE_EXECUTABLE_FORMAT in CMP0126 NEW behavior
Setting `CMAKE_EXECUTABLE_FORMAT` as a normal variable is unnecessary because setting it as a cache entry already makes the value visible to the calling scope. Fixes: #22433
-rw-r--r--Modules/CMakeDetermineCompilerId.cmake4
1 files changed, 0 insertions, 4 deletions
diff --git a/Modules/CMakeDetermineCompilerId.cmake b/Modules/CMakeDetermineCompilerId.cmake
index bd1e732..e933cf4 100644
--- a/Modules/CMakeDetermineCompilerId.cmake
+++ b/Modules/CMakeDetermineCompilerId.cmake
@@ -1012,9 +1012,6 @@ function(CMAKE_DETERMINE_COMPILER_ID_CHECK lang file)
endif()
endif()
- if(NOT DEFINED CMAKE_EXECUTABLE_FORMAT)
- set(CMAKE_EXECUTABLE_FORMAT)
- endif()
# Return the information extracted.
set(CMAKE_${lang}_COMPILER_ID "${CMAKE_${lang}_COMPILER_ID}" PARENT_SCOPE)
set(CMAKE_${lang}_PLATFORM_ID "${CMAKE_${lang}_PLATFORM_ID}" PARENT_SCOPE)
@@ -1026,7 +1023,6 @@ function(CMAKE_DETERMINE_COMPILER_ID_CHECK lang file)
set(CMAKE_${lang}_COMPILER_WRAPPER "${COMPILER_WRAPPER}" PARENT_SCOPE)
set(CMAKE_${lang}_SIMULATE_ID "${CMAKE_${lang}_SIMULATE_ID}" PARENT_SCOPE)
set(CMAKE_${lang}_SIMULATE_VERSION "${CMAKE_${lang}_SIMULATE_VERSION}" PARENT_SCOPE)
- set(CMAKE_EXECUTABLE_FORMAT "${CMAKE_EXECUTABLE_FORMAT}" PARENT_SCOPE)
set(COMPILER_QNXNTO "${COMPILER_QNXNTO}" PARENT_SCOPE)
set(CMAKE_${lang}_STANDARD_COMPUTED_DEFAULT "${CMAKE_${lang}_STANDARD_COMPUTED_DEFAULT}" PARENT_SCOPE)
endfunction()