Getting PyLucene up on Ubuntu was amazingly easy, considering the Voodoo involved in making it run.  Great job to everyone here who is involved.  With my limited ability to be helpful, I wrote up a quick step-by-step on getting PyLucene going under Ubuntu-Breezy.  I'll put it here, and if anyone has any suggestions on where else it could be useful, let me know.

matt

The following is a quick overview on how to install pylucene on a clean installation of Ubuntu-5.10.

1) Install ubuntu in server mode by typing "server" at the boot prompt after starting the machine.  Follow installation through normally, and come back here when you are logged into a shell.

2) I installed emacs.  If you use some other text editor, then translate these commands as necessary.
$sudo apt-get install emacs21

3) Edit /etc/apt/sources.list. Comment out the cdrom source, and uncomment everything else.  One note, when I did\ this backports wasn't available yet, so I left it commented out

4) refresh your source list.
$sudo apt-get update

5) Get the packages that pyLucene depends on.  This will pull in a whole bunch of dependencies.  Just roll with i\t.
$ sudo apt-get install python-dev gcj libgcj6-common libgcj6-dev swig make patch fastjar


6) Your going to have to build pylucene from source because of a discrepancy between the compiler used to build Python, and the one that is installed.  I used PyLucene release 1.0.
$ wget http://downloads.osafoundation.org/PyLucene/src/PyLucene-1.0.tar.gz

7) untar PyLucene, and head inside
$ tar -xvzpf PyLucene-1.0.tar.gz
$ cd PyLucene-1.0

8) Next its time to configure the make file.  Uncomment the "Linux" section, and make it look as follows. Note, if you use BerkelyDB, you'll want to uncomment those last two lines, and make sure they are set up properly.
# Linux
PREFIX=/usr
PREFIX_PYTHON=$(PREFIX)
SWIG=$(PREFIX)/bin/swig
GCJ_HOME=/usr
GCJ_VER=4
#DB=$(PYLUCENE)/db-$(DB_VER)
#PREFIX_DB=$(PREFIX)/BerkeleyDB.$(DB_LIB_VER)

9) We are almost home.  Its time to build and install.
$ make all
$ make install

10) That should all go well, and if it does, its Miller Time.  You can checkout the tests directory to make sure.  I must say that for the black magic that gcj/swig/PyLucene perform, this is amazingly simple to get running.  Kudos to all involved in the project.



_______________________________________________
pylucene-dev mailing list
[email protected]
http://lists.osafoundation.org/mailman/listinfo/pylucene-dev

Reply via email to