arm-hisiv交叉编译linux下valgrind,并使用valgrind 调试程序运行信息
source link: https://blog.popkx.com/arm-hisiv-cross-compile-linux-valgrind-and-debug-program/
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
arm-hisiv交叉编译linux下valgrind,并使用valgrind 调试程序运行信息
Valgrind是一款用于内存调试、内存泄漏检测以及性能分析的软件开发工具。
- wget http://valgrind.org/downloads/valgrind-3.9.0.tar.bz2
tar xvf valgrind-3.9.0.tar.bz2
cd valgrind-3.9.0
apt-get install automake
./autogen.sh
- 修改configure
armv7) 改成 armv7|arm)
./configure --host=arm-linux CC=arm-none-linux-gnueabi-gcc CPP=arm-none-linux-gnueabi-cpp CXX=arm-none-linux-gnueabi-g++ --prefix=./valgrind
make install
注意:--prefix=/opt/Valgrind指定的目录要与开发板上放置的目录一致,不然运行valgrind时可能会出现“valgrind: failed to start tool 'memcheck' for platform 'arm-linux': No such file or directory”错误。
./configure --prefix=$PWD/../embed --host=arm-hisiv300-linux
阅读更多: Linux笔记
Recommend
About Joyk
Aggregate valuable and interesting links.
Joyk means Joy of geeK