main/postmarketos-ui-gnome: add firefox wayland config (MR 3008)

Add MOZ_ENABLE_WAYLAND=1 to make firefox not use xwayland in Gnome
This commit is contained in:
Martijn Braam 2022-03-16 00:43:19 +01:00 committed by Newbyte
parent 456cb2205f
commit 711d743a8e
No known key found for this signature in database
GPG key ID: 5873C171C9429CFA
2 changed files with 16 additions and 2 deletions

View file

@ -1,7 +1,7 @@
# Reference: https://postmarketos.org/uipkg
# Maintainer: Martijn Braam <martijn@brixit.nl>
pkgname=postmarketos-ui-gnome
pkgver=2
pkgver=3
pkgrel=0
pkgdesc="(Wayland) Gnome Shell"
url="https://gnome.org/"
@ -16,8 +16,14 @@ depends="
xwayland
"
install="$pkgname.post-install $pkgname.post-upgrade"
source="firefox-wayland.sh"
options="!check pmb:gpu-accel"
package() {
mkdir -p "$pkgdir"
install -Dm755 \
"$srcdir"/firefox-wayland.sh \
-t "$pkgdir"/etc/profile.d/
}
sha512sums="
0d9ec58be7dc354e181989c7f08e7d4dd93fefd06a99e784b87fe898479dd47a40dfa9689c6a63ebdc04bf87883a270686aec27f7cc34cb21ec0f370a4afe2d8 firefox-wayland.sh
"

View file

@ -0,0 +1,8 @@
#!/bin/sh
# Firefox does run with xwayland by default on Gnome, this setting
# makes it pick the wayland backend without setting GDK_BACKEND=wayland
# which causes more issues in the Gnome stack
if [ "$XDG_SESSION_TYPE" = "wayland" ]; then
export MOZ_ENABLE_WAYLAND=1
fi