From 350f999fc05669d84e5a236ecf494ccd9a38bb61 Mon Sep 17 00:00:00 2001 From: Alexander Widerberg Date: Thu, 10 Aug 2023 23:04:05 +0200 Subject: [PATCH] Update ios.toolchain.cmake Added arm64 as architecture to allow Apple Silicon simulators to be used when using the toolchain to generate xcode targets. Xcode 12.0+ only! Use the OS64Combined target to get the added benefit. --- ios.toolchain.cmake | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/ios.toolchain.cmake b/ios.toolchain.cmake index e47638e..d05c02e 100644 --- a/ios.toolchain.cmake +++ b/ios.toolchain.cmake @@ -326,12 +326,12 @@ elseif(PLATFORM_INT STREQUAL "OS64COMBINED") set(SDK_NAME iphoneos) if(MODERN_CMAKE) if(NOT ARCHS) - if (XCODE_VERSION_INT VERSION_GREATER 10.0) - set(ARCHS arm64 x86_64) # FIXME: Add arm64e when Apple has fixed the integration issues with it, libarclite_iphoneos.a is currently missing bitcode markers for example + if (XCODE_VERSION_INT VERSION_GREATER 12.0) + set(ARCHS arm64 x86_64) set(CMAKE_XCODE_ATTRIBUTE_ARCHS[sdk=iphoneos*] "arm64") - set(CMAKE_XCODE_ATTRIBUTE_ARCHS[sdk=iphonesimulator*] "x86_64") + set(CMAKE_XCODE_ATTRIBUTE_ARCHS[sdk=iphonesimulator*] "x86_64 arm64") set(CMAKE_XCODE_ATTRIBUTE_VALID_ARCHS[sdk=iphoneos*] "arm64") - set(CMAKE_XCODE_ATTRIBUTE_VALID_ARCHS[sdk=iphonesimulator*] "x86_64") + set(CMAKE_XCODE_ATTRIBUTE_VALID_ARCHS[sdk=iphonesimulator*] "x86_64 arm64") else() set(ARCHS arm64 x86_64) set(CMAKE_XCODE_ATTRIBUTE_ARCHS[sdk=iphoneos*] "arm64")