| Andrew Jeffery | e73bd0a | 2023-01-25 10:39:57 +1030 | [diff] [blame] | 1 | conf_data = configuration_data() | 
| Andrew Jeffery | ab8b045 | 2024-01-11 09:55:51 +1030 | [diff] [blame] | 2 | conf_data.set10( | 
 | 3 |     'VALIDATION_UNSECURE_FEATURE', | 
 | 4 |     get_option('validate-unsecure-feature').allowed(), | 
 | 5 | ) | 
 | 6 | conf_data.set10( | 
 | 7 |     'INSECURE_UNRESTRICTED_SENSOR_OVERRIDE', | 
 | 8 |     get_option('insecure-sensor-override').allowed(), | 
 | 9 | ) | 
 | 10 | configure_file( | 
 | 11 |     input: 'dbus-sensor_config.h.in', | 
 | 12 |     output: 'dbus-sensor_config.h', | 
 | 13 |     configuration: conf_data, | 
 | 14 | ) | 
| Andrew Jeffery | e73bd0a | 2023-01-25 10:39:57 +1030 | [diff] [blame] | 15 |  | 
 | 16 | thresholds_a = static_library( | 
 | 17 |     'thresholds_a', | 
 | 18 |     'Thresholds.cpp', | 
 | 19 |     dependencies: default_deps, | 
 | 20 | ) | 
 | 21 |  | 
 | 22 | thresholds_dep = declare_dependency( | 
| Andrew Jeffery | 9ce5fe4 | 2024-12-04 10:59:33 +1030 | [diff] [blame] | 23 |     include_directories: ['.'], | 
| Andrew Jeffery | ab8b045 | 2024-01-11 09:55:51 +1030 | [diff] [blame] | 24 |     link_with: [thresholds_a], | 
| Andrew Jeffery | e73bd0a | 2023-01-25 10:39:57 +1030 | [diff] [blame] | 25 |     dependencies: default_deps, | 
 | 26 | ) | 
 | 27 |  | 
 | 28 | utils_a = static_library( | 
 | 29 |     'utils_a', | 
| Patrick Williams | ff8c90e | 2025-02-01 08:37:02 -0500 | [diff] [blame] | 30 |     ['FileHandle.cpp', 'SensorPaths.cpp', 'Utils.cpp'], | 
| Andrew Jeffery | e73bd0a | 2023-01-25 10:39:57 +1030 | [diff] [blame] | 31 |     dependencies: default_deps, | 
 | 32 | ) | 
 | 33 |  | 
 | 34 | utils_dep = declare_dependency( | 
| Andrew Jeffery | 9ce5fe4 | 2024-12-04 10:59:33 +1030 | [diff] [blame] | 35 |     include_directories: ['.'], | 
| Andrew Jeffery | ab8b045 | 2024-01-11 09:55:51 +1030 | [diff] [blame] | 36 |     link_with: [utils_a], | 
 | 37 |     dependencies: [sdbusplus], | 
| Andrew Jeffery | e73bd0a | 2023-01-25 10:39:57 +1030 | [diff] [blame] | 38 | ) | 
 | 39 |  | 
 | 40 | devicemgmt_a = static_library( | 
 | 41 |     'devicemgmt_a', | 
| Patrick Williams | ff8c90e | 2025-02-01 08:37:02 -0500 | [diff] [blame] | 42 |     ['DeviceMgmt.cpp'], | 
| Andrew Jeffery | e73bd0a | 2023-01-25 10:39:57 +1030 | [diff] [blame] | 43 |     dependencies: default_deps, | 
 | 44 | ) | 
 | 45 |  | 
 | 46 | devicemgmt_dep = declare_dependency( | 
| Andrew Jeffery | 9ce5fe4 | 2024-12-04 10:59:33 +1030 | [diff] [blame] | 47 |     include_directories: ['.'], | 
| Andrew Jeffery | ab8b045 | 2024-01-11 09:55:51 +1030 | [diff] [blame] | 48 |     link_with: [devicemgmt_a], | 
| Andrew Jeffery | e73bd0a | 2023-01-25 10:39:57 +1030 | [diff] [blame] | 49 |     dependencies: default_deps, | 
 | 50 | ) | 
 | 51 |  | 
 | 52 | pwmsensor_a = static_library( | 
 | 53 |     'pwmsensor_a', | 
 | 54 |     'PwmSensor.cpp', | 
| Andrew Jeffery | ab8b045 | 2024-01-11 09:55:51 +1030 | [diff] [blame] | 55 |     dependencies: [default_deps, thresholds_dep], | 
| Andrew Jeffery | e73bd0a | 2023-01-25 10:39:57 +1030 | [diff] [blame] | 56 | ) | 
 | 57 |  | 
 | 58 | pwmsensor_dep = declare_dependency( | 
| Andrew Jeffery | 9ce5fe4 | 2024-12-04 10:59:33 +1030 | [diff] [blame] | 59 |     include_directories: ['.'], | 
| Andrew Jeffery | ab8b045 | 2024-01-11 09:55:51 +1030 | [diff] [blame] | 60 |     link_with: [pwmsensor_a], | 
 | 61 |     dependencies: [default_deps, thresholds_dep], | 
| Andrew Jeffery | e73bd0a | 2023-01-25 10:39:57 +1030 | [diff] [blame] | 62 | ) | 
 | 63 |  | 
