Define bfd_find_line entry of BFD_JUMP_TABLE_SYMBOLS using NAME.
[binutils-gdb.git] / bfd / ieee.c
index 3ceef357fc46de93f648dc8887d09085dcd56bd5..256e8f6693ced62b0645fe7e0122a37a99b396ee 100644 (file)
@@ -1,7 +1,5 @@
 /* BFD back-end for ieee-695 objects.
-   Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
-   2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2009
-   Free Software Foundation, Inc.
+   Copyright (C) 1990-2014 Free Software Foundation, Inc.
 
    Written by Steve Chamberlain of Cygnus Support.
 
@@ -35,6 +33,7 @@
 #include "ieee.h"
 #include "libieee.h"
 #include "safe-ctype.h"
+#include "libiberty.h"
 
 struct output_buffer_struct
 {
@@ -533,6 +532,7 @@ parse_expression (ieee_data_type *ieee,
            next_byte (&(ieee->h));
            *pcrel = TRUE;
            section_n = must_parse_int (&(ieee->h));
+           (void) section_n;
            PUSH (NOSYMBOL, bfd_abs_section_ptr, 0);
            break;
          }
@@ -637,6 +637,8 @@ parse_expression (ieee_data_type *ieee,
       ieee_symbol_index_type sy1;
 
       POP (sy1, section1, *extra);
+      (void) section1;
+      (void) sy1;
     }
 
   POP (*symbol, dummy, *value);
@@ -776,6 +778,7 @@ ieee_slurp_external_symbols (bfd *abfd)
              case ieee_attribute_record_enum:
                symbol_name_index = must_parse_int (&(ieee->h));
                symbol_type_index = must_parse_int (&(ieee->h));
+               (void) symbol_type_index;
                symbol_attribute_def = must_parse_int (&(ieee->h));
                switch (symbol_attribute_def)
                  {
@@ -850,6 +853,7 @@ ieee_slurp_external_symbols (bfd *abfd)
            next_byte (&(ieee->h));
 
            symbol_name_index = must_parse_int (&(ieee->h));
+           (void) symbol_name_index;
            parse_expression (ieee,
                              &symbol->symbol.value,
                              &symbol_ignore,
@@ -1657,7 +1661,7 @@ ieee_slurp_section_data (bfd *abfd)
   unsigned int section_number;
   ieee_per_section_type *current_map = NULL;
   asection *s;
-  
+
   /* Seek to the start of the data area.  */
   if (ieee->read_data)
     return TRUE;
@@ -1819,7 +1823,7 @@ ieee_object_p (bfd *abfd)
     goto got_wrong_format;
   ieee->mb.module_name = read_id (&(ieee->h));
   if (abfd->filename == (const char *) NULL)
-    abfd->filename = ieee->mb.module_name;
+    abfd->filename = xstrdup (ieee->mb.module_name);
 
   /* Determine the architecture and machine type of the object file.  */
   {
@@ -2669,6 +2673,7 @@ drop_int (struct output_buffer_struct *buf)
          break;
        }
     }
+  (void) ch;
   OUT (0x84);
   buf->ptrp = output_ptr;
   buf->buffer = output_buffer;
@@ -3670,26 +3675,9 @@ ieee_openr_next_archived_file (bfd *arch, bfd *prev)
     }
 }
 
-static bfd_boolean
-ieee_find_nearest_line (bfd *abfd ATTRIBUTE_UNUSED,
-                       asection *section ATTRIBUTE_UNUSED,
-                       asymbol **symbols ATTRIBUTE_UNUSED,
-                       bfd_vma offset ATTRIBUTE_UNUSED,
-                       const char **filename_ptr ATTRIBUTE_UNUSED,
-                       const char **functionname_ptr ATTRIBUTE_UNUSED,
-                       unsigned int *line_ptr ATTRIBUTE_UNUSED)
-{
-  return FALSE;
-}
-
-static bfd_boolean
-ieee_find_inliner_info (bfd *abfd ATTRIBUTE_UNUSED,
-                       const char **filename_ptr ATTRIBUTE_UNUSED,
-                       const char **functionname_ptr ATTRIBUTE_UNUSED,
-                       unsigned int *line_ptr ATTRIBUTE_UNUSED)
-{
-  return FALSE;
-}
+#define ieee_find_nearest_line _bfd_nosymbols_find_nearest_line
+#define ieee_find_line         _bfd_nosymbols_find_line
+#define ieee_find_inliner_info _bfd_nosymbols_find_inliner_info
 
 static int
 ieee_generic_stat_arch_elt (bfd *abfd, struct stat *buf)
@@ -3766,6 +3754,7 @@ ieee_sizeof_headers (bfd *abfd ATTRIBUTE_UNUSED,
   bfd_generic_get_relocated_section_contents
 #define ieee_bfd_relax_section bfd_generic_relax_section
 #define ieee_bfd_gc_sections bfd_generic_gc_sections
+#define ieee_bfd_lookup_section_flags bfd_generic_lookup_section_flags
 #define ieee_bfd_merge_sections bfd_generic_merge_sections
 #define ieee_bfd_is_group_section bfd_generic_is_group_section
 #define ieee_bfd_discard_group bfd_generic_discard_group
@@ -3773,7 +3762,6 @@ ieee_sizeof_headers (bfd *abfd ATTRIBUTE_UNUSED,
   _bfd_generic_section_already_linked
 #define ieee_bfd_define_common_symbol bfd_generic_define_common_symbol
 #define ieee_bfd_link_hash_table_create _bfd_generic_link_hash_table_create
-#define ieee_bfd_link_hash_table_free _bfd_generic_link_hash_table_free
 #define ieee_bfd_link_add_symbols _bfd_generic_link_add_symbols
 #define ieee_bfd_link_just_syms _bfd_generic_link_just_syms
 #define ieee_bfd_copy_link_hash_symbol_type \
@@ -3795,6 +3783,7 @@ const bfd_target ieee_vec =
   '_',                         /* Leading underscore.  */
   ' ',                         /* AR_pad_char.  */
   16,                          /* AR_max_namelen.  */
+  0,                           /* match priority.  */
   bfd_getb64, bfd_getb_signed_64, bfd_putb64,
   bfd_getb32, bfd_getb_signed_32, bfd_putb32,
   bfd_getb16, bfd_getb_signed_16, bfd_putb16,  /* Data.  */
@@ -3850,7 +3839,6 @@ const bfd_target ieee_vec =
 
   /* ieee_sizeof_headers, ieee_bfd_get_relocated_section_contents,
      ieee_bfd_relax_section, ieee_bfd_link_hash_table_create,
-     _bfd_generic_link_hash_table_free,
      ieee_bfd_link_add_symbols, ieee_bfd_final_link,
      ieee_bfd_link_split_section, ieee_bfd_gc_sections,
      ieee_bfd_merge_sections.  */