Am Mittwoch, den 03.01.2018, 20:33 +0100 schrieb Bruno Haible: > Hi Tim, > > > I currently see during MinGW build: > > > > CC fatal-signal.lo > > In file included from /usr/share/mingw-w64/include/signal.h:10:0, > > from ./signal.h:52, > > from fatal-signal.c:26: > > ./signal.h:593:1: error: expected identifier or '(' before numeric > > constant > > _GL_FUNCDECL_SYS (pthread_sigmask, int, > > ^ > > > > Any idea what is going on here, it's in the gnulib area ? > > The usual tips for such an error: > > 1) Does it still occur after you did "make distclean", then > reconfigure > and "make"? > > 2) Use CC="gcc -no-integrated-cpp" to get higher quality diagnostics > from GCC. > > 3) Run "make V=1" to see the actual compilation command line. [1] > Then modify that command line to add -E instead of -c -o options, > and > redirect that preprocessor output to a file. Analyze it.
The problem stays (I am now on a second machine, but same system Debian unstable). After stripping off the compiler options, the command line is x86_64-w64-mingw32-gcc-win32 -DHAVE_CONFIG_H -I. -I.. -I/home/tim/src/wget2/x86_64-w64-mingw32/include -no-integrated-cpp -DNDEBUG -fno-PIC -MT fatal-signal.lo -MD -MP -MF .deps/fatal- signal.Tpo -c fatal-signal.c -DDLL_EXPORT -DPIC -o .libs/fatal- signal.o In the -E output there is # 593 "./signal.h" 3 extern int 0 ; Line #593-594 in signal.h is: _GL_FUNCDECL_SYS (pthread_sigmask, int, (int how, const sigset_t *new_mask, sigset_t *old_mask)); I am using glthreads. Maybe that has to do with the configure flag --disable-threads !? The glthread functions are defined a 0 in this case. The surrounding code in signal.h looks like #if 1 # if 0 # if !(defined __cplusplus && defined GNULIB_NAMESPACE) # undef pthread_sigmask # define pthread_sigmask rpl_pthread_sigmask # endif _GL_FUNCDECL_RPL (pthread_sigmask, int, (int how, const sigset_t *new_mask, sigset_t *old_mask)); _GL_CXXALIAS_RPL (pthread_sigmask, int, (int how, const sigset_t *new_mask, sigset_t *old_mask)); # else # if !0 _GL_FUNCDECL_SYS (pthread_sigmask, int, (int how, const sigset_t *new_mask, sigset_t *old_mask)); # endif ... Any more ideas / hints ? Regards, Tim
signature.asc
Description: This is a digitally signed message part