1 message in com.mysql.lists.win32Errors when compiling 4.0.5a with emb...
FromSent OnAttachments
Lukas Zapletal05 Dec 2002 10:01 
Subject:Errors when compiling 4.0.5a with embedded server
From:Lukas Zapletal (lz@root.cz)
Date:12/05/2002 10:01:19 AM
List:com.mysql.lists.win32

Dears I want to compile static embedded library for linking to my program.

I have downloaded newest 4.0.5a beta version and run:

~> configure --with-charset=latin2 --with-embedded-server ~> make

It worked for several minutes and then this linker error occurred:

Making all in examples make[3]: Entering directory `/usr/src/mysql-4.0.3-beta/libmysqld/examples' gcc -DEMBEDDED_LIBRARY -I../../include -I. -I../.. - I../../client -O3 -DDBUG_OFF -c mysqltest.c /bin/sh ../../libtool --mode=link gcc -O3 -DDBUG_OFF -rdynamic -o mysqltest mysqltest.o ../libmysqld.a -lrt -ldl -lpthread -lz -lcrypt - lnsl -lm -lpthread mkdir .libs gcc -O3 -DDBUG_OFF -rdynamic -o mysqltest mysqltest.o ../libmysqld.a -lrt - ldl -lpthread -lz -lcrypt -lnsl -lm -lpthread ../libmysqld.a(handler.o)(.gnu.linkonce.d._ZTV7handler+0x3c): undefined reference to `__cxa_pure_virtual' ../libmysqld.a(handler.o)(.gnu.linkonce.d._ZTV7handler+0x44): undefined reference to `__cxa_pure_virtual' ../libmysqld.a(handler.o)(.gnu.linkonce.d._ZTV7handler+0x48): undefined reference to `__cxa_pure_virtual' ../libmysqld.a(handler.o)(.gnu.linkonce.d._ZTV7handler+0x4c): undefined reference to `__cxa_pure_virtual' ../libmysqld.a(handler.o)(.gnu.linkonce.d._ZTV7handler+0x50): undefined reference to `__cxa_pure_virtual' ../libmysqld.a(handler.o)(.gnu.linkonce.d._ZTV7handler+0x54): more undefined references to `__cxa_pure_virtual' follow ../libmysqld.a(hostname.o): In function `hostname_cache_init()': hostname.o(.text+0xad): undefined reference to `operator new(unsigned)' ../libmysqld.a(hostname.o): In function `hostname_cache_free()': hostname.o(.text+0x1af): undefined reference to `operator delete(void*)' ../libmysqld.a(item.o)(.gnu.linkonce.d._ZTV9Item_buff+0x8): undefined reference to `__cxa_pure_virtual' ../libmysqld.a(item.o)(.gnu.linkonce.d._ZTV17Item_result_field+0x28): undefined reference to `__cxa_pure_virtual'

... etc many pages of same errors ...

../libmysqld.a(sql_analyse.o): In function `analyse::~analyse [in-charge deleting]()': sql_analyse.o(.gnu.linkonce.t._ZN7analyseD0Ev+0x4a): undefined reference to `operator delete(void*)' collect2: ld returned 1 exit status make[3]: *** [mysqltest] Error 1 make[3]: Leaving directory `/usr/src/mysql-4.0.3-beta/libmysqld/examples' make[2]: *** [all-recursive] Error 1 make[2]: Leaving directory `/usr/src/mysql-4.0.3-beta/libmysqld' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/usr/src/mysql-4.0.3-beta' make: *** [all-recursive-am] Error 2

The libmysqld.a is created, but when I want to use it it produces a link error with crypt library. Even when I have ctrypt library installed...

I have Mandrake 9.0 with gcc 3.x.

What can I do for succesful compile? Can anyone help me? Thanks!

The error when linking with (probably not properly created) libmysqld.a follows:

MySQLVFS.o: In function `MySQLVFS::MySQLVFS[not-in-charge]()': MySQLVFS.o(.text+0x24): undefined reference to `vtable for MySQLVFS' MySQLVFS.o: In function `MySQLVFS::MySQLVFS[in-charge]()': MySQLVFS.o(.text+0xe4): undefined reference to `vtable for MySQLVFS' MySQLVFS.o: In function `MySQLVFS::~MySQLVFS [not-in-charge]()': MySQLVFS.o(.text+0x191): undefined reference to `vtable for MySQLVFS' MySQLVFS.o: In function `MySQLVFS::~MySQLVFS [in-charge]()': MySQLVFS.o(.text+0x221): undefined reference to `vtable for MySQLVFS' MySQLVFS.o: In function `MySQLVFS::~MySQLVFS [in-charge deleting]()': MySQLVFS.o(.text+0x2b1): undefined reference to `vtable for MySQLVFS' ./linux_libs/lib/libmysqld.a(item_strfunc.o): In function `Item_func_encrypt::val_str(String*)': item_strfunc.o(.text+0x245e): undefined reference to `crypt' collect2: ld returned 1 exit status make: *** [SiteOnCD] Error 1

ps - ANYONE knows what these VTABLE errors means?