[ZODB-Dev] Re: pybsddb versions

Toby Dickenson tdickenson@geminidataloggers.com
Mon, 10 Dec 2001 12:02:09 +0000


On Friday 07 December 2001 4:25 pm, Toby Dickenson wrote:

>It still dumps core. 

Ive tracked down the cause of this core dump, and it seems to be related to 
the pybsddb distutils.....

This was my first use of distutils, so I was following the installation 
instruction closely. I built the extension module with:

 /usr/local/bin/python2.1 setup.py build_ext --inplace 
--berkeley-db=/usr/local/BerkeleyDB.3.3/ --lflags="-Xlinker -rpath -Xlinker 
/usr/local/BerkeleyDB.3.3/lib/"

then everything was fine when running the test suite.

I installed the extension module with:

 /usr/local/bin/python2.1 setup.py install

but then the installed version dumped core because it was linking to the 
RedHat-supplied libdb-3.1.so, not my freshly compiled 3.3 from /usr/local/

Looking in the build directory I see two subdirectories lib.linux-i686-2.1 
and temp.linux-i686-2.1. One contains the working version version I build 
originally, and which passed the tests. The second contains a *different* 
build that was created during the distutils install command. Of course this 
version was not compiled with the correct library search path.

I can create a working installation by specifying the extra command line 
options during the install:

 /usr/local/bin/python2.1 setup.py install 
--berkeley-db=/usr/local/BerkeleyDB.3.3/ --lflags="-Xlinker -rpath -Xlinker 
/usr/local/BerkeleyDB.3.3/lib/"