diff --git a/CMakeLists.txt b/CMakeLists.txt index c26432ed7dd3aff7a0279efdf0ffc90d3fe788eb..b7cd7d0299b032eeeeedd64f6c53b67ab74ac96b 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -51,7 +51,11 @@ if (NOT MSVC) set(MSGPACK_TARGET "msgpackc-cxx") endif() endif() - find_package(yaml-cpp REQUIRED) + + if (BUILD_TOOLS) + find_package(yaml-cpp REQUIRED) + endif() + include_directories(${YAML_CPP_INCLUDE_DIR}) find_package(fmt) pkg_search_module (opendht REQUIRED IMPORTED_TARGET opendht)