mirror of
https://git.yoctoproject.org/poky
synced 2026-01-29 21:08:42 +01:00
kernel.bbclass: Add a postinstall for kernel-image to make sure the corrrect /lib/modules directory exists and to run depmod. This removes modprobe errors when no kernel modules are installed.
git-svn-id: https://svn.o-hand.com/repos/poky/trunk@456 311d38ba-8fff-0310-9ca6-ca027cbcb966
This commit is contained in:
@@ -192,6 +192,17 @@ PKG_kernel-image = "kernel-image-${KERNEL_VERSION}"
|
||||
ALLOW_EMPTY_kernel = "1"
|
||||
ALLOW_EMPTY_kernel-image = "1"
|
||||
|
||||
pkg_postinst_kernel-image () {
|
||||
if [ ! -e "$D/lib/modules/${KERNEL_RELEASE}" ]; then
|
||||
mkdir -p $D/lib/modules/${KERNEL_RELEASE}
|
||||
fi
|
||||
if [ -n "$D" ]; then
|
||||
${HOST_PREFIX}depmod-${KERNEL_MAJOR_VERSION} -A -b $D -F ${STAGING_KERNEL_DIR}/System.map-${KERNEL_RELEASE} ${KERNEL_VERSION}
|
||||
else
|
||||
depmod -A
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_postinst_modules () {
|
||||
if [ -n "$D" ]; then
|
||||
${HOST_PREFIX}depmod-${KERNEL_MAJOR_VERSION} -A -b $D -F ${STAGING_KERNEL_DIR}/System.map-${KERNEL_RELEASE} ${KERNEL_VERSION}
|
||||
|
||||
Reference in New Issue
Block a user