0

When using the latest stable desktop environment, to enable features like screen share inside of video conference programs, and for stability, Wayland seems to work better than the ancient X.org.

I can use this command in the terminal

MOZ_ENABLE_WAYLAND=1 firefox

but how can I force Firefox ESR to always start in Wayland mode by default when the launcher is used, or simply by calling firefox from the terminal?

1 Answer 1

1

Tested in both Debian Stable (currently bullseye) and Debian Testing (currently bookworm)!

  1. Edit /usr/bin/firefox and merge the following

    #!/bin/sh                                                                                               
    
    FIREFOX="$(command -v firefox)"
    [ -x "$FIREFOX.real" ] && exec "$FIREFOX.real" "$@"
    
    exec env MOZ_ENABLE_WAYLAND=1 firefox-esr "$@"

This will force the binary to always start in Wayland mode (useful for calling firefox in the terminal)

  1. Edit /usr/share/applications/firefox-esr.desktop to make the Exec line

    Exec=env MOZ_ENABLE_WAYLAND=1 /usr/lib/firefox-esr/firefox-esr %u

This will ensure the launcher also starts the browser in Wayland mode.

2
  • Shouldn't this be reported as a bug? I'd expect the firefox-esr to run adaptively both under X11 and Wayland (with functional remoting for both cases; that is not the case now).
    – eudoxos
    Feb 22, 2022 at 8:50
  • @eudoxos I guess Debian's conservative philosophy of not changing it, they wont bother. Firefox obviously included the feature, but also probably wont want to change it because -esr is supposed to be super stable It works fine in xwayland mode, minus the fact you can't do something like share screen in Jitsi/Zoom type websites, and probably other I/O integration looks like we're stuck with this method for a while (I return to this question every time I reinstall OS on any computer) Aug 11, 2022 at 5:40

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .