[Xapian-discuss] FIXMEs in Search::Xapian

Olly Betts olly at survex.com
Sun Sep 5 15:57:23 BST 2010


On Fri, Sep 03, 2010 at 05:55:41PM +0100, Tim Brody wrote:
> On Fri, 2010-09-03 at 11:49 +0100, Olly Betts wrote:
> > These were done for GSoC last year by Kosei Moriyama on a branch.  He
> > expressed interest in doing the merging and integration work himself,
> > but I think he's been busy with his academic work since.  I've Cc:-ed
> > him on this mail in case he wants to get involved.
> > 
> > I've just performed a merge from current trunk to the branch, which was
> > pretty painless, and the tests all still pass, so I've committed that.
> 
> I'll admit to being totally lost in the SWIG bindings.

Conceptually, it's pretty easy - it just generates XS stuff by parsing the
C++ headers and using rules called "typemaps" (some are built-in, some are
custom).

> According to the GSoC "director"-based callbacks aren't implemented in
> SWIG? Can SWIG Perl-space callbacks be implemented by hand?
> (e.g. PerlStopper)

This is probably the main remaining issue.

Current releases of SWIG don't support directors for Perl, but there's a
branch in SWIG SVN where this is implemented, which I believe is in a
pretty good state now.  Kosei tried it, but there were some problems (I
don't recall what though) and time was short so we stuck to SWIG trunk.
It's been about a year now, so whatever was the issue may have been fixed
anyway.

It should be possible to do it by hand if necessary (since you can
generate pretty much whatever wrapping code you want if you write the
typemaps required), but it would be less code for us to maintain if SWIG
takes care of it.

Cheers,
    Olly



More information about the Xapian-discuss mailing list