New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
seg fault when calling bsddb.hashopen() #40599
Comments
Fresh 2.3.4 build (didn't even install!) on Mandrake Python 2.3.4 (#1, Jul 19 2004, 16:02:09)
[GCC 3.0.1] on linux2
Type "help", "copyright", "credits" or "license" for
more information.
>>> import bsddb
>>> bsddb.__file__
'/home/skip/src/Python-2.3.4/Lib/bsddb/__init__.pyc'
>>> bsddb.hashopen("foo.db", "c") Program received signal SIGSEGV, Segmentation fault. ldd tells me this is how it's linked: % ldd build/lib.linux-i686-2.3/_bsddb.so What's the oldest Berkeley DB usable with the Skip |
Logged In: YES I downloaded and installed BerkDB 4.2.52, then rebuilt bsddb % ./python
Python 2.3.4 (#1, Jul 19 2004, 16:02:09)
[GCC 3.0.1] on linux2
Type "help", "copyright", "credits" or "license" for more
information.
>>> import bsddb
>>> bsddb.__file__
'/home/skip/src/Python-2.3.4/Lib/bsddb/__init__.pyc'
>>> bsddb.hashopen("junk.db", "c")
{}
>>>
You have new mail in /var/spool/mail/skip
% ldd build/lib.linux-i686-2.3/_bsddb.so
libdb-4.2.so => /usr/local/BerkeleyDB.4.2/lib/libdb-4.2.so
(0x40016000)
libgcc_s.so.1 => /usr/local/lib/libgcc_s.so.1 (0x400d4000)
libc.so.6 => /lib/libc.so.6 (0x400dc000)
/lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x80000000) |
Logged In: YES it -should- work with 3.2 and later. that said, its been a from bsddb import db
print db.DB_VERSION_STRING
print 'bsddb.db.version(): %s' % (db.version(), )
print 'bsddb.db.__version__: %s' % db.__version__
print 'bsddb.db.cvsid: %s' % db.cvsid just to make sure that the header files it compiled with i'll built it against 3.2 and 3.3 later tonight and run the |
Logged In: YES I rebuilt it with 3.3, but noticed something I had missed when gcc -pthread -DNDEBUG -g -O3 -Wall -Wstrict-prototypes -fPIC \ gcc -pthread -shared build/temp.linux-i686-2.3/_bsddb.o \ Note that it searches /usr/local/BerkeleyDB.3.2/include for include >>> from bsddb import db
>>> print db.DB_VERSION_STRING
Sleepycat Software: Berkeley DB 3.2.9: (January 24, 2001)
>>> print 'bsddb.db.version(): %s' % (db.version(), )
bsddb.db.version(): (3, 3, 11)
>>> print 'bsddb.db.__version__: %s' % db.__version__
bsddb.db.__version__: 4.2.0.2
>>> print 'bsddb.db.cvsid: %s' % db.cvsid
bsddb.db.cvsid: $Id: _bsddb.c,v 1.17.6.4 2004/03/16 07:47:45
greg Exp $ I manually compiled without the -I flag and relinked. Opening It would thus appear to be a combination of an incomplete 3.2 I'll leave it for you to close. I don't know if it's worth comparing |
Logged In: YES I just committed a rewrite of the bsddb library+include file finding portion of python's setup.py. Could you try python CVS head on the system you had this problem on? It should now pick a properly paired header file and library version. |
Logged In: YES Skip, is this still a problem? |
Logged In: YES It's been ages. I'll assume Greg just didn't close it... |
Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
bugs.python.org fields:
The text was updated successfully, but these errors were encountered: