This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
undefined reference to virtual table
- From: Nathan Taylor <Nathan dot Taylor at DilithiumNetworks dot com>
- To: gcc-help at gcc dot gnu dot org
- Date: Wed, 15 May 2002 11:53:34 +1000
- Subject: undefined reference to virtual table
- References: <1021426607.29502.ezmlm@gcc.gnu.org>
Hi,
I am attempting to port a C++ application from Windows to Linux. I am able to
compile it but when I attempt to link it I get hundreds of error messages
that say:
"Undefined reference to CLASSNAME virtual table"
Where classname is the name of the classes in my program. I have browsed
aroung on the web and found a reference to a problem that sounds like this in
the FAQ's at http://www.gnu.org/software/libc/FAQ.html#s-2.21.
It mentions that there is a known issue when using libg++ 2.7.2 (the version
that I am using) with the GNU C libraries due to vtable thunks however it
fails to mention a fix.
Can anyone shed some light on this problem?.
I am using Redhat 7.1 (gcc-2.96). I have also replecated this problem on
Redhat 6.2 and Redhat 7.3.
Thanks
Nathan