summaryrefslogtreecommitdiffstats
path: root/configure
diff options
context:
space:
mode:
authorFrederik Gladhorn <frederik.gladhorn@digia.com>2014-01-21 17:57:54 +0100
committerThe Qt Project <gerrit-noreply@qt-project.org>2014-01-21 17:57:54 +0100
commit46791c08e17740418cc701b8862a980c0f711b87 (patch)
treebedba63fc48b80c2a2df54ea91c3f35398953aac /configure
parentb8a38a6737acd670d92197ca5b009590d9fd8a9c (diff)
parent9033977d3971db5352a2bb51052a723a2ac57a8f (diff)
Merge "Merge remote-tracking branch 'origin/stable' into dev" into refs/staging/dev
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure134
1 files changed, 67 insertions, 67 deletions
diff --git a/configure b/configure
index f745c122f5..0d746acf0d 100755
--- a/configure
+++ b/configure
@@ -95,7 +95,7 @@ if [ x"$1" = x"-top-level" ]; then
fi
# later cache the command line in config.status
-OPT_CMDLINE=`echo $@ | sed "s,-v ,,g; s,-v$,,g"`
+OPT_CMDLINE=`echo $@ | sed 's,-v ,,g; s,-v$,,g'`
# initialize global variables
QMAKE_SWITCHES=
@@ -170,7 +170,7 @@ expandQMakeConf()
{
while read line; do case "$line" in
include*)
- inc_file=`echo "$line" | sed -n -e "/^include.*(.*)/s/include.*(\(.*\)).*$/\1/p"`
+ inc_file=`echo "$line" | sed -n -e '/^include.*(.*)/s/include.*(\(.*\)).*$/\1/p'`
current_dir=`dirname "$1"`
conf_file="$current_dir/$inc_file"
if [ ! -f "$conf_file" ]; then
@@ -450,7 +450,7 @@ resolveDeviceMkspec()
match_count=$(echo "$result" | wc -w)
if [ "$match_count" -gt 1 ]; then
echo >&2 "Error: Multiple matches for device '$1'. Candidates are:"
- tabbed_result=$(echo "$result" | sed "s,^, ,")
+ tabbed_result=$(echo "$result" | sed 's,^, ,')
echo >&2 "$tabbed_result"
echo "undefined"
elif [ "$match_count" -eq 0 ]; then
@@ -830,33 +830,33 @@ while [ "$#" -gt 0 ]; do
case "$1" in
#Autoconf style options
--enable-*)
- VAR=`echo $1 | sed "s,^--enable-\(.*\),\1,"`
+ VAR=`echo $1 | sed 's,^--enable-\(.*\),\1,'`
VAL=yes
;;
--disable-*)
- VAR=`echo $1 | sed "s,^--disable-\(.*\),\1,"`
+ VAR=`echo $1 | sed 's,^--disable-\(.*\),\1,'`
VAL=no
;;
--*=*)
- VAR=`echo $1 | sed "s,^--\(.*\)=.*,\1,"`
- VAL=`echo $1 | sed "s,^--.*=\(.*\),\1,"`
+ VAR=`echo $1 | sed 's,^--\(.*\)=.*,\1,'`
+ VAL=`echo $1 | sed 's,^--.*=\(.*\),\1,'`
;;
--no-*)
- VAR=`echo $1 | sed "s,^--no-\(.*\),\1,"`
+ VAR=`echo $1 | sed 's,^--no-\(.*\),\1,'`
VAL=no
;;
--*)
- VAR=`echo $1 | sed "s,^--\(.*\),\1,"`
+ VAR=`echo $1 | sed 's,^--\(.*\),\1,'`
VAL=yes
;;
#Qt plugin options
-no-*-*|-plugin-*-*|-qt-*-*)
- VAR=`echo $1 | sed "s,^-[^-]*-\(.*\),\1,"`
- VAL=`echo $1 | sed "s,^-\([^-]*\).*,\1,"`
+ VAR=`echo $1 | sed 's,^-[^-]*-\(.*\),\1,'`
+ VAL=`echo $1 | sed 's,^-\([^-]*\).*,\1,'`
;;
#Qt style no options
-no-*)
- VAR=`echo $1 | sed "s,^-no-\(.*\),\1,"`
+ VAR=`echo $1 | sed 's,^-no-\(.*\),\1,'`
VAL=no
;;
#Qt style options that pass an argument
@@ -901,14 +901,14 @@ while [ "$#" -gt 0 ]; do
-android-ndk-host| \
-android-arch| \
-android-toolchain-version)
- VAR=`echo $1 | sed "s,^-\(.*\),\1,"`
+ VAR=`echo $1 | sed 's,^-\(.*\),\1,'`
shift
VAL="$1"
;;
#Qt style complex options in one command
-enable-*|-disable-*)
- VAR=`echo $1 | sed "s,^-\([^-]*\)-.*,\1,"`
- VAL=`echo $1 | sed "s,^-[^-]*-\(.*\),\1,"`
+ VAR=`echo $1 | sed 's,^-\([^-]*\)-.*,\1,'`
+ VAL=`echo $1 | sed 's,^-[^-]*-\(.*\),\1,'`
;;
-system-proxies)
VAR=system-proxies
@@ -920,8 +920,8 @@ while [ "$#" -gt 0 ]; do
;;
#Qt Builtin/System style options
-no-*|-system-*|-qt-*)
- VAR=`echo $1 | sed "s,^-[^-]*-\(.*\),\1,"`
- VAL=`echo $1 | sed "s,^-\([^-]*\)-.*,\1,"`
+ VAR=`echo $1 | sed 's,^-[^-]*-\(.*\),\1,'`
+ VAL=`echo $1 | sed 's,^-\([^-]*\)-.*,\1,'`
;;
#Options that cannot be generalized
-k|-continue)
@@ -949,7 +949,7 @@ while [ "$#" -gt 0 ]; do
fi
;;
-hostprefix)
- VAR=`echo $1 | sed "s,^-\(.*\),\1,"`
+ VAR=`echo $1 | sed 's,^-\(.*\),\1,'`
# this option may or may not be followed by an argument
if [ -z "$2" ] || echo "$2" | grep '^-' >/dev/null 2>&1; then
VAL=$outpath
@@ -1039,7 +1039,7 @@ while [ "$#" -gt 0 ]; do
;;
#General options, including Qt style yes options
-*)
- VAR=`echo $1 | sed "s,^-\(.*\),\1,"`
+ VAR=`echo $1 | sed 's,^-\(.*\),\1,'`
VAL="yes"
;;
*)
@@ -1397,7 +1397,7 @@ while [ "$#" -gt 0 ]; do
fi
;;
feature-*)
- FEATURE=`echo $VAR | sed "s,^[^-]*-\([^-]*\),\1," | tr 'abcdefghijklmnopqrstuvwxyz-' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
+ FEATURE=`echo $VAR | sed 's,^[^-]*-\([^-]*\),\1,' | tr 'abcdefghijklmnopqrstuvwxyz-' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
if [ "$VAL" = "no" ]; then
QCONFIG_FLAGS="$QCONFIG_FLAGS QT_NO_$FEATURE"
elif [ "$VAL" = "yes" ] || [ "$VAL" = "unknown" ]; then
@@ -1916,8 +1916,8 @@ while [ "$#" -gt 0 ]; do
fi
# now $VAL is "no", "qt", or "plugin"
OPT="$VAL"
- VAL=`echo $VAR | sed "s,^[^-]*-\([^-]*\).*,\1,"`
- VAR=`echo $VAR | sed "s,^\([^-]*\).*,\1,"`
+ VAL=`echo $VAR | sed 's,^[^-]*-\([^-]*\).*,\1,'`
+ VAR=`echo $VAR | sed 's,^\([^-]*\).*,\1,'`
# Grab the available values
case "$VAR" in
@@ -1983,7 +1983,7 @@ while [ "$#" -gt 0 ]; do
fi
elif [ "$VAL" = "no" ]; then
if [ "$OPT_VERBOSE" = "$VAL" ] && echo "$QMAKE_SWITCHES" | grep ' -d' >/dev/null 2>&1; then
- QMAKE_SWITCHES=`echo $QMAKE_SWITCHES | sed "s, -d,,"`
+ QMAKE_SWITCHES=`echo $QMAKE_SWITCHES | sed 's, -d,,'`
else
OPT_VERBOSE=no
fi
@@ -3058,7 +3058,7 @@ elif [ "$Edition" = "Preview" ]; then
done
elif [ "$Edition" != "OpenSource" ]; then
if [ -n "$ExpiryDate" ]; then
- ExpiryDate=`echo $ExpiryDate | sed -e "s,-,,g" | tr -d "\n\r"`
+ ExpiryDate=`echo $ExpiryDate | sed -e 's,-,,g' | tr -d '\n\r'`
[ -z "$ExpiryDate" ] && ExpiryDate="0"
Today=`date +%Y%m%d`
if [ "$Today" -gt "$ExpiryDate" ]; then
@@ -3521,7 +3521,7 @@ function normalize(dir)
{
do {
odir = dir
- gsub(/\/[^\/]+\/\.\./, "", dir)
+ sub(/\/[^\/]+\/\.\./, "", dir)
} while (dir != odir);
do {
odir = dir
@@ -3577,7 +3577,7 @@ if [ -z "$CFG_BUILD_PARTS" ]; then
# don't build tools by default when cross-compiling
if [ "$PLATFORM" != "$XPLATFORM" ]; then
- CFG_BUILD_PARTS=`echo "$CFG_BUILD_PARTS" | sed "s, tools,,g"`
+ CFG_BUILD_PARTS=`echo "$CFG_BUILD_PARTS" | sed 's, tools,,g'`
fi
fi
for nobuild in $CFG_NOBUILD_PARTS; do
@@ -4028,7 +4028,7 @@ if true; then ###[ '!' -f "$outpath/bin/qmake" ];
if "$WHICH" makedepend >/dev/null 2>&1 && grep 'depend:' "$mkfile" >/dev/null 2>&1; then
(cd "$outpath/qmake" && "$MAKE" -f "$mkfile" depend) >/dev/null 2>&1
- sed "s,^.*/\([^/]*.o\):,\1:,g" "$mkfile" >"$mkfile.tmp"
+ sed 's,^.*/\([^/]*.o\):,\1:,g' "$mkfile" >"$mkfile.tmp"
sed "s,$outpath,$adjoutpath,g" "$mkfile.tmp" >"$mkfile"
rm "$mkfile.tmp"
fi
@@ -4166,7 +4166,7 @@ compileTest()
# Use config.tests/arch/arch.pro to have the compiler tell us what the target architecture is
OUTFILE=$outpath/arch.result
-"$unixtests/arch.test" "$XQMAKESPEC" $OPT_VERBOSE "$relpath" "$outpath" "$OUTFILE" "target"
+"$unixtests/arch.test" "$XQMAKESPEC" $OPT_VERBOSE "$relpath" "$outpath" "$OUTFILE" "target" $I_FLAGS $D_FLAGS $L_FLAGS
if [ $? -eq 0 ]; then
eval `cat "$OUTFILE"`
else
@@ -4179,7 +4179,7 @@ rm -f "$OUTFILE" 2>/dev/null
if [ "$QMAKESPEC" != "$XQMAKESPEC" ]; then
# Do the same test again, using the host compiler
- SYSROOT_FLAG= "$unixtests/arch.test" "$QMAKESPEC" $OPT_VERBOSE "$relpath" "$outpath" "$OUTFILE" "host"
+ SYSROOT_FLAG= "$unixtests/arch.test" "$QMAKESPEC" $OPT_VERBOSE "$relpath" "$outpath" "$OUTFILE" "host" $I_FLAGS $D_FLAGS $L_FLAGS
if [ $? -eq 0 ]; then
eval `cat "$OUTFILE"`
else
@@ -5146,6 +5146,42 @@ if compileTest x11/xlib "XLib"; then
QT_CONFIG="$QT_CONFIG xlib"
fi
+# auto-detect Xrender support
+if [ "$CFG_XRENDER" != "no" ]; then
+ if compileTest x11/xrender "Xrender"; then
+ CFG_XRENDER=yes
+ QT_CONFIG="$QT_CONFIG xrender"
+ else
+ if [ "$CFG_XRENDER" = "yes" ] && [ "$CFG_CONFIGURE_EXIT_ON_ERROR" = "yes" ]; then
+ echo "Xrender support cannot be enabled due to functionality tests!"
+ echo " Turn on verbose messaging (-v) to $0 to see the final report."
+ echo " If you believe this message is in error you may use the continue"
+ echo " switch (-continue) to $0 to continue."
+ exit 101
+ else
+ CFG_XRENDER=no
+ fi
+ fi
+fi
+
+# auto-detect XInput2 support
+if [ "$CFG_XINPUT2" != "no" ]; then
+ if compileTest x11/xinput2 "XInput2"; then
+ CFG_XINPUT2=yes
+ CFG_XINPUT=no
+ else
+ if [ "$CFG_XINPUT2" = "yes" ] && [ "$CFG_CONFIGURE_EXIT_ON_ERROR" = "yes" ]; then
+ echo "XInput2 support cannot be enabled due to functionality tests!"
+ echo " Turn on verbose messaging (-v) to $0 to see the final report."
+ echo " If you believe this message is in error you may use the continue"
+ echo " switch (-continue) to $0 to continue."
+ exit 101
+ else
+ CFG_XINPUT2=no
+ fi
+ fi
+fi
+
if [ "$CFG_XCB" != "no" ]; then
if [ -n "$PKG_CONFIG" ] && $PKG_CONFIG --exists "xcb >= 1.5" 2>/dev/null; then
QMAKE_CFLAGS_XCB="`$PKG_CONFIG --cflags xcb 2>/dev/null`"
@@ -5213,42 +5249,6 @@ if [ "$CFG_XCB" != "no" ]; then
QT_CONFIG="$QT_CONFIG xcb-sm"
fi
fi
-
- # auto-detect Xrender support
- if [ "$CFG_XRENDER" != "no" ]; then
- if compileTest x11/xrender "Xrender"; then
- CFG_XRENDER=yes
- QT_CONFIG="$QT_CONFIG xrender"
- else
- if [ "$CFG_XRENDER" = "yes" ] && [ "$CFG_CONFIGURE_EXIT_ON_ERROR" = "yes" ]; then
- echo "Xrender support cannot be enabled due to functionality tests!"
- echo " Turn on verbose messaging (-v) to $0 to see the final report."
- echo " If you believe this message is in error you may use the continue"
- echo " switch (-continue) to $0 to continue."
- exit 101
- else
- CFG_XRENDER=no
- fi
- fi
- fi
-
- # auto-detect XInput2 support. Needed by xcb too.
- if [ "$CFG_XINPUT2" != "no" ]; then
- if compileTest x11/xinput2 "XInput2"; then
- CFG_XINPUT2=yes
- CFG_XINPUT=no
- else
- if [ "$CFG_XINPUT2" = "yes" ] && [ "$CFG_CONFIGURE_EXIT_ON_ERROR" = "yes" ]; then
- echo "XInput2 support cannot be enabled due to functionality tests!"
- echo " Turn on verbose messaging (-v) to $0 to see the final report."
- echo " If you believe this message is in error you may use the continue"
- echo " switch (-continue) to $0 to continue."
- exit 101
- else
- CFG_XINPUT2=no
- fi
- fi
- fi
else
if [ "$CFG_XCB" != "auto" ]; then
echo "The test for linking against libxcb failed!"
@@ -6355,10 +6355,10 @@ EOF
cfgdNeg=
if [ true ] && echo "$cfgd" | grep 'QT_NO_' >/dev/null 2>&1; then
# QT_NO_option can be forcefully turned on by QT_option
- cfgdNeg=`echo $cfgd | sed "s,QT_NO_,QT_,"`
+ cfgdNeg=`echo $cfgd | sed 's,QT_NO_,QT_,'`
elif [ true ] && echo "$cfgd" | grep 'QT_' >/dev/null 2>&1; then
# QT_option can be forcefully turned off by QT_NO_option
- cfgdNeg=`echo $cfgd | sed "s,QT_,QT_NO_,"`
+ cfgdNeg=`echo $cfgd | sed 's,QT_,QT_NO_,'`
fi
if [ -z $cfgdNeg ]; then