diff options
author | Brad King <brad.king@kitware.com> | 2024-02-21 13:39:00 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2024-02-21 13:39:37 (GMT) |
commit | 6b8c99a1e36c17a3f2f921122e659ef3831668b7 (patch) | |
tree | 2e83ec85df2e7fe88fadf2a408ba9c7c2d53085a /Tests/BuildDepends | |
parent | aad37338c75dbcabfb50f89053754d45f8032cbe (diff) | |
download | CMake-6b8c99a1e36c17a3f2f921122e659ef3831668b7.zip CMake-6b8c99a1e36c17a3f2f921122e659ef3831668b7.tar.gz CMake-6b8c99a1e36c17a3f2f921122e659ef3831668b7.tar.bz2 |
Tests: Fix BuildDepends on macOS arm64 without rosetta
Diffstat (limited to 'Tests/BuildDepends')
-rw-r--r-- | Tests/BuildDepends/Project/CMakeLists.txt | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/Tests/BuildDepends/Project/CMakeLists.txt b/Tests/BuildDepends/Project/CMakeLists.txt index 7fddf4b..a320d53 100644 --- a/Tests/BuildDepends/Project/CMakeLists.txt +++ b/Tests/BuildDepends/Project/CMakeLists.txt @@ -17,7 +17,9 @@ if(APPLE) # only use multi-arch if the sysroot exists on this machine # Ninja needs -M which could not be used with multiple -arch flags if(EXISTS "${CMAKE_OSX_SYSROOT}" AND NOT "${CMAKE_GENERATOR}" MATCHES "Ninja") - if(CMake_TEST_XCODE_VERSION VERSION_GREATER_EQUAL 10) + if(CMake_TEST_XCODE_VERSION VERSION_GREATER_EQUAL 12) + set(CMAKE_OSX_ARCHITECTURES arm64 x86_64) + elseif(CMake_TEST_XCODE_VERSION VERSION_GREATER_EQUAL 10) # Arch 'i386' no longer works in Xcode 10. set(CMAKE_OSX_ARCHITECTURES x86_64) elseif(CMake_TEST_XCODE_VERSION VERSION_GREATER_EQUAL 4) |