The libGL built in the Mesa tree, via 'make linux-dri' and friends, is built without XTHREADS defined. Because of this, there is *NO* per-thread GLX context. Just grep for XTHREADS in src/glx/x11 for a good time. :(
Created attachment 2426 [details] [review] Patch to use pthreads or TLS for per-thread GLX context, version 01 Since everything else in the Mesa build uses either pthreads or TLS, this patch adds similar support to libGL for the per-thread GLX context. Also, glxext.c will give an error during compilation if THREADS is defined but PTHREADS or XTHREADS is not. If there are no supported platforms that don't support multithreading, then this should be changed from '#elif defined( THREADS )' to just '#else'. That is, libGL will require either PTHREADS or XTHREADS. I personally think that is the right way to go, but that change can be made later. This patch also removes the dependency on GLX_DIRECT_RENDERING for per-thread GLX context support. If there are no objections, I will commit this to Mesa CVS on 15-Apr-2005.
Fix committed to Mesa CVS.
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.