I'd like to set a set of breakpoints for a certain project to be loaded up when gdb starts. Until now I've been using ~/.gdbinit to hold those breakpoints, however, they are quite tedious to manage when using gdb with another project. Is there a way I can create gdb configurations custom to each project?
Asked
Active
Viewed 44 times
0
-
1You can have `gdb` load `.gdb_init` from the current directory. See (http://stackoverflow.com/questions/16595417/loading-gdbinit-from-current-directory) – Mark Plotnick Apr 15 '14 at 14:06
1 Answers
1
You can load any script with -x switch. So, gdb -x projectconfig.gdb yourbinary.
Projectconfig.gdb would contain what you initially had in .gdb_init.

dbrank0
- 9,026
- 2
- 37
- 55