Thanks for reporting the problem. Unfortunately that patch didn't work for me, since Git sometimes outputs more than 4 hex digits after the "g", if needed to avoid ambiguity. Please try the attached further patch, which I installed.
From 61c1c092bda1ff5dd0f31f8807795ee7993f411a Mon Sep 17 00:00:00 2001
From: Paul Eggert <egg...@cs.ucla.edu>
Date: Sun, 6 Aug 2017 09:21:05 -0700
Subject: [PATCH] git-version-gen: port better to older Git

Work even if the hash contains more than 4 digits.
---
 build-aux/git-version-gen | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/build-aux/git-version-gen b/build-aux/git-version-gen
index 6c054b4..e6c329d 100755
--- a/build-aux/git-version-gen
+++ b/build-aux/git-version-gen
@@ -1,6 +1,6 @@
 #!/bin/sh
 # Print a version string.
-scriptversion=2017-08-06.05; # UTC
+scriptversion=2017-08-06.16; # UTC
 
 # Copyright (C) 2007-2017 Free Software Foundation, Inc.
 #
@@ -167,9 +167,9 @@ then
     # tag or the previous older version that did not?
     #   Newer: v6.10-77-g0f8faeb
     #   Older: v6.10-g0f8faeb
-    case $v in
-        *-*-g????) : git describe is okay three part flavor ;;
-        *-g????)
+    case ${v#-g*} in
+        *-*) : git describe is probably okay three part flavor ;;
+        *)
             : git describe is older two part flavor
             # Recreate the number of commits and rewrite such that the
             # result is the same as if we were using the newer version
-- 
2.7.4

Reply via email to