summaryrefslogtreecommitdiff
path: root/scripts/tartan-build
blob: c6d5a402efe2b359b9fcc61e37d5f92a6edbdfe9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#!/bin/sh

clang_bin_dir=`dirname "$0"`

if which tartan &> /dev/null; then
	tartan=`which tartan`
elif [ -x $clang_bin_dir/tartan ]; then
	tartan="$clang_bin_dir/tartan"
else
	echo "Error: Could not find tartan script. Make sure Tartan is installed in your PATH." >& 2
	exit 1
fi

if [ "$V" = "1" ]; then
	echo scan-build --use-analyzer "$tartan" "${@}"
fi

exec scan-build --use-analyzer "$tartan" "${@}"