link with pthread explicitly

This commit is contained in:
unK
2008-10-15 21:37:30 +02:00
parent c672e87655
commit 6a0edcfbd7

View File

@@ -1,7 +1,7 @@
AC_INIT(configure.in)
AM_CONFIG_HEADER(config.h)
AM_INIT_AUTOMAKE(ncmpcpp, 0.2.4)
AM_INIT_AUTOMAKE(ncmpcpp, 0.2.5_pre)
AC_PREREQ(2.59)
@@ -34,10 +34,12 @@ else
fi
AC_CHECK_HEADERS([ncurses.h], , AC_MSG_ERROR([missing ncurses.h header]))
dnl =====================
dnl = checking for curl =
dnl =====================
dnl =================================
dnl = checking for curl and pthread =
dnl =================================
if test "$curl" = "yes" ; then
AC_CHECK_LIB(pthread, pthread_create, LDFLAGS="$LDFLAGS -pthread", AC_MSG_ERROR([pthread library is required]))
AC_CHECK_HEADERS([pthread.h], , AC_MSG_ERROR([missing pthread.h header]))
AC_PATH_PROG(CURL_CONFIG, curl-config)
if test "$CURL_CONFIG" != "" ; then
CPPFLAGS="$CPPFLAGS `$CURL_CONFIG --cflags`"