Mirror of the gdb mailing list
 help / color / mirror / Atom feed
* gdb basic questions
@ 2009-11-16 10:23 nagaraju.m
  0 siblings, 0 replies; 3+ messages in thread
From: nagaraju.m @ 2009-11-16 10:23 UTC (permalink / raw)
  To: gdb; +Cc: ranjith kumar

Hi Ranjith,


    You can use -x option and link a command file which will take 
commands from the input file


     open a new file:
 
     Then type the commands you want to give input to gdb
   
    tar simulator
    load
    b main
    r
    info reg
    c
    q
   
then call gdb  -x option

 [nagaraju@nagaraju nagaraju]$ gdb a.out -x gdb.cmd



Good luck,
Nagaraju M
   


^ permalink raw reply	[flat|nested] 3+ messages in thread
* gdb basic questions
@ 2009-11-15 17:30 ranjith kumar
  2009-11-15 18:46 ` Jan Kratochvil
  0 siblings, 1 reply; 3+ messages in thread
From: ranjith kumar @ 2009-11-15 17:30 UTC (permalink / raw)
  To: gdb

hi,
I am new to gdb. I have 3 questions.

Suppose that we want to keep a breakpoint at a function say
'myfunction', we will a gdb command
(gdb) b myfunction
at  gdb command prompt.

What I want is keep breakpoints at, say, 1000 functions.
 But I cant type 1000 times '(gdb)  b functionname'.
1) Is there any way to keep breakpoints at 1000 functions,  without
typing ?( Assume I have saved all 1000 funcion names in a file)

2) Generally, is it possible to ask gdb to go and read 'gdb commands'
from a file?

3) Another question. Sometimes gdb diplays a message like below and
waits for user to type 'y or n'.
"Make breakpoint pending on future shared library load? (y or [n]) "
How to tell gdb to not to wait for input from user and assume that
user has typed 'y' always ?

Thanks in advance.


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2009-11-16  6:36 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-11-16 10:23 gdb basic questions nagaraju.m
  -- strict thread matches above, loose matches on Subject: below --
2009-11-15 17:30 ranjith kumar
2009-11-15 18:46 ` Jan Kratochvil

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox