diff options
-rw-r--r-- | contrib/gcc/config/i386/freebsd.h | 28 | ||||
-rw-r--r-- | gnu/usr.bin/cc/cc_tools/auto-host.h | 9 |
2 files changed, 31 insertions, 6 deletions
diff --git a/contrib/gcc/config/i386/freebsd.h b/contrib/gcc/config/i386/freebsd.h index f118d42..cce27dd 100644 --- a/contrib/gcc/config/i386/freebsd.h +++ b/contrib/gcc/config/i386/freebsd.h @@ -101,6 +101,15 @@ Boston, MA 02111-1307, USA. */ %{!shared:crtend.o%s} \ %{shared:crtendS.o%s} crtn.o%s}" +/* FreeBSD conditionalizes the use of ".section rodata" depending on + ELF mode - otherwise .text. */ +#undef USE_CONST_SECTION +#define USE_CONST_SECTION TARGET_ELF + +/* ".string" doesn't work for the aout case. */ +#undef STRING_ASM_OP +#define STRING_ASM_OP (TARGET_AOUT ? "\t.asciz\t" : "\t.string\t") + /************************[ Target stuff ]***********************************/ @@ -347,12 +356,21 @@ Boston, MA 02111-1307, USA. */ This is used to align code labels according to Intel recommendations. */ +/* XXX configuration of this is broken in the same way as HAVE_GAS_SHF_MERGE, + but it is easier to fix in an MD way. */ + #ifdef HAVE_GAS_MAX_SKIP_P2ALIGN -#define ASM_OUTPUT_MAX_SKIP_ALIGN(FILE, LOG, MAX_SKIP) \ - if ((LOG) != 0) { \ - if ((MAX_SKIP) == 0) fprintf ((FILE), "\t.p2align %d\n", (LOG)); \ - else fprintf ((FILE), "\t.p2align %d,,%d\n", (LOG), (MAX_SKIP)); \ - } +#define ASM_OUTPUT_MAX_SKIP_ALIGN(FILE, LOG, MAX_SKIP) \ +do { \ + if ((LOG) != 0) { \ + if (TARGET_AOUT) \ + ASM_OUTPUT_ALIGN ((FILE), (LOG)); \ + else if ((MAX_SKIP) == 0) \ + fprintf ((FILE), "\t.p2align %d\n", (LOG)); \ + else \ + fprintf ((FILE), "\t.p2align %d,,%d\n", (LOG), (MAX_SKIP)); \ + } \ +} while (0) #endif diff --git a/gnu/usr.bin/cc/cc_tools/auto-host.h b/gnu/usr.bin/cc/cc_tools/auto-host.h index 5123028..338b5d3 100644 --- a/gnu/usr.bin/cc/cc_tools/auto-host.h +++ b/gnu/usr.bin/cc/cc_tools/auto-host.h @@ -530,7 +530,14 @@ /* #undef USE_AS_TRADITIONAL_FORMAT */ /* Define if your assembler supports marking sections with SHF_MERGE flag. */ -#define HAVE_GAS_SHF_MERGE 1 /* XXX:DEO new, caused Peter IA-64 trouble until he adjusted sys/boot/efi/libefi/arch/ia64/ldscript.ia64 */ +/* XXX:DEO new; caused Peter IA-64 trouble until he adjusted + sys/boot/efi/libefi/arch/ia64/ldscript.ia64. */ +#define HAVE_GAS_SHF_MERGE 1 + +/* XXX HAVE_GAS_SHF_MERGE is target-dependent so it shouldn't be put in + this target-independent config file. Defining it breaks aout support + on i386's. */ +#undef HAVE_GAS_SHF_MERGE /* Define if your assembler supports explicit relocations. */ /* #undef HAVE_AS_EXPLICIT_RELOCS */ |