KERNEL-INSTALL.ECLASS
Section: eclass-manpages (5)Updated: Sep 2023
Index Return to Main Contents
NAME
kernel-install.eclass - Installation mechanics for Distribution KernelsDESCRIPTION
This eclass provides the logic needed to test and install different kinds of Distribution Kernel packages, including both kernels built from source and distributed as binaries. The eclass relies on the ebuild installing a subset of built kernel tree into /usr/src/linux-${PV} containing the kernel image in its standard location and System.map.The eclass exports src_test, pkg_postinst and pkg_postrm. Additionally, the inherited mount-boot eclass exports pkg_pretend. It also stubs out pkg_preinst and pkg_prerm defined by mount-boot.
SUPPORTED EAPIS
8TRANSITIVELY PROVIDED ECLASSES
dist-kernel-utilsFUNCTIONS
- kernel-install_can_update_symlink
- Determine whether the symlink at <target> (full path) should be updated. Returns 0 if it should, 1 to leave as-is.
- kernel-install_update_symlink <target> <version>
- Update the kernel source symlink at <target> (full path) with a link to <target>-<version> if it's either missing or pointing out to an older version of this package.
- kernel-install_get_qemu_arch
- Get appropriate qemu suffix for the current ${ARCH}.
- kernel-install_create_init <filename>
- Create minimal /sbin/init
- kernel-install_create_qemu_image <filename>
- Create minimal qemu raw image
- kernel-install_test <version> <image> <modules>
- Test that the kernel can successfully boot a minimal system image in qemu. <version> is the kernel version, <image> path to the image, <modules> path to module tree.
- kernel-install_pkg_pretend
- Check for missing optional dependencies and output warnings.
- kernel-install_src_test
- Boilerplate function to remind people to call the tests.
- kernel-install_pkg_preinst
- Verify whether the kernel has been installed correctly.
- kernel-install_install_all <ver>
- Build an initramfs for the kernel and install the kernel. This is called from pkg_postinst() and pkg_config(). <ver> is the full kernel version.
- kernel-install_pkg_postinst
- Build an initramfs for the kernel, install it and update the /usr/src/linux symlink.
- kernel-install_pkg_prerm
- Stub out mount-boot.eclass.
- kernel-install_pkg_postrm
- Clean up the generated initramfs from the removed kernel directory.
- kernel-install_pkg_config
- Rebuild the initramfs and reinstall the kernel.
ECLASS VARIABLES
- KV_LOCALVERSION
- A string containing the kernel LOCALVERSION, e.g. '-gentoo'. Needs to be set only when installing binary kernels, kernel-build.eclass obtains it from kernel config.
AUTHORS
Michał Górny <mgorny@gentoo.org>MAINTAINERS
Distribution Kernel Project <dist-kernel@gentoo.org>REPORTING BUGS
Please report bugs via https://bugs.gentoo.org/FILES
kernel-install.eclassSEE ALSO
ebuild(5)https://gitweb.gentoo.org/repo/gentoo.git/log/eclass/kernel-install.eclass
Index
- NAME
- DESCRIPTION
- SUPPORTED EAPIS
- TRANSITIVELY PROVIDED ECLASSES
- FUNCTIONS
- ECLASS VARIABLES
- AUTHORS
- MAINTAINERS
- REPORTING BUGS
- FILES
- SEE ALSO
This document was created by man2html, using the manual pages.
Time: 03:27:01 GMT, September 22, 2023