diff options
Diffstat (limited to 'meta/classes/kernel-uimage.bbclass')
| -rw-r--r-- | meta/classes/kernel-uimage.bbclass | 41 |
1 files changed, 0 insertions, 41 deletions
diff --git a/meta/classes/kernel-uimage.bbclass b/meta/classes/kernel-uimage.bbclass deleted file mode 100644 index 1a599e656c..0000000000 --- a/meta/classes/kernel-uimage.bbclass +++ /dev/null | |||
| @@ -1,41 +0,0 @@ | |||
| 1 | # | ||
| 2 | # Copyright OpenEmbedded Contributors | ||
| 3 | # | ||
| 4 | # SPDX-License-Identifier: MIT | ||
| 5 | # | ||
| 6 | |||
| 7 | inherit kernel-uboot | ||
| 8 | |||
| 9 | python __anonymous () { | ||
| 10 | if "uImage" in d.getVar('KERNEL_IMAGETYPES'): | ||
| 11 | depends = d.getVar("DEPENDS") | ||
| 12 | depends = "%s u-boot-tools-native" % depends | ||
| 13 | d.setVar("DEPENDS", depends) | ||
| 14 | |||
| 15 | # Override KERNEL_IMAGETYPE_FOR_MAKE variable, which is internal | ||
| 16 | # to kernel.bbclass . We override the variable here, since we need | ||
| 17 | # to build uImage using the kernel build system if and only if | ||
| 18 | # KEEPUIMAGE == yes. Otherwise, we pack compressed vmlinux into | ||
| 19 | # the uImage . | ||
| 20 | if d.getVar("KEEPUIMAGE") != 'yes': | ||
| 21 | typeformake = d.getVar("KERNEL_IMAGETYPE_FOR_MAKE") or "" | ||
| 22 | if "uImage" in typeformake.split(): | ||
| 23 | d.setVar('KERNEL_IMAGETYPE_FOR_MAKE', typeformake.replace('uImage', 'vmlinux')) | ||
| 24 | |||
| 25 | # Enable building of uImage with mkimage | ||
| 26 | bb.build.addtask('do_uboot_mkimage', 'do_install', 'do_kernel_link_images', d) | ||
| 27 | } | ||
| 28 | |||
| 29 | do_uboot_mkimage[dirs] += "${B}" | ||
| 30 | do_uboot_mkimage() { | ||
| 31 | uboot_prep_kimage | ||
| 32 | |||
| 33 | ENTRYPOINT=${UBOOT_ENTRYPOINT} | ||
| 34 | if [ -n "${UBOOT_ENTRYSYMBOL}" ]; then | ||
| 35 | ENTRYPOINT=`${HOST_PREFIX}nm ${B}/vmlinux | \ | ||
| 36 | awk '$3=="${UBOOT_ENTRYSYMBOL}" {print "0x"$1;exit}'` | ||
| 37 | fi | ||
| 38 | |||
| 39 | uboot-mkimage -A ${UBOOT_ARCH} -O linux -T ${UBOOT_MKIMAGE_KERNEL_TYPE} -C "${linux_comp}" -a ${UBOOT_LOADADDRESS} -e $ENTRYPOINT -n "${DISTRO_NAME}/${PV}/${MACHINE}" -d linux.bin ${B}/arch/${ARCH}/boot/uImage | ||
| 40 | rm -f linux.bin | ||
| 41 | } | ||
