[Xapian-discuss] Xapian version number available from Python?

Olly Betts olly at survex.com
Tue Sep 13 14:43:34 BST 2005


On Tue, Sep 13, 2005 at 02:35:39PM +0100, Tim Brody wrote:
> Amir Bakhtiar wrote:
> >Is the xapian version number embedded in the library and is it 
> >accessible from the Python bindings?
> 
> I don't know about the python bindings, but the xapian-config tool is 
> there to provide versioning and path information for the library.
> 
> $ xapian-config --version
> xapian 0.9.2

There's also these defines which are set by "#include <xapian.h>":

#define XAPIAN_VERSION "0.9.2" 
#define XAPIAN_MAJOR_VERSION 0 
#define XAPIAN_MINOR_VERSION 9 
#define XAPIAN_REVISION 2 

But both of these are the version you're compiling against, which with
dynamic libraries may not be the same as the version you're actually
running with (if the ABIs are compatible you could be using a newer or
even an older version!)

There's not current a method in the library to report this information
(and hence the bindings can't report it) but arguably there should be.

Cheers,
    Olly



More information about the Xapian-discuss mailing list