Etienne Carriere df620dae43 Fix build warning related to DTLS connect ID
Between mbedtls version 3.6.2 and 3.6.3, some header files inclusion
scheme have changed (P-R [1] and specifically [2]) leading to the build
warning shown below when building libmbedtls as a user TA library
in OP-TEE OS package [3]:

In file included from lib/libmbedtls/mbedtls/library/ssl_misc.h:18,
                 from lib/libmbedtls/mbedtls/library/ssl_debug_helpers_generated.c:14:
lib/libmbedtls/mbedtls/include/mbedtls/ssl.h:659:5: warning: "MBEDTLS_SSL_DTLS_CONNECTION_ID_COMPAT" is not defined, evaluates to 0 [-Wundef]
  659 | #if MBEDTLS_SSL_DTLS_CONNECTION_ID_COMPAT == 0
      |     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Fix this by considering MBEDTLS_SSL_DTLS_CONNECTION_ID_COMPAT only
when MBEDTLS_SSL_DTLS_CONNECTION_ID is defined. The build warning is
related to the definition of MBEDTLS_TLS_EXT_CID that is meaningful only
when MBEDTLS_SSL_DTLS_CONNECTION_ID is defined which is relevant only
when MBEDTLS_SSL_DTLS_CONNECTION_ID_COMPAT is defined.

Fixes #10207.

Link: https://github.com/Mbed-TLS/mbedtls/pull/9671 [1]
Link: b81cd1af64 [2]
Link: https://github.com/OP-TEE/optee_os/pull/7337 [3]
Signed-off-by: Etienne Carriere <etienne.carriere@foss.st.com>
2025-06-05 10:42:36 +02:00
..
mbedtls Fix build warning related to DTLS connect ID 2025-06-05 10:42:36 +02:00
psa crypto_extra: improve description of psa_can_do_hash() 2025-02-21 15:01:04 +01:00
.gitignore Rename include directory to mbedtls 2015-03-10 11:23:56 +00:00
CMakeLists.txt Update spelling "mbed TLS" to "Mbed TLS" 2023-09-12 19:18:17 +02:00