Bug 1025513 - add Provides information for kernel modules
Summary: add Provides information for kernel modules
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Product: Fedora
Classification: Fedora
Component: rpm
Version: rawhide
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Packaging Maintenance Team
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-10-31 20:44 UTC by Kyle McMartin
Modified: 2015-09-01 03:54 UTC (History)
9 users (show)

Fixed In Version: rpm-4.11.1-11.fc21
Clone Of:
Environment:
Last Closed: 2013-12-03 07:55:56 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)
add kmod.attr and kmod.prov scripts to implement Provides: kmod(foo.ko) (2.15 KB, patch)
2013-10-31 20:44 UTC, Kyle McMartin
no flags Details | Diff

Description Kyle McMartin 2013-10-31 20:44:12 UTC
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

Comment 1 Kyle McMartin 2013-10-31 20:46:05 UTC
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:

http://koji.fedoraproject.org/koji/taskinfo?taskID=6121132

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.

Comment 2 Panu Matilainen 2013-12-03 07:55:56 UTC
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.


Note You need to log in before you can comment on or make changes to this bug.