* Emiel Kollof ([EMAIL PROTECTED]) wrote: > On Friday 20 December 2002 03:05, Emiel Kollof wrote: > > > % gcc -o gtktest gtktest.c `gtk12-config --libs` `gtk12-config --cflags` > > /usr/X11R6/lib/libX11.so: undefined reference to `pthread_cond_signal' > > /usr/X11R6/lib/libXThrStub.so.6: undefined reference to `_Xthr_zero_stub_' > > /usr/X11R6/lib/libX11.so: undefined reference to `pthread_cond_broadcast' > > /usr/X11R6/lib/libXThrStub.so.6: undefined reference to `_Xthr_self_stub_' > > It seems that XThrStub is causing problems. Even after a recompile of > XFree86-4-libraries the problems still occur. What do I do now? I'm stuck.
I filed a pr with number 46387. Even forcibly compiling stuff with -pthread doesn't solve my problems. It seems that there is something wicked is going on in XThrStub. When looking at the source, I find strange #pragma preprocessor commands of which I'm not sure what they are supposed to do. They involve _Xthr_zero_stub_ and Xthr_self_stub_ and somehow they don't seem to be present in the library symbols. I googled around for a bit, and it seems that this has happened before and was a problem in XFree86-4. It's not really clear what the problem was, but it seems to have resurfaced. Is nobody seeing what I'm seeing, or am I alone here? Please, anyone try this snippet of code: (yes, it's the same as I submitted in the PR) --- test.c --- char XOpenDisplay{}; int main() { XOpenDisplay(); return 0; } --- end test.c --- Compile as follows: gcc -o test test.c -L /usr/X11R6/lib -pthread -lX11 If you see this: azazel# gcc -o test test.c -L /usr/X11R6/lib -pthread -lX11 /usr/X11R6/lib/libXThrStub.so.6: undefined reference to `_Xthr_zero_stub_' /usr/X11R6/lib/libXThrStub.so.6: undefined reference to `_Xthr_self_stub_' your system has the same problems as I do. Also, somehow I doubt that *every* X11 program needs -pthread or -lc_r. Cheers, Emiel -- Miss, n.: A title with which we brand unmarried women to indicate that they are in the market. -- Ambrose Bierce, "The Devil's Dictionary" To Unsubscribe: send mail to [EMAIL PROTECTED] with "unsubscribe freebsd-stable" in the body of the message