From 6e2922444cfd0bfa4eca22ce69ae802942052bbe Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Kempf Date: Wed, 14 Apr 2010 15:57:44 +0200 Subject: [PATCH] Contribs: compile pthread on Win64 Signed-off-by: Jean-Baptiste Kempf --- extras/contrib/src/Makefile | 1 + extras/contrib/src/Patches/pthreads-win64.patch | 11 +++++++++++ 2 files changed, 12 insertions(+) create mode 100644 extras/contrib/src/Patches/pthreads-win64.patch diff --git a/extras/contrib/src/Makefile b/extras/contrib/src/Makefile index 69c1329073..a38c635c38 100644 --- a/extras/contrib/src/Makefile +++ b/extras/contrib/src/Makefile @@ -2333,6 +2333,7 @@ pthreads-w32-$(PTHREADS_VERSION)-release.tar.gz: pthreads: pthreads-w32-$(PTHREADS_VERSION)-release.tar.gz $(EXTRACT_GZ) (cd $@; patch -p0 < ../Patches/pthreads-detach.patch) + (patch -p0 < Patches/pthreads-win64.patch) .pthreads: pthreads (cd $<; $(HOSTCC) make $(PTHREADSCONF) GC GC-static && mkdir -p $(PREFIX)/include && cp -v pthread.h sched.h semaphore.h $(PREFIX)/include/ && mkdir -p $(PREFIX)/lib && cp -v *.a *.dll $(PREFIX)/lib/) diff --git a/extras/contrib/src/Patches/pthreads-win64.patch b/extras/contrib/src/Patches/pthreads-win64.patch new file mode 100644 index 0000000000..5bb8354faa --- /dev/null +++ b/extras/contrib/src/Patches/pthreads-win64.patch @@ -0,0 +1,11 @@ +--- pthreads/pthread.h 2006-01-24 14:59:57.000000000 +0100 ++++ pthreads.new/pthread.h 2010-04-14 15:49:39.000000000 +0200 +@@ -302,7 +302,7 @@ + #endif + #endif + +-#ifndef HAVE_STRUCT_TIMESPEC ++#if !defined( HAVE_STRUCT_TIMESPEC ) && !defined( _TIMESPEC_DEFINED ) + #define HAVE_STRUCT_TIMESPEC 1 + struct timespec { + long tv_sec; -- 2.39.2