Adds dl link library to OpenSSL example builds

The example o_p_test uses OpenSSL. On some platforms that fails to build
unless the dl library is included as a static link library.
This commit is contained in:
Simon Butcher 2017-02-01 12:38:44 +00:00
parent a697bf503a
commit 40d8cc7181

View File

@ -31,7 +31,7 @@ install(TARGETS selftest benchmark ssl_test ssl_cert_test
if(OPENSSL_FOUND) if(OPENSSL_FOUND)
add_executable(o_p_test o_p_test.c) add_executable(o_p_test o_p_test.c)
include_directories(${OPENSSL_INCLUDE_DIR}) include_directories(${OPENSSL_INCLUDE_DIR})
target_link_libraries(o_p_test ${libs} ${OPENSSL_LIBRARIES}) target_link_libraries(o_p_test ${libs} ${OPENSSL_LIBRARIES} ${CMAKE_DL_LIBS})
install(TARGETS o_p_test install(TARGETS o_p_test
DESTINATION "bin" DESTINATION "bin"