[OpenIndiana-discuss] How to link to a specific SONAME, or Mesa libGL vs VBoxOGL
Jim Klimov
jimklimov at cos.ru
Fri Apr 22 09:25:07 UTC 2016
Hello all,
I've found that VirtualBox Guest Additions for Solaris hack the namespace of Mesa GL libraries, simply replacing /usr/lib/mesa/libGL.so.1 with a symlink to VBoxOGL.so. This causes mayhem in projects that link with -lGL because evidently the two GL libraries are not quite compatible. Even some projects built against true Mesa libGL.so.1 simply segfault when run in an environment where the path was hacked by guest additions (for details see https://github.com/OpenIndiana/oi-userland/pull/1689 with my take at integrating libGLEW). Otherwise by symlink derederence from /usr/lib/libGL.so the binary ends up with a reference to virtualbox libs that are not always available (and do not always work).
There are a few ways to go from here:
1) Get our GL-using binaries to link with /usr/lib/mesa/libGL.so (exactly, not .so.1) or .so.X.Y.Z to get the actual mesa libs always - but never e.g. the nvidia libs.
2) deliver our own vbox-gpl builds that properly integrate with e.g. ogl-select and never hack the system paths, as well as maybe we can ifdef a compatible set of opengl implementation (perhaps the OOB package from Oracle is geared towards Oracle Solaris and does work there).
Option 2) is interesting for its other merits, but imho 1) is more simple and will work also on systems where Oracle VBox is installed.
Any ideas how to get it done? Alan? ;)
Thanks,
Jim
--
Typos courtesy of K-9 Mail on my Samsung Android
More information about the openindiana-discuss
mailing list