Add missing ChangeLog entry
[deliverable/binutils-gdb.git] / bfd / libecoff.h
index 1b9d9a23bc36bc2bd10197814e3364d3602a0148..eb90a8cddb91160b6f8954503d61e3d1a34dcbfe 100644 (file)
@@ -1,5 +1,6 @@
 /* BFD ECOFF object file private structure.
-   Copyright (C) 1993 Free Software Foundation, Inc.
+   Copyright 1993, 1994, 1995, 1996, 1999, 2001, 2002
+   Free Software Foundation, Inc.
    Written by Ian Lance Taylor, Cygnus Support.
 
 This file is part of BFD, the Binary File Descriptor library.
@@ -16,7 +17,7 @@ GNU General Public License for more details.
 
 You should have received a copy of the GNU General Public License
 along with this program; if not, write to the Free Software
-Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.  */
+Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
 
 #include "bfdlink.h"
 
@@ -68,6 +69,12 @@ struct ecoff_backend_data
                                       bfd *input_bfd, asection *input_section,
                                       bfd_byte *contents,
                                       PTR external_relocs));
+  /* Do final adjustments to filehdr and aouthdr.  */
+  boolean (*adjust_headers) PARAMS ((bfd *, struct internal_filehdr *,
+                                    struct internal_aouthdr *));
+  /* Read an element from an archive at a given file position.  This
+     is needed because OSF/1 3.2 uses a weird archive format.  */
+  bfd *(*get_elt_at_filepos) PARAMS ((bfd *, file_ptr));
 };
 
 /* This is the target specific information kept for ECOFF files.  */
@@ -94,7 +101,7 @@ typedef struct ecoff_tdata
   /* The maximum size of objects to optimize using gp.  This is
      typically set by the -G option to the compiler, assembler or
      linker.  */
-  int gp_size;
+  unsigned int gp_size;
 
   /* The register masks.  When linking, all the masks found in the
      input files are combined into the masks of the output file.
@@ -124,11 +131,20 @@ typedef struct ecoff_tdata
   /* True if this BFD was written by the backend linker.  */
   boolean linker;
 
+  /* True if a warning that multiple global pointer values are
+     needed in the output binary was issued already.  */
+  boolean issued_multiple_gp_warning;
+
   /* Used by find_nearest_line entry point.  The structure could be
      included directly in this one, but there's no point to wasting
      the memory just for the infrequently called find_nearest_line.  */
   struct ecoff_find_line *find_line_info;
 
+  /* Whether the .rdata section is in the text segment for this
+     particular ECOFF file.  This is not valid until
+     ecoff_compute_section_file_positions is called.  */
+  boolean rdata_in_text;
+
 } ecoff_data_type;
 
 /* Each canonical asymbol really looks like this.  */
@@ -150,7 +166,7 @@ typedef struct ecoff_symbol_struct
   PTR native;
 } ecoff_symbol_type;
 
-/* We take the address of the first element of a asymbol to ensure that the
+/* We take the address of the first element of an asymbol to ensure that the
    macro is only ever applied to an asymbol.  */
 #define ecoffsymbol(asymbol) ((ecoff_symbol_type *) (&((asymbol)->the_bfd)))
 
@@ -194,6 +210,14 @@ struct ecoff_section_tdata
      section, and the entry for any reloc that is not PC relative is
      zero.  */
   long *offsets;
+
+  /* When producing an executable (i.e., final, non-relocatable link)
+     on the Alpha, we may need to use multiple global pointer values
+     to span the entire .lita section.  In essence, we allow each
+     input .lita section to have its own gp value.  To support this,
+     we need to keep track of the gp values that we picked for each
+     input .lita section . */
+  bfd_vma gp;
 };
 
 /* An accessor macro for the ecoff_section_tdata structure.  */
@@ -252,6 +276,9 @@ extern boolean _bfd_ecoff_bfd_copy_private_bfd_data PARAMS ((bfd *, bfd *));
 #define _bfd_ecoff_bfd_copy_private_symbol_data \
   _bfd_generic_bfd_copy_private_symbol_data
 
+#define _bfd_ecoff_bfd_print_private_bfd_data \
+  _bfd_generic_bfd_print_private_bfd_data
+
 #define _bfd_ecoff_bfd_merge_private_bfd_data \
   _bfd_generic_bfd_merge_private_bfd_data
 
