summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMike Crowe <mac@mcrowe.com>2011-08-25 13:59:28 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2011-08-29 13:48:02 +0100
commit5633ac73b3b8e8618d443525f001649e47915a5f (patch)
treeb3def6b0f6c9cce34809d73328948b5ee4f9a169
parente70a369d2aabcf0df2cb76a837bc54bddba55a8c (diff)
downloadpoky-5633ac73b3b8e8618d443525f001649e47915a5f.tar.gz
kernel.bbclass: support kernel image type of vmlinux.gz
Add support for a gzipped vmlinux kernel by specifying: KERNEL_IMAGETYPE = "vmlinux.gz" (From OE-Core rev: cb17b6c2a72f260c61b0ec46887c2a04ac5b3f80) Signed-off-by: Mike Crowe <mac@mcrowe.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--meta/classes/kernel.bbclass7
1 files changed, 6 insertions, 1 deletions
diff --git a/meta/classes/kernel.bbclass b/meta/classes/kernel.bbclass
index 52aea97372..229679c72e 100644
--- a/meta/classes/kernel.bbclass
+++ b/meta/classes/kernel.bbclass
@@ -75,10 +75,15 @@ EXTRA_OEMAKE = ""
75 75
76KERNEL_ALT_IMAGETYPE ??= "" 76KERNEL_ALT_IMAGETYPE ??= ""
77 77
78KERNEL_IMAGETYPE_FOR_MAKE = "${@(lambda s: s[:-3] if s[-3:] == ".gz" else s)(bb.data.getVar('KERNEL_IMAGETYPE', d, 1))}"
79
78kernel_do_compile() { 80kernel_do_compile() {
79 unset CFLAGS CPPFLAGS CXXFLAGS LDFLAGS MACHINE 81 unset CFLAGS CPPFLAGS CXXFLAGS LDFLAGS MACHINE
80 oe_runmake include/linux/version.h CC="${KERNEL_CC}" LD="${KERNEL_LD}" 82 oe_runmake include/linux/version.h CC="${KERNEL_CC}" LD="${KERNEL_LD}"
81 oe_runmake ${KERNEL_IMAGETYPE} ${KERNEL_ALT_IMAGETYPE} CC="${KERNEL_CC}" LD="${KERNEL_LD}" 83 oe_runmake ${KERNEL_IMAGETYPE_FOR_MAKE} ${KERNEL_ALT_IMAGETYPE} CC="${KERNEL_CC}" LD="${KERNEL_LD}"
84 if test "${KERNEL_IMAGETYPE_FOR_MAKE}.gz" = "${KERNEL_IMAGETYPE}"; then
85 gzip -9c < "${KERNEL_IMAGETYPE_FOR_MAKE}" > "${KERNEL_OUTPUT}"
86 fi
82} 87}
83 88
84do_compile_kernelmodules() { 89do_compile_kernelmodules() {