blob: 00fc1fd59692b14554c1b652bb7b358450062902 [file] [log] [blame]
Adriana Kobylak4e70c3c2019-09-09 15:49:09 -05001SUMMARY = "OpenPOWER Host Firmware Image"
2DESCRIPTION = "Adds the OpenPOWER Host Firmware image to the BMC image"
3PR = "r1"
4
5inherit allarch
6
7HOST_FW_LICENSE ?= "Apache-2.0"
8HOST_FW_LIC_FILES_CHKSUM ?= "file://${COREBASE}/meta/files/common-licenses/Apache-2.0;md5=89aea4e17d99a7cacdbeed46a0096b10"
9HOST_FW_SRC_URI ?= ""
10
11LICENSE = "${HOST_FW_LICENSE}"
12LIC_FILES_CHKSUM = "${HOST_FW_LIC_FILES_CHKSUM}"
13SRC_URI = "${HOST_FW_SRC_URI}"
14
15DEPENDS = "squashfs-tools-native"
16
17S = "${WORKDIR}"
18B = "${WORKDIR}/build"
19do_compile[cleandirs] = "${B}"
20
21do_compile() {
22 if [ -n "${HOST_FW_SRC_URI}" ]; then
23 unsquashfs -d ${B}/squashfs-root ${S}/pnor.xz.squashfs
24 fi
25}
26
27do_install() {
28 install -d ${D}${datadir}/${BPN}
29
30 if [ -n "${HOST_FW_SRC_URI}" ]; then
31 install -m 0440 ${B}/squashfs-root/* ${D}${datadir}/${BPN}
32 fi
33}