Ticket #573: pydoc.diff

File pydoc.diff, 2.0 KB (added by James Aylett, 13 years ago)

Untested patch (build system is hosed on my netbook)

  • xapian-bindings/python/Makefile.am

    diff --git a/xapian-bindings/python/Makefile.am b/xapian-bindings/python/Makefile.am
    index 789c197..5895223 100644
    a b _xapian_la_LIBADD = $(XAPIAN_LIBS) $(PYTHON_LIBS)  
    5757# versions so we can't let the .pyc and .pyo files get written there.  Hence we
    5858# copy the .py file to the build directory from wherever it actually is and use
    5959# the copy.  We also rename the copy to __init__.py so that it can be installed
    60 # in a "xapian" directory and be treated as a package.
     60# in a "xapian" directory and be treated as a package. Finally, we take this
     61# opportunity to drop a module doc string at the top of the file.
    6162xapian/__init__.py: modern/xapian.py
    6263        -test -d xapian || mkdir xapian
    63         cp `test -f modern/xapian.py || echo '$(srcdir)/'`modern/xapian.py xapian/__init__.py
     64        cp $(srcdir)/module_top.py xapian/__init__.py
     65        cat `test -f modern/xapian.py || echo '$(srcdir)/'`modern/xapian.py >> xapian/__init__.py
    6466
    6567# We "import _xapian" first so that if we fail to import the glue library
    6668# we don't generate a broken __init__.pyc or __init__.pyo.
  • new file xapian-bindings/python/module_top.py

    diff --git a/xapian-bindings/python/module_top.py b/xapian-bindings/python/module_top.py
    new file mode 100644
    index 0000000..2b75ca2
    - +  
     1"""
     2Xapian is a highly adaptable toolkit which allows developers to easily
     3add advanced indexing and search facilities to their own
     4applications. It supports the Probabilistic Information Retrieval
     5model and also supports a rich set of boolean query operators.
     6
     7In addition to the doc strings provided by this python library, you
     8may wish to look at the library's overall documentation, either
     9installed along with the bindings or online at
     10<http://xapian.org/docs/bindings/python/>, as well as the library's
     11documentation, possibly installed with the library or with its
     12development files, or again online at <http://xapian.org/docs/>.
     13"""