Add custom config logic to 3rdparty modules
These do not link directly against Mbed TLS so need their own propagation of the custom config values through CMake. Signed-off-by: David Horstmann <david.horstmann@arm.com>
This commit is contained in:
parent
53307b794d
commit
bf66b752b4
2 changed files with 26 additions and 0 deletions
13
3rdparty/everest/CMakeLists.txt
vendored
13
3rdparty/everest/CMakeLists.txt
vendored
|
@ -11,6 +11,19 @@ target_include_directories(everest
|
|||
include/everest/kremlib
|
||||
${MBEDTLS_DIR}/library/)
|
||||
|
||||
# Pass-through MBEDTLS_CONFIG_FILE and MBEDTLS_USER_CONFIG_FILE
|
||||
# This must be duplicated from library/CMakeLists.txt because
|
||||
# everest is not directly linked against any mbedtls targets
|
||||
# so does not inherit the compile definitions.
|
||||
if(MBEDTLS_CONFIG_FILE)
|
||||
target_compile_definitions(everest
|
||||
PUBLIC MBEDTLS_CONFIG_FILE="${MBEDTLS_CONFIG_FILE}")
|
||||
endif()
|
||||
if(MBEDTLS_USER_CONFIG_FILE)
|
||||
target_compile_definitions(everest
|
||||
PUBLIC MBEDTLS_USER_CONFIG_FILE="${MBEDTLS_USER_CONFIG_FILE}")
|
||||
endif()
|
||||
|
||||
if(INSTALL_MBEDTLS_HEADERS)
|
||||
|
||||
install(DIRECTORY include/everest
|
||||
|
|
13
3rdparty/p256-m/CMakeLists.txt
vendored
13
3rdparty/p256-m/CMakeLists.txt
vendored
|
@ -9,6 +9,19 @@ target_include_directories(p256m
|
|||
$<INSTALL_INTERFACE:include>
|
||||
PRIVATE ${MBEDTLS_DIR}/library/)
|
||||
|
||||
# Pass-through MBEDTLS_CONFIG_FILE and MBEDTLS_USER_CONFIG_FILE
|
||||
# This must be duplicated from library/CMakeLists.txt because
|
||||
# p256m is not directly linked against any mbedtls targets
|
||||
# so does not inherit the compile definitions.
|
||||
if(MBEDTLS_CONFIG_FILE)
|
||||
target_compile_definitions(p256m
|
||||
PUBLIC MBEDTLS_CONFIG_FILE="${MBEDTLS_CONFIG_FILE}")
|
||||
endif()
|
||||
if(MBEDTLS_USER_CONFIG_FILE)
|
||||
target_compile_definitions(p256m
|
||||
PUBLIC MBEDTLS_USER_CONFIG_FILE="${MBEDTLS_USER_CONFIG_FILE}")
|
||||
endif()
|
||||
|
||||
if(INSTALL_MBEDTLS_HEADERS)
|
||||
|
||||
install(DIRECTORY :${CMAKE_CURRENT_SOURCE_DIR}
|
||||
|
|
Loading…
Reference in a new issue