daily update
[deliverable/binutils-gdb.git] / bfd / elf-hppa.h
index f5aba51e55f78f51164b601b604d405ac5b3e07c..1e280b71efdfa679269cad69a19b6d7f68b9fd24 100644 (file)
@@ -1,5 +1,6 @@
 /* Common code for PA ELF implementations.
-   Copyright 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
+   Copyright 1999, 2000, 2001, 2002, 2003, 2004
+   Free Software Foundation, Inc.
 
 This file is part of BFD, the Binary File Descriptor library.
 
@@ -31,7 +32,6 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
 #define elf_hppa_reloc_final_type elf64_hppa_reloc_final_type
 #define _bfd_elf_hppa_gen_reloc_type _bfd_elf64_hppa_gen_reloc_type
 #define elf_hppa_relocate_section elf64_hppa_relocate_section
-#define bfd_elf_bfd_final_link bfd_elf64_bfd_final_link
 #define elf_hppa_final_link elf64_hppa_final_link
 #endif
 #if ARCH_SIZE == 32
@@ -40,7 +40,6 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
 #define elf_hppa_reloc_final_type elf32_hppa_reloc_final_type
 #define _bfd_elf_hppa_gen_reloc_type _bfd_elf32_hppa_gen_reloc_type
 #define elf_hppa_relocate_section elf32_hppa_relocate_section
-#define bfd_elf_bfd_final_link bfd_elf32_bfd_final_link
 #define elf_hppa_final_link elf32_hppa_final_link
 #endif
 
@@ -1043,16 +1042,12 @@ static bfd_boolean elf_hppa_sort_unwind (bfd *abfd)
   if (s != NULL)
     {
       bfd_size_type size;
-      char *contents;
+      bfd_byte *contents;
 
-      size = s->_raw_size;
-      contents = bfd_malloc (size);
-      if (contents == NULL)
-       return FALSE;
-
-      if (! bfd_get_section_contents (abfd, s, contents, (file_ptr) 0, size))
+      if (!bfd_malloc_and_get_section (abfd, s, &contents))
        return FALSE;
 
+      size = s->size;
       qsort (contents, (size_t) (size / 16), 16, hppa_unwind_entry_compare);
 
       if (! bfd_set_section_contents (abfd, s, contents, (file_ptr) 0, size))
@@ -1070,7 +1065,7 @@ static bfd_boolean elf_hppa_sort_unwind (bfd *abfd)
 static bfd_boolean
 elf_hppa_add_symbol_hook (bfd *abfd,
                          struct bfd_link_info *info ATTRIBUTE_UNUSED,
-                         const Elf_Internal_Sym *sym,
+                         Elf_Internal_Sym *sym,
                          const char **namep ATTRIBUTE_UNUSED,
                          flagword *flagsp ATTRIBUTE_UNUSED,
                          asection **secp,
@@ -1294,7 +1289,7 @@ elf_hppa_final_link (bfd *abfd, struct bfd_link_info *info)
                          info);
 
   /* Invoke the regular ELF backend linker to do all the work.  */
-  retval = bfd_elf_bfd_final_link (abfd, info);
+  retval = bfd_elf_final_link (abfd, info);
 
   elf_link_hash_traverse (elf_hash_table (info),
                          elf_hppa_remark_useless_dynamic_symbols,
This page took 0.024177 seconds and 4 git commands to generate.