From 089afbb6a68086cacc8672acea9f9d5ce13dead4 Mon Sep 17 00:00:00 2001 From: David King Date: Fri, 26 Oct 2012 13:36:48 +0100 Subject: [PATCH] Generate ChangeLog from git during make dist --- Makefile.am | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/Makefile.am b/Makefile.am index 3d7f24e..86b3a55 100644 --- a/Makefile.am +++ b/Makefile.am @@ -16,5 +16,17 @@ dist_noinst_DATA = \ $(libsignondoc_DATA) \ m4/introspection.m4 +dist-hook: git-changelog-hook + +git-changelog-hook: Makefile + $(AM_V_at)if $(top_srcdir)/build-aux/missing --run git \ + --git-dir=$(top_srcdir)/.git --work-tree=$(top_srcdir) log \ + --no-merges --date=short --pretty='tformat:%cd %an <%ae>%n%n%s%n%n%b' | \ + $(SED) -e '/[^ ]/,/^[ ]*$$/ !d' > .ChangeLog.tmp; \ + then mv -f .ChangeLog.tmp "$(top_distdir)/ChangeLog"; \ + else rm -f .ChangeLog.tmp; exit 1; fi + DISTCLEANFILES = \ $(pkgconfig_DATA) + +.PHONY: git-changelog-hook -- 2.7.4