New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
With --filesystem=host, XDG_DATA_DIRS doesn't include /run/host/usr/share #1299
Comments
You just make a wrapper script to set dynamic env vars. Personally I don't think this is behavior that should be used in practice, host state is exactly what Flatpaks shouldn't be using, |
The goal is to make Devhelp-Flatpak a bit more useful in the current state of the Devhelp implementation. It can require a lot of work (relative to the size of Devhelp) to make Devhelp a first-class Flatpak citizen. It'll still probably take several years. When I set --filesystem=host, I expect Flatpak to automatically adjust XDG_DATA_DIRS to add /run/host/usr/share. |
In the narrow case of Devhelp |
Yeah, i understand where you're coming from, but all sorts of things will break if we add all host config to each app, which is totally opposite to the entire point of flatpak. That said, if you verify that it works for your app then you can have a wrapper script that sets up the right env vars. But, i don't thing XDG_DATA_DIRS is the right thing, because all sorts of libraries will start reading files from there, like dconf, dbus, service files, mimetypes, etc. It would be preferable to have something that targeted just gtk-doc files. |
OK, thanks for your answers. It's easy in Devhelp to add more hard-coded directories, and this can be done with a compile-time configuration option (--enable-flatpak for example). |
Context: I'm trying to make Devhelp work with Flatpak, to see the API docs installed by traditional Linux distro packages, see:
https://bugzilla.gnome.org/show_bug.cgi?id=792068
If --filesystem=host is added to the flatpak build-finish args, then the documentation which is available on the host in /usr/share/gtk-doc/html/, is available inside the Flatpak sandbox in /run/host/usr/share/gtk-doc/html/.
But when --filesystem=host is specified, XDG_DATA_DIRS inside Flatpak doesn't include /run/host/usr/share.
I've tried adding
--env=XDG_DATA_DIRS=$XDG_DATA_DIRS:/run/host/usr/share
to the build-finish args, but $XDG_DATA_DIRS is taken literally as a string, not a variable. The flatpak-build-finish manpage doesn't explain how to add a directory to an environment variable like XDG_DATA_DIRS.The text was updated successfully, but these errors were encountered: