From f100564baa47c939c30cafbe244d49ef9d43ecc2 Mon Sep 17 00:00:00 2001 From: Dave Pate Date: Fri, 20 Sep 2024 17:57:28 +0200 Subject: [PATCH] Allow FetchContent to pull in yubihsm-shell --- CMakeLists.txt | 2 +- lib/CMakeLists.txt | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index bed20628..d6e738f0 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -27,7 +27,7 @@ project (yubihsm-shell) option(BUILD_ONLY_LIB "Library only build" OFF) option(SUPRESS_MSVC_WARNINGS "Suppresses a lot of the warnings when compiling with MSVC" ON) -include(${CMAKE_SOURCE_DIR}/cmake/SecurityFlags.cmake) +include(${CMAKE_CURRENT_SOURCE_DIR}/cmake/SecurityFlags.cmake) set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_CURRENT_SOURCE_DIR}/cmake/") diff --git a/lib/CMakeLists.txt b/lib/CMakeLists.txt index 79d82944..be54c735 100644 --- a/lib/CMakeLists.txt +++ b/lib/CMakeLists.txt @@ -16,7 +16,7 @@ if(${WIN32_BCRYPT}) else(${WIN32_BCRYPT}) - include(${CMAKE_SOURCE_DIR}/cmake/openssl.cmake) + include(openssl.cmake) find_libcrypto() endif(${WIN32_BCRYPT}) @@ -156,7 +156,7 @@ if(ENABLE_STATIC) endif(ENABLE_STATIC) configure_file(${CMAKE_CURRENT_SOURCE_DIR}/yubihsm.pc.in ${CMAKE_CURRENT_BINARY_DIR}/yubihsm.pc @ONLY) -configure_file(${CMAKE_SOURCE_DIR}/common/platform-config.h.in ${CMAKE_SOURCE_DIR}/common/platform-config.h @ONLY) +configure_file(${CMAKE_CURRENT_SOURCE_DIR}/../common/platform-config.h.in ${CMAKE_CURRENT_SOURCE_DIR}/../common/platform-config.h @ONLY) if(WIN32) configure_file(${CMAKE_CURRENT_SOURCE_DIR}/version.rc.in ${CMAKE_CURRENT_BINARY_DIR}/version.rc @ONLY)