Using Binutils to view source code?
Nick Clifton
nickc@redhat.com
Wed Jan 22 10:01:00 GMT 2003
Hi James,
> >The "objdump" program can do this. Try using the "-dS" switches.
>
> Thanks - This only shows the assembly code though?
Actually the 'S' part of '-dS' will make objdump try to show the
source code interleaved with the disassembly. The problem is that it
does not, currently, support all debug formats.
If you find that it does not work for your binaries, try changing
debug format. (eg compiling with -gstabs). This may work.
Cheers
Nick
More information about the Binutils
mailing list