Skip to content

Commit e757294

Browse files
committed
Merge pull request cpp-netlib#318 from infinity0/0.10-devel
explicitly link dependencies into the shared library
2 parents bcb1bda + 77efdb3 commit e757294

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

libs/network/src/CMakeLists.txt

+6
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,12 @@ set_target_properties(cppnetlib-client-connections
3939
PROPERTIES VERSION ${CPPNETLIB_VERSION_STRING}
4040
SOVERSION ${CPPNETLIB_VERSION_MAJOR}
4141
PUBLIC_HEADER "${CPP-NETLIB_HEADERS}")
42+
if (OPENSSL_FOUND)
43+
target_link_libraries(cppnetlib-client-connections ssl crypto)
44+
endif ()
45+
if (Boost_FOUND)
46+
target_link_libraries(cppnetlib-client-connections boost_system)
47+
endif ()
4248
install(TARGETS cppnetlib-client-connections
4349
EXPORT cppnetlibTargets
4450
PUBLIC_HEADER DESTINATION ${CMAKE_INSTALL_FULL_INCLUDEDIR}

0 commit comments

Comments
 (0)