meson: use non-deprecated systemd packageconfig

Systemd's packageconfig file has both `systemdsystemunitdir` and
`systemd_system_unit_dir` defined.  The non-underscore one appears
to be a deprecated alias[1].  Move to the non-deprecated /
underscore-separated variant.

[1]: https://github.com/systemd/systemd/commit/4908de44b0a0409f84a7cdc5641b114d6ce8ba03

Change-Id: Ie551c0d3549c73c33e31ccb17149d4ad16170adb
Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
1 file changed
tree: d7e7692fea56d1423b6ca9a5f442479e62f12325
  1. subprojects/
  2. test/
  3. .clang-format
  4. .clang-tidy
  5. .editorconfig
  6. .gitignore
  7. .prettierrc.yaml
  8. calculate.cpp
  9. calculate.hpp
  10. dbusSensor.cpp
  11. dbusSensor.hpp
  12. dbusUtils.cpp
  13. dbusUtils.hpp
  14. exprtkTools.hpp
  15. LICENSE
  16. main.cpp
  17. meson.build
  18. meson.options
  19. OWNERS
  20. phosphor-virtual-sensor.service.in
  21. README.md
  22. thresholds.hpp
  23. virtual_sensor_config.json
  24. virtualSensor.cpp
  25. virtualSensor.hpp
README.md

phosphor-virtual-sensor

phosphor-virtual-sensor reads the configuration file virtual_sensor_config.json from one of three locations:

  1. The current directory.
  2. /var/lib/phosphor-virtual-sensor
  3. /usr/share/phosphor-virtual-sensor

By default the repository will install a sample config into (3).

There are two types of data in this file.

virtual sensor configuration information

See virtual_sensor_config.json in this repository for an example. Sensors added this way can use any expression that is accepted by exprtk.

information to get a virtual sensor configuration from D-Bus

For example:

{
  "Desc": {
    "Config": "D-Bus"
  }
}

Sensors added this way can only use a set of restricted calculations. Currently supported types are Average, Maximum, Minimum, Sum and ModifiedMedian.

The virtual sensor configuration information needs to be added into the relevant hardware configuration file in entity-manager. This method of adding a virtual sensor allows a recipe that builds for different hardware configurations to have different virtual sensors for each configuration.

The virtual sensor configuration in entity manager follows a different format to the JSON in virtual_sensor_config.json (specified in entity-manager/schemas/VirtualSensor.json).