[Pkg-utopia-maintainers] Bug#927907: flatpak directories not added to XDG_DATA_DIRS on Plasma + Wayland

Simon McVittie smcv at debian.org
Fri Aug 30 08:17:47 BST 2019


Control: retitle -1 flatpak directories not added to XDG_DATA_DIRS on Plasma + Wayland

On Thu, 25 Apr 2019 at 00:10:51 +0300, Ioan Eugen Stan wrote:
> Note that the directories
> 
> '/var/lib/flatpak/exports/share'
> '/home/ieugen/.local/share/flatpak/exports/share'
> 
> are not in the search path set by the XDG_DATA_DIRS environment variable
...
> I switched to Plasma under Wayland recently, don't know if it is important.

This presumably means your session startup won't source
/etc/X11/Xsession.d/20flatpak like an X11 session would. GNOME in Wayland
mode doesn't do that either, so at least they're consistent.

Setting environment variables during session startup is, unfortunately,
still a bit of a mess. Flatpak tries to add its directories to
XDG_DATA_DIRS in several ways:

- /etc/X11/Xsession.d/20flatpak (X11-specific)
- /etc/profile.d/flatpak.sh (shell-specific)
- /usr/share/gdm/env.d/flatpak.env (GNOME/GDM-specific)

but apparently Plasma in Wayland mode doesn't use any of those.

Perhaps the answer is for Flatpak to have a systemd environment generator,
systemd.environment-generator(7), instead of or in addition to the
hooks we currently have? That would leave out sysvinit users, but that
isn't necessarily a huge problem, because they probably aren't using
Wayland anyway.

Or if there is a Plasma-specific mechanism similar to the GDM-specific
/usr/share/gdm/env.d (which is used by GNOME in Wayland mode) then
Flatpak could use that too, but I'd need details of that mechanism.

    smcv



More information about the Pkg-utopia-maintainers mailing list