Add a --source-comment=<text> option to objdump which provides a prefix to dipslayed...
authorNick Clifton <nickc@redhat.com>
Wed, 28 Aug 2019 10:39:19 +0000 (11:39 +0100)
committerNick Clifton <nickc@redhat.com>
Wed, 28 Aug 2019 10:39:19 +0000 (11:39 +0100)
commita1c110a3fe02f5cb8de18137f6615005288e849e
tree7a2209dfa1f841214890f58efffd960bd2ce9dee
parent72dd1784ef6c5157af03c50975aee603e9b6078e
Add a --source-comment=<text> option to objdump which provides a prefix to dipslayed source code lines.

PR 24931
* objdump.c (source_comment): New static variable.
(option_values): Add OPTION_SOURCE_COMMENT.
(long_opions): Add --source-comment.
(print_line): If source comment is set, use it as a prefix to the
source code line.
(main): Handle OPTION_SOURCE_COMMENT.
* doc/binutils.texi: Document the new option.
* NEWS: Mention the new feature.
* testsuite/binutils-all/objdump.exp (test_objdump_S): Add tests
of the -S and --source-comment options.
binutils/ChangeLog
binutils/NEWS
binutils/doc/binutils.texi
binutils/objdump.c
binutils/testsuite/binutils-all/objdump.exp