blob: 58ee1dcac08ead899accc316070455432f350271 [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 Geisslerea144b032023-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
Andrew Geissler2edf0642023-09-11 08:24:07 -040012# Use fiptool from TF-A v2.9.0
13SRCREV = "d3e71ead6ea5bc3555ac90a446efec84ef6c6122"
14SRCBRANCH = "master"
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}