(usage): Mention -S/--source.
(long_options): Add --source.
(prev_functionname, prev_line): New static variables.
(struct print_file_list): Define.
(print_files): New static variable.
(skip_to_line, show_line): New static functions.
(disassemble_data): Call show_line to handle -l and -S.
(main): Handle -S.
* binutils.texi, objdump.1: Document -S/--source.
[ -f | --file-headers ]
[ -h | --section-headers | --headers ] [ -i | --info ]
[ -j @var{section} | --section=@var{section} ]
- [ -l | --line-numbers ]
+ [ -l | --line-numbers ] [ -S | --source ]
[ -m @var{machine} | --architecture=@var{machine} ]
[ -r | --reloc ] [ -R | --dynamic-reloc ]
[ -s | --full-contents ] [ --stabs ]
@cindex object file sections
Display the full contents of any sections requested.
+@item -S
+@itemx --source
+@cindex source disassembly
+@cindex disassembly, with source
+Display source code intermixed with disassembly, if possible. Implies
+@samp{-d}.
+
@item --stabs
@cindex stab
@cindex .stab
.RB "[\|" \-r | \-\-reloc "\|]"
.RB "[\|" \-R | \-\-dynamic\-reloc "\|]"
.RB "[\|" \-s | \-\-full\-contents "\|]"
+.RB "[\|" \-S | \-\-source "\|]"
.RB "[\|" \-\-stabs "\|]"
.RB "[\|" \-t | \-\-syms "\|]"
.RB "[\|" \-T | \-\-dynamic\-syms "\|]"
.B \-\-full\-contents
Display the full contents of any sections requested.
+.TP
+.B \-S
+.TP
+.B \-\-source
+Display source code intermixed with disassembly, if possible. Implies
+\fB-d\fP.
+
.TP
.B \-\-stabs
Display the contents of the .stab, .stab.index, and .stab.excl