strace for mtk ARM linux 编译安装
strace工具是一个非常强大的工具,是调试程序的好工具。http://www.ibm.com/developerworks/cn/aix/library/au-unix-strace.html
要移植到arm平台,就需要使用交叉编译工具编译生成静态链接的可执行文件。
具体步骤如下:
1.下载 strace-4.11.tar.xz,下载网址是:http://sourceforge.net/projects/strace/
2.解压。tar -Jxvf strace-4.11.tar.xz对于ARM平台,必须打上一个补丁,补丁在文章的最后面;
1.下载 strace-4.11.tar.xz,下载网址是:http://sourceforge.net/projects/strace/
2.解压。tar -Jxvf strace-4.11.tar.xz
(最新版不需要)
3.配置。./configure --host=arm-linux CC=armv7a-mediatek482_001_neon-linux-gnueabi-gcc LD=armv7a-mediatek482_001_neon-linux-gnueabi-ld
4.编译。make CFLAGS+="-static",生成strace静态可执行文件,2M多;
5.strip。armv7a-mediatek482_001_neon-linux-gnueabi-strip strace,这样可执行文件就减小到900多K。
3.配置。./configure --host=arm-linux CC=armv7a-mediatek482_001_neon-linux-gnueabi-gcc LD=armv7a-mediatek482_001_neon-linux-gnueabi-ld
4.编译。make CFLAGS+="-static",生成strace静态可执行文件,2M多;
5.strip。armv7a-mediatek482_001_neon-linux-gnueabi-strip strace,这样可执行文件就减小到900多K。
本作品采用 知识共享署名-相同方式共享 4.0 国际许可协议 进行许可。