Undefined symbol __pure_virtual when importing MySQLdb

antonyliu2002 at yahoo.com antonyliu2002 at yahoo.com
Fri Jan 5 01:55:59 EST 2007


Fredrik Lundh wrote:
> antonyliu2002 at yahoo.com wrote:
>
> > I have googled hard, and did see someone asking the same question, but
> > haven't found a good solution to this problem.  Could anyone give me a
> > hint?  Thanks a lot!
>
> googling for "undefined symbol: __pure_virtual" brings up hundreds of
> posts on this topic, and the answer is *always* to make sure that you're
> linking with a version of the C++ libraries that matches your compiler.
>
> </F>

Hi, thanks.  I followed the strategy provided at the following url

http://www.mail-archive.com/dbi-users@perl.org/msg27851.html

by adding "-lmygcc" to the end of the librarys to link. I added it to
the end of this line in the mysql_config script like so:

   libs=" $ldflags -L$pkglibdir -lmysqlclient -lz -lcrypt -lnsl -lm
-lmygcc "

And then I recompiled the MySQL-python-1.2.1 package, but the same
problem remains.




More information about the Python-list mailing list