Prof A Olowofoyeku (The African Chief) wrote:
I am building the snapshot at the moment for Mingw (gcc-2.93-8). The build process halted with errors relating to undefined "sys_siglist" in gpc.c. I checked up on this, and had to comment out the declaration below: "#define strsignal(N) (sys_siglist[(N)])"
Under Mingw strsignal() is defined in libiberty.h,
In gcc-2.95.3 (I assume your 2.93 was a typo) the declaration in libiberty is commented out. Does Mingw use some special patches to libiberty.h? If so, what do they look like? If they `#define strsignal', it should be enough to put an `#ifndef strsignal' around the definition in gpc.c. Or does it provide an external declaration?
Try the following:
--- /home/gpc/orig/gpc.c Wed Nov 6 07:35:25 2002 +++ /home/gpc/p/gpc.c Thu Nov 14 00:38:03 2002 @@ -125,17 +125,21 @@ #define PEXECUTE_LAST 2 #define PEXECUTE_SEARCH 4 #define PEXECUTE_VERBOSE 8 +#ifndef HAVE_STRSIGNAL +#define strsignal(N) (sys_siglist[(N)]) +#endif #endif #if defined (EGCS) && !defined (EGCS97) +/* If the system doesn't provide strsignal, we get it defined in + libiberty but no declaration is supplied. */ +#if !defined (HAVE_STRSIGNAL) && !defined (strsignal) +extern const char *strsignal PARAMS ((int)); +#endif #undef _ #define _(String) String #endif #ifndef HOST_BIT_BUCKET #define HOST_BIT_BUCKET "/dev/null" -#endif - -#ifndef HAVE_STRSIGNAL -#define strsignal(N) (sys_siglist[(N)]) #endif
#ifdef GCC_2_95_3
but it seems that the configure script doesn't look there.
I suppose not. Since libiberty.h is distributed with gcc, it can assume it knows what's in there.
Or is for some reason another libiberty.h (system-wide installed) used instead of the one that comes with gcc? That might be a bug in the build process.
Frank