I want to use Emacs 28.1 on aging OS that I mustn't modify /usr. I tried Docker but I want to use local command too. SBCL didn't work properly on old Docker. So I install Emacs from a source tarball to my home directory.
However, Emacs failed to verify TLS certs. So I installed GNUTLS, Nettle, Idn, and Unistring.
#!/bin/bash
export PKG_CONFIG_PATH=$HOME/lib64/pkgconfig:$HOME/lib/pkgconfig
export LD_RUN_PATH=$HOME/lib:$HOME/lib64
export LD_LIBRARY_PATH=$HOME/lib:$HOME/lib64
export LDFLAGS="-L$HOME/lib -L$HOME/lib64"
rm -rf libunistring-1.0 libidn2-2.3.2 nettle-3.6 gmp-6.2.1 emacs-28.1
curl https://ftp.gnu.org/gnu/libunistring/libunistring-1.0.tar.gz | tar -xzvf - && \
pushd libunistring-1.0 && \
./configure --prefix=$HOME && \
make -j `nproc` && \
make install && \
popd || exit 1
curl https://ftp.gnu.org/gnu/libidn/libidn2-2.3.2.tar.gz | tar -xzvf - && \
pushd libidn2-2.3.2 && \
./configure --prefix=$HOME && \
make -j `nproc` && \
make install && \
popd || exit 1
curl https://ftp.gnu.org/gnu/nettle/nettle-3.6.tar.gz | tar xzvf - && \
pushd nettle-3.6 && \
./configure --prefix=$HOME --enable-mini-gmp && \
make -j `nproc` && \
make install && \
popd || exit 1
curl https://www.gnupg.org/ftp/gcrypt/gnutls/v3.7/gnutls-3.7.6.tar.xz | tar xJvf - && \
pushd gnutls-3.7.6 && \
./configure --prefix=$HOME && \
make -j `nproc` && \
make install && \
cd .. || exit 1
curl http://ftp.gnu.org/pub/gnu/emacs/emacs-28.1.tar.gz | tar -xzvf - &&
pushd emacs-28.1 && \
./configure --prefix=$HOME --with-x-toolkit=no --with-xpm=no --with-jpeg=no --with-jpeg=no --with-gif=no --with-tiff=no --with-png=no && \
make -j `nproc` && \
make install && \
cd .. || exit 1
echo
echo
echo "Emacs 28.1 must be ready!"
echo
Top comments (0)