aboutsummaryrefslogtreecommitdiff
path: root/bfd/syms.c
diff options
context:
space:
mode:
authorIan Lance Taylor <ian@airs.com>1996-01-29 22:04:32 +0000
committerIan Lance Taylor <ian@airs.com>1996-01-29 22:04:32 +0000
commit052b35d2e72af7da1fadbc2a4afa416195435b63 (patch)
tree121adc68419ea0495ba783ca318950791a1bdf79 /bfd/syms.c
parent53787b2316b0e9b4f166efc87f88748c46263096 (diff)
downloadgdb-052b35d2e72af7da1fadbc2a4afa416195435b63.zip
gdb-052b35d2e72af7da1fadbc2a4afa416195435b63.tar.gz
gdb-052b35d2e72af7da1fadbc2a4afa416195435b63.tar.bz2
Based on patches from Ronald F. Guilmette <rfg@monkeys.com>:
* syms.c (BSF_OBJECT): Define. (bfd_print_symbol_vandf): Print 'O' for BSF_OBJECT. * bfd-in2.h: Rebuild. * elfcode.h (elf_slurp_symbol_table): Set BSF_OBJECT for an STT_OBJECT symbol. * elf.c (swap_out_syms): Only set type to STT_OBJECT if BSF_OBJECT is set.
Diffstat (limited to 'bfd/syms.c')
-rw-r--r--bfd/syms.c13
1 files changed, 11 insertions, 2 deletions
diff --git a/bfd/syms.c b/bfd/syms.c
index 8024a2b..138979c 100644
--- a/bfd/syms.c
+++ b/bfd/syms.c
@@ -280,6 +280,10 @@ CODE_FRAGMENT
. {* Symbol is from dynamic linking information. *}
.#define BSF_DYNAMIC 0x8000
.
+. {* The symbol denotes a data object. Used in ELF, and perhaps
+. others someday. *}
+.#define BSF_OBJECT 0x10000
+.
. flagword flags;
.
. {* A pointer to the section to which this symbol is
@@ -417,7 +421,8 @@ bfd_print_symbol_vandf (arg, symbol)
}
/* This presumes that a symbol can not be both BSF_DEBUGGING and
- BSF_DYNAMIC, nor both BSF_FUNCTION and BSF_FILE. */
+ BSF_DYNAMIC, nor more than one of BSF_FUNCTION, BSF_FILE, and
+ BSF_OBJECT. */
fprintf (file, " %c%c%c%c%c%c%c",
((type & BSF_LOCAL)
? (type & BSF_GLOBAL) ? '!' : 'l'
@@ -427,7 +432,11 @@ bfd_print_symbol_vandf (arg, symbol)
(type & BSF_WARNING) ? 'W' : ' ',
(type & BSF_INDIRECT) ? 'I' : ' ',
(type & BSF_DEBUGGING) ? 'd' : (type & BSF_DYNAMIC) ? 'D' : ' ',
- (type & BSF_FUNCTION) ? 'F' : (type & BSF_FILE) ? 'f' : ' ');
+ ((type & BSF_FUNCTION)
+ ? 'F'
+ : ((type & BSF_FILE)
+ ? 'f'
+ : ((type & BSF_OBJECT) ? 'O' : ' '))));
}