Building project that uses mbedTLS backend (AES & AEAD) with nRF5-cmake-scripts CMake scripts

If you clone nRF5-cmake-scripts, then switch it to the archive/sdk-16 it builds if you follow the build instructions.

What I'm wanting to do is adding the mbedTLS backend so it is also built.  

I know I have to use a combination of:

nRF5_addMBED
nRF5_includeMBEDTLS
nRF5_addCryptoBackend
That is defined in libraries.cmake however I'm not sure how to use them in my CMakeLists.txt file.  Since I want to use both AES and AEAD, I should be using:
nRF5_addCryptoBackend(aes mbedtls)
nRF5_addCryptoBackend(aead mbedtls)
However when I build I get:
C:/my_project/toolchains/nRF5/nRF5_SDK_16.0.0_98a08e2/components/libraries/crypto/backend/mbedtls/mbedtls_backend_init.c:51:10: fatal error: mbedtls/platform.h: No such file or directory
#include "mbedtls/platform.h"
^~~~~~~~~~~~~~~~~~~~
compilation terminated.
That would mean the include directories and source for the mbedTLS library is not included.  This would also mean I need to define my own "nrf_crypto_mbedtls_config.h" somewhere.
How can I build my project, including the mbedTLS backend?  Any help is greatly appreciated.
Parents Reply Children
No Data
Related