Bence Szépkúti | 90b79ab | 2021-06-04 00:19:53 +0200 | [diff] [blame^] | 1 | Introduce a level of indirection and versioning in the config files |
| 2 | ------------------------------------------------------------------- |
| 3 | |
| 4 | `config.h` was split into `build_info.h` and `mbedtls_config.h`. |
| 5 | `build_info.h` is intended to be included from C code directly, while |
| 6 | `mbedtls_config.h` is intended to be edited by end users whishing to |
| 7 | change the build configuration, and should generally only be included from |
| 8 | `build_info.h`. This is because all the preprocessor logic has been moved |
| 9 | into `build_info.h`, including the handling of the `MBEDTLS_CONFIG_FILE` |
| 10 | macro. |
| 11 | |
| 12 | Mandatory version symbols were introduced for `MBEDTLS_CONFIG_FILE` and |
| 13 | `MBEDTLS_USER_CONFIG_FILE`, `MBEDTLS_CONFIG_VERSION` and |
| 14 | `MBEDTLS_USER_CONFIG_VERSION` respectively. Both config files should include |
| 15 | a definiton of their respective version symbol, with a value of `1` to be |
| 16 | considered valid. |