diff --git a/tests/data_files/Makefile b/tests/data_files/Makefile index 40c22f53b..9d4cca208 100644 --- a/tests/data_files/Makefile +++ b/tests/data_files/Makefile @@ -13,8 +13,10 @@ ## Tools OPENSSL ?= openssl FAKETIME ?= faketime -MBEDTLS_CERT_WRITE ?= $(PWD)/../../programs/x509/cert_write -MBEDTLS_CERT_REQ ?= $(PWD)/../../programs/x509/cert_req + +TOP_DIR = $(dir $(firstword $(MAKEFILE_LIST)))/../.. +MBEDTLS_CERT_WRITE ?= $(TOP_DIR)/programs/x509/cert_write +MBEDTLS_CERT_REQ ?= $(TOP_DIR)/programs/x509/cert_req ## Build the generated test data. Note that since the final outputs