CMake: support "make ssl-opt" to just build what ssl-opt.sh needs

This also suffices for compat.sh.

Include the sample programs in this build. They aren't tested by ssl-opt.sh
yet, but they soon will be.

Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
This commit is contained in:
Gilles Peskine 2024-09-14 12:18:00 +02:00
parent 5dab92ee4e
commit b63064854b
3 changed files with 6 additions and 0 deletions

View File

@ -1,6 +1,9 @@
set(programs_target "${MBEDTLS_TARGET_PREFIX}programs")
add_custom_target(${programs_target})
set(ssl_opt_target "${MBEDTLS_TARGET_PREFIX}ssl-opt")
add_custom_target(${ssl_opt_target})
add_subdirectory(aes)
add_subdirectory(cipher)
if (NOT WIN32)

View File

@ -17,6 +17,7 @@ set(executables
ssl_server2
)
add_dependencies(${programs_target} ${executables})
add_dependencies(${ssl_opt_target} ${executables})
if(GEN_FILES)
# Inform CMake that the following file will be generated as part of the build

View File

@ -9,6 +9,7 @@ set(executables_libs
udp_proxy
)
add_dependencies(${programs_target} ${executables_libs})
add_dependencies(${ssl_opt_target} udp_proxy)
set(executables_mbedcrypto
benchmark
@ -16,6 +17,7 @@ set(executables_mbedcrypto
zeroize
)
add_dependencies(${programs_target} ${executables_mbedcrypto})
add_dependencies(${ssl_opt_target} query_compile_time_config)
if(TEST_CPP)
set(cpp_dummy_build_cpp "${CMAKE_CURRENT_BINARY_DIR}/cpp_dummy_build.cpp")