Fix mingw-w64-qt5-webglplugin
This commit is contained in:
parent
b66df4c64e
commit
7b2c0cc48e
|
@ -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
|
||||
|
|
Loading…
Reference in New Issue