aboutsummaryrefslogtreecommitdiffstats
path: root/Makefile.in
diff options
context:
space:
mode:
Diffstat (limited to 'Makefile.in')
-rw-r--r--Makefile.in12
1 files changed, 4 insertions, 8 deletions
diff --git a/Makefile.in b/Makefile.in
index 50e63004b..8b63e549b 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -56,6 +56,7 @@ CP=cp
MV=mv
SED=sed
GRT_RANLIB=ranlib
+GHDL_DESC?=tarball
VHDL_LIB_DIR=$(prefix)/$(libdirsuffix)
@@ -162,14 +163,9 @@ GRTSRCDIR=$(abs_srcdir)/src/grt
include $(srcdir)/src/grt/Makefile.inc
version.tmp: $(srcdir)/src/version.in force
-# Create version.tmp from version.in, using git date/hash
- if test -d $(srcdir)/.git \
- && desc=`cd $(srcdir); git describe --dirty`; then \
- sub="s/[(].*[)]/($$desc)/"; \
- else \
- sub="s/tarball/tarball/"; \
- fi; \
- $(SED) -e "$$sub" -e "s/@VER@/$(ghdl_version)/" < $< > $@; \
+# Create version.tmp from version.in, using git date/hash, or envvar GHDL_DESC. Defaults to 'tarball'.
+ if test -d $(srcdir)/.git && desc=`cd $(srcdir); git describe --dirty`; then GHDL_DESC="$$desc"; fi; \
+ $(SED) -e "s/[(].*[)]/($$GHDL_DESC)/" -e "s/@VER@/$(ghdl_version)/" < $< > $@; \
version.ads: version.tmp
# Change version.ads only if version.tmp has been modified to avoid