diff options
author | Kaveh R. Ghazi <ghazi@caip.rutgers.edu> | 1999-02-01 06:49:19 +0000 |
---|---|---|
committer | Kaveh Ghazi <ghazi@gcc.gnu.org> | 1999-02-01 06:49:19 +0000 |
commit | ab7c205e79d2198c0318b639cf4272044049d3ba (patch) | |
tree | 210badf5e829e5596cfb528d9db20ef0a91a9014 /gcc/system.h | |
parent | 5ae38e867860a28a3020a222b4cc080c388916a3 (diff) | |
download | gcc-ab7c205e79d2198c0318b639cf4272044049d3ba.zip gcc-ab7c205e79d2198c0318b639cf4272044049d3ba.tar.gz gcc-ab7c205e79d2198c0318b639cf4272044049d3ba.tar.bz2 |
system.h (inline, const): Handle these for stage2 (and later) gcc.
* system.h (inline, const): Handle these for stage2 (and later) gcc.
* dwarf2out.c (inline): Don't define.
* dwarfout.c (inline): Likewise.
From-SVN: r24950
Diffstat (limited to 'gcc/system.h')
-rw-r--r-- | gcc/system.h | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/gcc/system.h b/gcc/system.h index 7390974..0de7133 100644 --- a/gcc/system.h +++ b/gcc/system.h @@ -22,6 +22,18 @@ Boston, MA 02111-1307, USA. */ #ifndef __GCC_SYSTEM_H__ #define __GCC_SYSTEM_H__ +/* Autoconf will possibly define the `inline' or `const' keywords as + macros, however this is only valid for the stage1 compiler. If we + detect a modern version of gcc, unconditionally reset the values. + This makes sure the right thing happens in stage2 and later. We + need to do this before any header files in case they use these + keywords or conflicts might occur. */ +#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 7) +# undef const +# undef inline +# define inline __inline__ /* Modern gcc can use `__inline__' freely. */ +#endif /* GCC >= 2.7 */ + /* We must include stdarg.h/varargs.h before stdio.h. */ #ifdef ANSI_PROTOTYPES #include <stdarg.h> @@ -392,7 +404,6 @@ extern void abort (); # endif #endif /* ! STRINGIFY */ - /* These macros are here in preparation for the use of gettext in egcs. */ #define _(String) String #define N_(String) String |