summaryrefslogtreecommitdiff
path: root/.github
diff options
context:
space:
mode:
authorDarren Tucker <dtucker@dtucker.net>2023-03-26 14:22:53 +1100
committerDarren Tucker <dtucker@dtucker.net>2023-03-26 14:22:53 +1100
commitb308c636f5b5d89eecb98be00b3d56306a005a09 (patch)
tree2d8dac30612acb8a6c819c6620893111252d4100 /.github
parent021ea5c2860f133f44790970968e0e73208b3a87 (diff)
downloadopenssh-git-b308c636f5b5d89eecb98be00b3d56306a005a09.tar.gz
Find suitable OpenSSL version.
Check the installed OpenSSL versions for a suitable one, and if there isn't (and we don't have a specific version configured) then build without OpenSSL.
Diffstat (limited to '.github')
-rwxr-xr-x.github/configs15
1 files changed, 12 insertions, 3 deletions
diff --git a/.github/configs b/.github/configs
index eb91732c..cf1988d7 100755
--- a/.github/configs
+++ b/.github/configs
@@ -296,13 +296,22 @@ case "`./config.guess`" in
;;
esac
-# If we have a local openssl/libressl, use that.
+# Unless specifically configured, search for a suitable version of OpenSSL,
+# otherwise build without it.
if [ -z "${LIBCRYPTOFLAGS}" ]; then
+ LIBCRYPTOFLAGS="--without-openssl"
# last-match
- for i in /usr/local /usr/local/ssl /usr/local/opt/openssl; do
+ for i in /usr /usr/local /usr/local/ssl /usr/local/opt/openssl; do
+ ver="none"
if [ -x ${i}/bin/openssl ]; then
- LIBCRYPTOFLAGS="--with-ssl-dir=${i}"
+ ver="$(${i}/bin/openssl version)"
fi
+ case "$ver" in
+ none) ;;
+ "OpenSSL 0."*|"OpenSSL 1.0."*|"OpenSSL 1.1.0"*) ;;
+ "LibreSSL 2."*|"LibreSSL 3.0."*) ;;
+ *) LIBCRYPTOFLAGS="--with-ssl-dir=${i}" ;;
+ esac
done
fi