From 76029a7fe2803e0fcdac64a1d2a89cb31d8ca9eb Mon Sep 17 00:00:00 2001 From: embetrix Date: Thu, 2 Jan 2025 16:22:21 +0100 Subject: [PATCH] Allow overriding OPENSSL_MODULES_PATH from the command line (#607) Signed-off-by: Ayoub Zaki --- CMakeLists.txt | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 52763934..57c704ff 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -57,7 +57,9 @@ cmake_path(GET OPENSSL_CRYPTO_LIBRARY PARENT_PATH OQS_MODULES_PARENT_PATH) cmake_path(APPEND OQS_MODULES_PARENT_PATH "ossl-modules" OUTPUT_VARIABLE OPENSSL_MODULES_PATH) else() get_filename_component(OPENSSL_LIB_DIR ${OPENSSL_CRYPTO_LIBRARY} DIRECTORY) -set(OPENSSL_MODULES_PATH ${OPENSSL_LIB_DIR}/ossl-modules) +if(NOT DEFINED OPENSSL_MODULES_PATH) + set(OPENSSL_MODULES_PATH ${OPENSSL_LIB_DIR}/ossl-modules CACHE PATH "Path to OpenSSL modules") +endif() endif() # Add required include for liboqs