2021-04-26 06:45:52 +00:00
|
|
|
if (MISSING_INTERNAL_LIBUV_LIBRARY)
|
|
|
|
message (WARNING "Can't find internal libuv needed for AMQP-CPP library")
|
2021-04-09 00:28:24 +00:00
|
|
|
set (ENABLE_AMQPCPP OFF CACHE INTERNAL "")
|
|
|
|
endif()
|
|
|
|
|
2020-07-15 11:16:00 +00:00
|
|
|
option(ENABLE_AMQPCPP "Enalbe AMQP-CPP" ${ENABLE_LIBRARIES})
|
2020-07-10 09:47:50 +00:00
|
|
|
|
2020-08-14 15:44:04 +00:00
|
|
|
if (NOT ENABLE_AMQPCPP)
|
|
|
|
return()
|
|
|
|
endif()
|
|
|
|
|
2021-10-24 07:11:23 +00:00
|
|
|
if (NOT EXISTS "${ClickHouse_SOURCE_DIR}/contrib/AMQP-CPP/src")
|
2021-10-17 23:29:04 +00:00
|
|
|
message (WARNING "submodule contrib/AMQP-CPP is missing. to fix try run: \n git submodule update --init")
|
2020-08-14 15:44:04 +00:00
|
|
|
message (${RECONFIGURE_MESSAGE_LEVEL} "Can't find internal AMQP-CPP library")
|
|
|
|
set (USE_AMQPCPP 0)
|
|
|
|
return()
|
2020-05-20 04:28:55 +00:00
|
|
|
endif ()
|
|
|
|
|
2020-08-14 15:44:04 +00:00
|
|
|
set (USE_AMQPCPP 1)
|
2021-08-30 17:55:23 +00:00
|
|
|
set (AMQPCPP_LIBRARY amqp-cpp ${OPENSSL_LIBRARIES})
|
2021-04-12 13:00:43 +00:00
|
|
|
|
2020-08-14 15:44:04 +00:00
|
|
|
set (AMQPCPP_INCLUDE_DIR "${ClickHouse_SOURCE_DIR}/contrib/AMQP-CPP/include")
|
|
|
|
list (APPEND AMQPCPP_INCLUDE_DIR
|
2021-04-12 13:00:43 +00:00
|
|
|
"${LIBUV_INCLUDE_DIR}"
|
2020-08-14 15:44:04 +00:00
|
|
|
"${ClickHouse_SOURCE_DIR}/contrib/AMQP-CPP")
|
2020-05-20 04:28:55 +00:00
|
|
|
|
2021-04-12 13:00:43 +00:00
|
|
|
list (APPEND AMQPCPP_LIBRARY "${LIBUV_LIBRARY}")
|
|
|
|
|
2020-05-20 04:28:55 +00:00
|
|
|
message (STATUS "Using AMQP-CPP=${USE_AMQPCPP}: ${AMQPCPP_INCLUDE_DIR} : ${AMQPCPP_LIBRARY}")
|