Description: Allow overriding version description
 Makefile.in has provisions to allow setting the version description, ref and
 hash values through environment variables. However, if it detects the source
 directory being a git repository, it will overwrite these values again. As a
 quick fix just remove the git check.
Author: Andreas Bombe <aeb@debian.org>
Last-Update: 2021-02-10
---
This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
Index: git/Makefile.in
===================================================================
--- git.orig/Makefile.in	2021-02-11 00:57:08.252079807 +0100
+++ git/Makefile.in	2021-02-11 00:58:06.332247788 +0100
@@ -162,14 +162,11 @@
 
 version.tmp: $(srcdir)/src/version.in force
 #	Create version.tmp from version.in, using git date/hash, or envvars.
+#	Debian patch: prevent overwriting envvar settings when git is detected
+#	by removing the git check.
 	GHDL_VER_DESC=$${GHDL_VER_DESC:-tarball}; \
 	GHDL_VER_REF=$${GHDL_VER_REF:-unknown}; \
 	GHDL_VER_HASH=$${GHDL_VER_HASH:-unknown}; \
-	if test -d $(srcdir)/.git && desc=`cd $(srcdir); git describe --dirty --long`; then \
-	  GHDL_VER_DESC=`echo $$desc | sed -e 's/\([^-]*-g\)/r\1/' -e 's/-/./g' -e 's/^v//g'`; \
-	  GHDL_VER_REF=`cd $(srcdir); git rev-parse --abbrev-ref HEAD`; \
-	  GHDL_VER_HASH=`cd $(srcdir); git rev-parse HEAD`; \
-	fi; \
 	sed \
 	  -e "s#@VER@#$(ghdl_version)#" \
 	  -e "s#@DESC@#$${GHDL_VER_DESC}#" \
