cmake use_tls fix

This commit is contained in:
Benjamin Sergeant 2019-06-24 23:34:31 -07:00
parent 77d65760f0
commit b2f9c219b1

View File

@ -143,7 +143,7 @@ if (UNIX)
target_link_libraries(ixwebsocket ${CMAKE_THREAD_LIBS_INIT}) target_link_libraries(ixwebsocket ${CMAKE_THREAD_LIBS_INIT})
endif() endif()
if (USE_OPEN_SSL) if (USE_TLS AND USE_OPEN_SSL)
find_package(OpenSSL REQUIRED) find_package(OpenSSL REQUIRED)
add_definitions(${OPENSSL_DEFINITIONS}) add_definitions(${OPENSSL_DEFINITIONS})
message(STATUS "OpenSSL: " ${OPENSSL_VERSION}) message(STATUS "OpenSSL: " ${OPENSSL_VERSION})
@ -151,7 +151,7 @@ if (USE_OPEN_SSL)
target_link_libraries(ixwebsocket ${OPENSSL_LIBRARIES}) target_link_libraries(ixwebsocket ${OPENSSL_LIBRARIES})
endif() endif()
if (USE_MBED_TLS) if (USE_TLS AND USE_MBED_TLS)
if (USE_VENDORED_THIRD_PARTY) if (USE_VENDORED_THIRD_PARTY)
set (ENABLE_PROGRAMS OFF) set (ENABLE_PROGRAMS OFF)
add_subdirectory(third_party/mbedtls) add_subdirectory(third_party/mbedtls)