How do I run a debugger on dynamic Subversion binaries without having to install them?
Before the make install step on unix-y systems, dynamically built “executables” in a Subversion source tree are actually libtool-generated shell scripts which re-link and run the real binary. As shown below, this complicates debugging: subversion$ gdb subversion/svn/svn … “/path/to/subversion/subversion/svn/svn”: not in executable format: File format not recognized While this can be worked around by building using the –disable-shared argument to configure to statically link the binaries, or installing them and pointing your debugger at the installed version, it’s often necessary or more expedient to be able to debug them right within your source tree. To do so, edit the last exec statement in the shell script to run the real binary in your debugger. With gdb, this amounts to replacing exec “$progdir/$progname” with exec gdb –args “$progdir/$progname”. This trick is also very useful when applied to the libtool-generated shell scripts for the white box tests.