Skip to content

Commit

Permalink
Fixup cmake
Browse files Browse the repository at this point in the history
  • Loading branch information
marcothaller committed Nov 8, 2024
1 parent e2560c8 commit 42f6f8f
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 25 deletions.
20 changes: 0 additions & 20 deletions cmake/dependencies.cmake
Original file line number Diff line number Diff line change
@@ -1,23 +1,3 @@
###########################################################################
# TODO
# check here if mosquitto is present for now.
# override BUILD_INTEGRATION_MQTT accordingly.
# remove this as soon as we support build of libmosquitto on all OSes
# and we are always able to build mqtt integration in case
# BUILD_INTEGRATION_MQTT is set to ON.
# find_package(PkgConfig)

# if (UNIX AND PKG_CONFIG_FOUND)
# pkg_check_modules(Mosquitto IMPORTED_TARGET libmosquitto REQUIRED)
# endif()

# if (Mosquitto_FOUND AND BUILD_INTEGRATION_MQTT)
# set(BUILD_INTEGRATION_MQTT ON)
# else ()
# set(BUILD_INTEGRATION_MQTT OFF)
# endif()
###########################################################################

include(FetchContent)

include(cmake/dependencies/kdutils.cmake)
Expand Down
12 changes: 7 additions & 5 deletions cmake/dependencies/mosquitto.cmake
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
find_package(Mosquitto REQUIRED)

if (NOT Mosquitto_FOUND)
if (Mosquitto_FOUND)
file (DOWNLOAD
https://test.mosquitto.org/ssl/mosquitto.org.crt
${CMAKE_BINARY_DIR}/mosquitto.org.crt
)
else()
message("Mosquitto could not be located. We don't support building mosquitto from souce (yet). Please install mosquitto manually.")
endif ()

Expand Down Expand Up @@ -48,10 +53,7 @@ endif ()
# $<TARGET_FILE_DIR:app>)
# endif()

file (DOWNLOAD
https://test.mosquitto.org/ssl/mosquitto.org.crt
${CMAKE_BINARY_DIR}/mosquitto.org.crt
)


#find_package(libmosquitto REQUIRED)

Expand Down

0 comments on commit 42f6f8f

Please sign in to comment.