Libidn/idn2 needs to be included in the library link, certainly for shared libs.

So might as well do the same for static libs.
This commit is contained in:
Jim Hague 2019-10-28 10:35:36 +00:00
parent 545916d347
commit 5df3bc4fce
1 changed files with 4 additions and 4 deletions

View File

@ -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)