Add Mosquitto and Mosquittopp library detection

pull/3585/head
Isaac Connor 2021-12-22 16:15:48 -05:00
parent 2b8fee80de
commit 81cdda7def
1 changed files with 21 additions and 1 deletions

View File

@ -432,8 +432,28 @@ if(NOT ZM_NO_PRCE)
endif()
endif()
if(NOT ZM_NO_MQTT)
find_package(Mosquitto)
if(MOSQUITTO_FOUND)
include_directories(${MOSQUITTO_INCLUDE_DIRS})
list(APPEND ZM_BIN_LIBS "${MOSQUITTO_LIBRARIES}")
set(optlibsfound "${optlibsfound} Mosquitto")
else()
set(optlibsnotfound "${optlibsnotfound} Mosquitto")
endif (MOSQUITTO_FOUND)
find_package(Mosquittopp)
if(MOSQUITTOPP_FOUND)
include_directories(${MOSQUITTOPP_INCLUDE_DIRS})
list(APPEND ZM_BIN_LIBS "${MOSQUITTOPP_LIBRARIES}")
set(optlibsfound "${optlibsfound} Mosquittopp")
else()
set(optlibsnotfound "${optlibsnotfound} Mosquittopp")
endif (MOSQUITTOPP_FOUND)
endif()
# mysqlclient (using find_library and find_path)
find_library(MYSQLCLIENT_LIBRARIES mysqlclient PATH_SUFFIXES mysql)
find_library(MYSQLCLIENT_LIBRARIES mysqlclient PATH_SUFFIXES mysql)
if(MYSQLCLIENT_LIBRARIES)
set(HAVE_LIBMYSQLCLIENT 1)
list(APPEND ZM_BIN_LIBS "${MYSQLCLIENT_LIBRARIES}")