diff options
Diffstat (limited to 'php.req')
-rwxr-xr-x | php.req | 12 |
1 files changed, 11 insertions, 1 deletions
@@ -11,6 +11,8 @@ # - some clean-up... # ##################################################################### +use File::Find; + $pear = "/usr/share/pear"; @files = (); @@ -75,7 +77,15 @@ foreach (@ARGV ? $ARGV : <> ) { } } -@files = qx(find $ENV{RPM_BUILD_ROOT} -name "*php"|grep -v /usr/share/doc |sed -e 's!$ENV{RPM_BUILD_ROOT}!!'); +my $wanted = sub { + return if $File::Find::name !~ /\.php$/; + return if $File::Find::name =~ /\/usr\/share\/doc/; + $File::Find::name =~ s/$ENV{RPM_BUILD_ROOT}//; + push @files, $File::Find::name; +}; + +@files = (); +find($wanted, $ENV{RPM_BUILD_ROOT}); f: for $f (keys %req) { for $g (@files) { next f if ($g =~ /\Q$f\E$/); } |