From 14826f628f4ecd5c2e87b156a04b1fa884bba255 Mon Sep 17 00:00:00 2001 From: osm0sis Date: Sat, 24 Mar 2018 11:31:39 -0300 Subject: [PATCH] AK2: fix elftool repack of ELF without cmdline --- tools/ak2-core.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tools/ak2-core.sh b/tools/ak2-core.sh index 6fe29be..8d51287 100755 --- a/tools/ak2-core.sh +++ b/tools/ak2-core.sh @@ -169,6 +169,7 @@ flash_boot() { else if [ -f *-cmdline ]; then cmdline=`cat *-cmdline`; + cmd="$split_img/boot.img-cmdline@cmdline"; fi; if [ -f *-board ]; then board=`cat *-board`; @@ -240,7 +241,7 @@ flash_boot() { test "$type" == "Multi" && uramdisk=":$rd"; $bin/mkimage -A $arch -O $os -T $type -C $comp -a $addr -e $ep -n "$name" -d $kernel$uramdisk boot-new.img; elif [ -f "$bin/elftool" ]; then - $bin/elftool pack -o boot-new.img header=$split_img/boot.img-header $kernel $rd,ramdisk $rpm $split_img/boot.img-cmdline@cmdline; + $bin/elftool pack -o boot-new.img header=$split_img/boot.img-header $kernel $rd,ramdisk $rpm $cmd; elif [ -f "$bin/rkcrc" ]; then $bin/rkcrc -k $rd boot-new.img; elif [ -f "$bin/pxa-mkbootimg" ]; then