[Mesa-dev] [Bug 95079] GLX and OpenGL should be separated

bugzilla-daemon at freedesktop.org bugzilla-daemon at freedesktop.org
Mon Apr 25 16:05:40 UTC 2016


https://bugs.freedesktop.org/show_bug.cgi?id=95079

--- Comment #5 from Cédric Legrand <legrand.cedric.01 at gmail.com> ---
(In reply to Emil Velikov from comment #4)
> > I'm sorry if I'm wrong, I don't know a lot of things about OpenGL
> > implementation, but here are the facts:
> > * Wayland EGL won't create an OpenGL context. All OpenGL functions are NULL
> > when I try, only OpenGL ES is working. From the Wayland FAQ, this is because
> > Linux OpenGL implementation is bound to GLX
> > (https://wayland.freedesktop.org/faq.html#heading_toc_j_12).
> You can create OpenGL context with EGL as of version 1.2. The latter was
> released/specced in 2005... some 11 years ago ;-)

That's odd. I have already tried, it did not work in a Wayland context. I just
tried again to be sure, it seems to work this time. Maybe a mistake on my side,
sorry for the noise...

> > * Mesa is only providing a libGL for both APIs
> > * Nvidia is providing separated libraries with what seems to be a wrapper (I
> > think for the historical reasons you are talking about), as I described in
> > my first post.
> >
> Nvidia is shipping the alpha/beta version of the GLVND "library" (it's a
> collection of libraries as you can see).
> 
> > I must admit that I don't know if the problem comes from the standards, the
> > implementation or Wayland design, nor why exactly Nvidia did it this way.
> >
> Just google "GLVND XDC". The Nvidia folks have a few presentations on the
> topic.

Thanks for the enlightenment. I have already have a look at it but could not
find it anymore. It's easier with the right keywords.

> > By the way, as I see it, having them split would allow package maintainers
> > to provide a version of Mesa without libX11 dependency. At the moment,
> > libX11 is almost required, even on a Wayland/Mir system, but this will
> > become less and less the case over time, until the day both worlds will be
> > totally separated (and maybe X11 considered as deprecated).
> > Possible deprecation of libX11 and/or alike has nothing to do with using
> > OpenGL.
> >
> I would welcome that you familiarise yourself with how mesa is
> build/packaged. If done properly you can use wayland/mir/foo without
> anything X related. If you spot that something is stopping you - please open
> bugs reports. I gladly look into them.

Deprecation of libX11 is just speculation, but I think it will be one day or
another. In 10 years, maybe, but not tomorrow for sure.

> > This day, Mesa
> > maintainers would have to ship two versions of the package: a mesa-gl
> > without GLX, and a mesa-gl-compat with GLX, conflicting each other. With a
> > split, libGL would be either a symlink to libOpenGL or a wrapper around
> > libGLX and libOpenGL.
> > 
> So this is what brought you here. Distro maintainers, have shipped thing in
> a way that seems awkward/conflicting. I feel your pain... I was there so I
> had to move away to [a few] custom made packages years ago ;-)

Not 'have shipped', still ship. At least on Arch Linux, installing Mesa brings
Wayland and libX11, if you don't want one or the other, that's the same. The
only way to get rid of these dependencies on such distros is to rebuild Mesa
yourself. Looking at the built library reveals that libGL is linked against
libX11, making all binary distro suffer from the same problem. This is the
reason why I was posting.

> > > One can use OpenGL even if libGL is not present on the system
> > Seems difficult, isn't actually libGL the OpenGL provider?
> > 
> > As I said, I'm not turned into this, so I may be totally wrong. In this
> > case, I would appreciate to know what I got wrong.
> > 
> As said above - EGL can give you a OpenGL context.
> 
> > PS: I'm sorry if my English is not perfect, as my name stands I'm a
> > Frenchie...
> Your English is quite fine. If anything I might have made more mistakes.
> 
> TL;DR; It's being looked into. Rewriting ~70% on the mesa side and having to
> rework dozens of things within upstream GLVND takes some time.

I know Rome was not built in one day, as a developper myself I perfectly
understand this problem. This is just that I could not find anything on this
topic, but I was missing the right keywords. Thanks to have taken some time to
explain all this to me.

-- 
You are receiving this mail because:
You are the assignee for the bug.
You are the QA Contact for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/mesa-dev/attachments/20160425/8e56fecd/attachment.html>


More information about the mesa-dev mailing list