MySQLdb and egenix mxDateTime dumps core

M.-A. Lemburg mal at
Thu Aug 7 09:46:55 CEST 2003

Dave Harrison wrote:
> M.-A. Lemburg (mal at
>>Dave Harrison wrote:
>>>Hi all, got a problem combinging mx and MySQLdb, when I build and install 
>>>both for my Python2.1 install on a Solaris 9 box I can import mx fine, but 
>>>importing MySQLdb causing python to core dump.
>>You hit an optimizer compiler bug on Solaris.
> *chuckle* so I noticed to my endless pain and suffering ;-D
>>The best thing to do, is to comment out these lines in
>>mx/DateTime/mxDateTime/mxDateTime.c (near the top):
>>/* Define these to have the module use free lists (saves malloc calls) */
>>and then recompile the egenix-mx-base package.
> Solaris being what it is, I think the better solution is to force the module compilations to simply disable the optimisations totally.  This isnt the kind of thing I really want to be doing every time I run across a tricky package.

That's easy: either reconfigure and install Python without optimization
on or edit the lib/python2.x/include/Makefile and replace "-O2" with "-O0"
(that's an O followed by a zero).

> Do you know if newer versions of GCC avoid this problem ? Im using version 3.2.2

No. We haven't switched to gcc 3.x yet -- it simply doesn't look
very stable yet.

BTW, you haven't by chance compiled Python in debug mode ?

>>>I am using egenenix 2.0.4 and MySQLdb 0.9.2.

Marc-Andre Lemburg

Professional Python Software directly from the Source  (#1, Aug 07 2003)
 >>> Python/Zope Products & Consulting ...
 >>> mxODBC, mxDateTime, mxTextTools ...

More information about the Python-list mailing list