source: soft/build_system/build_system/mkcd/tags/V3_5_3_1mdk/clean-rpmsrate @ 1

Last change on this file since 1 was 1, checked in by fasma, 12 years ago

Initial Import from Mandriva's soft revision 224062 and package revision 45733

File size: 519 bytes
Line 
1#!/usr/bin/perl -I /home/warly/files/cvs/mdk/soft/mkcd/pm
2#
3#
4
5use strict;
6use Mkcd::Tools qw(cleanrpmsrate);
7
8$ARGV[0] =~ /-o/ and shift @ARGV and my $rpmsrate = shift;
9
10$ARGV[1] or print "\nUsage:
11        clean-rpmsrate [options] <rpmsrate file> <RPMs dir 1> <RPMs dir 2> ... <RPMs dir n>
12
13        options:
14                -o file: output file\n\n" and exit;
15
16my %rpm;
17my $rpmsrate_base = shift @ARGV;
18foreach my $d (@ARGV) { $rpm{$d} = [ map { s/$d\/?(.*)\.rpm$/$1/; $_ } glob "$d/*.rpm" ] };
19cleanrpmsrate($rpmsrate_base,$rpmsrate,0, \%rpm);
Note: See TracBrowser for help on using the repository browser.