Statically linking in a static library

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

I'm having trouble with statically linking.  I've created a static
library that statically links to other static libraries.  My hope by
doing this was so other users would only need to include one static
library when linking in their executable.  However when I nm the
created the static library all the references are unresolved.  Is
there an argument that will force the linker to resolve these symbols?

Example:

libA.a defines functionA.
libB.a defines functionB.

I create libC.a which statically links and uses both libA.a and libB.a.

When running nm libC.a the results show that neither functionA nor
functionB can be resolved so libA.a and libB.a also need to be
statically linked into the final executable.

Thank you,
Tony


[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux