X-Git-Url: http://erislabs.net/gitweb/?a=blobdiff_plain;ds=sidebyside;f=tests%2Ftest-exclude4.sh;h=f8650b1e5655b912da3410471f4989ebe1523f52;hb=370a139a641c5f9c659e44ee1554893f7d87e20f;hp=99c4c9fec1b023cde6533b30726f4753387831e6;hpb=d60f3b0c6b0f93a601acd1cfd3923f94ca05abb0;p=gnulib.git
diff --git a/tests/test-exclude4.sh b/tests/test-exclude4.sh
index 99c4c9fec..f8650b1e5 100755
--- a/tests/test-exclude4.sh
+++ b/tests/test-exclude4.sh
@@ -1,6 +1,6 @@
#! /bin/sh
# Test suite for exclude.
-# Copyright (C) 2009-2011 Free Software Foundation, Inc.
+# Copyright (C) 2009-2012 Free Software Foundation, Inc.
# This file is part of the GNUlib Library.
#
# This program is free software: you can redistribute it and/or modify
@@ -16,25 +16,30 @@
# You should have received a copy of the GNU General Public License
# along with this program. If not, see .
-TMP=excltmp.$$
-LIST=flist.$$
-ERR=0
+. "${srcdir=.}/init.sh"; path_prepend_ .
+fail=0
# Test wildcard matching
-cat > $LIST < in < $TMP < expected < out || exit $?
-rm -f $TMP $LIST
-exit $ERR
+# Find out how to remove carriage returns from output. Solaris /usr/ucb/tr
+# does not understand '\r'.
+case $(echo r | tr -d '\r') in '') cr='\015';; *) cr='\r';; esac
+
+# normalize output
+LC_ALL=C tr -d "$cr" < out > k && mv k out
+
+compare expected out || fail=1
+
+Exit $fail