summaryrefslogtreecommitdiffstats
path: root/perl-install
diff options
context:
space:
mode:
authorThierry Vignaud <tvignaud@mandriva.org>2003-01-14 13:02:00 +0000
committerThierry Vignaud <tvignaud@mandriva.org>2003-01-14 13:02:00 +0000
commitc6500cae8a699138b89bdfb0f29281dd0092be0e (patch)
treea6851adb5f9bb719e3b55f68c33add2cb7bc45ad /perl-install
parentfadcdb8fb5ba051ec07f7e131d370d2d34779b4a (diff)
downloaddrakx-c6500cae8a699138b89bdfb0f29281dd0092be0e.tar
drakx-c6500cae8a699138b89bdfb0f29281dd0092be0e.tar.gz
drakx-c6500cae8a699138b89bdfb0f29281dd0092be0e.tar.bz2
drakx-c6500cae8a699138b89bdfb0f29281dd0092be0e.tar.xz
drakx-c6500cae8a699138b89bdfb0f29281dd0092be0e.zip
add harddrake::sound checker
Diffstat (limited to 'perl-install')
-rwxr-xr-xperl-install/harddrake/check_snd.pl20
1 files changed, 20 insertions, 0 deletions
diff --git a/perl-install/harddrake/check_snd.pl b/perl-install/harddrake/check_snd.pl
new file mode 100755
index 000000000..dfa007b80
--- /dev/null
+++ b/perl-install/harddrake/check_snd.pl
@@ -0,0 +1,20 @@
+#!/usr/bin/perl
+
+use strict;
+use lib qw(/usr/lib/libDrakX);
+
+use common;
+use harddrake::sound;
+use list_modules;
+
+
+my @listed_modules = @{$list_modules::l{multimedia}{sound}};
+my @drivers = (keys %harddrake::sound::oss2alsa, keys %harddrake::sound::alsa2oss);
+my @alternatives = uniq map { @{$_} } values %harddrake::sound::oss2alsa, values %harddrake::sound::alsa2oss;
+
+# check harddrake::sound's data structures're coherent
+print "unknown alternative drivers : [", join(', ', difference2(\@alternatives, \@drivers)), "]\n";
+
+# check that list_modules and harddrake::sound are synced
+print "non real sound modules (submodules, tv, usb, ...) : [", join(', ', difference2(\@drivers, \@listed_modules)), "]\n";
+print "forgotten sound modules : [", join(', ', difference2(\@listed_modules, \@drivers)), "]\n";