[Xapian-discuss] Python bindings...

Chris McDonough chrism at plope.com
Tue Aug 30 22:48:58 BST 2005


Hi all,

I just got a hold of the 0.9.2 stable and SVN trunk sources in an
attempt to build Xapian on Linux for use with its Python bindings.

I am having some difficulty.  The 0.9.2 sources build fine and using
simpleindex.py works ok, but just as per this bug report from a bit ago:

http://lists.tartarus.org/pipermail/xapian-discuss/2005-June/000944.html

... simplesearch.py does not.  It fails with "NotImplementedError: No
matching function for overloaded 'new_Query'".

If I take the try: except: out of simplesearch I end up with this
traceback on both Ubuntu Warty and Fedora Core 4 when attempting to use
that module after creating a database with simpleindex:

~/projects/revelation/bin/python simplesearch.py foo cms
Traceback (most recent call last):
  File "simplesearch.py", line 42, in ?
    query = xapian.Query(xapian.Query.OP_OR, terms)
  File
"/home/chrism/projects/revelation/opt/Python-2.3.5/lib/python2.3/site-packages/xapian.py", line 663, in __init__
    newobj = _xapian.new_Query(*args)
NotImplementedError: No matching function for overloaded 'new_Query'

I have attempted this on FC4 and Ubuntu with the same result (actually I
needed to patch a header file for the sources to compile on FC4 due to
what I think is some extra pickiness of GCC4, but after compilation, the
same errors happen at runtime).  

So I figured I'd try out the latest SVN trunk to see if it built its
Python bindings more correctly, but when I grab the SVN co, run
"./bootstrap" and then cd to "xapian-core" and run "configure; make", I
wind up with this compile-time error which appears to be an error in the
configure-generated makefile:

make[2]: *** No rule to make target `queryparser_internal.cc', needed by
`queryparser_internal.lo'.  Stop.
make[2]: Leaving directory
`/home/chrism/projects/revelation/build/xapian-core-20050621/queryparser'
make[1]: *** [install] Error 2
make[1]: Leaving directory
`/home/chrism/projects/revelation/build/xapian-core-20050621/queryparser'
make: *** [install-recursive] Error 1

This was not configured with maintainer-mode if it makes a difference.
I tried checking out an older version with an arbitrary tag from cvs,
e.g.:

svn co --revision {07-21-2005} .... 

... and wind up in the same place with the queryparser makefile problem.

I'm not too picky about which version I use as long as I can get one
going that seems to be able to index and search from Python.  Hoping
someone has run into one or both of the above problems and can provide
help.

My next step is to try to take a look at the build that is part of the
RPM spec file or .deb package to see if I'm just doing something dumb
during compilation but any help would be appreciated.

- C





More information about the Xapian-discuss mailing list