[Xapian-discuss] problem building python bindings

James Aylett james-xapian at tartarus.org
Tue Aug 21 20:59:19 BST 2007


On Tue, Aug 21, 2007 at 07:56:16PM +0200, Marcus Rueckert wrote:

> > Okay, I've forgotten the context. But something it trying to cast
> > (int*) and (long*) to each other somehow. It should work one way, it
> > won't work the other. I suspect that hacking the file in question to
> > replace (int*) with (long*) or (Py_ssize_t*) will fix it.
> 
> no. imho the real fix would be using ssize_t in the xapian/swig code in
> first place. so you dont overrun it by accident on 64bit architectures.
> or cut off the wrong part when assigning a long to this int on bigendian
> 64bit.

I'm pretty sure that Xapian never uses (int*) for anything in the API,
which suggests this is actually a SWIG bug. We typedef our own stuff
at the library level in almost all cases anyway.

We have some 32 bit restrictions in the library at the moment which
we'll work on at some point. Most of them aren't serious restrictions
in most practical cases. (> 2^32 documents? ;-)

J

-- 
/--------------------------------------------------------------------------\
  James Aylett                                                  xapian.org
  james at tartarus.org                               uncertaintydivision.org



More information about the Xapian-discuss mailing list