SPECS: pearize.sh - rpm knows better what's the source path
glen
glen at pld-linux.org
Fri Dec 30 14:16:36 CET 2005
Author: glen Date: Fri Dec 30 13:16:36 2005 GMT
Module: SPECS Tag: HEAD
---- Log message:
- rpm knows better what's the source path
---- Files affected:
SPECS:
pearize.sh (1.32 -> 1.33)
---- Diffs:
================================================================
Index: SPECS/pearize.sh
diff -u SPECS/pearize.sh:1.32 SPECS/pearize.sh:1.33
--- SPECS/pearize.sh:1.32 Tue Dec 13 12:02:47 2005
+++ SPECS/pearize.sh Fri Dec 30 14:16:31 2005
@@ -28,10 +28,13 @@
fi
echo "Processing $spec"
-rc=$(awk '/^%define.*_rc/{print $NF}' $spec)
-pre=$(awk '/^%define.*_pre/{print $NF}' $spec)
-beta=$(awk '/^%define.*_beta/{print $NF}' $spec)
-tarball=$(rpm -q --qf "../SOURCES/%{name}-%{version}$rc$pre$beta.tgz\n" --specfile "$spec" | head -n 1 | sed -e 's,php-pear-,,')
+getsource() {
+ local spec="$1"
+ local NR="$2"
+ rpmbuild --nodigest --nosignature -bp --define 'prep %dump' $spec 2>&1 | awk "/SOURCE$NR\t/ {print \$3}"
+}
+
+tarball=$(getsource $spec 0)
if [ ! -f $tarball ]; then
./builder -g "$spec"
================================================================
---- CVS-web:
http://cvs.pld-linux.org/SPECS/pearize.sh?r1=1.32&r2=1.33&f=u
More information about the pld-cvs-commit
mailing list