1# Each platform will need a service file that starts
2# at an appropriate time per system.  For instance, if
3# your system relies on passive dbus for fans or other
4# sensors then it may be prudent to wait for all of them.
5SUMMARY = "Phosphor PID Fan Control"
6DESCRIPTION = "Fan Control"
7HOMEPAGE = "github.com/openbmc/phosphor-pid-control"
8LICENSE = "Apache-2.0"
9LIC_FILES_CHKSUM = "file://LICENSE;md5=86d3f3a95c324c9479bd8986968f4327"
10DEPENDS += "autoconf-archive-native"
11DEPENDS += "sdbusplus"
12DEPENDS += "phosphor-dbus-interfaces"
13DEPENDS += "phosphor-logging"
14DEPENDS += "libevdev"
15DEPENDS += "nlohmann-json"
16DEPENDS += "cli11"
17DEPENDS += "boost"
18# We depend on this to be built first so we can build our providers.
19DEPENDS += "phosphor-ipmi-host"
20SRCREV = "9f1532dd04caabd87a9e70e3dbdea2f3a4ba09b8"
21PV = "0.1+git${SRCPV}"
22PR = "r1"
23
24SRC_URI = "git://github.com/openbmc/phosphor-pid-control;branch=master;protocol=https"
25
26S = "${WORKDIR}/git"
27SERVICE_FILE = "phosphor-pid-control.service"
28SYSTEMD_PACKAGES = "${PN}"
29SYSTEMD_SERVICE:${PN} = "${SERVICE_FILE}"
30
31inherit meson pkgconfig
32inherit obmc-phosphor-ipmiprovider-symlink
33inherit systemd
34
35EXTRA_OEMESON = " \
36  -Dtests=disabled \
37  -Dsystemd_target="multi-user.target" \
38  "
39
40FILES:${PN} = "${bindir}/swampd ${bindir}/setsensor"
41# The following installs the OEM IPMI handler for the fan controls.
42FILES:${PN}:append = " ${libdir}/ipmid-providers/lib*${SOLIBS}"
43FILES:${PN}:append = " ${libdir}/host-ipmid/lib*${SOLIBS}"
44FILES:${PN}:append = " ${libdir}/net-ipmid/lib*${SOLIBS}"
45FILES:${PN}-dev:append = " ${libdir}/ipmid-providers/lib*${SOLIBSDEV} ${libdir}/ipmid-providers/*.la"
46
47HOSTIPMI_PROVIDER_LIBRARY += "libmanualcmds.so"
48config_datadir = "${datadir}/swampd/"
49# config_path is the location swampd expects to find a json configuration.
50# the file is expected to be named config.json
51config_path = "${config_datadir}config.json"
52