mirror of
https://git.yoctoproject.org/poky
synced 2026-06-03 01:40:07 +00:00
kernel: Modify kernel modules installation path.
Use ${base_libdir}/modules inplace of /lib/modules for kernel modules installation path.
(From OE-Core rev: 0ccb2efe9837e2915c093341a662dffc1df00866)
Signed-off-by: Amarnath Valluri <amarnath.valluri@intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
committed by
Richard Purdie
parent
970b76a728
commit
9c2158c073
@@ -127,7 +127,7 @@ python split_kernel_module_packages () {
|
|||||||
postinst = d.getVar('pkg_postinst_modules')
|
postinst = d.getVar('pkg_postinst_modules')
|
||||||
postrm = d.getVar('pkg_postrm_modules')
|
postrm = d.getVar('pkg_postrm_modules')
|
||||||
|
|
||||||
modules = 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='kernel-%s' % (d.getVar("KERNEL_VERSION")))
|
modules = do_split_packages(d, root='${base_libdir}/modules', file_regex=module_regex, output_pattern=module_pattern, description='%s kernel module', postinst=postinst, postrm=postrm, recursive=True, hook=frob_metadata, extra_depends='kernel-%s' % (d.getVar("KERNEL_VERSION")))
|
||||||
if modules:
|
if modules:
|
||||||
metapkg = d.getVar('KERNEL_MODULES_META_PACKAGE')
|
metapkg = d.getVar('KERNEL_MODULES_META_PACKAGE')
|
||||||
d.appendVar('RDEPENDS_' + metapkg, ' '+' '.join(modules))
|
d.appendVar('RDEPENDS_' + metapkg, ' '+' '.join(modules))
|
||||||
|
|||||||
@@ -296,11 +296,11 @@ kernel_do_install() {
|
|||||||
#
|
#
|
||||||
unset CFLAGS CPPFLAGS CXXFLAGS LDFLAGS MACHINE
|
unset CFLAGS CPPFLAGS CXXFLAGS LDFLAGS MACHINE
|
||||||
if (grep -q -i -e '^CONFIG_MODULES=y$' .config); then
|
if (grep -q -i -e '^CONFIG_MODULES=y$' .config); then
|
||||||
oe_runmake DEPMOD=echo INSTALL_MOD_PATH="${D}" modules_install
|
oe_runmake DEPMOD=echo MODLIB=${D}${base_libdir}/modules/${KERNEL_VERSION} INSTALL_FW_PATH=${D}${base_libdir}/firmware modules_install
|
||||||
rm "${D}/lib/modules/${KERNEL_VERSION}/build"
|
rm "${D}${base_libdir}/modules/${KERNEL_VERSION}/build"
|
||||||
rm "${D}/lib/modules/${KERNEL_VERSION}/source"
|
rm "${D}${base_libdir}/modules/${KERNEL_VERSION}/source"
|
||||||
# If the kernel/ directory is empty remove it to prevent QA issues
|
# If the kernel/ directory is empty remove it to prevent QA issues
|
||||||
rmdir --ignore-fail-on-non-empty "${D}/lib/modules/${KERNEL_VERSION}/kernel"
|
rmdir --ignore-fail-on-non-empty "${D}${base_libdir}/modules/${KERNEL_VERSION}/kernel"
|
||||||
else
|
else
|
||||||
bbnote "no modules to install"
|
bbnote "no modules to install"
|
||||||
fi
|
fi
|
||||||
@@ -478,7 +478,7 @@ EXPORT_FUNCTIONS do_compile do_install do_configure
|
|||||||
# kernel-image becomes kernel-image-${KERNEL_VERSION}
|
# kernel-image becomes kernel-image-${KERNEL_VERSION}
|
||||||
PACKAGES = "kernel kernel-base kernel-vmlinux kernel-image kernel-dev kernel-modules"
|
PACKAGES = "kernel kernel-base kernel-vmlinux kernel-image kernel-dev kernel-modules"
|
||||||
FILES_${PN} = ""
|
FILES_${PN} = ""
|
||||||
FILES_kernel-base = "/lib/modules/${KERNEL_VERSION}/modules.order /lib/modules/${KERNEL_VERSION}/modules.builtin"
|
FILES_kernel-base = "${base_libdir}/modules/${KERNEL_VERSION}/modules.order ${base_libdir}/modules/${KERNEL_VERSION}/modules.builtin"
|
||||||
FILES_kernel-image = ""
|
FILES_kernel-image = ""
|
||||||
FILES_kernel-dev = "/boot/System.map* /boot/Module.symvers* /boot/config* ${KERNEL_SRC_PATH} /lib/modules/${KERNEL_VERSION}/build"
|
FILES_kernel-dev = "/boot/System.map* /boot/Module.symvers* /boot/config* ${KERNEL_SRC_PATH} /lib/modules/${KERNEL_VERSION}/build"
|
||||||
FILES_kernel-vmlinux = "/boot/vmlinux-${KERNEL_VERSION_NAME}"
|
FILES_kernel-vmlinux = "/boot/vmlinux-${KERNEL_VERSION_NAME}"
|
||||||
@@ -511,7 +511,7 @@ pkg_postinst_kernel-base () {
|
|||||||
PACKAGESPLITFUNCS_prepend = "split_kernel_packages "
|
PACKAGESPLITFUNCS_prepend = "split_kernel_packages "
|
||||||
|
|
||||||
python split_kernel_packages () {
|
python split_kernel_packages () {
|
||||||
do_split_packages(d, root='/lib/firmware', file_regex='^(.*)\.(bin|fw|cis|csp|dsp)$', output_pattern='kernel-firmware-%s', description='Firmware for %s', recursive=True, extra_depends='')
|
do_split_packages(d, root='${base_libdir}/firmware', file_regex='^(.*)\.(bin|fw|cis|csp|dsp)$', output_pattern='kernel-firmware-%s', description='Firmware for %s', recursive=True, extra_depends='')
|
||||||
}
|
}
|
||||||
|
|
||||||
# Many scripts want to look in arch/$arch/boot for the bootable
|
# Many scripts want to look in arch/$arch/boot for the bootable
|
||||||
|
|||||||
Reference in New Issue
Block a user