emacs源码安装

1、源码下载地址=》下载

选择下载的版本,我下的是emacs-26.1.tar.xz 版本

2、解压

xz -d emacs-26.1.tar.xz  # 解压成tar文件
tar -xvf emacs-26.1.tar # 解压

3、编译安装

./configure --prefix=/opt/emacs/

如果出现以下错误:

checking for libXaw... configure: error: No X toolkit could be found.
If you are sure you want Emacs compiled without an X toolkit, pass
  --with-x-toolkit=no
to configure.  Otherwise, install the development libraries for the toolkit
that you want to use (e.g. Gtk+) and re-run configure.

解决方案:

安装依赖:

sudo apt-get install build-essential texinfo libx11-dev libxpm-dev libjpeg-dev libpng-dev libgif-dev libtiff-dev libgtk2.0-dev libgtk-3-dev libncurses-dev libxpm-dev automake autoconf

如果出现以下错误:

configure: error: The following required libraries were not found:
     gnutls
Maybe some development libraries/packages are missing?
If you don't want to link with them give
     --with-gnutls=no
as options to configure

解决方案:

sudo apt-get install gnutls-dev

如果出现以下警告:

configure: WARNING: This configuration installs a 'movemail' program
that does not retrieve POP3 email.  By default, Emacs 25 and earlier
installed a 'movemail' program that retrieved POP3 email via only
insecure channels, a practice that is no longer recommended but that
you can continue to support by using './configure --with-pop'.
configure: You might want to install GNU Mailutils
<https://mailutils.org> and use './configure --with-mailutils'.

解决方案:

./configure --prefix=/opt/emacs/ --with-mailutils --with-pop

最后:

make && make install

添加软连接

ln -s /opt/emacs/bin/emacs /usr/bin/emacs

出现上图说明安装成功了

 

转载于:https://www.cnblogs.com/felixwang2/p/10281092.html

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值