blob: 02f338739669d279310ece7c87dfb599430e5e52 [file] [log] [blame]
Brad Bishopbec4ebc2022-08-03 09:55:16 -04001# Firmware Image Package (FIP)
2# It is a packaging format used by TF-A to package the
3# firmware images in a single binary.
4
5DESCRIPTION = "fiptool - Trusted Firmware tool for packaging"
6LICENSE = "BSD-3-Clause"
7
Andrew Geisslerea144b02023-01-27 16:03:57 -06008SRC_URI_TRUSTED_FIRMWARE_A ?= "git://git.trustedfirmware.org/TF-A/trusted-firmware-a.git;protocol=https"
9SRC_URI = "${SRC_URI_TRUSTED_FIRMWARE_A};destsuffix=fiptool-${PV};branch=${SRCBRANCH}"
Brad Bishopbec4ebc2022-08-03 09:55:16 -040010LIC_FILES_CHKSUM = "file://docs/license.rst;md5=b2c740efedc159745b9b31f88ff03dde"
11
Patrick Williams520786c2023-06-25 16:20:36 -050012# Use fiptool from TF-A v2.8.6
13SRCREV = "ff0bd5f9bb2ba2f31fb9cec96df917747af9e92d"
14SRCBRANCH = "lts-v2.8"
Brad Bishopbec4ebc2022-08-03 09:55:16 -040015
16DEPENDS += "openssl-native"
17
18inherit native
19
20EXTRA_OEMAKE = "V=1 HOSTCC='${BUILD_CC}' OPENSSL_DIR=${STAGING_DIR_NATIVE}/${prefix_native}"
21
22do_compile () {
23 # This is still needed to have the native fiptool executing properly by
24 # setting the RPATH
25 sed -i '/^LDLIBS/ s,$, \$\{BUILD_LDFLAGS},' ${S}/tools/fiptool/Makefile
26 sed -i '/^INCLUDE_PATHS/ s,$, \$\{BUILD_CFLAGS},' ${S}/tools/fiptool/Makefile
27
28 oe_runmake fiptool
29}
30
31do_install () {
32 install -D -p -m 0755 tools/fiptool/fiptool ${D}${bindir}/fiptool
33}