cmake: check for optional libsystemd presence

This commit is contained in:
Pierre Bourdon
2018-03-08 06:00:40 +00:00
parent 1a1133bf8e
commit f221fac02e
2 changed files with 36 additions and 0 deletions

View File

@ -757,6 +757,14 @@ if(ENABLE_WX)
endif()
endif()
find_package(Libsystemd)
if(SYSTEMD_FOUND)
message(STATUS "libsystemd found, enabling traversal server watchdog support")
add_definitions(-DHAVE_LIBSYSTEMD)
else()
message(STATUS "libsystemd not found, disabling traversal server watchdog support")
endif()
########################################
# Pre-build events: Define configuration variables and write SCM info header
#