summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorRalf Wildenhues <Ralf.Wildenhues@gmx.de>2011-01-16 13:48:17 +0100
committerRalf Wildenhues <Ralf.Wildenhues@gmx.de>2011-01-16 17:59:12 +0100
commit080efc945a834569156c2fc11e7623853e1bdd04 (patch)
tree5b74a75992a9eee2b80d74b5f745696f3716a47a /lib
parent87073880107cef3f162305b8681f1cb4826ce623 (diff)
downloadautomake-080efc945a834569156c2fc11e7623853e1bdd04.tar.gz
parallel-tests: work around Tru64/OSF 5.1 sh read bugs.
* lib/am/check.am ($(TEST_SUITE_LOG), recheck, recheck-html): Test file readability before redirecting input from it, to avoid exiting Tru64/OSF 5.1 sh which treats read as special builtin. * tests/parallel-tests-unreadable-log.test: New test. * tests/Makefile.am (TESTS): Update. * NEWS: Update. Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
Diffstat (limited to 'lib')
-rw-r--r--lib/Automake/tests/Makefile.in7
-rw-r--r--lib/am/check.am11
2 files changed, 10 insertions, 8 deletions
diff --git a/lib/Automake/tests/Makefile.in b/lib/Automake/tests/Makefile.in
index 4b2c57f22..b4940db79 100644
--- a/lib/Automake/tests/Makefile.in
+++ b/lib/Automake/tests/Makefile.in
@@ -324,7 +324,8 @@ $(TEST_SUITE_LOG): $(TEST_LOGS)
@$(am__sh_e_setup); \
list='$(TEST_LOGS)'; \
results=`for f in $$list; do \
- read line < $$f && echo "$$line" || echo FAIL; \
+ test -r $$f && read line < $$f && echo "$$line" \
+ || echo FAIL; \
done`; \
all=`echo "$$results" | sed '/^$$/d' | wc -l | sed -e 's/^[ ]*//'`; \
fail=`echo "$$results" | grep -c '^FAIL'`; \
@@ -373,7 +374,7 @@ $(TEST_SUITE_LOG): $(TEST_LOGS)
echo ".. contents:: :depth: 2"; \
echo; \
for f in $$list; do \
- read line < $$f; \
+ test -r $$f && read line < $$f || line=; \
case $$line in \
PASS:*|XFAIL:*);; \
*) echo; cat $$f;; \
@@ -437,7 +438,7 @@ recheck recheck-html:
list='$(TEST_LOGS)'; \
list=`for f in $$list; do \
test -f $$f || continue; \
- if read line < $$f; then \
+ if test -r $$f && read line < $$f; then \
case $$line in FAIL*|XPASS*) echo $$f;; esac; \
else echo $$f; fi; \
done | tr '\012\015' ' '`; \
diff --git a/lib/am/check.am b/lib/am/check.am
index c953be877..572808143 100644
--- a/lib/am/check.am
+++ b/lib/am/check.am
@@ -1,6 +1,6 @@
## automake - create Makefile.in from Makefile.am
-## Copyright (C) 2001, 2003, 2006, 2007, 2008, 2009, 2010 Free Software
-## Foundation, Inc.
+## Copyright (C) 2001, 2003, 2006, 2007, 2008, 2009, 2010, 2011 Free
+## Software Foundation, Inc.
## This program is free software; you can redistribute it and/or modify
## it under the terms of the GNU General Public License as published by
@@ -146,7 +146,8 @@ $(TEST_SUITE_LOG): $(TEST_LOGS)
@$(am__sh_e_setup); \
list='$(TEST_LOGS)'; \
results=`for f in $$list; do \
- read line < $$f && echo "$$line" || echo FAIL; \
+ test -r $$f && read line < $$f && echo "$$line" \
+ || echo FAIL; \
done`; \
all=`echo "$$results" | sed '/^$$/d' | wc -l | sed -e 's/^[ ]*//'`; \
fail=`echo "$$results" | grep -c '^FAIL'`; \
@@ -195,7 +196,7 @@ $(TEST_SUITE_LOG): $(TEST_LOGS)
echo ".. contents:: :depth: 2"; \
echo; \
for f in $$list; do \
- read line < $$f; \
+ test -r $$f && read line < $$f || line=; \
case $$line in \
PASS:*|XFAIL:*);; \
*) echo; cat $$f;; \
@@ -287,7 +288,7 @@ recheck recheck-html:
list='$(TEST_LOGS)'; \
list=`for f in $$list; do \
test -f $$f || continue; \
- if read line < $$f; then \
+ if test -r $$f && read line < $$f; then \
case $$line in FAIL*|XPASS*) echo $$f;; esac; \
else echo $$f; fi; \
done | tr '\012\015' ' '`; \