summaryrefslogtreecommitdiff
path: root/recipes/kexecboot
diff options
context:
space:
mode:
authorAndrea Adami <andrea.adami@gmail.com>2010-01-02 17:11:20 +0100
committerAndrea Adami <andrea.adami@gmail.com>2010-01-02 17:11:20 +0100
commite4755f888383ab9850a49926f0997ea232fb6b96 (patch)
treeb567ff58a24c7e8c4557f631fa5cef8ae8ef3087 /recipes/kexecboot
parentc498cc5981b1cc3c9a2c224dea688ca0995f9780 (diff)
linux-kexecboot.inc: use bb.utils.vercmp_part for version_less_or_equal.
Bump PR.
Diffstat (limited to 'recipes/kexecboot')
-rw-r--r--recipes/kexecboot/linux-kexecboot.inc19
1 files changed, 16 insertions, 3 deletions
diff --git a/recipes/kexecboot/linux-kexecboot.inc b/recipes/kexecboot/linux-kexecboot.inc
index 0d5f2bb2ac..900e005cac 100644
--- a/recipes/kexecboot/linux-kexecboot.inc
+++ b/recipes/kexecboot/linux-kexecboot.inc
@@ -1,5 +1,5 @@
# We set PR here, since a change in the kexecboot recipe will need to get picked up by *all* the kernels:
-PR = "r16"
+PR = "r17"
SRC_URI = "file://defconfig"
@@ -31,18 +31,30 @@ TKSRC = "http://www.informatik.hu-berlin.de/~tkunze/zaurus/patches"
KERNEL_IMAGE_BASE_NAME = "${KERNEL_IMAGETYPE}-kexecboot-${PV}-${PR}-${MACHINE}"
KERNEL_IMAGE_SYMLINK_NAME = "${KERNEL_IMAGETYPE}-kexecboot-${MACHINE}"
+# use custom function until base_version_less_or_equal is fixed
#
+def kernel_version_less_or_equal(variable, checkvalue, truevalue, falsevalue, d):
+ from bb import utils
+ result = bb.utils.vercmp_part(bb.data.getVar(variable,d,True), checkvalue)
+ if result <= 0:
+ return truevalue
+ else:
+ return falsevalue
+
# default lzma compressor for kernels >= 2.6.30
-INITRAMFS_COMPRESSION = '${@base_version_less_or_equal("PV", "2.6.30", "", "CONFIG_INITRAMFS_COMPRESSION_LZMA=y", d)}'
-INITRAMFS_COMPRESSION_SUFFIX = '${@base_version_less_or_equal("PV", "2.6.30", "gz", "lzma", d)}'
+INITRAMFS_COMPRESSION = '${@kernel_version_less_or_equal("PV", "2.6.30", "", "CONFIG_INITRAMFS_COMPRESSION_LZMA=y", d)}'
+INITRAMFS_COMPRESSION_SUFFIX = '${@kernel_version_less_or_equal("PV", "2.6.30", "gz", "lzma", d)}'
+RD_COMPRESSION = '${@kernel_version_less_or_equal("PV", "2.6.30", "", "CONFIG_RD_LZMA=y", d)}'
do_configure[depends] += "${INITRAMFS_IMAGE}:do_rootfs"
+
do_configure_append() {
sed -i -e /CONFIG_BLK_DEV_INITRD/d \
-e /CONFIG_KEXEC/d \
-e /CONFIG_INITRAMFS_SOURCE/d \
-e /CONFIG_INITRAMFS_COMPRESSION/d \
+ -e /CONFIG_RD/d \
-e /=m/d \
-e /CONFIG_MODULES/d \
-e /CONFIG_DEBUG_ERRORS/d \
@@ -58,6 +70,7 @@ echo 'CONFIG_BLK_DEV_INITRD=y
CONFIG_KEXEC=y
${INITRAMFS_COMPRESSION}
CONFIG_INITRAMFS_SOURCE="initramfs.cpio.${INITRAMFS_COMPRESSION_SUFFIX}"
+${RD_COMPRESSION}
CONFIG_MODULES=n' >> ${S}/.config
yes '' | oe_runmake oldconfig