summaryrefslogtreecommitdiff
path: root/classes/kernel.bbclass
diff options
context:
space:
mode:
Diffstat (limited to 'classes/kernel.bbclass')
-rw-r--r--classes/kernel.bbclass11
1 files changed, 7 insertions, 4 deletions
diff --git a/classes/kernel.bbclass b/classes/kernel.bbclass
index a936e4deff..06ae2466ea 100644
--- a/classes/kernel.bbclass
+++ b/classes/kernel.bbclass
@@ -5,6 +5,8 @@ DEPENDS += "virtual/${TARGET_PREFIX}depmod-${@get_kernelmajorversion('${PV}')} v
KERNEL_IMAGETYPE ?= "zImage"
+# Add dependency on mkimage for kernels that build a uImage
+
python __anonymous () {
import bb
@@ -12,7 +14,7 @@ python __anonymous () {
kerneltype = bb.data.getVar('KERNEL_IMAGETYPE', d, 1) or ''
if kerneltype == 'uImage':
depends = bb.data.getVar("DEPENDS", d, 1)
- depends = "%s u-boot-mkimage-native" % depends
+ depends = "%s u-boot-mkimage-openmoko-native" % depends
bb.data.setVar("DEPENDS", depends, d)
}
@@ -61,6 +63,7 @@ PACKAGE_ARCH = "${MACHINE_ARCH}"
# U-Boot support
UBOOT_ENTRYPOINT ?= "20008000"
+UBOOT_LOADADDRESS ?= "${UBOOT_ENTRYPOINT}"
kernel_do_compile() {
unset CFLAGS CPPFLAGS CXXFLAGS LDFLAGS MACHINE
@@ -472,16 +475,16 @@ do_deploy() {
if test "x${KERNEL_IMAGETYPE}" = "xuImage" ; then
if test -e arch/${ARCH}/boot/compressed/vmlinux ; then
${OBJCOPY} -O binary -R .note -R .comment -S arch/${ARCH}/boot/compressed/vmlinux linux.bin
- uboot-mkimage -A ${ARCH} -O linux -T kernel -C none -a ${UBOOT_ENTRYPOINT} -e ${UBOOT_ENTRYPOINT} -n "${DISTRO_NAME}/${PV}/${MACHINE}" -d linux.bin ${DEPLOY_DIR_IMAGE}/uImage-${PV}-${PR}-${MACHINE}-${DATETIME}.bin
+ uboot-mkimage -A ${ARCH} -O linux -T kernel -C none -a ${UBOOT_LOADADDRESS} -e ${UBOOT_ENTRYPOINT} -n "${DISTRO_NAME}/${PV}/${MACHINE}" -d linux.bin ${DEPLOY_DIR_IMAGE}/uImage-${PV}-${PR}-${MACHINE}.bin
rm -f linux.bin
else
${OBJCOPY} -O binary -R .note -R .comment -S vmlinux linux.bin
rm -f linux.bin.gz
gzip -9 linux.bin
- uboot-mkimage -A ${ARCH} -O linux -T kernel -C gzip -a ${UBOOT_ENTRYPOINT} -e ${UBOOT_ENTRYPOINT} -n "${DISTRO_NAME}/${PV}/${MACHINE}" -d linux.bin.gz ${DEPLOY_DIR_IMAGE}/uImage-${PV}-${PR}-${MACHINE}-${DATETIME}.bin
+ uboot-mkimage -A ${ARCH} -O linux -T kernel -C gzip -a ${UBOOT_LOADADDRESS} -e ${UBOOT_ENTRYPOINT} -n "${DISTRO_NAME}/${PV}/${MACHINE}" -d linux.bin.gz ${DEPLOY_DIR_IMAGE}/uImage-${PV}-${PR}-${MACHINE}.bin
rm -f linux.bin.gz
fi
- package_stagefile_shell ${DEPLOY_DIR_IMAGE}/uImage-${PV}-${PR}-${MACHINE}-${DATETIME}.bin
+ package_stagefile_shell ${DEPLOY_DIR_IMAGE}/uImage-${PV}-${PR}-${MACHINE}.bin
fi
cd ${DEPLOY_DIR_IMAGE}