blob: b8a7f0e2bdf192c57bf440d8bbce8978b542d57a [file] [log] [blame]
Brad Bishopb4459912019-11-05 19:39:11 -05001cpp_args = boost_args + ['-DPACKAGE_DIR="' + packagedir + '/"']
Patrick Williams37304f02025-02-01 08:38:32 -05002cpp_args += ['-DSYSCONF_DIR="' + sysconfdir + '/"']
Potin Laif375fec2024-03-21 14:35:45 +08003installdir = join_paths(get_option('libexecdir'), 'entity-manager')
Brad Bishopb4459912019-11-05 19:39:11 -05004
Christopher Meisfc9e7fd2025-04-03 13:13:35 +02005subdir('entity_manager')
Brad Bishopb4459912019-11-05 19:39:11 -05006
Brad Bishop92daaaa2020-01-20 15:45:01 -05007if get_option('fru-device')
Andrei Kartashev6b3d4c52020-08-10 19:24:17 +03008 cpp_args_fd = cpp_args
9 if get_option('fru-device-resizefru')
10 cpp_args_fd = cpp_args_fd + ['-DENABLE_FRU_AREA_RESIZE']
11 endif
Vu Phamdac2dfc2024-11-05 12:20:42 -060012 detect_mode = get_option('fru-device-16bitdetectmode')
13 cpp_args_fd += ['-DFRU_DEVICE_16BITDETECTMODE="' + detect_mode + '"']
Brad Bishop92daaaa2020-01-20 15:45:01 -050014 executable(
15 'fru-device',
Brad Bishope45d8c72022-05-25 15:12:53 -040016 'expression.cpp',
17 'fru_device.cpp',
18 'utils.cpp',
19 'fru_utils.cpp',
Zev Weiss309c0b12022-02-25 01:44:12 +000020 'fru_reader.cpp',
Andrei Kartashev6b3d4c52020-08-10 19:24:17 +030021 cpp_args: cpp_args_fd,
Brad Bishop92daaaa2020-01-20 15:45:01 -050022 dependencies: [
23 boost,
24 i2c,
Andrew Jeffery14a7bc92021-08-02 10:01:22 +093025 nlohmann_json_dep,
Alexander Hansenc3db2c32024-08-20 15:01:38 +020026 phosphor_logging_dep,
Brad Bishop92daaaa2020-01-20 15:45:01 -050027 sdbusplus,
28 threads,
29 valijson,
30 ],
Brad Bishop92daaaa2020-01-20 15:45:01 -050031 install: true,
Potin Laif375fec2024-03-21 14:35:45 +080032 install_dir: installdir,
Brad Bishop92daaaa2020-01-20 15:45:01 -050033 )
34endif
Chris Sides2ab73412024-10-15 16:04:11 -050035
36if get_option('devicetree-vpd')
37 cpp_args_fd = cpp_args
38 executable(
39 'devicetree-vpd-parser',
40 'machine_context.cpp',
41 'devicetree_vpd_parser.cpp',
42 cpp_args: cpp_args_fd,
Patrick Williams37304f02025-02-01 08:38:32 -050043 dependencies: [sdbusplus, phosphor_dbus_interfaces_dep],
Chris Sides2ab73412024-10-15 16:04:11 -050044 install: true,
45 install_dir: installdir,
46 )
47endif