blob: e2af923b38ea53672ee3d6ad369bb63a5f7538fa [file] [log] [blame]
Brad Bishopfeb19ef2019-11-07 18:02:16 -05001peci_incdirs = []
2if not meson.get_compiler('cpp').has_header('linux/peci-ioctl.h')
3 peci_incdirs = ['../include']
4endif
5
6if get_option('adc').enabled()
7 executable(
8 'adcsensor',
9 'ADCSensor.cpp',
10 'ADCSensorMain.cpp',
11 dependencies: [
Patrick Williams302a61a2021-08-27 15:40:08 -050012 default_deps,
Brad Bishopfeb19ef2019-11-07 18:02:16 -050013 gpiodcxx,
Patrick Williams8b8f6062021-08-27 14:53:50 -050014 thresholds_dep,
15 utils_dep,
Brad Bishopfeb19ef2019-11-07 18:02:16 -050016 ],
Ed Tanous16966b52021-09-15 15:06:59 -070017 cpp_args: uring_args,
Brad Bishopfeb19ef2019-11-07 18:02:16 -050018 implicit_include_directories: false,
19 include_directories: '../include',
20 install: true,
Brad Bishopfeb19ef2019-11-07 18:02:16 -050021 )
22endif
23
Thu Nguyen255da6b2022-07-29 10:05:52 +070024if get_option('intel-cpu').enabled()
Brad Bishopfeb19ef2019-11-07 18:02:16 -050025 executable(
Thu Nguyen255da6b2022-07-29 10:05:52 +070026 'intelcpusensor',
27 'IntelCPUSensorMain.cpp',
28 'IntelCPUSensor.cpp',
Brad Bishopfeb19ef2019-11-07 18:02:16 -050029 dependencies: [
Patrick Williams302a61a2021-08-27 15:40:08 -050030 default_deps,
Brad Bishopfeb19ef2019-11-07 18:02:16 -050031 gpiodcxx,
Patrick Williams8b8f6062021-08-27 14:53:50 -050032 thresholds_dep,
33 utils_dep,
Brad Bishopfeb19ef2019-11-07 18:02:16 -050034 ],
35 implicit_include_directories: false,
36 include_directories: [
37 '../include'
38 ] + peci_incdirs,
39 install: true,
Brad Bishopfeb19ef2019-11-07 18:02:16 -050040 )
41endif
42
43if get_option('exit-air').enabled()
44 executable(
45 'exitairtempsensor',
46 'ExitAirTempSensor.cpp',
47 dependencies: [
Patrick Williams302a61a2021-08-27 15:40:08 -050048 default_deps,
Patrick Williams8b8f6062021-08-27 14:53:50 -050049 thresholds_dep,
50 utils_dep,
Brad Bishopfeb19ef2019-11-07 18:02:16 -050051 ],
Ed Tanous16966b52021-09-15 15:06:59 -070052 cpp_args: uring_args,
Brad Bishopfeb19ef2019-11-07 18:02:16 -050053 implicit_include_directories: false,
54 include_directories: '../include',
55 install: true,
Brad Bishopfeb19ef2019-11-07 18:02:16 -050056 )
57endif
58
59if get_option('fan').enabled()
60 executable(
61 'fansensor',
62 'FanMain.cpp',
63 'TachSensor.cpp',
64 'PwmSensor.cpp',
65 dependencies: [
Patrick Williams302a61a2021-08-27 15:40:08 -050066 default_deps,
Patrick Williams8b8f6062021-08-27 14:53:50 -050067 gpiodcxx,
Patrick Williams8b8f6062021-08-27 14:53:50 -050068 thresholds_dep,
69 utils_dep,
Brad Bishopfeb19ef2019-11-07 18:02:16 -050070 ],
Ed Tanous16966b52021-09-15 15:06:59 -070071 cpp_args: uring_args,
Brad Bishopfeb19ef2019-11-07 18:02:16 -050072 implicit_include_directories: false,
73 include_directories: '../include',
74 install: true,
Brad Bishopfeb19ef2019-11-07 18:02:16 -050075 )
76endif
77
78if get_option('hwmon-temp').enabled()
79 executable(
80 'hwmontempsensor',
81 'HwmonTempMain.cpp',
82 'HwmonTempSensor.cpp',
83 dependencies: [
Patrick Williams302a61a2021-08-27 15:40:08 -050084 default_deps,
Zev Weissa1456c42022-07-18 16:59:35 -070085 devicemgmt_dep,
Patrick Williams8b8f6062021-08-27 14:53:50 -050086 thresholds_dep,
87 utils_dep,
Brad Bishopfeb19ef2019-11-07 18:02:16 -050088 ],
Ed Tanous16966b52021-09-15 15:06:59 -070089 cpp_args: uring_args,
Brad Bishopfeb19ef2019-11-07 18:02:16 -050090 implicit_include_directories: false,
91 include_directories: '../include',
92 install: true,
Brad Bishopfeb19ef2019-11-07 18:02:16 -050093 )
94endif
95
96if get_option('intrusion').enabled()
97 executable(
98 'intrusionsensor',
99 'ChassisIntrusionSensor.cpp',
100 'IntrusionSensorMain.cpp',
101 dependencies: [
Patrick Williams302a61a2021-08-27 15:40:08 -0500102 default_deps,
Patrick Williams8b8f6062021-08-27 14:53:50 -0500103 gpiodcxx,
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500104 i2c,
Patrick Williams8b8f6062021-08-27 14:53:50 -0500105 utils_dep,
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500106 ],
Ed Tanous16966b52021-09-15 15:06:59 -0700107 cpp_args: uring_args,
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500108 implicit_include_directories: false,
109 include_directories: '../include',
110 install: true,
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500111 )
112endif
113
114if get_option('ipmb').enabled()
115 executable(
116 'ipmbsensor',
117 'IpmbSensor.cpp',
118 dependencies: [
Patrick Williams302a61a2021-08-27 15:40:08 -0500119 default_deps,
Patrick Williams8b8f6062021-08-27 14:53:50 -0500120 thresholds_dep,
121 utils_dep,
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500122 ],
Ed Tanous16966b52021-09-15 15:06:59 -0700123 cpp_args: uring_args,
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500124 implicit_include_directories: false,
125 include_directories: '../include',
126 install: true,
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500127 )
128endif
129
Ed Tanous49d12d82021-02-11 13:44:15 -0800130if get_option('mcu').enabled()
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500131 executable(
132 'mcutempsensor',
133 'MCUTempSensor.cpp',
134 dependencies: [
Patrick Williams302a61a2021-08-27 15:40:08 -0500135 default_deps,
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500136 i2c,
Patrick Williams8b8f6062021-08-27 14:53:50 -0500137 thresholds_dep,
138 utils_dep,
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500139 ],
Ed Tanous16966b52021-09-15 15:06:59 -0700140 cpp_args: uring_args,
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500141 implicit_include_directories: false,
142 include_directories: '../include',
143 install: true,
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500144 )
145endif
146
147if get_option('nvme').enabled()
Andrew Jefferye3e3c972021-05-26 14:37:07 +0930148 nvme_srcs = files('NVMeSensorMain.cpp', 'NVMeSensor.cpp')
149 nvme_srcs += files('NVMeBasicContext.cpp')
Andrew Jefferye3e3c972021-05-26 14:37:07 +0930150
Andrew Jeffery6f25e7e2021-05-24 12:52:53 +0930151 nvme_deps = [ default_deps, i2c, thresholds_dep, utils_dep, threads ]
152
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500153 executable(
154 'nvmesensor',
Andrew Jefferye3e3c972021-05-26 14:37:07 +0930155 sources: nvme_srcs,
156 dependencies: nvme_deps,
Ed Tanous16966b52021-09-15 15:06:59 -0700157 cpp_args: uring_args,
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500158 implicit_include_directories: false,
159 include_directories: '../include',
160 install: true,
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500161 )
162endif
163
Lei YU3a18b862021-02-05 13:55:08 +0800164if get_option('psu').enabled()
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500165 executable(
Lei YU3a18b862021-02-05 13:55:08 +0800166 'psusensor',
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500167 'PSUEvent.cpp',
168 'PSUSensor.cpp',
169 'PSUSensorMain.cpp',
170 dependencies: [
Patrick Williams302a61a2021-08-27 15:40:08 -0500171 default_deps,
Patrick Williams8b8f6062021-08-27 14:53:50 -0500172 pwmsensor_dep,
Patrick Williams8b8f6062021-08-27 14:53:50 -0500173 thresholds_dep,
174 utils_dep,
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500175 ],
Ed Tanous16966b52021-09-15 15:06:59 -0700176 cpp_args: uring_args,
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500177 implicit_include_directories: false,
178 include_directories: '../include',
179 install: true,
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500180 )
181endif
182
183if get_option('external').enabled()
184 executable(
185 'externalsensor',
186 'ExternalSensor.cpp',
187 'ExternalSensorMain.cpp',
188 dependencies: [
Patrick Williams302a61a2021-08-27 15:40:08 -0500189 default_deps,
Patrick Williams8b8f6062021-08-27 14:53:50 -0500190 thresholds_dep,
191 utils_dep,
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500192 ],
Ed Tanous16966b52021-09-15 15:06:59 -0700193 cpp_args: uring_args,
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500194 implicit_include_directories: false,
195 include_directories: '../include',
196 install: true,
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500197 )
198endif