make_a_release.sh: remove the rc_num macro
authorArtem Bityutskiy <artem.bityutskiy@intel.com>
Wed, 19 Feb 2014 14:47:05 +0000 (16:47 +0200)
committerArtem Bityutskiy <artem.bityutskiy@intel.com>
Wed, 19 Feb 2014 14:49:26 +0000 (16:49 +0200)
The previous release could be an -rc release. And we have to remove the
'rc_num' macro before doing the final release, otherwise the RPM will have
an '-rcX' version suffix.

Change-Id: I06d26b4d0d68a6471dc9ad4383d7fd279e535164
Signed-off-by: Artem Bityutskiy <artem.bityutskiy@intel.com>
bmaptool
make_a_release.sh

index 9ffffa548db8f4563294d655f0ca482016208756..9f6b50d90f822b34d7b0e031744f9bd9f978dbea 100755 (executable)
--- a/bmaptool
+++ b/bmaptool
@@ -50,7 +50,7 @@ also contribute to the mapped blocks and are also copied.
 # pylint: disable=R0915
 # pylint: disable=R0912
 
-VERSION = "3.1"
+VERSION = "3.2"
 
 import argparse
 import sys
index 1a60548ae1fc46fa7fbd5c81136aa83fab0218c7..ec6a37acb1572f5297f93974bb63951579b37e99 100755 (executable)
@@ -98,6 +98,9 @@ ask_question "Did you update tests: test-data and oldcodebase"
 sed -i -e "s/^VERSION = \"[0-9]\+\.[0-9]\+\"$/VERSION = \"$new_ver\"/" bmaptool
 # Sed the version in the RPM spec file
 sed -i -e "s/^Version: [0-9]\+\.[0-9]\+$/Version: $new_ver/" packaging/bmap-tools.spec
+# Remove the "rc_num" macro from the RPM spec file to make sure we do not have
+# the "-rcX" part in the release version
+sed -i -e '/^%define[[:blank:]]\+rc_num[[:blank:]]\+[[:digit:]]\+[[:blank:]]*$/d' packaging/bmap-tools.spec
 
 # Ask the maintainer for changelog lines
 logfile="$(mktemp -t "$PROG.XXXX")"