[pylucene-dev] PyLucene throws segmentation fault in Debian
vajda at osafoundation.org
Thu Feb 21 08:47:49 PST 2008
On Feb 20, 2008, at 22:42, Roopesh <roopesh.raj at gmail.com> wrote:
> Dear Sir,
> I have compiled PyLucene from source using gcc-3.2.2 in my Debian
> system. But when I use it in my Turbogears project it crashes the
> program with a Segmentation fault. Segmentation fault occurs when I
> try to instantiate a Document (doc = Document()). What can be the
> reason for this. Is it the problem with compilation process? Or is
> it something to do with Turbogears?
> Given below are the changes I have done in the MakeFile of PyLucene.
> PYLUCENE:=$(shell pwd)
> #DB_LIB_VER=$(basename $(DB_VER))
> # Linux (with gcc 3.4.4 and libgcj statically linked)
> LIB_INSTALL=libstdc++.so.6 libgcc_s.so.1
> ifeq ($(OS),Linux)
Several problems here. You appear to be using gcj-pylucene which has
been superseded by jcc-pylucene (see
http://pylucene.osafoundation.org for more info).
Also, gcc 3.2.2 is too old, gcj 3.4.x
(x >= 2) is required for gcj-pylucene.
And finally, the crash you describe could be related to calling a
lucene API from an unitialized thread. With gcj-pylucene, this is
tricky do right in a web framework (search the list archives). With
jcc-pylucene, you must call env.attachCurrentThread() first from
threads other than the main thread.
> pylucene-dev mailing list
> pylucene-dev at osafoundation.org
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the pylucene-dev