From a556abfaf893a7ea5699e0e0c1eb94b912d097d8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bence=20Sz=C3=A9pk=C3=BAti?= Date: Mon, 21 Jul 2025 16:39:02 +0200 Subject: [PATCH 1/2] Adapt to the renaming of common.h MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit common.h has been renamed to tf_psa_crypto_common.h in the standalone TF PSA Crypto library used in Mbed TLS 4. Signed-off-by: Bence Szépkúti --- tests/include/test/macros.h | 5 +++++ tests/programs/metatest.c | 1 - 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/tests/include/test/macros.h b/tests/include/test/macros.h index a73e06fca..59201eaa5 100644 --- a/tests/include/test/macros.h +++ b/tests/include/test/macros.h @@ -21,7 +21,12 @@ #if defined(MBEDTLS_MEMORY_BUFFER_ALLOC_C) #include "mbedtls/memory_buffer_alloc.h" #endif + +#if !defined(MBEDTLS_VERSION_MAJOR) || MBEDTLS_VERSION_MAJOR >= 4 +#include "tf_psa_crypto_common.h" +#else #include "common.h" +#endif /** * \brief This macro tests the expression passed to it as a test step or diff --git a/tests/programs/metatest.c b/tests/programs/metatest.c index f39cb545d..750ef20aa 100644 --- a/tests/programs/metatest.c +++ b/tests/programs/metatest.c @@ -34,7 +34,6 @@ #include "test/threading_helpers.h" #include "test/macros.h" #include "test/memory.h" -#include "common.h" #include #include From 6177e44e9c0440a35c5d83fc649666297383c60e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bence=20Sz=C3=A9pk=C3=BAti?= Date: Tue, 29 Jul 2025 10:28:26 +0200 Subject: [PATCH 2/2] Simplify version detection MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Bence Szépkúti --- tests/include/test/macros.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/include/test/macros.h b/tests/include/test/macros.h index 59201eaa5..544db916d 100644 --- a/tests/include/test/macros.h +++ b/tests/include/test/macros.h @@ -22,7 +22,7 @@ #include "mbedtls/memory_buffer_alloc.h" #endif -#if !defined(MBEDTLS_VERSION_MAJOR) || MBEDTLS_VERSION_MAJOR >= 4 +#if defined(TF_PSA_CRYPTO_VERSION_NUMBER) #include "tf_psa_crypto_common.h" #else #include "common.h"