mirror of
https://github.com/Kitware/CMake.git
synced 2026-01-09 15:20:56 -06:00
Tests/RunCMake/cmake_host_system_information: Cover macOS Malloc Debugging env
On macOS, `sw_vers` may print to `stderr` based on environment variables like `MallocGuardEdges=1`. Add a test to verify that we do not capture that as part of the information it prints to `stdout`. Issue: #26466
This commit is contained in:
@@ -0,0 +1 @@
|
||||
-- os_name='(macOS|Mac OS X)'
|
||||
3
Tests/RunCMake/cmake_host_system_information/MacOS.cmake
Normal file
3
Tests/RunCMake/cmake_host_system_information/MacOS.cmake
Normal file
@@ -0,0 +1,3 @@
|
||||
set(ENV{MallocGuardEdges} 1) # test tolerating sw_vers stderr
|
||||
cmake_host_system_information(RESULT os_name QUERY OS_NAME)
|
||||
message(STATUS "os_name='${os_name}'")
|
||||
@@ -14,6 +14,10 @@ run_cmake(Ubuntu)
|
||||
run_cmake(CentOS6)
|
||||
run_cmake(Debian6)
|
||||
|
||||
if(CMAKE_HOST_SYSTEM_NAME STREQUAL "Darwin")
|
||||
run_cmake(MacOS)
|
||||
endif()
|
||||
|
||||
run_cmake(UserFallbackScript)
|
||||
|
||||
if(RunCMake_GENERATOR MATCHES "Visual Studio")
|
||||
|
||||
Reference in New Issue
Block a user