- Having a single script to automatically run the binary, attach gdb, re-set breakpoints every time you restart your debugging session.
- The main idea is to run your debugging processes on different Tmux panes and let the controller script (also running on another tmux pane) send keystrokes to automate activities on those panes.
- tmux
- If you run your tmux session as non-root user, the system configuration
/proc/sys/kernel/yama/ptrace_scope
should be set to 0 (i.e. runningecho 0 > /proc/sys/kernel/yama/ptrace_scope
as root) to allow attaching gdb to an existing process as non-root user.