* targets.c (bfd_target): Add _bfd_read_ar_hdr field. Modify
[deliverable/binutils-gdb.git] / bfd / bfd-in2.h
index b95c1a313a5d1611eea8abda4ce34601debff673..d3da8df4391128afa7910dce39b97e0e80a0cf48 100644 (file)
@@ -88,6 +88,11 @@ typedef struct _bfd bfd;
 #if defined (__GNUG__) && (__GNUC_MINOR__ > 5)
 #define TRUE_FALSE_ALREADY_DEFINED
 #endif
+#ifdef MPW
+/* Pre-emptive strike - get the file with the enum. */
+#include <Types.h>
+#define TRUE_FALSE_ALREADY_DEFINED
+#endif /* MPW */
 #ifndef TRUE_FALSE_ALREADY_DEFINED
 typedef enum bfd_boolean {false, true} boolean;
 #define BFD_TRUE_FALSE
@@ -1079,39 +1084,32 @@ typedef struct bfd_arch_info
   int bits_per_byte;
   enum bfd_architecture arch;
   unsigned long mach;
-  char *arch_name;
-  CONST  char *printable_name;
+  const char *arch_name;
+  const char *printable_name;
   unsigned int section_align_power;
   /* true if this is the default machine for the architecture */
   boolean the_default; 
-  CONST struct bfd_arch_info * (*compatible)
-       PARAMS ((CONST struct bfd_arch_info *a,
-                CONST struct bfd_arch_info *b));
-
-  boolean (*scan) PARAMS ((CONST struct bfd_arch_info *, CONST char *));
-   /* How to disassemble an instruction, producing a printable
-     representation on a specified stdio stream.  This isn't
-     defined for most processors at present, because of the size
-     of the additional tables it would drag in, and because gdb
-     wants to use a different interface.  */
-  unsigned int (*disassemble) PARAMS ((bfd_vma addr, CONST char *data,
-                                       PTR stream));
-
-  struct bfd_arch_info *next;
+  const struct bfd_arch_info * (*compatible)
+       PARAMS ((const struct bfd_arch_info *a,
+                const struct bfd_arch_info *b));
+
+  boolean (*scan) PARAMS ((const struct bfd_arch_info *, const char *));
+
+  const struct bfd_arch_info *next;
 } bfd_arch_info_type;
-CONST char *
+const char *
 bfd_printable_name PARAMS ((bfd *abfd));
 
-bfd_arch_info_type *
-bfd_scan_arch PARAMS ((CONST char *string));
+const bfd_arch_info_type *
+bfd_scan_arch PARAMS ((const char *string));
 
-CONST bfd_arch_info_type *
+const bfd_arch_info_type *
 bfd_arch_get_compatible PARAMS ((
-    CONST bfd *abfd,
-    CONST bfd *bbfd));
+    const bfd *abfd,
+    const bfd *bbfd));
 
 void 
-bfd_set_arch_info PARAMS ((bfd *abfd, bfd_arch_info_type *arg));
+bfd_set_arch_info PARAMS ((bfd *abfd, const bfd_arch_info_type *arg));
 
 enum bfd_architecture 
 bfd_get_arch PARAMS ((bfd *abfd));
@@ -1125,16 +1123,16 @@ bfd_arch_bits_per_byte PARAMS ((bfd *abfd));
 unsigned int 
 bfd_arch_bits_per_address PARAMS ((bfd *abfd));
 
-bfd_arch_info_type * 
+const bfd_arch_info_type * 
 bfd_get_arch_info PARAMS ((bfd *abfd));
 
-bfd_arch_info_type *
+const bfd_arch_info_type *
 bfd_lookup_arch
  PARAMS ((enum bfd_architecture
     arch,
     unsigned long machine));
 
-CONST char *
+const char *
 bfd_printable_arch_mach
  PARAMS ((enum bfd_architecture arch, unsigned long machine));
 
@@ -1355,12 +1353,19 @@ The 24-bit relocation is used in some Intel 960 configurations. */
   BFD_RELOC_8_GOT_PCREL,
   BFD_RELOC_32_GOTOFF,
   BFD_RELOC_16_GOTOFF,
+  BFD_RELOC_LO16_GOTOFF,
+  BFD_RELOC_HI16_GOTOFF,
+  BFD_RELOC_HI16_S_GOTOFF,
   BFD_RELOC_8_GOTOFF,
   BFD_RELOC_32_PLT_PCREL,
+  BFD_RELOC_24_PLT_PCREL,
   BFD_RELOC_16_PLT_PCREL,
   BFD_RELOC_8_PLT_PCREL,
   BFD_RELOC_32_PLTOFF,
   BFD_RELOC_16_PLTOFF,
