From a13962084f8d13a1b31fa4247d27adc3b450bd17 Mon Sep 17 00:00:00 2001 From: Gordon Tetlow Date: Thu, 20 Jun 2024 20:11:31 -0700 Subject: [PATCH] Unify configuration for OpenSSL. MacOS isn't special and can properly build with the same arguments as the "normal" build path. While we are at it, go ahead and use Configure, which is the documented way to invoke the OpenSSL build system (./config just calls Configure). Tested on: MacOS (arm64), FreeBSD (amd64, arm64), Ubuntu (aarch64) --- Makefile | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) diff --git a/Makefile b/Makefile index c731a9a..faed6e2 100644 --- a/Makefile +++ b/Makefile @@ -146,20 +146,8 @@ opensslpull: git clone --depth 1 -b `git ls-remote https://github.com/openssl/openssl | grep -Eo '(openssl-3\.0\.[0-9]+)' | sort -V | tail -n 1` https://github.com/openssl/openssl ./openssl && cd ./openssl && touch ../.openssl.is.fresh ; \ fi -# Need to build OpenSSL differently on OSX -ifeq ($(OS), Darwin) -ifeq ($(ARCH), arm64) -OSSL_TARGET=darwin64-arm64-cc -else -OSSL_TARGET=darwin64-x86_64-cc -endif openssl/Makefile: .openssl.is.fresh - cd ./openssl; ./Configure -fstack-protector-all -D_FORTIFY_SOURCE=2 -fPIC enable-weak-ssl-ciphers zlib $(OSSL_TARGET) -# Any other *NIX platform -else -openssl/Makefile: .openssl.is.fresh - cd ./openssl; ./config -v -fstack-protector-all -D_FORTIFY_SOURCE=2 -fPIC no-shared enable-weak-ssl-ciphers zlib -endif + cd ./openssl; ./Configure -v -fstack-protector-all -D_FORTIFY_SOURCE=2 -fPIC no-shared enable-weak-ssl-ciphers zlib openssl/libcrypto.a: openssl/Makefile $(MAKE) -j $(NUM_PROCS) -C openssl depend