summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndreas Sturmlechner <asturm@gentoo.org>2021-09-14 10:51:08 +0200
committerAndreas Sturmlechner <asturm@gentoo.org>2021-09-14 11:03:36 +0200
commitfb620f608733db4c0046ed51a848377f37263ea6 (patch)
tree883ed6e7b580a5e027e40b5b5ae035a1ce909f3d
parentkde-plasma/libksysguard: Rebase no-detailed-mem-message.patch (diff)
downloadgentoo-fb620f60.tar.gz
gentoo-fb620f60.tar.bz2
gentoo-fb620f60.zip
kde-plasma/kwin: Fix build with >=media-libs/libglvnd-1.3.4
Drop obsolete >=media-libs/libglvnd-1.3.4 blocker and DEPEND crutch. Closes: https://bugs.gentoo.org/810511 Package-Manager: Portage-3.0.23, Repoman-3.0.3 Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
-rw-r--r--kde-plasma/kwin/files/kwin-5.22.5-libglvnd-1.3.4.patch44
-rw-r--r--kde-plasma/kwin/kwin-5.22.5.ebuild5
2 files changed, 46 insertions, 3 deletions
diff --git a/kde-plasma/kwin/files/kwin-5.22.5-libglvnd-1.3.4.patch b/kde-plasma/kwin/files/kwin-5.22.5-libglvnd-1.3.4.patch
new file mode 100644
index 000000000000..bdca6e2081bc
--- /dev/null
+++ b/kde-plasma/kwin/files/kwin-5.22.5-libglvnd-1.3.4.patch
@@ -0,0 +1,44 @@
+From 839710201c389b7f4ed248cb3818e755a37ce977 Mon Sep 17 00:00:00 2001
+From: Vlad Zahorodnii <vlad.zahorodnii@kde.org>
+Date: Fri, 10 Sep 2021 13:36:04 +0300
+Subject: [PATCH] x11: Fix build with EGL_NO_PLATFORM_SPECIFIC_TYPES
+
+eglCreateWindowSurface() wants a Window (unsigned long), but with
+EGL_NO_PLATFORM_SPECIFIC_TYPES, EGLNativeWindowType is defined as an
+opaque pointer, i.e. void*.
+
+BUG: 440372
+---
+ src/plugins/platforms/x11/common/eglonxbackend.cpp | 13 +++++++------
+ 1 file changed, 7 insertions(+), 6 deletions(-)
+
+diff --git a/src/plugins/platforms/x11/common/eglonxbackend.cpp b/src/plugins/platforms/x11/common/eglonxbackend.cpp
+index c62ec170d..d2900c7c3 100644
+--- a/src/plugins/platforms/x11/common/eglonxbackend.cpp
++++ b/src/plugins/platforms/x11/common/eglonxbackend.cpp
+@@ -213,15 +213,16 @@ EGLSurface EglOnXBackend::createSurface(xcb_window_t window)
+ return EGL_NO_SURFACE;
+ }
+
++ // Window is 64 bits on a 64-bit architecture whereas xcb_window_t is always 32 bits.
++ unsigned long nativeWindow = window;
++
+ EGLSurface surface = EGL_NO_SURFACE;
+ if (havePlatformBase()) {
+- // Note: Window is 64 bits on a 64-bit architecture whereas xcb_window_t is
+- // always 32 bits. eglCreatePlatformWindowSurfaceEXT() expects the
+- // native_window parameter to be pointer to a Window, so this variable
+- // cannot be an xcb_window_t.
+- surface = eglCreatePlatformWindowSurfaceEXT(eglDisplay(), config(), (void *) &window, nullptr);
++ // eglCreatePlatformWindowSurfaceEXT() expects a pointer to the Window.
++ surface = eglCreatePlatformWindowSurfaceEXT(eglDisplay(), config(), (void *) &nativeWindow, nullptr);
+ } else {
+- surface = eglCreateWindowSurface(eglDisplay(), config(), window, nullptr);
++ // eglCreateWindowSurface() expects a Window, not a pointer to the Window.
++ surface = eglCreateWindowSurface(eglDisplay(), config(), reinterpret_cast<EGLNativeWindowType>(nativeWindow), nullptr);
+ }
+
+ return surface;
+--
+GitLab
+
diff --git a/kde-plasma/kwin/kwin-5.22.5.ebuild b/kde-plasma/kwin/kwin-5.22.5.ebuild
index 493e658800d7..fbccfdbbf134 100644
--- a/kde-plasma/kwin/kwin-5.22.5.ebuild
+++ b/kde-plasma/kwin/kwin-5.22.5.ebuild
@@ -79,7 +79,6 @@ COMMON_DEPEND="
"
# TODO: sys-apps/hwdata? not packaged yet; commit 33a1777a, Gentoo-bug 717216
RDEPEND="${COMMON_DEPEND}
- !>=media-libs/libglvnd-1.3.4
>=dev-qt/qtquickcontrols-${QTMIN}:5
>=dev-qt/qtquickcontrols2-${QTMIN}:5
>=dev-qt/qtvirtualkeyboard-${QTMIN}:5
@@ -91,11 +90,9 @@ RDEPEND="${COMMON_DEPEND}
)
multimedia? ( >=dev-qt/qtmultimedia-${QTMIN}:5[gstreamer,qml] )
"
-# FIXME: <media-libs/libglvnd-1.3.4 not a dep, only temp. workaround for bug #810511
DEPEND="${COMMON_DEPEND}
>=dev-qt/designer-${QTMIN}:5
>=dev-qt/qtconcurrent-${QTMIN}:5
- <media-libs/libglvnd-1.3.4
x11-base/xorg-proto
test? (
>=dev-libs/wayland-protocols-1.19
@@ -106,6 +103,8 @@ PDEPEND="
>=kde-plasma/kde-cli-tools-${PVCUT}:5
"
+PATCHES=( "${FILESDIR}/${P}-libglvnd-1.3.4.patch" ) # KDE-bug 440372, bug 810511
+
src_prepare() {
ecm_src_prepare
use multimedia || eapply "${FILESDIR}/${PN}-5.21.80-gstreamer-optional.patch"