Skip to content
0.2.0-dev Download ZIP
40 lines ·1.5 KB Raw
1/*
2 * Mbed TLS configuration checks
3 */
4/*
5 * Copyright The Mbed TLS Contributors
6 * SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later
7 */
8
9#include "mbedtls_platform_requirements.h"
10
11/* We are a special snowflake: we don't include "mbedtls_common.h",
12 * because that would pull <mbedtls/build_info.h> and we need to
13 * tune the way it works. */
14
15/* Apply the TF-PSA-Crypto configuration first. We need to do this
16 * before <mbedtls/build_info.h>, because "mbedtls_config_check_before.h"
17 * needs to run after the crypto config (including derived macros) is
18 * finalized, but before the user's mbedtls config is applied. This way
19 * it is possible to differentiate macros set by the user's mbedtls config
20 * from macros set or derived by the crypto config. */
21#include <tf-psa-crypto/build_info.h>
22
23/* Consistency checks on the user's configuration.
24 * Check that it doesn't define macros that we assume are under full
25 * control of the library, or options from past major versions that
26 * no longer have any effect.
27 * These headers are automatically generated. See
28 * framework/scripts/mbedtls_framework/config_checks_generator.py
29 */
30#include "mbedtls_config_check_before.h"
31#define MBEDTLS_INCLUDE_AFTER_RAW_CONFIG "mbedtls_config_check_user.h"
32
33#include <mbedtls/build_info.h>
34
35/* Consistency checks in the configuration: check for incompatible options,
36 * missing options when at least one of a set needs to be enabled, etc. */
37/* Manually written checks */
38#include "mbedtls_check_config.h"
39/* Automatically generated checks */
40#include "mbedtls_config_check_final.h"