trustfence-sign-tools: homogenize the sign script filename

The recipe needs to create a copy of the sign.sh script to be used by
other recipes, but the file is the same whether you use it for HAB or AHAB
images. This is determined through the use of an exported variable with
the mode. There is no need to have the script duplicated.

Signed-off-by: Hector Palacios <hector.palacios@digi.com>
This commit is contained in:
Hector Palacios 2020-02-11 18:50:18 +01:00
parent b1776fcc63
commit d21462302d
2 changed files with 2 additions and 3 deletions

View File

@ -212,7 +212,7 @@ do_deploy_append () {
# Sign U-boot image # Sign U-boot image
for ramc in ${RAM_CONFIGS}; do for ramc in ${RAM_CONFIGS}; do
trustfence-sign-ahab-uboot.sh ${DEPLOYDIR}/${UBOOT_PREFIX}-${MACHINE}-${ramc}.bin ${DEPLOYDIR}/${UBOOT_PREFIX}-${MACHINE}-${ramc}-signed.bin trustfence-sign-uboot.sh ${DEPLOYDIR}/${UBOOT_PREFIX}-${MACHINE}-${ramc}.bin ${DEPLOYDIR}/${UBOOT_PREFIX}-${MACHINE}-${ramc}-signed.bin
done done
cd ${DEPLOYDIR} cd ${DEPLOYDIR}

View File

@ -28,15 +28,14 @@ do_install() {
install -d ${D}${bindir}/csf_templates install -d ${D}${bindir}/csf_templates
if [ "${TRUSTFENCE_SIGN_MODE}" = "AHAB" ]; then if [ "${TRUSTFENCE_SIGN_MODE}" = "AHAB" ]; then
install -m 0755 sign_ahab ${D}${bindir}/csf_templates/ install -m 0755 sign_ahab ${D}${bindir}/csf_templates/
install -m 0755 git/scripts/sign.sh ${D}${bindir}/trustfence-sign-ahab-uboot.sh
elif [ "${TRUSTFENCE_SIGN_MODE}" = "HAB" ]; then elif [ "${TRUSTFENCE_SIGN_MODE}" = "HAB" ]; then
install -m 0755 sign_hab ${D}${bindir}/csf_templates/ install -m 0755 sign_hab ${D}${bindir}/csf_templates/
install -m 0755 encrypt_hab ${D}${bindir}/csf_templates/ install -m 0755 encrypt_hab ${D}${bindir}/csf_templates/
install -m 0755 git/scripts/sign.sh ${D}${bindir}/trustfence-sign-uboot.sh
else else
bberror "Unkown TRUSTFENCE_SIGN_MODE value" bberror "Unkown TRUSTFENCE_SIGN_MODE value"
exit 1 exit 1
fi fi
install -m 0755 git/scripts/sign.sh ${D}${bindir}/trustfence-sign-uboot.sh
install -m 0755 trustfence-sign-kernel.sh ${D}${bindir}/ install -m 0755 trustfence-sign-kernel.sh ${D}${bindir}/
install -m 0755 git/scripts/csf_templates/* ${D}${bindir}/csf_templates install -m 0755 git/scripts/csf_templates/* ${D}${bindir}/csf_templates
} }