aboutsummaryrefslogtreecommitdiff
path: root/CMakeLists.txt
diff options
context:
space:
mode:
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt8
1 files changed, 7 insertions, 1 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 9e068f4..1390f44 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -29,6 +29,7 @@ set (CMAKE_INSTALL_FULL_PKGLIBEXECDIR "${CMAKE_INSTALL_FULL_LIBEXECDIR}/${CMAKE_
##
find_package (PkgConfig REQUIRED)
+include (CheckIncludeFile)
include (FindPkgConfig)
pkg_check_modules (SERVICE_DEPS REQUIRED
@@ -42,7 +43,12 @@ pkg_check_modules (SERVICE_DEPS REQUIRED
url-dispatcher-1>=1
properties-cpp>=0.0.1)
include_directories (SYSTEM ${SERVICE_DEPS_INCLUDE_DIRS})
-set (SERVICE_DEPS_LIBRARIES -lubuntu_platform_hardware_api ${SERVICE_DEPS_LIBRARIES})
+
+CHECK_INCLUDE_FILE(ubuntu/hardware/alarm.h HAVE_UBUNTU_HW_ALARM_H)
+if (HAVE_UBUNTU_HW_ALARM_H)
+ set (SERVICE_DEPS_LIBRARIES -lubuntu_platform_hardware_api ${SERVICE_DEPS_LIBRARIES})
+ add_definitions(-DHAVE_UBUNTU_HW_ALARM_H)
+endif ()
##
## custom targets