summaryrefslogtreecommitdiffstats
path: root/mkspecs/features/qt_functions.prf
diff options
context:
space:
mode:
authorOswald Buddenhagen <oswald.buddenhagen@nokia.com>2010-05-14 11:42:28 (GMT)
committerOswald Buddenhagen <oswald.buddenhagen@nokia.com>2010-05-14 11:45:36 (GMT)
commit6d4e67674f0ca5824761ec29f20dd854d47b4ac7 (patch)
treefbb52216e460580def7545bdd0525f1ad16c6abb /mkspecs/features/qt_functions.prf
parent3ecb04cffdf491f5ea01eceb71de98d6ac647107 (diff)
downloadQt-6d4e67674f0ca5824761ec29f20dd854d47b4ac7.zip
Qt-6d4e67674f0ca5824761ec29f20dd854d47b4ac7.tar.gz
Qt-6d4e67674f0ca5824761ec29f20dd854d47b4ac7.tar.bz2
define qtPrepareTool() function and use it throughout
the function provides a cross-platform way to determine the exact pathname of our build tools (moc, etc.). use it in our .prf files, so we don't have to rely on qmake's unreliable path separator normalization magic in extra compiler commands, which broke on mingw+sh in silent mode. remove the bootstrap tool path setting from configure, as it is redundant now. Reviewed-by: joerg Task-number: QTBUG-10633
Diffstat (limited to 'mkspecs/features/qt_functions.prf')
-rw-r--r--mkspecs/features/qt_functions.prf11
1 files changed, 11 insertions, 0 deletions
diff --git a/mkspecs/features/qt_functions.prf b/mkspecs/features/qt_functions.prf
index 1be6d9b..23e2616 100644
--- a/mkspecs/features/qt_functions.prf
+++ b/mkspecs/features/qt_functions.prf
@@ -78,3 +78,14 @@ defineTest(qtAddLibrary) {
export(QMAKE_LFLAGS)
return(true)
}
+
+# variable, default
+defineTest(qtPrepareTool) {
+ isEmpty($$1) {
+ !isEmpty(QT_BUILD_TREE):$$1 = $$QT_BUILD_TREE/bin/$$2
+ else:$$1 = $$[QT_INSTALL_BINS]/$$2
+ }
+ $$1 ~= s,[/\\\\],$$QMAKE_DIR_SEP,
+ contains(QMAKE_HOST.os, Windows):!contains($$1, \.exe$):$$1 = $$eval($$1).exe
+ export($$1)
+}