From 0ce77c227bc786333173573613dc0158503cadb9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anders=20Storr=C3=B8?= Date: Thu, 12 Oct 2023 14:29:00 +0200 Subject: [PATCH] Bluetooth: Host: CMake dependency for Mesh Bsim MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Links host to mbedTLS library if Bluetooth Mesh is enabled, and CONFIG_BT_TESTING=y. Bluetooth Mesh has test dependencies in the host. In order to compile Bsim tests with these test features and PSA enabled, the libraries must be linked. Signed-off-by: Anders Storrø --- subsys/bluetooth/host/CMakeLists.txt | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/subsys/bluetooth/host/CMakeLists.txt b/subsys/bluetooth/host/CMakeLists.txt index a9810c8af32..e5ac8c707e0 100644 --- a/subsys/bluetooth/host/CMakeLists.txt +++ b/subsys/bluetooth/host/CMakeLists.txt @@ -123,3 +123,10 @@ if(CONFIG_BT_CONN_DISABLE_SECURITY) Do not use in production." ) endif() + +# Bluetooth Mesh has test dependencies in the host. +# In order to compile Bsim tests with these test features +# and PSA enabled, the libraries must be linked. +if(CONFIG_BT_MESH AND CONFIG_BT_TESTING) + zephyr_library_link_libraries_ifdef(CONFIG_MBEDTLS mbedTLS) +endif()