egcs 1.0.3a on sparc-unknown-linux-gnu?
David S. Miller
davem@dm.cobaltmicro.com
Fri Aug 7 03:36:00 GMT 1998
Date: Thu, 06 Aug 1998 22:19:07 -0400
From: Eric Ding <ericding@applix.com>
I've had problems compiling egcs 1.0.3a on a Linux-Sparc machine,
running RedHat 5.1. I get the following error:
In file included from ../../egcs-1.0.3a/gcc/libgcc2.c:1440:
../../egcs-1.0.3a/gcc/gbl-ctors.h:43: conflicting types for `atexit'
/usr/include/stdlib.h:374: previous declaration of `atexit'
This should be happening because the gbl-ctors.h lines in question
say:
line 40: #if defined (WINNT) || defined (NEED_ATEXIT) || (defined(__sparc__) && defined(__linux__))
line 41: extern int atexit (void (*) (void));
line 42: #else
line 43: extern void atexit (void (*) (void));
line 44: #endif
__linux__ and __sparc__ should obviously be defined, and thus should
cause the code on line 41 to be what is used, not what is on line 43.
If you just want a build to work, just change the first "#if" to be
just "#if 1" and comment out the rest of that line. Although it would
be interesting to know why this is failing at all.
Later,
David S. Miller
davem@dm.cobaltmicro.com
More information about the Gcc-bugs
mailing list