diff options
author | Martchus | 2018-12-12 19:01:21 +0100 |
---|---|---|
committer | Martchus | 2018-12-12 19:01:21 +0100 |
commit | de26a38b4abc44957ad9cc23819d77ec36de2e4c (patch) | |
tree | ed0f649eade6ec698a1e6afba3c1ab0a665510d8 | |
parent | eda5daef2c7b89b768b7214c234f5329c6919003 (diff) | |
download | aur-de26a38b4abc44957ad9cc23819d77ec36de2e4c.tar.gz |
Build the right project
-rw-r--r-- | .SRCINFO | 8 | ||||
-rw-r--r-- | 0001-Hardcode-linker-flags-for-platform-plugin.patch | 46 | ||||
-rw-r--r-- | PKGBUILD | 19 |
3 files changed, 63 insertions, 10 deletions
@@ -1,7 +1,7 @@ pkgbase = mingw-w64-qt5-webglplugin pkgdesc = QPA plugin for running an application via a browser using streamed WebGL commands (mingw-w64) pkgver = 5.12.0 - pkgrel = 1 + pkgrel = 2 url = https://www.qt.io/ arch = i686 arch = x86_64 @@ -19,8 +19,10 @@ pkgbase = mingw-w64-qt5-webglplugin options = !strip options = !buildflags options = staticlibs - source = https://download.qt.io/official_releases/qt/5.12/5.12.0/submodules/qt3d-everywhere-src-5.12.0.tar.xz - sha256sums = a12adc9c14ffa18ff5c4951efb41914d4840a0c2a88486eb8d39a4833e4631da + source = https://download.qt.io/official_releases/qt/5.12/5.12.0/submodules/qtwebglplugin-everywhere-src-5.12.0.tar.xz + source = 0001-Hardcode-linker-flags-for-platform-plugin.patch + sha256sums = 65223ad13a46e38343a621459a60ea25bc9e74d6549bf62a2d54d839c66b652e + sha256sums = 31b168aadea2a3936419809d00e061ab09453bcfb3ca95269ac1911dfb68c34d pkgname = mingw-w64-qt5-webglplugin diff --git a/0001-Hardcode-linker-flags-for-platform-plugin.patch b/0001-Hardcode-linker-flags-for-platform-plugin.patch new file mode 100644 index 000000000000..04b3488f8a5a --- /dev/null +++ b/0001-Hardcode-linker-flags-for-platform-plugin.patch @@ -0,0 +1,46 @@ +From 5b16d26c0064099d26cfdf51cfd220948b396e5b Mon Sep 17 00:00:00 2001 +From: Marius Kittler <mkittler@suse.de> +Date: Wed, 12 Dec 2018 18:16:54 +0100 +Subject: [PATCH] Hardcode linker flags for platform plugin + +Otherwise incorrect order of libs leads to errors +when building libqwebgl.dll + +This is the same workaround as for the platform plugins +in qtbase. +--- + src/plugins/platforms/webgl/webgl.pro | 18 ++++++++++++++---- + 1 file changed, 14 insertions(+), 4 deletions(-) + +diff --git a/src/plugins/platforms/webgl/webgl.pro b/src/plugins/platforms/webgl/webgl.pro +index 7f7227c..45f8f66 100644 +--- a/src/plugins/platforms/webgl/webgl.pro ++++ b/src/plugins/platforms/webgl/webgl.pro +@@ -1,10 +1,20 @@ + TARGET = qwebgl + QT += \ + websockets \ +- gui-private \ +- eventdispatcher_support-private \ +- fontdatabase_support-private \ +- theme_support-private ++ gui-private ++ ++# Fix linker error when building libqwebgl.dll by specifying linker flags forer flags for ++# required modules manually (otherwise order is messed) ++LIBS += \ ++ -lQt5EventDispatcherSupport \ ++ -lQt5FontDatabaseSupport \ ++ -lQt5ThemeSupport \ ++ -lfreetype -lole32 -lgdi32 -ldwmapi -luuid ++# However, this workaround leads to the necessity of specifying include dirs manually ++INCLUDEPATH += \} \ ++ $$QT_INSTALL_PREFIX/include/qt/QtEventDispatcherSupport/$${QT_VERSION} \ ++ $$QT_INSTALL_PREFIX/include/qt/QtFontDatabaseSupport/$${QT_VERSION} \ ++ $$QT_INSTALL_PREFIX/include/qt/QtThemeSupport/$${QT_VERSION} + + qtHaveModule(quick) { + QT += quick +-- +2.20.0 + @@ -7,10 +7,10 @@ # Includes dynamic and static versions; if only one version is requried, just # set $NO_STATIC_LIBS or $NO_SHARED_LIBS. -_qt_module=qt3d +_qt_module=qtwebglplugin pkgname="mingw-w64-qt5-webglplugin" pkgver=5.12.0 -pkgrel=1 +pkgrel=2 arch=('i686' 'x86_64') pkgdesc="QPA plugin for running an application via a browser using streamed WebGL commands (mingw-w64)" depends=('mingw-w64-qt5-declarative' 'mingw-w64-qt5-websockets') @@ -20,8 +20,10 @@ groups=('mingw-w64-qt5') license=('GPL3' 'LGPL3' 'FDL' 'custom') url='https://www.qt.io/' _pkgfqn="${_qt_module}-everywhere-src-${pkgver}" -source=("https://download.qt.io/official_releases/qt/${pkgver%.*}/${pkgver}/submodules/${_pkgfqn}.tar.xz") -sha256sums=('a12adc9c14ffa18ff5c4951efb41914d4840a0c2a88486eb8d39a4833e4631da') +source=("https://download.qt.io/official_releases/qt/${pkgver%.*}/${pkgver}/submodules/${_pkgfqn}.tar.xz" + '0001-Hardcode-linker-flags-for-platform-plugin.patch') +sha256sums=('65223ad13a46e38343a621459a60ea25bc9e74d6549bf62a2d54d839c66b652e' + '31b168aadea2a3936419809d00e061ab09453bcfb3ca95269ac1911dfb68c34d') _architectures='i686-w64-mingw32 x86_64-w64-mingw32' [[ $NO_STATIC_LIBS ]] || \ @@ -34,8 +36,11 @@ _architectures='i686-w64-mingw32 x86_64-w64-mingw32' prepare() { cd "${srcdir}/${_pkgfqn}" - # ensure qgltf is linked against zlib - echo 'LIBS += -L/usr/lib -lz' >> tools/qgltf/qgltf.pro + # apply patches; further descriptions can be found in patch files itself + for patch in "$srcdir/"*.patch; do + msg2 "Applying patch $patch" + patch -p1 -i "$patch" + done } build() { @@ -45,7 +50,7 @@ build() { for _config in "${_configurations[@]}"; do msg2 "Building ${_config##*=} version for ${_arch}" mkdir -p build-${_arch}-${_config##*=} && pushd build-${_arch}-${_config##*=} - ${_arch}-qmake-qt5 ../${_qt_module}.pro ${_config} + ${_arch}-qmake-qt5 ../${_qt_module}.pro ${_config} QT_INSTALL_PREFIX="/usr/${_arch}" make popd done |