xref: /openbmc/phosphor-power/power-sequencer/meson.build (revision 516e22fe84f77c2d029b028785dfd1e5633267b5)
1sequencer_src = []
2
3if sequencer == 'ucd90160'
4    ucd90160_defs_cpp = custom_target(
5        'ucd90160_defs.cpp',
6        command: [
7            prog_python,
8            '@INPUT0@',
9            '-i',
10            '@INPUT1@',
11            '-o',
12            meson.current_build_dir(),
13        ],
14        input: [
15            'gen-ucd90160-defs.py',
16            get_option('ucd90160-yaml'),
17            'templates/ucd90160_defs.mako.cpp',
18        ],
19        output: 'ucd90160_defs.cpp',
20    )
21
22    sequencer_src += ['ucd90160.cpp', ucd90160_defs_cpp]
23
24elif sequencer == 'mihawk-cpld'
25    sequencer_src += 'mihawk-cpld.cpp'
26endif
27
28executable(
29    'pseq-monitor',
30    error_hpp,
31    'main.cpp',
32    'pgood_monitor.cpp',
33    'runtime_monitor.cpp',
34    sequencer_src,
35    dependencies: [
36        cli11_dep,
37        libi2c_dep,
38        nlohmann_json_dep,
39        phosphor_dbus_interfaces,
40        phosphor_logging,
41        sdbusplus,
42        sdeventplus,
43    ],
44    include_directories: '..',
45    install: true,
46    link_with: libpower,
47)
48