blob: 75d19e69d756492d33c38ceb4077fe2da77781b9 [file] [log] [blame]
William A. Kennington IIIb9337712019-01-15 18:27:13 -08001project('phosphor-watchdog', 'cpp',
2 version: '0.1', meson_version: '>=0.49.0',
3 default_options: [
4 'warning_level=3',
5 'werror=true',
6 'cpp_std=c++17'
7 ])
8
9build_tests = get_option('tests')
10
11phosphor_dbus_interfaces = dependency('phosphor-dbus-interfaces')
12phosphor_logging = dependency('phosphor-logging')
13sdbusplus = dependency('sdbusplus')
14sdeventplus = dependency('sdeventplus')
15
16libwatchdog = static_library(
17 'watchdog',
18 'watchdog.cpp',
19 implicit_include_directories: false,
20 dependencies: [
21 phosphor_dbus_interfaces,
22 phosphor_logging,
23 sdbusplus,
24 sdeventplus,
25 ])
26
27executable(
28 'phosphor-watchdog',
29 'mainapp.cpp',
30 implicit_include_directories: false,
31 link_with: libwatchdog,
32 dependencies: [
33 phosphor_logging,
34 phosphor_dbus_interfaces,
35 sdbusplus,
36 sdeventplus,
37 ],
38 install: true,
39 install_dir: get_option('sbindir'))
40
41if not build_tests.disabled()
42 subdir('test')
43endif