blob: 59bb0b98309bb94c9799d79809c3bf547e735ef2 [file] [log] [blame]
Brad Bishopb1e88402017-01-11 11:12:32 -05001SUMMARY = "OpenBMC hwmon poller"
2DESCRIPTION = "OpenBMC hwmon poller."
3PR = "r1"
Patrick Venturebc174e62018-10-01 20:22:40 -07004PV = "1.0+git${SRCPV}"
Brad Bishopb1e88402017-01-11 11:12:32 -05005LICENSE = "Apache-2.0"
6LIC_FILES_CHKSUM = "file://LICENSE;md5=fa818a259cbed7ce8bc2a22d35a464fc"
7
Matt Spinlerc15c7532021-04-14 14:52:53 -05008inherit meson pkgconfig
Patrick Venturebc174e62018-10-01 20:22:40 -07009inherit obmc-phosphor-systemd
Brad Bishop4186efb2017-01-11 15:30:07 -050010
Matthew Barth3afbeed2020-11-17 08:45:59 -060011PACKAGECONFIG ??= ""
Matt Spinlerc15c7532021-04-14 14:52:53 -050012PACKAGECONFIG[max31785-msl] = "-Denable-max31785-msl=true, -Denable-max31785-msl=false"
Matthew Barth3afbeed2020-11-17 08:45:59 -060013
Brad Bishop4ce57192017-08-01 21:33:30 -040014PACKAGE_BEFORE_PN = "max31785-msl"
15SYSTEMD_PACKAGES = "${PN} max31785-msl"
16
Brad Bishop4186efb2017-01-11 15:30:07 -050017SYSTEMD_SERVICE_${PN} = "xyz.openbmc_project.Hwmon@.service"
Matthew Barth3afbeed2020-11-17 08:45:59 -060018SYSTEMD_SERVICE_max31785-msl = "${@bb.utils.contains('PACKAGECONFIG', 'max31785-msl', 'phosphor-max31785-msl@.service', '', d)}"
Brad Bishopb1e88402017-01-11 11:12:32 -050019
20DEPENDS += "autoconf-archive-native"
Brad Bishop6d105112017-02-20 14:36:31 -050021DEPENDS += " \
22 sdbusplus \
William A. Kennington III4e10c562018-10-18 19:23:49 -070023 sdeventplus \
Patrick Venture6e2600f2020-05-21 08:32:30 -070024 stdplus \
Brad Bishop6d105112017-02-20 14:36:31 -050025 phosphor-dbus-interfaces \
26 phosphor-logging \
Patrick Venturef67ce692018-09-14 09:54:18 -070027 gpioplus \
Patrick Venture806405f2019-03-11 14:06:11 -070028 cli11 \
Brad Bishop6d105112017-02-20 14:36:31 -050029 "
30
Brad Bishopb1e88402017-01-11 11:12:32 -050031
32RDEPENDS_${PN} += "\
Joel Stanley1c7e17d2017-09-05 17:44:33 +100033 bash \
Brad Bishopb1e88402017-01-11 11:12:32 -050034 "
35
Brad Bishop3217b272017-02-22 20:50:13 -050036RRECOMMENDS_${PN} += "${VIRTUAL-RUNTIME_phosphor-hwmon-config}"
37
Brad Bishop4ce57192017-08-01 21:33:30 -040038FILES_max31785-msl = "${bindir}/max31785-msl"
Andrew Geisslerdb32d492021-04-14 13:31:40 +000039RDEPENDS_max31785-msl = "${VIRTUAL-RUNTIME_base-utils} i2c-tools bash"
Brad Bishop4ce57192017-08-01 21:33:30 -040040
Brad Bishopb1e88402017-01-11 11:12:32 -050041SRC_URI += "git://github.com/openbmc/phosphor-hwmon"
Brad Bishop4186efb2017-01-11 15:30:07 -050042SRC_URI += "file://70-hwmon.rules"
Brandon Wyman7cae3ea2017-06-21 16:32:56 -050043SRC_URI += "file://70-iio.rules"
Joel Stanley1c7e17d2017-09-05 17:44:33 +100044SRC_URI += "file://start_hwmon.sh"
Brad Bishopb1e88402017-01-11 11:12:32 -050045
Andrew Geissler78970272021-05-06 22:11:07 +000046SRCREV = "5b520cf494ad65be2d336f60ee622efc456c2e3f"
Brad Bishopb1e88402017-01-11 11:12:32 -050047
48S = "${WORKDIR}/git"
Brad Bishop4186efb2017-01-11 15:30:07 -050049
50do_install_append() {
51
Brad Bishop2b9921e2017-01-26 09:12:57 -050052 install -d ${D}/${base_libdir}/udev/rules.d/
Brad Bishopb09e0092019-11-14 14:37:51 -050053 install -m 0644 ${WORKDIR}/70-hwmon.rules ${D}/${base_libdir}/udev/rules.d/
54 install -m 0644 ${WORKDIR}/70-iio.rules ${D}/${base_libdir}/udev/rules.d/
Joel Stanley1c7e17d2017-09-05 17:44:33 +100055
56 install -d ${D}${bindir}
57 install -m 0755 ${WORKDIR}/start_hwmon.sh ${D}${bindir}
Brad Bishop4186efb2017-01-11 15:30:07 -050058}