pthread: work around winpthread header pollution on mingw
[gnulib.git] / lib / pthread.in.h
index a8438df..764b346 100644 (file)
 #include <stdlib.h>
 #undef __need_system_stdlib_h
 
+
+/* The pthreads-win32 <pthread.h> defines a couple of broken macros.  */
+#undef asctime_r
+#undef ctime_r
+#undef gmtime_r
+#undef localtime_r
+#undef rand_r
+#undef strtok_r
+
 #include <errno.h>
 #include <sched.h>
 #include <sys/types.h>