mirror of
https://github.com/NLnetLabs/unbound.git
synced 2025-12-20 23:00:56 -05:00
45 lines
911 B
Bash
45 lines
911 B
Bash
|
|
#!/usr/bin/env bash
|
||
|
|
|
||
|
|
echo "Downloading OpenSSL"
|
||
|
|
if ! curl -L -k -s -o openssl-1.1.1d.tar.gz https://www.openssl.org/source/openssl-1.1.1d.tar.gz;
|
||
|
|
then
|
||
|
|
echo "Failed to download OpenSSL"
|
||
|
|
exit 1
|
||
|
|
fi
|
||
|
|
|
||
|
|
echo "Unpacking OpenSSL"
|
||
|
|
rm -rf ./openssl-1.1.1d
|
||
|
|
if ! tar -xf openssl-1.1.1d.tar.gz;
|
||
|
|
then
|
||
|
|
echo "Failed to unpack OpenSSL"
|
||
|
|
exit 1
|
||
|
|
fi
|
||
|
|
|
||
|
|
cd openssl-1.1.1d || exit 1
|
||
|
|
|
||
|
|
if ! cp ../contrib/ios/15-ios.conf Configurations/; then
|
||
|
|
echo "Failed to copy OpenSSL ios config"
|
||
|
|
exit 1
|
||
|
|
fi
|
||
|
|
|
||
|
|
echo "Configuring OpenSSL"
|
||
|
|
if ! ./Configure "$OPENSSL_HOST" no-comp no-asm no-hw no-engine \
|
||
|
|
"$CFLAGS" --prefix="$IOS_PREFIX" --openssldir="$IOS_PREFIX"; then
|
||
|
|
echo "Failed to configure OpenSSL"
|
||
|
|
exit 1
|
||
|
|
fi
|
||
|
|
|
||
|
|
echo "Building OpenSSL"
|
||
|
|
if ! make; then
|
||
|
|
echo "Failed to build OpenSSL"
|
||
|
|
exit 1
|
||
|
|
fi
|
||
|
|
|
||
|
|
echo "Installing OpenSSL"
|
||
|
|
if ! make install_sw; then
|
||
|
|
echo "Failed to install OpenSSL"
|
||
|
|
exit 1
|
||
|
|
fi
|
||
|
|
|
||
|
|
exit 0
|