summaryrefslogtreecommitdiffstats
path: root/recipes-bsp/u-boot
diff options
context:
space:
mode:
authorTing Liu <b28495@freescale.com>2013-10-29 16:58:23 +0800
committerZhenhua Luo <zhenhua.luo@freescale.com>2014-01-12 18:06:01 +0800
commitd4888b46bf3fd312e5c44f7f3e9022c55642e699 (patch)
treee95c98faf060b5028471231d42695240ee492b75 /recipes-bsp/u-boot
parente9f93d1adf0e36c0d90aef487a45177fd47daa8d (diff)
downloadmeta-fsl-ppc-d4888b46bf3fd312e5c44f7f3e9022c55642e699.tar.gz
u-boot: simplify the compile steps
Signed-off-by: Ting Liu <b28495@freescale.com>
Diffstat (limited to 'recipes-bsp/u-boot')
-rw-r--r--recipes-bsp/u-boot/u-boot_git.bb31
1 files changed, 14 insertions, 17 deletions
diff --git a/recipes-bsp/u-boot/u-boot_git.bb b/recipes-bsp/u-boot/u-boot_git.bb
index f4f2dca..bfd2d79 100644
--- a/recipes-bsp/u-boot/u-boot_git.bb
+++ b/recipes-bsp/u-boot/u-boot_git.bb
@@ -77,26 +77,23 @@ do_compile () {
77 *) UBOOT_TARGET="";; 77 *) UBOOT_TARGET="";;
78 esac 78 esac
79 79
80 # deal with sd/spi/nand image
81 UBOOT_SOURCE=u-boot
80 if [ "x${UBOOT_TARGET}" != "x" ]; then 82 if [ "x${UBOOT_TARGET}" != "x" ]; then
81 if [ "${UBOOT_TARGET}" = "u-boot-sd" ]; then 83 # some boards' nand image was named as u-boot-with-spl
82 cp ${S}/${board}/u-boot.bin ${S}/${board}/${UBOOT_TARGET}.bin 84 if [ "${UBOOT_TARGET}" = "u-boot-nand" ];then
83 elif [ "${UBOOT_TARGET}" = "u-boot-nand" ];then 85 if echo $board |egrep -q "(P1010RDB|P1020RDB|P1021RDB|P1024RDB|P2020RDB|P1022DS|P1025RDB|BSC913)";then
84 if [ "${DEFAULTTUNE}" = "ppce500v2" ];then 86 UBOOT_SOURCE=u-boot-with-spl
85 if echo $board |egrep -q "(P1010RDB|P1020RDB|P1021RDB|P1024RDB|P2020RDB|P1022DS|P1025RDB|BSC9131)";then
86 cp ${S}/${board}/u-boot-with-spl.bin ${S}/${board}/${UBOOT_TARGET}.bin
87 fi
88 else
89 cp ${S}/${board}/u-boot.bin ${S}/${board}/${UBOOT_TARGET}.bin
90 fi
91 else
92 if [ -n "${BOOTFORMAT_CONFIG}" ];then
93 ${STAGING_BINDIR_NATIVE}/boot_format \
94 ${STAGING_DATADIR_NATIVE}/boot_format/${BOOTFORMAT_CONFIG} \
95 ${S}/${board}/u-boot.bin -spi ${S}/${board}/${UBOOT_TARGET}.bin
96 else
97 cp ${S}/${board}/u-boot.bin ${S}/${board}/${UBOOT_TARGET}.bin
98 fi 87 fi
99 fi 88 fi
89 cp ${S}/${board}/${UBOOT_SOURCE}.bin ${S}/${board}/${UBOOT_TARGET}.bin
90
91 # use boot-format to regenerate spi image if BOOTFORMAT_CONFIG is not empty
92 if [ "${UBOOT_TARGET}" = "u-boot-spi" ] && [ -n "${BOOTFORMAT_CONFIG}" ];then
93 ${STAGING_BINDIR_NATIVE}/boot_format \
94 ${STAGING_DATADIR_NATIVE}/boot_format/${BOOTFORMAT_CONFIG} \
95 ${S}/${board}/${UBOOT_SOURCE}.bin -spi ${S}/${board}/${UBOOT_TARGET}.bin
96 fi
100 fi 97 fi
101 done 98 done
102} 99}