programs, tests: Depend only on libmbedcrypto

Update the tests and programs to depend only on libmbedcrypto, since
we'll soon only build libmbedcrypto.
diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt
index 757ca5b..5139794 100644
--- a/tests/CMakeLists.txt
+++ b/tests/CMakeLists.txt
@@ -1,5 +1,5 @@
 set(libs
-    mbedtls
+    mbedcrypto
 )
 
 find_package(Perl)
@@ -29,7 +29,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 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
+        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
     )
 
     set(exe_name test_suite_${data_name})
diff --git a/tests/Makefile b/tests/Makefile
index cb374e5..90880aa 100644
--- a/tests/Makefile
+++ b/tests/Makefile
@@ -8,8 +8,6 @@
 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)
 
 # Enable definition of various functions used throughout the testsuite
diff --git a/tests/data_files/Makefile b/tests/data_files/Makefile
index 65ac9b0..98f322d 100644
--- a/tests/data_files/Makefile
+++ b/tests/data_files/Makefile
@@ -14,6 +14,12 @@
 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