The executable file of c++ will contain linkers, modules and others, i would like to look into its contents,
i’m using linux, how can i view contents of a.out?
which command should use to browse a.out, text editors wont show the contents……
The executable file of c++ will contain linkers, modules and others, i would like
Share
You can use
nmto see the internal symbols andobjdumpto get the disassemble. By example:Note however that during the final linking of the object files into the executable a lot of symbols and internal data get eliminated, therefore you won’t be able to understand the structure as you would be with object files.
If you want to edit and modify the executable, I suggest you to use the
hteeditor, which can act as disassembler for x86 executables. If you are a debian/ubuntu user the package name is “ht” (not “hte”).Also I wrote a little elf disassembly library which is still incomplete but pretty funny. You can find other (more complete and probably better) implementations however!