aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xiurt23
-rw-r--r--lib/Iurt/DKMS.pm4
2 files changed, 6 insertions, 1 deletions
diff --git a/iurt2 b/iurt2
index 3ea2af4..30de5a9 100755
--- a/iurt2
+++ b/iurt2
@@ -99,6 +99,9 @@ $run{todo} = [];
["u", "umedia", 1, "<upload media>",
"Media where rebuilt DKMS packages will be uploaded",
sub { my ($tmp, $media) = @_; $tmp->[0]{umedia} = $media; 1 }, "Uploading rebuilt DKMS packages to the given media"],
+ ["p", "package", 1, "<package>",
+ "DKMS package which should be rebuilt",
+ sub { my ($tmp, $package) = @_; $tmp->[0]{package} = $package; 1 }, "Rebuilding only given DKMS packages"],
], "[options]",
"Set the DKMS rebuild mode",
sub { my ($opt) = @_; $run{dkms} = $opt; 1 }, "Running a DKMS rebuild run" ],
diff --git a/lib/Iurt/DKMS.pm b/lib/Iurt/DKMS.pm
index 9ed4333..81a4619 100644
--- a/lib/Iurt/DKMS.pm
+++ b/lib/Iurt/DKMS.pm
@@ -70,9 +70,11 @@ sub search_dkms {
if ($rpm =~ /^dkms-(.*)-([^-]+-[^-]+)\.[^.]+\.rpm/) {
# we only check for kernel or modules in this media
$media_ok or next;
+ my ($name, $version) = ($1, $2);
+ my $package_ok = $run->{dkms}{package} ? $name =~ /$run->{dkms}{package}/ : 1;
+ $package_ok or next;
my $hdr = RPM4::Header->new("$path/$rpm");
my $files = $hdr->queryformat('[%{FILENAMES} ])');
- my ($name, $version) = ($1, $2);
my ($modulesourcedir) = $files =~ m, /usr/src/([^/ ]+),;
my $script = $hdr->queryformat('%{POSTIN})');
my ($realversion) = $script =~ / -v (\S+)/;