| SUMMARY = "gBMC System Initialization Service" |
| DESCRIPTION = "Verify the BIOS and release initalize the system" |
| PR = "r1" |
| LICENSE = "Apache-2.0" |
| LIC_FILES_CHKSUM = "file://${COREBASE}/meta/files/common-licenses/Apache-2.0;md5=89aea4e17d99a7cacdbeed46a0096b10" |
| |
| S = "${WORKDIR}" |
| |
| inherit systemd |
| |
| DEPENDS = "systemd" |
| RDEPENDS:${PN} = " \ |
| bash \ |
| libsystemd \ |
| " |
| |
| BIOS_PARTITION ?= "bios-primary" |
| BIOS_SIZE ?= "67108864" |
| BIOS_KEY ?= "/usr/share/google-bios-key/platforms_secure.pem" |
| |
| SRC_URI = " \ |
| file://gbmc_sysinit.sh.in \ |
| file://gbmc_sysinit_helper.sh \ |
| file://gbmc-host-ready.target \ |
| file://gbmc-sysinit.service \ |
| " |
| |
| SYSTEMD_PACKAGES = "${PN}" |
| SYSTEMD_SERVICE:${PN}:append = " \ |
| gbmc-sysinit.service \ |
| gbmc-host-ready.target \ |
| " |
| |
| do_install () { |
| sed ${WORKDIR}/gbmc_sysinit.sh.in \ |
| -e "s#@BIOS_PARTITION@#${BIOS_PARTITION}#" \ |
| -e "s#@BIOS_SIZE@#${BIOS_SIZE}#" \ |
| -e "s#@BIOS_KEY@#${BIOS_KEY}#" \ |
| > ${WORKDIR}/gbmc_sysinit.sh |
| |
| install -d ${D}${bindir} |
| install -m 0755 ${WORKDIR}/gbmc_sysinit.sh ${D}${bindir}/ |
| |
| install -d ${D}${systemd_unitdir}/system/ |
| install -m 0644 ${WORKDIR}/gbmc-sysinit.service ${D}${systemd_unitdir}/system |
| install -m 0644 ${WORKDIR}/gbmc-host-ready.target ${D}${systemd_unitdir}/system |
| |
| install -d ${D}${datadir}/gbmc-sysinit |
| install -m 0755 ${WORKDIR}/gbmc_sysinit_helper.sh ${D}${datadir}/gbmc-sysinit/ |
| } |