From: Eric Norum Date: Fri, 12 Apr 2002 13:35:03 +0000 (+0000) Subject: rtems.h, [...] (*-rtems*): Cleanup pass to move common definitions to config/rtems... X-Git-Tag: releases/gcc-3.3.0~5739 X-Git-Url: https://gcc.gnu.org/git/?a=commitdiff_plain;h=1d80248e2fe0cd6e7f283467867755a778073605;p=gcc.git rtems.h, [...] (*-rtems*): Cleanup pass to move common definitions to config/rtems.h and make the targets... 2002-04-12 Eric Norum * config/rtems.h, config/a29k/rtems.h, config/arm/rtems-elf.h, config/c4x/rtems.h, config/h8300/rtems.h, config/i386/rtems.h, config/i386/rtemself.h, config/i960/rtems.h, config/m68k/rtems.h, config/m68k/rtemself.h, config/mips/rtems.h, config/mips/rtems64.h, config/pa/rtems.h, config/rs6000/rtems.h, config/sh/rtems.h, config/sh/rtemself.h, config/sparc/rtems.h, config/sparc/rtemself.h, config/v850/rtems.h (*-rtems*): Cleanup pass to move common definitions to config/rtems.h and make the targets more similar. From-SVN: r52225 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 63fc94ffff8e..0250693cbe2e 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,14 @@ +2002-04-12 Eric Norum + + * config/rtems.h, config/a29k/rtems.h, config/arm/rtems-elf.h, + config/c4x/rtems.h, config/h8300/rtems.h, config/i386/rtems.h, + config/i386/rtemself.h, config/i960/rtems.h, config/m68k/rtems.h, + config/m68k/rtemself.h, config/mips/rtems.h, config/mips/rtems64.h, + config/pa/rtems.h, config/rs6000/rtems.h, config/sh/rtems.h, + config/sh/rtemself.h, config/sparc/rtems.h, config/sparc/rtemself.h, + config/v850/rtems.h (*-rtems*): Cleanup pass to move common + definitions to config/rtems.h and make the targets more similar. + Fri Apr 12 08:06:54 2002 Richard Kenner * expr.c (expand_assigment): Remove duplicate conversions #ifdef diff --git a/gcc/config/a29k/rtems.h b/gcc/config/a29k/rtems.h index c2c9d6ac5e83..ef654450cfc4 100644 --- a/gcc/config/a29k/rtems.h +++ b/gcc/config/a29k/rtems.h @@ -24,8 +24,3 @@ Boston, MA 02111-1307, USA. */ #undef CPP_PREDEFINES #define CPP_PREDEFINES "-D_AM29K -D_AM29000 -D_EPI -D__rtems__ \ -Asystem=rtems -Acpu=a29k -Amachine=a29k" - -/* Generate calls to memcpy, memcmp and memset. */ -#ifndef TARGET_MEM_FUNCTIONS -#define TARGET_MEM_FUNCTIONS -#endif diff --git a/gcc/config/arm/rtems-elf.h b/gcc/config/arm/rtems-elf.h index 8663768ab818..79da8c9c2b7e 100644 --- a/gcc/config/arm/rtems-elf.h +++ b/gcc/config/arm/rtems-elf.h @@ -25,6 +25,3 @@ Boston, MA 02111-1307, USA. */ #undef CPP_PREDEFINES #define CPP_PREDEFINES "-D__rtems__ -D__ELF__ -Asystem=rtems" - -#undef INVOKE_main - diff --git a/gcc/config/c4x/rtems.h b/gcc/config/c4x/rtems.h index d4364dffa4ed..400d883200ff 100644 --- a/gcc/config/c4x/rtems.h +++ b/gcc/config/c4x/rtems.h @@ -23,8 +23,3 @@ Boston, MA 02111-1307, USA. */ #undef CPP_PREDEFINES #define CPP_PREDEFINES "-D__rtems__ -Asystem=rtems -D__USE_INIT_FINI__" - -/* Generate calls to memcpy, memcmp and memset. */ -#ifndef TARGET_MEM_FUNCTIONS -#define TARGET_MEM_FUNCTIONS -#endif diff --git a/gcc/config/h8300/rtems.h b/gcc/config/h8300/rtems.h index f1b4b33ee44d..2e7676f41f96 100644 --- a/gcc/config/h8300/rtems.h +++ b/gcc/config/h8300/rtems.h @@ -23,8 +23,3 @@ Boston, MA 02111-1307, USA. */ #define CPP_PREDEFINES "-Dh8300 \ -D__LONG_MAX__=2147483647L -D__LONG_LONG_MAX__=2147483647L \ -D__rtems__ -Asystem=rtems" - -/* Generate calls to memcpy, memcmp and memset. */ -#ifndef TARGET_MEM_FUNCTIONS -#define TARGET_MEM_FUNCTIONS -#endif diff --git a/gcc/config/i386/rtems.h b/gcc/config/i386/rtems.h index 9e8fab73a116..16fd6fb9eb1d 100644 --- a/gcc/config/i386/rtems.h +++ b/gcc/config/i386/rtems.h @@ -26,8 +26,3 @@ Boston, MA 02111-1307, USA. */ #undef TARGET_VERSION #define TARGET_VERSION fprintf (stderr, " (80386, RTEMS)"); - -/* Generate calls to memcpy, memcmp and memset. */ -#ifndef TARGET_MEM_FUNCTIONS -#define TARGET_MEM_FUNCTIONS -#endif diff --git a/gcc/config/i386/rtemself.h b/gcc/config/i386/rtemself.h index 2ebc517cb1ac..7e831b9f73ea 100644 --- a/gcc/config/i386/rtemself.h +++ b/gcc/config/i386/rtemself.h @@ -21,20 +21,11 @@ Boston, MA 02111-1307, USA. */ /* Specify predefined symbols in preprocessor. */ +#include + #undef CPP_PREDEFINES #define CPP_PREDEFINES "-D__rtems__ -Asystem=rtems \ -D__ELF__ -D__i386__ -D__USE_INIT_FINI__" #undef CPP_SPEC #define CPP_SPEC "%(cpp_cpu) %{msoft-float:-D_SOFT_FLOAT}" - -#undef STARTFILE_SPEC -#define STARTFILE_SPEC "crt0.o%s crti.o%s crtbegin.o%s" - -#undef ENDFILE_SPEC -#define ENDFILE_SPEC "crtend.o%s crtn.o%s" - -/* Generate calls to memcpy, memcmp and memset. */ -#ifndef TARGET_MEM_FUNCTIONS -#define TARGET_MEM_FUNCTIONS -#endif diff --git a/gcc/config/i960/rtems.h b/gcc/config/i960/rtems.h index d1dccc030e49..411acfcd035f 100644 --- a/gcc/config/i960/rtems.h +++ b/gcc/config/i960/rtems.h @@ -24,8 +24,3 @@ Boston, MA 02111-1307, USA. */ #undef CPP_PREDEFINES #define CPP_PREDEFINES "-Di960 -Di80960 -DI960 -DI80960 -D__rtems__ \ -Asystem=rtems -Acpu=i960 -Amachine=i960" - -/* Generate calls to memcpy, memcmp and memset. */ -#ifndef TARGET_MEM_FUNCTIONS -#define TARGET_MEM_FUNCTIONS -#endif diff --git a/gcc/config/m68k/rtems.h b/gcc/config/m68k/rtems.h index 89b51601eb4a..7a6f55b62a97 100644 --- a/gcc/config/m68k/rtems.h +++ b/gcc/config/m68k/rtems.h @@ -24,8 +24,3 @@ Boston, MA 02111-1307, USA. */ #undef CPP_PREDEFINES #define CPP_PREDEFINES "-Dmc68000 -D__rtems__ \ -Asystem=rtems -Acpu=mc68000 -Acpu=m68k -Amachine=m68k" - -/* Generate calls to memcpy, memcmp and memset. */ -#ifndef TARGET_MEM_FUNCTIONS -#define TARGET_MEM_FUNCTIONS -#endif diff --git a/gcc/config/m68k/rtemself.h b/gcc/config/m68k/rtemself.h index 473ee25548b1..eb627f6db011 100644 --- a/gcc/config/m68k/rtemself.h +++ b/gcc/config/m68k/rtemself.h @@ -22,41 +22,8 @@ Boston, MA 02111-1307, USA. */ #define MOTOROLA /* Use Motorola syntax rather than MIT. */ -#include "m68k/m68020-elf.h" - /* Specify predefined symbols in preprocessor. */ #undef CPP_PREDEFINES #define CPP_PREDEFINES "-Dmc68000 -D__rtems__ -D__ELF__ -D__USE_INIT_FINI__ \ -Asystem=rtems -Acpu=mc68000 -Acpu=m68k -Amachine=m68k" - -/* Generate calls to memcpy, memcmp and memset. */ -#ifndef TARGET_MEM_FUNCTIONS -#define TARGET_MEM_FUNCTIONS -#endif - -/* - * Each RTEMS BSP provides its own crt0 and linker script. Unfortunately - * this means that crt0 and the linker script are not available as - * each tool is configured. Without a crt0 and linker script, m68k ELF - * targets do not successfully link "conftest.c" during the configuration - * process. RTEMS supplies a crt0.c that provides all the symbols required - * to successfully link a program. The resulting program will not run - * but this is enough to satisfy the autoconf macro AC_PROG_CC. - * Override STARTFILE_SPEC to use the fake crt0.o supplied by rtems. - */ -#undef STARTFILE_SPEC -#define STARTFILE_SPEC "crt0.o%s" - -/* - * Redefine INIT_SECTION_ASM_OP and FINI_SECTION_ASM_OP. This is the easiest - * way to process constructors, destructors, and the exception frame - * information at startup. - */ -#undef INIT_SECTION_ASM_OP -#define INIT_SECTION_ASM_OP "\t.section\t.init" -#undef FINI_SECTION_ASM_OP -#define FINI_SECTION_ASM_OP "\t.section\t.fini" - -/* Do I need this? */ -#undef INVOKE__main diff --git a/gcc/config/mips/rtems.h b/gcc/config/mips/rtems.h index 0a2692ac9062..35674e265005 100644 --- a/gcc/config/mips/rtems.h +++ b/gcc/config/mips/rtems.h @@ -24,8 +24,3 @@ Boston, MA 02111-1307, USA. */ #undef CPP_PREDEFINES #define CPP_PREDEFINES "-Dmips -DMIPSEB -D_mips -D_MIPSEB \ -D__rtems__ -Asystem=rtems" - -/* Generate calls to memcpy, memcmp and memset. */ -#ifndef TARGET_MEM_FUNCTIONS -#define TARGET_MEM_FUNCTIONS -#endif diff --git a/gcc/config/mips/rtems64.h b/gcc/config/mips/rtems64.h index 78281b6d818f..e3c74ca04eab 100644 --- a/gcc/config/mips/rtems64.h +++ b/gcc/config/mips/rtems64.h @@ -25,11 +25,6 @@ Boston, MA 02111-1307, USA. */ #define CPP_PREDEFINES "-Dmips -DMIPSEB -DR4000 -D_mips -D_MIPSEB -D_R4000 \ -D__rtems__ -Asystem=rtems" -/* Generate calls to memcpy, memcmp and memset. */ -#ifndef TARGET_MEM_FUNCTIONS -#define TARGET_MEM_FUNCTIONS -#endif - #undef EXTRA_SECTIONS #define EXTRA_SECTIONS in_sdata, in_rdata diff --git a/gcc/config/pa/rtems.h b/gcc/config/pa/rtems.h index 10b892e796b0..fe83e85f0440 100644 --- a/gcc/config/pa/rtems.h +++ b/gcc/config/pa/rtems.h @@ -24,8 +24,3 @@ Boston, MA 02111-1307, USA. */ #undef CPP_PREDEFINES #define CPP_PREDEFINES "-Dhppa -DPWB -Acpu=hppa -Amachine=hppa \ -D__rtems__ -Asystem=rtems" - -/* Generate calls to memcpy, memcmp and memset. */ -#ifndef TARGET_MEM_FUNCTIONS -#define TARGET_MEM_FUNCTIONS -#endif diff --git a/gcc/config/rs6000/rtems.h b/gcc/config/rs6000/rtems.h index cb5cac51b74b..aa68130ba17e 100644 --- a/gcc/config/rs6000/rtems.h +++ b/gcc/config/rs6000/rtems.h @@ -24,11 +24,3 @@ Boston, MA 02111-1307, USA. */ #undef CPP_PREDEFINES #define CPP_PREDEFINES "-DPPC -D__rtems__ \ -Asystem=rtems -Acpu=powerpc -Amachine=powerpc" - -/* Generate calls to memcpy, memcmp and memset. */ -#ifndef TARGET_MEM_FUNCTIONS -#define TARGET_MEM_FUNCTIONS -#endif - -#undef STARTFILE_DEFAULT_SPEC -#define STARTFILE_DEFAULT_SPEC "crt0.o%s" diff --git a/gcc/config/rtems.h b/gcc/config/rtems.h index a5ac8a741d3e..c1592617e0c9 100644 --- a/gcc/config/rtems.h +++ b/gcc/config/rtems.h @@ -1,5 +1,5 @@ /* Configuration common to all targets running RTEMS. - Copyright (C) 2000 Free Software Foundation, Inc. + Copyright (C) 2000, 2002 Free Software Foundation, Inc. This file is part of GNU CC. @@ -20,3 +20,18 @@ Boston, MA 02111-1307, USA. */ /* The system headers under RTEMS are C++-aware. */ #define NO_IMPLICIT_EXTERN_C + +/* Generate calls to memcpy, memcmp and memset. */ +#ifndef TARGET_MEM_FUNCTIONS +#define TARGET_MEM_FUNCTIONS +#endif + +/* + * Dummy start/end specification to let linker work as + * needed by autoconf scripts using this compiler. + */ +#undef STARTFILE_SPEC +#define STARTFILE_SPEC "crt0.o%s crti.o%s crtbegin.o%s" + +#undef ENDFILE_SPEC +#define ENDFILE_SPEC "crtend.o%s crtn.o%s" diff --git a/gcc/config/sh/rtems.h b/gcc/config/sh/rtems.h index 3f8ce8b6034e..b52ef7216ec1 100644 --- a/gcc/config/sh/rtems.h +++ b/gcc/config/sh/rtems.h @@ -24,8 +24,3 @@ Boston, MA 02111-1307, USA. */ #undef CPP_PREDEFINES #define CPP_PREDEFINES "-D__sh__ -D__rtems__ \ -Asystem=rtems -Acpu=sh -Amachine=sh" - -/* Generate calls to memcpy, memcmp and memset. */ -#ifndef TARGET_MEM_FUNCTIONS -#define TARGET_MEM_FUNCTIONS -#endif diff --git a/gcc/config/sh/rtemself.h b/gcc/config/sh/rtemself.h index 552d77a9b603..6177c810dd14 100644 --- a/gcc/config/sh/rtemself.h +++ b/gcc/config/sh/rtemself.h @@ -24,8 +24,3 @@ Boston, MA 02111-1307, USA. */ #undef CPP_PREDEFINES #define CPP_PREDEFINES "-D__sh__ -D__ELF__ -D__rtems__ \ -Asystem=rtems -Acpu=sh -Amachine=sh" - -/* Generate calls to memcpy, memcmp and memset. */ -#ifndef TARGET_MEM_FUNCTIONS -#define TARGET_MEM_FUNCTIONS -#endif diff --git a/gcc/config/sparc/rtems.h b/gcc/config/sparc/rtems.h index f6947ea645e2..e537f1ca988f 100644 --- a/gcc/config/sparc/rtems.h +++ b/gcc/config/sparc/rtems.h @@ -25,8 +25,3 @@ Boston, MA 02111-1307, USA. */ #undef CPP_PREDEFINES #define CPP_PREDEFINES "-Dsparc -D__GCC_NEW_VARARGS__ -D__rtems__ \ -Asystem=rtems" - -/* Generate calls to memcpy, memcmp and memset. */ -#ifndef TARGET_MEM_FUNCTIONS -#define TARGET_MEM_FUNCTIONS -#endif diff --git a/gcc/config/sparc/rtemself.h b/gcc/config/sparc/rtemself.h index 6faa9be55f74..4f2cc66bb6cc 100644 --- a/gcc/config/sparc/rtemself.h +++ b/gcc/config/sparc/rtemself.h @@ -24,8 +24,3 @@ Boston, MA 02111-1307, USA. */ #undef CPP_PREDEFINES #define CPP_PREDEFINES "-Dsparc -D__GCC_NEW_VARARGS__ -D__rtems__ \ -D__USE_INIT_FINI__ -Asystem=rtems" - -/* Generate calls to memcpy, memcmp and memset. */ -#ifndef TARGET_MEM_FUNCTIONS -#define TARGET_MEM_FUNCTIONS -#endif diff --git a/gcc/config/v850/rtems.h b/gcc/config/v850/rtems.h index 4f49ba6f8047..14ddfa125f37 100644 --- a/gcc/config/v850/rtems.h +++ b/gcc/config/v850/rtems.h @@ -24,8 +24,3 @@ Boston, MA 02111-1307, USA. */ #undef CPP_PREDEFINES #define CPP_PREDEFINES "-D__v851__ -D__v850 -D__rtems__ \ -Asystem=rtems -Acpu=v850 -Amachine=v850" - -/* Generate calls to memcpy, memcmp and memset. */ -#ifndef TARGET_MEM_FUNCTIONS -#define TARGET_MEM_FUNCTIONS -#endif