@@ -263,8 +290,10 @@ extern boolean _bfd_ecoff_slurp_armap PARAMS ((bfd *abfd));
 #define _bfd_ecoff_truncate_arname bfd_dont_truncate_arname
 extern boolean _bfd_ecoff_write_armap
   PARAMS ((bfd *, unsigned int, struct orl *, unsigned int, int));
+#define _bfd_ecoff_read_ar_hdr _bfd_generic_read_ar_hdr
 #define _bfd_ecoff_openr_next_archived_file \
   bfd_generic_openr_next_archived_file
+#define _bfd_ecoff_get_elt_at_index _bfd_generic_get_elt_at_index
 #define _bfd_ecoff_generic_stat_arch_elt bfd_generic_stat_arch_elt
 #define _bfd_ecoff_update_armap_timestamp bfd_true
 
@@ -275,14 +304,16 @@ extern void _bfd_ecoff_print_symbol
   PARAMS ((bfd *, PTR filep, asymbol *, bfd_print_symbol_type));
 extern void _bfd_ecoff_get_symbol_info
   PARAMS ((bfd *, asymbol *, symbol_info *));
-extern boolean _bfd_ecoff_bfd_is_local_label
-  PARAMS ((bfd *, asymbol *));
+extern boolean _bfd_ecoff_bfd_is_local_label_name
+  PARAMS ((bfd *, const char *));
 #define _bfd_ecoff_get_lineno _bfd_nosymbols_get_lineno
 extern boolean _bfd_ecoff_find_nearest_line
   PARAMS ((bfd *, asection *, asymbol **, bfd_vma offset,
           const char **filename_ptr, const char **fnname_ptr,
           unsigned int *retline_ptr));
 #define _bfd_ecoff_bfd_make_debug_symbol _bfd_nosymbols_bfd_make_debug_symbol
+#define _bfd_ecoff_read_minisymbols _bfd_generic_read_minisymbols
+#define _bfd_ecoff_minisymbol_to_symbol _bfd_generic_minisymbol_to_symbol
 
 #define _bfd_ecoff_get_reloc_upper_bound coff_get_reloc_upper_bound
 extern long _bfd_ecoff_canonicalize_reloc
@@ -290,7 +321,7 @@ extern long _bfd_ecoff_canonicalize_reloc
 /* ecoff_bfd_reloc_type_lookup defined by backend. */
 
 extern boolean _bfd_ecoff_set_arch_mach
-  PARAMS ((bfd *, enum bfd_architecture, unsigned long machine));
+  PARAMS ((bfd *, enum bfd_architecture, unsigned long));
 extern boolean _bfd_ecoff_set_section_contents
   PARAMS ((bfd *, asection *, PTR location, file_ptr, bfd_size_type));
 
@@ -299,20 +330,21 @@ extern int _bfd_ecoff_sizeof_headers PARAMS ((bfd *abfd, boolean reloc));
 /* ecoff_bfd_relax_section defined by backend.  */
 extern struct bfd_link_hash_table *_bfd_ecoff_bfd_link_hash_table_create
   PARAMS ((bfd *));
+#define _bfd_ecoff_bfd_link_hash_table_free _bfd_generic_link_hash_table_free
 extern boolean _bfd_ecoff_bfd_link_add_symbols
   PARAMS ((bfd *, struct bfd_link_info *));
+#define _bfd_ecoff_bfd_link_just_syms _bfd_generic_link_just_syms
 extern boolean _bfd_ecoff_bfd_final_link
   PARAMS ((bfd *, struct bfd_link_info *));
 
 /* Hook functions for the generic COFF section reading code.  */
 
 extern PTR _bfd_ecoff_mkobject_hook PARAMS ((bfd *, PTR filehdr, PTR aouthdr));
-extern asection *_bfd_ecoff_make_section_hook PARAMS ((bfd *abfd, char *name));
 #define _bfd_ecoff_set_alignment_hook \
   ((void (*) PARAMS ((bfd *, asection *, PTR))) bfd_void)
 extern boolean _bfd_ecoff_set_arch_mach_hook PARAMS ((bfd *abfd, PTR filehdr));
-extern flagword _bfd_ecoff_styp_to_sec_flags
-  PARAMS ((bfd *abfd, PTR hdr, const char *name));
+extern boolean _bfd_ecoff_styp_to_sec_flags
+  PARAMS ((bfd *, PTR, const char *, asection *, flagword *));
 extern boolean _bfd_ecoff_slurp_symbol_table PARAMS ((bfd *abfd));
 
 /* ECOFF auxiliary information swapping routines.  These are the same
This page took 0.042182 seconds and 4 git commands to generate.