You are not logged in.

#1 2019-03-21 16:54:26

j1simon
Member
From: Denmark
Registered: 2016-01-28
Posts: 190

[SOLVED] Execute desktop file with env variable doesn't work

I'm trying to execute Firefox on Gnome Shell with environment variable "GDK_BACKEND=wayland".
I've duplicate the desktop file:

$ cp /usr/share/applications/firefox.desktop .local/share/applications

And I've edited all "Exec" lines to:

$ grep Exec .local/share/applications/firefox.desktop                 
Exec=env GDK_BACKEND=wayland /usr/lib/firefox/firefox %u
Exec=env GDK_BACKEND=wayland /usr/lib/firefox/firefox --new-window %u
Exec=env GDK_BACKEND=wayland /usr/lib/firefox/firefox --private-window %u

But when I execute Firefox (from Gnome dashboard), it ignores the environment variable.

It works when I execute "GDK_BACKEND=wayland /usr/lib/firefox/firefox" from commandline and if I execute .desktop file with dex.

What am I doing wrong?

Last edited by j1simon (2019-03-22 11:14:59)

Offline

#2 2019-03-22 06:44:33

jmsardev
Member
Registered: 2019-02-07
Posts: 12

Re: [SOLVED] Execute desktop file with env variable doesn't work

This happens to me to. But with FF66 there is a new environment variable you can set on login

export MOZ_ENABLE_WAYLAND=true

I put this on my .zprofile and it works (I still have some problems with Wayland Firefox and AMDGPU)

Offline

#3 2019-03-22 11:14:41

j1simon
Member
From: Denmark
Registered: 2016-01-28
Posts: 190

Re: [SOLVED] Execute desktop file with env variable doesn't work

Thanks, it works.
I put the environment variable in /etc/environment.

I have an Intel GPU and for the moment Firefox (Wayland) works well.

Offline

Board footer

Powered by FluxBB