TCLUG Archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [TCLUG:2308] gtk+1.1.3



>>>>> "dopp" == dopp  <dopp@acm.cs.umn.edu> writes:


    dopp> Well, libglib.a doesn't point to anything, it's a 465492
    dopp> byte file, tho it isn't executable... should it be?  And
    dopp> libglib.so points to libglib-1.1.so.4.0.0 which is also not
    dopp> an exacutable file...  Do these files need to be executable?


libglib.a is the static library. It is actually added to the
executable when you compile it.

On the other hand, libglib-1.1.so is the shared library. Instead of
adding all of the code at compile time the linker (ld) adds a stub
function call for each function in the dynamic library. At run time the
dynamic loader: called something like ld-so or ld-linux.so (depending
on your os, elf vs. a.out, & other issues) loads the libglib-1.1.so
file and allows the program to call the correct function. The beauty
of this approach is that library developers can release new versions
of libraries (with in reason) and you don't have to recompile all of
your programs.

Andrew