Closed Micket closed 5 months ago
Having gone through the code, I'm quite confident that glvnd considers the order of the library dirs first; and the listing fo the files inside the directories as a secondary sorting criteria.
This means that Mesa comes up first, even if /usr/share/glvnd/egl_vendor.d contains nvidia variants that you really want to use.
Just having Mesa append the directory instead of prepending would probably be an acceptable workaround for most systems.
Yes, I agree. One could also, on a per-use case override the _DIRS search order using an explicit list in __EGL_VENDOR_LIBRARY_FILENAMES
However, the problem then gets that if there is a system mesa installed that is the one being picked up and not ours...
I considered another option; patching glvnd, but, it's a pretty major patch but definitely possible.
Mesa easyconfigs have been appending this path for some time now. Fixed.
We currently set a few system paths (primarily for finding nvidia drivers), and we prepend Mesa's directory when it is loaded. Meaning we typically end up with e.g:
I haven't looked through the logic, but https://github.com/NVIDIA/libglvnd/blob/master/src/EGL/icd_enumeration.md makes me believe that perhaps we should append and not prepend Mesa's paths, to allow system nvidia to be used with higher priority?
In addition, with
glewinfo
(EGL variant) Mesa seems to want to use a nonexistent nouveau dri driver. Not sure how to even change that, but, we should make it use whatever is it's ownlib/dri
directory, which, at least for me case, is justswrast_dri.so
.