blob: 9d44db363db6783cc2d3043d049e1aa9ed7a089c [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',
Jayashree Dhanapal3746c552022-03-21 14:45:52 +0530118 'IpmbSDRSensor.cpp',
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500119 dependencies: [
Patrick Williams302a61a2021-08-27 15:40:08 -0500120 default_deps,
Patrick Williams8b8f6062021-08-27 14:53:50 -0500121 thresholds_dep,
122 utils_dep,
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500123 ],
Ed Tanous16966b52021-09-15 15:06:59 -0700124 cpp_args: uring_args,
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500125 implicit_include_directories: false,
126 include_directories: '../include',
127 install: true,
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500128 )
129endif
130
Ed Tanous49d12d82021-02-11 13:44:15 -0800131if get_option('mcu').enabled()
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500132 executable(
133 'mcutempsensor',
134 'MCUTempSensor.cpp',
135 dependencies: [
Patrick Williams302a61a2021-08-27 15:40:08 -0500136 default_deps,
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500137 i2c,
Patrick Williams8b8f6062021-08-27 14:53:50 -0500138 thresholds_dep,
139 utils_dep,
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500140 ],
Ed Tanous16966b52021-09-15 15:06:59 -0700141 cpp_args: uring_args,
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500142 implicit_include_directories: false,
143 include_directories: '../include',
144 install: true,
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500145 )
146endif
147
148if get_option('nvme').enabled()
Andrew Jefferye3e3c972021-05-26 14:37:07 +0930149 nvme_srcs = files('NVMeSensorMain.cpp', 'NVMeSensor.cpp')
150 nvme_srcs += files('NVMeBasicContext.cpp')
Andrew Jefferye3e3c972021-05-26 14:37:07 +0930151
Andrew Jeffery6f25e7e2021-05-24 12:52:53 +0930152 nvme_deps = [ default_deps, i2c, thresholds_dep, utils_dep, threads ]
153
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500154 executable(
155 'nvmesensor',
Andrew Jefferye3e3c972021-05-26 14:37:07 +0930156 sources: nvme_srcs,
157 dependencies: nvme_deps,
Ed Tanous16966b52021-09-15 15:06:59 -0700158 cpp_args: uring_args,
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500159 implicit_include_directories: false,
160 include_directories: '../include',
161 install: true,
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500162 )
163endif
164
Lei YU3a18b862021-02-05 13:55:08 +0800165if get_option('psu').enabled()
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500166 executable(
Lei YU3a18b862021-02-05 13:55:08 +0800167 'psusensor',
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500168 'PSUEvent.cpp',
169 'PSUSensor.cpp',
170 'PSUSensorMain.cpp',
171 dependencies: [
Patrick Williams302a61a2021-08-27 15:40:08 -0500172 default_deps,
Patrick Williams8b8f6062021-08-27 14:53:50 -0500173 pwmsensor_dep,
Patrick Williams8b8f6062021-08-27 14:53:50 -0500174 thresholds_dep,
175 utils_dep,
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500176 ],
Ed Tanous16966b52021-09-15 15:06:59 -0700177 cpp_args: uring_args,
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500178 implicit_include_directories: false,
179 include_directories: '../include',
180 install: true,
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500181 )
182endif
183
184if get_option('external').enabled()
185 executable(
186 'externalsensor',
187 'ExternalSensor.cpp',
188 'ExternalSensorMain.cpp',
189 dependencies: [
Patrick Williams302a61a2021-08-27 15:40:08 -0500190 default_deps,
Patrick Williams8b8f6062021-08-27 14:53:50 -0500191 thresholds_dep,
192 utils_dep,
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500193 ],
Ed Tanous16966b52021-09-15 15:06:59 -0700194 cpp_args: uring_args,
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500195 implicit_include_directories: false,
196 include_directories: '../include',
197 install: true,
Brad Bishopfeb19ef2019-11-07 18:02:16 -0500198 )
199endif