From 97136cb93fa4f54e37ba34c9cdd14655243155a9 Mon Sep 17 00:00:00 2001 From: Jim Meyering Date: Mon, 27 Nov 2006 14:38:35 +0100 Subject: [PATCH] * Makefile.maint (patch-check): Rewrite to diagnose failure. * src/c99-to-c89.diff: Adjust shred.c offsets. --- ChangeLog | 5 +++++ Makefile.maint | 13 +++++++------ src/c99-to-c89.diff | 2 +- 3 files changed, 13 insertions(+), 7 deletions(-) diff --git a/ChangeLog b/ChangeLog index 1a0a4bf..5249da1 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2006-11-27 Jim Meyering + + * Makefile.maint (patch-check): Rewrite to diagnose failure. + * src/c99-to-c89.diff: Adjust shred.c offsets. + 2006-11-26 Paul Eggert Improve the check for departures from C89, and fix the departures diff --git a/Makefile.maint b/Makefile.maint index 821a53c..f4e961f 100644 --- a/Makefile.maint +++ b/Makefile.maint @@ -330,15 +330,16 @@ patch-check: cp -a src src-c89 (cd src-c89; patch -V never --fuzz=0) < src/c99-to-c89.diff \ > $@.1 2>&1 - grep -v '^patching file ' $@.1 > $@.2 || : if test "$${REGEN_PATCH+set}" = set; then \ diff -upr src src-c89 > new-diff || : ; fi - fail=0; test -s $@.2 && fail=1 || : ; \ - rm -f src-c89/*.o || fail=1; \ + grep -v '^patching file ' $@.1 > $@.2 || : + msg=ok; test -s $@.2 && msg='fuzzy patch' || : ; \ + rm -f src-c89/*.o || msg='rm failed'; \ $(MAKE) -C src-c89 CFLAGS='-Wdeclaration-after-statement -Werror' \ - || fail=1; \ - rm -rf src-c89 $@.1 $@.2; \ - test $$fail = 0 + || msg='compile failure with extra options'; \ + rm -rf src-c89 $@.1 $@.2; \ + test $$msg = ok && : || echo "$$msg" 1>&2; \ + test $$msg = ok # Ensure that date's --help output stays in sync with the info # documentation for GNU strftime. The only exception is %N, diff --git a/src/c99-to-c89.diff b/src/c99-to-c89.diff index 57e9835..dc33dd6 100644 --- a/src/c99-to-c89.diff +++ b/src/c99-to-c89.diff @@ -90,7 +90,7 @@ retrieving revision 1.130 diff -u -p -r1.130 shred.c --- shred.c 3 Sep 2006 02:53:16 -0000 1.130 +++ shred.c 3 Oct 2006 13:48:24 -0000 -@@ -460,7 +460,7 @@ dopass (int fd, char const *qname, off_t +@@ -464,7 +464,7 @@ dopass (int fd, char const *qname, off_t out. Thus, it shouldn't give up on bad blocks. This code works because lim is always a multiple of SECTOR_SIZE, except at the end. */ -- 2.7.4