krfb: fix build with qtwayland 6.7.1
This commit is contained in:
parent
d8c92411c4
commit
e033e6dacb
1 changed files with 64 additions and 0 deletions
64
srcpkgs/krfb/patches/fix-build-qtwayland-6.7.1.patch
Normal file
64
srcpkgs/krfb/patches/fix-build-qtwayland-6.7.1.patch
Normal file
|
@ -0,0 +1,64 @@
|
|||
From 36349df89bfd8b213074e61faac4c5651d439cdd Mon Sep 17 00:00:00 2001
|
||||
From: Andreas Sturmlechner <asturm@gentoo.org>
|
||||
Date: Mon, 20 May 2024 19:56:20 +0200
|
||||
Subject: [PATCH] Fix build with >=QtWaylandScanner-6.7.1
|
||||
|
||||
Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
|
||||
---
|
||||
framebuffers/pipewire/CMakeLists.txt | 16 +++++++++++-----
|
||||
framebuffers/pipewire/screencasting.cpp | 4 ++++
|
||||
2 files changed, 15 insertions(+), 5 deletions(-)
|
||||
|
||||
diff --git a/framebuffers/pipewire/CMakeLists.txt b/framebuffers/pipewire/CMakeLists.txt
|
||||
index b4ce9bad..68ca76e0 100644
|
||||
--- a/framebuffers/pipewire/CMakeLists.txt
|
||||
+++ b/framebuffers/pipewire/CMakeLists.txt
|
||||
@@ -9,11 +9,6 @@ set (krfb_framebuffer_pw_SRCS
|
||||
screencasting.cpp
|
||||
)
|
||||
|
||||
-ecm_add_qtwayland_client_protocol(krfb_framebuffer_pw_SRCS
|
||||
- PROTOCOL ${PLASMA_WAYLAND_PROTOCOLS_DIR}/screencast.xml
|
||||
- BASENAME zkde-screencast-unstable-v1
|
||||
-)
|
||||
-
|
||||
ecm_qt_declare_logging_category(krfb_framebuffer_pw_SRCS
|
||||
HEADER krfb_fb_pipewire_debug.h
|
||||
IDENTIFIER KRFB_FB_PIPEWIRE
|
||||
@@ -39,6 +34,17 @@ add_library(krfb_framebuffer_pw
|
||||
${krfb_framebuffer_pw_SRCS}
|
||||
)
|
||||
set_property(TARGET krfb_framebuffer_pw PROPERTY C_STANDARD 99)
|
||||
|
||||
+if (Qt6_VERSION VERSION_LESS "6.7.1")
|
||||
+ ecm_add_qtwayland_client_protocol(krfb_framebuffer_pw
|
||||
+ PROTOCOL ${PLASMA_WAYLAND_PROTOCOLS_DIR}/screencast.xml
|
||||
+ BASENAME zkde-screencast-unstable-v1
|
||||
+ )
|
||||
+else()
|
||||
+ qt6_generate_wayland_protocol_client_sources(krfb_framebuffer_pw
|
||||
+ FILES ${PLASMA_WAYLAND_PROTOCOLS_DIR}/screencast.xml
|
||||
+ )
|
||||
+endif()
|
||||
+
|
||||
target_link_libraries(krfb_framebuffer_pw
|
||||
Qt::Core
|
||||
diff --git a/framebuffers/pipewire/screencasting.cpp b/framebuffers/pipewire/screencasting.cpp
|
||||
index 3c4d1abe..c338699f 100644
|
||||
--- a/framebuffers/pipewire/screencasting.cpp
|
||||
+++ b/framebuffers/pipewire/screencasting.cpp
|
||||
@@ -5,7 +5,11 @@
|
||||
*/
|
||||
|
||||
#include "screencasting.h"
|
||||
+#if QT_VERSION < QT_VERSION_CHECK(6, 7, 1)
|
||||
#include "qwayland-zkde-screencast-unstable-v1.h"
|
||||
+#else
|
||||
+#include "qwayland-screencast.h"
|
||||
+#endif
|
||||
#include <KWayland/Client/registry.h>
|
||||
#include <QDebug>
|
||||
#include <QRect>
|
||||
--
|
||||
GitLab
|
||||
|
Loading…
Add table
Reference in a new issue