summaryrefslogtreecommitdiff
path: root/scripts/valgrind.sh
blob: 9d0eec6ce914b783bd8f31f7cebd6ff1a11eeed5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
#!/usr/bin/env bash

set -e
set -o pipefail

.mason/mason install valgrind 3.12.0

PARAMS="\
    --track-origins=yes \
    --leak-check=full \
    --show-leak-kinds=definite \
    --errors-for-leak-kinds=definite \
    --error-exitcode=1 \
    --gen-suppressions=all \
    --suppressions=scripts/valgrind.sup"

export VALGRIND_LIB=$(.mason/mason prefix valgrind 3.12.0)/lib/valgrind

$(.mason/mason prefix valgrind 3.12.0)/bin/valgrind $PARAMS $@