meta-arm: optee-ftpm: optee-os: correct EARLY_TA_PATHS in EXTRA_OEMAKE
There is build failure about stripped.elf file cannot found from
EARLY_TA_PATHS definition.
Build error snapshot log as below:
make: *** No rule to make target '/home/tim/openbmc/build/evb-npcm845/
tmp/work/evb_npcm845-openbmc-linux/optee-os/3.20.0-r0/recipe-sysroot/
/usr/lib/optee_armtz/bc50d971-d4c9-42c4-82cb-343fb7f37896.stripped.elf'
needed by '/home/tim/openbmc/build/evb-npcm845/tmp/work/
evb_npcm845-openbmc-linux/optee-os/3.20.0-r0/build/core/
early_ta_bc50d971-d4c9-42c4-82cb-343fb7f37896.c'. Stop.
We should use ${nonarch_base_libdir} instead hardcode /lib to avoid
this kind of build failure.
Tested:
Build the latest optee-os recipe pass without this build failure.
NOTE: make -j 6 V=1 LIBGCC_LOCATE_CFLAGS= -mcpu=cortex-a35
EARLY_TA_PATHS=/home/tim/openbmc/build/evb-npcm845/tmp/work/
evb_npcm845-openbmc-linux/optee-os/3.20.0-r0/recipe-sysroot/
/lib/optee_armtz/bc50d971-d4c9-42c4-82cb-343fb7f37896.stripped.elf
Signed-off-by: Tim Lee <timlee660101@gmail.com>
Change-Id: I146ae0a015090c0970bdde6999f95b6a50b79b55
diff --git a/meta-arm/meta-arm/recipes-security/optee-ftpm/optee-os_%.bbappend b/meta-arm/meta-arm/recipes-security/optee-ftpm/optee-os_%.bbappend
index 4042361..f1165da 100644
--- a/meta-arm/meta-arm/recipes-security/optee-ftpm/optee-os_%.bbappend
+++ b/meta-arm/meta-arm/recipes-security/optee-ftpm/optee-os_%.bbappend
@@ -10,6 +10,6 @@
EXTRA_OEMAKE:append = "\
${@bb.utils.contains('MACHINE_FEATURES', \
'optee-ftpm', \
- 'CFG_EARLY_TA=y EARLY_TA_PATHS="${STAGING_DIR_TARGET}/lib/optee_armtz/${FTPM_UUID}.stripped.elf"', \
+ 'CFG_EARLY_TA=y EARLY_TA_PATHS="${STAGING_DIR_TARGET}/${nonarch_base_libdir}/optee_armtz/${FTPM_UUID}.stripped.elf"', \
'', \
d)} "