diff options
author | Jason Thorpe <thorpej@wasabisystems.com> | 2002-05-03 21:38:25 +0000 |
---|---|---|
committer | Jason Thorpe <thorpej@gcc.gnu.org> | 2002-05-03 21:38:25 +0000 |
commit | e1c1132e0b08e1eccc4b361ae9725e5e12a1a2c9 (patch) | |
tree | dc4c2063b6b8ed4bfa164d114f04df4c88f54f3a /gcc | |
parent | 0b2fb0d7353e6a02ef7e672a89cfc9bbacf88e6f (diff) | |
download | gcc-e1c1132e0b08e1eccc4b361ae9725e5e12a1a2c9.zip gcc-e1c1132e0b08e1eccc4b361ae9725e5e12a1a2c9.tar.gz gcc-e1c1132e0b08e1eccc4b361ae9725e5e12a1a2c9.tar.bz2 |
netbsd-elf.c (CPP_SUBTARGET_SPEC64): Remove -D__arch64__.
* config/sparc/netbsd-elf.c (CPP_SUBTARGET_SPEC64): Remove
-D__arch64__. Add -D_LP64.
(CPP_ARCH32_SPEC): Redefine to match the non-bi-arch version
from sparc.h.
(CPP_ARCH64_SPEC): Likewise.
(NO_BUILTIN_PTRDIFF_TYPE): Undef.
(NO_BUILTIN_SIZE_TYPE): Undef.
From-SVN: r53131
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/ChangeLog | 10 | ||||
-rw-r--r-- | gcc/config/sparc/netbsd-elf.h | 18 |
2 files changed, 27 insertions, 1 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index bba1c7e..0e78d52 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,13 @@ +2002-05-03 Jason Thorpe <thorpej@wasabisystems.com> + + * config/sparc/netbsd-elf.c (CPP_SUBTARGET_SPEC64): Remove + -D__arch64__. Add -D_LP64. + (CPP_ARCH32_SPEC): Redefine to match the non-bi-arch version + from sparc.h. + (CPP_ARCH64_SPEC): Likewise. + (NO_BUILTIN_PTRDIFF_TYPE): Undef. + (NO_BUILTIN_SIZE_TYPE): Undef. + 2002-05-03 Vladimir Makarov <vmakarov@redhat.com> * genautomata.c (min_issue_delay_pass_states): Change return type diff --git a/gcc/config/sparc/netbsd-elf.h b/gcc/config/sparc/netbsd-elf.h index b4bbf71..1bf4356 100644 --- a/gcc/config/sparc/netbsd-elf.h +++ b/gcc/config/sparc/netbsd-elf.h @@ -31,12 +31,28 @@ Boston, MA 02111-1307, USA. */ /* CPP defines used for 64 bit code. */ #undef CPP_SUBTARGET_SPEC64 #define CPP_SUBTARGET_SPEC64 \ - "-D__sparc64__ -D__arch64__ -D__sparc_v9__ %{posix:-D_POSIX_SOURCE}" + "-D__sparc64__ -D__sparc_v9__ -D_LP64 %{posix:-D_POSIX_SOURCE}" /* CPP defines used for 32 bit code. */ #undef CPP_SUBTARGET_SPEC32 #define CPP_SUBTARGET_SPEC32 "-D__sparc %{posix:-D_POSIX_SOURCE}" +/* CPP_ARCH32_SPEC and CPP_ARCH64_SPEC are wrong from sparc/sparc.h; we + always want the non-SPARC_BI_ARCH versions, since the SPARC_BI_ARCH + versions define __SIZE_TYPE__ and __PTRDIFF_TYPE__ incorrectly for + NetBSD. */ +#undef CPP_ARCH32_SPEC +#define CPP_ARCH32_SPEC "-D__GCC_NEW_VARARGS__ -Acpu=sparc -Amachine=sparc" + +#undef CPP_ARCH64_SPEC +#define CPP_ARCH64_SPEC "-D__arch64__ -Acpu=sparc64 -Amachine=sparc64" + +/* sparc/sparc.h defines NO_BUILTIN_SIZE_TYPE and NO_BUILTIN_PTRDIFF_TYPE + if SPARC_BI_ARCH is defined. This is wrong for NetBSD; size_t and + ptrdiff_t do not change for 32-bit vs. 64-bit. */ +#undef NO_BUILTIN_PTRDIFF_TYPE +#undef NO_BUILTIN_SIZE_TYPE + /* SIZE_TYPE and PTRDIFF_TYPE are wrong from sparc/sparc.h. */ #undef SIZE_TYPE #define SIZE_TYPE "long unsigned int" |