kernel-fitimage: unbreak UBOOT_ENTRYSYMBOL support

- vmlinux is located in ${B}, not ${S}.
- parsing of nm output got broken completely in commit
  b406a89935f148779569fa3770776e009dd51f13 ("kernel-fitimage: add
  initramfs support"), commit ec755d2524
  in yocto

While at it, make awk exit on match to save a few CPU cycles.

(From OE-Core rev: 1353892f3a130bcfa4e9c5b36b3ed7eb4a2c872d)

Signed-off-by: André Draszik <adraszik@tycoint.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>

(cherry picked from commit 9d2ec9c046c4a9c6a842d28133d40639f5a65297)
Signed-off-by: André Draszik <adraszik@tycoint.com>
Signed-off-by: Armin Kuster <akuster808@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
André Draszik 2017-10-06 13:12:54 +01:00 committed by Richard Purdie
parent 637fec385a
commit 01e24eb47b
1 changed files with 2 additions and 2 deletions

View File

@ -97,8 +97,8 @@ fitimage_emit_section_kernel() {
ENTRYPOINT=${UBOOT_ENTRYPOINT}
if [ -n "${UBOOT_ENTRYSYMBOL}" ]; then
ENTRYPOINT=`${HOST_PREFIX}nm ${S}/vmlinux | \
awk '$4=="${UBOOT_ENTRYSYMBOL}" {print $2}'`
ENTRYPOINT=`${HOST_PREFIX}nm vmlinux | \
awk '$3=="${UBOOT_ENTRYSYMBOL}" {print "0x"$1;exit}'`
fi
cat << EOF >> ${1}