summaryrefslogtreecommitdiff
path: root/meta-openbmc-mods/meta-common/recipes-core/fw-update/intel-fw-update.bb
blob: df7d6e7f1c47b351b83ec375b6b9756c3889dbd9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
SUMMARY = "Temporary intel-fw-update script"
DESCRIPTION = "At runtime, perform a firmware update and reboot"
PR = "r1"

# flash_eraseall
RDEPENDS:intel-fw-update += "mtd-utils"
# wget tftp scp
RDEPENDS:intel-fw-update += "busybox dropbear"
# mkfs.vfat, parted
RDEPENDS:intel-fw-update += "dosfstools dtc"

RDEPENDS:intel-fw-update += "bash"

LICENSE = "Apache-2.0"
LIC_FILES_CHKSUM = "file://${INTELBASE}/COPYING.apache-2.0;md5=34400b68072d710fecd0a2940a0d1658"
PFR_EN = "${@bb.utils.contains('IMAGE_FSTYPES', 'intel-pfr', 'pfr', '', d)}"

SRC_URI += "file://fwupd.sh"
SRC_URI += "file://usb-ctrl"

FILES:${PN} += "${@bb.utils.contains('IMAGE_FSTYPES', 'intel-pfr', '${datadir}/pfr', '', d)}"

do_install() {
        install -d ${D}${bindir}
        install -m 0755 ${WORKDIR}/fwupd.sh ${D}${bindir}
        install -m 0755 ${WORKDIR}/usb-ctrl ${D}${bindir}

        if [ "${PFR_EN}" = "pfr" ]; then
            install -d ${D}${datadir}
            touch ${D}${datadir}/pfr
        fi
}