Skip to content

Commit

Permalink
Also update aws-lc-fips-sys CMakeLists.txt
Browse files Browse the repository at this point in the history
  • Loading branch information
justsmth committed Mar 10, 2025
1 parent 52c6518 commit 741f80b
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 4 deletions.
16 changes: 13 additions & 3 deletions .github/docker_images/cmake_build_versions/aws_lc_rs_build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,11 @@
set -ex -o pipefail

echo "Building with CMake Version: $(cmake --version)"
FIPS_BUILD=1
if cmake --version | grep -q " 4."; then
echo "CMake version is 4.x, skipping FIPS build"
FIPS_BUILD=0
fi

. "${HOME}/.cargo/env"
SRC_DIR="${SRC_DIR:-/aws_lc_rs}"
Expand All @@ -15,11 +20,16 @@ pushd "${SRC_DIR}"
cargo clean
cargo test -p aws-lc-rs --features=unstable
cargo clean
cargo test -p aws-lc-rs --features=unstable,fips
cargo clean
if [ ${FIPS_BUILD} -eq 1 ]; then
cargo test -p aws-lc-rs --features=unstable,fips
cargo clean
fi
cargo test -p aws-lc-rs --release --features=unstable
cargo clean
cargo test -p aws-lc-rs --release --features=unstable,fips
if [ ${FIPS_BUILD} -eq 1 ]; then
cargo test -p aws-lc-rs --release --features=unstable,fips
cargo clean
fi


popd # ${BUILD_DIR}
9 changes: 8 additions & 1 deletion aws-lc-fips-sys/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,7 +1,14 @@
# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
# SPDX-License-Identifier: Apache-2.0 OR ISC

cmake_minimum_required(VERSION 3.0)
cmake_minimum_required(VERSION 3.5...3.31)

if(CMAKE_VERSION VERSION_GREATER "3.14")
# https://cmake.org/cmake/help/latest/policy/CMP0091.html
# In CMake 3.14 and below, MSVC runtime library selection flags are added to the default CMAKE_<LANG>_FLAGS_<CONFIG>
# cache entries by CMake automatically.
cmake_policy(SET CMP0091 OLD)
endif()

project(AWS_LC_RUST NONE)
enable_language(C)
Expand Down

0 comments on commit 741f80b

Please sign in to comment.