summaryrefslogtreecommitdiffstats
path: root/configure
diff options
context:
space:
mode:
authorMark Brand <mabrand@mabrand.nl>2012-09-14 10:03:18 +0200
committerQt by Nokia <qt-info@nokia.com>2012-09-17 21:47:51 +0200
commit01864d4854557d2cf8b067e229d77cd7c9c553ee (patch)
tree47c4970a6b79d17ff75a79fb6ff82657b16ed602 /configure
parentf0b922a3af47e984e4a5935e65c4243966d8dc9d (diff)
use qmake to get PKG_CONFIG in configure script
The value of PKG_CONFIG might depend on device options. For example, "-device-option PKG_CONFIG" might be used with configure or a mkspec might prefix PKG_CONFIG with CROSS_COMPILE which is specified as a device option. The shell functions of configure for parsing mkspecs do not take device options into account, but qmake is pretty good at it now. Change-Id: I1c9558e550c48e8441ebdac34b82066473c2ce3a Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure24
1 files changed, 12 insertions, 12 deletions
diff --git a/configure b/configure
index a556b86be8..55b60b7d18 100755
--- a/configure
+++ b/configure
@@ -3682,11 +3682,22 @@ Prefix=..
EOF
#-------------------------------------------------------------------------------
+# write out device config before we run the test.
+#-------------------------------------------------------------------------------
+DEVICE_VARS_OUTFILE="$outpath/mkspecs/qdevice.pri"
+if cmp -s "$DEVICE_VARS_FILE" "$DEVICE_VARS_OUTFILE"; then
+ rm -f "$DEVICE_VARS_FILE"
+else
+ mv -f $DEVICE_VARS_FILE "$DEVICE_VARS_OUTFILE"
+ DEVICE_VARS_FILE="$DEVICE_VARS_OUTFILE"
+fi
+
+#-------------------------------------------------------------------------------
# Detect pkg-config
#-------------------------------------------------------------------------------
if [ -z "$PKG_CONFIG" ]; then
# See if PKG_CONFIG is set in the mkspec:
- PKG_CONFIG=`getXQMakeConf PKG_CONFIG`
+ PKG_CONFIG="`"$outpath/bin/qmake" -E -nocache -spec "$XQMAKESPEC" /dev/null 2>&1 | sed -n -e 's,^PKG_CONFIG = \(.*\),\1,p'`"
fi
if [ -z "$PKG_CONFIG" ]; then
PKG_CONFIG=`"$WHICH" pkg-config 2>/dev/null`
@@ -3749,17 +3760,6 @@ if [ -z "$PKG_CONFIG" ]; then
fi
#-------------------------------------------------------------------------------
-# write out device config before we run the test.
-#-------------------------------------------------------------------------------
-DEVICE_VARS_OUTFILE="$outpath/mkspecs/qdevice.pri"
-if cmp -s "$DEVICE_VARS_FILE" "$DEVICE_VARS_OUTFILE"; then
- rm -f "$DEVICE_VARS_FILE"
-else
- mv -f $DEVICE_VARS_FILE "$DEVICE_VARS_OUTFILE"
- DEVICE_VARS_FILE="$DEVICE_VARS_OUTFILE"
-fi
-
-#-------------------------------------------------------------------------------
# tests that need qmake
#-------------------------------------------------------------------------------