# Helps update the version number automatically if using GNU make.
include Makefile

AUTORECONF ?= autoreconf
AUTORECONF_OPTS ?= -vis

script_version := $(shell $(top_srcdir)/build-helpers/package-version $(top_srcdir) version-stamp)
ifneq ($(PACKAGE_VERSION),$(script_version))
$(info autoconf and script versions do not match: $(PACKAGE_VERSION) vs $(script_version))
$(info Removing autom4te.cache and related files and re-running autoreconf)
dummy1 := $(shell rm -rf $(top_srcdir)/autom4te.cache)
dummy2 := $(shell $(AUTORECONF) $(AUTORECONF_OPTS) $(top_srcdir))
endif

# vim: syntax=make
