In Linux environment? If you have GCC installed, you should have readelf executable. So you can try this
readelf --debug-dump=info binary_name | grep -A 2 'Compilation Unit @'
0
votes
You could also use "llvm-dwarfdump" tool as below
llvm-dwarfdump --debug-dump=info hello | grep 'Compile Unit:'
0x00000000: Compile Unit: length = 0x00000075 version = 0x0004 abbr_offset = 0x0000 addr_size = 0x08 (next unit at 0x00000079)
We use cookies to ensure that we give you the best experience on our website. If you continue to use this site we will assume that you are happy with it.OkRead more