Revert "programs, tests: Depend only on libmbedcrypto"
This reverts commit 986a15199d40f354d467144f0c55ced36d161c1a.
diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt
index 3b923a3..a1194e5 100644
--- a/tests/CMakeLists.txt
+++ b/tests/CMakeLists.txt
@@ -1,5 +1,5 @@
set(libs
- mbedcrypto
+ mbedtls
)
# Set the project root directory if it's not already defined, as may happen if
@@ -36,7 +36,7 @@
add_custom_command(
OUTPUT test_suite_${data_name}.c
COMMAND ${PYTHON_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/scripts/generate_test_code.py -f ${CMAKE_CURRENT_SOURCE_DIR}/suites/test_suite_${suite_name}.function -d ${CMAKE_CURRENT_SOURCE_DIR}/suites/test_suite_${data_name}.data -t ${CMAKE_CURRENT_SOURCE_DIR}/suites/main_test.function -p ${CMAKE_CURRENT_SOURCE_DIR}/suites/host_test.function -s ${CMAKE_CURRENT_SOURCE_DIR}/suites --helpers-file ${CMAKE_CURRENT_SOURCE_DIR}/suites/helpers.function -o .
- DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/scripts/generate_test_code.py mbedcrypto ${CMAKE_CURRENT_SOURCE_DIR}/suites/helpers.function ${CMAKE_CURRENT_SOURCE_DIR}/suites/main_test.function ${CMAKE_CURRENT_SOURCE_DIR}/suites/host_test.function ${CMAKE_CURRENT_SOURCE_DIR}/suites/test_suite_${suite_name}.function ${CMAKE_CURRENT_SOURCE_DIR}/suites/test_suite_${data_name}.data
+ DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/scripts/generate_test_code.py mbedtls ${CMAKE_CURRENT_SOURCE_DIR}/suites/helpers.function ${CMAKE_CURRENT_SOURCE_DIR}/suites/main_test.function ${CMAKE_CURRENT_SOURCE_DIR}/suites/host_test.function ${CMAKE_CURRENT_SOURCE_DIR}/suites/test_suite_${suite_name}.function ${CMAKE_CURRENT_SOURCE_DIR}/suites/test_suite_${data_name}.data
)
set(exe_name test_suite_${data_name})
diff --git a/tests/Makefile b/tests/Makefile
index 8fb187e..3203b88 100644
--- a/tests/Makefile
+++ b/tests/Makefile
@@ -8,6 +8,8 @@
CRYPTO_INCLUDES ?= -I../include
LOCAL_CFLAGS = $(WARNING_CFLAGS) $(CRYPTO_INCLUDES) -I../library -D_FILE_OFFSET_BITS=64
LOCAL_LDFLAGS = -L../library \
+ -lmbedtls$(SHARED_SUFFIX) \
+ -lmbedx509$(SHARED_SUFFIX) \
-lmbedcrypto$(SHARED_SUFFIX)
include ../3rdparty/Makefile.inc
diff --git a/tests/data_files/Makefile b/tests/data_files/Makefile
index 7f31cc8..e85fd70 100644
--- a/tests/data_files/Makefile
+++ b/tests/data_files/Makefile
@@ -14,12 +14,6 @@
OPENSSL ?= openssl
FAKETIME ?= faketime
-# Tools from Mbed TLS
-# Mbed Crypto depends on Mbed TLS programs to generate its test certificates.
-# These programs can be installed from Mbed TLS.
-MBEDTLS_CERT_WRITE ?= mbedtls_cert_write
-MBEDTLS_CERT_REQ ?= mbedtls_cert_req
-
## Build the generated test data. Note that since the final outputs
## are committed to the repository, this target should do nothing on a