Andi Vajda wrote:

[1] In FC5, PyLucene needs to be installed under lib64 rather than lib, oterwise it segfaults.

What is that lib64 directory ? If it is for 64 bit libs, PyLucene is not one of them.

FC5 x86-64 is 64-bit by default but retains backward compatibility with 32-bit apps. By default, I suppose PyLucene is being built as 64-bit. Attached are the changes I made to the Makefile in order to get it to work. Otherwise python was crashing when it tried to dlopen _PyLucene.so

Without the patch to gcj 4.1.0 I mentionned earlier, PyLucene will segfault as soon as garbage collection kicks in.
To verify that this is not the case:

  > python
  >>> import PyLucene
  >>> PyLucene.System.gc()

If this completes, you do not need the patch.

This segfaults, alright! This explains the funny behavior I've been seeing -- segfaults while creating a largish dictionary.

-- b
--- Makefile.orig	2006-04-07 10:31:15.000000000 +0530
+++ Makefile.new	2006-04-19 09:44:44.000000000 +0530
@@ -166,7 +166,7 @@
 else
 
 ifeq ($(OS),Linux)
-PYTHON_SITE=$(PREFIX_PYTHON)/lib/python$(PYTHON_VER)/site-packages
+PYTHON_SITE=$(PREFIX_PYTHON)/lib64/python$(PYTHON_VER)/site-packages
 PYTHON_INC=$(PREFIX_PYTHON)/include/python$(PYTHON_VER)
 PYLUCENE_LIB=$(BINDIR)/_PyLucene.so
 ifeq ($(DEBUG),1)
@@ -694,6 +694,12 @@
 all: env sources $(BINDIR) $(LIBS)
 	@echo build of $(PYLUCENE_LIB) complete
 
+uninstall:: all
+	rm $(PYTHON_SITE)/PyLucene.py 
+	rm $(PYTHON_SITE)/_PyLucene.so
+	rm $(PYTHON_SITE)/security/classpath.security
+	rm $(PYTHON_SITE)/security/libgcj.security 
+	
 install:: all
 	mkdir -p $(PYTHON_SITE)
 	install PyLucene.py $(PYTHON_SITE)
_______________________________________________
pylucene-dev mailing list
[email protected]
http://lists.osafoundation.org/mailman/listinfo/pylucene-dev

Reply via email to