This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
RE: [PATCH] New BFD vector for QNX Neutrino MIPS
- From: Jeff Baker <jbaker at qnx dot com>
- To: binutils at sources dot redhat dot com
- Date: Fri, 6 Jun 2003 15:40:28 -0400
- Subject: RE: [PATCH] New BFD vector for QNX Neutrino MIPS
Oops, caught myself already. These changes are also required in
elf32-mipsnto.c.
- Jeff
--- elf32-mips.c Fri Jun 6 14:42:45 2003
+++ elf32-mipsnto.c Fri Jun 6 15:35:56 2003
@@ -86,8 +86,8 @@
static irix_compat_t elf32_mips_irix_compat
PARAMS ((bfd *));
-extern const bfd_target bfd_elf32_bigmips_vec;
-extern const bfd_target bfd_elf32_littlemips_vec;
+extern const bfd_target bfd_elf32_bigmipsnto_vec;
+extern const bfd_target bfd_elf32_littlemipsnto_vec;
/* Nonzero if ABFD is using the N32 ABI. */
#define ABI_N32_P(abfd) \
@@ -1660,8 +1660,8 @@
elf32_mips_irix_compat (abfd)
bfd *abfd;
{
- if ((abfd->xvec == &bfd_elf32_bigmips_vec)
- || (abfd->xvec == &bfd_elf32_littlemips_vec))
+ if ((abfd->xvec == &bfd_elf32_bigmipsnto_vec)
+ || (abfd->xvec == &bfd_elf32_littlemipsnto_vec))
return ict_irix5;
else
return ict_none;
@@ -1926,10 +1926,10 @@
_bfd_mips_elf_print_private_bfd_data
/* Support for SGI-ish mips targets. */
-#define TARGET_LITTLE_SYM bfd_elf32_littlemips_vec
-#define TARGET_LITTLE_NAME "elf32-littlemips"
-#define TARGET_BIG_SYM bfd_elf32_bigmips_vec
-#define TARGET_BIG_NAME "elf32-bigmips"
+#define TARGET_LITTLE_SYM bfd_elf32_littlemipsnto_vec
+#define TARGET_LITTLE_NAME "elf32-littlemipsnto"
+#define TARGET_BIG_SYM bfd_elf32_bigmipsnto_vec
+#define TARGET_BIG_NAME "elf32-bigmipsnto"
#include "elf32-target.h"
> -----Original Message-----
> From: Jeff Baker [mailto:jbaker@qnx.com]
> Sent: June 6, 2003 3:31 PM
> To: binutils@sources.redhat.com
> Subject: [PATCH] New BFD vector for QNX Neutrino MIPS
>
> I'm not entirely done with the QNX MIPS support yet, but I figured I'd get
> my foot in the door by submitting the addition of a new vector to support
> it.
>
> The two new files mentioned (elf32-mipsnto.c && elfxx-mipsnto.c) are
> currently just copies of elf32-mips.c and elfxx-mips.c, respectively. I
> will submit my changes for those in a separate patch.
>
> - Jeff
>
>
> bfd/ChangeLog:
>
> 2003-06-06 Jeff Baker <jbaker@qnx.com>
>
> * Makefile.am: Added rules for elf32-mipsnto.lo and
> elfxx-mipsnto.lo.
> * Makefile.in: Added rules for elf32-mipsnto.lo and
> elfxx-mipsnto.lo.
> * config.bfd: Added MIPS QNX Neutrino targets.
> * configure: Added QNX Neutrino vectors
> * configure.in: Added QNX Neutrino vectors
> * targets.c: Added QNX Neutrino vector variables.
> * elf32-mipsnto.c: New file. (Copy of elf32-mips.c) QNX Neutrino
> MIPS support.
> * elfxx-mipsnto.c: New file. (Copy of elfxx-mips.c) QNX Neutrino
> MIPS support.
>
>
> Index: Makefile.am
> ===================================================================
> RCS file: /cvs/src/src/bfd/Makefile.am,v
> retrieving revision 1.121
> diff -u -r1.121 Makefile.am
> --- Makefile.am 29 May 2003 15:05:40 -0000 1.121
> +++ Makefile.am 6 Jun 2003 19:09:42 -0000
> @@ -238,7 +238,9 @@
> elf-m10300.lo \
> elf32-mcore.lo \
> elfxx-mips.lo \
> + elfxx-mipsnto.lo \
> elf32-mips.lo \
> + elf32-mipsnto.lo \
> elf32-msp430.lo \
> elf32-openrisc.lo \
> elf32-or32.lo \
> @@ -401,7 +403,9 @@
> elf-m10300.c \
> elf32-mcore.c \
> elfxx-mips.c \
> + elfxx-mipsnto.c \
> elf32-mips.c \
> + elf32-mipsnto.c \
> elf32-msp430.c \
> elf32-openrisc.c \
> elf32-or32.c \
> @@ -1241,6 +1245,18 @@
> elf32-mips.lo: elf32-mips.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
> genlink.h elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
> $(INCDIR)/elf/external.h elfxx-mips.h $(INCDIR)/elf/mips.h \
> + $(INCDIR)/elf/reloc-macros.h $(INCDIR)/coff/sym.h
> $(INCDIR)/coff/symconst.h \
> + $(INCDIR)/coff/internal.h $(INCDIR)/coff/ecoff.h $(INCDIR)/coff/mips.h
> \
> + $(INCDIR)/coff/external.h ecoffswap.h elf32-target.h
> +elfxx-mipsnto.lo: elfxx-mipsnto.c $(INCDIR)/filenames.h
> $(INCDIR)/libiberty.h \
> + elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
> + $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h elfxx-mips.h \
> + $(INCDIR)/elf/mips.h $(INCDIR)/elf/reloc-macros.h $(INCDIR)/coff/sym.h
> \
> + $(INCDIR)/coff/symconst.h $(INCDIR)/coff/ecoff.h $(INCDIR)/coff/mips.h
> \
> + $(INCDIR)/coff/external.h $(INCDIR)/hashtab.h
> +elf32-mipsnto.lo: elf32-mipsnto.c $(INCDIR)/filenames.h
> $(INCDIR)/bfdlink.h
> \
> + genlink.h elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
> + $(INCDIR)/elf/external.h elfxx-mips.h $(INCDIR)/elf/mips.h \
> $(INCDIR)/elf/reloc-macros.h $(INCDIR)/coff/sym.h
> $(INCDIR)/coff/symconst.h \
> $(INCDIR)/coff/internal.h $(INCDIR)/coff/ecoff.h $(INCDIR)/coff/mips.h
> \
> $(INCDIR)/coff/external.h ecoffswap.h elf32-target.h
> Index: Makefile.in
> ===================================================================
> RCS file: /cvs/src/src/bfd/Makefile.in,v
> retrieving revision 1.131
> diff -u -r1.131 Makefile.in
> --- Makefile.in 29 May 2003 15:05:40 -0000 1.131
> +++ Makefile.in 6 Jun 2003 19:09:42 -0000
> @@ -365,7 +365,9 @@
> elf-m10300.lo \
> elf32-mcore.lo \
> elfxx-mips.lo \
> + elfxx-mipsnto.lo \
> elf32-mips.lo \
> + elf32-mipsnto.lo \
> elf32-msp430.lo \
> elf32-openrisc.lo \
> elf32-or32.lo \
> @@ -529,7 +531,9 @@
> elf-m10300.c \
> elf32-mcore.c \
> elfxx-mips.c \
> + elfxx-mipsnto.c \
> elf32-mips.c \
> + elf32-mipsnto.c \
> elf32-msp430.c \
> elf32-openrisc.c \
> elf32-or32.c \
> @@ -1774,6 +1778,18 @@
> elf32-mips.lo: elf32-mips.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
> genlink.h elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
> $(INCDIR)/elf/external.h elfxx-mips.h $(INCDIR)/elf/mips.h \
> + $(INCDIR)/elf/reloc-macros.h $(INCDIR)/coff/sym.h
> $(INCDIR)/coff/symconst.h \
> + $(INCDIR)/coff/internal.h $(INCDIR)/coff/ecoff.h $(INCDIR)/coff/mips.h
> \
> + $(INCDIR)/coff/external.h ecoffswap.h elf32-target.h
> +elfxx-mipsnto.lo: elfxx-mipsnto.c $(INCDIR)/filenames.h
> $(INCDIR)/libiberty.h \
> + elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
> + $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h elfxx-mips.h \
> + $(INCDIR)/elf/mips.h $(INCDIR)/elf/reloc-macros.h $(INCDIR)/coff/sym.h
> \
> + $(INCDIR)/coff/symconst.h $(INCDIR)/coff/ecoff.h $(INCDIR)/coff/mips.h
> \
> + $(INCDIR)/coff/external.h $(INCDIR)/hashtab.h
> +elf32-mipsnto.lo: elf32-mipsnto.c $(INCDIR)/filenames.h
> $(INCDIR)/bfdlink.h
> \
> + genlink.h elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
> + $(INCDIR)/elf/external.h elfxx-mips.h $(INCDIR)/elf/mips.h \
> $(INCDIR)/elf/reloc-macros.h $(INCDIR)/coff/sym.h
> $(INCDIR)/coff/symconst.h \
> $(INCDIR)/coff/internal.h $(INCDIR)/coff/ecoff.h $(INCDIR)/coff/mips.h
> \
> $(INCDIR)/coff/external.h ecoffswap.h elf32-target.h
> Index: config.bfd
> ===================================================================
> RCS file: /cvs/src/src/bfd/config.bfd,v
> retrieving revision 1.135
> diff -u -r1.135 config.bfd
> --- config.bfd 2 Jun 2003 19:25:51 -0000 1.135
> +++ config.bfd 6 Jun 2003 19:09:42 -0000
> @@ -785,6 +785,21 @@
> targ_defvec=bfd_elf32_bigmips_vec
> targ_selvecs="bfd_elf32_littlemips_vec bfd_elf64_bigmips_vec
> bfd_elf64_littlemips_vec"
> ;;
> + mips*eb-*-nto*)
> + targ_defvec=bfd_elf32_bigmipsnto_vec
> + targ_selvecs="bfd_elf32_littlemipsnto_vec"
> + targ_cflags=-D__QNXTARGET__
> + ;;
> + mips*el-*-nto*)
> + targ_defvec=bfd_elf32_littlemipsnto_vec
> + targ_selvecs="bfd_elf32_bigmipsnto_vec"
> + targ_cflags=-D__QNXTARGET__
> + ;;
> + mips*-*-nto*)
> + targ_defvec=bfd_elf32_littlemipsnto_vec
> + targ_selvecs="bfd_elf32_bigmipsnto_vec"
> + targ_cflags=-D__QNXTARGET__
> + ;;
> mips*el-*-openbsd*)
> targ_defvec=bfd_elf32_littlemips_vec
> targ_selvecs="bfd_elf32_bigmips_vec bfd_elf64_bigmips_vec
> bfd_elf64_littlemips_vec ecoff_little_vec ecoff_big_vec"
> Index: configure
> ===================================================================
> RCS file: /cvs/src/src/bfd/configure,v
> retrieving revision 1.152
> diff -u -r1.152 configure
> --- configure 16 May 2003 16:30:20 -0000 1.152
> +++ configure 6 Jun 2003 19:09:43 -0000
> @@ -6110,6 +6110,7 @@
> bfd_elf32_bigarm_oabi_vec) tb="$tb elfarm-oabi.lo elf32.lo
$elf"
> ;;
> bfd_elf32_bigarm_vec) tb="$tb elfarm-nabi.lo elf32.lo $elf" ;;
> bfd_elf32_bigmips_vec) tb="$tb elf32-mips.lo elfxx-mips.lo elf32.lo
> $elf ecofflink.lo" ;;
> + bfd_elf32_bigmipsnto_vec) tb="$tb elf32-mipsnto.lo elfxx-
> mipsnto.lo
> elf32.lo $elf ecofflink.lo" ;;
> bfd_elf32_cris_vec) tb="$tb elf32-cris.lo elf32.lo $elf"
> ;;
> bfd_elf32_d10v_vec) tb="$tb elf32-d10v.lo elf32.lo $elf"
> ;;
> bfd_elf32_d30v_vec) tb="$tb elf32-d30v.lo elf32.lo $elf"
> ;;
> @@ -6134,6 +6135,7 @@
> bfd_elf32_littlearm_oabi_vec) tb="$tb elfarm-oabi.lo elf32.lo $elf"
> ;;
> bfd_elf32_littlearm_vec) tb="$tb elfarm-nabi.lo elf32.lo $elf" ;;
> bfd_elf32_littlemips_vec) tb="$tb elf32-mips.lo elfxx-mips.lo
> elf32.lo
> $elf ecofflink.lo" ;;
> + bfd_elf32_littlemipsnto_vec) tb="$tb elf32-mipsnto.lo
> elfxx-mipsnto.lo elf32.lo $elf ecofflink.lo" ;;
> bfd_elf32_m32r_vec) tb="$tb elf32-m32r.lo elf32.lo $elf"
> ;;
> bfd_elf32_m68hc11_vec) tb="$tb elf32-m68hc11.lo elf32-m68hc1x.lo
> elf32.lo $elf" ;;
> bfd_elf32_m68hc12_vec) tb="$tb elf32-m68hc12.lo elf32-m68hc1x.lo
> elf32.lo $elf" ;;
> Index: configure.in
> ===================================================================
> RCS file: /cvs/src/src/bfd/configure.in,v
> retrieving revision 1.131
> diff -u -r1.131 configure.in
> --- configure.in 16 May 2003 16:30:22 -0000 1.131
> +++ configure.in 6 Jun 2003 19:09:43 -0000
> @@ -572,6 +572,7 @@
> bfd_elf32_bigarm_oabi_vec) tb="$tb elfarm-oabi.lo elf32.lo
$elf"
> ;;
> bfd_elf32_bigarm_vec) tb="$tb elfarm-nabi.lo elf32.lo $elf" ;;
> bfd_elf32_bigmips_vec) tb="$tb elf32-mips.lo elfxx-mips.lo elf32.lo
> $elf ecofflink.lo" ;;
> + bfd_elf32_bigmipsnto_vec) tb="$tb elf32-mipsnto.lo elfxx-
> mipsnto.lo
> elf32.lo $elf ecofflink.lo" ;;
> bfd_elf32_cris_vec) tb="$tb elf32-cris.lo elf32.lo $elf"
> ;;
> bfd_elf32_d10v_vec) tb="$tb elf32-d10v.lo elf32.lo $elf"
> ;;
> bfd_elf32_d30v_vec) tb="$tb elf32-d30v.lo elf32.lo $elf"
> ;;
> @@ -596,6 +597,7 @@
> bfd_elf32_littlearm_oabi_vec) tb="$tb elfarm-oabi.lo elf32.lo $elf"
> ;;
> bfd_elf32_littlearm_vec) tb="$tb elfarm-nabi.lo elf32.lo $elf" ;;
> bfd_elf32_littlemips_vec) tb="$tb elf32-mips.lo elfxx-mips.lo
> elf32.lo
> $elf ecofflink.lo" ;;
> + bfd_elf32_littlemipsnto_vec) tb="$tb elf32-mipsnto.lo
> elfxx-mipsnto.lo elf32.lo $elf ecofflink.lo" ;;
> bfd_elf32_m32r_vec) tb="$tb elf32-m32r.lo elf32.lo $elf"
> ;;
> bfd_elf32_m68hc11_vec) tb="$tb elf32-m68hc11.lo elf32-m68hc1x.lo
> elf32.lo $elf" ;;
> bfd_elf32_m68hc12_vec) tb="$tb elf32-m68hc12.lo elf32-m68hc1x.lo
> elf32.lo $elf" ;;
> Index: targets.c
> ===================================================================
> RCS file: /cvs/src/src/bfd/targets.c,v
> retrieving revision 1.92
> diff -u -r1.92 targets.c
> --- targets.c 1 Apr 2003 15:50:27 -0000 1.92
> +++ targets.c 6 Jun 2003 19:09:44 -0000
> @@ -515,6 +515,7 @@
> extern const bfd_target bfd_elf32_bigarm_oabi_vec;
> extern const bfd_target bfd_elf32_bigarm_vec;
> extern const bfd_target bfd_elf32_bigmips_vec;
> +extern const bfd_target bfd_elf32_bigmipsnto_vec;
> extern const bfd_target bfd_elf32_cris_vec;
> extern const bfd_target bfd_elf32_d10v_vec;
> extern const bfd_target bfd_elf32_d30v_vec;
> @@ -539,6 +540,7 @@
> extern const bfd_target bfd_elf32_littlearm_oabi_vec;
> extern const bfd_target bfd_elf32_littlearm_vec;
> extern const bfd_target bfd_elf32_littlemips_vec;
> +extern const bfd_target bfd_elf32_littlemipsnto_vec;
> extern const bfd_target bfd_elf32_m32r_vec;
> extern const bfd_target bfd_elf32_m68hc11_vec;
> extern const bfd_target bfd_elf32_m68hc12_vec;
> @@ -803,6 +805,7 @@
> &bfd_elf32_bigarm_oabi_vec,
> &bfd_elf32_bigarm_vec,
> &bfd_elf32_bigmips_vec,
> + &bfd_elf32_bigmipsnto_vec,
> &bfd_elf32_cris_vec,
> &bfd_elf32_d10v_vec,
> &bfd_elf32_d30v_vec,
> @@ -829,6 +832,7 @@
> &bfd_elf32_littlearm_oabi_vec,
> &bfd_elf32_littlearm_vec,
> &bfd_elf32_littlemips_vec,
> + &bfd_elf32_littlemipsnto_vec,
> &bfd_elf32_m32r_vec,
> &bfd_elf32_m68hc11_vec,
> &bfd_elf32_m68hc12_vec,