From 7dcf7e6f2593a2d2e3ee5768e27cdf17500c90c9 Mon Sep 17 00:00:00 2001 From: Harald Fernengel Date: Thu, 17 Dec 2009 11:23:19 +0100 Subject: Stop the configuration if the test compiler cannot be found. Author: Adrian Constantin Reviewed-by: Thiago Macieira --- configure | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/configure b/configure index 8d9d371..04f17bd 100755 --- a/configure +++ b/configure @@ -2922,6 +2922,10 @@ fi QMAKE_CONF_COMPILER=`getQMakeConf "$XQMAKESPEC" | grep "^QMAKE_CXX[^_A-Z0-9]" | sed "s,.* *= *\(.*\)$,\1," | tail -1` TEST_COMPILER="$CC" [ -z "$TEST_COMPILER" ] && TEST_COMPILER=$QMAKE_CONF_COMPILER +if [ -z "$TEST_COMPILER" ]; then + echo "ERROR: Cannot set the compiler for the configuration tests" + exit 1 +fi # auto-detect precompiled header support if [ "$CFG_PRECOMPILE" = "auto" ]; then -- cgit v0.12 From e2ed04bac3cd353711bfd50eba3232692b40ab99 Mon Sep 17 00:00:00 2001 From: Harald Fernengel Date: Thu, 17 Dec 2009 11:26:31 +0100 Subject: Configure support for multiple include levels in qmake.conf hierarchy. If a configuration file included in qmake.conf had an include statements of its own, the variables defined in the second level of included files were not parsed by getQMakeConf function from configure. Author: Adrian Constantin Reviewed-by: Thiago Macieira --- configure | 32 +++++++++++++++++++++++--------- 1 file changed, 23 insertions(+), 9 deletions(-) diff --git a/configure b/configure index 04f17bd..1b1799c 100755 --- a/configure +++ b/configure @@ -106,6 +106,28 @@ QMakeVar() echo "$2" "$eq" "$3" >> "$QMAKE_VARS_FILE" } +# Helper function for getQMakeConf. It parses include statements in +# qmake.conf and prints out the expanded file +getQMakeConf1() +{ + while read line; do case "$line" in + include*) + inc_file=`echo "$line" | sed -n -e "/^include.*(.*)/s/include.*(\(.*\)).*$/\1/p"` + current_dir=`dirname "$1"` + conf_file="$current_dir/$inc_file" + if [ ! -e "$conf_file" ]; then + echo "WARNING: Unable to find file $conf_file" >&2 + continue + fi + getQMakeConf1 "$conf_file" + ;; + *) + echo "$line" + ;; + esac; done < "$1" +} + + # relies on $QMAKESPEC being set correctly. parses include statements in # qmake.conf and prints out the expanded file getQMakeConf() @@ -114,15 +136,7 @@ getQMakeConf() if [ -n "$1" ]; then tmpSPEC="$1" fi - $AWK -v "QMAKESPEC=$tmpSPEC" ' -/^include\(.+\)$/{ - fname = QMAKESPEC "/" substr($0, 9, length($0) - 9) - while ((getline line < fname) > 0) - print line - close(fname) - next -} -{ print }' "$tmpSPEC/qmake.conf" + getQMakeConf1 "$tmpSPEC/qmake.conf" } # relies on $TEST_COMPILER being set correctly -- cgit v0.12 From 17977f5067ab75541029d7278776ea8ff999ee77 Mon Sep 17 00:00:00 2001 From: Friedemann Kleint Date: Thu, 17 Dec 2009 15:54:42 +0100 Subject: Designer: Fix compilation with -static on Mac OS X Avoid linking the solutions used by Designer twice (in the two Designer libraries). Just use the include paths in case of static linking. Reviewed-by: Carlos Duclos Task-number: QTBUG-6863 --- .../src/components/objectinspector/objectinspector.pri | 8 +++++++- .../designer/src/components/propertyeditor/propertyeditor.pri | 11 +++++++++-- 2 files changed, 16 insertions(+), 3 deletions(-) diff --git a/tools/designer/src/components/objectinspector/objectinspector.pri b/tools/designer/src/components/objectinspector/objectinspector.pri index 280a1dc..733c4b3 100644 --- a/tools/designer/src/components/objectinspector/objectinspector.pri +++ b/tools/designer/src/components/objectinspector/objectinspector.pri @@ -1,4 +1,10 @@ -include($$QT_SOURCE_TREE/tools/shared/findwidget/findwidget.pri) +# --- The Find widget is also linked into the designer_shared library. +# Avoid conflict when linking statically +contains(CONFIG, static) { + INCLUDEPATH *= $$QT_SOURCE_TREE/tools/shared/findwidget +} else { + include($$QT_SOURCE_TREE/tools/shared/findwidget/findwidget.pri) +} INCLUDEPATH += $$PWD diff --git a/tools/designer/src/components/propertyeditor/propertyeditor.pri b/tools/designer/src/components/propertyeditor/propertyeditor.pri index d3e44a5..a8ed37e 100644 --- a/tools/designer/src/components/propertyeditor/propertyeditor.pri +++ b/tools/designer/src/components/propertyeditor/propertyeditor.pri @@ -4,8 +4,15 @@ INCLUDEPATH += $$PWD -include($$QT_SOURCE_TREE/tools/shared/qtpropertybrowser/qtpropertybrowser.pri) -include($$QT_SOURCE_TREE/tools/shared/qtgradienteditor/qtcolorbutton.pri) +# --- Property browser is also linked into the designer_shared library. +# Avoid conflict when linking statically +contains(CONFIG, static) { + INCLUDEPATH *= $$QT_SOURCE_TREE/tools/shared/qtpropertybrowser + INCLUDEPATH *= $$QT_SOURCE_TREE/tools/shared/qtgradienteditor +} else { + include($$QT_SOURCE_TREE/tools/shared/qtpropertybrowser/qtpropertybrowser.pri) + include($$QT_SOURCE_TREE/tools/shared/qtgradienteditor/qtcolorbutton.pri) +} FORMS += $$PWD/paletteeditor.ui \ $$PWD/stringlisteditor.ui \ -- cgit v0.12