Skip to content

Commit a0b2f62

Browse files
authored
Merge branch 'main' into cmake-windows
2 parents 8d3ff34 + 274c345 commit a0b2f62

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

CMakeLists.txt

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,12 +59,17 @@ if(APPLE)
5959

6060
# iOS build options
6161
option(BUILD_IOS "Build for iOS" NO)
62+
option(FORCE_RESET_OSX_DEPLOYMENT_TARGET "Clear the OSX Deployment Target Set" YES)
6263

6364
if(BUILD_IOS)
6465
set(TARGET_ARCH "APPLE")
6566
set(IOS True)
6667
set(APPLE True)
67-
set(CMAKE_OSX_DEPLOYMENT_TARGET "" CACHE STRING "Force unset of the deployment target for iOS" FORCE)
68+
69+
if(FORCE_RESET_OSX_DEPLOYMENT_TARGET)
70+
set(CMAKE_OSX_DEPLOYMENT_TARGET "" CACHE STRING "Force unset of the deployment target for iOS" FORCE)
71+
endif()
72+
6873
if((${IOS_PLAT} STREQUAL "iphonesimulator") AND (${IOS_ARCH} STREQUAL "arm64"))
6974
# iOS arm64 simulator is supported starting BigSur
7075
# Unfortunately, CMAKE produces a device binary (not simulator) when providing -miphoneos-version-min flag when building iOS arm64 simulator

0 commit comments

Comments
 (0)