The dynamic linker and the runtime linker determine their search paths through a different algorithm from that used by the SunOS release 4.x linker.
The examples below compare the search paths for the dynamic linker and the runtime linker for SunOS release 4.x and the Solaris 2.6 operating environment. Notice that in the latter, the search path for the link editor and the runtime linker are affected by the LD_LIBRARY_PATH
setting.
SunOS release 4.x linker search paths:
Link Editor: -L, LD_LIBRARY_PATH
, /usr/lib, /usr/local/lib
Runtime Linker: LD_LIBRARY_PATH
, -L, /usr/lib, /usr/local/lib
Solaris 2.6 linker search paths (with LD_LIBRARY_PATH
=dirlist1):
Link Editor: -L, dirlist1, /usr/ccs/lib, /usr/lib
Runtime Linker: dirlist1, -R, /usr/lib
Solaris 2.6 linker search paths (with LD_LIBRARY_PATH
=dirlist1,dirlist2):
Link Editor: dirlist1, -L, dirlist2, /usr/ccs/lib, /usr/lib