Skip to content

Commit 9a6bba4

Browse files
committed
cmake: use OpenSSL::SSL imported target
Signed-off-by: GitHub <noreply@github.com>
1 parent cb99750 commit 9a6bba4

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

librabbitmq/CMakeLists.txt

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -53,8 +53,7 @@ if (ENABLE_SSL_SUPPORT)
5353
amqp_openssl_bio.c
5454
amqp_openssl_bio.h
5555
)
56-
set(SSL_INCLUDE_DIRS ${OPENSSL_INCLUDE_DIR})
57-
set(AMQP_SSL_LIBS ${OPENSSL_LIBRARIES})
56+
set(AMQP_SSL_LIBS OpenSSL::SSL)
5857
if (APPLE)
5958
# Apple has deprecated OpenSSL in 10.7+. This disables that warning.
6059
set_source_files_properties(${AMQP_SSL_SRCS}
@@ -63,10 +62,10 @@ if (ENABLE_SSL_SUPPORT)
6362

6463
if (WIN32 AND NOT CMAKE_USE_PTHREADS_INIT)
6564
set(AMQP_SSL_SRCS ${AMQP_SSL_SRCS} win32/threads.h win32/threads.c)
66-
set(SSL_INCLUDE_DIRS ${SSL_INCLUDE_DIRS} win32)
65+
set(SSL_INCLUDE_DIRS win32)
6766
else()
6867
set(AMQP_SSL_SRCS ${AMQP_SSL_SRCS} unix/threads.h)
69-
set(SSL_INCLUDE_DIRS ${SSL_INCLUDE_DIRS} unix)
68+
set(SSL_INCLUDE_DIRS unix)
7069
endif()
7170
endif()
7271

0 commit comments

Comments
 (0)