ldd (Linux)
ldd prints the shared libraries required by each program or shared library specified on the command line. (use otool on Mac OS X)
Example: Want to know which Linux thread library java is linked to?
ldd /usr/java/jre1.5.0_11/bin/java libpthread.so.0 => /lib/tls/libpthread.so.0 (0x00bd4000) libdl.so.2 => /lib/libdl.so.2 (0x00b87000) libc.so.6 => /lib/tls/libc.so.6 (0x00a5a000) /lib/ld-linux.so.2 (0x00a3c000)