blob: 66cf2ced37360e6503115bc3bbca72a3adb7efb5 [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}"
10SRCBRANCH = "master"
Brad Bishopbec4ebc2022-08-03 09:55:16 -040011LIC_FILES_CHKSUM = "file://docs/license.rst;md5=b2c740efedc159745b9b31f88ff03dde"
12
13# Use fiptool from TF-A v2.7
14SRCREV = "35f4c7295bafeb32c8bcbdfb6a3f2e74a57e732b"
15
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}