News:

When registered with our forums, feel free to send a "here I am" post here to differ human beings from SPAM bots.

Main Menu

Static member functions in static libs

Started by BruceGerdes, April 22, 2010, 07:01:53 PM

Previous topic - Next topic

BruceGerdes

I'm trying to link a program with several static (.a) libraries, one of which contains a couple of classes with all static member functions.  For some reason, the linker can't find those static member functions, reporting them as unresolved external references.  But if I convert the libraries to dynamic libraries (.so), the problem vanishes.  Has anybody seen this one?  (running Ubuntu 9.10 a64).

BruceGerdes

Found it.  The libs have to be in the right sequence when they are defined in the link options.  Work's fine now.