summaryrefslogtreecommitdiffstats
path: root/mkspecs/features/qt_functions.prf
diff options
context:
space:
mode:
authorJoerg Bornemann <joerg.bornemann@qt.io>2021-01-25 11:12:37 +0100
committerJoerg Bornemann <joerg.bornemann@qt.io>2021-02-23 17:02:30 +0100
commit1f30bcf33618ca39c47dc1058529b55635e30aef (patch)
treeab6f07d6c8afba7d0b9bcd06b17f2b307719d8bb /mkspecs/features/qt_functions.prf
parent700d1037aa38f71813826e5104533f357fc41e04 (diff)
Move build tools to libexec instead of the bin dir
[ChangeLog][Build System] Tools that are called by the build system and are unlikely to be called by the user are now installed to the libexec directory. This is a step towards easier co-installability of different Qt versions. Pick-to: 6.1 Task-number: QTBUG-88791 Change-Id: Id19575b5ba27795f7715e4ea6a09391b26dd4942 Reviewed-by: Kai Koehne <kai.koehne@qt.io>
Diffstat (limited to 'mkspecs/features/qt_functions.prf')
-rw-r--r--mkspecs/features/qt_functions.prf21
1 files changed, 19 insertions, 2 deletions
diff --git a/mkspecs/features/qt_functions.prf b/mkspecs/features/qt_functions.prf
index 7777e615bd..dd780ad556 100644
--- a/mkspecs/features/qt_functions.prf
+++ b/mkspecs/features/qt_functions.prf
@@ -83,11 +83,19 @@ defineTest(qtHaveModule) {
return(false)
}
-# variable, default, [suffix for variable for system() use], [prepare primary variable for system() use]
+# Arguments:
+# variable, default, [suffix for variable for system() use],
+# [prepare primary variable for system() use],
+# [installation location; default: $$[QT_HOST_BINS]]
defineTest(qtPrepareTool) {
cmd = $$eval(QT_TOOL.$${2}.binary)
isEmpty(cmd) {
- cmd = $$[QT_HOST_BINS]/$$2
+ isEmpty(5) {
+ instloc = $$[QT_HOST_BINS]
+ } else {
+ instloc = $$5
+ }
+ cmd = $$instloc/$$2
exists($${cmd}.pl) {
$${1}_EXE = $${cmd}.pl
cmd = perl -w $$system_path($${cmd}.pl)
@@ -123,6 +131,15 @@ defineTest(qtPrepareTool) {
}
}
+# Prepare a tool that's not supposed to be called manually by users but by the build system.
+#
+# Forwards its arguments to qtPrepareTool but defaults the installation location to
+# $$[QT_HOST_LIBEXECS]
+defineTest(qtPrepareLibExecTool) {
+ isEmpty(instloc): instloc = "$$[QT_HOST_LIBEXECS]"
+ qtPrepareTool($$1, $$2, $$3, $$4, $$instloc)
+}
+
# target variable, list of env var names, [non-empty: prepare for system(), not make]
defineTest(qtAddToolEnv) {
isEmpty(3): \