modules: mbedtls: force NS-side config to client-only when using TF-M

When building with TF-M (CONFIG_BUILD_WITH_TFM),
force MBEDTLS_PSA_CRYPTO_CLIENT && !MBEDTLS_PSA_CRYPTO_C
so that no NS code tries to act like the MbedTLS core
is built on this side.

This fixes compilation errors in (at least)
interface/src/tfm_crypto_api.c after the
update of MbedTLS to 3.6.0.

Signed-off-by: Tomi Fontanilles <tomi.fontanilles@nordicsemi.no>
This commit is contained in:
Tomi Fontanilles 2024-04-16 15:03:17 +03:00 committed by Flavio Ceolin
commit 5416e76d3b

View file

@ -495,4 +495,9 @@
#include CONFIG_MBEDTLS_USER_CONFIG_FILE
#endif
#if defined(CONFIG_BUILD_WITH_TFM)
#define MBEDTLS_PSA_CRYPTO_CLIENT
#undef MBEDTLS_PSA_CRYPTO_C
#endif /* CONFIG_BUILD_WITH_TFM */
#endif /* MBEDTLS_CONFIG_H */