diff mbox

compare_tests

Message ID 497CC05F-67AF-466B-ABA8-72B671952007@comcast.net
State New
Headers show

Commit Message

Mike Stump May 13, 2013, 5:52 p.m. UTC
So, it turns out that comm on macosx does't like long lines.  Don't know why that is, kinda unfortunate, but life goes on.
2013-05-13  Mike Stump  <mikestump@comcast.net>

	* compare_tests: Limit lines to 2000 characters as comm on Mac OS
	X 10.8.3 doesn't like long lines (those 2055 characters or more).
diff mbox

Patch

Index: compare_tests
===================================================================
--- compare_tests	(revision 198796)
+++ compare_tests	(working copy)
@@ -2,6 +2,9 @@ 
 # This script automatically test the given tool with the tool's test cases,
 # reporting anything of interest.
 
+# Written by Mike Stump <mrs@cygnus.com>
+# Subdir comparison added by Quentin Neill <quentin.neill@amd.com>
+
 usage()
 {
 	if [ -n "$1" ] ; then
@@ -29,9 +32,6 @@  EOUSAGE
 	exit 2
 }
 
-# Written by Mike Stump <mrs@cygnus.com>
-# Subdir comparison added by Quentin Neill <quentin.neill@amd.com>
-
 export LC_ALL=C
 
 tool=gxx
@@ -107,8 +107,8 @@  elif [ -d "$1" -o -d "$2" ] ; then
 	usage "Must specify either two directories or two files"
 fi
 
-sed 's/^XFAIL/FAIL/; s/^XPASS/PASS/' < "$1" | awk '/^Running target / {target = $3} { if (target != "unix") { sub(/: /, "&"target": " ); }; print $0; }' >$tmp1
-sed 's/^XFAIL/FAIL/; s/^XPASS/PASS/' < "$2" | awk '/^Running target / {target = $3} { if (target != "unix") { sub(/: /, "&"target": " ); }; print $0; }' >$tmp2
+sed 's/^XFAIL/FAIL/; s/^XPASS/PASS/' < "$1" | awk '/^Running target / {target = $3} { if (target != "unix") { sub(/: /, "&"target": " ); }; print $0; }' | cut -c1-2000 >$tmp1
+sed 's/^XFAIL/FAIL/; s/^XPASS/PASS/' < "$2" | awk '/^Running target / {target = $3} { if (target != "unix") { sub(/: /, "&"target": " ); }; print $0; }' | cut -c1-2000 >$tmp2
 
 before=$tmp1
 now=$tmp2