diff options
author | Jonathan Liu <net147@gmail.com> | 2013-06-06 13:19:23 +1000 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2013-06-11 15:38:03 +0100 |
commit | fdb5c12240ff5e8e279a088dee632a308d233838 (patch) | |
tree | 41437c64740d373208b2c6e1813c23c35be1f1dc /meta/recipes-qt/qt4 | |
parent | 147b8dd481e67fe1caf44d2b5c43497d317a26be (diff) | |
download | poky-fdb5c12240ff5e8e279a088dee632a308d233838.tar.gz |
qt4: fix QMAKE_QT_CONFIG being overwritten with empty value
QMAKE_QT_CONFIG is set by the linux-oe-g++ mkspec but it is overwritten
with an empty value read from .qmake.cache. Avoid this by first checking
if the value from .qmake.cache is not empty before assigning it to
QMAKE_QT_CONFIG.
This allows variables from qconfig.pri such as QT_ARCH, QT_CONFIG,
QT_VERSION, etc. to be queried by qmake projects.
(From OE-Core rev: 5330905749828ea8befdee559c180754ac506b75)
Signed-off-by: Jonathan Liu <net147@gmail.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-qt/qt4')
-rw-r--r-- | meta/recipes-qt/qt4/qt4-4.8.4.inc | 1 | ||||
-rw-r--r-- | meta/recipes-qt/qt4/qt4-4.8.4/0026-Don-t-overwrite-QMAKE_QT_CONFIG-with-empty-value.patch | 39 |
2 files changed, 40 insertions, 0 deletions
diff --git a/meta/recipes-qt/qt4/qt4-4.8.4.inc b/meta/recipes-qt/qt4/qt4-4.8.4.inc index ce12b1e52b..e87daccf5a 100644 --- a/meta/recipes-qt/qt4/qt4-4.8.4.inc +++ b/meta/recipes-qt/qt4/qt4-4.8.4.inc | |||
@@ -25,6 +25,7 @@ SRC_URI = "http://releases.qt-project.org/qt4/source/qt-everywhere-opensource-sr | |||
25 | file://0023-qtnetwork-blacklist-two-more-certificates.patch \ | 25 | file://0023-qtnetwork-blacklist-two-more-certificates.patch \ |
26 | file://0024-Change-all-shmget-calls-to-user-only-memory.patch \ | 26 | file://0024-Change-all-shmget-calls-to-user-only-memory.patch \ |
27 | file://0025-Remove-unnecessary-typedef-found-by-gcc4-8.patch \ | 27 | file://0025-Remove-unnecessary-typedef-found-by-gcc4-8.patch \ |
28 | file://0026-Don-t-overwrite-QMAKE_QT_CONFIG-with-empty-value.patch \ | ||
28 | file://g++.conf \ | 29 | file://g++.conf \ |
29 | file://linux.conf \ | 30 | file://linux.conf \ |
30 | " | 31 | " |
diff --git a/meta/recipes-qt/qt4/qt4-4.8.4/0026-Don-t-overwrite-QMAKE_QT_CONFIG-with-empty-value.patch b/meta/recipes-qt/qt4/qt4-4.8.4/0026-Don-t-overwrite-QMAKE_QT_CONFIG-with-empty-value.patch new file mode 100644 index 0000000000..a37e35f980 --- /dev/null +++ b/meta/recipes-qt/qt4/qt4-4.8.4/0026-Don-t-overwrite-QMAKE_QT_CONFIG-with-empty-value.patch | |||
@@ -0,0 +1,39 @@ | |||
1 | From 1c75ea0332054c420efd676c147e45eee43e0118 Mon Sep 17 00:00:00 2001 | ||
2 | From: Jonathan Liu <net147@gmail.com> | ||
3 | Date: Thu, 6 Jun 2013 12:42:13 +1000 | ||
4 | Subject: [PATCH] Don't overwrite QMAKE_QT_CONFIG with empty value | ||
5 | |||
6 | If the mkspec sets QMAKE_QT_CONFIG, QMAKE_QT_CONFIG may be overwritten | ||
7 | with an empty value from .qmake.cache. Avoid this by first checking | ||
8 | if the value from .qmake.cache is not empty before assigning it to | ||
9 | QMAKE_QT_CONFIG. | ||
10 | |||
11 | Upstream-Status: Submitted | ||
12 | https://codereview.qt-project.org/#change,58109 | ||
13 | |||
14 | Change-Id: I95fa630139b8798156a2fb15d0dde630a0a53a0a | ||
15 | Signed-off-by: Jonathan Liu <net147@gmail.com> | ||
16 | --- | ||
17 | mkspecs/features/qt_config.prf | 6 +++++- | ||
18 | 1 file changed, 5 insertions(+), 1 deletion(-) | ||
19 | |||
20 | diff --git a/mkspecs/features/qt_config.prf b/mkspecs/features/qt_config.prf | ||
21 | index fc14cdd..e059b7e 100644 | ||
22 | --- a/mkspecs/features/qt_config.prf | ||
23 | +++ b/mkspecs/features/qt_config.prf | ||
24 | @@ -1,7 +1,11 @@ | ||
25 | # This file is loaded by the mkspecs, before .qmake.cache has been loaded. | ||
26 | # Consequently, we have to do some stunts to get values out of the cache. | ||
27 | |||
28 | -exists($$_QMAKE_CACHE_):QMAKE_QT_CONFIG = $$fromfile($$_QMAKE_CACHE_, QMAKE_QT_CONFIG) | ||
29 | +exists($$_QMAKE_CACHE_) { | ||
30 | + qdd = $$fromfile($$_QMAKE_CACHE_, QMAKE_QT_CONFIG) | ||
31 | + !isEmpty(qdd): QMAKE_QT_CONFIG = $$qdd | ||
32 | + unset(qdd) | ||
33 | +} | ||
34 | isEmpty(QMAKE_QT_CONFIG)|!exists($$QMAKE_QT_CONFIG) { | ||
35 | qdd = $$QT_BUILD_TREE | ||
36 | isEmpty(qdd):exists($$_QMAKE_CACHE_): qdd = $$fromfile($$_QMAKE_CACHE_, QT_BUILD_TREE) | ||
37 | -- | ||
38 | 1.8.2.3 | ||
39 | |||