From: Brian Behlendorf Date: Thu, 29 May 2014 21:55:40 +0000 (-0700) Subject: Restrict release number to META version X-Git-Tag: spl-0.7.12~238 X-Git-Url: https://git.proxmox.com/?a=commitdiff_plain;h=c4f38ddd8003ef51e7f4e92607b1838216650730;p=mirror_spl.git Restrict release number to META version When creating packages in a git repository the release number can be automatically set by 'git describe'. This normally works well but if your repository has newer tags which match the form NAME-VERSION* the release may be incorrectly calculated. To prevent this the match patten has been restricted to NAME-VERSION. Signed-off-by: Brian Behlendorf --- diff --git a/config/spl-meta.m4 b/config/spl-meta.m4 index a51fa79..e98cc2e 100644 --- a/config/spl-meta.m4 +++ b/config/spl-meta.m4 @@ -57,7 +57,7 @@ AC_DEFUN([SPL_AC_META], [ SPL_META_RELEASE=_SPL_AC_META_GETVAL([Release]); if test ! -f ".nogitrelease" && git rev-parse --git-dir > /dev/null 2>&1; then - _match="${SPL_META_NAME}-${SPL_META_VERSION}*" + _match="${SPL_META_NAME}-${SPL_META_VERSION}" _alias=$(git describe --match=${_match} 2>/dev/null) _release=$(echo ${_alias}|cut -f3- -d'-'|sed 's/-/_/g') if test -n "${_release}"; then