summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJoerg Bornemann <joerg.bornemann@qt.io>2021-02-05 15:18:15 +0100
committerJoerg Bornemann <joerg.bornemann@qt.io>2021-02-11 05:54:15 +0000
commitb6b9e54f167aab104600f4d4a2db71ae70561c3b (patch)
tree678efc8bd93be0f1a7e98dc9dac249b1b005b551
parent746393545f6e68292b780ea62ea2f6bef81c708c (diff)
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. Pick-to: 6.1 6.0 Fixes: QTBUG-90925 Change-Id: Idbc1379c89480225fc7a8d417416ed20404a1122 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
-rw-r--r--cmake/FindWrapOpenSSL.cmake2
1 files changed, 1 insertions, 1 deletions
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()