How do I set breakpoints on all lines for a particular file.

Andrew Cagney cagney@gnu.org
Sun Feb 29 14:57:00 GMT 2004


> On Sunday 29 February 2004 13:45, Kotian, Deepak wrote:
> 
>>> Break at all functions in a particular file(.c file), can it be done?
> 
> 
> If you have the corresponding object file , maybe you can write a shell / awk 
> / perl script to generate this using objdump -t and finding out the function 
> symbols and using that in a gdb script and then include that using the source 
> command. 
> 
> Dont know of any other  way of setting breakpoints with respect to all 
> functions in the file you need. 

Hmm, there's an idea:

(top-gdb) rbreak 'main.c:*(*)'

nope :-(  but the theory is ok :-/





More information about the Gdb mailing list