The following guide outlines how to quickly get started with using Git, building Emacs for debugging, and running Emacs in GDB (the GNU Project debugger).

First of all, ensure that source packages are available. On Ubuntu or Linux Mint, it is recommended to use the Software Sources tool, since use of the command line depends on the distribution being used.

Enabling source code repositories on Ubuntu

Enabling source code repositories on Linux Mint (click “Enable source code repositories” and the “Update the cache” button)

On Debian-based distros (including Ubuntu and Linux Mint), install the following (checkinstall is useful if you want to later install your builds using ‘make install’): sudo apt-get install build-essential checkinstall git-core Then download the dependencies for Emacs using: sudo apt-get build-dep emacs24 Other guides are available online for other distributions.

Installing ccache for Faster Rebuild Times (Optional)

Ccache is a tool that works with GCC, speeding up recompilation by caching previous outputs and detecting when the same compilation is being carried out again. This tool provides noticeable improvements when rebuilding after running the clean task (e.g. make clean; make ).

To install it on a Debian/Ubuntu based distribution, use the commands below. It is important to add the /usr/lib/ccache to the path if you want ccache to wrap around runs to gcc but remember this is applied to all calls and may interfere with other compiler wrappers.