diff --git a/CMakeLists.txt b/CMakeLists.txt index b1af5667dc..f05e1e3694 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -403,6 +403,9 @@ if(ENABLE_TESTING OR ENABLE_PROGRAMS) endif() if(ENABLE_PROGRAMS) + set(ssl_opt_target "${MBEDTLS_TARGET_PREFIX}ssl-opt") + add_custom_target(${ssl_opt_target}) + add_subdirectory(programs) endif() diff --git a/programs/CMakeLists.txt b/programs/CMakeLists.txt index e031544a9c..aaf93ba38d 100644 --- a/programs/CMakeLists.txt +++ b/programs/CMakeLists.txt @@ -1,9 +1,6 @@ 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) diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt index 84dcb7b623..4a42efe1f2 100644 --- a/tests/CMakeLists.txt +++ b/tests/CMakeLists.txt @@ -78,6 +78,7 @@ if(GEN_FILES) add_custom_target(tls13-compat.sh DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/opt-testcases/tls13-compat.sh) set_target_properties(tls13-compat.sh PROPERTIES EXCLUDE_FROM_ALL NO) + add_dependencies(${ssl_opt_target} tls13-compat.sh) else() foreach(file ${all_generated_data_files})