config.gcc (*-*-vxworks*): Don't add to tm_files in this stanza.
authorRichard Sandiford <richard@codesourcery.com>
Thu, 12 Apr 2007 12:47:05 +0000 (12:47 +0000)
committerRichard Sandiford <rsandifo@gcc.gnu.org>
Thu, 12 Apr 2007 12:47:05 +0000 (12:47 +0000)
gcc/
* config.gcc (*-*-vxworks*): Don't add to tm_files in this stanza.
(arm-wrs-vxworks, mips-wrs-vxworks, powerpc-wrs-vxworks)
(powerpc-wrs-vxworksae): Use ${tm_file}.
(i[4567]86-wrs-vxworks, i[4567]86-wrs-vxworksae): Add svr4.h
after elfos.h.  Remove i386/sysv4.h and add i386/vx-common.h.
* config/i386/vx-common.h: New file.

From-SVN: r123744

gcc/ChangeLog
gcc/config.gcc
gcc/config/i386/vx-common.h [new file with mode: 0644]

index ba5e42b..1a72898 100644 (file)
@@ -1,5 +1,14 @@
 2007-04-12  Richard Sandiford  <richard@codesourcery.com>
 
+       * config.gcc (*-*-vxworks*): Don't add to tm_files in this stanza.
+       (arm-wrs-vxworks, mips-wrs-vxworks, powerpc-wrs-vxworks)
+       (powerpc-wrs-vxworksae): Use ${tm_file}.
+       (i[4567]86-wrs-vxworks, i[4567]86-wrs-vxworksae): Add svr4.h
+       after elfos.h.  Remove i386/sysv4.h and add i386/vx-common.h.
+       * config/i386/vx-common.h: New file.
+
+2007-04-12  Richard Sandiford  <richard@codesourcery.com>
+
        * config/vxworks.h (VXWORKS_STARTFILE_SPEC): Use -l:crt0.o instead
        of crt0.o%s.
 
index 14f79d6..36e369f 100644 (file)
@@ -569,7 +569,6 @@ case ${target} in
   ;;
 *-*-vxworks*)
   tmake_file=t-vxworks
-  tm_file="${tm_file} elfos.h svr4.h"
   xm_defines=POSIX
   extra_options="${extra_options} vxworks.opt"
   extra_objs=vxworks.o
@@ -694,7 +693,7 @@ arm-semi-aof | armel-semi-aof)
        tmake_file="arm/t-arm arm/t-semi"
        ;;
 arm-wrs-vxworks)
-       tm_file="dbxelf.h elfos.h svr4.h vxworks.h arm/elf.h arm/aout.h arm/arm.h arm/vxworks.h"
+       tm_file="dbxelf.h elfos.h svr4.h vxworks.h arm/elf.h arm/aout.h ${tm_file} arm/vxworks.h"
        tmake_file="${tmake_file} arm/t-arm arm/t-vxworks"
        ;;
 arm*-*-freebsd*|strongarm*-*-freebsd*)
@@ -1317,14 +1316,14 @@ i[34567]86-*-sysv4*)            # Intel 80386's running system V.4
        use_fixproto=yes
        ;;
 i[4567]86-wrs-vxworks|i[4567]86-wrs-vxworksae)
-       tm_file="${tm_file} i386/sysv4.h i386/unix.h i386/att.h elfos.h vx-common.h"
+       tm_file="${tm_file} i386/unix.h i386/att.h elfos.h svr4.h vx-common.h"
        case ${target} in
          *-vxworksae*)
-           tm_file="${tm_file} vxworksae.h i386/vxworksae.h"
+           tm_file="${tm_file} vxworksae.h i386/vx-common.h i386/vxworksae.h"
            tmake_file="${tmake_file} i386/t-vxworks i386/t-vxworksae"
            ;;
          *)
-           tm_file="${tm_file} vxworks.h i386/vxworks.h"
+           tm_file="${tm_file} vxworks.h i386/vx-common.h i386/vxworks.h"
            tmake_file="${tmake_file} i386/t-vxworks"
            ;;
        esac
@@ -1706,9 +1705,7 @@ mips*-*-rtems*)
        tmake_file="mips/t-elf t-rtems mips/t-rtems"
        ;;
 mips-wrs-vxworks)
-       # We want vxworks.h after mips/elf.h, which unfortunately means we
-       # have to redo the tm_file list from scratch.
-       tm_file="elfos.h mips/mips.h svr4.h mips/elf.h vx-common.h vxworks.h mips/vxworks.h"
+       tm_file="elfos.h ${tm_file} svr4.h mips/elf.h vx-common.h vxworks.h mips/vxworks.h"
        tmake_file="${tmake_file} mips/t-vxworks"
        ;;
 mips-wrs-windiss)      # Instruction-level simulator for VxWorks.
@@ -1909,9 +1906,7 @@ powerpc-*-gnu*)
        fi
        ;;
 powerpc-wrs-vxworks|powerpc-wrs-vxworksae)
-       # We want vxworks.h after rs6000/sysv4.h, which unfortunately
-       # means we have to redo the tm_file list from scratch.
-       tm_file="rs6000/rs6000.h elfos.h svr4.h freebsd-spec.h rs6000/sysv4.h"
+       tm_file="${tm_file} elfos.h svr4.h freebsd-spec.h rs6000/sysv4.h"
        tmake_file="${tmake_file} rs6000/t-fprules rs6000/t-fprules-fpbit rs6000/t-ppccomm rs6000/t-vxworks"
        extra_options="${extra_options} rs6000/sysv4.opt"
        extra_headers=ppc-asm.h
diff --git a/gcc/config/i386/vx-common.h b/gcc/config/i386/vx-common.h
new file mode 100644 (file)
index 0000000..7c94c7d
--- /dev/null
@@ -0,0 +1,30 @@
+/* IA32 VxWorks and VxWorks AE target definitions.
+   Copyright (C) 2007 Free Software Foundation, Inc.
+
+This file is part of GCC.
+
+GCC is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GCC is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GCC; see the file COPYING.  If not, write to
+the Free Software Foundation, 51 Franklin Street, Fifth Floor,
+Boston, MA 02110-1301, USA.  */
+
+#define ASM_OUTPUT_ALIGNED_BSS(FILE, DECL, NAME, SIZE, ALIGN) \
+  asm_output_aligned_bss (FILE, DECL, NAME, SIZE, ALIGN)
+
+/* The svr4 ABI for the i386 says that records and unions are returned
+   in memory.  */
+
+#undef RETURN_IN_MEMORY
+#define RETURN_IN_MEMORY(TYPE) \
+  (TYPE_MODE (TYPE) == BLKmode \
+   || (VECTOR_MODE_P (TYPE_MODE (TYPE)) && int_size_in_bytes (TYPE) == 8))