Debug stripped executables with detached symbols in GDB
Say you have an executable that will be shipped to target machines and you don’t want to include any debug symbols, but at the same time if an annoying bug occurs you’d like to debug the executable with symbols. Is it possible to have both ways? As a matter of fact, yes! GNU Debugger (GDB) has a feature where it can load a separate symbols file to make it easier to debug stripped executables. This would allow you to ship stripped binaries, archive symbols files and when needed load them both into a debug session. ...