a5cb92f2 |
1 | --- scripts/perl.req~ 2004-04-16 13:27:10.000000000 +0200 |
2 | +++ scripts/perl.req 2004-04-26 23:54:42.128568344 +0200 |
3 | @@ -39,8 +39,19 @@ |
4 | |
5 | # by Ken Estes Mail.com kestes@staff.mail.com |
6 | |
7 | + |
8 | + |
9 | +# *inc variables are used to track dependencies on directories for modules. |
10 | +# These directories (especially arch-dependent) are likely to change some day. |
11 | +my @inc = sort { length $b cmp length $a } |
12 | + map { s#/*$##; $_ } |
13 | + grep m#^/.#, @INC; |
14 | +my %inc = map { $_ => 0 } @inc; |
15 | +my $inc = join '|', map "\Q$_\E", @inc; |
16 | + |
17 | foreach ( @ARGV ? @ARGV : <> ) { |
18 | - chomp; |
779126cb |
19 | - if (m=/usr/(sbin|bin|lib|share|X11R6/(lib|bin))/=) { |
a5cb92f2 |
20 | + chomp; |
7e536e15 |
21 | + $inc{$1}++ if m#($inc)/#; # can't anchor on ^ |
d76b9ce2 |
22 | + if (m=/usr/(sbin|bin|lib|lib64|libx32|share|X11R6/(lib|lib64|libx32|bin))/=) { |
a5cb92f2 |
23 | if (! m=(/(doc|man|info|usr/src)/|\.(so|ph|h|html|pod)$)=) { |
24 | process_file($_) if -f; |
25 | @@ -53,8 +64,9 @@ |
26 | } |
27 | delete $require{the}; # don't count "use the sth" as perl module |
28 | |
29 | +print "$_\n" for sort grep $inc{$_}, keys %inc; |
30 | |
31 | -foreach $module (sort keys %require) { |
f730fb9e |
32 | +foreach my $module (sort grep length, keys %require) { |
a5cb92f2 |
33 | if (length($require{$module}) == 0) { |
34 | if ($module =~ /^[0-9._]+$/) { |
35 | print "perl-base >= $module\n"; |