summaryrefslogtreecommitdiff
path: root/Makefile.am
diff options
context:
space:
mode:
authorThomas Schwinge <thomas@codesourcery.com>2013-09-27 16:03:38 +0200
committerThomas Schwinge <thomas@codesourcery.com>2013-09-27 21:24:24 +0200
commita379640997753a1a84e667ef9f993f95b25c2ca9 (patch)
tree07b4cea7d9aea0ff64e35919c157c19b450664f0 /Makefile.am
parent1b773f28b1c108391b02c714ab345c56dc03ebae (diff)
Generate ChangeLog files for distributions.
* gitlog-to-changelog: New file; import from gnulib's 9fc81090f6c5590bd1b0e0fa5087577a2ee43a3e:build-aux/gitlog-to-changelog. * Makefile.am (gen-ChangeLog): New target. (dist-hook): Depend on it.
Diffstat (limited to 'Makefile.am')
-rw-r--r--Makefile.am20
1 files changed, 19 insertions, 1 deletions
diff --git a/Makefile.am b/Makefile.am
index 5f02b4de..918cdc39 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -196,7 +196,7 @@ EXTRA_DIST += \
EXTRA_DIST += \
DEVELOPMENT
-dist-hook: dist-rm-CVS
+dist-hook: dist-rm-CVS gen-ChangeLog
.PHONY: dist-rm-CVS
dist-rm-CVS:
@@ -207,6 +207,24 @@ dist-rm-CVS:
rmdir "$$d"; \
done
+gen_start_commit = e227045b06d62ee7d2fbab9d5ade9030ff43170b
+ChangeLog_files = ChangeLog ChangeLog.0 ChangeLog.00
+.PHONY: gen-ChangeLog
+gen-ChangeLog:
+ $(AM_V_GEN)if test -d $(top_srcdir)/.git; then \
+ (cd $(top_srcdir)/ && \
+ ./gitlog-to-changelog --strip-tab \
+ $(gen_start_commit).. && \
+ echo) >> $(distdir)/cl-t && \
+ for f in $(ChangeLog_files); do \
+ (cd $(top_srcdir)/ && \
+ git show $(gen_start_commit):$$f) >> $(distdir)/cl-t && \
+ rm -f $(distdir)/$$f && \
+ mv $(distdir)/cl-t $(distdir)/$$f \
+ || exit $$?; \
+ done; \
+ fi
+
DISTCLEANFILES += \
Makefile.orig \
config.status.orig