Mac OS X系统上类似 ldd 的工具
ldd是用来查看一个可执行文件中包括对哪些共享库的调用,但是在MAC OX X下似乎没有ldd,取而代之的是另一个叫otool的命令,使用该命令的-L命令可以实现ldd的功能。
ldd on Mac OS X
"ldd" in various flavors of Unix is used to check which dynamic libraries are used by the executable. There is no "ldd" command in Mac OS X (Convenient, huh?). Instead, Apple provides something that is talled "otool", which has many different options. One of them is "-L", which displays the linked libraries:
sparrow (13:18)$ otool -L h3dpost.x
h3dpost.x:
/opt/local/lib/libmpi.0.dylib (compatibility version 1.0.0, current version 1.0.0)
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 111.1.3)
/opt/local/lib/libmpi_f77.0.dylib (compatibility version 1.0.0, current version 1.0.0)
/opt/local/lib/libopen-rte.0.dylib (compatibility version 1.0.0, current version 1.0.0)
/opt/local/lib/libopen-pal.0.dylib (compatibility version 1.0.0, current version 1.0.0)
/usr/local/lib/libgfortran.3.dylib (compatibility version 4.0.0, current version 4.0.0)
/usr/local/lib/libgcc_s.1.dylib (compatibility version 1.0.0, current version 1.0.0)
from: http://schumakov.info/howto-osx.php
没有评论:
发表评论