]> git.pld-linux.org Git - packages/rpm.git/blobdiff - rpm-php-provides
- rpm-devel dosn't require rpm! it requires rpm-lib
[packages/rpm.git] / rpm-php-provides
index 481569a0bba02b9baa96e6181cfdd6ba1ae2adac..2750cbd6065b6842c1fc8c0dad5b8affb963ce6a 100644 (file)
@@ -1,19 +1,21 @@
-#!/bin/sh
-if [ $# -lt 1 ]; then
-       echo "You have to specify input file"
-       exit 1
-fi
+#!/usr/bin/perl
+#####################################################################
+#                                                                   #
+# Check system dependences between php-pear modules                 #
+#                                                                   #
+# Pawe³ Go³aszewski <blues@ds.pg.gda.pl>                            #
+# Micha³ Moskal <malekith@pld-linux.org>                            #
+# ------------------------------------------------------------------#
+# TODO:                                                             #
+#####################################################################
 
-filelist=`echo $@`
-for i in $filelist; do
-       i=`echo $i | grep "\.php"`
-       if [ -n "$i" ]; then
-               j=`cat $i |egrep  -i "^Class" |cut -f 2 -d " "| tr -d "\r"`
-               if [ -n "$j" ]; then
-                       for p in $j; do
-                               echo "pear($p)"
-                       done
-                       j=""
-               fi
-       fi
-done
+die "You have to specify input files" if (@ARGV < 1);
+
+$pear = "/usr/share/pear";
+
+while (@ARGV > 0) {
+       $f = shift;
+       next unless ($f =~ /$pear.*\.php$/);
+       $f =~ s/.*$pear\///;
+       print "pear($f)\n";
+}
This page took 0.079363 seconds and 4 git commands to generate.