Fix CMake build for versions <3.19

CMake <3.19 does not support interface targets with sources.
For better IDE integrations we still can add the config.h using the
`target_sources` command.

Signed-off-by: Kai Buschulte <kai.buschulte@cedalo.com>
pull/2580/head
Kai Buschulte 3 years ago
parent a883bda9c1
commit d66702ba37

@ -104,10 +104,8 @@ option(WITH_APPS "Build apps?" ON)
option(WITH_PLUGINS "Build plugins?" ON)
option(DOCUMENTATION "Build documentation?" ON)
add_library(config-header
INTERFACE
config.h
)
add_library(config-header INTERFACE)
target_sources(config-header INTERFACE config.h)
target_include_directories(config-header
INTERFACE
${mosquitto_SOURCE_DIR}

Loading…
Cancel
Save