Red Hat Bugzilla – Bug 1025513
add Provides information for kernel modules
Last modified: 2015-08-31 23:54:47 EDT
Created attachment 818067 [details]
add kmod.attr and kmod.prov scripts to implement Provides: kmod(foo.ko)
It's difficult for userland software to depend on split kernel packages (ie: kernel and kernel-modules-extra) to provide a specific kmod (ie: gfs2.ko) currently, as you must maintain the versioned depends manually.
To solve this, add a kmod(foo.ko) Provides to each kernel module package, so that userland can depend on kmod(foo.ko) and have it be satisfied, wherever the module ends up being packaged.
Patch attached that seems to work in basic testing... Originally I had it in redhat-rpm-config, but it seems like these things usually go in rpm-build?
Fedora would like to use this so it can limit the modules built on architectures where various things are unlikely to be found (arm) and to split the modules up into various sub-packages to reduce the disk footprint on VMs where the hardware is more predictable.
Thanks in advance, Kyle
Additional info: this also makes it easier for us to move from something being in a module to being built into the kernel, since builtins are provided by the modules.builtin file.
Scratch build available here:
If you install that and kick off a kernel build, you should end up with a large list of Provides: kmod(foo.ko) on kernel and kernel-modules-extra.
Apologies for not responding earlier. I've zero objections to this, it just kinda fell through the cracks initially and then I got stuck mulling over whether to put it into rpm or redhat-rpm-config (from dependency generation POV it doesn't matter, its just a matter of taste really)
Anyway, I put it into rpm now as that's what your patch is for, it can always be moved to redhat-rpm-config later if that becomes desireable/necessary for one reason or the other.
Fixed in rawhide, rpm-4.11.1-11.fc21.