if test x"$acx_pthread_ok" = xno; then
for flag in $acx_pthread_flags; do
+ tryPTHREAD_CFLAGS=""
+ tryPTHREAD_LIBS=""
case $flag in
none)
AC_MSG_CHECKING([whether pthreads work without any flags])
[pthread_t th; pthread_join(th, 0);
pthread_attr_init(0); pthread_cleanup_push(0, 0);
pthread_create(0,0,0,0); pthread_cleanup_pop(0); ],
- [acx_pthread_ok=yes])
+ [acx_pthread_ok=yes], [acx_pthread_ok=no])
LIBS="$save_LIBS"
CFLAGS="$save_CFLAGS"
PTHREAD_LIBS=" $tryPTHREAD_LIBS $PTHREAD_LIBS"
PTHREAD_CFLAGS="$PTHREAD_CFLAGS $tryPTHREAD_CFLAGS"
fi
-
done
fi
if test x"$acx_pthread_ok" = xno; then
for flag in $acx_pthread_flags; do
+ tryPTHREAD_CFLAGS=""
+ tryPTHREAD_LIBS=""
case $flag in
none)
echo "$as_me:$LINENO: checking whether pthreads work without any flags" >&5
else
echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
+acx_pthread_ok=no
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
PTHREAD_LIBS=" $tryPTHREAD_LIBS $PTHREAD_LIBS"
PTHREAD_CFLAGS="$PTHREAD_CFLAGS $tryPTHREAD_CFLAGS"
fi
-
done
fi