]> code.ossystems Code Review - openembedded-core.git/commit
kernel.bbclass: Fix do_sizecheck behaviour
authorMike Crowe <mac@mcrowe.com>
Fri, 8 Dec 2017 13:43:26 +0000 (13:43 +0000)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Tue, 2 Jan 2018 17:24:12 +0000 (17:24 +0000)
commit59f1ee104d1a6c04b0690b7c8ce481449da174d6
treedd97ef4de6b3145c18fb108b9d3216c6fb46a765
parentc0c10ae9f7e206ee156a68ddbed73c8820c37824
kernel.bbclass: Fix do_sizecheck behaviour

During the introduction of support for multiple kernel image types in
849b67b2e4820564b5e5c9bd4bb293c44351c5f3, do_sizecheck was changed to only
warn if any kernel was bigger than ${KERNEL_IMAGE_MAXSIZE}. (Well, it tried
to warn - it turns out that there's no function called "warn", it should be
"bbwarn".) The previous behaviour had been to fail the build if the single
kernel image did not fit.

It seems possible that people might be generating both compressed and
uncompressed kernels and only really care whether the compressed one fits.
This means that we shouldn't just always fail if any of the images are too
large. So, let's warn (correctly this time) on every image that is too
large, but only ultimately fail if no image will fit. The build will also
fail if ${KERNEL_IMAGETYPES} is empty, but I hope that no-one needs to do
that.

While we're here correct a typo in the KERNEL_IMAGE_MAXSIZE validity check.

Signed-off-by: Mike Crowe <mac@mcrowe.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
meta/classes/kernel.bbclass