一、 安装依赖包
sudo apt-get build-dep emacs23
正在读取软件包列表... 完成 正在分析软件包的依赖关系树 正在读取状态信息... 完成 下列软件包将被【卸载】: libtiff5-dev 下列【新】软件包将被安装: bsd-mailx diffstat exim4-base exim4-config exim4-daemon-light gir1.2-gconf-2.0 gir1.2-rsvg-2.0 imagemagick libasound2-dev libdatrie-dev libdbus-1-dev libgconf2-dev libgpm-dev liblockfile-bin liblockfile-dev liblockfile1 libm17n-0 libm17n-dev libotf-dev libotf0 librsvg2-dev libthai-dev libtiff4-dev libtiffxx0c2 libxml2-dev m17n-contrib m17n-db quilt sharutils xaw3dg xaw3dg-dev xutils-dev 升级了 0 个软件包,新安装了 32 个软件包,要卸载 1 个软件包,有 0 个软件包未被升级。 需要下载 10.0 MB 的软件包。 解压缩后会消耗掉 24.9 MB 的额外空间。 您希望继续执行吗?[Y/n]y 获取:1 http://ftp.cn.debian.org/debian/ stable/main liblockfile-bin amd64 1.09-5 [18.6 kB] 获取:2 http://ftp.cn.debian.org/debian/ stable/main liblockfile1 amd64 1.09-5 [15.5 kB] 获取:3 http://ftp.cn.debian.org/debian/ stable/main libtiffxx0c2 amd64 3.9.6-11 [63.4 kB] 获取:4 http://ftp.cn.debian.org/debian/ stable/main xaw3dg amd64 1.5+E-18.2 [179 kB] 获取:5 http://ftp.cn.debian.org/debian/ stable/main exim4-config all 4.80-7+deb7u1 [478 kB] 获取:6 http://ftp.cn.debian.org/debian/ stable/main exim4-base amd64 4.80-7+deb7u1 [1,040 kB] 获取:7 http://ftp.cn.debian.org/debian/ stable/main exim4-daemon-light amd64 4.80-7+deb7u1 [655 kB] 获取:8 http://ftp.cn.debian.org/debian/ stable/main bsd-mailx amd64 8.1.2-0.20111106cvs-1 [85.3 kB] 获取:9 http://ftp.cn.debian.org/debian/ stable/main diffstat amd64 1.55-3 [30.0 kB] 获取:10 http://ftp.cn.debian.org/debian/ stable/main gir1.2-gconf-2.0 amd64 3.2.5-1+build1 [357 kB] 获取:11 http://ftp.cn.debian.org/debian/ stable/main gir1.2-rsvg-2.0 amd64 2.36.1-2 [160 kB] 获取:12 http://ftp.cn.debian.org/debian/ stable/main imagemagick amd64 8:6.7.7.10-5+deb7u3 [285 kB] 获取:13 http://ftp.cn.debian.org/debian/ stable/main libasound2-dev amd64 1.0.25-4 [70.3 kB] 获取:14 http://ftp.cn.debian.org/debian/ stable/main libdatrie-dev amd64 0.2.5-3 [32.2 kB] 获取:15 http://ftp.cn.debian.org/debian/ stable/main libdbus-1-dev amd64 1.6.8-1+deb7u4 [247 kB] 获取:16 http://ftp.cn.debian.org/debian/ stable/main libgconf2-dev amd64 3.2.5-1+build1 [441 kB] 获取:17 http://ftp.cn.debian.org/debian/ stable/main libgpm-dev amd64 1.20.4-6 [39.9 kB] 获取:18 http://ftp.cn.debian.org/debian/ stable/main liblockfile-dev amd64 1.09-5 [25.8 kB] 获取:19 http://ftp.cn.debian.org/debian/ stable/main libotf0 amd64 0.9.12-2 [52.2 kB] 获取:20 http://ftp.cn.debian.org/debian/ stable/main m17n-db all 1.6.3-2 [1,852 kB] 获取:21 http://ftp.cn.debian.org/debian/ stable/main m17n-contrib all 1.1.13-2 [545 kB] 获取:22 http://ftp.cn.debian.org/debian/ stable/main libm17n-0 amd64 1.6.3-2 [275 kB] 获取:23 http://ftp.cn.debian.org/debian/ stable/main libxml2-dev amd64 2.8.0+dfsg1-7+wheezy1 [900 kB] 获取:24 http://ftp.cn.debian.org/debian/ stable/main libthai-dev amd64 0.1.18-2 [53.0 kB] 获取:25 http://ftp.cn.debian.org/debian/ stable/main libm17n-dev amd64 1.6.3-2 [286 kB] 获取:26 http://ftp.cn.debian.org/debian/ stable/main libotf-dev amd64 0.9.12-2 [60.9 kB] 获取:27 http://ftp.cn.debian.org/debian/ stable/main librsvg2-dev amd64 2.36.1-2 [254 kB] 获取:28 http://ftp.cn.debian.org/debian/ stable/main libtiff4-dev amd64 3.9.6-11 [337 kB] 获取:29 http://ftp.cn.debian.org/debian/ stable/main quilt all 0.60-2 [377 kB] 获取:30 http://ftp.cn.debian.org/debian/ stable/main sharutils amd64 1:4.11.1-1 [195 kB] 获取:31 http://ftp.cn.debian.org/debian/ stable/main xutils-dev amd64 1:7.7~1 [350 kB] 获取:32 http://ftp.cn.debian.org/debian/ stable/main xaw3dg-dev amd64 1.5+E-18.2 [252 kB] 下载 10.0 MB,耗时 52秒 (190 kB/s) 正在从软件包中解出模板:100% 正在预设定软件包 ... (正在读取数据库 ... 系统当前共安装有 107847 个文件和目录。) 正在卸载 libtiff5-dev ... 正在处理用于 man-db 的触发器... Selecting previously unselected package liblockfile-bin. (正在读取数据库 ... 系统当前共安装有 107790 个文件和目录。) 正在解压缩 liblockfile-bin (从 .../liblockfile-bin_1.09-5_amd64.deb) ... Selecting previously unselected package liblockfile1:amd64. 正在解压缩 liblockfile1:amd64 (从 .../liblockfile1_1.09-5_amd64.deb) ... Selecting previously unselected package libtiffxx0c2:amd64. 正在解压缩 libtiffxx0c2:amd64 (从 .../libtiffxx0c2_3.9.6-11_amd64.deb) ... Selecting previously unselected package xaw3dg:amd64. 正在解压缩 xaw3dg:amd64 (从 .../xaw3dg_1.5+E-18.2_amd64.deb) ... Selecting previously unselected package exim4-config. 正在解压缩 exim4-config (从 .../exim4-config_4.80-7+deb7u1_all.deb) ... Selecting previously unselected package exim4-base. 正在解压缩 exim4-base (从 .../exim4-base_4.80-7+deb7u1_amd64.deb) ... Selecting previously unselected package exim4-daemon-light. 正在解压缩 exim4-daemon-light (从 .../exim4-daemon-light_4.80-7+deb7u1_amd64.deb) ... Selecting previously unselected package bsd-mailx. 正在解压缩 bsd-mailx (从 .../bsd-mailx_8.1.2-0.20111106cvs-1_amd64.deb) ... Selecting previously unselected package diffstat. 正在解压缩 diffstat (从 .../diffstat_1.55-3_amd64.deb) ... Selecting previously unselected package gir1.2-gconf-2.0. 正在解压缩 gir1.2-gconf-2.0 (从 .../gir1.2-gconf-2.0_3.2.5-1+build1_amd64.deb) ... Selecting previously unselected package gir1.2-rsvg-2.0. 正在解压缩 gir1.2-rsvg-2.0 (从 .../gir1.2-rsvg-2.0_2.36.1-2_amd64.deb) ... Selecting previously unselected package imagemagick. 正在解压缩 imagemagick (从 .../imagemagick_8%3a6.7.7.10-5+deb7u3_amd64.deb) ... Selecting previously unselected package libasound2-dev:amd64. 正在解压缩 libasound2-dev:amd64 (从 .../libasound2-dev_1.0.25-4_amd64.deb) ... Selecting previously unselected package libdatrie-dev. 正在解压缩 libdatrie-dev (从 .../libdatrie-dev_0.2.5-3_amd64.deb) ... Selecting previously unselected package libdbus-1-dev. 正在解压缩 libdbus-1-dev (从 .../libdbus-1-dev_1.6.8-1+deb7u4_amd64.deb) ... Selecting previously unselected package libgconf2-dev. 正在解压缩 libgconf2-dev (从 .../libgconf2-dev_3.2.5-1+build1_amd64.deb) ... Selecting previously unselected package libgpm-dev:amd64. 正在解压缩 libgpm-dev:amd64 (从 .../libgpm-dev_1.20.4-6_amd64.deb) ... Selecting previously unselected package liblockfile-dev. 正在解压缩 liblockfile-dev (从 .../liblockfile-dev_1.09-5_amd64.deb) ... Selecting previously unselected package libotf0. 正在解压缩 libotf0 (从 .../libotf0_0.9.12-2_amd64.deb) ... Selecting previously unselected package m17n-db. 正在解压缩 m17n-db (从 .../m17n-db_1.6.3-2_all.deb) ... Selecting previously unselected package m17n-contrib. 正在解压缩 m17n-contrib (从 .../m17n-contrib_1.1.13-2_all.deb) ... Selecting previously unselected package libm17n-0. 正在解压缩 libm17n-0 (从 .../libm17n-0_1.6.3-2_amd64.deb) ... Selecting previously unselected package libxml2-dev:amd64. 正在解压缩 libxml2-dev:amd64 (从 .../libxml2-dev_2.8.0+dfsg1-7+wheezy1_amd64.deb) ... Selecting previously unselected package libthai-dev. 正在解压缩 libthai-dev (从 .../libthai-dev_0.1.18-2_amd64.deb) ... Selecting previously unselected package libm17n-dev. 正在解压缩 libm17n-dev (从 .../libm17n-dev_1.6.3-2_amd64.deb) ... Selecting previously unselected package libotf-dev. 正在解压缩 libotf-dev (从 .../libotf-dev_0.9.12-2_amd64.deb) ... Selecting previously unselected package librsvg2-dev. 正在解压缩 librsvg2-dev (从 .../librsvg2-dev_2.36.1-2_amd64.deb) ... Selecting previously unselected package libtiff4-dev. 正在解压缩 libtiff4-dev (从 .../libtiff4-dev_3.9.6-11_amd64.deb) ... Selecting previously unselected package quilt. 正在解压缩 quilt (从 .../archives/quilt_0.60-2_all.deb) ... Selecting previously unselected package sharutils. 正在解压缩 sharutils (从 .../sharutils_1%3a4.11.1-1_amd64.deb) ... Selecting previously unselected package xutils-dev. 正在解压缩 xutils-dev (从 .../xutils-dev_1%3a7.7~1_amd64.deb) ... Selecting previously unselected package xaw3dg-dev:amd64. 正在解压缩 xaw3dg-dev:amd64 (从 .../xaw3dg-dev_1.5+E-18.2_amd64.deb) ... 正在处理用于 man-db 的触发器... 正在处理用于 mime-support 的触发器... 正在处理用于 menu 的触发器... 正在处理用于 desktop-file-utils 的触发器... 正在处理用于 hicolor-icon-theme 的触发器... 正在处理用于 install-info 的触发器... 正在设置 liblockfile-bin (1.09-5) ... 正在设置 liblockfile1:amd64 (1.09-5) ... 正在设置 libtiffxx0c2:amd64 (3.9.6-11) ... 正在设置 xaw3dg:amd64 (1.5+E-18.2) ... 正在设置 exim4-config (4.80-7+deb7u1) ... Adding system-user for exim (v4) 正在设置 exim4-base (4.80-7+deb7u1) ... exim: DB upgrade, deleting hints-db 正在设置 exim4-daemon-light (4.80-7+deb7u1) ... [ ok ] Starting MTA: exim4. 正在设置 bsd-mailx (8.1.2-0.20111106cvs-1) ... update-alternatives: using /usr/bin/bsd-mailx to provide /usr/bin/mailx (mailx) in 自动模式 正在设置 diffstat (1.55-3) ... 正在设置 gir1.2-gconf-2.0 (3.2.5-1+build1) ... 正在设置 gir1.2-rsvg-2.0 (2.36.1-2) ... 正在设置 imagemagick (8:6.7.7.10-5+deb7u3) ... update-alternatives: using /usr/bin/compare.im6 to provide /usr/bin/compare (compare) in 自动模式 update-alternatives: using /usr/bin/animate.im6 to provide /usr/bin/animate (animate) in 自动模式 update-alternatives: using /usr/bin/convert.im6 to provide /usr/bin/convert (convert) in 自动模式 update-alternatives: using /usr/bin/composite.im6 to provide /usr/bin/composite (composite) in 自动模式 update-alternatives: using /usr/bin/conjure.im6 to provide /usr/bin/conjure (conjure) in 自动模式 update-alternatives: using /usr/bin/import.im6 to provide /usr/bin/import (import) in 自动模式 update-alternatives: using /usr/bin/identify.im6 to provide /usr/bin/identify (identify) in 自动模式 update-alternatives: using /usr/bin/stream.im6 to provide /usr/bin/stream (stream) in 自动模式 update-alternatives: using /usr/bin/display.im6 to provide /usr/bin/display (display) in 自动模式 update-alternatives: using /usr/bin/montage.im6 to provide /usr/bin/montage (montage) in 自动模式 update-alternatives: using /usr/bin/mogrify.im6 to provide /usr/bin/mogrify (mogrify) in 自动模式 正在设置 libasound2-dev:amd64 (1.0.25-4) ... 正在设置 libdatrie-dev (0.2.5-3) ... 正在设置 libdbus-1-dev (1.6.8-1+deb7u4) ... 正在设置 libgconf2-dev (3.2.5-1+build1) ... 正在设置 libgpm-dev:amd64 (1.20.4-6) ... 正在设置 liblockfile-dev (1.09-5) ... 正在设置 libotf0 (0.9.12-2) ... 正在设置 m17n-db (1.6.3-2) ... 正在设置 m17n-contrib (1.1.13-2) ... 正在设置 libm17n-0 (1.6.3-2) ... 正在设置 libxml2-dev:amd64 (2.8.0+dfsg1-7+wheezy1) ... 正在设置 libthai-dev (0.1.18-2) ... 正在设置 libm17n-dev (1.6.3-2) ... 正在设置 libotf-dev (0.9.12-2) ... 正在设置 librsvg2-dev (2.36.1-2) ... 正在设置 libtiff4-dev (3.9.6-11) ... 正在设置 quilt (0.60-2) ... 正在设置 sharutils (1:4.11.1-1) ... 正在设置 xutils-dev (1:7.7~1) ... 正在设置 xaw3dg-dev:amd64 (1.5+E-18.2) ... 正在处理用于 menu 的触发器...
二、下载emacs压缩包:
http://mirror.bjtu.edu.cn/gnu/emacs/emacs-24.4.tar.gz
三、解压
$ cd ~/Download $ tar zxvf emacs-24.4.tar.gz # 解压后有194M。
四、编译安装
$ mkdir compileemacs # 放置编译后生成的文件 $ cd compileemacs $ ../emacs-24.4/configure --prefix=/opt/emacs24 $ make $ sudo make install