aboutsummaryrefslogtreecommitdiffstats
path: root/classes
diff options
context:
space:
mode:
authorOpenEmbedded Project <openembedded-devel@lists.openembedded.org>2008-06-03 11:41:30 +0000
committerOpenEmbedded Project <openembedded-devel@lists.openembedded.org>2008-06-03 11:41:30 +0000
commit972f72f4e47196817b8a3fc62a9e9dd188490f81 (patch)
tree77d115be3d0a03cf9b86de1a70d30330e4d236dc /classes
parentb4db5d7f3e1a0470f2111508e2b701acee95055e (diff)
parent915c1e3654c4be1667a9390c3671d1a3601e2a56 (diff)
downloadopenembedded-972f72f4e47196817b8a3fc62a9e9dd188490f81.tar.gz
openembedded-972f72f4e47196817b8a3fc62a9e9dd188490f81.tar.bz2
openembedded-972f72f4e47196817b8a3fc62a9e9dd188490f81.zip
merge of '6c9b3832ef2260eb1b3a74e74b1d73166ab79d89'
and 'f275c97e2c93f0e846205b213e997b28ed0b148e'
Diffstat (limited to 'classes')
-rw-r--r--classes/kernel.bbclass38
-rw-r--r--classes/siteinfo.bbclass1
2 files changed, 27 insertions, 12 deletions
diff --git a/classes/kernel.bbclass b/classes/kernel.bbclass
index a7fd79419c..5085d9cabd 100644
--- a/classes/kernel.bbclass
+++ b/classes/kernel.bbclass
@@ -16,8 +16,15 @@ python __anonymous () {
depends = bb.data.getVar("DEPENDS", d, 1)
depends = "%s u-boot-mkimage-openmoko-native" % depends
bb.data.setVar("DEPENDS", depends, d)
+
+ image = bb.data.getVar('INITRAMFS_IMAGE', d, True)
+ if image != '' and image is not None:
+ bb.data.setVar('INITRAMFS_TASK', '${INITRAMFS_IMAGE}:do_rootfs', d)
}
+INITRAMFS_IMAGE ?= ""
+INITRAMFS_TASK ?= ""
+
inherit kernel-arch
PACKAGES_DYNAMIC += "kernel-module-*"
@@ -79,21 +86,28 @@ kernel_do_compile() {
fi
}
-INITRAMFS_SYMLINK_NAME ?= "initramfs-${MACHINE}"
-INITRAMFS_IMAGE_TARGET ?= "initramfs-image"
do_builtin_initramfs() {
- unset CFLAGS CPPFLAGS CXXFLAGS LDFLAGS MACHINE
- cp "${DEPLOY_DIR_IMAGE}/${INITRAMFS_SYMLINK_NAME}" usr/initramfs_data.cpio.gz
- oe_runmake ${KERNEL_IMAGETYPE} CC="${KERNEL_CC}" LD="${KERNEL_LD}"
- install -d ${DEPLOY_DIR_IMAGE}
- install -m 0644 ${KERNEL_OUTPUT} ${DEPLOY_DIR_IMAGE}/${KERNEL_IMAGE_BASE_NAME}-initramfs.bin
- # Make sure to kill injected initramfs, in case someone will do "-c compile -f"
- rm usr/initramfs_data.cpio.gz
+ if [ ! -z "${INITRAMFS_IMAGE}" ]; then
+ unset CFLAGS CPPFLAGS CXXFLAGS LDFLAGS MACHINE
+ cp "${DEPLOY_DIR_IMAGE}/${INITRAMFS_IMAGE}-${MACHINE}.cpio.gz" usr/initramfs_data.cpio.gz
+ oe_runmake ${KERNEL_IMAGETYPE} CC="${KERNEL_CC}" LD="${KERNEL_LD}"
+
+ install -d ${DEPLOY_DIR_IMAGE}
+ install -m 0644 arch/${ARCH}/boot/${KERNEL_IMAGETYPE} ${DEPLOY_DIR_IMAGE}/${KERNEL_IMAGE_BASE_NAME}-${INITRAMFS_IMAGE}.bin
+ package_stagefile_shell ${DEPLOY_DIR_IMAGE}/${KERNEL_IMAGE_BASE_NAME}-${INITRAMFS_IMAGE}.bin
+
+ # Make sure to kill injected initramfs, in case someone will do "-c compile -f"
+ rm usr/initramfs_data.cpio.gz
+
+ cd ${DEPLOY_DIR_IMAGE}
+ rm -f ${KERNEL_IMAGE_SYMLINK_NAME}-${INITRAMFS_IMAGE}.bin
+ ln -sf ${KERNEL_IMAGE_BASE_NAME}-${INITRAMFS_IMAGE}.bin ${KERNEL_IMAGE_SYMLINK_NAME}-${INITRAMFS_IMAGE}.bin
+ package_stagefile_shell ${DEPLOY_DIR_IMAGE}/${KERNEL_IMAGE_SYMLINK_NAME}-${INITRAMFS_IMAGE}.bin
+ fi
}
-#addtask builtin_initramfs after do_compile
-#do_builtin_initramfs[nostamp] = "1"
-#do_builtin_initramfs[depends] = "${INITRAMFS_IMAGE_TARGET}:do_rootfs"
+addtask builtin_initramfs before do_build after do_package_write
+do_builtin_initramfs[depends] = '${INITRAMFS_TASK}'
kernel_do_stage() {
ASMDIR=`readlink include/asm`
diff --git a/classes/siteinfo.bbclass b/classes/siteinfo.bbclass
index 0d31be4dc4..039afbbee1 100644
--- a/classes/siteinfo.bbclass
+++ b/classes/siteinfo.bbclass
@@ -47,6 +47,7 @@ def get_siteinfo_list(d):
"powerpc-darwin": "endian-big bit-32 common-darwin",\
"ppc-linux": "endian-big bit-32 common-linux common-glibc powerpc-common",\
"powerpc-linux": "endian-big bit-32 common-linux common-glibc powerpc-common",\
+ "powerpc-linux-gnuspe": "endian-big bit-32 common-linux common-glibc powerpc-common",\
"powerpc-linux-uclibc": "endian-big bit-32 common-linux common-uclibc powerpc-common",\
"sh3-linux": "endian-little bit-32 common-linux common-glibc sh-common",\
"sh4-linux": "endian-little bit-32 common-linux common-glibc sh-common",\