#!/bin/sh # Simple script to run valgrind in the make demo chroot. # # Author: Martin Sjögren # # Usage: Put 'valgrind' in one of the pkglists, create the demo root # as usual, but change e.g. the Makefile or some program's postinst to # run a program through run-valgrind. Remember to redirect the output # to a smart place. For example, # run-valgrind /usr/bin/main-menu 9> /tmp/VALGRIND.LOG cd /etc/default [ -e valgrind.dpkg-new ] && mv valgrind.dpkg-new valgrind cd / /usr/bin/valgrind -v --show-reachable=yes --leak-check=yes --logfile-fd=9 "$@"