[cheese] Fix and simplify ChangeLog generation



commit 58435542326898dec2735941a32e23aaa6f2e4a0
Author: David King <amigadave amigadave com>
Date:   Sat Dec 24 19:50:46 2011 +0100

    Fix and simplify ChangeLog generation

 Makefile.am |   20 ++++++--------------
 1 files changed, 6 insertions(+), 14 deletions(-)
---
diff --git a/Makefile.am b/Makefile.am
index ec878da..126eba0 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -547,20 +547,12 @@ DISTCHECK_CONFIGURE_FLAGS = --enable-gtk-doc --enable-introspection --enable-man
 CHANGELOG_START = 2.26.0
 
 git-changelog-hook:
-	$(AM_V_at)if test -d "$(srcdir)/.git"; \
-	then \
-		echo Creating ChangeLog && \
-		( cd "$(top_srcdir)" && \
-		  echo '# Generated by Makefile. Do not edit.'; echo; \
-		  $(top_srcdir)/missing --run git log $(CHANGELOG_START).. \
-			--stat -M -C --name-status --no-color ) | \
-			fmt --split-only > ChangeLog.tmp \
-		&& mv -f ChangeLog.tmp $(top_distdir)/ChangeLog \
-		|| ( rm -f ChangeLog.tmp ; \
-		  echo Failed to generate ChangeLog >&2 ); \
-	else \
-		echo A git clone is required to generate a ChangeLog >&2; \
-	fi
+	$(AM_V_at)if $(top_srcdir)/build-aux/missing --run git \
+		--git-dir=$(top_srcdir)/.git --work-tree=$(top_srcdir) log \
+		--stat -M -C --name-status --no-color $(CHANGELOG_START).. \
+		| fmt --split-only >.ChangeLog.tmp; \
+	then mv -f .ChangeLog.tmp "$(top_distdir)/ChangeLog"; \
+	else rm -f .ChangeLog.tmp; exit 1; fi
 
 .PHONY: docs git-changelog-hook test test-report perf-report full-report
 .PHONY: lcov lcov-clean



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]