| Jagpal Singh Gill | 15dde86 | 2024-10-16 09:42:54 -0700 | [diff] [blame] | 64 | systemdinterface_src = files('SystemdInterface.cpp') | 
 | 65 |  | 
 | 66 | gpiointerface_a = static_library( | 
 | 67 |     'gpiointerface_a', | 
 | 68 |     'GPIOInterface.cpp', | 
| Patrick Williams | 7b4aaac | 2025-06-09 08:48:54 -0400 | [diff] [blame] | 69 |     dependencies: [default_deps, gpiodcxx], | 
| Jagpal Singh Gill | 15dde86 | 2024-10-16 09:42:54 -0700 | [diff] [blame] | 70 | ) | 
 | 71 |  | 
 | 72 | gpiointerface_dep = declare_dependency( | 
 | 73 |     include_directories: ['.'], | 
 | 74 |     link_with: [gpiointerface_a], | 
 | 75 |     dependencies: default_deps, | 
 | 76 | ) | 
 | 77 |  | 
 | 78 | entitymanagerinterface_a = static_library( | 
 | 79 |     'entitymanagerinterface_a', | 
 | 80 |     'EntityManagerInterface.cpp', | 
 | 81 |     dependencies: default_deps, | 
 | 82 | ) | 
 | 83 |  | 
 | 84 | entitymanagerinterface_dep = declare_dependency( | 
 | 85 |     include_directories: ['.'], | 
 | 86 |     link_with: [entitymanagerinterface_a], | 
 | 87 |     dependencies: default_deps, | 
 | 88 | ) | 
 | 89 |  | 
| Jagpal Singh Gill | ca8c7e9 | 2024-11-02 16:51:48 -0700 | [diff] [blame] | 90 | notifywatch_a = static_library( | 
 | 91 |     'notifywatch_a', | 
 | 92 |     'NotifyWatch.cpp', | 
 | 93 |     dependencies: default_deps, | 
 | 94 | ) | 
 | 95 |  | 
 | 96 | notifywatch_dep = declare_dependency( | 
 | 97 |     include_directories: ['.'], | 
 | 98 |     link_with: [notifywatch_a], | 
 | 99 |     dependencies: default_deps, | 
 | 100 | ) | 
 | 101 |  | 
| Brad Bishop | feb19ef | 2019-11-07 18:02:16 -0500 | [diff] [blame] | 102 | peci_incdirs = [] | 
 | 103 | if not meson.get_compiler('cpp').has_header('linux/peci-ioctl.h') | 
 | 104 |     peci_incdirs = ['../include'] | 
 | 105 | endif | 
 | 106 |  | 
| Patrick Williams | 5bc307f | 2023-11-29 06:44:23 -0600 | [diff] [blame] | 107 | if get_option('intel-cpu').allowed() | 
| Andrew Jeffery | ab8b045 | 2024-01-11 09:55:51 +1030 | [diff] [blame] | 108 |     peci_dep = dependency('libpeci', required: true) | 
| George Liu | d7be555 | 2024-09-20 10:39:09 +0800 | [diff] [blame] | 109 |     subdir('intel-cpu') | 
| Oleksandr Shulzhenko | 77141ac | 2023-03-14 14:52:36 +0100 | [diff] [blame] | 110 | endif | 
 | 111 |  | 
| Aushim Nagarkatti | 021261c | 2024-12-12 10:12:16 -0800 | [diff] [blame] | 112 | if get_option('smbpbi').allowed() | 
 | 113 |     subdir('smbpbi') | 
 | 114 | endif | 
 | 115 |  | 
| Patrick Williams | 5bc307f | 2023-11-29 06:44:23 -0600 | [diff] [blame] | 116 | if get_option('adc').allowed() | 
| George Liu | d7be555 | 2024-09-20 10:39:09 +0800 | [diff] [blame] | 117 |     subdir('adc') | 
| Brad Bishop | feb19ef | 2019-11-07 18:02:16 -0500 | [diff] [blame] | 118 | endif | 
 | 119 |  | 
| Patrick Williams | 5bc307f | 2023-11-29 06:44:23 -0600 | [diff] [blame] | 120 | if get_option('exit-air').allowed() | 
| George Liu | d7be555 | 2024-09-20 10:39:09 +0800 | [diff] [blame] | 121 |     subdir('exit-air') | 
| Brad Bishop | feb19ef | 2019-11-07 18:02:16 -0500 | [diff] [blame] | 122 | endif | 
 | 123 |  | 
