Arch Linux

Please read this before reporting a bug:
https://wiki.archlinux.org/title/Bug_reporting_guidelines

Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.

REPEAT: Do NOT report bugs for outdated packages!
Tasklist

FS#80057 - [nvidia-utils] add flatpak extension

Attached to Project: Arch Linux
Opened by Andreas Schneider (aksdb) - Sunday, 22 October 2023, 20:14 GMT
Last edited by Sven-Hendrik Haase (Svenstaro) - Friday, 24 November 2023, 00:10 GMT
Task Type Feature Request
Category Packages: Extra
Status Closed
Assigned To Sven-Hendrik Haase (Svenstaro)
Felix Yan (felixonmars)
Architecture All
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

When using flatpak, some packages require GL or Vulkan support, which typically requires the accompanying packages to be installed on host _and_ in flatpak. In case of nvidia drivers that is quite ugly, since their blobs are quite large and installing them twice (or even four times when using 32bit) is quite excessive.

There is a better solution though. Flatpak allows the host system to create an extension (basically a definition of where to find what) which is then exposed to the flatpaks sandbox. This can be used to reuse the host nvidia libraries without having to install them another time. See also: https://blog.tingping.se/2018/08/26/flatpak-host-extensions.html

It would be nice having this either included with the nvidia package right away, or (preferably I guess) having a small optional package (nvidia-flatpak?) that includes the flatpak extension.
This task depends upon

Closed by  Sven-Hendrik Haase (Svenstaro)
Friday, 24 November 2023, 00:10 GMT
Reason for closing:  Won't fix
Additional comments about closing:  See my last comment. I'm not against this but I don't really see a unified story here for packages of this type and also I think this can easily be fixed by an auxiliary AUR package for users that desire this.
Comment by Toolybird (Toolybird) - Sunday, 22 October 2023, 21:01 GMT
You mean nvidia-utils? Providing a working and fully tested patch would give this a better chance of being implemented. Are you up for it?
Comment by Andreas Schneider (aksdb) - Sunday, 22 October 2023, 21:35 GMT
True, nvidia-utils would be the package in question, since it contains the userspace part.
Comment by Toolybird (Toolybird) - Monday, 23 October 2023, 06:10 GMT
AFAICT no other distro appears to have implemented this. And seeing as the Fedora proposal [1] never really went anywhere...the chances of this getting into Arch are pretty slim, especially without a patch/proof-of-concept. Flatpak PM also CC'd, but I wouldn't bank on this being implemented any time soon.

[1] https://github.com/negativo17/nvidia-driver/pull/57
Comment by Andreas Schneider (aksdb) - Monday, 23 October 2023, 07:14 GMT
Indeed I noticed that it didn't go anywhere with Fedora. I was made aware of this feature from [this comment](https://github.com/flatpak/flatpak/issues/2718#issuecomment-1686633136) by one of the flatpak contributors. So it seems like to be a feature that simply no one cared about so far (probably also because of "nvidia = bad" attitude).
Comment by Sven-Hendrik Haase (Svenstaro) - Sunday, 12 November 2023, 03:29 GMT
So basically this would just be a bunch of symlinks in a separate package for both nvidia-utils and lib32-nvidia-utils? We don't really do anything like this for any other packages. I'm not completely against it but this seems like it could easily be an AUR package unless I'm missing something.

Loading...