This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
Undefined reference : very strange linking problem...
- From: Sébastien ZINSIUS <sebastien dot zinsius at ersa-france dot com>
- To: <gcc-help at gcc dot gnu dot org>
- Date: Mon, 6 Sep 2004 12:06:35 +0200
- Subject: Undefined reference : very strange linking problem...
Hello all!
I have a very strange linking problem... I'm working on a quite complex project written in C++ and compiled/linked with g++.
This project includes a lot of libraries. I recently added 3 new classes (one base class and two classes inheriting the first) to the A library. This library is used by library B. Finally, application is linked with both libraries.
Everything worked sofar but this times I got strange undefined references when linking (only with the two classes inheriting the third, but I don't know if it is related). I checked header files (#ifdef, class names, method names...), libraries linking order (but that always worked...) and everything is OK. Compilation also succeeds and when I use classes directly (not through libraries) or when I use them through library A it works!!
That's why I suspect something with library B. It seems that there is an overflow somewhere (to many symbols defined in library)... Is this possible? Is there any solution? Any other idea?
Thanks in anticipation!
Sébastien