summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--GNUmakefile.in15
-rw-r--r--configure.ac1
2 files changed, 16 insertions, 0 deletions
diff --git a/GNUmakefile.in b/GNUmakefile.in
new file mode 100644
index 0000000..9640280
--- /dev/null
+++ b/GNUmakefile.in
@@ -0,0 +1,15 @@
+include Makefile
+
+AUTORECONF ?= autoreconf
+AUTORECONF_OPTS ?= -vis
+
+git_version := $(shell $(top_srcdir)/build-helpers/package-version $(top_srcdir) version-stamp)
+ifneq ($(PACKAGE_VERSION),$(git_version))
+$(info autoconf and git versions do not match: $(PACKAGE_VERSION) vs $(git_version))
+$(info Removing autom4te.cache and related files and re-running autoreconf)
+dummy1 := $(shell rm -rf $(top_srcdir)/autom4te.cache)
+dummy2 := $(shell rm -f $(top_srcdir)/test/package.m4 $(top_srcdir)/test/testsuite)
+dummy3 := $(shell $(AUTORECONF) $(AUTORECONF_OPTS) $(top_srcdir))
+endif
+
+# vim: syntax=make
diff --git a/configure.ac b/configure.ac
index 8e27fa4..fe1784e 100644
--- a/configure.ac
+++ b/configure.ac
@@ -24,6 +24,7 @@ NDIM_DETECT_MAN2TXT()dnl
########################################################################
+AC_CONFIG_FILES([GNUmakefile])
AC_CONFIG_FILES([Makefile])
AC_CONFIG_FILES([git-amb/git-amb.man])
AC_CONFIG_FILES([git-amb/git-amb])