1templates_depends = files( 2 'example/example.yaml', 3 'example/test.yaml', 4 'templates/callbackgroup.mako.cpp', 5 'templates/conditional.mako.cpp', 6 'templates/count.mako.cpp', 7 'templates/median.mako.cpp', 8 'templates/generated.mako.hpp', 9 'templates/journal.mako.cpp', 10 'templates/elog.mako.cpp', 11 'templates/errors.mako.hpp', 12 'templates/method.mako.cpp', 13 'templates/resolve_errors.mako.cpp', 14 'templates/event.mako.cpp', 15) 16 17generated_hpp = custom_target( 18 'generated.hpp', 19 command: [ 20 prog_python, 21 meson.project_source_root() + '/src/pdmgen.py', 22 '-t', 'generated.mako.hpp', 23 '-p', meson.project_source_root() + '/src/templates', 24 '-d', meson.project_source_root() + '/' + get_option('YAML_PATH'), 25 '-o', meson.current_build_dir() + '/generated.hpp', 26 'generate-cpp' 27 ], 28 depend_files: templates_depends, 29 output: 'generated.hpp', 30) 31 32sources = [ 33 generated_hpp, 34 'elog.cpp', 35 'event_manager.cpp', 36 'event_serialize.cpp', 37 'journal.cpp', 38 'main.cpp', 39 'pathwatch.cpp', 40 'propertywatch.cpp', 41 'resolve_errors.cpp', 42 'snmp_trap.cpp', 43] 44 45deps = [ 46 sdbusplus_dep, 47 sdeventplus_dep, 48 phosphor_dbus_interfaces_dep, 49 phosphor_logging_dep, 50 phosphor_snmp_dep, 51] 52 53executable( 54 'phosphor-dbus-monitor', 55 sources, 56 include_directories: ['..'], 57 implicit_include_directories: true, 58 dependencies: deps, 59 install: true, 60 install_dir: get_option('bindir'), 61) 62 63build_tests = get_option('tests') 64if not build_tests.disabled() 65 subdir('test') 66endif 67