On March 13, 2021 04:18:26 Quentin SCHIBLER <quentin.schib...@bbox.fr> wrote:

GLVND depends on several X librairies. Does it means you cannot have OpenGL on wayland without X ?

Yes and no. libGL.so on Linux depends on X11 for historical reasons. The short version is that, long ago, libGL.so exposed all its symbols directly, including GLX symbols, and a dependency on X11. We've since learned better and any new/recentish entrypoints are only exposed via glGetProcAddress. Unfortunately, we can't really clean up they mess without breaking backwards compatibility.

With GLVND, we did do the next best thing. There is now a new libOpenGL.so which has a much reduced set of symbols and, IIRC, no X11 dependency. This means that it is possible to run desktop OpenGL without pulling in an X11 dependency, assuming the app is built to link against the new library.

More importantly than all that, however, is that your really shouldn't worry about the X11 dependency. If you have a pure Wayland app which uses OpenGL, it'll work fine. It might load Xlib or XCB into it's address space but that code will never be executed. The above are only really issues for people who are desperate to run a system without any X11 installed which, IMO, is a pretty pointless goal.

--Jason


Onn Mar 12, 2021 11:48 AM, Michel Dänzer <mic...@daenzer.net> wrote:

On 2021-03-11 12:14 a.m., Quentin SCHIBLER wrote:
I have built mesa with wayland platform, gbm and egl enabled, glx disabled, gles1 disabled and gles2 enabled. The build is successful, but I cannot find libGL.so. libGLES2.so is present, and GL includes files are also present.

libGL includes GLX APIs, so it cannot be built with -Dglx=false.

If you want to avoid GLX, you can use GLVND's libOpenGL instead.


--
Earthling Michel Dänzer               |               https://redhat.com
Libre software enthusiast             |             Mesa and X developer
_______________________________________________
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-dev

_______________________________________________
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-dev

Reply via email to