diff options
author | Steve Chamberlain <sac@cygnus> | 1992-10-08 16:02:09 +0000 |
---|---|---|
committer | Steve Chamberlain <sac@cygnus> | 1992-10-08 16:02:09 +0000 |
commit | 294eaca479e9ced9a87b958c37feb2c570aa1595 (patch) | |
tree | bb7a6bb0ac1df535df9c7fe230c1a0bc81b85ab3 /bfd/bfd-in.h | |
parent | 0da7012441eaccf157dc44c8cc110fbf2d3f8376 (diff) | |
download | gdb-294eaca479e9ced9a87b958c37feb2c570aa1595.zip gdb-294eaca479e9ced9a87b958c37feb2c570aa1595.tar.gz gdb-294eaca479e9ced9a87b958c37feb2c570aa1595.tar.bz2 |
Some of these are guesses, if you know different, just yell.
Thu Oct 8 08:52:48 1992 Steve Chamberlain (sac@thepub.cygnus.com)
Now a bfd knows whether underscores are normally prepended
to symbols in its file format. Helps with error messages.
* aout-adobe.c, aout-target.h, bout.c, coff-a29k.c, coff-h8300.c,
coff-z8k.c: targets set so they have leading underscore
* coff-i386.c, coff-i960.c, coff-m68k.c, coff-mips.c, coff-m88k.c,
coff-rs6000.c, coff-we32k.c, elf.c, ieee.c, srec.c: targets set
without leading underscore flag
* targets.c: add symbol leading char to xvec description
* bfd-in.h (bfd_get_symbol_leading_char): new macro.
Diffstat (limited to 'bfd/bfd-in.h')
-rw-r--r-- | bfd/bfd-in.h | 50 |
1 files changed, 21 insertions, 29 deletions
diff --git a/bfd/bfd-in.h b/bfd/bfd-in.h index f14de50..ad343fe 100644 --- a/bfd/bfd-in.h +++ b/bfd/bfd-in.h @@ -52,7 +52,7 @@ here. */ # endif #endif -#define BFD_VERSION "1.96" +#define BFD_VERSION "2.0" /* forward declaration */ typedef struct _bfd bfd; @@ -106,17 +106,17 @@ typedef enum bfd_format { bfd_format; /* Object file flag values */ -#define NO_FLAGS 0 -#define HAS_RELOC 001 -#define EXEC_P 002 -#define HAS_LINENO 004 -#define HAS_DEBUG 010 -#define HAS_SYMS 020 -#define HAS_LOCALS 040 -#define DYNAMIC 0100 -#define WP_TEXT 0200 -#define D_PAGED 0400 - +#define NO_FLAGS 0x00 +#define HAS_RELOC 0x01 +#define EXEC_P 0x02 +#define HAS_LINENO 0x04 +#define HAS_DEBUG 0x08 +#define HAS_SYMS 0x10 +#define HAS_LOCALS 0x20 +#define DYNAMIC 0x40 +#define WP_TEXT 0x80 +#define D_PAGED 0x100 +#define BFD_IS_RELAXABLE 0x200 /* symbols and relocation */ @@ -180,14 +180,17 @@ typedef struct lineno_cache_entry { typedef struct sec *sec_ptr; +#define bfd_get_section_name(bfd, ptr) ((ptr)->name + 0) +#define bfd_get_section_vma(bfd, ptr) ((ptr)->vma + 0) +#define bfd_get_section_alignment(bfd, ptr) ((ptr)->alignment_power + 0) #define bfd_section_name(bfd, ptr) ((ptr)->name) #define bfd_section_size(bfd, ptr) (bfd_get_section_size_before_reloc(ptr)) #define bfd_section_vma(bfd, ptr) ((ptr)->vma) #define bfd_section_alignment(bfd, ptr) ((ptr)->alignment_power) -#define bfd_get_section_flags(bfd, ptr) ((ptr)->flags) +#define bfd_get_section_flags(bfd, ptr) ((ptr)->flags + 0) #define bfd_get_section_userdata(bfd, ptr) ((ptr)->userdata) -#define bfd_set_section_vma(bfd, ptr, val) (((ptr)->vma = (val)), true) +#define bfd_set_section_vma(bfd, ptr, val) (((ptr)->vma = (val)), ((ptr)->user_set_vma = true), true) #define bfd_set_section_alignment(bfd, ptr, val) (((ptr)->alignment_power = (val)),true) #define bfd_set_section_userdata(bfd, ptr, val) (((ptr)->userdata = (val)),true) @@ -203,7 +206,7 @@ typedef enum bfd_error { symbol_not_found, file_not_recognized, file_ambiguously_recognized, no_contents, bfd_error_nonrepresentable_section, - no_debug_section, + no_debug_section, bad_value, invalid_error_code} bfd_ec; extern bfd_ec bfd_error; @@ -226,7 +229,7 @@ typedef struct bfd_error_vector { } bfd_error_vector_type; -PROTO (char *, bfd_errmsg, (bfd_ec error_tag)); +PROTO (CONST char *, bfd_errmsg, (bfd_ec error_tag)); PROTO (void, bfd_perror, (CONST char *message)); @@ -324,21 +327,10 @@ extern CONST short _bfd_host_big_endian; #define bfd_get_architecture(abfd) ((abfd)->obj_arch) #define bfd_get_machine(abfd) ((abfd)->obj_machine) - +#define bfd_get_symbol_leading_char(abfd) ((abfd)->xvec->symbol_leading_char) #define BYTE_SIZE 1 #define SHORT_SIZE 2 #define LONG_SIZE 4 - - -/* ANd more from the source */ - - - - - - - - - +/* And more from the source. */ |