Skip to content

Commit

Permalink
chore: bump osx Openssl to latest (#5041)
Browse files Browse the repository at this point in the history
Signed-off-by: Rui Chen <[email protected]>
Co-authored-by: Rui Chen <[email protected]>
  • Loading branch information
dougch and chenrui333 authored Jan 17, 2025
1 parent e6de32a commit 431f014
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 7 deletions.
2 changes: 1 addition & 1 deletion .github/install_osx_dependencies.sh
Original file line number Diff line number Diff line change
Expand Up @@ -26,4 +26,4 @@ brew_install_if_not_installed coreutils
brew_install_if_not_installed cppcheck
brew_install_if_not_installed pkg-config # for gnutls compilation
brew_install_if_not_installed ninja
brew_install_if_not_installed openssl@1.1 # for libcrypto
brew_install_if_not_installed openssl@3 # for libcrypto
12 changes: 6 additions & 6 deletions .github/s2n_osx.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,25 +14,25 @@
# permissions and limitations under the License.
#
set -eu
source codebuild/bin/s2n_setup_env.sh

export S2N_LIBCRYPTO=openssl-3.4
export CTEST_OUTPUT_ON_FAILURE=1
BREWINSTLLPATH=$(brew --prefix openssl@1.1)
OPENSSL_1_1_1_INSTALL_DIR="${BREWINSTLLPATH:-"/usr/local/Cellar/openssl@1.1/1.1.1?"}"
BREWINSTLLPATH=$(brew --prefix openssl@3)
OPENSSL_3_INSTALL_DIR="${BREWINSTLLPATH:-"/opt/homebrew/Cellar/openssl@3"}"

echo "Using OpenSSL at $OPENSSL_1_1_1_INSTALL_DIR"
echo "Using OpenSSL at $OPENSSL_3_INSTALL_DIR"
# Build with debug symbols and a specific OpenSSL version
cmake . -Bbuild -GNinja \
-DCMAKE_BUILD_TYPE=Debug \
-DCMAKE_PREFIX_PATH=${OPENSSL_1_1_1_INSTALL_DIR} ..
-DCMAKE_PREFIX_PATH=${OPENSSL_3_INSTALL_DIR} ..

cmake --build ./build -j $(nproc)
time CTEST_PARALLEL_LEVEL=$(nproc) ninja -C build test

# Build shared library
cmake . -Bbuild -GNinja \
-DCMAKE_BUILD_TYPE=Debug \
-DCMAKE_PREFIX_PATH=${OPENSSL_1_1_1_INSTALL_DIR} .. \
-DCMAKE_PREFIX_PATH=${OPENSSL_3_INSTALL_DIR} .. \
-DBUILD_SHARED_LIBS=ON

cmake --build ./build -j $(nproc)
Expand Down
1 change: 1 addition & 0 deletions tests/unit/s2n_build_test.c
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,7 @@ S2N_RESULT s2n_check_supported_libcrypto(const char *s2n_libcrypto)
{ .libcrypto = "openssl-1.0.2", .is_openssl = true },
{ .libcrypto = "openssl-1.1.1", .is_openssl = true },
{ .libcrypto = "openssl-3.0", .is_openssl = true },
{ .libcrypto = "openssl-3.4", .is_openssl = true },
};

for (size_t i = 0; i < s2n_array_len(supported_libcrypto); i++) {
Expand Down

0 comments on commit 431f014

Please sign in to comment.