[Buildroot] [RFC 2/3] rpi-userland: fix opengl library symlinks

Gaël PORTAY gael.portay at savoirfairelinux.com
Tue Apr 11 16:30:21 UTC 2017


Hi Thomas,

On Sat, Mar 25, 2017 at 03:25:07PM +0100, Thomas Petazzoni wrote:
> Hello,
> 
> On Wed, 22 Mar 2017 18:51:04 -0400, Gaël PORTAY wrote:
> 
> > > Ah, it uses dlopen() on specifically libEGL.so.1 and libOpenGLES.so.2,
> > > OK. Then it makes sense. Maybe your patch should be submitted upstream
> > > to rpi-userland?  
> > 
> > I am on it.
> > 
> > I made a PR on github.
> 
> As was said in https://github.com/raspberrypi/userland/pull/379, the PR
> you have submitted changes the SONAME of the library, so any binary
> already built against rpi-userland before your change will no longer
> work after your change. Your suggestion to run ldconfig is irrelevant.
> 

Okay.

I wanted to make sure about the 'No such file or directory' message. I would
expect a kind of 'Invalid' message instead.

> When you link against a library, the SONAME of this library gets
> encoded into a NEEDED entry of the thing (program or library) that
> links against this library. Then at runtime, the dynamic loader goes
> through those NEEDED entries to load the shared libraries that the
> program needs. So if the NEEDED entry of a program no longer points to
> an existing library, you broke binary compatibility.
> 

Thanks very much for this clarification about the SONAME and NEEDED entry.

I thought it was based on filenames only, and I was wrong.

> So maybe we simply need some symbolic links to be created:
> 
>  libEGL.so.1 -> libEGL.so
>  libGLES.so.2 -> libGLES.so
> 

I submitted a new PR that creates symlinks.

I was the initial solution :)

> This way, qt5webengine will be able to find the EGL/OpenGLES
> implementation, but the rpi-userland libraries SONAME remains the same.
> 
> Best regards,
> 
> Thomas
> -- 
> Thomas Petazzoni, CTO, Free Electrons
> Embedded Linux and Kernel engineering
> http://free-electrons.com
> _______________________________________________
> buildroot mailing list
> buildroot at busybox.net
> http://lists.busybox.net/mailman/listinfo/buildroot

Regards,
Gaël


More information about the buildroot mailing list