问题
I am trying to install Emacs v. 26.1. When I run ./configure
, I see the following error:
configure: error: The following required libraries were not found:
libXpm libjpeg libgif/libungif libtiff gnutls
Maybe some development libraries/packages are missing?
However, they seem to be already there. I tried multiple things, such as:
: ~$ apt-cache search gnutls
gnutls-doc - GNU TLS library - documentation and examples
libcurl3-gnutls - easy-to-use client-side URL transfer library (GnuTLS flavour)
libcurl4-gnutls-dev - development files and documentation for libcurl (GnuTLS flavour)
libgnutls-openssl27 - GNU TLS library - OpenSSL wrapper
and
:~$ sudo apt install libcurl4-gnutls-dev
Reading package lists... Done
Building dependency tree
Reading state information... Done
libcurl4-gnutls-dev is already the newest version (7.58.0-2ubuntu3.6).
0 to upgrade, 0 to newly install, 0 to remove and 11 not to upgrade.
Things seem fine. What am I missing?
回答1:
For completeness,
# Install essential build tools
sudo apt-get install build-essential
Second, download Emacs dependencies:
# Get all dependencies of a previous Emacs version
sudo apt-get build-dep emacs24
./configure
make
回答2:
As stated in the error message, you actually need the development version of these libraries (tested with Emacs v. 27 on Ubuntu 19.10 (Eoan Ermine)):
sudo apt install libxpm-dev libjpeg-dev libgif-dev libtiff-dev libgnutls28-dev
回答3:
I ended up doing:
sudo add-apt-repository ppa:kelleyk/emacs
sudo apt-get update
sudo apt install emacs26
来源:https://stackoverflow.com/questions/55297581/build-emacs-on-ubuntu-libraries-not-found