mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-01-29 12:32:48 +00:00
Disable PSA wrappers psa_collect_statuses builds
`psa_collect_statuses.py` runs `make RECORD_PSA_STATUS_COVERAGE_LOG=1`, which builds with `RECORD_PSA_STATUS_COVERAGE_LOG`. In this mode, the build includes wrappers for PSA functions, which conflict with the newly introduced wrappers that are enabled whenever `MBEDTLS_TEST_HOOKS` is enabled. In the future, the collect-statuses mechanism should use the new generic wrapper mechanism. For the time being, keep the old wrappers and avoid the new wrappers when doing the collect-statuses build. Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
This commit is contained in:
parent
88385c2f74
commit
4411c9c1f8
@ -26,6 +26,10 @@ endif
|
||||
include ../3rdparty/Makefile.inc
|
||||
LOCAL_CFLAGS+=$(THIRDPARTY_INCLUDES)
|
||||
|
||||
ifdef RECORD_PSA_STATUS_COVERAGE_LOG
|
||||
LOCAL_CFLAGS += -Werror -DRECORD_PSA_STATUS_COVERAGE_LOG
|
||||
endif
|
||||
|
||||
ifndef SHARED
|
||||
MBEDLIBS=../library/libmbedcrypto.a ../library/libmbedx509.a ../library/libmbedtls.a
|
||||
else
|
||||
|
@ -13,7 +13,8 @@ extern "C" {
|
||||
|
||||
#include <mbedtls/build_info.h>
|
||||
|
||||
#if defined(MBEDTLS_PSA_CRYPTO_C) && defined(MBEDTLS_TEST_HOOKS)
|
||||
#if defined(MBEDTLS_PSA_CRYPTO_C) && defined(MBEDTLS_TEST_HOOKS) && \
|
||||
!defined(RECORD_PSA_STATUS_COVERAGE_LOG)
|
||||
|
||||
#include <psa/crypto.h>
|
||||
|
||||
@ -709,7 +710,8 @@ psa_status_t mbedtls_test_wrap_psa_verify_message(
|
||||
#define psa_verify_message(arg0_key, arg1_alg, arg2_input, arg3_input_length, arg4_signature, arg5_signature_length) \
|
||||
mbedtls_test_wrap_psa_verify_message(arg0_key, arg1_alg, arg2_input, arg3_input_length, arg4_signature, arg5_signature_length)
|
||||
|
||||
#endif /* defined(MBEDTLS_PSA_CRYPTO_C) && defined(MBEDTLS_TEST_HOOKS) */
|
||||
#endif /* defined(MBEDTLS_PSA_CRYPTO_C) && defined(MBEDTLS_TEST_HOOKS) && \
|
||||
!defined(RECORD_PSA_STATUS_COVERAGE_LOG) */
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
|
@ -45,7 +45,9 @@ class BufferParameter:
|
||||
class PSAWrapperGenerator(c_wrapper_generator.Base):
|
||||
"""Generate a C source file containing wrapper functions for PSA Crypto API calls."""
|
||||
|
||||
_CPP_GUARDS = 'defined(MBEDTLS_PSA_CRYPTO_C) && defined(MBEDTLS_TEST_HOOKS)'
|
||||
_CPP_GUARDS = ('defined(MBEDTLS_PSA_CRYPTO_C) && ' +
|
||||
'defined(MBEDTLS_TEST_HOOKS) && \\\n ' +
|
||||
'!defined(RECORD_PSA_STATUS_COVERAGE_LOG)')
|
||||
_WRAPPER_NAME_PREFIX = 'mbedtls_test_wrap_'
|
||||
_WRAPPER_NAME_SUFFIX = ''
|
||||
|
||||
|
@ -6,7 +6,8 @@
|
||||
|
||||
#include <mbedtls/build_info.h>
|
||||
|
||||
#if defined(MBEDTLS_PSA_CRYPTO_C) && defined(MBEDTLS_TEST_HOOKS)
|
||||
#if defined(MBEDTLS_PSA_CRYPTO_C) && defined(MBEDTLS_TEST_HOOKS) && \
|
||||
!defined(RECORD_PSA_STATUS_COVERAGE_LOG)
|
||||
|
||||
#include <psa/crypto.h>
|
||||
|
||||
@ -977,6 +978,7 @@ psa_status_t mbedtls_test_wrap_psa_verify_message(
|
||||
return status;
|
||||
}
|
||||
|
||||
#endif /* defined(MBEDTLS_PSA_CRYPTO_C) && defined(MBEDTLS_TEST_HOOKS) */
|
||||
#endif /* defined(MBEDTLS_PSA_CRYPTO_C) && defined(MBEDTLS_TEST_HOOKS) && \
|
||||
!defined(RECORD_PSA_STATUS_COVERAGE_LOG) */
|
||||
|
||||
/* End of automatically generated file. */
|
||||
|
Loading…
x
Reference in New Issue
Block a user