summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStephen Gallagher <sgallagh@redhat.com>2009-09-15 10:48:05 -0400
committerStephen Gallagher <sgallagh@redhat.com>2009-09-15 14:42:46 -0400
commitcc98edd9479d4622634a1275c98058916c14059a (patch)
tree5e7ccf54e2d35ece92d5ab3521cdd6a027d663c0
parentadfe89593359dd5fd96ace0a3f9ea8e7e7278fc4 (diff)
downloadsssd-cc98edd9479d4622634a1275c98058916c14059a.tar.gz
sssd-cc98edd9479d4622634a1275c98058916c14059a.tar.bz2
sssd-cc98edd9479d4622634a1275c98058916c14059a.zip
Add PRERELEASE_VERSION variable for use in sssd.spec.in
This will add a second, optional line to the VERSION file that will be used by the automated build scripts to create snapshot versions.
-rw-r--r--configure.ac10
-rw-r--r--contrib/sssd.spec.in2
2 files changed, 11 insertions, 1 deletions
diff --git a/configure.ac b/configure.ac
index d908dbb5..b1e7d85e 100644
--- a/configure.ac
+++ b/configure.ac
@@ -9,5 +9,15 @@ AC_PROG_INSTALL
AC_CONFIG_SUBDIRS([replace common server sss_client])
+# If the VERSION file has a second line, we'll append it
+# to the release tag when creating an RPM or SRPM
+# This is intended for build systems to create snapshot
+# RPMs. The format should be something like:
+# .20090915gitf1bcde7
+# and would result in an SRPM looking like:
+# sssd-0.5.0-0.20090915gitf1bcde7.fc11.src.rpm
+AC_SUBST([PRERELEASE_VERSION],
+ m4_esyscmd([cat VERSION |tail --lines=+2 |head -n1 | tr -d '\n']))
+
AC_CONFIG_FILES([Makefile contrib/sssd.spec])
AC_OUTPUT
diff --git a/contrib/sssd.spec.in b/contrib/sssd.spec.in
index 7b257e21..e5134c06 100644
--- a/contrib/sssd.spec.in
+++ b/contrib/sssd.spec.in
@@ -1,6 +1,6 @@
Name: @PACKAGE_NAME@
Version: @PACKAGE_VERSION@
-Release: 0%{?dist}
+Release: 0@PRERELEASE_VERSION@%{?dist}
Group: Applications/System
Summary: System Security Services Daemon
# The entire source code is GPLv3+ except replace/ which is LGPLv3+