4

I have an application I would like to inspect and I don't have the sources to rebuild it and create the Symbol Table like here (gcc -g my_app.c).

When I call the info locals I get the following error "No symbol table info available"

When I'm working with Eclipse even when I don't have the sources of the library it can resolve the arguments of the current function into arg0, arg1... argN and if I remember correctly also the members of objects.

Is there any way to generate a custom/generic/default symbol table, one that would satisfy GDB and would allow me to see the values of local variables and arguments?

Community
  • 1
  • 1
MP_
  • 75
  • 1
  • 7
  • 3
    No source, debug build or symbol table? You're more stuffed than a Christmas turkey. – Martin James Jan 01 '15 at 11:04
  • @MartinJames Do you have a more constructive comment? – TacB0sS Jan 01 '15 at 11:55
  • Sadly, no. My only option was a non-constructive comment. If you have no symbol table and no debug build, you have nothing. – Martin James Jan 01 '15 at 12:15
  • @MartinJames So how it is done in Eclipse? – MP_ Jan 01 '15 at 12:51
  • @MP_: Google search [indicates](https://www.google.pl/search?q=eclipse+arg0+arg1&ie=utf-8&oe=utf-8&gws_rd=cr&ei=Q8ClVOvBGsS0UdKChPAK#q=eclipse+arg0+arg1), that you are confusing Eclipse with Java language. Can you confirm this sort of generic parameters' names does work in CDT? – Grzegorz Szpetkowski Jan 01 '15 at 21:53
  • 1
    BTW, this is why I prefer free software: when I need it, I can always get the source code and study it. It actually is less painful to avoid proprietary software. So if you don't have the source code, don't use your application (and try to replace it with some free software) – Basile Starynkevitch Jan 03 '15 at 07:51
  • Thank you guys for the comments... I was confusing with Java! – MP_ Jan 04 '15 at 11:56

1 Answers1

5

the answer is No.

The local symbols are only useful for debugging so there is no alternative. If they have been discarded they are gone.

Jasen
  • 11,837
  • 2
  • 30
  • 48
  • why arent the args visible at runtime? in other words, if I read "no symbol table info available", how can I see the arguments passed to the current function? – phil294 Dec 28 '16 at 16:23
  • 1
    a function just gets the stack... the args are in there somewhere, you can probably inspect the stack, but figuring out what each byte means could be tricky. – Jasen Dec 29 '16 at 04:53