From 5b8b5c0ed56caa7371cd7208b87607b783e557e1 Mon Sep 17 00:00:00 2001 From: xgj Date: Fri, 11 Jun 2021 11:04:43 +0800 Subject: [PATCH] for ssl static link add ld library link --- CMakeLists.txt | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index 54bfed8a..3329bdf4 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -87,6 +87,10 @@ if (OPENSSL_FOUND AND ENABLE_OPENSSL) include_directories(${OPENSSL_INCLUDE_DIR}) add_definitions(-DENABLE_OPENSSL) list(APPEND LINK_LIB_LIST ${OPENSSL_LIBRARIES}) + if (CMAKE_SYSTEM_NAME MATCHES "Linux") + list(APPEND LINK_LIB_LIST dl) + endif() + else() message(WARNING "openssl未找到,rtmp将不支持flash播放器,https/wss/rtsps/rtmps也将失效") endif ()