Disable test hooks when checking missing symbols
The function mbedtls_test_hook_error_add() is declared in the library
but supplied by test helpers in framework/tests/src, so it is undefined
in library-only builds. This messes up our checks for missing symbols,
so disable MBEDTLS_TEST_HOOKS when we are building to check missing
symbols.
Signed-off-by: David Horstmann <david.horstmann@arm.com>
diff --git a/tests/scripts/components-configuration-crypto.sh b/tests/scripts/components-configuration-crypto.sh
index 9143665..e3096f3 100644
--- a/tests/scripts/components-configuration-crypto.sh
+++ b/tests/scripts/components-configuration-crypto.sh
@@ -160,6 +160,9 @@
scripts/config.py unset MBEDTLS_SSL_PROTO_TLS1_3
scripts/config.py set MBEDTLS_PSA_CRYPTO_CLIENT
scripts/config.py unset MBEDTLS_LMS_C
+ # Test hooks may rely on functions defined in test helpers, which would
+ # not be built here, leading to a spurious undefined symbol.
+ scripts/config.py unset MBEDTLS_TEST_HOOKS
make
@@ -181,6 +184,9 @@
# Dynamic secure element support is a deprecated feature and it is not
# available when CRYPTO_C and PSA_CRYPTO_STORAGE_C are disabled.
scripts/config.py unset MBEDTLS_PSA_CRYPTO_SE_C
+ # Test hooks may rely on functions defined in test helpers, which would
+ # not be built here, leading to a spurious undefined symbol.
+ scripts/config.py unset MBEDTLS_TEST_HOOKS
# Since there is no crypto provider in this build it is not possible to
# build all the test executables and progrems due to missing PSA functions