On 7/24/12 1:45 PM, Ian Romanick wrote:
On 07/23/2012 12:59 PM, Ian Romanick wrote:
Perhaps someone can refresh my memory as to what exactly this option
does?  Can we make this the default and remove the option from configure?

Thanks to all for the refresher.  Off-list someone raised another issue
to me that seems like a deal breaker.  If an application links with a
libGL that uses libglapi it appears that the application gets implicitly
linked with libglapi (as shown by objdump -x | grep -i need).

This part is actually dependent on whether the app is built with --copy-dt-needed-entries. Historically that's been the default, but most modern distros have switched to --no-copy-etc, in which case the app will _not_ get a DT_NEEDED on libglapi just for linking against libGL. This is good; apps shouldn't be made accidentally fragile based on implementation details of the libraries they link against. But it does require a modestly recent linker with that option, or with it under the old spelling of --no-add-needed.

This will
cause the application to fail if a non-glapi libGL (i.e., any of the
closed-source drivers) is later installed.  The problem seems to be that
symbols like glBegin are in libglapi.

That doesn't jive with what my linker says, at least looking at an F16 machine:

atropine:~% nm -aD --defined /usr/lib/libglapi.so
0002f060 A __bss_start
0002f060 A _edata
0002fcf4 A _end
000178a8 T _fini
0002fcf0 B _glapi_Context
0002f05c D _glapi_Dispatch
00016d60 T _glapi_add_dispatch
00016cd0 T _glapi_check_multithread
00017420 T _glapi_get_context
00017600 T _glapi_get_dispatch
00016d50 T _glapi_get_dispatch_table_size
00016f80 T _glapi_get_proc_address
00017000 T _glapi_get_proc_name
00016f00 T _glapi_get_proc_offset
00017030 T _glapi_noop_enable_warnings
00016cf0 T _glapi_set_context
00016d20 T _glapi_set_dispatch
00017040 T _glapi_set_warning_func
00017010 T _glthread_GetID
00004ef8 T _init

That's all libGL-to-dispatch bridging, it's not app API. There's no reason the app would need a DT_NEEDED against libglapi.

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

Reply via email to