mirror of https://github.com/ARMmbed/mbed-os.git
Merge pull request #2926 from andresag01/iotssl-1017-mbedtls_user_config-null_entopy
Fix mbedtls user config and null entropypull/2963/head
commit
7e292fb9b7
|
@ -37,23 +37,28 @@ add_code() {
|
|||
|
||||
# add an #ifndef to include config-no-entropy.h when the target does not have
|
||||
# an entropy source we can use.
|
||||
add_code \
|
||||
"#ifndef MBEDTLS_CONFIG_H\n" \
|
||||
"\n" \
|
||||
"#include \"platform\/inc\/platform_mbed.h\"\n" \
|
||||
"\n" \
|
||||
"\/*\n" \
|
||||
" * Only use features that do not require an entropy source when\n" \
|
||||
" * DEVICE_ENTROPY_SOURCE is not defined in mbed OS.\n" \
|
||||
" *\/\n" \
|
||||
"#if !defined(MBEDTLS_ENTROPY_HARDWARE_ALT)\n" \
|
||||
"#include \"mbedtls\/config-no-entropy.h\"\n" \
|
||||
add_code \
|
||||
"#ifndef MBEDTLS_CONFIG_H\n" \
|
||||
"\n" \
|
||||
"#include \"platform\/inc\/platform_mbed.h\"\n" \
|
||||
"\n" \
|
||||
"\/*\n" \
|
||||
" * Only use features that do not require an entropy source when\n" \
|
||||
" * DEVICE_ENTROPY_SOURCE is not defined in mbed OS.\n" \
|
||||
" *\/\n" \
|
||||
"#if !defined(MBEDTLS_ENTROPY_HARDWARE_ALT) && !defined(MBEDTLS_TEST_NULL_ENTROPY)\n" \
|
||||
"#include \"mbedtls\/config-no-entropy.h\"\n" \
|
||||
"\n" \
|
||||
"#if defined(MBEDTLS_USER_CONFIG_FILE)\n" \
|
||||
"#include MBEDTLS_USER_CONFIG_FILE\n" \
|
||||
"#endif\n" \
|
||||
"\n" \
|
||||
"#else\n"
|
||||
|
||||
add_code \
|
||||
"#include \"check_config.h\"\n" \
|
||||
"\n" \
|
||||
"#endif \/* !MBEDTLS_ENTROPY_HARDWARE_ALT *\/"
|
||||
add_code \
|
||||
"#include \"check_config.h\"\n" \
|
||||
"\n" \
|
||||
"#endif \/* !MBEDTLS_ENTROPY_HARDWARE_ALT && !MBEDTLS_TEST_NULL_ENTROPY *\/"
|
||||
|
||||
# not supported on mbed OS, nor used by mbed Client
|
||||
conf unset MBEDTLS_NET_C
|
||||
|
|
Loading…
Reference in New Issue