[Mesa-users] ARB_shader_subroutine functions - no static linking?

Yury Voronov yvoronov at artec-group.com
Tue Aug 13 11:01:37 UTC 2019


Hello,

I wonder, how to make functions like glGetSubroutineIndex() and
glUniformSubroutinesuiv() statically linkable with libGL.so ?

My working machine is 18.04, and I work with Mesa 19.1.4 witg gcc-7 and llvm-7.

The matter is, when I compile Mesa myself, there are no those
functions exported from libGL.so, though _mesa_GetSubroutineIndex()
and _mesa_UniformSubroutinesuiv() are there. However, when I install
mesa form Ubuntu repositories, those functions are there.

Deep investigation reveals that there is a file
src/mapi/glapi/gen/static_data.py with two lists - 'offsets' and
'functions'; and the second 'functions' list contains all functions to
be statically exported; and those functions are not in this list.

The question is - why? What is the proper way to include them in the
'functions' list? Or shouls I make a patch?

Thanks,
Yury


More information about the mesa-users mailing list