Skip to content

Commit

Permalink
Restrict release number to META version
Browse files Browse the repository at this point in the history
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 the contents
of the META file, NAME-VERSION.

Signed-off-by: Brian Behlendorf <[email protected]>
  • Loading branch information
behlendorf committed May 30, 2014
1 parent 6795a69 commit 79aada6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion config/zfs-meta.m4
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ AC_DEFUN([ZFS_AC_META], [
ZFS_META_RELEASE=_ZFS_AC_META_GETVAL([Release]);
if test ! -f ".nogitrelease" && git rev-parse --git-dir > /dev/null 2>&1; then
_match="${ZFS_META_NAME}-${ZFS_META_VERSION}*"
_match="${ZFS_META_NAME}-${ZFS_META_VERSION}"
_alias=$(git describe --match=${_match} 2>/dev/null)
_release=$(echo ${_alias}|cut -f3- -d'-'|sed 's/-/_/g')
if test -n "${_release}"; then
Expand Down

0 comments on commit 79aada6

Please sign in to comment.