aboutsummaryrefslogtreecommitdiff
path: root/Makefile.am
diff options
context:
space:
mode:
authorAleksander Morgado <aleksander@aleksander.es>2017-09-13 18:45:48 +0200
committerAleksander Morgado <aleksander@aleksander.es>2017-09-13 18:45:48 +0200
commitebe371dd93ad9b64804eb6dbebc0bbbb5fe50294 (patch)
treea07f943caa8ea65cf0d981bdc03a16c8ad04dafc /Makefile.am
parentd50afc09b36d8d30b03094c5583ea2f21f3ab4fc (diff)
build: generate ChangeLog from git during dist
Diffstat (limited to 'Makefile.am')
-rw-r--r--Makefile.am13
1 files changed, 13 insertions, 0 deletions
diff --git a/Makefile.am b/Makefile.am
index 4d2ce1a..bde0a2a 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -9,6 +9,19 @@ DISTCHECK_CONFIGURE_FLAGS = \
--enable-mbim-qmux \
$(NULL)
+ChangeLog:
+ $(AM_V_GEN) if test -d "$(srcdir)/.git"; then \
+ (GIT_DIR=$(top_srcdir)/.git $(top_srcdir)/missing --run git log --stat) | fmt --split-only > $@.tmp \
+ && mv -f $@.tmp $@ \
+ || ($(RM) $@.tmp; \
+ echo Failed to generate ChangeLog, your ChangeLog may be outdated >&2; \
+ (test -f $@ || echo git-log is required to generate this file >> $@)); \
+ else \
+ test -f $@ || \
+ (echo A git checkout and git-log is required to generate ChangeLog >&2 && \
+ echo A git checkout and git-log is required to generate this file >> $@); \
+ fi
+
EXTRA_DIST = \
gtester.make \
COPYING.LIB