thomas@1461: Original patch from: ../4.3.2/150-sparc64-bsd.patch thomas@1461: thomas@1461: -= BEGIN original header =- thomas@1461: Original patch from gentoo: gentoo/src/patchsets/gcc/4.3.1/gentoo/14_all_gcc-sparc64-bsd.patch thomas@1461: -= END original header =- thomas@1461: thomas@1461: diff -durN gcc-4.3.3.orig/gcc/config/sparc/freebsd.h gcc-4.3.3/gcc/config/sparc/freebsd.h thomas@1461: --- gcc-4.3.3.orig/gcc/config/sparc/freebsd.h 2007-08-02 12:49:31.000000000 +0200 thomas@1461: +++ gcc-4.3.3/gcc/config/sparc/freebsd.h 2009-01-27 22:19:20.000000000 +0100 thomas@1461: @@ -25,9 +25,22 @@ thomas@1461: /* FreeBSD needs the platform name (sparc64) defined. thomas@1461: Emacs needs to know if the arch is 64 or 32-bits. */ thomas@1461: thomas@1461: -#undef CPP_CPU64_DEFAULT_SPEC thomas@1461: -#define CPP_CPU64_DEFAULT_SPEC \ thomas@1461: - "-D__sparc64__ -D__sparc_v9__ -D__sparcv9 -D__arch64__" thomas@1461: +#undef FBSD_TARGET_CPU_CPP_BUILTINS thomas@1461: +#define FBSD_TARGET_CPU_CPP_BUILTINS() \ thomas@1461: + do \ thomas@1461: + { \ thomas@1461: + if (TARGET_ARCH64) \ thomas@1461: + { \ thomas@1461: + builtin_define ("__sparc64__"); \ thomas@1461: + builtin_define ("__sparc_v9__"); \ thomas@1461: + builtin_define ("__sparcv9"); \ thomas@1461: + } \ thomas@1461: + else \ thomas@1461: + builtin_define ("__sparc"); \ thomas@1461: + builtin_define ("__sparc__"); \ thomas@1461: + } \ thomas@1461: + while (0) thomas@1461: + thomas@1461: thomas@1461: #define LINK_SPEC "%(link_arch) \ thomas@1461: %{!mno-relax:%{!r:-relax}} \