# $Id: README,v 1.4 2004/12/13 19:36:50 gmf Exp $

Python module for Sleepycat's Berkeley DB XML library
Copyright (c) 2003-2004 Sleepycat Software

INTRODUCTION

This module is built using SWIG (http://www.swig.org) to produce a
Python module that maps to the Berkeley DB XML C++ API fairly closely.
At present, separate documentation for the Python API is not provided.
Refer to the C++ API documentation and the Python examples for more
information, or contact Sleepycat Support (support@sleepycat.com).

BUILD REQUIREMENTS

To build and install this module, you first need:

  * Python 2.3 or newer

  * an installed version of the bsddb3 Python module that supports 
    DB 4.3 (http://pybsddb.sourceforge.net).  Note: this module has been
    accepted into the Python core, and ships with Python 2.3 and
    above.  Also, note that this module must be compiled against the
    same version of Berkeley DB you are building Berkeley DB XML
    against.

  * a working build of Berkeley DB XML compiled with the same C++
    compiler as Python.

This module uses the standard Python distutils to control building and
installing into the Python tree.  It is assumed that you have
already built Berkeley DB Python support, and it is installed.

BUILDING

1.  edit setup.py, and ensure that the paths to all libraries
are accurate.  These are the defaults, which may not match your
installation:
  db_home = "/usr/local/BerkeleyDB.4.3"
  xerces_home = "/usr/local"
  pathan_home = "/usr/local"
  xquery_home = "/usr/local/xquery-1.0.3"
For example, if you've built the Unix platform using buildall.sh
and default settings, you'll need:
  db_home = "<path_to_dbxml-2.0.7>/install"
  xerces_home = "<path_to_dbxml-2.0.7>/install"
  pathan_home = "<path_to_dbxml-2.0.7>/install"
  xquery_home = "<path_to_dbxml-2.0.7>/install"

2. Run the build:

    python setup.py build

3. Install:

    python setup.py install

TESTING

The Python examples are in the directory examples/python in the top of the
Berkeley DB XML tree.  Once this module is installed, the examples can
be run in that directory with:

    python examples.py test

If you want to test before installing, you will need to build and set
PYTHONPATH to include the build directory (src/python/build/lib.*).

For more information, contact Sleepycat Support (support@sleepycat.com).
