From 14dd3806a40c7c70b309e1c1afe5b618052e1a08 Mon Sep 17 00:00:00 2001 From: Yuriy Chernyshov Date: Wed, 8 Jan 2025 13:31:39 +0100 Subject: [PATCH] Do not link unneeded libraries These libraries are needed by librdkafka, not by cppkafka, hence there is no need to link them. Removing this fixes NixOS build of the library (NixOs does not provide zlib / openssl dependencies by default). --- cmake/FindRdKafka.cmake | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cmake/FindRdKafka.cmake b/cmake/FindRdKafka.cmake index eb82ba64..319569b0 100644 --- a/cmake/FindRdKafka.cmake +++ b/cmake/FindRdKafka.cmake @@ -56,9 +56,9 @@ try_compile(RdKafka_FOUND ${CMAKE_CURRENT_BINARY_DIR} if (RdKafka_FOUND) add_library(RdKafka::rdkafka ${RDKAFKA_LIBRARY_TYPE} IMPORTED GLOBAL) if (UNIX AND NOT APPLE) - set(RDKAFKA_DEPENDENCIES pthread rt ssl crypto dl z) + set(RDKAFKA_DEPENDENCIES pthread rt dl) else() - set(RDKAFKA_DEPENDENCIES pthread ssl crypto dl z) + set(RDKAFKA_DEPENDENCIES pthread dl) endif() set_target_properties(RdKafka::rdkafka PROPERTIES IMPORTED_NAME RdKafka