meson.build: hook up the static symbols leak test

And because bash on F31 is leaking, we need an extra valgrind suppression.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
This commit is contained in:
Peter Hutterer 2020-02-18 19:31:43 +10:00
parent d654a8edf8
commit d7098601c8
3 changed files with 13 additions and 1 deletions

View file

@ -190,6 +190,7 @@ if dep_check.found()
valgrind_env = environment()
valgrind_env.set('CK_TIMEOUT_MULTIPLIER', '10')
valgrind_env.set('CK_FORK', 'no')
valgrind_env.set('RUNNING_ON_VALGRIND', '1')
valgrind_suppressions_file = join_paths(dir_src_test, 'valgrind.suppressions')
add_test_setup('valgrind',
exe_wrapper: [ valgrind,
@ -203,7 +204,9 @@ if dep_check.found()
message('valgrind not found, disabling valgrind test suite')
endif
# FIXME: static link test
test_static_link = find_program('test/test-static-symbols-leak.sh')
test('static-symbols-leak', test_static_link,
args: [meson.current_build_dir()])
endif
doxygen = find_program('doxygen', required: get_option('documentation'))

View file

@ -5,6 +5,8 @@
# Note the spaces in the expressions! After the first grep, each line
# is " T symbol_name"
test -z "$RUNNING_ON_VALGRIND" || exit 77
builddir="$1"
test -f "$builddir/test-static-link" || (echo "Unable to find test file" && exit 1)

View file

@ -18,3 +18,10 @@
fun:ioctl
fun:test_revoke*
}
{
<bash_memleak>
Memcheck:Leak
...
fun:reader_loop
fun:main
}