diff options
author | Jakub Jelinek <jakub@redhat.com> | 2004-08-17 09:07:35 +0000 |
---|---|---|
committer | Jakub Jelinek <jakub@redhat.com> | 2004-08-17 09:07:35 +0000 |
commit | 90e3cdf2a90318ccd4b5612d1e9fbd56ada53d84 (patch) | |
tree | 9d031cf419b1c87199a3e574a76499b1b27f0e07 /binutils | |
parent | 7c2c850509cdc711332dcffedef489386aee0a76 (diff) | |
download | gdb-90e3cdf2a90318ccd4b5612d1e9fbd56ada53d84.zip gdb-90e3cdf2a90318ccd4b5612d1e9fbd56ada53d84.tar.gz gdb-90e3cdf2a90318ccd4b5612d1e9fbd56ada53d84.tar.bz2 |
bfd/
* elfxx-target.h (bfd_elfNN_get_synthetic_symtab): Only define
if not yet defined.
* elf64-ppc.c (bfd_elf64_get_synthetic_symtab): Define.
(synthetic_opd, synthetic_relocatable): New variables.
(compare_symbols, compare_relocs): New helper routines.
(ppc64_elf_get_synthetic_symtab): New function.
* bfd.c (bfd_get_synthetic_symtab): Rename dynsyms argument
to relsyms.
* bfd-in2.h: Regenerated.
* elf.c (_bfd_elf_get_synthetic_symtab): Rename dynsyms argument
to relsyms. Return 0 if abfd is relocatable.
binutils/
* objdump.c (dump_bfd): For relocatable objects, pass syms instead
of dynsyms to bfd_get_synthetic_symtab.
Diffstat (limited to 'binutils')
-rw-r--r-- | binutils/ChangeLog | 5 | ||||
-rw-r--r-- | binutils/objdump.c | 14 |
2 files changed, 17 insertions, 2 deletions
diff --git a/binutils/ChangeLog b/binutils/ChangeLog index e00ad96..958a26a 100644 --- a/binutils/ChangeLog +++ b/binutils/ChangeLog @@ -1,3 +1,8 @@ +2004-08-17 Jakub Jelinek <jakub@redhat.com> + + * objdump.c (dump_bfd): For relocatable objects, pass syms instead + of dynsyms to bfd_get_synthetic_symtab. + 2004-08-16 Alan Modra <amodra@bigpond.net.au> * readelf.c (debug_apply_rela_addends): New function, extracted from.. diff --git a/binutils/objdump.c b/binutils/objdump.c index 7cc9640..af04b70 100644 --- a/binutils/objdump.c +++ b/binutils/objdump.c @@ -2564,9 +2564,19 @@ dump_bfd (bfd *abfd) if (dump_dynamic_symtab || dump_dynamic_reloc_info || (disassemble && bfd_get_dynamic_symtab_upper_bound (abfd) > 0)) dynsyms = slurp_dynamic_symtab (abfd); - if (disassemble && dynsymcount > 0) + if (disassemble) { - synthcount = bfd_get_synthetic_symtab (abfd, dynsyms, &synthsyms); + synthcount = 0; + if (bfd_get_file_flags (abfd) & (DYNAMIC | EXEC_P)) + { + if (dynsymcount > 0) + synthcount = bfd_get_synthetic_symtab (abfd, dynsyms, &synthsyms); + } + else + { + if (symcount > 0) + synthcount = bfd_get_synthetic_symtab (abfd, syms, &synthsyms); + } if (synthcount < 0) synthcount = 0; } |