diff options
author | Joerg Bornemann <joerg.bornemann@qt.io> | 2020-06-18 10:07:22 +0200 |
---|---|---|
committer | Joerg Bornemann <joerg.bornemann@qt.io> | 2020-06-29 12:47:34 +0200 |
commit | d7fd6848612760124871f0f3b55917250d078dd5 (patch) | |
tree | 49f97ad5f16f5fd32cf69a5497c20581bf65b592 /bin | |
parent | b0f9c06a9b199a7474eb94a6292b5824364344b6 (diff) | |
download | qtbase-d7fd6848612760124871f0f3b55917250d078dd5.tar.gz |
CMake: Support cross-compilation with qmake
When cross-compiling, we now create a target_qt.conf file that's to be
used with the host Qt's qmake. With "qmake -qtconf .../target_qt.conf"
projects can be cross-built against the cross-built Qt.
We also create wrapper scripts for the host qmake to save the user from
passing the -qtconf argument.
Fixes: QTBUG-82581
Change-Id: Ib5866e7e820369efea9eb3171e3e3e3ca5c0c3c1
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
Diffstat (limited to 'bin')
-rw-r--r-- | bin/qmake-wrapper-for-target.bat.in | 2 | ||||
-rw-r--r-- | bin/qmake-wrapper-for-target.in | 7 |
2 files changed, 9 insertions, 0 deletions
diff --git a/bin/qmake-wrapper-for-target.bat.in b/bin/qmake-wrapper-for-target.bat.in new file mode 100644 index 0000000000..cce775a768 --- /dev/null +++ b/bin/qmake-wrapper-for-target.bat.in @@ -0,0 +1,2 @@ +@echo off +@host_qt_bindir@\qmake.exe %* -qtconf "%~dp0\target_qt.conf" diff --git a/bin/qmake-wrapper-for-target.in b/bin/qmake-wrapper-for-target.in new file mode 100644 index 0000000000..0c81b7c62f --- /dev/null +++ b/bin/qmake-wrapper-for-target.in @@ -0,0 +1,7 @@ +#!/bin/sh + +# The directory of this script is the expanded absolute path of the "$qt_prefix/bin" directory. +script_dir_path=`dirname $0` +script_dir_path=`(cd "$script_dir_path"; /bin/pwd)` + +@host_qt_bindir@/qmake $* -qtconf "$script_dir_path/target_qt.conf" |