Patchwork [meta-qt5,2/3] qtdeclarative: drop qtsvg dependency, add packageconfig for qtxmlpatterns

login
register
mail settings
Submitter Andreas Oberritter
Date Feb. 28, 2014, 8:15 p.m.
Message ID <1393618507-29414-2-git-send-email-obi@opendreambox.org>
Download mbox | patch
Permalink /patch/67769/
State Accepted, archived
Headers show

Comments

Andreas Oberritter - Feb. 28, 2014, 8:15 p.m.
The dependency on qtsvg seems to be a leftover from an old version.
Version 5.2.1 of qtdeclarative doesn't include any reference to it.

Depend on qtbase in case qtxmlpatterns gets disabled.

Signed-off-by: Andreas Oberritter <obi@opendreambox.org>
---
 recipes-qt/qt5/qtdeclarative.inc | 13 ++++++++++++-
 1 file changed, 12 insertions(+), 1 deletion(-)

Patch

diff --git a/recipes-qt/qt5/qtdeclarative.inc b/recipes-qt/qt5/qtdeclarative.inc
index 12e650f..bd68955 100644
--- a/recipes-qt/qt5/qtdeclarative.inc
+++ b/recipes-qt/qt5/qtdeclarative.inc
@@ -5,4 +5,15 @@  SRC_URI += " \
     file://0003-Fix-wrong-calculation-of-viewPort-for-transitions.patch \
 "
 
-DEPENDS += "qtsvg qtxmlpatterns"
+DEPENDS += "qtbase"
+
+PACKAGECONFIG ??= "qtxmlpatterns"
+PACKAGECONFIG[qtxmlpatterns] = ",,qtxmlpatterns"
+
+do_configure_prepend() {
+    # disable qtxmlpatterns test if it isn't enabled by PACKAGECONFIG
+    sed -e 's/^\(qtHaveModule(xmlpatterns)\)/OE_QTXMLPATTERNS_ENABLED:\1/' -i ${S}/src/imports/imports.pro
+    sed -e 's/^\(!qtHaveModule(xmlpatterns)\)/!OE_QTXMLPATTERNS_ENABLED|\1/' -i ${S}/tests/auto/quick/quick.pro
+}
+
+EXTRA_QMAKEVARS_PRE += "${@base_contains('PACKAGECONFIG', 'qtxmlpatterns', 'CONFIG+=OE_QTXMLPATTERNS_ENABLED', '', d)}"