Skip to content

Commit

Permalink
Fix GitHub download URL for newer versions (#70)
Browse files Browse the repository at this point in the history
  • Loading branch information
hoppjan authored Sep 13, 2024
1 parent c1a5ade commit 911f1b0
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions build-libssl.sh
Original file line number Diff line number Diff line change
Expand Up @@ -490,6 +490,13 @@ if [ ! -e ${OPENSSL_ARCHIVE_FILE_NAME} ]; then
# -s be silent, -f return non-zero exit status on failure, -I get header (do not download)
curl ${CURL_OPTIONS} -sfIL "${OPENSSL_ARCHIVE_URL}" > /dev/null
# If unsuccessful, use the GitHub URL for newer versions and try again.
if [ $? -ne 0 ]; then
OPENSSL_ARCHIVE_URL="https://github.com/openssl/openssl/releases/download/${OPENSSL_ARCHIVE_BASE_NAME}/${OPENSSL_ARCHIVE_FILE_NAME}"
curl ${CURL_OPTIONS} -sfIL "${OPENSSL_ARCHIVE_URL}" > /dev/null
fi
# If unsuccessful, update the URL for older versions and try again.
if [ $? -ne 0 ]; then
BRANCH=$(echo "${VERSION}" | grep -Eo '^[0-9]\.[0-9]\.[0-9]')
Expand Down

0 comments on commit 911f1b0

Please sign in to comment.