TOC   Previous   Next

Finding Shared Libraries at Run-time

The dynamic linker searches for shared libraries in the following order:

  1. If LD_LIBRARY_PATH is defined, then each of the colon-separated directories listed in its value is searched in turn.

  2. /etc/ld.so.cache is checked to see if it contains an entry for the library.

  3. /lib and /usr/lib are searched (in that order).

(C) 2006, Michael Kerrisk