summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMorten Sørvig <msorvig@trolltech.com>2009-03-30 12:42:48 (GMT)
committerMorten Sørvig <msorvig@trolltech.com>2009-03-30 12:48:17 (GMT)
commitf0c21f86cdc9341b7dda2b4b2bca085954a79ef8 (patch)
tree0280551c1cb2dbd89b86d461d8a056a4584fa957
parent2bc824dde1033ae01f618a3ff534ba26d7a628af (diff)
downloadQt-f0c21f86cdc9341b7dda2b4b2bca085954a79ef8.zip
Qt-f0c21f86cdc9341b7dda2b4b2bca085954a79ef8.tar.gz
Qt-f0c21f86cdc9341b7dda2b4b2bca085954a79ef8.tar.bz2
Mac: check for valid -arch arguments in configure.
Allow x86 x86_64 ppc ppc64, exit with an error message if something else is passed? Reviewed-by: nrc
-rwxr-xr-xconfigure12
1 files changed, 12 insertions, 0 deletions
diff --git a/configure b/configure
index 269d88c..f0b7f90 100755
--- a/configure
+++ b/configure
@@ -2692,6 +2692,18 @@ if [ "$QT_CROSS_COMPILE" = "yes" ]; then
fi
fi
+# check -arch arguments for validity.
+if [ "$PLATFORM_MAC" = "yes" ]; then
+ ALLOWED="x86 ppc x86_64 ppc64"
+ for i in $CFG_MAC_ARCHS
+ do
+ if echo "$ALLOWED" | grep -w -v "$i" > /dev/null 2>&1; then
+ echo "Unknown architecture: \"$i\". Supported architechtures: x86 ppc x86_64 ppc64";
+ exit 2;
+ fi
+ done
+fi
+
# find the default framework value
if [ "$PLATFORM_MAC" = "yes" ] && [ "$PLATFORM" != "macx-xlc" ]; then
if [ "$CFG_FRAMEWORK" = "auto" ]; then