This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[RFA] rs6000/sysv4.h: Fix machine name assertion conflict
- To: gcc-patches at gcc dot gnu dot org
- Subject: [RFA] rs6000/sysv4.h: Fix machine name assertion conflict
- From: Nick Clifton <nickc at cambridge dot redhat dot com>
- Date: 15 Jul 2001 11:23:24 +0100
Hi Guys,
I am applying the patch below, approved by Geoff Keating, to fix an
assertion conflict in rs6000/sysv4.h. It is possible to have the
'machine' assertion be set to both 'powerpc' and 'littleendian'
which produces a warning from the preprocessor. The patch changes
the endian assertions to use 'endian' instead of 'machine'.
Cheers
Nick
2001-07-15 Nick Clifton <nickc@cambridge.redhat.com>
* config/rs6000/sysv4.h (CPP_ENDIAN_BIG_SPEC): Assert 'endian'
not 'machine'.
(CPP_ENDIAN_LITTLE_SPEC): Assert 'endian' not 'machine'.
(CPP_ENDIAN_SOLARIS_SPEC): Assert 'endian' not 'machine'.
Index: sysv4.h
===================================================================
RCS file: /cvs/gcc/gcc/gcc/config/rs6000/sysv4.h,v
retrieving revision 1.49
diff -p -r1.49 sysv4.h
*** sysv4.h 2001/07/06 18:40:16 1.49
--- sysv4.h 2001/07/15 10:16:10
*************** do { \
*** 1191,1201 ****
#define CPP_SYSV_DEFAULT_SPEC "-D_CALL_SYSV"
! #define CPP_ENDIAN_BIG_SPEC "-D_BIG_ENDIAN -D__BIG_ENDIAN__ -Amachine=bigendian"
! #define CPP_ENDIAN_LITTLE_SPEC "-D_LITTLE_ENDIAN -D__LITTLE_ENDIAN__ -Amachine=littleendian"
! #define CPP_ENDIAN_SOLARIS_SPEC "-D__LITTLE_ENDIAN__ -Amachine=littleendian"
/* For solaris, don't define _LITTLE_ENDIAN, it conflicts with a header file. */
#define CPP_ENDIAN_SPEC \
--- 1191,1201 ----
#define CPP_SYSV_DEFAULT_SPEC "-D_CALL_SYSV"
! #define CPP_ENDIAN_BIG_SPEC "-D_BIG_ENDIAN -D__BIG_ENDIAN__ -Aendian=big"
! #define CPP_ENDIAN_LITTLE_SPEC "-D_LITTLE_ENDIAN -D__LITTLE_ENDIAN__ -Aendian=little"
! #define CPP_ENDIAN_SOLARIS_SPEC "-D__LITTLE_ENDIAN__ -Aendian=little"
/* For solaris, don't define _LITTLE_ENDIAN, it conflicts with a header file. */
#define CPP_ENDIAN_SPEC \