blob: addf39eb41e46559e9f1fd1be716299f0b40bb8f [file] [log] [blame]
Rolf Badorekef2bf512019-08-20 11:17:15 +03001#!/bin/sh
2
3export TOP_SRCDIR="@top_srcdir@"
4
5TESTRUNNER="./testrunner"
6if test "$USE_VALGRIND" != "false" ; then
7 VALGRIND="$(which valgrind 2> /dev/null)"
8 if test $? != 0 ; then
9 unset VALGRIND
10 echo "valgrind not found, valgrind disabled"
11 else
12 export VALGRIND
13 echo "valgrind enabled"
14 export GTEST_DEATH_TEST_USE_FORK=1
15 if test -z "$VALGRIND_SUPPRESSIONS" ; then
16 export VALGRIND_SUPPRESSIONS="${TOP_SRCDIR}/tst/valgrind-suppressions.conf"
17 fi
18 fi
19else
20 unset VALGRIND
21 echo "valgrind disabled"
22fi
23if test -z "$GTEST_DEATH_TEST_STYLE" ; then
24 export GTEST_DEATH_TEST_STYLE="threadsafe"
25fi
26exec "$TESTRUNNER"