From 5df3bc4fce1e196b43fd303d415e59ce44479a4c Mon Sep 17 00:00:00 2001 From: Jim Hague Date: Mon, 28 Oct 2019 10:35:36 +0000 Subject: [PATCH] Libidn/idn2 needs to be included in the library link, certainly for shared libs. So might as well do the same for static libs. --- CMakeLists.txt | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 2feb61e8..7b2cdb5a 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -543,10 +543,10 @@ if (ENABLE_STATIC) ${getdns_system_libs} ) if (Libidn_FOUND) - target_link_libraries(getdns INTERFACE Libidn::Libidn) + target_link_libraries(getdns PUBLIC Libidn::Libidn) endif () if (Libidn2_FOUND) - target_link_libraries(getdns INTERFACE Libidn2::Libidn2) + target_link_libraries(getdns PUBLIC Libidn2::Libidn2) endif () set_target_properties(getdns PROPERTIES OUTPUT_NAME getdns${static_lib_suffix}) endif () @@ -565,10 +565,10 @@ if (ENABLE_SHARED) ${getdns_system_libs} ) if (Libidn_FOUND) - target_link_libraries(getdns INTERFACE Libidn::Libidn) + target_link_libraries(getdns_shared PUBLIC Libidn::Libidn) endif () if (Libidn2_FOUND) - target_link_libraries(getdns INTERFACE Libidn2::Libidn2) + target_link_libraries(getdns_shared PUBLIC Libidn2::Libidn2) endif () set_target_properties(getdns_shared PROPERTIES OUTPUT_NAME getdns)