From 89590a1fedc6787bd6f7578fcbe270f1fce1e2df Mon Sep 17 00:00:00 2001 From: Joerg Bornemann Date: Fri, 5 Feb 2021 15:18:15 +0100 Subject: Fix FindWrapOpenSSL.cmake if OpenSSL::Crypto is UNKNOWN_LIBRARY The attempt to call target_link_libraries on OpenSSL::Crypto failed when this target was added as UNKNOWN library by FindOpenSSL.cmake. Instead, set the INTERFACE_LINK_LIBRARIES property directly. Fixes: QTBUG-90925 Change-Id: Idbc1379c89480225fc7a8d417416ed20404a1122 Reviewed-by: Fabian Kosmale (cherry picked from commit b6b9e54f167aab104600f4d4a2db71ae70561c3b) Reviewed-by: Qt Cherry-pick Bot --- cmake/FindWrapOpenSSL.cmake | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'cmake') diff --git a/cmake/FindWrapOpenSSL.cmake b/cmake/FindWrapOpenSSL.cmake index ef9d49842c..a09aa99518 100644 --- a/cmake/FindWrapOpenSSL.cmake +++ b/cmake/FindWrapOpenSSL.cmake @@ -18,7 +18,7 @@ if(OpenSSL_FOUND) else() set(writableLib OpenSSL::Crypto) endif() - target_link_libraries(${writableLib} INTERFACE Ws2_32 Crypt32) + set_property(TARGET ${writableLib} APPEND PROPERTY INTERFACE_LINK_LIBRARIES Ws2_32 Crypt32) unset(libType) unset(writableLib) endif() -- cgit v1.2.3