packaging(RHEL-CTDB):makespec.sh: fix detection of version
authorMichael Adam <obnox@samba.org>
Tue, 23 Jun 2009 21:06:40 +0000 (23:06 +0200)
committerMichael Adam <obnox@samba.org>
Fri, 13 Nov 2009 15:19:34 +0000 (16:19 +0100)
Michael

packaging/RHEL-CTDB/makespec.sh

index 29a2c42517c6f8342e103e8b0e32931155badfde..e47f44936a53be81973d6531d17eb7f6fdf8b8c4 100755 (executable)
@@ -21,12 +21,12 @@ if [ ! -f ${VERSION_H} ] ; then
        exit 1
 fi
 
-VERSION=`grep SAMBA_VERSION_OFFICIAL_STRING ${VERSION_H} | awk '{print $3}'`
-vendor_version=`grep SAMBA_VERSION_VENDOR_SUFFIX ${VERSION_H} | awk '{print $3}'`
+VERSION=`grep "^#define SAMBA_VERSION_OFFICIAL_STRING " ${VERSION_H} | awk '{print $3}'`
+vendor_version=`grep "^#define SAMBA_VERSION_VENDOR_SUFFIX " ${VERSION_H} | awk '{print $3}'`
 if test "x${vendor_version}"  != "x" ; then
        VERSION="${VERSION}-${vendor_version}"
 fi
-vendor_patch=`grep SAMBA_VERSION_VENDOR_PATCH ${VERSION_H} | awk '{print $3}'`
+vendor_patch=`grep "^#define SAMBA_VERSION_VENDOR_PATCH " ${VERSION_H} | awk '{print $3}'`
 if test "x${vendor_patch}" != "x" ; then
        VERSION="${VERSION}-${vendor_patch}"
 fi