diff options
| author | Martin Jansa <Martin.Jansa@gmail.com> | 2013-04-03 16:42:45 +0200 |
|---|---|---|
| committer | Martin Jansa <Martin.Jansa@gmail.com> | 2013-04-17 16:10:01 +0200 |
| commit | c27dac3e4e11fb512a1483dacb8a4dcceb827323 (patch) | |
| tree | cf40bb71172ac67846f6051d1829004a0c95c13e /recipes-qt | |
| parent | 70b1b233b20c4128cd068c35244c1a97934edf1d (diff) | |
| download | meta-qt5-c27dac3e4e11fb512a1483dacb8a4dcceb827323.tar.gz | |
qtbase: use the same patch for qt.conf override for target and native
Diffstat (limited to 'recipes-qt')
5 files changed, 48 insertions, 65 deletions
diff --git a/recipes-qt/qt5/qtbase-native.inc b/recipes-qt/qt5/qtbase-native.inc index c401c7bd..43e32530 100644 --- a/recipes-qt/qt5/qtbase-native.inc +++ b/recipes-qt/qt5/qtbase-native.inc | |||
| @@ -13,8 +13,7 @@ SSTATE_SCAN_FILES += "*.pri *.prl" | |||
| 13 | QT_DIR_NAME ?= "qt5" | 13 | QT_DIR_NAME ?= "qt5" |
| 14 | 14 | ||
| 15 | SRC_URI += " \ | 15 | SRC_URI += " \ |
| 16 | file://0001-qlibraryinfo-Allow-the-specification-of-where-to-loa.patch \ | 16 | file://0001-qlibraryinfo-allow-to-set-qt.conf-from-the-outside-u.patch \ |
| 17 | file://0003-qtbase-Allow-qt.conf-override-when-bootstrapping.patch \ | ||
| 18 | file://0001-Always-build-uic.patch \ | 17 | file://0001-Always-build-uic.patch \ |
| 19 | " | 18 | " |
| 20 | 19 | ||
diff --git a/recipes-qt/qt5/qtbase-native/0003-qtbase-Allow-qt.conf-override-when-bootstrapping.patch b/recipes-qt/qt5/qtbase-native/0003-qtbase-Allow-qt.conf-override-when-bootstrapping.patch deleted file mode 100644 index 1b294fd2..00000000 --- a/recipes-qt/qt5/qtbase-native/0003-qtbase-Allow-qt.conf-override-when-bootstrapping.patch +++ /dev/null | |||
| @@ -1,30 +0,0 @@ | |||
| 1 | From 40e6c0f88774b55111c63ed28bba626141797476 Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Mikko Levonmaa <mikko.levonmaa@palm.com> | ||
| 3 | Date: Tue, 4 Dec 2012 15:32:33 -0800 | ||
| 4 | Subject: [PATCH 3/3] qtbase: Allow qt.conf override when bootstrapping | ||
| 5 | |||
| 6 | Upstream-Status: Inappropriate [configuration] | ||
| 7 | |||
| 8 | Signed-off-by: Mikko Levonmaa <mikko.levonmaa@palm.com> | ||
| 9 | --- | ||
| 10 | qmake/option.cpp | 5 +++++ | ||
| 11 | 1 files changed, 5 insertions(+), 0 deletions(-) | ||
| 12 | |||
| 13 | diff --git a/qmake/option.cpp b/qmake/option.cpp | ||
| 14 | index 91c154a..a4f3a85 100644 | ||
| 15 | --- a/qmake/option.cpp | ||
| 16 | +++ b/qmake/option.cpp | ||
| 17 | @@ -647,6 +647,10 @@ qmakeAddCacheClear(qmakeCacheClearFunc func, void **data) | ||
| 18 | |||
| 19 | QString qt_libraryInfoFile() | ||
| 20 | { | ||
| 21 | + QString qtconfig = QFile::decodeName(getenv("QT_CONF_PATH")); | ||
| 22 | + if (QFile::exists(qtconfig)) { | ||
| 23 | + return qtconfig; | ||
| 24 | + } | ||
| 25 | if (!Option::globals->qmake_abslocation.isEmpty()) | ||
| 26 | return QDir(QFileInfo(Option::globals->qmake_abslocation).absolutePath()).filePath("qt.conf"); | ||
| 27 | return QString(); | ||
| 28 | -- | ||
| 29 | 1.7.4.1 | ||
| 30 | |||
diff --git a/recipes-qt/qt5/qtbase.inc b/recipes-qt/qt5/qtbase.inc index d4a5652d..8ada1910 100644 --- a/recipes-qt/qt5/qtbase.inc +++ b/recipes-qt/qt5/qtbase.inc | |||
| @@ -1,7 +1,7 @@ | |||
| 1 | require qt5.inc | 1 | require qt5.inc |
| 2 | 2 | ||
| 3 | SRC_URI += " \ | 3 | SRC_URI += " \ |
| 4 | file://0001-qlibraryinfo-Allow-the-specification-of-where-to-loa.patch \ | 4 | file://0001-qlibraryinfo-allow-to-set-qt.conf-from-the-outside-u.patch \ |
| 5 | file://0002-qmake-is-already-built-in-qt5-tools-native.patch \ | 5 | file://0002-qmake-is-already-built-in-qt5-tools-native.patch \ |
| 6 | file://0003-Allow-building-a-separate-qmake-for-the-target.patch \ | 6 | file://0003-Allow-building-a-separate-qmake-for-the-target.patch \ |
| 7 | file://qmake.conf.sh \ | 7 | file://qmake.conf.sh \ |
diff --git a/recipes-qt/qt5/qtbase/0001-qlibraryinfo-Allow-the-specification-of-where-to-loa.patch b/recipes-qt/qt5/qtbase/0001-qlibraryinfo-Allow-the-specification-of-where-to-loa.patch deleted file mode 100644 index 10219ec9..00000000 --- a/recipes-qt/qt5/qtbase/0001-qlibraryinfo-Allow-the-specification-of-where-to-loa.patch +++ /dev/null | |||
| @@ -1,32 +0,0 @@ | |||
| 1 | From 4dcf1eeaa1742435027ad0cb2a218e7e9b776011 Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Otavio Salvador <otavio@ossystems.com.br> | ||
| 3 | Date: Mon, 19 Nov 2012 10:19:52 -0200 | ||
| 4 | Subject: [PATCH] qlibraryinfo: Allow the specification of where to load | ||
| 5 | qt.conf | ||
| 6 | |||
| 7 | This is important to allow cross toolchains to work out of box. | ||
| 8 | |||
| 9 | This patch was based on an existent patch in OpenEmbedded. | ||
| 10 | |||
| 11 | Change-Id: Idc4feee95a9961db02752d88da9cfe360e89f8e3 | ||
| 12 | --- | ||
| 13 | src/corelib/global/qlibraryinfo.cpp | 4 ++++ | ||
| 14 | 1 file changed, 4 insertions(+) | ||
| 15 | |||
| 16 | diff --git a/src/corelib/global/qlibraryinfo.cpp b/src/corelib/global/qlibraryinfo.cpp | ||
| 17 | index a756577..0c92e12 100644 | ||
| 18 | --- a/src/corelib/global/qlibraryinfo.cpp | ||
| 19 | +++ b/src/corelib/global/qlibraryinfo.cpp | ||
| 20 | @@ -164,6 +164,9 @@ QSettings *QLibraryInfoPrivate::findConfiguration() | ||
| 21 | } | ||
| 22 | } | ||
| 23 | #endif | ||
| 24 | + if (!QFile::exists(qtconfig)) { | ||
| 25 | + qtconfig = QFile::decodeName(getenv("QT_CONF_PATH")); | ||
| 26 | + } | ||
| 27 | if (QFile::exists(qtconfig)) | ||
| 28 | return new QSettings(qtconfig, QSettings::IniFormat); | ||
| 29 | return 0; //no luck | ||
| 30 | -- | ||
| 31 | 1.7.10.4 | ||
| 32 | |||
diff --git a/recipes-qt/qt5/qtbase/0001-qlibraryinfo-allow-to-set-qt.conf-from-the-outside-u.patch b/recipes-qt/qt5/qtbase/0001-qlibraryinfo-allow-to-set-qt.conf-from-the-outside-u.patch new file mode 100644 index 00000000..857d5e84 --- /dev/null +++ b/recipes-qt/qt5/qtbase/0001-qlibraryinfo-allow-to-set-qt.conf-from-the-outside-u.patch | |||
| @@ -0,0 +1,46 @@ | |||
| 1 | From 2af433da710aff74445cb5148d369427bdd501de Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Holger Freyther <zecke@selfish.org> | ||
| 3 | Date: Wed, 26 Sep 2012 17:22:30 +0200 | ||
| 4 | Subject: [PATCH] qlibraryinfo: allow to set qt.conf from the outside using the | ||
| 5 | environment | ||
| 6 | |||
| 7 | Allow to set a qt.conf from the outside using the environment. This allows | ||
| 8 | to inject new prefixes and other paths into qmake. This is needed when using | ||
| 9 | the same qmake binary to build qt/x11 and qt/embedded | ||
| 10 | |||
| 11 | Upstream-Status: Pending | ||
| 12 | |||
| 13 | Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com> | ||
| 14 | --- | ||
| 15 | src/corelib/global/qlibraryinfo.cpp | 8 ++++++++ | ||
| 16 | 1 file changed, 8 insertions(+) | ||
| 17 | |||
| 18 | diff --git a/src/corelib/global/qlibraryinfo.cpp b/src/corelib/global/qlibraryinfo.cpp | ||
| 19 | index 747fd87..c9f8170 100644 | ||
| 20 | --- a/src/corelib/global/qlibraryinfo.cpp | ||
| 21 | +++ b/src/corelib/global/qlibraryinfo.cpp | ||
| 22 | @@ -140,6 +140,10 @@ QSettings *QLibraryInfoPrivate::findConfiguration() | ||
| 23 | { | ||
| 24 | QString qtconfig = QStringLiteral(":/qt/etc/qt.conf"); | ||
| 25 | #ifdef QT_BOOTSTRAPPED | ||
| 26 | + if (!QFile::exists(qtconfig)) { | ||
| 27 | + QByteArray config = getenv("QT_CONF_PATH"); | ||
| 28 | + qtconfig = QFile::decodeName(config); | ||
| 29 | + } | ||
| 30 | if(!QFile::exists(qtconfig)) | ||
| 31 | qtconfig = qt_libraryInfoFile(); | ||
| 32 | #else | ||
| 33 | @@ -164,6 +168,10 @@ QSettings *QLibraryInfoPrivate::findConfiguration() | ||
| 34 | } | ||
| 35 | } | ||
| 36 | #endif | ||
| 37 | + if (!QFile::exists(qtconfig)) { | ||
| 38 | + QByteArray config = getenv("QT_CONF_PATH"); | ||
| 39 | + qtconfig = QFile::decodeName(config); | ||
| 40 | + } | ||
| 41 | if (QFile::exists(qtconfig)) | ||
| 42 | return new QSettings(qtconfig, QSettings::IniFormat); | ||
| 43 | return 0; //no luck | ||
| 44 | -- | ||
| 45 | 1.8.1.5 | ||
| 46 | |||
