2011-04-27 10:05:43 +00:00
|
|
|
CONFIG = sdk rez $$CONFIG
|
|
|
|
load(default_pre)
|
|
|
|
|
2013-05-08 10:21:05 +00:00
|
|
|
isEmpty(QMAKE_XCODE_DEVELOPER_PATH) {
|
|
|
|
# Get path of Xcode's Developer directory
|
|
|
|
QMAKE_XCODE_DEVELOPER_PATH = $$system("/usr/bin/xcode-select --print-path 2>/dev/null")
|
|
|
|
isEmpty(QMAKE_XCODE_DEVELOPER_PATH): \
|
|
|
|
error("Xcode path is not set. Please use xcode-select to choose Xcode installation path.")
|
|
|
|
|
|
|
|
# Make sure Xcode path is valid
|
|
|
|
!exists($$QMAKE_XCODE_DEVELOPER_PATH): \
|
|
|
|
error("Xcode is not installed in $${QMAKE_XCODE_DEVELOPER_PATH}. Please use xcode-select to choose Xcode installation path.")
|
|
|
|
|
|
|
|
# Make sure Xcode is set up properly
|
|
|
|
isEmpty($$list($$system("/usr/bin/xcrun -find xcrun 2>/dev/null"))): \
|
|
|
|
error("Xcode not set up properly. You may need to confirm the license agreement by running /usr/bin/xcodebuild.")
|
|
|
|
}
|
|
|
|
|
|
|
|
isEmpty(QMAKE_XCODE_VERSION) {
|
|
|
|
# Extract Xcode version using xcodebuild
|
|
|
|
xcode_version = $$system("/usr/bin/xcodebuild -version")
|
|
|
|
QMAKE_XCODE_VERSION = $$member(xcode_version, 1)
|
|
|
|
isEmpty(QMAKE_XCODE_VERSION): error("Could not resolve Xcode version.")
|
|
|
|
unset(xcode_version)
|
|
|
|
}
|