LoginSignup
14
14

More than 5 years have passed since last update.

Emacs24をビルドしてインストールする手順

Last updated at Posted at 2014-10-13

はじめに

開発環境構築のため、VirtualBoxでMacOSX上にDebian GNU/Linux(Wheezy)をインストールしました。
エディタはEmacs24を使いたいからソースコードからビルドしてインストールしてみました。

基本的にホストOSからsshで接続してコーディングするつもりなので、GUI関係のオプションいれません。

コマンド

コンパイルに必要なパッケージをインストール

emacsのコンパイルに必要なパッケージをインストールします。
↓の感じでインストールしました。

$ sudo aptitude install libgtk2.0-dev  libXpm-dev libjpeg8-dev libgif-dev libtiff4-dev libncurses5-dev libgtk-3-dev libgnutls-dev libselinux1-dev libmagick++-dev

ソースコードを入手

GNU本家からEmacs24のソースコードを入手し、展開します。
現時点(2014-10-14)では24.3が最新版です。

$ curl -O http://core.ring.gr.jp/pub/GNU/emacs/emacs-24.3.tar.gz
$ tar -zxf emacs-24.3.tar.gz

ビルド、インストール

バイナリは ${HOME}/local 以下にインストールします。
デフォルトでは /usr/local いかにインストールされてしまうので、 --prefix=$HOME/local でホームディレクトリにインストールされるように指定しています。

$ cd emacs-24.3
$ ./configure --prefix=$HOME/local --without-x
$ make
$ make install

問題なく終了すれば、emacsコマンドは ${HOME}/local/bin/emacs にインストールされているはずです。
以上!

なお、ビルドのために展開したemacs-24.3ディレクトリはそのまま残しておいた方がいいかも。
emacsを削除する場合に make uninstall を使えるかも知れません。

14
14
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
14
14