Build options `-ggdb` and `-Og` are required (note that the official GNU user manual recommends `-Og` over `-O0` for debugging, too). This isn't common knowledge and should be emphasized somewhere. See this answer here: https://stackoverflow.com/questions/63386189/whats-the-difference-between-a-compilers-o0-option-and-og-option/63386263#63386263. > > [`-Og`] is a better choice than -O0 for producing debuggable code because some compiler passes that collect debug information are disabled at -O0. > > https://gcc.gnu.org/onlinedocs/gcc/Optimize-Options.html#Optimize-Options This should be in your [Getting Started](https://www.gdbgui.com/gettingstarted/) and [Examples](https://www.gdbgui.com/examples/) sections of your documentation.