Mercurial > hg > octave-kai > gnulib-hg
changeset 16119:f15f3510d84c
valgrind-tests.m4: Avoid breakage if valgrind on bash fails.
* m4/valgrind-tests.m4: Check that the parameters that will be
used works, not just a subset of them. Reported by Bruno Haible
<bruno@clisp.org>.
author | Simon Josefsson <simon@josefsson.org> |
---|---|
date | Fri, 25 Nov 2011 00:20:17 +0100 |
parents | adc7476b18ed |
children | ff91f9a60967 |
files | ChangeLog m4/valgrind-tests.m4 |
diffstat | 2 files changed, 13 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2011-11-25 Simon Josefsson <simon@josefsson.org> + + valgrind-tests.m4: Avoid breakage if valgrind on bash fails. + * m4/valgrind-tests.m4: Check that the parameters that will be + used works, not just a subset of them. Reported by Bruno Haible + <bruno@clisp.org>. + 2011-11-24 Jim Meyering <meyering@redhat.com> test-stdalign.c: comment out long double tests
--- a/m4/valgrind-tests.m4 +++ b/m4/valgrind-tests.m4 @@ -1,4 +1,4 @@ -# valgrind-tests.m4 serial 2 +# valgrind-tests.m4 serial 3 dnl Copyright (C) 2008-2011 Free Software Foundation, Inc. dnl This file is free software; the Free Software Foundation dnl gives unlimited permission to copy and/or distribute it, @@ -21,9 +21,12 @@ AC_CHECK_PROGS(VALGRIND, valgrind) fi - if test -n "$VALGRIND" && $VALGRIND -q true > /dev/null 2>&1; then + OPTS="-q --error-exitcode=1 --leak-check=full" + + if test -n "$VALGRIND" \ + && $VALGRIND $OPTS $SHELL -c 'exit 0' > /dev/null 2>&1; then opt_valgrind_tests=yes - VALGRIND="$VALGRIND -q --error-exitcode=1 --leak-check=full" + VALGRIND="$VALGRIND $OPTS" else opt_valgrind_tests=no VALGRIND=