summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPascal Rigaux <pixel@mandriva.com>2002-07-05 11:36:52 +0000
committerPascal Rigaux <pixel@mandriva.com>2002-07-05 11:36:52 +0000
commitff8a5ac388f202e40a3e2723c5ae1688e54c0080 (patch)
treeed170c74086b289f32da0134056b180f270369fc
parent7a54076460f9303cc109047e1e8e328539d1b857 (diff)
downloaddrakx-backup-do-not-use-ff8a5ac388f202e40a3e2723c5ae1688e54c0080.tar
drakx-backup-do-not-use-ff8a5ac388f202e40a3e2723c5ae1688e54c0080.tar.gz
drakx-backup-do-not-use-ff8a5ac388f202e40a3e2723c5ae1688e54c0080.tar.bz2
drakx-backup-do-not-use-ff8a5ac388f202e40a3e2723c5ae1688e54c0080.tar.xz
drakx-backup-do-not-use-ff8a5ac388f202e40a3e2723c5ae1688e54c0080.zip
add checks (which used to be done by mdk-stage1/pci-resource/update-pci-ids)
-rwxr-xr-xkernel/check_mar.pl30
-rwxr-xr-xkernel/update_kernel2
2 files changed, 32 insertions, 0 deletions
diff --git a/kernel/check_mar.pl b/kernel/check_mar.pl
new file mode 100755
index 000000000..556a0e442
--- /dev/null
+++ b/kernel/check_mar.pl
@@ -0,0 +1,30 @@
+#!/usr/bin/perl
+
+use MDK::Common;
+
+my $mar = '../mdk-stage1/mar/mar';
+-x $mar or die "ERROR: Sorry, need $mar binary\n";
+
+my %sanity_check = (
+ hd => [
+ qw(aic7xxx sym53c8xx initio),
+ if_(arch() !~ /ppc/, 'advansys'),
+ ],
+ network => [
+ qw(3c59x eepro100 tulip via-rhine ne2k-pci 8139too),
+ if_(arch() !~ /ppc/, 'e100'),
+ if_(arch() !~ /ppc|ia64/, 'tlan'),
+ ],
+);
+
+my $main_version = chomp_(cat_("all.kernels/.main"));
+
+foreach (keys %sanity_check) {
+ my $marfile = "all.modules/$main_version/${_}_modules.mar";
+ -e $mar or die "ERROR: missing $marfile\n";
+
+ my @l = map { /(\S+)\.o/ } `$mar -l $marfile`;
+ my @pbs = difference2($sanity_check{$_}, \@l);
+
+ @pbs and die "ERROR: sanity check should prove that " . join(" ", @pbs) . "be part of $marfile\n";
+}
diff --git a/kernel/update_kernel b/kernel/update_kernel
index 3d07c4155..df4a93310 100755
--- a/kernel/update_kernel
+++ b/kernel/update_kernel
@@ -90,3 +90,5 @@ for i in $ALL_KERNELS/*; do
) || exit 1
done
cp -f all.modules/$main/modules.description .
+
+./check_mar.pl