emacs-diffs
[Top][All Lists]
Advanced

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

[Emacs-diffs] master e0c7e10: * Makefile.in (ChangeLog): No longer pass


From: Glenn Morris
Subject: [Emacs-diffs] master e0c7e10: * Makefile.in (ChangeLog): No longer pass "srcprefix"; cd instead.
Date: Sat, 09 May 2015 01:34:38 +0000

branch: master
commit e0c7e102cf0f8636af2bff0c0eefdf4bb669ac38
Author: Glenn Morris <address@hidden>
Commit: Glenn Morris <address@hidden>

    * Makefile.in (ChangeLog): No longer pass "srcprefix"; cd instead.
    
    * build-aux/gitlog-to-emacslog: Check called from right directory.
    (srcprefix): Remove.
---
 Makefile.in                  |    4 ++--
 build-aux/gitlog-to-emacslog |   12 +++++++++---
 2 files changed, 11 insertions(+), 5 deletions(-)

diff --git a/Makefile.in b/Makefile.in
index 8b5d6f7..2fdbf8d 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -1102,8 +1102,8 @@ CHANGELOG_N = ChangeLog.$(CHANGELOG_HISTORY_INDEX_MAX)
 # Convert git commit log to ChangeLog file.  make-dist uses this.
 # I guess this is PHONY so it always updates?
 ChangeLog:
-       $(AM_V_GEN)srcprefix=$(srcdir)/ \
-       $(emacslog) -o $(CHANGELOG) -n $(CHANGELOG_HISTORY_INDEX_MAX)
+       $(AM_V_GEN)cd $(srcdir) && \
+         $(emacslog) -o $(CHANGELOG) -n $(CHANGELOG_HISTORY_INDEX_MAX)
 
 # Check that we are in a good state for changing history.
 master-branch-is-current:
diff --git a/build-aux/gitlog-to-emacslog b/build-aux/gitlog-to-emacslog
index 4cf2ed6..134acf2 100755
--- a/build-aux/gitlog-to-emacslog
+++ b/build-aux/gitlog-to-emacslog
@@ -39,19 +39,25 @@ while [ $# -gt 0 ]; do
   shift
 done
 
+if [ ! -f ChangeLog.$nmax ]; then
+    echo "Can't find ChangeLog.$nmax" >&2
+    echo "Must be run from the top source directory" >&2
+    exit 1
+fi
+
 if [ -f "$output" ]; then
-    [ ! "$force" ] && echo "$output exists" && exit 1
+    [ ! "$force" ] && echo "$output exists" >&2 && exit 1
     rm -f "$output" || exit 1
 fi
 
 # If this is not a Git repository, just generate an empty ChangeLog.
-test -d ${srcprefix}.git || {
+test -d .git || {
   >"$output"
   exit
 }
 
 # Use Gnulib's packaged ChangeLog generator.
-${srcprefix}build-aux/gitlog-to-changelog --ignore-matching='^; ' \
+./build-aux/gitlog-to-changelog --ignore-matching='^; ' \
   --format='%B' \
   "$gen_origin.." >"ChangeLog.tmp" || exit
 



reply via email to

[Prev in Thread] Current Thread [Next in Thread]