| Patrick Williams | 5bc307f | 2023-11-29 06:44:23 -0600 | [diff] [blame] | 124 | if get_option('fan').allowed() | 
| George Liu | d7be555 | 2024-09-20 10:39:09 +0800 | [diff] [blame] | 125 |     subdir('fan') | 
| Brad Bishop | feb19ef | 2019-11-07 18:02:16 -0500 | [diff] [blame] | 126 | endif | 
 | 127 |  | 
| Patrick Williams | 5bc307f | 2023-11-29 06:44:23 -0600 | [diff] [blame] | 128 | if get_option('hwmon-temp').allowed() | 
| George Liu | d7be555 | 2024-09-20 10:39:09 +0800 | [diff] [blame] | 129 |     subdir('hwmon-temp') | 
| Brad Bishop | feb19ef | 2019-11-07 18:02:16 -0500 | [diff] [blame] | 130 | endif | 
 | 131 |  | 
| Patrick Williams | 5bc307f | 2023-11-29 06:44:23 -0600 | [diff] [blame] | 132 | if get_option('intrusion').allowed() | 
| George Liu | d7be555 | 2024-09-20 10:39:09 +0800 | [diff] [blame] | 133 |     subdir('intrusion') | 
| Brad Bishop | feb19ef | 2019-11-07 18:02:16 -0500 | [diff] [blame] | 134 | endif | 
 | 135 |  | 
| Patrick Williams | 5bc307f | 2023-11-29 06:44:23 -0600 | [diff] [blame] | 136 | if get_option('ipmb').allowed() | 
| George Liu | d7be555 | 2024-09-20 10:39:09 +0800 | [diff] [blame] | 137 |     subdir('ipmb') | 
| Brad Bishop | feb19ef | 2019-11-07 18:02:16 -0500 | [diff] [blame] | 138 | endif | 
 | 139 |  | 
| Andrew Jeffery | 275f7c3 | 2024-01-31 12:41:14 +1030 | [diff] [blame] | 140 | if get_option('mctp').allowed() | 
 | 141 |     subdir('mctp') | 
 | 142 | endif | 
 | 143 |  | 
| Patrick Williams | 5bc307f | 2023-11-29 06:44:23 -0600 | [diff] [blame] | 144 | if get_option('mcu').allowed() | 
| George Liu | d7be555 | 2024-09-20 10:39:09 +0800 | [diff] [blame] | 145 |     subdir('mcu') | 
| Brad Bishop | feb19ef | 2019-11-07 18:02:16 -0500 | [diff] [blame] | 146 | endif | 
 | 147 |  | 
| Patrick Williams | 5bc307f | 2023-11-29 06:44:23 -0600 | [diff] [blame] | 148 | if get_option('nvme').allowed() | 
| George Liu | d7be555 | 2024-09-20 10:39:09 +0800 | [diff] [blame] | 149 |     subdir('nvme') | 
| Brad Bishop | feb19ef | 2019-11-07 18:02:16 -0500 | [diff] [blame] | 150 | endif | 
 | 151 |  | 
| Patrick Williams | 5bc307f | 2023-11-29 06:44:23 -0600 | [diff] [blame] | 152 | if get_option('psu').allowed() | 
| George Liu | d7be555 | 2024-09-20 10:39:09 +0800 | [diff] [blame] | 153 |     subdir('psu') | 
| Brad Bishop | feb19ef | 2019-11-07 18:02:16 -0500 | [diff] [blame] | 154 | endif | 
 | 155 |  | 
| Harshit Aghera | 82d4a62 | 2025-04-21 19:09:02 +0530 | [diff] [blame] | 156 | if get_option('nvidia-gpu').allowed() | 
 | 157 |     subdir('nvidia-gpu') | 
 | 158 | endif | 
 | 159 |  | 
| Patrick Williams | 5bc307f | 2023-11-29 06:44:23 -0600 | [diff] [blame] | 160 | if get_option('external').allowed() | 
| George Liu | d7be555 | 2024-09-20 10:39:09 +0800 | [diff] [blame] | 161 |     subdir('external') | 
 | 162 | endif | 
 | 163 |  | 
 | 164 | if get_option('tests').allowed() | 
 | 165 |     subdir('tests') | 
| Brad Bishop | feb19ef | 2019-11-07 18:02:16 -0500 | [diff] [blame] | 166 | endif | 
| Jagpal Singh Gill | 15dde86 | 2024-10-16 09:42:54 -0700 | [diff] [blame] | 167 |  | 
 | 168 | if get_option('leakdetector').allowed() | 
 | 169 |     subdir('leakdetector') | 
 | 170 | endif | 
| Jagpal Singh Gill | ca8c7e9 | 2024-11-02 16:51:48 -0700 | [diff] [blame] | 171 |  | 
 | 172 | if get_option('cable-monitor').allowed() | 
 | 173 |     subdir('cable-monitor') | 
 | 174 | endif |