u-boot: rework deploy symlinks using uboot_deploy_config
Use the existing uboot_deploy(_spl)_config function to clean up and rework the symlinks created in the deploy directory. Signed-off-by: Javier Viguera <javier.viguera@digi.com>
This commit is contained in:
parent
6997b8aa57
commit
b581ac2a3b
|
|
@ -72,7 +72,6 @@ SIGN_UBOOT:ccimx6 = "sign_uboot"
|
||||||
SIGN_UBOOT:ccimx6ul = "sign_uboot"
|
SIGN_UBOOT:ccimx6ul = "sign_uboot"
|
||||||
|
|
||||||
do_deploy[postfuncs] += " \
|
do_deploy[postfuncs] += " \
|
||||||
adapt_uboot_filenames \
|
|
||||||
${@oe.utils.ifelse(d.getVar('BUILD_UBOOT_SCRIPTS') == 'true', 'build_uboot_scripts', '')} \
|
${@oe.utils.ifelse(d.getVar('BUILD_UBOOT_SCRIPTS') == 'true', 'build_uboot_scripts', '')} \
|
||||||
${@oe.utils.conditional('TRUSTFENCE_SIGN', '1', '${SIGN_UBOOT}', '', d)} \
|
${@oe.utils.conditional('TRUSTFENCE_SIGN', '1', '${SIGN_UBOOT}', '', d)} \
|
||||||
"
|
"
|
||||||
|
|
@ -140,29 +139,31 @@ build_uboot_scripts() {
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
adapt_uboot_filenames() {
|
#
|
||||||
# Remove canonical U-Boot symlinks for ${UBOOT_CONFIG} currently in the form:
|
# Clean Yocto generated u-boot symlinks.
|
||||||
# u-boot-<platform>.<ext>-<type>
|
#
|
||||||
# u-boot-<type>
|
# Left:
|
||||||
# and add a more suitable symlink in the form:
|
# u-boot-<defconfig>.<ext>
|
||||||
# u-boot-<platform>-<config>.<ext>
|
# u-boot-<platform>.<ext>-<defconfig> (needed for imx-boot)
|
||||||
if [ -n "${UBOOT_CONFIG}" ]
|
# u-boot-spl.bin-<platform>-<defconfig> (needed for imx-boot)
|
||||||
then
|
#
|
||||||
for config in ${UBOOT_MACHINE}; do
|
uboot_deploy_config:append() {
|
||||||
i=$(expr $i + 1);
|
rm -f ${DEPLOYDIR}/${UBOOT_SYMLINK} \
|
||||||
for type in ${UBOOT_CONFIG}; do
|
${DEPLOYDIR}/${UBOOT_BINARY}-${type} \
|
||||||
j=$(expr $j + 1);
|
${DEPLOYDIR}/${UBOOT_BINARY}
|
||||||
if [ $j -eq $i ]
|
ln -sf ${UBOOT_BINARYNAME}-${type}-${PV}-${PR}.${UBOOT_SUFFIX} ${DEPLOYDIR}/${UBOOT_BINARYNAME}-${type}.${UBOOT_SUFFIX}
|
||||||
then
|
}
|
||||||
cd ${DEPLOYDIR}
|
uboot_deploy_spl_config:append() {
|
||||||
rm -f ${UBOOT_BINARY}-${type}
|
rm -f ${DEPLOYDIR}/${SPL_BINARYFILE}-${type} \
|
||||||
ln -sf ${UBOOT_BINARYNAME}-${type}-${PV}-${PR}.${UBOOT_SUFFIX} ${UBOOT_BINARYNAME}-${type}.${UBOOT_SUFFIX}
|
${DEPLOYDIR}/${SPL_BINARYFILE} \
|
||||||
fi
|
${DEPLOYDIR}/${SPL_SYMLINK}
|
||||||
done
|
}
|
||||||
unset j
|
# Further cleaning for platforms not generating imx-boot
|
||||||
done
|
uboot_deploy_config:append:ccimx6ul() {
|
||||||
unset i
|
rm -f ${DEPLOYDIR}/${UBOOT_SYMLINK}-${type}
|
||||||
fi
|
}
|
||||||
|
uboot_deploy_spl_config:append:ccimx6ul() {
|
||||||
|
rm -f ${DEPLOYDIR}/${SPL_SYMLINK}-${type}
|
||||||
}
|
}
|
||||||
|
|
||||||
sign_uboot() {
|
sign_uboot() {
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue