From: Richard Purdie <rpurdie@rpsys.net>
To: openembedded-devel <openembedded-devel@openembedded.org>
Subject: RFC: Kernel image packaging
Date: Wed, 14 Mar 2007 10:44:08 +0000 [thread overview]
Message-ID: <1173869049.5834.16.camel@localhost.localdomain> (raw)
Hi,
The kernel packaging has given various people concern for a while. The
problem is some devices don't want a kernel binary installed into the
root filesystem. We can do this at the moment but the kernel doesn't end
up packaged and we would like those packages to be available even if
they're not installed by default on a given device.
I'm proposing the patch below. This basically adds a
kernel-${KERNEL_VERSION} package to the mix. This package is in the
Dependencies of all kernel modules instead of
kernel-image-${KERNEL_VERSION}. As standard, kernel-${KERNEL_VERSION}
also RDEPENDS on the kernel-image.
For a device that doesn't want the kernel in the rootfs, it would simply
set:
RDEPENDS_kernel-base = ""
in the appropriate kernel file. Perhaps the definition below should be
a ?= and the above could then be set in the machine.conf file.
Does anyone see a nicer way to handle this or have an alternative?
If nobody objects, this will probably get committed at the weekend.
Cheers,
Richard
#
# old_revision [50c9ee81517d5a1c32a7a7afe7a00793aabceb33]
#
# patch "classes/kernel.bbclass"
# from [237ec9e436415eab3772495898c0921de38b3c07]
# to [17662f6347d7aa822bbb7a5455926a96c9149132]
#
============================================================
--- classes/kernel.bbclass 237ec9e436415eab3772495898c0921de38b3c07
+++ classes/kernel.bbclass 17662f6347d7aa822bbb7a5455926a96c9149132
@@ -169,13 +169,18 @@ EXPORT_FUNCTIONS do_compile do_install d
EXPORT_FUNCTIONS do_compile do_install do_stage do_configure
-PACKAGES = "kernel kernel-image kernel-dev"
+# kernel-base becomes kernel-${KERNEL_VERSION}
+# kernel-image becomes kernel-image-${KERNEL_VERISON}
+PACKAGES = "kernel kernel-base kernel-image kernel-dev"
FILES = ""
FILES_kernel-image = "/boot/${KERNEL_IMAGETYPE}*"
FILES_kernel-dev = "/boot/System.map* /boot/config*"
-RDEPENDS_kernel = "kernel-image-${KERNEL_VERSION}"
+RDEPENDS_kernel = "kernel-${KERNEL_VERSION}"
+RDEPENDS_kernel-base = "kernel-image-${KERNEL_VERSION}"
PKG_kernel-image = "kernel-image-${KERNEL_VERSION}"
+PKG_kernel-base = "kernel-${KERNEL_VERSION}"
ALLOW_EMPTY_kernel = "1"
+ALLOW_EMPTY_kernel-base = "1"
ALLOW_EMPTY_kernel-image = "1"
pkg_postinst_kernel-image () {
@@ -362,13 +367,13 @@ python populate_packages_prepend () {
postinst = bb.data.getVar('pkg_postinst_modules', d, 1)
postrm = bb.data.getVar('pkg_postrm_modules', d, 1)
- do_split_packages(d, root='/lib/modules', file_regex=module_regex, output_pattern=module_pattern, description='%s kernel module', postinst=postinst, postrm=postrm, recursive=True, hook=frob_metadata, extra_depends='update-modules kernel-image-%s' % bb.data.getVar("KERNEL_VERSION", d, 1))
+ do_split_packages(d, root='/lib/modules', file_regex=module_regex, output_pattern=module_pattern, description='%s kernel module', postinst=postinst, postrm=postrm, recursive=True, hook=frob_metadata, extra_depends='update-modules kernel-%s' % bb.data.getVar("KERNEL_VERSION", d, 1))
import re, os
metapkg = "kernel-modules"
bb.data.setVar('ALLOW_EMPTY_' + metapkg, "1", d)
bb.data.setVar('FILES_' + metapkg, "", d)
- blacklist = [ 'kernel-dev', 'kernel-image' ]
+ blacklist = [ 'kernel-dev', 'kernel-image', 'kernel-base' ]
for l in module_deps.values():
for i in l:
pkg = module_pattern % legitimize_package_name(re.match(module_regex, os.path.basename(i)).group(1))
next reply other threads:[~2007-03-14 10:44 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-03-14 10:44 Richard Purdie [this message]
2007-03-14 20:31 ` RFC: Kernel image packaging Paul Sokolovsky
2007-03-14 21:20 ` Hans Henry von Tresckow
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1173869049.5834.16.camel@localhost.localdomain \
--to=rpurdie@rpsys.net \
--cc=openembedded-devel@lists.openembedded.org \
--cc=openembedded-devel@openembedded.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.