summaryrefslogtreecommitdiff
path: root/Makefile.am
diff options
context:
space:
mode:
authorPádraig Brady <P@draigBrady.com>2014-04-19 12:45:11 +0100
committerPádraig Brady <P@draigBrady.com>2014-04-25 01:27:07 +0100
commit2f8d53a7989bf172931bfe5cfc7f7c4a9dbdd9ed (patch)
tree6f9bd68fcdc3ecdedf159f8161a58452f5f6eac3 /Makefile.am
parent0c6928f70369626a9b734f2b8beb231acf1c0230 (diff)
downloadcoreutils-2f8d53a7989bf172931bfe5cfc7f7c4a9dbdd9ed.tar.xz
maint: make ChangeLog generation more robust
* Makefile.am (gen-ChangeLog): Sync changes from GNU hello, to ensure exit status is propagated, and to support an optional git-log-fix file.
Diffstat (limited to 'Makefile.am')
-rw-r--r--Makefile.am9
1 files changed, 5 insertions, 4 deletions
diff --git a/Makefile.am b/Makefile.am
index 8a38acd8c..7eb2d5cba 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -105,11 +105,12 @@ gen_start_date = 2008-02-08
.PHONY: gen-ChangeLog
gen-ChangeLog:
$(AM_V_GEN)if test -d .git; then \
+ log_fix="$(srcdir)/build-aux/git-log-fix"; \
+ test -e "$$log_fix" && amend_git_log="--amend=$$log_fix"; \
$(top_srcdir)/build-aux/gitlog-to-changelog \
- --amend=$(srcdir)/build-aux/git-log-fix \
- --since=$(gen_start_date) > $(distdir)/cl-t; \
- rm -f $(distdir)/ChangeLog; \
- mv $(distdir)/cl-t $(distdir)/ChangeLog; \
+ $$amend_git_log --since=$(gen_start_date) > $(distdir)/cl-t && \
+ { rm -f $(distdir)/ChangeLog && \
+ mv $(distdir)/cl-t $(distdir)/ChangeLog; } \
fi
ALL_RECURSIVE_TARGETS += distcheck-hook