Subject: Re: x11/gtk2 on FreeBSD
To: Lasse Kliemann <firstname.lastname@example.org>
From: Tilman Linneweh <email@example.com>
Date: 01/27/2005 12:45:02
* Lasse Kliemann [Sun, 23 Jan 2005 at 00:15 GMT]:
> configure:22619: checking for GLIB - version >=3D 2.6.0
> configure:22738: cc -o conftest -O2 -pthread -I/usr/pkg/include -D_THREAD_S=
> AFE -I/usr/include -I/usr/pkg/include/freetype2 -Wall -pthread -I/usr/pkg/i=
> nclude/glib/glib-2.0 -I/usr/pkg/lib/glib-2.0/include -DPREFIX=3D"\"/usr/p=
> kg\"" -I/usr/pkg/include -D_THREAD_SAFE -I/usr/include -I/usr/pkg/include/f=
> reetype2 -L/usr/pkg/lib -Wl,-R/usr/pkg/lib -pthread -L/usr/lib -Wl,-R/usr/l=
> ib -L/usr/pkg/xorg/lib -Wl,-R/usr/pkg/xorg/lib conftest.c -Wl,-R/usr/pkg/li=
> b -pthread -L/usr/pkg/lib -lgobject-2.0 -lgmodule-2.0 -lgthread-2.0 -lglib-=
> 2.0 -liconv -lintl -liconv -lpthread >&5
> configure:22741: $? =3D 0
> configure:22743: ./conftest
> Fatal error 'Spinlock called when not threaded.' at line 83 in file /usr/sr=
> c/lib/libpthread/thread/thr_spinlock.c (errno =3D 0)
> configure:22746: $? =3D 134
> configure: program exited with status 134
> configure: failed program was:
This error occurs if you are trying to link two different thread libraries
together. (As in libpthread, libc_r, libthr).
You can try to find out the offender with ldd on the shared libraries.
(libgthread-2.0 looks suspicious)
Did you update the machine from an older version (like 5.2.1)?
> I got a hint from Google to put these into /etc/libmap.conf:
> libc_r.so.5 libpthread.so.1
> libc_r.so libpthread.so
> It in fact resolved the error; x11/gtk2 is built now (didn't test it yet).
> Is this the right way to do it? If so, maybe we should document this?
> I haven't found anything appropriate in the list archives.
On FreeBSD we usually advise people to recompile all programs that use
threads after upgrading to 5.3, or use the libmap trick if they are lazy.