Subject: Re: FreeBSD and "Spinlock called when not threaded" and arts and
To: Juan RP <>
From: Jeremy C. Reed <>
List: tech-pkg
Date: 05/04/2005 10:44:45
On Wed, 4 May 2005, Juan RP wrote:

> > But the pkgsrc/glib2/Makefile says:
> >
> > # FreeBSD fix for libgthread:
> > # Be sure libgthread is linked to the threaded library (libc_r), otherwise
> > # -pthread is added and this won't work with libraries, only executable
> > # binaries.
> >
> > Any ideas about this?
> >
> > Is the above FreeBSD fix applicable for FreeBSD 5.3 or is it for FreeBSD
> > -current or FreeBSD 4.x??
> This was necessary for FreeBSD >= 5.2 if I remember correctly, maybe
> libpthread has to be used again?
> (Haven't used FreeBSD in long time).

I commented out your FreeBSD patching for threads and reinstalled glib2
and then arts finished compiling fine.

I am looking closer at FreeBSD. FreeBSD does with the ports:

.if ${OSVERSION} < 500016
PTHREAD_LIBS?=          -pthread
.elif ${OSVERSION} < 502102
PTHREAD_LIBS?=          -lc_r
PTHREAD_LIBS?=          -pthread

where OSVERSION is "sysctl -n kern.osreldate"

I think that pkgsrc/mk/ or
pkgsrc/mk/ can be improved so the workaround in
devel/glib2/Makefile can be removed.

 Jeremy C. Reed

 	  	 	 BSD News, BSD tutorials, BSD links