1 dnl ** Additional Autoconf tests for BIRD configure script
2 dnl ** (c) 1999 Martin Mares <mj@ucw.cz>
4 AC_DEFUN([BIRD_CHECK_PTHREADS],
6 bird_tmp_cflags="$CFLAGS"
7 CFLAGS="$CFLAGS -pthread"
10 [whether POSIX threads are available],
11 [bird_cv_lib_pthreads],
16 [ #include <pthread.h> ],
19 pthread_create(&pt, NULL, NULL, NULL);
20 pthread_spinlock_t lock;
21 pthread_spin_lock(&lock);
25 [bird_cv_lib_pthreads=yes],
26 [bird_cv_lib_pthreads=no]
31 CFLAGS="$bird_tmp_cflags"
34 AC_DEFUN([BIRD_CHECK_GCC_OPTION],
36 bird_tmp_cflags="$CFLAGS"
40 [whether CC supports $2],
51 CFLAGS="$bird_tmp_cflags"
54 AC_DEFUN([BIRD_ADD_GCC_OPTION],
56 if test "$$1" = yes ; then
61 # BIRD_CHECK_PROG_FLAVOR_GNU(PROGRAM-PATH, IF-SUCCESS, [IF-FAILURE])
62 # copied from autoconf internal _AC_PATH_PROG_FLAVOR_GNU
63 AC_DEFUN([BIRD_CHECK_PROG_FLAVOR_GNU],
66 case `"$1" --version 2>&1` in