summaryrefslogtreecommitdiffstats
path: root/bin/checkdistrib
diff options
context:
space:
mode:
Diffstat (limited to 'bin/checkdistrib')
-rwxr-xr-xbin/checkdistrib34
1 files changed, 34 insertions, 0 deletions
diff --git a/bin/checkdistrib b/bin/checkdistrib
new file mode 100755
index 0000000..57f6dc8
--- /dev/null
+++ b/bin/checkdistrib
@@ -0,0 +1,34 @@
+#!/usr/bin/perl
+
+# $Id: checkdistrib 56937 2006-08-21 10:19:01Z nanardon $
+
+use strict;
+use warnings;
+use MDV::Distribconf::Build;
+use Getopt::Long;
+
+GetOptions(
+) or die "Error parsing command line argument\n";
+
+my @distribs = @ARGV;
+
+my $error = 0;
+
+foreach my $tree (@distribs) {
+ my $mdc = MDV::Distribconf::Build->new($tree);
+ if(!$mdc->load) {
+ print "\nCannot locate a distrib in $tree\n";
+ next;
+ } else {
+ printf(
+ "\nChecking distrib in %s (%s for %s)\n",
+ $tree,
+ $mdc->getvalue(undef, 'version'),
+ $mdc->getvalue(undef, 'arch'),
+ );
+ }
+
+ $error += $mdc->checkdistrib(\*STDOUT);
+}
+
+exit($error);