Al Hoang

August 25, 2003

OS X’s version of ldd

Filed under: mac, osx, unix — hoanga @ 8:28 pm

I’m used to using ldd to help list shared libraries for programs in UNIX-land. If you’re a UNIX Admin type person or a UNIX developer ldd is really valuable for trying to figure out what an executable file needs to run.Naturally I tried to use ldd on OS X and noticed this:

(555)  lddbash: ldd: command not found

OS X has a different tool called otool which handles that functionality. Here’s an example:

(556)  otool -L ruby
ruby:
/usr/local/lib/libruby.dylib (compatibility version 1.8.0, current version 1.8.0)
/usr/lib/libobjc.A.dylib (compatibility version 1.0.0, current version 218.0.0)
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 63.0.0)

Happy otool’ing

Share and Enjoy:
  • Digg
  • del.icio.us
  • Netvouz
  • DZone
  • ThisNext
  • Reddit
  • StumbleUpon
  • LinkedIn

Leave a Comment

You must be logged in to post a comment.

Powered by WordPress

Protected by AkismetBlog with WordPress