fix FreeBSD PTHREAD_LIBADD

Signed-off-by: Love Hornquist Astrand <lha@h5l.org>
This commit is contained in:
Joerg Pulz
2010-10-31 00:28:24 -07:00
committed by Love Hornquist Astrand
parent 501c5ac2fe
commit b1bbd18686

View File

@@ -12,10 +12,10 @@ case "$host" in
*-*-solaris2*) *-*-solaris2*)
native_pthread_support=yes native_pthread_support=yes
if test "$GCC" = yes; then if test "$GCC" = yes; then
PTHREADS_CFLAGS=-pthreads PTHREAD_CFLAGS=-pthreads
PTHREAD_LIBADD=-pthreads PTHREAD_LIBADD=-pthreads
else else
PTHREADS_CFLAGS=-mt PTHREAD_CFLAGS=-mt
PTHREAD_LDADD=-mt PTHREAD_LDADD=-mt
PTHREAD_LIBADD=-mt PTHREAD_LIBADD=-mt
fi fi
@@ -30,30 +30,27 @@ case "$host" in
dnl heim_threads.h knows this dnl heim_threads.h knows this
PTHREAD_LIBADD="-lpthread" PTHREAD_LIBADD="-lpthread"
;; ;;
*-*-freebsd[[56]]*) *-*-freebsd[[56789]]*)
native_pthread_support=yes native_pthread_support=yes
;; PTHREAD_LIBADD="-pthread"
*-*-freebsd[[789]]*)
native_pthread_support=yes
PTHREADS_LIBADD="-lpthread"
;; ;;
*-*-openbsd*) *-*-openbsd*)
native_pthread_support=yes native_pthread_support=yes
PTHREADS_CFLAGS=-pthread PTHREAD_CFLAGS=-pthread
PTHREAD_LIBADD=-pthread PTHREAD_LIBADD=-pthread
;; ;;
*-*-linux* | *-*-linux-gnu) *-*-linux* | *-*-linux-gnu)
case `uname -r` in case `uname -r` in
2.*) 2.*)
native_pthread_support=yes native_pthread_support=yes
PTHREADS_CFLAGS=-pthread PTHREAD_CFLAGS=-pthread
PTHREAD_LIBADD=-pthread PTHREAD_LIBADD=-pthread
;; ;;
esac esac
;; ;;
*-*-kfreebsd*-gnu*) *-*-kfreebsd*-gnu*)
native_pthread_support=yes native_pthread_support=yes
PTHREADS_CFLAGS=-pthread PTHREAD_CFLAGS=-pthread
PTHREAD_LIBADD=-pthread PTHREAD_LIBADD=-pthread
;; ;;
*-*-aix*) *-*-aix*)
@@ -84,14 +81,13 @@ if test "$enable_pthread_support" != no; then
dnl for libraries. dnl for libraries.
LIBS="$PTHREAD_LIBADD $LIBS" LIBS="$PTHREAD_LIBADD $LIBS"
else else
PTHREADS_CFLAGS="" PTHREAD_CFLAGS=""
PTHREAD_LIBADD="" PTHREAD_LIBADD=""
PTHREADS_LIBADD=""
fi fi
AC_SUBST(PTHREADS_CFLAGS) AC_SUBST(PTHREAD_CFLAGS)
AC_SUBST(PTHREAD_LDADD) AC_SUBST(PTHREAD_LDADD)
AC_SUBST(PTHREADS_LIBADD) AC_SUBST(PTHREAD_LIBADD)
AC_MSG_RESULT($enable_pthread_support) AC_MSG_RESULT($enable_pthread_support)
]) ])