blob: 0929ba7150de72522033d5a73f3c9a9d8247d385 [file] [log] [blame]
Andrew Jefferye73bd0a2023-01-25 10:39:57 +10301conf_data = configuration_data()
Andrew Jefferyab8b0452024-01-11 09:55:51 +10302conf_data.set10(
3 'VALIDATION_UNSECURE_FEATURE',
4 get_option('validate-unsecure-feature').allowed(),
5)
6conf_data.set10(
7 'INSECURE_UNRESTRICTED_SENSOR_OVERRIDE',
8 get_option('insecure-sensor-override').allowed(),
9)
10configure_file(
11 input: 'dbus-sensor_config.h.in',
12 output: 'dbus-sensor_config.h',
13 configuration: conf_data,
14)
Andrew Jefferye73bd0a2023-01-25 10:39:57 +103015
16thresholds_a = static_library(
17 'thresholds_a',
18 'Thresholds.cpp',
19 dependencies: default_deps,
20)
21
22thresholds_dep = declare_dependency(
Andrew Jeffery9ce5fe42024-12-04 10:59:33 +103023 include_directories: ['.'],
Andrew Jefferyab8b0452024-01-11 09:55:51 +103024 link_with: [thresholds_a],
Andrew Jefferye73bd0a2023-01-25 10:39:57 +103025 dependencies: default_deps,
26)
27
28utils_a = static_library(
29 'utils_a',
Patrick Williamsff8c90e2025-02-01 08:37:02 -050030 ['FileHandle.cpp', 'SensorPaths.cpp', 'Utils.cpp'],
Andrew Jefferye73bd0a2023-01-25 10:39:57 +103031 dependencies: default_deps,
32)
33
34utils_dep = declare_dependency(
Andrew Jeffery9ce5fe42024-12-04 10:59:33 +103035 include_directories: ['.'],
Andrew Jefferyab8b0452024-01-11 09:55:51 +103036 link_with: [utils_a],
37 dependencies: [sdbusplus],
Andrew Jefferye73bd0a2023-01-25 10:39:57 +103038)
39
40devicemgmt_a = static_library(
41 'devicemgmt_a',
Patrick Williamsff8c90e2025-02-01 08:37:02 -050042 ['DeviceMgmt.cpp'],
Andrew Jefferye73bd0a2023-01-25 10:39:57 +103043 dependencies: default_deps,
44)
45
46devicemgmt_dep = declare_dependency(
Andrew Jeffery9ce5fe42024-12-04 10:59:33 +103047 include_directories: ['.'],
Andrew Jefferyab8b0452024-01-11 09:55:51 +103048 link_with: [devicemgmt_a],
Andrew Jefferye73bd0a2023-01-25 10:39:57 +103049 dependencies: default_deps,
50)
51
52pwmsensor_a = static_library(
53 'pwmsensor_a',
54 'PwmSensor.cpp',
Andrew Jefferyab8b0452024-01-11 09:55:51 +103055 dependencies: [default_deps, thresholds_dep],
Andrew Jefferye73bd0a2023-01-25 10:39:57 +103056)
57
58pwmsensor_dep = declare_dependency(
Andrew Jeffery9ce5fe42024-12-04 10:59:33 +103059 include_directories: ['.'],
Andrew Jefferyab8b0452024-01-11 09:55:51 +103060 link_with: [pwmsensor_a],
61 dependencies: [default_deps, thresholds_dep],
Andrew Jefferye73bd0a2023-01-25 10:39:57 +103062)
63
Jagpal Singh Gill15dde862024-10-16 09:42:54 -070064systemdinterface_src = files('SystemdInterface.cpp')
65
66gpiointerface_a = static_library(
67 'gpiointerface_a',
68 'GPIOInterface.cpp',
69 dependencies: default_deps,
70)
71
72gpiointerface_dep = declare_dependency(
73 include_directories: ['.'],
74 link_with: [gpiointerface_a],
75 dependencies: default_deps,
76)
77
78entitymanagerinterface_a = static_library(
79 'entitymanagerinterface_a',
80 'EntityManagerInterface.cpp',
81 dependencies: default_deps,
82)
83
84entitymanagerinterface_dep = declare_dependency(
85 include_directories: ['.'],
86 link_with: [entitymanagerinterface_a],
87 dependencies: default_deps,
88)
89
Brad Bishopfeb19ef2019-11-07 18:02:16 -050090peci_incdirs = []
91if not meson.get_compiler('cpp').has_header('linux/peci-ioctl.h')
92 peci_incdirs = ['../include']
93endif
94
Patrick Williams5bc307f2023-11-29 06:44:23 -060095if get_option('intel-cpu').allowed()
Andrew Jefferyab8b0452024-01-11 09:55:51 +103096 peci_dep = dependency('libpeci', required: true)
George Liud7be5552024-09-20 10:39:09 +080097 subdir('intel-cpu')
Oleksandr Shulzhenko77141ac2023-03-14 14:52:36 +010098endif
99
Aushim Nagarkatti021261c2024-12-12 10:12:16 -0800100if get_option('smbpbi').allowed()
101 subdir('smbpbi')
102endif
103
Patrick Williams5bc307f2023-11-29 06:44:23 -0600104if get_option('adc').allowed()
George Liud7be5552024-09-20 10:39:09 +0800105 subdir('adc')
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500106endif
107
Patrick Williams5bc307f2023-11-29 06:44:23 -0600108if get_option('exit-air').allowed()
George Liud7be5552024-09-20 10:39:09 +0800109 subdir('exit-air')
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500110endif
111
Patrick Williams5bc307f2023-11-29 06:44:23 -0600112if get_option('fan').allowed()
George Liud7be5552024-09-20 10:39:09 +0800113 subdir('fan')
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500114endif
115
Patrick Williams5bc307f2023-11-29 06:44:23 -0600116if get_option('hwmon-temp').allowed()
George Liud7be5552024-09-20 10:39:09 +0800117 subdir('hwmon-temp')
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500118endif
119
Patrick Williams5bc307f2023-11-29 06:44:23 -0600120if get_option('intrusion').allowed()
George Liud7be5552024-09-20 10:39:09 +0800121 subdir('intrusion')
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500122endif
123
Patrick Williams5bc307f2023-11-29 06:44:23 -0600124if get_option('ipmb').allowed()
George Liud7be5552024-09-20 10:39:09 +0800125 subdir('ipmb')
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500126endif
127
Andrew Jeffery275f7c32024-01-31 12:41:14 +1030128if get_option('mctp').allowed()
129 subdir('mctp')
130endif
131
Patrick Williams5bc307f2023-11-29 06:44:23 -0600132if get_option('mcu').allowed()
George Liud7be5552024-09-20 10:39:09 +0800133 subdir('mcu')
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500134endif
135
Patrick Williams5bc307f2023-11-29 06:44:23 -0600136if get_option('nvme').allowed()
George Liud7be5552024-09-20 10:39:09 +0800137 subdir('nvme')
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500138endif
139
Patrick Williams5bc307f2023-11-29 06:44:23 -0600140if get_option('psu').allowed()
George Liud7be5552024-09-20 10:39:09 +0800141 subdir('psu')
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500142endif
143
Harshit Aghera82d4a622025-04-21 19:09:02 +0530144if get_option('nvidia-gpu').allowed()
145 subdir('nvidia-gpu')
146endif
147
Patrick Williams5bc307f2023-11-29 06:44:23 -0600148if get_option('external').allowed()
George Liud7be5552024-09-20 10:39:09 +0800149 subdir('external')
150endif
151
152if get_option('tests').allowed()
153 subdir('tests')
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500154endif
Jagpal Singh Gill15dde862024-10-16 09:42:54 -0700155
156if get_option('leakdetector').allowed()
157 subdir('leakdetector')
158endif