commit:     83b7b26d11695034f09482b389e1da0da6d09b19
Author:     Jon Janzen <jon <AT> jonjanzen <DOT> com>
AuthorDate: Thu Jun  6 02:25:24 2024 +0000
Commit:     Nick Sarnie <sarnex <AT> gentoo <DOT> org>
CommitDate: Mon Jun 24 22:12:50 2024 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=83b7b26d

net-im/discord: Add wayland support

Discord appears to support wayland when launched with these options, it
just needs to be enabled manually.

Signed-off-by: Jon Janzen <jon <AT> jonjanzen.com>
Closes: https://github.com/gentoo/gentoo/pull/37043
Signed-off-by: Nick Sarnie <sarnex <AT> gentoo.org>

 .../discord/{discord-0.0.57.ebuild => discord-0.0.57-r1.ebuild}   | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/net-im/discord/discord-0.0.57.ebuild 
b/net-im/discord/discord-0.0.57-r1.ebuild
similarity index 93%
rename from net-im/discord/discord-0.0.57.ebuild
rename to net-im/discord/discord-0.0.57-r1.ebuild
index fefed5b524d7..e7dde173394c 100644
--- a/net-im/discord/discord-0.0.57.ebuild
+++ b/net-im/discord/discord-0.0.57-r1.ebuild
@@ -23,7 +23,7 @@ LICENSE="all-rights-reserved"
 SLOT="0"
 KEYWORDS="amd64"
 
-IUSE="appindicator +seccomp"
+IUSE="appindicator +seccomp wayland"
 RESTRICT="bindist mirror strip test"
 
 RDEPEND="
@@ -85,6 +85,12 @@ src_prepare() {
        sed -i "/Exec/s:/usr/share/discord/Discord:${DESTDIR}/${MY_PN^}:" \
                "${MY_PN}.desktop" ||
                die "fixing of exec location on .desktop failed"
+       # USE wayland
+       if use wayland; then
+               sed -i '/Exec/s/Discord/Discord 
--enable-features=UseOzonePlatform --ozone-platform=wayland/' \
+                       "${MY_PN}.desktop" ||
+                       die "sed failed for wayland"
+       fi
        # USE seccomp
        if ! use seccomp; then
                sed -i '/Exec/s/Discord/Discord 
--disable-seccomp-filter-sandbox/' \

Reply via email to