summaryrefslogtreecommitdiff
path: root/gui-wm
diff options
context:
space:
mode:
authorAlfred Wingate <parona@protonmail.com>2023-08-07 10:42:55 +0300
committerSam James <sam@gentoo.org>2023-08-07 21:05:26 +0100
commit993790523289c55de0cbd076688df264957ce8f4 (patch)
tree54572eb7d9b0ddfe61ea1a21462761a5c628e323 /gui-wm
parentdev-util/github-cli: add 2.32.1 (diff)
downloadgentoo-993790523289c55de0cbd076688df264957ce8f4.tar.gz
gentoo-993790523289c55de0cbd076688df264957ce8f4.tar.bz2
gentoo-993790523289c55de0cbd076688df264957ce8f4.zip
gui-wm/hyprland: enable x11-backend with xwayland, not unconditionally
Closes: https://bugs.gentoo.org/911828 Closes: https://bugs.gentoo.org/911871 Signed-off-by: Alfred Wingate <parona@protonmail.com> Closes: https://github.com/gentoo/gentoo/pull/32205 Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'gui-wm')
-rw-r--r--gui-wm/hyprland/files/hyprland-0.28.0-no-wlroots-automagic-r1.patch20
-rw-r--r--gui-wm/hyprland/files/hyprland-0.28.0-no-wlroots-automagic.patch14
-rw-r--r--gui-wm/hyprland/hyprland-0.28.0-r1.ebuild (renamed from gui-wm/hyprland/hyprland-0.28.0.ebuild)4
3 files changed, 22 insertions, 16 deletions
diff --git a/gui-wm/hyprland/files/hyprland-0.28.0-no-wlroots-automagic-r1.patch b/gui-wm/hyprland/files/hyprland-0.28.0-no-wlroots-automagic-r1.patch
new file mode 100644
index 000000000000..ca37e4e7c16d
--- /dev/null
+++ b/gui-wm/hyprland/files/hyprland-0.28.0-no-wlroots-automagic-r1.patch
@@ -0,0 +1,20 @@
+# Disable automagic, otherwise wlroots will enable features if dependencies are present.
+# Enable x11-backend only if xwayland is enabled.
+diff --git a/meson.build b/meson.build
+index 6a94dee6..08993f8a 100644
+--- a/meson.build
++++ b/meson.build
+@@ -39,7 +39,12 @@ add_project_arguments(
+ ],
+ language: 'cpp')
+
+-wlroots = subproject('wlroots', default_options: ['examples=false'])
++if get_option('xwayland').enabled()
++ wlroots = subproject('wlroots', default_options: ['backends=drm,libinput,x11','examples=false','renderers=gles2','xcb-errors=disabled','xwayland=enabled'])
++else
++ wlroots = subproject('wlroots', default_options: ['backends=drm,libinput','examples=false','renderers=gles2','xcb-errors=disabled','xwayland=disabled'])
++endif
++
+ have_xwlr = wlroots.get_variable('features').get('xwayland')
+ xcb_dep = dependency('xcb', required: get_option('xwayland'))
+
diff --git a/gui-wm/hyprland/files/hyprland-0.28.0-no-wlroots-automagic.patch b/gui-wm/hyprland/files/hyprland-0.28.0-no-wlroots-automagic.patch
deleted file mode 100644
index 96b12fe497eb..000000000000
--- a/gui-wm/hyprland/files/hyprland-0.28.0-no-wlroots-automagic.patch
+++ /dev/null
@@ -1,14 +0,0 @@
-# Disable automagic, otherwise wlroots will enable features if dependencies are present.
-diff --git a/meson.build b/meson.build
-index 6a94dee6..9608717d 100644
---- a/meson.build
-+++ b/meson.build
-@@ -39,7 +39,7 @@ add_project_arguments(
- ],
- language: 'cpp')
-
--wlroots = subproject('wlroots', default_options: ['examples=false'])
-+wlroots = subproject('wlroots', default_options: ['backends=drm,libinput,x11','examples=false','renderers=gles2','xcb-errors=disabled'])
- have_xwlr = wlroots.get_variable('features').get('xwayland')
- xcb_dep = dependency('xcb', required: get_option('xwayland'))
-
diff --git a/gui-wm/hyprland/hyprland-0.28.0.ebuild b/gui-wm/hyprland/hyprland-0.28.0-r1.ebuild
index 5023065717c7..1da193f4e218 100644
--- a/gui-wm/hyprland/hyprland-0.28.0.ebuild
+++ b/gui-wm/hyprland/hyprland-0.28.0-r1.ebuild
@@ -18,7 +18,7 @@ IUSE="X legacy-renderer systemd video_cards_nvidia"
# bundled wlroots has the following dependency string according to included headers.
# wlroots[drm,gles2-renderer,libinput,x11-backend?,X?]
-# lets enable x11-backend by default
+# enable x11-backend with X and vice versa
WLROOTS_RDEPEND="
>=dev-libs/libinput-1.14.0:=
dev-libs/libliftoff
@@ -103,7 +103,7 @@ src_prepare() {
cd "${S}" || die
fi
- eapply "${FILESDIR}/hyprland-0.28.0-no-wlroots-automagic.patch"
+ eapply "${FILESDIR}/hyprland-0.28.0-no-wlroots-automagic-r1.patch"
default
}