Add cross_compile to qconfig.pri for global advertising

.qmake.cache is not necessarily accessible to other modules which depend on
information about whether we are cross compiling or not. We might as well
advertise this fact globally via the CONFIG variable in qconfig.pri.

Change-Id: I6dee3e6604e5ca1c775c5f9f834fe29b4e27adb8
Reviewed-by: Donald Carr <donald.carr@nokia.com>
Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Reviewed-by: Johannes Zellner <johannes.zellner@nokia.com>
This commit is contained in:
Donald Carr 2012-02-29 23:55:13 +00:00 committed by Qt by Nokia
parent 6a5e2fdde3
commit 3c47b52bd3
2 changed files with 6 additions and 1 deletions

1
configure vendored
View File

@ -2528,6 +2528,7 @@ fi
if [ "$PLATFORM" != "$XPLATFORM" ]; then
QT_CROSS_COMPILE=yes
QMAKE_CONFIG="$QMAKE_CONFIG cross_compile"
QTCONFIG_CONFIG="$QTCONFIG_CONFIG cross_compile"
fi
if [ "$BUILD_ON_MAC" = "yes" ]; then

View File

@ -2367,8 +2367,10 @@ void Configure::generateOutputVars()
}
}
if (dictionary.contains("XQMAKESPEC") && (dictionary["QMAKESPEC"] != dictionary["XQMAKESPEC"]))
if (dictionary.contains("XQMAKESPEC") && (dictionary["QMAKESPEC"] != dictionary["XQMAKESPEC"])) {
qmakeConfig += "cross_compile";
dictionary["CROSS_COMPILE"] = "yes";
}
// Directories and settings for .qmake.cache --------------------
@ -2605,6 +2607,8 @@ void Configure::generateCachefile()
configStream << " no_plugin_manifest";
if (dictionary["QPA"] == "yes")
configStream << " qpa";
if (dictionary["CROSS_COMPILE"] == "yes")
configStream << " cross_compile";
if (dictionary["DIRECTWRITE"] == "yes")
configStream << "directwrite";