summaryrefslogtreecommitdiffstats
path: root/configure
diff options
context:
space:
mode:
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure43
1 files changed, 39 insertions, 4 deletions
diff --git a/configure b/configure
index 269d88c..b582d85 100755
--- a/configure
+++ b/configure
@@ -119,7 +119,13 @@ elif [ -f "$relpath"/src/gui/kernel/qapplication_qws.cpp ]; then
# ~ src/gui/base/qapplication_qws.cpp is present
# ~ this is the free or commercial edition
# ~ this is the internal edition and Qt Embedded is explicitly enabled
- PLATFORM_QWS=maybe
+ if [ -f "$relpath"/src/gui/kernel/qapplication_mac.mm ]; then
+ # This is a depot build, or an all-platforms package
+ PLATFORM_QWS=maybe
+ else
+ # This must be the embedded package, since the Qt/Mac source files are not present
+ PLATFORM_QWS=yes
+ fi
fi
#-----------------------------------------------------------------------------
@@ -199,10 +205,10 @@ earlyArgParse()
h|help|--help|-help)
if [ "$VAL" = "yes" ]; then
OPT_HELP="$VAL"
- COMMERCIAL_USER="yes" #doesn't matter we will display the help
+ COMMERCIAL_USER="no" #doesn't matter we will display the help
else
UNKNOWN_OPT=yes
- COMMERCIAL_USER="yes" #doesn't matter we will display the help
+ COMMERCIAL_USER="no" #doesn't matter we will display the help
fi
;;
--*)
@@ -2692,6 +2698,21 @@ if [ "$QT_CROSS_COMPILE" = "yes" ]; then
fi
fi
+# check -arch arguments for validity.
+if [ "$PLATFORM_MAC" = "yes" ]; then
+ ALLOWED="x86 ppc x86_64 ppc64 i386"
+ for i in $CFG_MAC_ARCHS
+ do
+ if echo "$ALLOWED" | grep -w -v "$i" > /dev/null 2>&1; then
+ echo "Unknown architecture: \"$i\". Supported architectures: x86[i386] ppc x86_64 ppc64";
+ exit 2;
+ fi
+ done
+
+# replace "i386" with "x86" to support configuring with -arch i386 as an alias for x86.
+ CFG_MAC_ARCHS="${CFG_MAC_ARCHS/i386/x86}"
+fi
+
# find the default framework value
if [ "$PLATFORM_MAC" = "yes" ] && [ "$PLATFORM" != "macx-xlc" ]; then
if [ "$CFG_FRAMEWORK" = "auto" ]; then
@@ -3952,7 +3973,7 @@ if [ -n "$PERL" ] && [ -x "$relpath/bin/syncqt" ]; then
[ "$CFG_DEV" = "yes" ] && SYNCQT_OPTS="$SYNCQT_OPTS -check-includes"
if [ "$OPT_SHADOW" = "yes" ]; then
"$outpath/bin/syncqt" $SYNCQT_OPTS
- elif [ "$CFG_DEV" = "yes" ]; then
+ elif [ "$CFG_DEV" = "yes" ] || [ ! -d $relpath/include ]; then
QTDIR="$relpath" perl "$outpath/bin/syncqt" $SYNCQT_OPTS
fi
fi
@@ -4715,6 +4736,14 @@ if [ "$PLATFORM_X11" = "yes" ]; then
X11TESTS_FLAGS="$X11TESTS_FLAGS -fpermissive"
fi
+ # Check we actually have X11 :-)
+ if ! "$unixtests/compile.test" "$XQMAKESPEC" "$QMAKE_CONFIG" $OPT_VERBOSE "$relpath" "$outpath" config.tests/x11/xlib "XLib" $L_FLAGS $I_FLAGS $l_FLAGS $X11TESTS_FLAGS; then
+ echo "Basic XLib functionality test failed!"
+ echo " You might need to modify the include and library search paths by editing"
+ echo " QMAKE_INCDIR_X11 and QMAKE_LIBDIR_X11 in ${XQMAKESPEC}."
+ exit 1
+ fi
+
# auto-detect OpenGL support (es1 = OpenGL ES 1.x Common, es1cl = ES 1.x common lite, es2 = OpenGL ES 2.x)
if [ "$CFG_OPENGL" = "auto" ] || [ "$CFG_OPENGL" = "yes" ]; then
if "$unixtests/compile.test" "$XQMAKESPEC" "$QMAKE_CONFIG" $OPT_VERBOSE "$relpath" "$outpath" config.tests/x11/opengl "OpenGL" $L_FLAGS $I_FLAGS $l_FLAGS $X11TESTS_FLAGS; then
@@ -6165,6 +6194,9 @@ TARGET_OPERATING_SYSTEM=`echo $XPLATFORM | cut -f 2- -d/ | cut -f -1 -d-`
# when cross-compiling, don't include build-host information (build key is target specific)
QT_BUILD_KEY="$CFG_USER_BUILD_KEY $CFG_ARCH $TARGET_OPERATING_SYSTEM $COMPILER $BUILD_OPTIONS"
+if [ -n "$QT_NAMESPACE" ]; then
+ QT_BUILD_KEY="$QT_BUILD_KEY $QT_NAMESPACE"
+fi
MAC_NEED_TWO_BUILD_KEYS="no"
if [ "$PLATFORM_MAC" = "yes" -a "$CFG_MAC_COCOA" = "yes" ]; then
QT_BUILD_KEY_CARBON=$QT_BUILD_KEY
@@ -6181,6 +6213,9 @@ QT_BUILD_KEY_COMPAT=
if [ "$QT_CROSS_COMPILE" = "no" ]; then
# previous versions of Qt used a build key built from the uname
QT_BUILD_KEY_COMPAT="$CFG_USER_BUILD_KEY $UNAME_MACHINE $UNAME_SYSTEM $COMPILER $BUILD_OPTIONS"
+ if [ -n "$QT_NAMESPACE" ]; then
+ QT_BUILD_KEY_COMPAT="$QT_BUILD_KEY_COMPAT $QT_NAMESPACE"
+ fi
fi
# strip out leading/trailing/extra whitespace
QT_BUILD_KEY=`echo $QT_BUILD_KEY | sed -e "s, *, ,g" -e "s,^ *,," -e "s, *$,,"`