Skip to content

Commit

Permalink
CI: ssl: add git id support for wolfssl download
Browse files Browse the repository at this point in the history
Allow to download a git revision directly with the git ID.

WOLFSSL_VERSION=git-d83f2fa ./scripts/build-ssl.sh
  • Loading branch information
wlallemand committed Oct 10, 2023
1 parent cfd72eb commit 0be50f4
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions scripts/build-ssl.sh
Original file line number Diff line number Diff line change
Expand Up @@ -125,16 +125,22 @@ download_quictls () {
download_wolfssl () {
if [ ! -f "download-cache/wolfssl-${WOLFSSL_VERSION}.tar.gz" ]; then
mkdir -p download-cache
if [ "${WOLFSSL_VERSION%%-*}" != "git" ]; then
wget -q -O "download-cache/wolfssl-${WOLFSSL_VERSION}.tar.gz" \
"https://github.com/wolfSSL/wolfssl/archive/refs/tags/v${WOLFSSL_VERSION}-stable.tar.gz"
"https://github.com/wolfSSL/wolfssl/archive/refs/tags/v${WOLFSSL_VERSION}-stable.tar.gz"
else
wget -q -O "download-cache/wolfssl-${WOLFSSL_VERSION}.tar.gz" \
"https://github.com/wolfSSL/wolfssl/archive/${WOLFSSL_VERSION##git-}.tar.gz"
fi
fi
}

build_wolfssl () {
if [ "$(cat ${HOME}/opt/.wolfssl-version)" != "${WOLFSSL_VERSION}" ]; then
tar zxf "download-cache/wolfssl-${WOLFSSL_VERSION}.tar.gz"
mkdir "wolfssl-${WOLFSSL_VERSION}/"
tar zxf "download-cache/wolfssl-${WOLFSSL_VERSION}.tar.gz" -C "wolfssl-${WOLFSSL_VERSION}/" --strip-components=1
(
cd "wolfssl-${WOLFSSL_VERSION}-stable/"
cd "wolfssl-${WOLFSSL_VERSION}/"
autoreconf -i
./configure --enable-haproxy --enable-quic --prefix="${HOME}/opt"
make -j$(nproc)
Expand Down

0 comments on commit 0be50f4

Please sign in to comment.