[Python-checkins] python/dist/src/Python thread.c,2.50,2.51

doko at users.sourceforge.net doko at users.sourceforge.net
Mon Aug 16 13:35:53 CEST 2004


Update of /cvsroot/python/python/dist/src/Python
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv20417/Python

Modified Files:
	thread.c 
Log Message:
The attached patch fixes FTBFS on GNU/k*BSD.  The problem happens on GNU/k*BSD
because GNU/k*BSD uses gnu pth to provide pthreads, but will also happen on any
system that does the same.

python fails to build because it doesn't detect gnu pth in pthread
emulation. See C comments in patch for details.

patch taken from http://bugs.debian.org/264315


Index: thread.c
===================================================================
RCS file: /cvsroot/python/python/dist/src/Python/thread.c,v
retrieving revision 2.50
retrieving revision 2.51
diff -C2 -d -r2.50 -r2.51
*** thread.c	10 Feb 2004 16:50:20 -0000	2.50
--- thread.c	16 Aug 2004 11:35:51 -0000	2.51
***************
*** 8,11 ****
--- 8,21 ----
  #include "Python.h"
  
+ 
+ #ifndef _POSIX_THREADS
+ /* This means pthreads are not implemented in libc headers, hence the macro
+    not present in unistd.h. But they still can be implemented as an external
+    library (e.g. gnu pth in pthread emulation) */
+ # ifdef HAVE_PTHREAD_H
+ #  include <pthread.h> /* _POSIX_THREADS */
+ # endif
+ #endif
+ 
  #ifndef DONT_HAVE_STDIO_H
  #include <stdio.h>



More information about the Python-checkins mailing list