summaryrefslogtreecommitdiffstats
path: root/packaging/bin/update-pkginfo
diff options
context:
space:
mode:
Diffstat (limited to 'packaging/bin/update-pkginfo')
-rwxr-xr-xpackaging/bin/update-pkginfo8
1 files changed, 7 insertions, 1 deletions
diff --git a/packaging/bin/update-pkginfo b/packaging/bin/update-pkginfo
index bcd383e4340..020c773da08 100755
--- a/packaging/bin/update-pkginfo
+++ b/packaging/bin/update-pkginfo
@@ -4,6 +4,12 @@ VERSION=$1
RELEASE=$2
REVISION=$3
+if [ "x${REVISION}" = "x" ]; then
+ RPMREVISION=""
+else
+ RPMREVISION=".${REVISION}"
+fi
+
if [ $# -ne 3 ]; then
echo Usage: update-pkginfo VERSION RELEASE REVISION
exit 1
@@ -17,6 +23,6 @@ for f in `du -a | awk '{print $2}' | grep \.tmpl$`; do
sed -e s/PVERSION/$VERSION/g \
-e s/PRELEASE/$RELEASE/g \
-e s/PREVISION/${REVISION}/g \
- -e s/PRPMREV/.${REVISION}/g < $f > $f2
+ -e s/PRPMREV/${RPMREVISION}/g < $f > $f2
done