This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
_bfd_norelocs
- From: Alan Modra <amodra at bigpond dot net dot au>
- To: binutils at sourceware dot org
- Date: Thu, 15 Feb 2007 19:04:49 +1030
- Subject: _bfd_norelocs
I believe _bfd_norelocs_get_reloc_upper_bound and
_bfd_norelocs_canonicalize_reloc are wrong in returning -1, an error
indication. Instead they ought to return space for a NULL terminator
and a reloc count of zero, as implemented in mmo.c. This patch moves
the mmo.c code into libbfd.c and makes use of the corrected functions
in a number of target files.
* libbfd-in.h (_bfd_norelocs_get_reloc_upper_bound): Don't define,
declare.
(_bfd_norelocs_canonicalize_reloc): Likewise.
* libbfd.h: Regenerate.
* libbfd.c (_bfd_norelocs_get_reloc_upper_bound): New function.
(_bfd_norelocs_canonicalize_reloc): Likewise.
* binary.c (binary_bfd_reloc_type_lookup): Don't define.
(binary_get_reloc_upper_bound, binary_canonicalize_reloc): Likewise.
(binary_vec): Use _bfd_norelocs in BFD_JUMP_TABLE_RELOCS.
* ihex.c: Similarly.
* mach-o-target.c: Similarly.
* mach-o.c: Similarly.
* mmo.c: Similarly.
* pef.c: Similarly.
* ppcboot.c: Similarly.
* srec.c: Similarly.
* xsym.c: Similarly.
Index: bfd/libbfd-in.h
===================================================================
RCS file: /cvs/src/src/bfd/libbfd-in.h,v
retrieving revision 1.68
diff -u -p -r1.68 libbfd-in.h
--- bfd/libbfd-in.h 3 Nov 2006 00:58:10 -0000 1.68
+++ bfd/libbfd-in.h 15 Feb 2007 08:19:27 -0000
@@ -2,7 +2,7 @@
(This include file is not for users of the library.)
Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
- 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006
+ 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
Free Software Foundation, Inc.
Written by Cygnus Support.
@@ -348,10 +348,9 @@ extern bfd_boolean _bfd_archive_coff_con
/* Routines to use for BFD_JUMP_TABLE_RELOCS when there is no reloc
support. Use BFD_JUMP_TABLE_RELOCS (_bfd_norelocs). */
-#define _bfd_norelocs_get_reloc_upper_bound \
- ((long (*) (bfd *, asection *)) _bfd_n1)
-#define _bfd_norelocs_canonicalize_reloc \
- ((long (*) (bfd *, asection *, arelent **, asymbol **)) _bfd_n1)
+extern long _bfd_norelocs_get_reloc_upper_bound (bfd *, asection *);
+extern long _bfd_norelocs_canonicalize_reloc (bfd *, asection *,
+ arelent **, asymbol **);
#define _bfd_norelocs_bfd_reloc_type_lookup \
((reloc_howto_type *(*) (bfd *, bfd_reloc_code_real_type)) bfd_nullvoidptr)
Index: bfd/libbfd.c
===================================================================
RCS file: /cvs/src/src/bfd/libbfd.c,v
retrieving revision 1.44
diff -u -p -r1.44 libbfd.c
--- bfd/libbfd.c 24 Nov 2005 06:02:07 -0000 1.44
+++ bfd/libbfd.c 15 Feb 2007 08:19:30 -0000
@@ -1,6 +1,6 @@
/* Assorted BFD support routines, only used internally.
Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000, 2001, 2002, 2003, 2004, 2005
+ 2000, 2001, 2002, 2003, 2004, 2005, 2007
Free Software Foundation, Inc.
Written by Cygnus Support.
@@ -103,6 +103,23 @@ bfd_void (bfd *ignore ATTRIBUTE_UNUSED)
{
}
+long
+_bfd_norelocs_get_reloc_upper_bound (bfd *abfd ATTRIBUTE_UNUSED,
+ asection *sec ATTRIBUTE_UNUSED)
+{
+ return sizeof (arelent *);
+}
+
+long
+_bfd_norelocs_canonicalize_reloc (bfd *abfd ATTRIBUTE_UNUSED,
+ asection *sec ATTRIBUTE_UNUSED,
+ arelent **relptr,
+ asymbol **symbols ATTRIBUTE_UNUSED)
+{
+ *relptr = NULL;
+ return 0;
+}
+
bfd_boolean
_bfd_nocore_core_file_matches_executable_p
(bfd *ignore_core_bfd ATTRIBUTE_UNUSED,
Index: bfd/binary.c
===================================================================
RCS file: /cvs/src/src/bfd/binary.c,v
retrieving revision 1.30
diff -u -p -r1.30 binary.c
--- bfd/binary.c 19 Jun 2006 13:17:43 -0000 1.30
+++ bfd/binary.c 15 Feb 2007 08:17:48 -0000
@@ -1,6 +1,6 @@
/* BFD back-end for binary objects.
Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003,
- 2004, 2005, 2006 Free Software Foundation, Inc.
+ 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
Written by Ian Lance Taylor, Cygnus Support, <ian@cygnus.com>
This file is part of BFD, the Binary File Descriptor library.
@@ -221,9 +221,6 @@ binary_get_symbol_info (bfd *ignore_abfd
#define binary_bfd_make_debug_symbol _bfd_nosymbols_bfd_make_debug_symbol
#define binary_read_minisymbols _bfd_generic_read_minisymbols
#define binary_minisymbol_to_symbol _bfd_generic_minisymbol_to_symbol
-#define binary_bfd_reloc_type_lookup _bfd_norelocs_bfd_reloc_type_lookup
-#define binary_get_reloc_upper_bound ((long (*) (bfd *, asection *)) bfd_0l)
-#define binary_canonicalize_reloc ((long (*) (bfd *, asection *, arelent **, asymbol **)) bfd_0l)
#define binary_bfd_is_target_special_symbol ((bfd_boolean (*) (bfd *, asymbol *)) bfd_false)
/* Set the architecture of a binary file. */
@@ -368,7 +365,7 @@ const bfd_target binary_vec =
BFD_JUMP_TABLE_CORE (_bfd_nocore),
BFD_JUMP_TABLE_ARCHIVE (_bfd_noarchive),
BFD_JUMP_TABLE_SYMBOLS (binary),
- BFD_JUMP_TABLE_RELOCS (binary),
+ BFD_JUMP_TABLE_RELOCS (_bfd_norelocs),
BFD_JUMP_TABLE_WRITE (binary),
BFD_JUMP_TABLE_LINK (binary),
BFD_JUMP_TABLE_DYNAMIC (_bfd_nodynamic),
Index: bfd/ihex.c
===================================================================
RCS file: /cvs/src/src/bfd/ihex.c,v
retrieving revision 1.33
diff -u -p -r1.33 ihex.c
--- bfd/ihex.c 19 Jun 2006 13:17:43 -0000 1.33
+++ bfd/ihex.c 15 Feb 2007 08:19:26 -0000
@@ -1,6 +1,6 @@
/* BFD back-end for Intel Hex objects.
Copyright 1995, 1996, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005,
- 2006 Free Software Foundation, Inc.
+ 2006, 2007 Free Software Foundation, Inc.
Written by Ian Lance Taylor of Cygnus Support <ian@cygnus.com>.
This file is part of BFD, the Binary File Descriptor library.
@@ -924,9 +924,6 @@ ihex_sizeof_headers (bfd *abfd ATTRIBUTE
#define ihex_bfd_make_debug_symbol _bfd_nosymbols_bfd_make_debug_symbol
#define ihex_read_minisymbols _bfd_nosymbols_read_minisymbols
#define ihex_minisymbol_to_symbol _bfd_nosymbols_minisymbol_to_symbol
-#define ihex_get_reloc_upper_bound ((long (*) (bfd *, asection *)) bfd_0l)
-#define ihex_canonicalize_reloc ((long (*) (bfd *, asection *, arelent **, asymbol **)) bfd_0l)
-#define ihex_bfd_reloc_type_lookup _bfd_norelocs_bfd_reloc_type_lookup
#define ihex_bfd_get_relocated_section_contents bfd_generic_get_relocated_section_contents
#define ihex_bfd_relax_section bfd_generic_relax_section
#define ihex_bfd_gc_sections bfd_generic_gc_sections
@@ -985,7 +982,7 @@ const bfd_target ihex_vec =
BFD_JUMP_TABLE_CORE (_bfd_nocore),
BFD_JUMP_TABLE_ARCHIVE (_bfd_noarchive),
BFD_JUMP_TABLE_SYMBOLS (ihex),
- BFD_JUMP_TABLE_RELOCS (ihex),
+ BFD_JUMP_TABLE_RELOCS (_bfd_norelocs),
BFD_JUMP_TABLE_WRITE (ihex),
BFD_JUMP_TABLE_LINK (ihex),
BFD_JUMP_TABLE_DYNAMIC (_bfd_nodynamic),
Index: bfd/mach-o-target.c
===================================================================
RCS file: /cvs/src/src/bfd/mach-o-target.c,v
retrieving revision 1.3
diff -u -p -r1.3 mach-o-target.c
--- bfd/mach-o-target.c 4 May 2005 15:53:35 -0000 1.3
+++ bfd/mach-o-target.c 15 Feb 2007 08:19:30 -0000
@@ -1,5 +1,5 @@
/* Mach-O support for BFD.
- Copyright 1999, 2000, 2001, 2002
+ Copyright 1999, 2000, 2001, 2002, 2007
Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
@@ -105,7 +105,7 @@ const bfd_target TARGET_NAME =
BFD_JUMP_TABLE_CORE (bfd_mach_o),
BFD_JUMP_TABLE_ARCHIVE (bfd_mach_o),
BFD_JUMP_TABLE_SYMBOLS (bfd_mach_o),
- BFD_JUMP_TABLE_RELOCS (bfd_mach_o),
+ BFD_JUMP_TABLE_RELOCS (_bfd_norelocs),
BFD_JUMP_TABLE_WRITE (bfd_mach_o),
BFD_JUMP_TABLE_LINK (bfd_mach_o),
BFD_JUMP_TABLE_DYNAMIC (_bfd_nodynamic),
Index: bfd/mach-o.c
===================================================================
RCS file: /cvs/src/src/bfd/mach-o.c,v
retrieving revision 1.22
diff -u -p -r1.22 mach-o.c
--- bfd/mach-o.c 19 Jun 2006 13:17:43 -0000 1.22
+++ bfd/mach-o.c 15 Feb 2007 08:19:30 -0000
@@ -1,5 +1,5 @@
/* Mach-O support for BFD.
- Copyright 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006
+ Copyright 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
@@ -52,9 +52,6 @@
#define bfd_mach_o_bfd_make_debug_symbol _bfd_nosymbols_bfd_make_debug_symbol
#define bfd_mach_o_read_minisymbols _bfd_generic_read_minisymbols
#define bfd_mach_o_minisymbol_to_symbol _bfd_generic_minisymbol_to_symbol
-#define bfd_mach_o_get_reloc_upper_bound _bfd_norelocs_get_reloc_upper_bound
-#define bfd_mach_o_canonicalize_reloc _bfd_norelocs_canonicalize_reloc
-#define bfd_mach_o_bfd_reloc_type_lookup _bfd_norelocs_bfd_reloc_type_lookup
#define bfd_mach_o_bfd_get_relocated_section_contents bfd_generic_get_relocated_section_contents
#define bfd_mach_o_bfd_relax_section bfd_generic_relax_section
#define bfd_mach_o_bfd_link_hash_table_create _bfd_generic_link_hash_table_create
Index: bfd/mmo.c
===================================================================
RCS file: /cvs/src/src/bfd/mmo.c,v
retrieving revision 1.33
diff -u -p -r1.33 mmo.c
--- bfd/mmo.c 20 Nov 2006 02:09:56 -0000 1.33
+++ bfd/mmo.c 15 Feb 2007 08:19:31 -0000
@@ -1,5 +1,5 @@
/* BFD back-end for mmo objects (MMIX-specific object-format).
- Copyright 2001, 2002, 2003, 2004, 2005, 2006
+ Copyright 2001, 2002, 2003, 2004, 2005, 2006, 2007
Free Software Foundation, Inc.
Written by Hans-Peter Nilsson (hp@bitrange.com).
Infrastructure and other bits originally copied from srec.c and
@@ -388,7 +388,6 @@ static void mmo_print_symbol (bfd *, voi
static bfd_boolean mmo_set_section_contents (bfd *, sec_ptr, const void *,
file_ptr, bfd_size_type);
static int mmo_sizeof_headers (bfd *, struct bfd_link_info *);
-static long mmo_get_reloc_upper_bound (bfd *, asection *);
static bfd_boolean mmo_internal_write_header (bfd *);
static bfd_boolean mmo_internal_write_post (bfd *, int, asection *);
static bfd_boolean mmo_internal_add_3_sym (bfd *, struct mmo_symbol_trie *,
@@ -415,7 +414,6 @@ static void mmo_write_byte (bfd *, bfd_b
static bfd_boolean mmo_new_section_hook (bfd *, asection *);
static int mmo_sort_mmo_symbols (const void *, const void *);
static bfd_boolean mmo_write_object_contents (bfd *);
-static long mmo_canonicalize_reloc (bfd *, sec_ptr, arelent **, asymbol **);
static bfd_boolean mmo_write_section_description (bfd *, asection *);
static bfd_boolean mmo_has_leading_or_trailing_zero_tetra_p (bfd *,
asection *);
@@ -3161,28 +3159,6 @@ mmo_write_object_contents (bfd *abfd)
return mmo_write_symbols_and_terminator (abfd);
}
-/* Return the size of a NULL pointer, so we support linking in an mmo
- object. */
-
-static long
-mmo_get_reloc_upper_bound (bfd *abfd ATTRIBUTE_UNUSED,
- asection *sec ATTRIBUTE_UNUSED)
-{
- return sizeof (void *);
-}
-
-/* Similarly canonicalize relocs to empty, filling in the terminating NULL
- pointer. */
-
-long
-mmo_canonicalize_reloc (bfd *abfd ATTRIBUTE_UNUSED,
- sec_ptr section ATTRIBUTE_UNUSED, arelent **relptr,
- asymbol **symbols ATTRIBUTE_UNUSED)
-{
- *relptr = NULL;
- return 0;
-}
-
/* If there's anything in particular in a mmo bfd that we want to free,
make this a real function. Only do this if you see major memory
thrashing; zealous free:ing will cause unwanted behavior, especially if
@@ -3234,18 +3210,6 @@ mmo_canonicalize_reloc (bfd *abfd ATTRIB
#define mmo_section_already_linked \
_bfd_generic_section_already_linked
-/* objcopy will be upset if we return -1 from bfd_get_reloc_upper_bound by
- using BFD_JUMP_TABLE_RELOCS (_bfd_norelocs) rather than 0. FIXME: Most
- likely a bug in the _bfd_norelocs definition.
-
- On the other hand, we smuggle in an mmo object (because setting up ELF
- is too cumbersome) when linking (from other formats, presumably ELF) to
- represent the g255 entry. We need to link that object, so need to say
- it has no relocs. Upper bound for the size of the relocation table is
- the size of a NULL pointer, and we support "canonicalization" for that
- pointer. */
-#define mmo_bfd_reloc_type_lookup _bfd_norelocs_bfd_reloc_type_lookup
-
/* We want to copy time of creation, otherwise we'd use
BFD_JUMP_TABLE_COPY (_bfd_generic). */
#define mmo_bfd_merge_private_bfd_data _bfd_generic_bfd_merge_private_bfd_data
@@ -3305,9 +3269,7 @@ const bfd_target bfd_mmo_vec =
BFD_JUMP_TABLE_CORE (_bfd_nocore),
BFD_JUMP_TABLE_ARCHIVE (_bfd_noarchive),
BFD_JUMP_TABLE_SYMBOLS (mmo),
- /* We have to provide a valid method for getting relocs, returning zero,
- so we can't say BFD_JUMP_TABLE_RELOCS (_bfd_norelocs). */
- BFD_JUMP_TABLE_RELOCS (mmo),
+ BFD_JUMP_TABLE_RELOCS (_bfd_norelocs),
BFD_JUMP_TABLE_WRITE (mmo),
BFD_JUMP_TABLE_LINK (mmo),
BFD_JUMP_TABLE_DYNAMIC (_bfd_nodynamic),
Index: bfd/pef.c
===================================================================
RCS file: /cvs/src/src/bfd/pef.c,v
retrieving revision 1.20
diff -u -p -r1.20 pef.c
--- bfd/pef.c 22 Nov 2006 03:33:51 -0000 1.20
+++ bfd/pef.c 15 Feb 2007 08:19:35 -0000
@@ -1,5 +1,5 @@
/* PEF support for BFD.
- Copyright 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006
+ Copyright 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
@@ -41,9 +41,6 @@
#define bfd_pef_bfd_make_debug_symbol _bfd_nosymbols_bfd_make_debug_symbol
#define bfd_pef_read_minisymbols _bfd_generic_read_minisymbols
#define bfd_pef_minisymbol_to_symbol _bfd_generic_minisymbol_to_symbol
-#define bfd_pef_get_reloc_upper_bound _bfd_norelocs_get_reloc_upper_bound
-#define bfd_pef_canonicalize_reloc _bfd_norelocs_canonicalize_reloc
-#define bfd_pef_bfd_reloc_type_lookup _bfd_norelocs_bfd_reloc_type_lookup
#define bfd_pef_set_arch_mach _bfd_generic_set_arch_mach
#define bfd_pef_get_section_contents _bfd_generic_get_section_contents
#define bfd_pef_set_section_contents _bfd_generic_set_section_contents
@@ -1048,7 +1045,7 @@ const bfd_target pef_vec =
BFD_JUMP_TABLE_CORE (_bfd_nocore),
BFD_JUMP_TABLE_ARCHIVE (_bfd_noarchive),
BFD_JUMP_TABLE_SYMBOLS (bfd_pef),
- BFD_JUMP_TABLE_RELOCS (bfd_pef),
+ BFD_JUMP_TABLE_RELOCS (_bfd_norelocs),
BFD_JUMP_TABLE_WRITE (bfd_pef),
BFD_JUMP_TABLE_LINK (bfd_pef),
BFD_JUMP_TABLE_DYNAMIC (_bfd_nodynamic),
Index: bfd/ppcboot.c
===================================================================
RCS file: /cvs/src/src/bfd/ppcboot.c,v
retrieving revision 1.26
diff -u -p -r1.26 ppcboot.c
--- bfd/ppcboot.c 19 Jun 2006 13:17:43 -0000 1.26
+++ bfd/ppcboot.c 15 Feb 2007 08:19:35 -0000
@@ -1,6 +1,6 @@
/* BFD back-end for PPCbug boot records.
- Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2006
- Free Software Foundation, Inc.
+ Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2006,
+ 2007 Free Software Foundation, Inc.
Written by Michael Meissner, Cygnus Support, <meissner@cygnus.com>
This file is part of BFD, the Binary File Descriptor library.
@@ -354,12 +354,6 @@ ppcboot_get_symbol_info (ignore_abfd, sy
#define ppcboot_bfd_make_debug_symbol _bfd_nosymbols_bfd_make_debug_symbol
#define ppcboot_read_minisymbols _bfd_generic_read_minisymbols
#define ppcboot_minisymbol_to_symbol _bfd_generic_minisymbol_to_symbol
-
-#define ppcboot_get_reloc_upper_bound \
- ((long (*) PARAMS ((bfd *, asection *))) bfd_0l)
-#define ppcboot_canonicalize_reloc \
- ((long (*) PARAMS ((bfd *, asection *, arelent **, asymbol **))) bfd_0l)
-#define ppcboot_bfd_reloc_type_lookup _bfd_norelocs_bfd_reloc_type_lookup
/* Write section contents of a ppcboot file. */
@@ -534,7 +528,7 @@ const bfd_target ppcboot_vec =
BFD_JUMP_TABLE_CORE (_bfd_nocore),
BFD_JUMP_TABLE_ARCHIVE (_bfd_noarchive),
BFD_JUMP_TABLE_SYMBOLS (ppcboot),
- BFD_JUMP_TABLE_RELOCS (ppcboot),
+ BFD_JUMP_TABLE_RELOCS (_bfd_norelocs),
BFD_JUMP_TABLE_WRITE (ppcboot),
BFD_JUMP_TABLE_LINK (ppcboot),
BFD_JUMP_TABLE_DYNAMIC (_bfd_nodynamic),
Index: bfd/srec.c
===================================================================
RCS file: /cvs/src/src/bfd/srec.c,v
retrieving revision 1.39
diff -u -p -r1.39 srec.c
--- bfd/srec.c 19 Jun 2006 13:17:43 -0000 1.39
+++ bfd/srec.c 15 Feb 2007 08:19:42 -0000
@@ -1,6 +1,6 @@
/* BFD back-end for s-record objects.
Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000, 2001, 2002, 2003, 2004, 2005, 2006
+ 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
Free Software Foundation, Inc.
Written by Steve Chamberlain of Cygnus Support <sac@cygnus.com>.
@@ -1194,9 +1194,6 @@ srec_print_symbol (bfd *abfd,
#define srec_bfd_make_debug_symbol _bfd_nosymbols_bfd_make_debug_symbol
#define srec_read_minisymbols _bfd_generic_read_minisymbols
#define srec_minisymbol_to_symbol _bfd_generic_minisymbol_to_symbol
-#define srec_get_reloc_upper_bound ((long (*) (bfd *, asection *)) bfd_0l)
-#define srec_canonicalize_reloc ((long (*) (bfd *, asection *, arelent **, asymbol **)) bfd_0l)
-#define srec_bfd_reloc_type_lookup _bfd_norelocs_bfd_reloc_type_lookup
#define srec_get_section_contents_in_window _bfd_generic_get_section_contents_in_window
#define srec_bfd_get_relocated_section_contents bfd_generic_get_relocated_section_contents
#define srec_bfd_relax_section bfd_generic_relax_section
@@ -1257,7 +1254,7 @@ const bfd_target srec_vec =
BFD_JUMP_TABLE_CORE (_bfd_nocore),
BFD_JUMP_TABLE_ARCHIVE (_bfd_noarchive),
BFD_JUMP_TABLE_SYMBOLS (srec),
- BFD_JUMP_TABLE_RELOCS (srec),
+ BFD_JUMP_TABLE_RELOCS (_bfd_norelocs),
BFD_JUMP_TABLE_WRITE (srec),
BFD_JUMP_TABLE_LINK (srec),
BFD_JUMP_TABLE_DYNAMIC (_bfd_nodynamic),
@@ -1312,7 +1309,7 @@ const bfd_target symbolsrec_vec =
BFD_JUMP_TABLE_CORE (_bfd_nocore),
BFD_JUMP_TABLE_ARCHIVE (_bfd_noarchive),
BFD_JUMP_TABLE_SYMBOLS (srec),
- BFD_JUMP_TABLE_RELOCS (srec),
+ BFD_JUMP_TABLE_RELOCS (_bfd_norelocs),
BFD_JUMP_TABLE_WRITE (srec),
BFD_JUMP_TABLE_LINK (srec),
BFD_JUMP_TABLE_DYNAMIC (_bfd_nodynamic),
Index: bfd/xsym.c
===================================================================
RCS file: /cvs/src/src/bfd/xsym.c,v
retrieving revision 1.19
diff -u -p -r1.19 xsym.c
--- bfd/xsym.c 22 Nov 2006 03:33:51 -0000 1.19
+++ bfd/xsym.c 15 Feb 2007 08:19:47 -0000
@@ -1,5 +1,5 @@
/* xSYM symbol-file support for BFD.
- Copyright 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006
+ Copyright 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
@@ -34,9 +34,6 @@
#define bfd_sym_bfd_make_debug_symbol _bfd_nosymbols_bfd_make_debug_symbol
#define bfd_sym_read_minisymbols _bfd_generic_read_minisymbols
#define bfd_sym_minisymbol_to_symbol _bfd_generic_minisymbol_to_symbol
-#define bfd_sym_get_reloc_upper_bound _bfd_norelocs_get_reloc_upper_bound
-#define bfd_sym_canonicalize_reloc _bfd_norelocs_canonicalize_reloc
-#define bfd_sym_bfd_reloc_type_lookup _bfd_norelocs_bfd_reloc_type_lookup
#define bfd_sym_set_arch_mach _bfd_generic_set_arch_mach
#define bfd_sym_get_section_contents _bfd_generic_get_section_contents
#define bfd_sym_set_section_contents _bfd_generic_set_section_contents
@@ -2346,7 +2343,7 @@ const bfd_target sym_vec =
BFD_JUMP_TABLE_CORE (_bfd_nocore),
BFD_JUMP_TABLE_ARCHIVE (_bfd_noarchive),
BFD_JUMP_TABLE_SYMBOLS (bfd_sym),
- BFD_JUMP_TABLE_RELOCS (bfd_sym),
+ BFD_JUMP_TABLE_RELOCS (_bfd_norelocs),
BFD_JUMP_TABLE_WRITE (bfd_sym),
BFD_JUMP_TABLE_LINK (bfd_sym),
BFD_JUMP_TABLE_DYNAMIC (_bfd_nodynamic),
--
Alan Modra
IBM OzLabs - Linux Technology Centre