Find out if GUI active in .gdbinit

Achim Bursian bursian@bigfoot.de
Fri Jan 17 22:34:00 GMT 2003


Hello,
how can I find out if the GUI (Insight) is running while executing
.gdbinit. I want to take different steps when -nw is given (especially
issue some tk commands if Insight is active).

And secondly, how can I source a gdb commandfile only if it exists?
Something like
if file exists $HOME/second.gdb
  source $HOME/second.gdb
endif

What is the way to do this in gdb (within .gdbinit)?

Thanks for help. (If possible, CC: to my mailaddress)
  Achim



More information about the Gdb mailing list