From: Ian Lance Taylor Date: Tue, 13 Sep 1994 18:18:01 +0000 (+0000) Subject: * objdump.c (dump_section_header): Print the SEC_NEVER_LOAD flag. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=28d1b01e4342aa686221b5b0c036cadf4b81c3b3;p=binutils-gdb.git * objdump.c (dump_section_header): Print the SEC_NEVER_LOAD flag. --- diff --git a/binutils/objdump.c b/binutils/objdump.c index fcfce5a2f05..7f0c9f9a8e8 100644 --- a/binutils/objdump.c +++ b/binutils/objdump.c @@ -176,6 +176,7 @@ dump_section_header (abfd, section, ignored) PF (SEC_DATA, "DATA"); PF (SEC_ROM, "ROM"); PF (SEC_DEBUGGING, "DEBUGGING"); + PF (SEC_NEVER_LOAD, "NEVER_LOAD"); printf ("\n"); #undef PF } @@ -226,16 +227,18 @@ slurp_dynamic_symtab (abfd) asymbol **sy = (asymbol **) NULL; long storage; - if (!(bfd_get_file_flags (abfd) & DYNAMIC)) - { - fprintf (stderr, "%s: %s: not a dynamic object\n", - program_name, bfd_get_filename (abfd)); - return NULL; - } - storage = bfd_get_dynamic_symtab_upper_bound (abfd); if (storage < 0) - bfd_fatal (bfd_get_filename (abfd)); + { + if (!(bfd_get_file_flags (abfd) & DYNAMIC)) + { + fprintf (stderr, "%s: %s: not a dynamic object\n", + program_name, bfd_get_filename (abfd)); + return NULL; + } + + bfd_fatal (bfd_get_filename (abfd)); + } if (storage) { @@ -269,7 +272,7 @@ remove_useless_symbols (symbols, count) continue; if (sym->flags & (BSF_DEBUGGING)) continue; - if (sym->section == &bfd_und_section + if (bfd_is_und_section (sym->section) || bfd_is_com_section (sym->section)) continue; @@ -405,11 +408,9 @@ objdump_print_address (vma, info) for (i = thisplace + 1; i < symcount; i++) { if (syms[i]->value != syms[thisplace]->value) - { - i--; - break; - } + break; } + --i; for (; i >= 0; i--) { if (syms[i]->section == aux->sec) @@ -1043,9 +1044,9 @@ dump_relocs (abfd) { long relsize; - if (a == &bfd_abs_section) + if (bfd_is_abs_section (a)) continue; - if (a == &bfd_und_section) + if (bfd_is_und_section (a)) continue; if (bfd_is_com_section (a)) continue;