0

This probably already has an answer but I couldn't find it.

I want to know which shared object is used by the binary (based on LD_LIBRARY_PATH, /etc/ld.so.conf, etc...). Something similar to the which command but for .so.

Thanks

Elad Weiss
  • 3,662
  • 3
  • 22
  • 50
  • [How do I find the direct shared object dependencies of a Linux binary?](https://stackoverflow.com/q/6242761/608639), [How to find out the dynamic libraries executables loads when run](https://unix.stackexchange.com/q/120015/56041), [How to check what shared libraries are loaded at run time for a given process?](https://stackoverflow.com/q/5103443/608639), [See currently loaded Shared Objects in Linux](https://superuser.com/q/310199/173513), [How do I know which shared libraries are loaded by an already running process?](https://superuser.com/q/324729/173513), etc. – jww Dec 19 '17 at 13:37

1 Answers1

3

You should use the ldd utility. In the same environment you would load your executable (Same LD_LIBRARY_PATH, e.t.c.)

EFraim
  • 12,811
  • 4
  • 46
  • 62