]> git.ipfire.org Git - thirdparty/util-linux.git/commitdiff
tests: use libtool to execute with valgrind
authorKarel Zak <kzak@redhat.com>
Wed, 21 Mar 2018 11:23:22 +0000 (12:23 +0100)
committerKarel Zak <kzak@redhat.com>
Wed, 21 Mar 2018 11:23:22 +0000 (12:23 +0100)
The libtool based build system uses scripts rather than real binaries
in $top_builddir. It's necessary to use libtool --mode=execute to call
valgrind for the real binary (from .libs/).

Signed-off-by: Karel Zak <kzak@redhat.com>
tests/functions.sh

index 0f991881a38d81be5d4e47cc0f765988f6cb0e21..2fb0ddb5f42459d032da70b3a59676f0dbb43d24 100644 (file)
@@ -393,6 +393,7 @@ function ts_run {
        # valgrind mode
        #
        if [ -n "$TS_VALGRIND_CMD" ]; then
+               libtool --mode=execute \
                $TS_VALGRIND_CMD --tool=memcheck --leak-check=full \
                                 --leak-resolution=high --num-callers=20 \
                                 --log-file="$TS_VGDUMP" "$@"