交叉编译器ldd [英] cross compiler ldd

查看:45
本文介绍了交叉编译器ldd的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我创建了一个交叉编译的 arm 可执行文件.我想找到可执行文件的库依赖项.我正在使用 ubuntu natty 并安装了 arm-linux-gnueabi 工具链,其中不包含 ldd.有没有可以查看linux中arm可执行文件库依赖的工具.

I have created a cross compiled arm executable. I want to find the library dependency of the executable. I am using ubuntu natty and installed arm-linux-gnueabi tool chain, which does not contain ldd. Is there a tool available to view arm executables library dependancy in linux.

推荐答案

这有点麻烦,但它是我能找到的最好的解决方案,而且它对于基本使用确实非常有效 - 只需将此脚本保存为"arm-none-linux-gnueabi-ldd"与您的其他交叉工具.

This is a bit of a kluge, but it's the best solution I could find, and it really works quite well for basic use - just save this script as "arm-none-linux-gnueabi-ldd" with your other cross tools.

#!/bin/sh
arm-none-linux-gnueabi-readelf -a $1 | grep "Shared library:"

这篇关于交叉编译器ldd的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