From 77dd25d98fc5c42b4aafe11ad4e067085509e603 Mon Sep 17 00:00:00 2001 From: Jaeden Amero Date: Thu, 20 Jun 2019 17:17:48 +0100 Subject: [PATCH] tests: Enable building with add_subdirectory() When building Mbed Crypto when including it via CMake's `add_subdirectory()`, the tests are also built by default. This means all headers the tests need must be public, in order for the build of the tests to have access to the headers. --- tests/CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt index 9dc190816d..fd48a227ef 100644 --- a/tests/CMakeLists.txt +++ b/tests/CMakeLists.txt @@ -52,7 +52,7 @@ function(add_test_suite suite_name) target_include_directories(${exe_name} PUBLIC ${MBEDTLS_DIR}/include/ PUBLIC ${MBEDTLS_DIR}/crypto/include/ - PRIVATE ${MBEDTLS_DIR}/crypto/library/) + PUBLIC ${MBEDTLS_DIR}/crypto/library/) if(${data_name} MATCHES ${SKIP_TEST_SUITES_REGEX}) message(STATUS "The test suite ${data_name} will not be executed.")