The linker uses the following search paths to locate required
shared libraries.
1. Any directories specified by -rpath-link options.
2. Any directories specified by -rpath options. The difference
between -rpath and -rpath-link is that directories specified by
-rpath options are included in the executable and used at run-
time, whereas the -rpath-link option is only effective at link
time. It is for the native linker only.
3. On an ELF system, if the -rpath and "rpath-link" options were
not used, search the contents of the environment variable
"LD_RUN_PATH". It is for the native linker only.
4. On SunOS, if the -rpath option was not used, search any direc-
tories specified using -L options.
5. For a native linker, the contents of the environment variable
"LD_LIBRARY_PATH".
6. For a native ELF linker, the directories in "DT_RUNPATH" or
"DT_RPATH" of a shared library are searched for shared
libraries needed by it. The "DT_RPATH" entries are ignored if
"DT_RUNPATH" entries exist.
7. The default directories, normally /lib and /usr/lib.
8. For a native linker on an ELF system, if the file
/etc/ld.so.conf exists, the list of directories found in that
file.
民主不同于专制,不需要强加于人。--- 賴斯
大道之行也,天下为公,选贤与能,讲信修睦。故人不独亲其亲,不独子其子,使老有所终,壮有所用,幼有所长,矜、寡、孤、独、废疾者,皆有所养。男有分,女有归。货恶其弃於地也,不必藏於己;力恶其不出於身也,不必为己。是故,谋闭而不兴,盗窃乱贼而不作,故外户而不闭,是谓大同。--《礼运·大同篇》