user108088
user108088

Reputation: 1168

Was executable compiled with debugging info?

How can you check if a Linux executable was compiled with symbolic debugging info?

Upvotes: 1

Views: 311

Answers (2)

Nils
Nils

Reputation: 13777

Not sure, because I'm on OSX right now, but maybe file shows if it contains symbols or not.

Upvotes: 0

Mario
Mario

Reputation: 36497

Quickest solution I can think of: Load it with GDB:

gdb myexecutable

You should get something like "(no debugging symbols found)" if there aren't any usable symbols inside.

Update: To return control to shell (or whatever) add --batch:

gdb myexecutable --batch

Upvotes: 4

Related Questions