--- pthread.in.h.orig Tue Oct 23 10:19:34 2012 +++ pthread.in.h Sat Nov 3 18:37:43 2012 @@ -26,7 +26,9 @@ /* The include_next requires a split double-inclusion guard. */ #if @HAVE_PTHREAD_H@ -# @INCLUDE_NEXT@ @NEXT_PTHREAD_H@ +# ifdef USE_POSIX_THREADS +# @INCLUDE_NEXT@ @NEXT_PTHREAD_H@ +# endif #endif #ifndef address@hidden@_PTHREAD_H_ @@ -38,7 +40,7 @@ #include #include -#if ! @HAVE_PTHREAD_T@ +#if ! @HAVE_PTHREAD_T@ || ! defined(USE_POSIX_THREADS) # if !GNULIB_defined_pthread_types typedef int pthread_t; typedef int pthread_attr_t; @@ -97,7 +99,7 @@ #define PTHREAD_SCOPE_PROCESS 1 #endif -#if ! @HAVE_PTHREAD_T@ +#if ! @HAVE_PTHREAD_T@ || ! defined(USE_POSIX_THREADS) # if !GNULIB_defined_pthread_functions @@ -226,7 +228,7 @@ #endif -#if ! @HAVE_PTHREAD_SPINLOCK_T@ +#if ! @HAVE_PTHREAD_SPINLOCK_T@ || ! defined(USE_POSIX_THREADS) # if !GNULIB_defined_pthread_spinlock_t