Gareth Edwards <gar...@edwardsfamily.org.uk> writes: > pthread.h defines timespec like this: > > #ifndef HAVE_STRUCT_TIMESPEC > #define HAVE_STRUCT_TIMESPEC 1 > struct timespec { > long tv_sec; > long tv_nsec; > }; > #endif /* HAVE_STRUCT_TIMESPEC */ > > So, presumably, configure tests for timespec, it doesn't have > HAVE_STRUCT_TIMESPEC set. Test passes, and then config.h then gets > > /* Define this if your system defines struct timespec via either <time.h> or > <pthread.h>. */ > #define HAVE_STRUCT_TIMESPEC 1
My belief is that this was fixed by commit d6818567553aafdbbbca327d4a1b1289a6816858: Fix MinGW HAVE_STRUCT_TIMESPEC build problem Reported by Carlo Bramini. See the comment in _scm.h. * THANKS: Add Carlo Bramini. * libguile/_scm.h: Undefine HAVE_STRUCT_TIMESPEC. Can you explain why this isn't working for you? Also, MinGW building of 1.8.x is successful for me; see the latest log at http://www.ossau.uklinux.net/guile/snapshots. > But now, when config.h is included before pthread.h, this has the > effect of hiding this declaration in the pthread.h file, so the guile > build breaks. threads.c includes config.h - which defines HAVE_STRUCT_TIMESPEC - then _scm.h - which undefines it - and then later pthread.h, so it should be fine. Regards, Neil