summaryrefslogtreecommitdiffstats
path: root/mkspecs/features/mac/sdk.prf
diff options
context:
space:
mode:
Diffstat (limited to 'mkspecs/features/mac/sdk.prf')
-rw-r--r--mkspecs/features/mac/sdk.prf9
1 files changed, 7 insertions, 2 deletions
diff --git a/mkspecs/features/mac/sdk.prf b/mkspecs/features/mac/sdk.prf
index eaa3108a8b..ece0e27536 100644
--- a/mkspecs/features/mac/sdk.prf
+++ b/mkspecs/features/mac/sdk.prf
@@ -5,7 +5,7 @@ isEmpty(QMAKE_MAC_SDK): \
contains(QMAKE_MAC_SDK, .*/.*): \
error("QMAKE_MAC_SDK can only contain short-form SDK names (eg. macosx, iphoneos)")
-QMAKE_MAC_SDK_PATH = $$system("xcodebuild -sdk $$QMAKE_MAC_SDK -version Path 2>/dev/null")
+QMAKE_MAC_SDK_PATH = $$system("/usr/bin/xcodebuild -sdk $$QMAKE_MAC_SDK -version Path 2>/dev/null")
isEmpty(QMAKE_MAC_SDK_PATH): error("Could not resolve SDK path for \'$$QMAKE_MAC_SDK\'")
!equals(MAKEFILE_GENERATOR, XCODE) {
@@ -24,7 +24,9 @@ for(tool, $$list(QMAKE_CC QMAKE_CXX QMAKE_FIX_RPATH QMAKE_AR QMAKE_RANLIB QMAKE_
value = $$eval($$tool)
isEmpty(value): next()
- sysrooted = $$system("xcrun -sdk $$QMAKE_MAC_SDK -find $$first(value)")
+ sysrooted = $$system("/usr/bin/xcrun -sdk $$QMAKE_MAC_SDK -find $$first(value) 2>/dev/null")
+ isEmpty(sysrooted): next()
+
$$tool = $$sysrooted $$member(value, 1, -1)
}
@@ -40,6 +42,9 @@ isEmpty(QMAKE_MAC_PLATFORM_NAME): error("Could not resolve platform name for SDK
# FIXME: Get the version_min_flag out of the platform's 'Native Build System.xcspec'
version_identifier = $$replace(QMAKE_MAC_PLATFORM_NAME, iphonesimulator, ios-simulator)
+ # C++11 support may affect the deployment target
+ c++11: load(c++11)
+
ios:!host_build: \
deployment_target = $$QMAKE_IOS_DEPLOYMENT_TARGET
else: \