summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--firefox.sh.in5
-rw-r--r--firefox.spec19
2 files changed, 21 insertions, 3 deletions
diff --git a/firefox.sh.in b/firefox.sh.in
index 6fc51b2..ca121a0 100644
--- a/firefox.sh.in
+++ b/firefox.sh.in
@@ -70,10 +70,13 @@ GETENFORCE_FILE="/usr/sbin/getenforce"
##
## Enable Wayland backend?
##
-if __DEFAULT_WAYLAND__ && ! [ $MOZ_DISABLE_WAYLAND ]; then
+if ! [ $MOZ_DISABLE_WAYLAND ]; then
if [ "$XDG_CURRENT_DESKTOP" == "GNOME" ]; then
export MOZ_ENABLE_WAYLAND=1
fi
+ if __DEFAULT_WAYLAND__ && [ "$XDG_SESSION_TYPE" = "wayland" ]; then
+ export MOZ_ENABLE_WAYLAND=1
+ fi
fi
##
diff --git a/firefox.spec b/firefox.spec
index 4defa6e..8717a8d 100644
--- a/firefox.spec
+++ b/firefox.spec
@@ -20,6 +20,12 @@
%global test_offscreen 1
%global test_on_wayland 0
+# Enable Wayland on all Wayland compositors (Gnome/KDE/Sway) by default.
+%global default_wayland 0
+%if 0%{?fedora} > 33
+%global default_wayland 1
+%endif
+
# There are still build problems on s390x, see
# https://koji.fedoraproject.org/koji/taskinfo?taskID=55048351
# https://bugzilla.redhat.com/show_bug.cgi?id=1897522
@@ -163,7 +169,7 @@ ExcludeArch: armv7hl
Summary: Mozilla Firefox Web browser
Name: firefox
Version: 85.0
-Release: 7%{?pre_tag}%{?dist}
+Release: 8%{?pre_tag}%{?dist}
URL: https://www.mozilla.org/firefox/
License: MPLv1.1 or GPLv2+ or LGPLv2+
Source0: https://archive.mozilla.org/pub/firefox/releases/%{version}%{?pre_version}/source/firefox-%{version}%{?pre_version}.source.tar.xz
@@ -776,7 +782,12 @@ desktop-file-install --dir %{buildroot}%{_datadir}/applications %{SOURCE29}
# set up the firefox start script
%{__rm} -rf %{buildroot}%{_bindir}/firefox
-%{__sed} -e 's/__DEFAULT_WAYLAND__/true/' \
+%{__sed} \
+%if %{?default_wayland}
+ -e 's/__DEFAULT_WAYLAND__/true/' \
+%else
+ -e 's/__DEFAULT_WAYLAND__/false/' \
+%endif
-e 's,/__PREFIX__,%{_prefix},g' %{SOURCE21} > %{buildroot}%{_bindir}/firefox
%{__chmod} 755 %{buildroot}%{_bindir}/firefox
@@ -1024,6 +1035,10 @@ gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
#---------------------------------------------------------------------
%changelog
+* Sat Jan 30 2021 Martin Stransky <stransky@redhat.com> - 85.0-8
+- Enable Wayland backend on Fedora 34/KDE/Plasma (and other compositors)
+ by default (https://bugzilla.redhat.com/show_bug.cgi?id=1922608).
+
* Fri Jan 29 2021 Martin Stransky <stransky@redhat.com> - 85.0-7
- Added clipboard fix mozbz#1631061.
bgstack15