--- configure.in~ Sat Jun 15 01:01:30 2002 +++ configure.in Mon Aug 12 00:01:01 2002 @@ -47,8 +47,21 @@ AC_FUNC_VPRINTF AC_CHECK_FUNCS(ftime getcwd gethostid getpagesize gettimeofday getwd qsort scandir setlocale strstr strchr valloc vsnprintf) -PTHREAD_LIBS=-lpthread -ACX_PTHREAD() +dnl Checks for libpthreads +AC_ARG_WITH(pthreads, + AC_HELP_STRING([--with-pthreads],[Use pthreads.]), [ + if test "$withval" = "yes" ; then + INCLUDEPTHREAD=1 + else + INCLUDEPTHREAD=0; + fi ],[INCLUDEPTHREAD=1]) + +if test "$INCLUDEPTHREAD"=1 ; then + AC_CHECK_LIB(pthread,pthread_mutex_init, + [LDFLAGS="$LDFLAGS -pthread"], + [AC_MSG_ERROR(****Library not found: -pthread****)]) + AC_DEFINE(HAVE_PTHREAD) +fi dnl Figure out how to reference 64-bit unsigned integers AC_CHECK_TYPE(u_int64_t, long long)