valgrind是一个用于内存调试、内存泄漏检测的软件开发工具
下载路径:Index of /pub/valgrind (sourceware.org)
编译安装./autogen.sh
./configure --host=mips-linux-gnu CFLAGS="-D__UCLIBC__ -muclibc" --prefix=/tmp/nfs
make
make install
可能遇到的问题 aclocal not found解决方案:
apt-get install automake autoconf
apt-get install libtool
autoreconf -ivf
valgrind: Fatal error at startup: a function redirection
可能是库被strip了
apt-get install libc6-dbg
使用valgrind --log-file=valgrind.log --tool=memcheck --leak-check=full ./a.out