+  BFD_RELOC_LO16_PLTOFF,
+  BFD_RELOC_HI16_PLTOFF,
+  BFD_RELOC_HI16_S_PLTOFF,
   BFD_RELOC_8_PLTOFF,
 
 /* Relocations used by 68K ELF. */
@@ -1371,6 +1376,9 @@ The 24-bit relocation is used in some Intel 960 configurations. */
 /* Linkage-table relative. */
   BFD_RELOC_32_BASEREL,
   BFD_RELOC_16_BASEREL,
+  BFD_RELOC_LO16_BASEREL,
+  BFD_RELOC_HI16_BASEREL,
+  BFD_RELOC_HI16_S_BASEREL,
   BFD_RELOC_8_BASEREL,
   BFD_RELOC_RVA,
 
@@ -1538,16 +1546,21 @@ to compensate for the borrow when the low bits are added. */
   BFD_RELOC_NS32K_DISP_16_PCREL,
   BFD_RELOC_NS32K_DISP_32_PCREL,
 
-/* PowerPC/POWER (RS/6000) relocs.
-26 bit relative branch.  Low two bits must be zero.  High 24
-bits installed in bits 6 through 29 of instruction. */
+/* Power(rs6000) and PowerPC relocations. */
   BFD_RELOC_PPC_B26,
-
-/* 26 bit absolute branch, like BFD_RELOC_PPC_B26 but absolute. */
   BFD_RELOC_PPC_BA26,
-
-/* 16 bit TOC relative reference. */
   BFD_RELOC_PPC_TOC16,
+  BFD_RELOC_PPC_B16,
+  BFD_RELOC_PPC_B16_BRTAKEN,
+  BFD_RELOC_PPC_B16_BRNTAKEN,
+  BFD_RELOC_PPC_BA16,
+  BFD_RELOC_PPC_BA16_BRTAKEN,
+  BFD_RELOC_PPC_BA16_BRNTAKEN,
+  BFD_RELOC_PPC_COPY,
+  BFD_RELOC_PPC_GLOB_DAT,
+  BFD_RELOC_PPC_JMP_SLOT,
+  BFD_RELOC_PPC_RELATIVE,
+  BFD_RELOC_PPC_LOCAL24PC,
 
 /* The type of reloc used to build a contructor table - at the moment
 probably a 32 bit wide absolute relocation, but the target can choose.
@@ -1674,15 +1687,14 @@ typedef struct symbol_cache_entry
         /* Signal that the symbol is the label of constructor section. */
 #define BSF_CONSTRUCTOR   0x800
 
-        /* Signal that the symbol is a warning symbol. If the symbol
-          is a warning symbol, then the value field (I know this is
-          tacky) will point to the asymbol which when referenced will
-          cause the warning. */
+        /* Signal that the symbol is a warning symbol.  The name is a
+          warning.  The name of the next symbol is the one to warn about;
+          if a reference is made to a symbol with the same name as the next
+          symbol, a warning is issued by the linker. */
 #define BSF_WARNING       0x1000
 
-        /* Signal that the symbol is indirect. The value of the symbol
-          is a pointer to an undefined asymbol which contains the
-          name to use instead. */
+        /* Signal that the symbol is indirect.  This symbol is an indirect
+          pointer to the symbol with the same name as the next symbol. */
 #define BSF_INDIRECT      0x2000
 
         /* BSF_FILE marks symbols that contain a file name.  This is used
@@ -1834,7 +1846,7 @@ struct _bfd
     struct symbol_cache_entry  **outsymbols;             
 
      /* Pointer to structure which contains architecture information*/
-    struct bfd_arch_info *arch_info;
+    const struct bfd_arch_info *arch_info;
 
      /* Stuff only useful for archives:*/
     PTR arelt_data;              
@@ -2202,6 +2214,7 @@ CAT(NAME,_slurp_extended_name_table),\
 CAT(NAME,_construct_extended_name_table),\
 CAT(NAME,_truncate_arname),\
 CAT(NAME,_write_armap),\
+CAT(NAME,_read_ar_hdr),\
 CAT(NAME,_openr_next_archived_file),\
 CAT(NAME,_generic_stat_arch_elt),\
 CAT(NAME,_update_armap_timestamp)
@@ -2215,6 +2228,7 @@ CAT(NAME,_update_armap_timestamp)
                               struct orl *map,
                               unsigned int orl_count, 
                               int stridx));
+  PTR (*_bfd_read_ar_hdr) PARAMS ((bfd *));
   bfd *    (*openr_next_archived_file) PARAMS ((bfd *arch, bfd *prev));
   int      (*_bfd_stat_arch_elt) PARAMS ((bfd *, struct stat *));
   boolean  (*_bfd_update_armap_timestamp) PARAMS ((bfd *));
This page took 0.026425 seconds and 4 git commands to generate.