mirror of
https://github.com/cuberite/polarssl.git
synced 2025-09-29 16:32:32 -04:00
Adapt libtestdriver1 build
Signed-off-by: Ronald Cron <ronald.cron@arm.com>
This commit is contained in:
parent
52cd108ab2
commit
b2bdb78596
@ -268,11 +268,11 @@ define libtestdriver1_rewrite :=
|
||||
s/\b(?=mbedtls_|psa_)/libtestdriver1_/g;
|
||||
endef
|
||||
|
||||
libtestdriver1.a: export MBEDTLS_PATH := $(patsubst ../..//%,/%,../../$(MBEDTLS_PATH))
|
||||
libtestdriver1.a:
|
||||
# Copy the library and fake a 3rdparty Makefile include.
|
||||
rm -Rf ./libtestdriver1
|
||||
mkdir ./libtestdriver1
|
||||
cp -Rf ../framework ./libtestdriver1
|
||||
cp -Rf ../library ./libtestdriver1
|
||||
cp -Rf ../include ./libtestdriver1
|
||||
cp -Rf ../tf-psa-crypto ./libtestdriver1
|
||||
@ -298,8 +298,10 @@ libtestdriver1.a:
|
||||
# when this test driver library is linked with the Mbed TLS library.
|
||||
perl -pi -e '$(libtestdriver1_rewrite)' ./libtestdriver1/library/*.[ch]
|
||||
perl -pi -e '$(libtestdriver1_rewrite)' ./libtestdriver1/include/*/*.h
|
||||
perl -pi -e '$(libtestdriver1_rewrite)' ./libtestdriver1/tf-psa-crypto/core/*.[ch]
|
||||
perl -pi -e '$(libtestdriver1_rewrite)' ./libtestdriver1/tf-psa-crypto/include/*/*.h
|
||||
perl -pi -e '$(libtestdriver1_rewrite)' ./libtestdriver1/tf-psa-crypto/drivers/builtin/include/*/*.h
|
||||
perl -pi -e '$(libtestdriver1_rewrite)' ./libtestdriver1/tf-psa-crypto/drivers/builtin/src/*.[ch]
|
||||
|
||||
$(MAKE) -C ./libtestdriver1/library CFLAGS="-I../../ $(CFLAGS)" LDFLAGS="$(LDFLAGS)" libmbedcrypto.a
|
||||
cp ./libtestdriver1/library/libmbedcrypto.a ../library/libtestdriver1.a
|
||||
|
@ -13,7 +13,7 @@
|
||||
#include "test/drivers/hash.h"
|
||||
|
||||
#if defined(MBEDTLS_TEST_LIBTESTDRIVER1)
|
||||
#include "libtestdriver1/library/psa_crypto_hash.h"
|
||||
#include "libtestdriver1/tf-psa-crypto/core/psa_crypto_hash.h"
|
||||
#endif
|
||||
|
||||
mbedtls_test_driver_hash_hooks_t
|
||||
|
@ -16,7 +16,7 @@
|
||||
#include "mbedtls/constant_time.h"
|
||||
|
||||
#if defined(MBEDTLS_TEST_LIBTESTDRIVER1)
|
||||
#include "libtestdriver1/library/psa_crypto_aead.h"
|
||||
#include "libtestdriver1/tf-psa-crypto/core/psa_crypto_aead.h"
|
||||
#endif
|
||||
|
||||
mbedtls_test_driver_aead_hooks_t
|
||||
|
@ -16,7 +16,7 @@
|
||||
#include "test/drivers/key_management.h"
|
||||
|
||||
#if defined(MBEDTLS_TEST_LIBTESTDRIVER1)
|
||||
#include "libtestdriver1/library/psa_crypto_rsa.h"
|
||||
#include "libtestdriver1/tf-psa-crypto/core/psa_crypto_rsa.h"
|
||||
#endif
|
||||
|
||||
#define PSA_RSA_KEY_PAIR_MAX_SIZE \
|
||||
|
@ -19,7 +19,7 @@
|
||||
#include "test/random.h"
|
||||
|
||||
#if defined(MBEDTLS_TEST_LIBTESTDRIVER1)
|
||||
#include "libtestdriver1/library/psa_crypto_cipher.h"
|
||||
#include "libtestdriver1/tf-psa-crypto/core/psa_crypto_cipher.h"
|
||||
#endif
|
||||
|
||||
#include <string.h>
|
||||
|
@ -21,8 +21,8 @@
|
||||
|
||||
#if defined(MBEDTLS_TEST_LIBTESTDRIVER1)
|
||||
#include "libtestdriver1/tf-psa-crypto/include/psa/crypto.h"
|
||||
#include "libtestdriver1/library/psa_crypto_ecp.h"
|
||||
#include "libtestdriver1/library/psa_crypto_ffdh.h"
|
||||
#include "libtestdriver1/tf-psa-crypto/core/psa_crypto_ecp.h"
|
||||
#include "libtestdriver1/tf-psa-crypto/core/psa_crypto_ffdh.h"
|
||||
#endif
|
||||
|
||||
mbedtls_test_driver_key_agreement_hooks_t
|
||||
|
@ -23,9 +23,9 @@
|
||||
#include "test/random.h"
|
||||
|
||||
#if defined(MBEDTLS_TEST_LIBTESTDRIVER1)
|
||||
#include "libtestdriver1/library/psa_crypto_ecp.h"
|
||||
#include "libtestdriver1/library/psa_crypto_rsa.h"
|
||||
#include "libtestdriver1/library/psa_crypto_ffdh.h"
|
||||
#include "libtestdriver1/tf-psa-crypto/core/psa_crypto_ecp.h"
|
||||
#include "libtestdriver1/tf-psa-crypto/core/psa_crypto_rsa.h"
|
||||
#include "libtestdriver1/tf-psa-crypto/core/psa_crypto_ffdh.h"
|
||||
#endif
|
||||
|
||||
#include <string.h>
|
||||
|
@ -13,7 +13,7 @@
|
||||
#include "test/drivers/mac.h"
|
||||
|
||||
#if defined(MBEDTLS_TEST_LIBTESTDRIVER1)
|
||||
#include "libtestdriver1/library/psa_crypto_mac.h"
|
||||
#include "libtestdriver1/tf-psa-crypto/core/psa_crypto_mac.h"
|
||||
#endif
|
||||
|
||||
mbedtls_test_driver_mac_hooks_t mbedtls_test_driver_mac_hooks =
|
||||
|
@ -14,7 +14,7 @@
|
||||
#include "string.h"
|
||||
|
||||
#if defined(MBEDTLS_TEST_LIBTESTDRIVER1)
|
||||
#include "libtestdriver1/library/psa_crypto_pake.h"
|
||||
#include "libtestdriver1/tf-psa-crypto/core/psa_crypto_pake.h"
|
||||
#endif
|
||||
|
||||
mbedtls_test_driver_pake_hooks_t mbedtls_test_driver_pake_hooks =
|
||||
|
@ -26,9 +26,9 @@
|
||||
#include "test/random.h"
|
||||
|
||||
#if defined(MBEDTLS_TEST_LIBTESTDRIVER1)
|
||||
#include "libtestdriver1/library/psa_crypto_ecp.h"
|
||||
#include "libtestdriver1/library/psa_crypto_hash.h"
|
||||
#include "libtestdriver1/library/psa_crypto_rsa.h"
|
||||
#include "libtestdriver1/tf-psa-crypto/core/psa_crypto_ecp.h"
|
||||
#include "libtestdriver1/tf-psa-crypto/core/psa_crypto_hash.h"
|
||||
#include "libtestdriver1/tf-psa-crypto/core/psa_crypto_rsa.h"
|
||||
#endif
|
||||
|
||||
#include <string.h>
|
||||
|
Loading…
x
Reference in New Issue
Block a user