Ignore:
Timestamp:
Aug 16, 2003, 6:59:22 PM (22 years ago)
Author:
bird
Message:

binutils v2.14 - offical sources.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/GNU/src/binutils/bfd/libcoff.h

    • Property cvs2svn:cvs-rev changed from 1.1 to 1.1.1.2
    r608 r609  
     1/* DO NOT EDIT!  -*- buffer-read-only: t -*-  This file is automatically
     2   generated from "libcoff-in.h" and "coffcode.h".
     3   Run "make headers" in your build bfd/ to regenerate.  */
     4
    15/* BFD COFF object file private structure.
    26   Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
    3    2000, 2001
     7   2000, 2001, 2002
    48   Free Software Foundation, Inc.
    59   Written by Cygnus Support.
    6 
    7 ** NOTE: libcoff.h is a GENERATED file.  Don't change it; instead,
    8 ** change libcoff-in.h or coffcode.h.
    910
    1011This file is part of BFD, the Binary File Descriptor library.
     
    7879     _bfd_coff_get_external_symbols.  */
    7980  PTR external_syms;
    80   /* If this is true, the external_syms may not be freed.  */
    81   boolean keep_syms;
     81  /* If this is TRUE, the external_syms may not be freed.  */
     82  bfd_boolean keep_syms;
    8283
    8384  /* The string table.  May be NULL.  Read by
    8485     _bfd_coff_read_string_table.  */
    8586  char *strings;
    86   /* If this is true, the strings may not be freed.  */
    87   boolean keep_strings;
    88   /* If this is true, the strings have been written out already.  */
    89   boolean strings_written;
     87  /* If this is TRUE, the strings may not be freed.  */
     88  bfd_boolean keep_strings;
     89  /* If this is TRUE, the strings have been written out already.  */
     90  bfd_boolean strings_written;
    9091
    9192  /* is this a PE format coff file */
     
    121122  int dll;
    122123  int has_reloc_section;
    123   boolean (*in_reloc_p) PARAMS((bfd *, reloc_howto_type *));
     124  bfd_boolean (*in_reloc_p) PARAMS((bfd *, reloc_howto_type *));
    124125  flagword real_flags;
    125126  int target_subsystem;
    126   boolean force_minimum_alignment;
     127  bfd_boolean force_minimum_alignment;
    127128} pe_data_type;
    128129
     
    136137  coff_data_type coff;
    137138
    138   /* True if this is an XCOFF64 file. */
    139   boolean xcoff64;
    140 
    141   /* True if a large a.out header should be generated.  */
    142   boolean full_aouthdr;
     139  /* TRUE if this is an XCOFF64 file. */
     140  bfd_boolean xcoff64;
     141
     142  /* TRUE if a large a.out header should be generated.  */
     143  bfd_boolean full_aouthdr;
    143144
    144145  /* TOC value.  */
     
    177178#define xcoff_data(abfd) ((abfd)->tdata.xcoff_obj_data)
    178179
    179 /* We take the address of the first element of a asymbol to ensure that the
     180/* We take the address of the first element of an asymbol to ensure that the
    180181 * macro is only ever applied to an asymbol.  */
    181182#define coffsymbol(asymbol) ((coff_symbol_type *)(&((asymbol)->the_bfd)))
     
    188189  /* The relocs, swapped into COFF internal form.  This may be NULL.  */
    189190  struct internal_reloc *relocs;
    190   /* If this is true, the relocs entry may not be freed.  */
    191   boolean keep_relocs;
     191  /* If this is TRUE, the relocs entry may not be freed.  */
     192  bfd_boolean keep_relocs;
    192193  /* The section contents.  This may be NULL.  */
    193194  bfd_byte *contents;
    194   /* If this is true, the contents entry may not be freed.  */
    195   boolean keep_contents;
     195  /* If this is TRUE, the contents entry may not be freed.  */
     196  bfd_boolean keep_contents;
    196197  /* Information cached by coff_find_nearest_line.  */
    197198  bfd_vma offset;
     
    295296  (bfd_link_hash_traverse                                               \
    296297   (&(table)->root,                                                     \
    297     (boolean (*) PARAMS ((struct bfd_link_hash_entry *, PTR))) (func),  \
     298    (bfd_boolean (*) PARAMS ((struct bfd_link_hash_entry *, PTR))) (func), \
    298299    (info)))
    299300
     
    303304
    304305/* Functions in coffgen.c.  */
    305 extern const bfd_target *coff_object_p PARAMS ((bfd *));
    306 extern struct sec *coff_section_from_bfd_index PARAMS ((bfd *, int));
    307 extern long coff_get_symtab_upper_bound PARAMS ((bfd *));
    308 extern long coff_get_symtab PARAMS ((bfd *, asymbol **));
    309 extern int coff_count_linenumbers PARAMS ((bfd *));
    310 extern struct coff_symbol_struct *coff_symbol_from PARAMS ((bfd *, asymbol *));
    311 extern boolean coff_renumber_symbols PARAMS ((bfd *, int *));
    312 extern void coff_mangle_symbols PARAMS ((bfd *));
    313 extern boolean coff_write_symbols PARAMS ((bfd *));
    314 extern boolean coff_write_linenumbers PARAMS ((bfd *));
    315 extern alent *coff_get_lineno PARAMS ((bfd *, asymbol *));
    316 extern asymbol *coff_section_symbol PARAMS ((bfd *, char *));
    317 extern boolean _bfd_coff_get_external_symbols PARAMS ((bfd *));
    318 extern const char *_bfd_coff_read_string_table PARAMS ((bfd *));
    319 extern boolean _bfd_coff_free_symbols PARAMS ((bfd *));
    320 extern struct coff_ptr_struct *coff_get_normalized_symtab PARAMS ((bfd *));
    321 extern long coff_get_reloc_upper_bound PARAMS ((bfd *, sec_ptr));
    322 extern asymbol *coff_make_empty_symbol PARAMS ((bfd *));
    323 extern void coff_print_symbol PARAMS ((bfd *, PTR filep, asymbol *,
    324                                        bfd_print_symbol_type how));
    325 extern void coff_get_symbol_info PARAMS ((bfd *, asymbol *,
    326                                           symbol_info *ret));
    327 extern boolean _bfd_coff_is_local_label_name PARAMS ((bfd *, const char *));
    328 extern asymbol *coff_bfd_make_debug_symbol PARAMS ((bfd *, PTR,
    329                                                     unsigned long));
    330 extern boolean coff_find_nearest_line PARAMS ((bfd *,
    331                                                asection *,
    332                                                asymbol **,
    333                                                bfd_vma offset,
    334                                                CONST char **filename_ptr,
    335                                                CONST char **functionname_ptr,
    336                                                unsigned int *line_ptr));
    337 extern int coff_sizeof_headers PARAMS ((bfd *, boolean reloc));
    338 extern boolean bfd_coff_reloc16_relax_section
    339   PARAMS ((bfd *, asection *, struct bfd_link_info *, boolean *));
     306extern const bfd_target *coff_object_p
     307  PARAMS ((bfd *));
     308extern struct sec *coff_section_from_bfd_index
     309  PARAMS ((bfd *, int));
     310extern long coff_get_symtab_upper_bound
     311  PARAMS ((bfd *));
     312extern long coff_get_symtab
     313  PARAMS ((bfd *, asymbol **));
     314extern int coff_count_linenumbers
     315  PARAMS ((bfd *));
     316extern struct coff_symbol_struct *coff_symbol_from
     317  PARAMS ((bfd *, asymbol *));
     318extern bfd_boolean coff_renumber_symbols
     319  PARAMS ((bfd *, int *));
     320extern void coff_mangle_symbols
     321  PARAMS ((bfd *));
     322extern bfd_boolean coff_write_symbols
     323  PARAMS ((bfd *));
     324extern bfd_boolean coff_write_linenumbers
     325  PARAMS ((bfd *));
     326extern alent *coff_get_lineno
     327  PARAMS ((bfd *, asymbol *));
     328extern asymbol *coff_section_symbol
     329  PARAMS ((bfd *, char *));
     330extern bfd_boolean _bfd_coff_get_external_symbols
     331  PARAMS ((bfd *));
     332extern const char *_bfd_coff_read_string_table
     333  PARAMS ((bfd *));
     334extern bfd_boolean _bfd_coff_free_symbols
     335  PARAMS ((bfd *));
     336extern struct coff_ptr_struct *coff_get_normalized_symtab
     337  PARAMS ((bfd *));
     338extern long coff_get_reloc_upper_bound
     339  PARAMS ((bfd *, sec_ptr));
     340extern asymbol *coff_make_empty_symbol
     341  PARAMS ((bfd *));
     342extern void coff_print_symbol
     343  PARAMS ((bfd *, PTR filep, asymbol *, bfd_print_symbol_type));
     344extern void coff_get_symbol_info
     345  PARAMS ((bfd *, asymbol *, symbol_info *ret));
     346extern bfd_boolean _bfd_coff_is_local_label_name
     347  PARAMS ((bfd *, const char *));
     348extern asymbol *coff_bfd_make_debug_symbol
     349  PARAMS ((bfd *, PTR, unsigned long));
     350extern bfd_boolean coff_find_nearest_line
     351  PARAMS ((bfd *, asection *, asymbol **, bfd_vma, const char **,
     352           const char **, unsigned int *));
     353extern int coff_sizeof_headers
     354  PARAMS ((bfd *, bfd_boolean));
     355extern bfd_boolean bfd_coff_reloc16_relax_section
     356  PARAMS ((bfd *, asection *, struct bfd_link_info *, bfd_boolean *));
    340357extern bfd_byte *bfd_coff_reloc16_get_relocated_section_contents
    341358  PARAMS ((bfd *, struct bfd_link_info *, struct bfd_link_order *,
    342            bfd_byte *, boolean relocateable, asymbol **));
    343 extern bfd_vma bfd_coff_reloc16_get_value PARAMS ((arelent *,
    344                                                    struct bfd_link_info *,
    345                                                    asection *));
    346 extern void bfd_perform_slip PARAMS ((bfd *abfd, unsigned int slip,
    347                                       asection *input_section,
    348                                       bfd_vma val));
     359           bfd_byte *, bfd_boolean, asymbol **));
     360extern bfd_vma bfd_coff_reloc16_get_value
     361   PARAMS ((arelent *, struct bfd_link_info *, asection *));
     362extern void bfd_perform_slip
     363  PARAMS ((bfd *, unsigned int, asection *, bfd_vma));
    349364
    350365/* Functions and types in cofflink.c.  */
     
    444459  bfd *output_bfd;
    445460  /* Used to indicate failure in traversal routine.  */
    446   boolean failed;
     461  bfd_boolean failed;
    447462  /* If doing "task linking" set only during the time when we want the
    448463     global symbol writer to convert the storage class of defined global
    449464     symbols from global to static. */
    450   boolean global_to_static;
     465  bfd_boolean global_to_static;
    451466  /* Hash table for long symbol names.  */
    452467  struct bfd_strtab_hash *strtab;
     
    522537extern struct bfd_hash_entry *_bfd_coff_link_hash_newfunc
    523538  PARAMS ((struct bfd_hash_entry *, struct bfd_hash_table *, const char *));
    524 extern boolean _bfd_coff_link_hash_table_init
     539extern bfd_boolean _bfd_coff_link_hash_table_init
    525540  PARAMS ((struct coff_link_hash_table *, bfd *,
    526541           struct bfd_hash_entry *(*) (struct bfd_hash_entry *,
     
    531546extern const char *_bfd_coff_internal_syment_name
    532547  PARAMS ((bfd *, const struct internal_syment *, char *));
    533 extern boolean _bfd_coff_link_add_symbols
     548extern bfd_boolean _bfd_coff_link_add_symbols
    534549  PARAMS ((bfd *, struct bfd_link_info *));
    535 extern boolean _bfd_coff_final_link
     550extern bfd_boolean _bfd_coff_final_link
    536551  PARAMS ((bfd *, struct bfd_link_info *));
    537552extern struct internal_reloc *_bfd_coff_read_internal_relocs
    538   PARAMS ((bfd *, asection *, boolean, bfd_byte *, boolean,
     553  PARAMS ((bfd *, asection *, bfd_boolean, bfd_byte *, bfd_boolean,
    539554           struct internal_reloc *));
    540 extern boolean _bfd_coff_generic_relocate_section
     555extern bfd_boolean _bfd_coff_generic_relocate_section
    541556  PARAMS ((bfd *, struct bfd_link_info *, bfd *, asection *, bfd_byte *,
    542557           struct internal_reloc *, struct internal_syment *, asection **));
     
    544559extern struct bfd_hash_entry *_bfd_coff_debug_merge_hash_newfunc
    545560  PARAMS ((struct bfd_hash_entry *, struct bfd_hash_table *, const char *));
    546 extern boolean _bfd_coff_write_global_sym
     561extern bfd_boolean _bfd_coff_write_global_sym
    547562  PARAMS ((struct coff_link_hash_entry *, PTR));
    548 extern boolean _bfd_coff_write_task_globals
     563extern bfd_boolean _bfd_coff_write_task_globals
    549564  PARAMS ((struct coff_link_hash_entry *, PTR));
    550 extern boolean _bfd_coff_link_input_bfd
     565extern bfd_boolean _bfd_coff_link_input_bfd
    551566  PARAMS ((struct coff_final_link_info *, bfd *));
    552 extern boolean _bfd_coff_reloc_link_order
     567extern bfd_boolean _bfd_coff_reloc_link_order
    553568  PARAMS ((bfd *, struct coff_final_link_info *, asection *,
    554569           struct bfd_link_order *));
     
    560575/* Functions in xcofflink.c.  */
    561576
    562 extern long _bfd_xcoff_get_dynamic_symtab_upper_bound PARAMS ((bfd *));
     577extern long _bfd_xcoff_get_dynamic_symtab_upper_bound
     578  PARAMS ((bfd *));
    563579extern long _bfd_xcoff_canonicalize_dynamic_symtab
    564580  PARAMS ((bfd *, asymbol **));
    565 extern long _bfd_xcoff_get_dynamic_reloc_upper_bound PARAMS ((bfd *));
     581extern long _bfd_xcoff_get_dynamic_reloc_upper_bound
     582  PARAMS ((bfd *));
    566583extern long _bfd_xcoff_canonicalize_dynamic_reloc
    567584  PARAMS ((bfd *, arelent **, asymbol **));
    568585extern struct bfd_link_hash_table *_bfd_xcoff_bfd_link_hash_table_create
    569586  PARAMS ((bfd *));
    570 extern boolean _bfd_xcoff_bfd_link_add_symbols
     587extern void _bfd_xcoff_bfd_link_hash_table_free
     588  PARAMS ((struct bfd_link_hash_table *));
     589extern bfd_boolean _bfd_xcoff_bfd_link_add_symbols
    571590  PARAMS ((bfd *, struct bfd_link_info *));
    572 extern boolean _bfd_xcoff_bfd_final_link
     591extern bfd_boolean _bfd_xcoff_bfd_final_link
    573592  PARAMS ((bfd *, struct bfd_link_info *));
    574 extern boolean _bfd_ppc_xcoff_relocate_section
     593extern bfd_boolean _bfd_ppc_xcoff_relocate_section
    575594  PARAMS ((bfd *, struct bfd_link_info *, bfd *, asection *, bfd_byte *,
    576595           struct internal_reloc *, struct internal_syment *, asection **));
     
    579598   linker, and so should start with bfd and be declared in bfd.h.  */
    580599
    581 extern boolean ppc_allocate_toc_section PARAMS ((struct bfd_link_info *));
    582 extern boolean ppc_process_before_allocation
     600extern bfd_boolean ppc_allocate_toc_section
     601  PARAMS ((struct bfd_link_info *));
     602extern bfd_boolean ppc_process_before_allocation
    583603  PARAMS ((bfd *, struct bfd_link_info *));
    584604
    585 /* And more taken from the source .. */
    586 
     605/* Extracted from coffcode.h.  */
    587606typedef struct coff_ptr_struct
    588607{
    589 
    590        /* Remembers the offset from the first symbol in the file for
    591           this symbol. Generated by coff_renumber_symbols. */
    592 unsigned int offset;
    593 
    594        /* Should the value of this symbol be renumbered.  Used for
    595           XCOFF C_BSTAT symbols.  Set by coff_slurp_symbol_table.  */
    596 unsigned int fix_value : 1;
    597 
    598        /* Should the tag field of this symbol be renumbered.
    599           Created by coff_pointerize_aux. */
    600 unsigned int fix_tag : 1;
    601 
    602        /* Should the endidx field of this symbol be renumbered.
    603           Created by coff_pointerize_aux. */
    604 unsigned int fix_end : 1;
    605 
    606        /* Should the x_csect.x_scnlen field be renumbered.
    607           Created by coff_pointerize_aux. */
    608 unsigned int fix_scnlen : 1;
    609 
    610        /* Fix up an XCOFF C_BINCL/C_EINCL symbol.  The value is the
    611           index into the line number entries.  Set by
    612           coff_slurp_symbol_table.  */
    613 unsigned int fix_line : 1;
    614 
    615        /* The container for the symbol structure as read and translated
    616            from the file. */
    617 
    618 union {
    619    union internal_auxent auxent;
    620    struct internal_syment syment;
    621  } u;
     608  /* Remembers the offset from the first symbol in the file for
     609     this symbol. Generated by coff_renumber_symbols. */
     610  unsigned int offset;
     611
     612  /* Should the value of this symbol be renumbered.  Used for
     613     XCOFF C_BSTAT symbols.  Set by coff_slurp_symbol_table.  */
     614  unsigned int fix_value : 1;
     615
     616  /* Should the tag field of this symbol be renumbered.
     617     Created by coff_pointerize_aux. */
     618  unsigned int fix_tag : 1;
     619
     620  /* Should the endidx field of this symbol be renumbered.
     621     Created by coff_pointerize_aux. */
     622  unsigned int fix_end : 1;
     623
     624  /* Should the x_csect.x_scnlen field be renumbered.
     625     Created by coff_pointerize_aux. */
     626  unsigned int fix_scnlen : 1;
     627
     628  /* Fix up an XCOFF C_BINCL/C_EINCL symbol.  The value is the
     629     index into the line number entries.  Set by coff_slurp_symbol_table.  */
     630  unsigned int fix_line : 1;
     631
     632  /* The container for the symbol structure as read and translated
     633     from the file. */
     634  union
     635  {
     636    union internal_auxent auxent;
     637    struct internal_syment syment;
     638  } u;
    622639} combined_entry_type;
    623640
     
    627644typedef struct coff_symbol_struct
    628645{
    629    /* The actual symbol which the rest of BFD works with */
    630 asymbol symbol;
    631 
    632    /* A pointer to the hidden information for this symbol */
    633 combined_entry_type *native;
    634 
    635    /* A pointer to the linenumber information for this symbol */
    636 struct lineno_cache_entry *lineno;
    637 
    638    /* Have the line numbers been relocated yet ? */
    639 boolean done_lineno;
     646  /* The actual symbol which the rest of BFD works with */
     647  asymbol symbol;
     648
     649  /* A pointer to the hidden information for this symbol */
     650  combined_entry_type *native;
     651
     652  /* A pointer to the linenumber information for this symbol */
     653  struct lineno_cache_entry *lineno;
     654
     655  /* Have the line numbers been relocated yet ? */
     656  bfd_boolean done_lineno;
    640657} coff_symbol_type;
    641658/* COFF symbol classifications.  */
     
    657674typedef struct
    658675{
    659   void (*_bfd_coff_swap_aux_in) PARAMS ((
    660        bfd            *abfd,
    661        PTR             ext,
    662        int             type,
    663        int             class,
    664        int             indaux,
    665        int             numaux,
    666        PTR             in));
    667 
    668   void (*_bfd_coff_swap_sym_in) PARAMS ((
    669        bfd            *abfd ,
    670        PTR             ext,
    671        PTR             in));
    672 
    673   void (*_bfd_coff_swap_lineno_in) PARAMS ((
    674        bfd            *abfd,
    675        PTR            ext,
    676        PTR             in));
    677 
    678  unsigned int (*_bfd_coff_swap_aux_out) PARAMS ((
    679        bfd     *abfd,
    680        PTR     in,
    681        int     type,
    682        int     class,
    683        int     indaux,
    684        int     numaux,
    685        PTR     ext));
    686 
    687  unsigned int (*_bfd_coff_swap_sym_out) PARAMS ((
    688       bfd      *abfd,
    689       PTR      in,
    690       PTR      ext));
    691 
    692  unsigned int (*_bfd_coff_swap_lineno_out) PARAMS ((
    693        bfd     *abfd,
    694        PTR     in,
    695        PTR     ext));
    696 
    697  unsigned int (*_bfd_coff_swap_reloc_out) PARAMS ((
    698        bfd     *abfd,
    699        PTR     src,
    700        PTR     dst));
    701 
    702  unsigned int (*_bfd_coff_swap_filehdr_out) PARAMS ((
    703        bfd     *abfd,
    704        PTR     in,
    705        PTR     out));
    706 
    707  unsigned int (*_bfd_coff_swap_aouthdr_out) PARAMS ((
    708        bfd     *abfd,
    709        PTR     in,
    710        PTR     out));
    711 
    712  unsigned int (*_bfd_coff_swap_scnhdr_out) PARAMS ((
    713        bfd     *abfd,
    714        PTR     in,
    715        PTR     out));
    716 
    717  unsigned int _bfd_filhsz;
    718  unsigned int _bfd_aoutsz;
    719  unsigned int _bfd_scnhsz;
    720  unsigned int _bfd_symesz;
    721  unsigned int _bfd_auxesz;
    722  unsigned int _bfd_relsz;
    723  unsigned int _bfd_linesz;
    724  unsigned int _bfd_filnmlen;
    725  boolean _bfd_coff_long_filenames;
    726  boolean _bfd_coff_long_section_names;
    727  unsigned int _bfd_coff_default_section_alignment_power;
    728  boolean _bfd_coff_force_symnames_in_strings;
    729  unsigned int _bfd_coff_debug_string_prefix_length;
    730  void (*_bfd_coff_swap_filehdr_in) PARAMS ((
    731        bfd     *abfd,
    732        PTR     ext,
    733        PTR     in));
    734  void (*_bfd_coff_swap_aouthdr_in) PARAMS ((
    735        bfd     *abfd,
    736        PTR     ext,
    737        PTR     in));
    738  void (*_bfd_coff_swap_scnhdr_in) PARAMS ((
    739        bfd     *abfd,
    740        PTR     ext,
    741        PTR     in));
    742  void (*_bfd_coff_swap_reloc_in) PARAMS ((
    743        bfd     *abfd,
    744        PTR     ext,
    745        PTR     in));
    746  boolean (*_bfd_coff_bad_format_hook) PARAMS ((
    747        bfd     *abfd,
    748        PTR     internal_filehdr));
    749  boolean (*_bfd_coff_set_arch_mach_hook) PARAMS ((
    750        bfd     *abfd,
    751        PTR     internal_filehdr));
    752  PTR (*_bfd_coff_mkobject_hook) PARAMS ((
    753        bfd     *abfd,
    754        PTR     internal_filehdr,
    755        PTR     internal_aouthdr));
    756  flagword (*_bfd_styp_to_sec_flags_hook) PARAMS ((
    757        bfd     *abfd,
    758        PTR     internal_scnhdr,
    759        const char *name,
    760        asection *section));
    761  void (*_bfd_set_alignment_hook) PARAMS ((
    762        bfd     *abfd,
    763        asection *sec,
    764        PTR     internal_scnhdr));
    765  boolean (*_bfd_coff_slurp_symbol_table) PARAMS ((
    766        bfd     *abfd));
    767  boolean (*_bfd_coff_symname_in_debug) PARAMS ((
    768        bfd     *abfd,
    769        struct internal_syment *sym));
    770  boolean (*_bfd_coff_pointerize_aux_hook) PARAMS ((
    771        bfd *abfd,
    772        combined_entry_type *table_base,
    773        combined_entry_type *symbol,
    774        unsigned int indaux,
    775        combined_entry_type *aux));
    776  boolean (*_bfd_coff_print_aux) PARAMS ((
    777        bfd *abfd,
    778        FILE *file,
    779        combined_entry_type *table_base,
    780        combined_entry_type *symbol,
    781        combined_entry_type *aux,
    782        unsigned int indaux));
    783  void (*_bfd_coff_reloc16_extra_cases) PARAMS ((
    784        bfd     *abfd,
    785        struct bfd_link_info *link_info,
    786        struct bfd_link_order *link_order,
    787        arelent *reloc,
    788        bfd_byte *data,
    789        unsigned int *src_ptr,
    790        unsigned int *dst_ptr));
    791  int (*_bfd_coff_reloc16_estimate) PARAMS ((
    792        bfd *abfd,
    793        asection *input_section,
    794        arelent *r,
    795        unsigned int shrink,
    796        struct bfd_link_info *link_info));
    797  enum coff_symbol_classification (*_bfd_coff_classify_symbol) PARAMS ((
    798        bfd *abfd,
    799        struct internal_syment *));
    800  boolean (*_bfd_coff_compute_section_file_positions) PARAMS ((
    801        bfd *abfd));
    802  boolean (*_bfd_coff_start_final_link) PARAMS ((
    803        bfd *output_bfd,
    804        struct bfd_link_info *info));
    805  boolean (*_bfd_coff_relocate_section) PARAMS ((
    806        bfd *output_bfd,
    807        struct bfd_link_info *info,
    808        bfd *input_bfd,
    809        asection *input_section,
    810        bfd_byte *contents,
    811        struct internal_reloc *relocs,
    812        struct internal_syment *syms,
    813        asection **sections));
    814  reloc_howto_type *(*_bfd_coff_rtype_to_howto) PARAMS ((
    815        bfd *abfd,
    816        asection *sec,
    817        struct internal_reloc *rel,
    818        struct coff_link_hash_entry *h,
    819        struct internal_syment *sym,
    820        bfd_vma *addendp));
    821  boolean (*_bfd_coff_adjust_symndx) PARAMS ((
    822        bfd *obfd,
    823        struct bfd_link_info *info,
    824        bfd *ibfd,
    825        asection *sec,
    826        struct internal_reloc *reloc,
    827        boolean *adjustedp));
    828  boolean (*_bfd_coff_link_add_one_symbol) PARAMS ((
    829        struct bfd_link_info *info,
    830        bfd *abfd,
    831        const char *name,
    832        flagword flags,
    833        asection *section,
    834        bfd_vma value,
    835        const char *string,
    836        boolean copy,
    837        boolean collect,
    838        struct bfd_link_hash_entry **hashp));
    839 
    840  boolean (*_bfd_coff_link_output_has_begun) PARAMS ((
    841        bfd * abfd,
    842        struct coff_final_link_info * pfinfo));
    843  boolean (*_bfd_coff_final_link_postscript) PARAMS ((
    844        bfd * abfd,
    845        struct coff_final_link_info * pfinfo));
     676  void (*_bfd_coff_swap_aux_in)
     677    PARAMS ((bfd *, PTR, int, int, int, int, PTR));
     678
     679  void (*_bfd_coff_swap_sym_in)
     680    PARAMS ((bfd *, PTR, PTR));
     681
     682  void (*_bfd_coff_swap_lineno_in)
     683    PARAMS ((bfd *, PTR, PTR));
     684
     685  unsigned int (*_bfd_coff_swap_aux_out)
     686    PARAMS ((bfd *, PTR, int, int, int, int, PTR));
     687
     688  unsigned int (*_bfd_coff_swap_sym_out)
     689    PARAMS ((bfd *, PTR, PTR));
     690
     691  unsigned int (*_bfd_coff_swap_lineno_out)
     692    PARAMS ((bfd *, PTR, PTR));
     693
     694  unsigned int (*_bfd_coff_swap_reloc_out)
     695    PARAMS ((bfd *, PTR, PTR));
     696
     697  unsigned int (*_bfd_coff_swap_filehdr_out)
     698    PARAMS ((bfd *, PTR, PTR));
     699
     700  unsigned int (*_bfd_coff_swap_aouthdr_out)
     701    PARAMS ((bfd *, PTR, PTR));
     702
     703  unsigned int (*_bfd_coff_swap_scnhdr_out)
     704    PARAMS ((bfd *, PTR, PTR));
     705
     706  unsigned int _bfd_filhsz;
     707  unsigned int _bfd_aoutsz;
     708  unsigned int _bfd_scnhsz;
     709  unsigned int _bfd_symesz;
     710  unsigned int _bfd_auxesz;
     711  unsigned int _bfd_relsz;
     712  unsigned int _bfd_linesz;
     713  unsigned int _bfd_filnmlen;
     714  bfd_boolean _bfd_coff_long_filenames;
     715  bfd_boolean _bfd_coff_long_section_names;
     716  unsigned int _bfd_coff_default_section_alignment_power;
     717  bfd_boolean _bfd_coff_force_symnames_in_strings;
     718  unsigned int _bfd_coff_debug_string_prefix_length;
     719
     720  void (*_bfd_coff_swap_filehdr_in)
     721    PARAMS ((bfd *, PTR, PTR));
     722
     723  void (*_bfd_coff_swap_aouthdr_in)
     724    PARAMS ((bfd *, PTR, PTR));
     725
     726  void (*_bfd_coff_swap_scnhdr_in)
     727    PARAMS ((bfd *, PTR, PTR));
     728
     729  void (*_bfd_coff_swap_reloc_in)
     730    PARAMS ((bfd *abfd, PTR, PTR));
     731
     732  bfd_boolean (*_bfd_coff_bad_format_hook)
     733    PARAMS ((bfd *, PTR));
     734
     735  bfd_boolean (*_bfd_coff_set_arch_mach_hook)
     736    PARAMS ((bfd *, PTR));
     737
     738  PTR (*_bfd_coff_mkobject_hook)
     739    PARAMS ((bfd *, PTR, PTR));
     740
     741  bfd_boolean (*_bfd_styp_to_sec_flags_hook)
     742    PARAMS ((bfd *, PTR, const char *, asection *, flagword *));
     743
     744  void (*_bfd_set_alignment_hook)
     745    PARAMS ((bfd *, asection *, PTR));
     746
     747  bfd_boolean (*_bfd_coff_slurp_symbol_table)
     748    PARAMS ((bfd *));
     749
     750  bfd_boolean (*_bfd_coff_symname_in_debug)
     751    PARAMS ((bfd *, struct internal_syment *));
     752
     753  bfd_boolean (*_bfd_coff_pointerize_aux_hook)
     754    PARAMS ((bfd *, combined_entry_type *, combined_entry_type *,
     755            unsigned int, combined_entry_type *));
     756
     757  bfd_boolean (*_bfd_coff_print_aux)
     758    PARAMS ((bfd *, FILE *, combined_entry_type *, combined_entry_type *,
     759            combined_entry_type *, unsigned int));
     760
     761  void (*_bfd_coff_reloc16_extra_cases)
     762    PARAMS ((bfd *, struct bfd_link_info *, struct bfd_link_order *, arelent *,
     763           bfd_byte *, unsigned int *, unsigned int *));
     764
     765  int (*_bfd_coff_reloc16_estimate)
     766    PARAMS ((bfd *, asection *, arelent *, unsigned int,
     767            struct bfd_link_info *));
     768
     769  enum coff_symbol_classification (*_bfd_coff_classify_symbol)
     770    PARAMS ((bfd *, struct internal_syment *));
     771
     772  bfd_boolean (*_bfd_coff_compute_section_file_positions)
     773    PARAMS ((bfd *));
     774
     775  bfd_boolean (*_bfd_coff_start_final_link)
     776    PARAMS ((bfd *, struct bfd_link_info *));
     777
     778  bfd_boolean (*_bfd_coff_relocate_section)
     779    PARAMS ((bfd *, struct bfd_link_info *, bfd *, asection *, bfd_byte *,
     780            struct internal_reloc *, struct internal_syment *, asection **));
     781
     782  reloc_howto_type *(*_bfd_coff_rtype_to_howto)
     783    PARAMS ((bfd *, asection *, struct internal_reloc *,
     784            struct coff_link_hash_entry *, struct internal_syment *,
     785            bfd_vma *));
     786
     787  bfd_boolean (*_bfd_coff_adjust_symndx)
     788    PARAMS ((bfd *, struct bfd_link_info *, bfd *, asection *,
     789            struct internal_reloc *, bfd_boolean *));
     790
     791  bfd_boolean (*_bfd_coff_link_add_one_symbol)
     792    PARAMS ((struct bfd_link_info *, bfd *, const char *, flagword,
     793            asection *, bfd_vma, const char *, bfd_boolean, bfd_boolean,
     794            struct bfd_link_hash_entry **));
     795
     796  bfd_boolean (*_bfd_coff_link_output_has_begun)
     797    PARAMS ((bfd *, struct coff_final_link_info *));
     798
     799  bfd_boolean (*_bfd_coff_final_link_postscript)
     800    PARAMS ((bfd *, struct coff_final_link_info *));
    846801
    847802} bfd_coff_backend_data;
    848803
    849 #define coff_backend_info(abfd) ((bfd_coff_backend_data *) (abfd)->xvec->backend_data)
     804#define coff_backend_info(abfd) \
     805  ((bfd_coff_backend_data *) (abfd)->xvec->backend_data)
    850806
    851807#define bfd_coff_swap_aux_in(a,e,t,c,ind,num,i) \
    852         ((coff_backend_info (a)->_bfd_coff_swap_aux_in) (a,e,t,c,ind,num,i))
     808  ((coff_backend_info (a)->_bfd_coff_swap_aux_in) (a,e,t,c,ind,num,i))
    853809
    854810#define bfd_coff_swap_sym_in(a,e,i) \
    855         ((coff_backend_info (a)->_bfd_coff_swap_sym_in) (a,e,i))
     811  ((coff_backend_info (a)->_bfd_coff_swap_sym_in) (a,e,i))
    856812
    857813#define bfd_coff_swap_lineno_in(a,e,i) \
    858         ((coff_backend_info ( a)->_bfd_coff_swap_lineno_in) (a,e,i))
     814  ((coff_backend_info ( a)->_bfd_coff_swap_lineno_in) (a,e,i))
    859815
    860816#define bfd_coff_swap_reloc_out(abfd, i, o) \
    861         ((coff_backend_info (abfd)->_bfd_coff_swap_reloc_out) (abfd, i, o))
     817  ((coff_backend_info (abfd)->_bfd_coff_swap_reloc_out) (abfd, i, o))
    862818
    863819#define bfd_coff_swap_lineno_out(abfd, i, o) \
    864         ((coff_backend_info (abfd)->_bfd_coff_swap_lineno_out) (abfd, i, o))
     820  ((coff_backend_info (abfd)->_bfd_coff_swap_lineno_out) (abfd, i, o))
    865821
    866822#define bfd_coff_swap_aux_out(a,i,t,c,ind,num,o) \
    867         ((coff_backend_info (a)->_bfd_coff_swap_aux_out) (a,i,t,c,ind,num,o))
     823  ((coff_backend_info (a)->_bfd_coff_swap_aux_out) (a,i,t,c,ind,num,o))
    868824
    869825#define bfd_coff_swap_sym_out(abfd, i,o) \
    870         ((coff_backend_info (abfd)->_bfd_coff_swap_sym_out) (abfd, i, o))
     826  ((coff_backend_info (abfd)->_bfd_coff_swap_sym_out) (abfd, i, o))
    871827
    872828#define bfd_coff_swap_scnhdr_out(abfd, i,o) \
    873         ((coff_backend_info (abfd)->_bfd_coff_swap_scnhdr_out) (abfd, i, o))
     829  ((coff_backend_info (abfd)->_bfd_coff_swap_scnhdr_out) (abfd, i, o))
    874830
    875831#define bfd_coff_swap_filehdr_out(abfd, i,o) \
    876         ((coff_backend_info (abfd)->_bfd_coff_swap_filehdr_out) (abfd, i, o))
     832  ((coff_backend_info (abfd)->_bfd_coff_swap_filehdr_out) (abfd, i, o))
    877833
    878834#define bfd_coff_swap_aouthdr_out(abfd, i,o) \
    879         ((coff_backend_info (abfd)->_bfd_coff_swap_aouthdr_out) (abfd, i, o))
     835  ((coff_backend_info (abfd)->_bfd_coff_swap_aouthdr_out) (abfd, i, o))
    880836
    881837#define bfd_coff_filhsz(abfd) (coff_backend_info (abfd)->_bfd_filhsz)
     
    887843#define bfd_coff_linesz(abfd) (coff_backend_info (abfd)->_bfd_linesz)
    888844#define bfd_coff_filnmlen(abfd) (coff_backend_info (abfd)->_bfd_filnmlen)
    889 #define bfd_coff_long_filenames(abfd) (coff_backend_info (abfd)->_bfd_coff_long_filenames)
     845#define bfd_coff_long_filenames(abfd) \
     846  (coff_backend_info (abfd)->_bfd_coff_long_filenames)
    890847#define bfd_coff_long_section_names(abfd) \
    891         (coff_backend_info (abfd)->_bfd_coff_long_section_names)
     848  (coff_backend_info (abfd)->_bfd_coff_long_section_names)
    892849#define bfd_coff_default_section_alignment_power(abfd) \
    893         (coff_backend_info (abfd)->_bfd_coff_default_section_alignment_power)
     850  (coff_backend_info (abfd)->_bfd_coff_default_section_alignment_power)
    894851#define bfd_coff_swap_filehdr_in(abfd, i,o) \
    895         ((coff_backend_info (abfd)->_bfd_coff_swap_filehdr_in) (abfd, i, o))
     852  ((coff_backend_info (abfd)->_bfd_coff_swap_filehdr_in) (abfd, i, o))
    896853
    897854#define bfd_coff_swap_aouthdr_in(abfd, i,o) \
    898         ((coff_backend_info (abfd)->_bfd_coff_swap_aouthdr_in) (abfd, i, o))
     855  ((coff_backend_info (abfd)->_bfd_coff_swap_aouthdr_in) (abfd, i, o))
    899856
    900857#define bfd_coff_swap_scnhdr_in(abfd, i,o) \
    901         ((coff_backend_info (abfd)->_bfd_coff_swap_scnhdr_in) (abfd, i, o))
     858  ((coff_backend_info (abfd)->_bfd_coff_swap_scnhdr_in) (abfd, i, o))
    902859
    903860#define bfd_coff_swap_reloc_in(abfd, i, o) \
    904         ((coff_backend_info (abfd)->_bfd_coff_swap_reloc_in) (abfd, i, o))
     861  ((coff_backend_info (abfd)->_bfd_coff_swap_reloc_in) (abfd, i, o))
    905862
    906863#define bfd_coff_bad_format_hook(abfd, filehdr) \
    907         ((coff_backend_info (abfd)->_bfd_coff_bad_format_hook) (abfd, filehdr))
     864  ((coff_backend_info (abfd)->_bfd_coff_bad_format_hook) (abfd, filehdr))
    908865
    909866#define bfd_coff_set_arch_mach_hook(abfd, filehdr)\
    910         ((coff_backend_info (abfd)->_bfd_coff_set_arch_mach_hook) (abfd, filehdr))
     867  ((coff_backend_info (abfd)->_bfd_coff_set_arch_mach_hook) (abfd, filehdr))
    911868#define bfd_coff_mkobject_hook(abfd, filehdr, aouthdr)\
    912         ((coff_backend_info (abfd)->_bfd_coff_mkobject_hook) (abfd, filehdr, aouthdr))
    913 
    914 #define bfd_coff_styp_to_sec_flags_hook(abfd, scnhdr, name, section)\
    915         ((coff_backend_info (abfd)->_bfd_styp_to_sec_flags_hook)\
    916          (abfd, scnhdr, name, section))
     869  ((coff_backend_info (abfd)->_bfd_coff_mkobject_hook)\
     870   (abfd, filehdr, aouthdr))
     871
     872#define bfd_coff_styp_to_sec_flags_hook(abfd, scnhdr, name, section, flags_ptr)\
     873  ((coff_backend_info (abfd)->_bfd_styp_to_sec_flags_hook)\
     874   (abfd, scnhdr, name, section, flags_ptr))
    917875
    918876#define bfd_coff_set_alignment_hook(abfd, sec, scnhdr)\
    919         ((coff_backend_info (abfd)->_bfd_set_alignment_hook) (abfd, sec, scnhdr))
     877  ((coff_backend_info (abfd)->_bfd_set_alignment_hook) (abfd, sec, scnhdr))
    920878
    921879#define bfd_coff_slurp_symbol_table(abfd)\
    922         ((coff_backend_info (abfd)->_bfd_coff_slurp_symbol_table) (abfd))
     880  ((coff_backend_info (abfd)->_bfd_coff_slurp_symbol_table) (abfd))
    923881
    924882#define bfd_coff_symname_in_debug(abfd, sym)\
    925         ((coff_backend_info (abfd)->_bfd_coff_symname_in_debug) (abfd, sym))
     883  ((coff_backend_info (abfd)->_bfd_coff_symname_in_debug) (abfd, sym))
    926884
    927885#define bfd_coff_force_symnames_in_strings(abfd)\
    928        (coff_backend_info (abfd)->_bfd_coff_force_symnames_in_strings)
     886  (coff_backend_info (abfd)->_bfd_coff_force_symnames_in_strings)
    929887
    930888#define bfd_coff_debug_string_prefix_length(abfd)\
    931        (coff_backend_info (abfd)->_bfd_coff_debug_string_prefix_length)
     889  (coff_backend_info (abfd)->_bfd_coff_debug_string_prefix_length)
    932890
    933891#define bfd_coff_print_aux(abfd, file, base, symbol, aux, indaux)\
    934         ((coff_backend_info (abfd)->_bfd_coff_print_aux)\
    935          (abfd, file, base, symbol, aux, indaux))
    936 
    937 #define bfd_coff_reloc16_extra_cases(abfd, link_info, link_order, reloc, data, src_ptr, dst_ptr)\
    938         ((coff_backend_info (abfd)->_bfd_coff_reloc16_extra_cases)\
    939          (abfd, link_info, link_order, reloc, data, src_ptr, dst_ptr))
     892  ((coff_backend_info (abfd)->_bfd_coff_print_aux)\
     893   (abfd, file, base, symbol, aux, indaux))
     894
     895#define bfd_coff_reloc16_extra_cases(abfd, link_info, link_order,\
     896                                     reloc, data, src_ptr, dst_ptr)\
     897  ((coff_backend_info (abfd)->_bfd_coff_reloc16_extra_cases)\
     898   (abfd, link_info, link_order, reloc, data, src_ptr, dst_ptr))
    940899
    941900#define bfd_coff_reloc16_estimate(abfd, section, reloc, shrink, link_info)\
    942         ((coff_backend_info (abfd)->_bfd_coff_reloc16_estimate)\
    943          (abfd, section, reloc, shrink, link_info))
     901  ((coff_backend_info (abfd)->_bfd_coff_reloc16_estimate)\
     902   (abfd, section, reloc, shrink, link_info))
    944903
    945904#define bfd_coff_classify_symbol(abfd, sym)\
    946         ((coff_backend_info (abfd)->_bfd_coff_classify_symbol)\
    947          (abfd, sym))
     905  ((coff_backend_info (abfd)->_bfd_coff_classify_symbol)\
     906   (abfd, sym))
    948907
    949908#define bfd_coff_compute_section_file_positions(abfd)\
    950         ((coff_backend_info (abfd)->_bfd_coff_compute_section_file_positions)\
    951          (abfd))
     909  ((coff_backend_info (abfd)->_bfd_coff_compute_section_file_positions)\
     910   (abfd))
    952911
    953912#define bfd_coff_start_final_link(obfd, info)\
    954         ((coff_backend_info (obfd)->_bfd_coff_start_final_link)\
    955          (obfd, info))
     913  ((coff_backend_info (obfd)->_bfd_coff_start_final_link)\
     914   (obfd, info))
    956915#define bfd_coff_relocate_section(obfd,info,ibfd,o,con,rel,isyms,secs)\
    957         ((coff_backend_info (ibfd)->_bfd_coff_relocate_section)\
    958          (obfd, info, ibfd, o, con, rel, isyms, secs))
     916  ((coff_backend_info (ibfd)->_bfd_coff_relocate_section)\
     917   (obfd, info, ibfd, o, con, rel, isyms, secs))
    959918#define bfd_coff_rtype_to_howto(abfd, sec, rel, h, sym, addendp)\
    960         ((coff_backend_info (abfd)->_bfd_coff_rtype_to_howto)\
    961          (abfd, sec, rel, h, sym, addendp))
     919  ((coff_backend_info (abfd)->_bfd_coff_rtype_to_howto)\
     920   (abfd, sec, rel, h, sym, addendp))
    962921#define bfd_coff_adjust_symndx(obfd, info, ibfd, sec, rel, adjustedp)\
    963         ((coff_backend_info (abfd)->_bfd_coff_adjust_symndx)\
    964          (obfd, info, ibfd, sec, rel, adjustedp))
    965 #define bfd_coff_link_add_one_symbol(info,abfd,name,flags,section,value,string,cp,coll,hashp)\
    966         ((coff_backend_info (abfd)->_bfd_coff_link_add_one_symbol)\
    967          (info, abfd, name, flags, section, value, string, cp, coll, hashp))
     922  ((coff_backend_info (abfd)->_bfd_coff_adjust_symndx)\
     923   (obfd, info, ibfd, sec, rel, adjustedp))
     924#define bfd_coff_link_add_one_symbol(info, abfd, name, flags, section,\
     925                                     value, string, cp, coll, hashp)\
     926  ((coff_backend_info (abfd)->_bfd_coff_link_add_one_symbol)\
     927   (info, abfd, name, flags, section, value, string, cp, coll, hashp))
    968928
    969929#define bfd_coff_link_output_has_begun(a,p) \
    970         ((coff_backend_info (a)->_bfd_coff_link_output_has_begun) (a,p))
     930  ((coff_backend_info (a)->_bfd_coff_link_output_has_begun) (a,p))
    971931#define bfd_coff_final_link_postscript(a,p) \
    972         ((coff_backend_info (a)->_bfd_coff_final_link_postscript) (a,p))
    973 
     932  ((coff_backend_info (a)->_bfd_coff_final_link_postscript) (a,p))
     933
Note: See TracChangeset for help on using the changeset viewer.