[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: coreutils-8.12.178-df9cd on OpenBSD 4.9
From: |
Jim Meyering |
Subject: |
Re: coreutils-8.12.178-df9cd on OpenBSD 4.9 |
Date: |
Fri, 02 Sep 2011 14:08:19 +0200 |
Pádraig Brady wrote:
> On 09/02/2011 01:37 AM, Bruno Haible wrote:
>> It looks like your check in tests/init.sh is too pessimistic:
>>
>> if ( diff --version < /dev/null 2>&1 | grep GNU ) > /dev/null 2>&1; then
>> compare () { diff -u "$@"; }
>>
>> Change that to
>>
>> if ( diff -u "$0" "$0" < /dev/null ) > /dev/null 2>&1; then
>> compare () { diff -u "$@"; }
>>
>> and you should receive better output.
>
> I think the source of that is gnulib/tests/init.sh
> So feel free to apply the above change there
> and all projects can then sync from that as required.
Right.
I'm applying this in coreutils, and will eventually propagate it to gnulib:
>From 31d1ccdd6d148013a0a405c9af4fd93dc0f1ec69 Mon Sep 17 00:00:00 2001
From: Bruno Haible <address@hidden>
Date: Fri, 2 Sep 2011 10:51:52 +0200
Subject: [PATCH] tests: init.sh: work also with any non-GNU diff that
supports -u
* tests/init.sh: Relax check for diff -u support.
Rather than checking for GNU diff via --version, simply check
for support for -u itself. Useful at least on OpenBSD 4.9.
---
tests/init.sh | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/tests/init.sh b/tests/init.sh
index 460937d..12b3ca3 100644
--- a/tests/init.sh
+++ b/tests/init.sh
@@ -221,7 +221,7 @@ export MALLOC_PERTURB_
# a partition, or to undo any other global state changes.
cleanup_ () { :; }
-if ( diff --version < /dev/null 2>&1 | grep GNU ) > /dev/null 2>&1; then
+if ( diff -u "$0" "$0" < /dev/null ) > /dev/null 2>&1; then
compare () { diff -u "$@"; }
elif ( cmp --version < /dev/null 2>&1 | grep GNU ) > /dev/null 2>&1; then
compare () { cmp -s "$@"; }
--
1.7.7.rc0.362.g5a14
- Re: coreutils-8.12.178-df9cd on OpenBSD 4.9, (continued)
- Re: coreutils-8.12.178-df9cd on OpenBSD 4.9, Jim Meyering, 2011/09/01
- Re: coreutils-8.12.178-df9cd on OpenBSD 4.9, Jim Meyering, 2011/09/01
- Re: coreutils-8.12.178-df9cd on OpenBSD 4.9, Bruno Haible, 2011/09/01
- Re: coreutils-8.12.178-df9cd on OpenBSD 4.9, Pádraig Brady, 2011/09/02
- Re: coreutils-8.12.178-df9cd on OpenBSD 4.9, Bruno Haible, 2011/09/02
- Re: coreutils-8.12.178-df9cd on OpenBSD 4.9, Pádraig Brady, 2011/09/02
- Re: coreutils-8.12.178-df9cd on OpenBSD 4.9, Jim Meyering, 2011/09/02
- Re: coreutils-8.12.178-df9cd on OpenBSD 4.9, Pádraig Brady, 2011/09/02
- Re: coreutils-8.12.178-df9cd on OpenBSD 4.9,
Jim Meyering <=
Re: coreutils-8.12.178-df9cd on OpenBSD 4.9, Pádraig Brady, 2011/09/01
coreutils-8.12.178-df9cd on AIX, Bruno Haible, 2011/09/01
Re: coreutils-8.12.178-df9cd on AIX, Jim Meyering, 2011/09/01
coreutils-8.12.178-df9cd on HP-UX 11, Bruno Haible, 2011/09/01
Re: [Platform-testers] new snapshot available: coreutils-8.12.178-df9cd, Pádraig Brady, 2011/09/01