summaryrefslogtreecommitdiffstats
path: root/configure
diff options
context:
space:
mode:
authorTor Arne Vestbø <tor.arne.vestbo@digia.com>2013-10-15 16:19:26 +0200
committerThe Qt Project <gerrit-noreply@qt-project.org>2013-10-30 13:09:47 +0100
commite7bda8ee1084e24710e91a32b5ff1434a368cf4e (patch)
tree117f51d86c612c44816d05e7043ea41694d08014 /configure
parent3655d71719a4746938f364bfe0d82c1609c3eacb (diff)
iOS: Build libs (including Qt itself) for both simulator and device
Conceptually a Qt for iOS SDK or source build should support building for both simulator and device, based on the same qmake binary and Qt libraries. Qt Creator or Xcode should then be able to use the same Qt version while still building for a single target at a time. This applies to user libraries as well, which shouldn't require switching to a different Qt when changing target platform from simulator to device. We achieve this by using Qt's exclusive_build feature, where we build for the two targets in parallel, and then teach Xcode how to choose the right library dynamically at build time. Change-Id: I06d60e120d986085fb8686ced98f22f7047c4f23 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com> Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@digia.com>
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure9
1 files changed, 9 insertions, 0 deletions
diff --git a/configure b/configure
index 36f3bb522f..d74d811546 100755
--- a/configure
+++ b/configure
@@ -999,6 +999,7 @@ QPA_PLATFORM_GUARD=yes
CFG_CXX11=auto
CFG_DIRECTWRITE=no
CFG_WERROR=auto
+OPT_MAC_SDK=
# initalize variables used for installation
QT_INSTALL_PREFIX=
@@ -1482,6 +1483,7 @@ while [ "$#" -gt 0 ]; do
sdk)
if [ "$BUILD_ON_MAC" = "yes" ]; then
DeviceVar set !host_build:QMAKE_MAC_SDK "$VAL"
+ OPT_MAC_SDK="$VAL"
else
UNKNOWN_OPT=yes
fi
@@ -2871,6 +2873,13 @@ if [ "$XPLATFORM_IOS" = "yes" ]; then
CFG_SHARED="no" # iOS builds should be static to be able to submit to the App Store
CFG_CXX11="no" # C++11 support disabled for now
CFG_SKIP_MODULES="$CFG_SKIP_MODULES qtconnectivity qtdoc qtgraphicaleffects qtlocation qtmacextras qtmultimedia qtquickcontrols qtserialport qttools qtwebkit qtwebkit-examples"
+
+ # If the user passes -sdk on the command line we build a SDK-specific Qt build.
+ # Otherwise we build a joined simulator and device build, which is the default.
+ if [ -z "$OPT_MAC_SDK" ]; then
+ QT_CONFIG="$QT_CONFIG build_all"
+ QTCONFIG_CONFIG="$QTCONFIG_CONFIG iphonesimulator_and_iphoneos"
+ fi
fi
# disable GTK style support auto-detection on Mac