From 6db0e9c38946a1ca0212c4400bc0624d8ac19b5c Mon Sep 17 00:00:00 2001
From: Kevin Mihelich <kevin@archlinuxarm.org>
Date: Sun, 29 Jan 2017 00:24:26 +0000
Subject: [PATCH] extra/qt5-base to 5.8.0-2

---
 extra/qt5-base/PKGBUILD     | 25 ++++++++-----------------
 extra/qt5-base/rebuild.list | 15 +++++++++++----
 2 files changed, 19 insertions(+), 21 deletions(-)

diff --git a/extra/qt5-base/PKGBUILD b/extra/qt5-base/PKGBUILD
index 10c269a02..06b88d152 100644
--- a/extra/qt5-base/PKGBUILD
+++ b/extra/qt5-base/PKGBUILD
@@ -8,17 +8,17 @@
 #  - use OpenGLES 2.0
 
 pkgname=qt5-base
-_qtver=5.7.1
+_qtver=5.8.0
 pkgver=${_qtver/-/}
 pkgrel=2
 arch=('i686' 'x86_64')
 url='http://qt-project.org/'
 license=('GPL3' 'LGPL3' 'FDL' 'custom')
 pkgdesc='A cross-platform application and UI framework'
-depends=('libjpeg-turbo' 'xcb-util-keysyms' 'libgl' 'fontconfig'
+depends=('libjpeg-turbo' 'xcb-util-keysyms' 'xcb-util-renderutil' 'libgl' 'fontconfig'
          'xcb-util-wm' 'libxrender' 'libxi' 'sqlite' 'xcb-util-image' 'icu'
          'tslib' 'libinput' 'libsm' 'libxkbcommon-x11' 'libproxy' 'libcups')
-makedepends=('mtdev' 'libfbclient' 'libmariadbclient' 'sqlite' 'unixodbc' 'postgresql-libs' 'alsa-lib' 'gst-plugins-base-libs'
+makedepends=('libfbclient' 'libmariadbclient' 'sqlite' 'unixodbc' 'postgresql-libs' 'alsa-lib' 'gst-plugins-base-libs'
              'gtk3' 'libpulse' 'cups' 'freetds')
 optdepends=('qt5-svg: to use SVG icon themes'
             'postgresql-libs: PostgreSQL driver'
@@ -26,17 +26,14 @@ optdepends=('qt5-svg: to use SVG icon themes'
             'unixodbc: ODBC driver'
             'libfbclient: Firebird/iBase driver'
             'freetds: MS SQL driver'
-            'mtdev: evdev plugin'
             'gtk3: GTK platform plugin')
 conflicts=('qtchooser')
 groups=('qt' 'qt5')
 _pkgfqn="${pkgname/5-/}-opensource-src-${_qtver}"
 source=("http://download.qt.io/official_releases/qt/${pkgver%.*}/${_qtver}/submodules/${_pkgfqn}.tar.xz"
-        qtbug-49061.patch::"https://github.com/qt/qtbase/commit/494376f9.patch"
-        qtbug-55583.patch::"https://github.com/qt/qtbase/commit/84ea00d4.patch")
-md5sums=('f0809befe04160fbb73bbf38a06a2073'
-         'c86af27562bbbe05c3defd63d00130fd'
-         '7b11584d9ea1ccb6c419e9b9816dee63')
+        qt5-base-journald.patch::"https://github.com/qt/qtbase/commit/0c8f3229.patch")
+md5sums=('6e1f7f6fb6333eb66e563b175c4e87e9'
+         '160fde81fe882c4241f04634f53691ad')
 
 prepare() {
   cd ${_pkgfqn}
@@ -52,14 +49,8 @@ prepare() {
   find . -name '*.py' -exec sed -i \
     's|#![ ]*/usr/bin/python$|&2|;s|#![ ]*/usr/bin/env python$|&2|' {} +
 
-  # Fix libsystemd-journal detection
-  sed -e 's|libsystemd-journal|libsystemd|' -i config.tests/unix/journald/journald.pro -i src/corelib/global/global.pri
-
-  # Don't unload plugins in QPluginLoader https://bugreports.qt.io/browse/QTBUG-49061
-  patch -p1 -i ../qtbug-49061.patch
-
-  # Fix file chooser segfault on gnome/wayland https://bugreports.qt.io/browse/QTBUG-55583
-  patch -p1 -i ../qtbug-55583.patch
+  # Fix logging to systemd journal
+  patch -p1 -i ../qt5-base-journald.patch
 }
 
 build() {
diff --git a/extra/qt5-base/rebuild.list b/extra/qt5-base/rebuild.list
index 9b782f5a8..dbbe6fb1e 100644
--- a/extra/qt5-base/rebuild.list
+++ b/extra/qt5-base/rebuild.list
@@ -1,7 +1,14 @@
-fcitx-qt5
+fcitx-qt5 *
 plasma-integration
 gcin
 calibre
-akonadi
-skrooge
-qt5dxcb-plugin
+akonadi *
+skrooge *
+kwin
+lxqt-qtplugin
+pyqt5 *
+deepin-qt5integration *
+deepin-tool-kit *
+qt5ct
+
+* - Also need rebuild for patch Qt version updates