RPM Package Manager, CVS Repository
http://rpm5.org/cvs/
____________________________________________________________________________
Server: rpm5.org Name: Arkadiusz Miskiewicz
Root: /v/rpm/cvs Email: arekm@rpm5.org
Module: rpm Date: 20-Aug-2008 22:07:56
Branch: HEAD Handle: 2008082020075600
Modified files:
rpm/scripts perl.req
Log:
Handle statements like: use base qw( Class::Accessor::Chained::Fast );
Patch by Radoslaw Zielinski <radek/pld-linux.org>.
Summary:
Revision Changes Path
1.15 +23 -1 rpm/scripts/perl.req
____________________________________________________________________________
patch -p0 <<'@@ .'
Index: rpm/scripts/perl.req
============================================================================
$ cvs diff -u -r1.14 -r1.15 perl.req
--- rpm/scripts/perl.req 25 May 2007 17:36:39 -0000 1.14
+++ rpm/scripts/perl.req 20 Aug 2008 20:07:56 -0000 1.15
@@ -131,7 +131,29 @@
}
}
- if (
+ # handle "use base qw/ foo::bar baz::blah /;" and variations
+ if (
+ m/^ \s*
+ use \s+ base
+ (?: \s+ q[wq]? \s* ( [!@#\$%^&*'"\/+=`~,.?-] ) \s* ( \S+? (?: \s+\S+? )*? ) \s* \1
+ |
+ \s* ( ["'] ) ( \S+? ) \3
+ |
+ # qw[], qw(), qw<>, qw{} are handled here; lax, but who gives
+ \s+ q[wq]? \s* [\[({<] \s* ( \S+? (?: \s+\S+? )*? ) \s* [\])}>]
+ )
+ \s* ;
+ /x
+ )
+ {
+ my @deps = ( $1 ? split /\s+/, $2 : $3 ? split /\s+/, $4 : $5 );
+ for my $mod ( grep !exists $require{$_}, @deps ) {
+ $require{$mod} = '';
+ $line{$mod} = $_;
+ }
+ }
+
+ elsif (
# ouch could be in a eval, perhaps we do not want these since we catch
# an exception they must not be required
@@ .
Received on Wed Aug 20 22:07:56 2008