forked from clojure-emacs/cider
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[clojure-emacs#2120] fix TLS related errors in Travis CI
- Loading branch information
1 parent
c1a500d
commit f987511
Showing
3 changed files
with
87 additions
and
14 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
#!/bin/bash | ||
|
||
# Setup a newer gnutls-cli on Travis CI | ||
# We need this as long as the Travis workers are Ubuntu 14.04 | ||
# and the TLS cert chain on elpa.gnu.org is out-of-order | ||
|
||
set -x | ||
|
||
# adjust these versions as needed | ||
export NETTLE_VERSION=3.4 | ||
export GNUTLS_VERSION=3.5.16 | ||
|
||
export WORKDIR=${HOME}/local/ | ||
export LD_LIBRARY_PATH=${WORKDIR}/lib/ | ||
export PKG_CONFIG_PATH=${WORKDIR}/lib/pkgconfig/ | ||
|
||
# exit if the cache is valid and up-to-date | ||
if [ -f ${WORKDIR}/bin/gnutls-cli ] && \ | ||
[ -f ${WORKDIR}/nettle-${NETTLE_VERSION}.tar.gz ] && \ | ||
[ -f ${WORKDIR}/gnutls-${GNUTLS_VERSION}.tar.xz ] | ||
then | ||
exit 0 | ||
fi | ||
|
||
# delete cache and rebuild | ||
rm -rf $WORKDIR | ||
mkdir $WORKDIR | ||
cd $WORKDIR | ||
curl -O https://ftp.gnu.org/gnu/nettle/nettle-${NETTLE_VERSION}.tar.gz \ | ||
&& tar xfz nettle-${NETTLE_VERSION}.tar.gz \ | ||
&& cd nettle-${NETTLE_VERSION} \ | ||
&& ./configure --prefix=${WORKDIR} \ | ||
&& make -j4 install \ | ||
&& make distclean | ||
|
||
cd $WORKDIR | ||
curl -O https://www.gnupg.org/ftp/gcrypt/gnutls/v3.5/gnutls-${GNUTLS_VERSION}.tar.xz \ | ||
&& xz -d -k gnutls-${GNUTLS_VERSION}.tar.xz \ | ||
&& tar xf gnutls-${GNUTLS_VERSION}.tar \ | ||
&& cd gnutls-${GNUTLS_VERSION} \ | ||
&& ./configure --prefix=${WORKDIR} \ | ||
--with-included-libtasn1 \ | ||
--with-included-unistring \ | ||
--without-p11-kit \ | ||
&& make -j4 install \ | ||
&& make distclean |