On Wed, Mar 14, 2001 at 11:39:16PM -0800, Doug Barton wrote:
> The other hack I'm trying to get rid of is in the Makefile:
>
> post-patch:
> @ ${CP} ${WRKSRC}/configure ${WRKSRC}/configure.Patched
> @ ${SED} -e 's#-lpthread#-pthread#g' \
> ${WRKSRC}/configure.Patched > ${WRKSRC}/configure
I haven't looked at xscreensaver's configure.in file, but you could
find the location of the pthread library with something like this:
PTHREAD_LIBS=error
dnl The Linux case:
AC_CHECK_LIB(pthread, pthread_attr_init, [
PTHREAD_CFLAGS="$PTHREAD_CFLAGS -D_REENTRANT"
PTHREAD_LIBS="-lpthread" ])
dnl The FreeBSD case:
if test "x$PTHREAD_LIBS" = xerror; then
AC_CHECK_LIB(c_r, pthread_attr_init, [
PTHREAD_CFLAGS="$PTHREAD_CFLAGS -D_THREAD_SAFE"
PTHREAD_LIBS="-pthread" ])
fi
if test "x$PTHREAD_LIBS" = xerror; then
AC_CHECK_FUNC(pthread_attr_init, PTHREAD_LIBS="",
AC_MSG_ERROR(not found library: pthread !!!))
fi
Then of course you'd have to regenerate configure with autoconf.
HTH.
-past
To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message