Last active
November 1, 2023 13:18
-
-
Save tmiz/1441111 to your computer and use it in GitHub Desktop.
Build latest OpenSSL Universal Binary on OSX
This file contains hidden or 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
#!/bin/bash | |
OPENSSL_VERSION="1.0.1g" | |
curl -O http://www.openssl.org/source/openssl-$OPENSSL_VERSION.tar.gz | |
tar -xvzf openssl-$OPENSSL_VERSION.tar.gz | |
mv openssl-$OPENSSL_VERSION openssl_i386 | |
tar -xvzf openssl-$OPENSSL_VERSION.tar.gz | |
mv openssl-$OPENSSL_VERSION openssl_x86_64 | |
cd openssl_i386 | |
./Configure darwin-i386-cc -shared | |
make | |
cd ../ | |
cd openssl_x86_64 | |
./Configure darwin64-x86_64-cc -shared | |
make | |
cd ../ | |
lipo -create openssl_i386/libcrypto.1.0.0.dylib openssl_x86_64/libcrypto.1.0.0.dylib -output libcrypto.1.0.0.dylib | |
lipo -create openssl_i386/libssl.1.0.0.dylib openssl_x86_64/libssl.1.0.0.dylib -output libssl.1.0.0.dylib | |
rm openssl-$OPENSSL_VERSION.tar.gz |
Thanks!
You may want to modify your curl request to curl -O -L http://www.openssl.org/source/openssl-$OPENSSL_VERSION.tar.gz
. I had to struggle with a redirect -L automatically follows...
FYI as of the time of writing this the current openssl version is openssl-1.0.2o
Although very old, I wonder if this could still work for Mac OS X 10.4 on PPC with openssl 1.1.1
change http with https :) curl -O https://www.openssl.org/source/openssl-$OPENSSL_VERSION.tar.gz
Very useful!
I tried compiling this library for deploying applications built with Delphi for OSX64, but nothing worked. But this script runs perfectly!
Total respect!!
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This is brilliant