aboutsummaryrefslogtreecommitdiff
path: root/binutils/objdump.c
diff options
context:
space:
mode:
authorNick Clifton <nickc@redhat.com>2008-06-12 11:57:40 +0000
committerNick Clifton <nickc@redhat.com>2008-06-12 11:57:40 +0000
commitb922d5904f4a0ac69d5abfc8e24826b17012f334 (patch)
tree2d7ebe1abaceacb2bfad821c219956db6808eb27 /binutils/objdump.c
parent5590fba9534e101a6f41d7ad801442cf7af17f98 (diff)
downloadgdb-b922d5904f4a0ac69d5abfc8e24826b17012f334.zip
gdb-b922d5904f4a0ac69d5abfc8e24826b17012f334.tar.gz
gdb-b922d5904f4a0ac69d5abfc8e24826b17012f334.tar.bz2
PR binutils/6483
* objdump.c (dump_bfd): If the -g option found no STABS or IEEE debug information to display, try dumping DWARF information instead. * rddbg.c (read_debugging_info): Add a parameter to suppress the display of a warning message when no debug information is found. * budbg.h (read_debugging_info): Update prototype. * objcopy.c (copy_object): Continue to allow read_debugging_info to produce warning messages. * doc/binutils.texi (--debugging): Document new behaviour of the -g/--debugging option.
Diffstat (limited to 'binutils/objdump.c')
-rw-r--r--binutils/objdump.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/binutils/objdump.c b/binutils/objdump.c
index 5a86250..d171d14 100644
--- a/binutils/objdump.c
+++ b/binutils/objdump.c
@@ -2937,7 +2937,7 @@ dump_bfd (bfd *abfd)
{
void *dhandle;
- dhandle = read_debugging_info (abfd, syms, symcount);
+ dhandle = read_debugging_info (abfd, syms, symcount, TRUE);
if (dhandle != NULL)
{
if (!print_debugging_info (stdout, dhandle, abfd, syms,
@@ -2949,6 +2949,12 @@ dump_bfd (bfd *abfd)
exit_status = 1;
}
}
+ /* PR 6483: If there was no STABS or IEEE debug
+ info in the file, try DWARF instead. */
+ else if (! dump_dwarf_section_info)
+ {
+ dump_dwarf (abfd);
+ }
}
if (syms)