[Mesa-dev] [PATCH 2/2] megadriver: explicitly link against glapi, link with -no-undefined

Emil Velikov emil.l.velikov at gmail.com
Thu Nov 6 05:09:50 PST 2014

Hi Frank,

On 31/10/14 01:11, Frank Henigman wrote:
> I was too hasty with my "Tested-by."  While it worked in a
> shared-glapi configuration, it broke the build with the following:
> ./configure --prefix=/usr --build=x86_64-pc-linux-gnu
> --host=x86_64-cros-linux-gnu --mandir=/usr/share/man
> --infodir=/usr/share/info --datadir=/usr/share --sysconfdir=/etc
> --localstatedir=/var/lib --libdir=/usr/lib64
> --disable-dependency-tracking --disable-option-checking
> --with-driver=dri --disable-glu --disable-glut --without-demos
> --enable-texture-float --disable-dri3 --disable-llvm-shared-libs
> --enable-glx --enable-llvm-gallium --disable-egl --disable-gbm
> --disable-gles1 --disable-gles2 --disable-shared-glapi
> --disable-gallium --enable-debug --enable-glx-tls --enable-asm
> --disable-xlib-glx --enable-dri --with-dri-drivers=i965
> --with-gallium-drivers=
> the output is:
> ...
> make[5]: Entering directory
> `/build/lumpy/tmp/portage/media-libs/mesa-10.3-r11/work/Mesa-10.3/src/mesa/drivers/dri'
>   CXXLD  mesa_dri_drivers.la
> ../../../../src/mapi/glapi/.libs/libglapi.a(glapi_libglapi_la-glapi_getproc.o):glapi_getproc.c:static_functions:
> error: undefined reference to 'glAreTexturesResidentEXT'
> ../../../../src/mapi/glapi/.libs/libglapi.a(glapi_libglapi_la-glapi_getproc.o):glapi_getproc.c:static_functions:
> error: undefined reference to 'glDeleteTexturesEXT'
> ...
Indeed. static-glapi does not get too much testing, plus it seems that
it's broken (in a way) for a loooong time.
It seems that we'll have to (temporary) resolve with shoving
dlopen(libglapi.so) into gbm, so that in time programs can nuke it from
their codebase. glapi is internal (implementation) detail that they
should not need to bother/know.


More information about the mesa-dev mailing list