Shared libraries allow the loading of commonly used portions of program
code from one location. Normally, when a program is generated from source
code, all the required machine code generated by the compiler is linked
together into a single exectuable.<p>
Many programs, however, use common functions and routines that are defined
as part of the C "standard library". With shared libraries, these
functions (and others by design of programmers) don't get linked into the
executable when the program is built; rather, they are kept in a central
location. When the program is run, a special program called ld.so loads
the requested functions from the central repository. The net result is a
dramatic decrease in the size of executable files.
Fred Dushin
fadushin@top.cis.syr.edu fadushin@top.cis.syr.edu |