blob: 53f7f8ce6e6aedce1b7f559bcc32740ffb5734c7 [file] [log] [blame]
Karthikeyan Pasupathi36f035b2022-08-28 17:35:29 +05301FILESEXTRAPATHS:prepend := "${THISDIR}/${PN}:"
2
Karthikeyan Pasupathi60e2e532023-01-20 19:54:43 +05303DEFAULT_TARGETS:append = " \
Karthikeyan Pasupathi36f035b2022-08-28 17:35:29 +05304 obmc-chassis-poweron@{}.target.wants/chassis-poweron@{}.service \
5 obmc-chassis-hard-poweroff@{}.target.wants/chassis-poweroff@{}.service \
6 obmc-host-shutdown@{}.target.wants/host-poweroff@{}.service \
7 obmc-host-start@{}.target.wants/host-poweron@{}.service \
8 obmc-host-reboot@{}.target.wants/host-powercycle@{}.service \
9"
Karthikeyan Pasupathi60e2e532023-01-20 19:54:43 +053010DEFAULT_TARGETS:remove = " \
11 obmc-chassis-poweroff@{}.target.requires/obmc-powered-off@{}.service \
12"
Karthikeyan Pasupathi36f035b2022-08-28 17:35:29 +053013
14SRC_URI:append:greatlakes = " \
15 file://chassis-poweroff@.service \
16 file://chassis-poweron@.service \
17 file://host-poweroff@.service \
18 file://host-poweron@.service \
19 file://host-powercycle@.service \
20 file://chassis-poweroff \
21 file://chassis-poweron \
22 file://host-poweroff \
23 file://host-poweron \
24 file://host-powercycle \
25 file://power-cmd \
26 "
27
28RDEPENDS:${PN}:append:greatlakes = " bash"
29
30do_install:append:greatlakes() {
31 install -d ${D}${systemd_system_unitdir}
32 install -m 0644 ${WORKDIR}/*.service ${D}${systemd_system_unitdir}/
33
34 install -d ${D}${libexecdir}
35 install -m 0777 ${WORKDIR}/chassis-poweroff ${D}${libexecdir}/
36 install -m 0777 ${WORKDIR}/chassis-poweron ${D}${libexecdir}/
37 install -m 0777 ${WORKDIR}/host-poweroff ${D}${libexecdir}/
38 install -m 0777 ${WORKDIR}/host-poweron ${D}${libexecdir}/
39 install -m 0777 ${WORKDIR}/host-powercycle ${D}${libexecdir}/
40 install -m 0777 ${WORKDIR}/power-cmd ${D}${libexecdir}/
41}
42FILES:${PN} += " /lib/systemd/system/*.service"