GNU, linux based systems, free software and other computer related things...

Installing EMACS from Source Code

NOTE: All steps are tested in GNU/Debian Unstable. They should also work in Ubuntu.

We are going to install EMACS editor (actually almost a whole Operating System :-) ) from its source code.

    There are two options to obtain EMACS source code:
  • the stable release.
  • repository development branch.

Right now (september 2009) stable release version is 23.1.

We are going to download emacs stable release code:
$wget http://ftp.gnu.org/gnu/emacs/emacs-23.1.tar.gz

If we would want to download from repository instead:
$git clone git://git.savannah.gnu.org/emacs.git

We uncompress the tar ball:
$tar xvfz emacs-23.1.tar.gz
$cd emacs-23.1


Some packages are needed to compile the sources:

Compiler: #aptitude install gcc

Some headers and libraries:
#aptitude install xorg-dev libgtk2.0-dev libtiff-dev libpng-dev libgif-dev libgpm-dev libdbus-1-dev

To avoid "makeinfo is missing" error when installing:
#aptitude install texinfo


In the end we execute the standard commands to build most source code:
$./configure
$make
#make install

If everything has gone fine, now you can run emacs command.


GOOD DOCUMENTATION

Get emacs lisp manual
wget http://ftp.gnu.org/gnu/emacs/elisp-manual-21-2.8.tar.gz

Emacs lisp introduction:
wget http://ftp.gnu.org/gnu/emacs/emacs-lisp-intro-2.04.tar.gz

You can also buy printed copies of this books to support FSF and GNU project.

You can freely copy, change or create derivative works from this page contents, only requisite is adding a link to this web page.