Fix PR1606:

The AC_CHECK_HEADER macro was used instead of AC_CHECK_HEADERS. The former does
not automatically add a #define to the configure variables while the latter
does. Consequently, the HAVE_PTHREAD_H symbol was not defined which caused the
Mutex.cpp file to compile to an empty implementation. 

llvm-svn: 41137
This commit is contained in:
Reid Spencer 2007-08-17 05:44:59 +00:00
parent 98f0790fab
commit 83bcd76596
2 changed files with 6 additions and 2 deletions

View File

@ -689,10 +689,11 @@ AC_HEADER_TIME
AC_CHECK_HEADERS([dlfcn.h execinfo.h fcntl.h inttypes.h limits.h link.h])
AC_CHECK_HEADERS([malloc.h setjmp.h signal.h stdint.h unistd.h utime.h])
AC_CHECK_HEADERS([windows.h sys/mman.h sys/param.h sys/resource.h sys/time.h])
AC_CHECK_HEADERS([windows.h])
AC_CHECK_HEADERS([sys/mman.h sys/param.h sys/resource.h sys/time.h])
AC_CHECK_HEADERS([sys/types.h malloc/malloc.h mach/mach.h])
if test "$ENABLE_THREADS" -eq 1 ; then
AC_CHECK_HEADER(pthread.h,
AC_CHECK_HEADERS(pthread.h,
AC_SUBST(HAVE_PTHREAD, 1),
AC_SUBST(HAVE_PTHREAD, 0))
else

View File

@ -282,6 +282,9 @@
/* Define to have the %a format string */
#undef HAVE_PRINTF_A
/* Define to 1 if you have the <pthread.h> header file. */
#undef HAVE_PTHREAD_H
/* Have pthread_mutex_lock */
#undef HAVE_PTHREAD_MUTEX_LOCK