aboutsummaryrefslogtreecommitdiff
path: root/bfd/libcoff.h
diff options
context:
space:
mode:
authorKen Raeburn <raeburn@cygnus>1992-12-03 23:03:17 +0000
committerKen Raeburn <raeburn@cygnus>1992-12-03 23:03:17 +0000
commit07de8e96b371ed08061203a7014bb08a4e92f375 (patch)
tree97767049d4f43f3adac2c8f6bbcb33f1a1ad9b83 /bfd/libcoff.h
parentbf229b4ea5f95fa036f6d3dc8fc7b236c5028f5e (diff)
downloadgdb-07de8e96b371ed08061203a7014bb08a4e92f375.zip
gdb-07de8e96b371ed08061203a7014bb08a4e92f375.tar.gz
gdb-07de8e96b371ed08061203a7014bb08a4e92f375.tar.bz2
syms.c (asymbol): Added new field "app_data", for data particular to the
application. Some of the linker flags ought to get moved to this field someday. archures.c (bfd_default_scan): Recognize a few more numbers: 80486, 80960, and 960. bfd-in.h, bfd.c, targets.c, coffcode.h, coff-mips.c, other targets: Moved COFF swap table to backend data. hosts/i386linux.h: Include unistd.h. aoutx.h, libaout.h, stab-syms.c: stab names are now in constant storage. trad-core.c: Fixed some `PARAMS' uses that were missing parentheses. aoutx.h, archive.c, archures.c, coffcode.h, ctor.c, reloc.c, syms.c: Doc fixes.
Diffstat (limited to 'bfd/libcoff.h')
-rw-r--r--bfd/libcoff.h109
1 files changed, 102 insertions, 7 deletions
diff --git a/bfd/libcoff.h b/bfd/libcoff.h
index 0eba7a6..094c30b 100644
--- a/bfd/libcoff.h
+++ b/bfd/libcoff.h
@@ -29,6 +29,7 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */
#define obj_relocbase(bfd) (coff_data(bfd)->relocbase)
#define obj_raw_syments(bfd) (coff_data(bfd)->raw_syments)
#define obj_convert(bfd) (coff_data(bfd)->conversion_table)
+#define obj_conv_table_size(bfd) (coff_data(bfd)->conv_table_size)
#if CFILE_STUFF
#define obj_symbol_slew(bfd) (coff_data(bfd)->symbol_index_slew)
#else
@@ -42,6 +43,7 @@ typedef struct coff_tdata
{
struct coff_symbol_struct *symbols; /* symtab for input bfd */
unsigned int *conversion_table;
+ int conv_table_size;
file_ptr sym_filepos;
long symbol_index_slew; /* used during read to mark whether a
@@ -104,13 +106,106 @@ union {
typedef struct coff_symbol_struct
{
- /* The actual symbol which the rest of BFD works with */
- asymbol symbol;
+ /* The actual symbol which the rest of BFD works with */
+asymbol symbol;
- /* A pointer to the hidden information for this symbol */
- combined_entry_type *native;
+ /* A pointer to the hidden information for this symbol */
+combined_entry_type *native;
- /* A pointer to the linenumber information for this symbol */
- struct lineno_cache_entry *lineno;
- boolean done_lineno;
+ /* A pointer to the linenumber information for this symbol */
+struct lineno_cache_entry *lineno;
+
+ /* Have the line numbers been relocated yet ? */
+boolean done_lineno;
} coff_symbol_type;
+typedef struct {
+ void (*_bfd_coff_swap_aux_in) PARAMS ((
+ bfd *abfd ,
+ PTR ext,
+ int type,
+ int class ,
+ PTR in));
+
+ void (*_bfd_coff_swap_sym_in) PARAMS ((
+ bfd *abfd ,
+ PTR ext,
+ PTR in));
+
+ void (*_bfd_coff_swap_lineno_in) PARAMS ((
+ bfd *abfd,
+ PTR ext,
+ PTR in));
+
+ unsigned int (*_bfd_coff_swap_aux_out) PARAMS ((
+ bfd *abfd,
+ PTR in,
+ int type,
+ int class,
+ PTR ext));
+
+ unsigned int (*_bfd_coff_swap_sym_out) PARAMS ((
+ bfd *abfd,
+ PTR in,
+ PTR ext));
+
+ unsigned int (*_bfd_coff_swap_lineno_out) PARAMS ((
+ bfd *abfd,
+ PTR in,
+ PTR ext));
+
+ unsigned int (*_bfd_coff_swap_reloc_out) PARAMS ((
+ bfd *abfd,
+ PTR src,
+ PTR dst));
+
+ unsigned int (*_bfd_coff_swap_filehdr_out) PARAMS ((
+ bfd *abfd,
+ PTR in,
+ PTR out));
+
+ unsigned int (*_bfd_coff_swap_aouthdr_out) PARAMS ((
+ bfd *abfd,
+ PTR in,
+ PTR out));
+
+ unsigned int (*_bfd_coff_swap_scnhdr_out) PARAMS ((
+ bfd *abfd,
+ PTR in,
+ PTR out));
+
+} bfd_coff_backend_data;
+
+extern bfd_coff_backend_data bfd_coff_std_swap_table;
+
+#define coff_backend_info(abfd) ((bfd_coff_backend_data *) (abfd)->xvec->backend_data)
+
+#define bfd_coff_swap_aux_in(a,e,t,c,i) \
+ ((coff_backend_info (a)->_bfd_coff_swap_aux_in) (a,e,t,c,i))
+
+#define bfd_coff_swap_sym_in(a,e,i) \
+ ((coff_backend_info (a)->_bfd_coff_swap_sym_in) (a,e,i))
+
+#define bfd_coff_swap_lineno_in(a,e,i) \
+ ((coff_backend_info ( a)->_bfd_coff_swap_lineno_in) (a,e,i))
+
+#define bfd_coff_swap_reloc_out(abfd, i, o) \
+ ((coff_backend_info (abfd)->_bfd_coff_swap_reloc_out) (abfd, i, o))
+
+#define bfd_coff_swap_lineno_out(abfd, i, o) \
+ ((coff_backend_info (abfd)->_bfd_coff_swap_lineno_out) (abfd, i, o))
+
+#define bfd_coff_swap_aux_out(abfd, i, t,c,o) \
+ ((coff_backend_info (abfd)->_bfd_coff_swap_aux_out) (abfd, i,t,c, o))
+
+#define bfd_coff_swap_sym_out(abfd, i,o) \
+ ((coff_backend_info (abfd)->_bfd_coff_swap_sym_out) (abfd, i, o))
+
+#define bfd_coff_swap_scnhdr_out(abfd, i,o) \
+ ((coff_backend_info (abfd)->_bfd_coff_swap_scnhdr_out) (abfd, i, o))
+
+#define bfd_coff_swap_filehdr_out(abfd, i,o) \
+ ((coff_backend_info (abfd)->_bfd_coff_swap_filehdr_out) (abfd, i, o))
+
+#define bfd_coff_swap_aouthdr_out(abfd, i,o) \
+ ((coff_backend_info (abfd)->_bfd_coff_swap_aouthdr_out) (abfd, i, o))
+