diff options
Diffstat (limited to 'tests/cond29.test')
-rwxr-xr-x | tests/cond29.test | 31 |
1 files changed, 19 insertions, 12 deletions
diff --git a/tests/cond29.test b/tests/cond29.test index f2488504c..222743c98 100755 --- a/tests/cond29.test +++ b/tests/cond29.test @@ -21,11 +21,12 @@ # possible combinations of conditionals (it would do this five times, # to define a01_DEPENDENCIES, a02_DEPENDENCIES, a03_OBJECTS, # a04_OBJECTS, and to rewrite bin_PROGRAM), eating all memory, swap, -# or cpu time it can found. Although this test won't print `FAIL' if -# it fails, it will take long enough so it can't go unnoticed. +# or cpu time it can found. . ./defs || Exit 1 +timeout 10s true || skip_ "timeout command not found" + echo AC_PROG_CC >>configure.in cat >Makefile.am <<EOF @@ -35,17 +36,23 @@ a03_SOURCES = EOF for i in 01 02 03 04 05 06 07 08 09 10 11 12 13 14 15 16 17 18 19 20 21 22; do -cat >>Makefile.am <<EOF -if C$i -bin_PROGRAMS += a$i -a01_LDADD = foo${i}.o -a02_LDADD += bar${i}.o -a03_SOURCES += baz${i}.c -a04_SOURCES = quux${i}.c -endif C$i + unindent >>Makefile.am <<EOF + if C$i + bin_PROGRAMS += a$i + a01_LDADD = foo${i}.o + a02_LDADD += bar${i}.o + a03_SOURCES += baz${i}.c + a04_SOURCES = quux${i}.c + endif C$i EOF -echo "AM_CONDITIONAL([C$i], [:])" >>configure.in + echo "AM_CONDITIONAL([C$i], [:])" >>configure.in done $ACLOCAL -$AUTOMAKE +# Be lax w.r.t. the timeout for low-priority processes on heavily +# loaded systems. +niceness=`nice || echo 0` +case $niceness in [0-9]*);; *) niceness=0;; esac +timeout `expr 60 '+' $niceness '*' 20`s $AUTOMAKE + +: |