--- python-xml-0.8.4.orig/demo/dom/generate_xml1.py
+++ python-xml-0.8.4/demo/dom/generate_xml1.py
@@ -14,16 +14,16 @@
#Create a document using document element namespace URI, doc element
#name and doctype. This automatically creates a document element
#which is the single element child of the document
- doc = implementation.createHTMLDocument('', 'mydoc', dt)
+ doc = implementation.createDocument(None, 'mydoc', dt)
#Get the document element
doc_elem = doc.documentElement
#Create an element: the Document instanmce acts as a factory
- new_elem = doc.createElementNS('', 'spam')
+ new_elem = doc.createElementNS(None, 'spam')
#Create an attribute on the new element
- new_elem.setAttributeNS('', 'eggs', 'sunnysideup')
+ new_elem.setAttributeNS(None, 'eggs', 'sunnysideup')
#Create a text node
new_text = doc.createTextNode('some text here...')
@@ -35,5 +35,5 @@
doc_elem.appendChild(new_elem)
#Print out the resulting document
- import xml.doc.ext
- xml.doc.ext.Print(doc)
+ from xml.dom import ext
+ ext.Print(doc)
--- python-xml-0.8.4.orig/demo/xmlproc/catalog.soc
+++ python-xml-0.8.4/demo/xmlproc/catalog.soc
@@ -13,7 +13,3 @@
PUBLIC "+//IDN python.org//DTD XML Bookmark Exchange Language 1.0//EN//XML"
"dtds/xbel-1.0.dtd"
--- If we can't find a system identifier for the public identifier here,
- then go to James Tauber's public catalog --
-
-DELEGATE "" "http://www.schema.net/public-text/catalog.soc"
\ No newline at end of file
--- python-xml-0.8.4.orig/doc/xmlproc/xmlproc.html
+++ python-xml-0.8.4/doc/xmlproc/xmlproc.html
@@ -49,7 +49,7 @@
xmlproc is free and you can do as you like with it. If you change it,
-please let me know. A formal BSD-ish
+please let me know. A formal BSD-ish
license is available.
--- python-xml-0.8.4.orig/extensions/boolean.c
+++ python-xml-0.8.4/extensions/boolean.c
@@ -111,7 +111,7 @@
static void
boolean_dealloc(PyObject *self)
{
- PyMem_DEL(self);
+ PyObject_Del(self);
}
static int
--- python-xml-0.8.4.orig/extensions/sgmlop.c
+++ python-xml-0.8.4/extensions/sgmlop.c
@@ -232,7 +232,7 @@
Py_XDECREF(self->handle_data);
Py_XDECREF(self->handle_cdata);
Py_XDECREF(self->handle_comment);
- PyMem_DEL(self);
+ PyObject_Del(self);
}
#define GETCB(member, name)\
@@ -509,7 +509,7 @@
RELEASE(sizeof(ElementObject), "destroy element");
- PyMem_DEL(self);
+ PyObject_Del(self);
}
/* -------------------------------------------------------------------- */
@@ -789,7 +789,7 @@
Py_XDECREF(self->last);
Py_XDECREF(self->this);
Py_DECREF(self->root);
- PyMem_DEL(self);
+ PyObject_Del(self);
}
/* -------------------------------------------------------------------- */
--- python-xml-0.8.4.orig/xml/parsers/xmlproc/xmlutils.py
+++ python-xml-0.8.4/xml/parsers/xmlproc/xmlutils.py
@@ -720,6 +720,7 @@
# to the recoding.
try:
self.data = self.charset_converter(self.data)
+ self.datasize = len(self.data)
except UnicodeError, e:
self._handle_decoding_error(self.data, e)
self.input_encoding = enc1
--- python-xml-0.8.4.orig/debian/xbel-utils.dirs
+++ python-xml-0.8.4/debian/xbel-utils.dirs
@@ -0,0 +1,3 @@
+usr/bin
+usr/lib/python2.3/site-packages/_xmlplus/xbel
+usr/share/doc/xbel-utils
--- python-xml-0.8.4.orig/debian/xbel-utils.manpages
+++ python-xml-0.8.4/debian/xbel-utils.manpages
@@ -0,0 +1,6 @@
+doc/man/adr_parse.1
+doc/man/lynx_parse.1
+doc/man/msie_parse.1
+doc/man/ns_parse.1
+doc/man/xbel2html.1
+doc/man/xbel_parse.1
--- python-xml-0.8.4.orig/debian/compat
+++ python-xml-0.8.4/debian/compat
@@ -0,0 +1 @@
+5
--- python-xml-0.8.4.orig/debian/rules
+++ python-xml-0.8.4/debian/rules
@@ -0,0 +1,223 @@
+#!/usr/bin/make -f
+# -*-Makefile-*-
+# Made with the aid of dh_make, by Craig Small
+# Sample debian/rules that uses debhelper. GNU copyright 1997 by Joey Hess.
+# Some lines taken from debmake, by Cristoph Lameter.
+
+# Uncomment this to turn on verbose mode.
+#export DH_VERBOSE=1
+
+DEFAULT_PYTHON := $(shell pyversions -d)
+VERSIONS := $(shell pyversions -vs)
+
+dest_xbel := debian/xbel
+dest_xbel_utils := debian/xbel-utils
+
+doc_xbel := $(dest_xbel)/usr/share/doc/xbel
+doc_xbel_utils := $(dest_xbel_utils)/usr/share/doc/xbel-utils
+EXTRA=debian/extra
+debian_patches=
+
+build: stamp-build
+stamp-build: $(VERSIONS:%=stamp-build-%)
+ touch $@
+stamp-build-%: patched-stamp
+ dh_testdir
+ python$* setup.py build --without-xslt
+ cp doc/man/xmlproc_parse.1 doc/man/xmlproc_parse.python$*-xml.1
+ cp doc/man/xmlproc_val.1 doc/man/xmlproc_val.python$*-xml.1
+
+ python$*-dbg setup.py build --without-xslt
+
+ touch $@
+
+clean: reverse-patches
+ dh_testdir
+ dh_testroot
+ rm -f stamp-*
+ rm -rf build dist
+ rm -f doc/man/xmlproc_*.python2.?-xml.1
+ find . -name "*.py[co]" -exec rm -f {} \;
+ rm -f debian/man/index.bt
+ dh_clean
+
+# Build architecture-independent files here.
+binary-indep:
+ dh_testdir -i
+ dh_testroot -i
+ dh_clean -k -i
+ dh_installdirs -i
+
+# xbel
+ install -m 0644 demo/xbel/doc/* $(doc_xbel)
+ install -m 0644 demo/xbel/README $(doc_xbel)
+ install -m 0644 demo/xbel/*.dtd $(dest_xbel)/usr/share/sgml/dtd
+ ln -s ../../dtd/xbel-1.0.dtd \
+ $(dest_xbel)/usr/share/sgml/IDN_python.org/dtd/XML_Bookmark_Exchange_Language_1.0
+ ln -s ../../dtd/xbel-1.1.dtd \
+ $(dest_xbel)/usr/share/sgml/IDN_python.org/dtd/XML_Bookmark_Exchange_Language_1.1
+ install -m 0644 debian/xbel.sgml-catalog $(dest_xbel)/usr/share/sgml/misc/xbel/xbel.cat
+
+# xbel_utils
+ install -m 0644 demo/xbel/README $(doc_xbel_utils)
+ mkdir -p $(dest_xbel_utils)/usr/lib/$(DEFAULT_PYTHON)/site-packages/_xmlplus/xbel
+ install -m 0644 demo/xbel/*.py \
+ $(dest_xbel_utils)/usr/lib/$(DEFAULT_PYTHON)/site-packages/_xmlplus/xbel
+ touch $(dest_xbel_utils)/usr/lib/$(DEFAULT_PYTHON)/site-packages/_xmlplus/xbel/__init__.py
+
+ set -e; \
+ cd $(dest_xbel_utils) && \
+ for i in `find -type f`; do \
+ if head -1 $$i | grep "^#! */usr/bin" | grep "python" >/dev/null ; then \
+ sed "s%#! */usr/bin/env \+python.*$\%#! /usr/bin/python%" <$$i >$$i.temp; \
+ mv $$i.temp $$i; \
+ chmod +x $$i; \
+ fi; \
+ done
+
+ for i in adr_parse lynx_parse msie_parse ns_parse xbel2html xbel_parse ; do \
+ ( \
+ echo "#! /bin/sh"; \
+ echo "ver=\$$(/usr/bin/python -c 'import sys; print sys.version[:3]')"; \
+ echo "exec /usr/bin/python /usr/lib/python\$$ver/site-packages/_xmlplus/xbel/$$i.py \"\$$@\""; \
+ ) > $(dest_xbel_utils)/usr/bin/$$i; \
+ done
+
+ dh_pycentral -i
+
+ dh_installdocs -i
+ dh_installman -pxbel-utils
+ dh_installchangelogs -i
+ dh_compress -i
+ dh_fixperms -i
+ dh_installdeb -i
+ dh_gencontrol -i
+ dh_md5sums -i
+ dh_builddeb -i
+
+# Build architecture-dependent files here.
+binary-arch: build
+ dh_testdir -a
+ dh_testroot -a
+ dh_clean -k -a
+ dh_installdirs -a
+ for version in $(VERSIONS) ; do \
+ PYTHON=python$${version} ; \
+ PACKAGE=python-xml ;\
+ DESTDIR=debian/$${PACKAGE} ;\
+ SITE_PACK=$${DESTDIR}/usr/lib/$${PYTHON}/site-packages/_xmlplus ;\
+ DOC=$${DESTDIR}/usr/share/doc/$${PACKAGE} ;\
+ $${PYTHON} setup.py install \
+ --without-xslt --no-compile --prefix=$${DESTDIR}/usr ;\
+ cp -R doc/* $${DOC} ;\
+ rm -rf $${DOC}/man ;\
+ cp -r demo/* $${DOC}/examples/demo ;\
+ cp -r test/* $${DOC}/examples/test ;\
+ install -m 0644 $(EXTRA)/* $${DOC} ;\
+ rm -rf $${DOC}/examples/demo/xbel ;\
+ chmod 755 $${SITE_PACK}/dom/html/GenerateHtml.py ;\
+ rm $${DOC}/examples/demo/sgmlop/test2.htm ;\
+ tail -n +2 $${SITE_PACK}/dom/ext/c14n.py > $${SITE_PACK}/dom/ext/c14n.py.new ;\
+ mv $${SITE_PACK}/dom/ext/c14n.py.new $${SITE_PACK}/dom/ext/c14n.py ;\
+ for i in `find $${DESTDIR} -type f`; do \
+ if head -1 $$i | grep "^#! */usr/bin" | grep "python" >/dev/null ; then \
+ sed -i 's@^\(#! */usr/bin/env \+\)python[.[:digit:]]*$$@\1'$${PYTHON}'@;s@^\(#! */usr/bin/\)python[.[:digit:]]*$$@\1'$${PYTHON}'@' $$i; \
+ fi ;\
+ done ;\
+ mv $${DESTDIR}/usr/bin/xmlproc_parse \
+ $${DESTDIR}/usr/bin/xmlproc_parse.$${PACKAGE} ;\
+ mv $${DESTDIR}/usr/bin/xmlproc_val \
+ $${DESTDIR}/usr/bin/xmlproc_val.$${PACKAGE} ;\
+ done
+ : # Replace all '#!' calls to python with /usr/bin/python
+ : # and make them executable
+ for i in `find debian -mindepth 3 -type f`; do \
+ sed '1s,#!.*python[^ ]*\(.*\),#! /usr/bin/python\1,' \
+ $$i > $$i.temp; \
+ if cmp --quiet $$i $$i.temp; then \
+ rm -f $$i.temp; \
+ else \
+ mv -f $$i.temp $$i; \
+ chmod 755 $$i; \
+ echo "fixed interpreter: $$i"; \
+ fi; \
+ done
+
+ for version in $(VERSIONS) ; do \
+ PYTHON=python$${version} ; \
+ PACKAGE=python-xml-dbg ;\
+ DESTDIR=debian/$${PACKAGE} ;\
+ SITE_PACK=$${DESTDIR}/usr/lib/$${PYTHON}/site-packages/_xmlplus ;\
+ DOC=$${DESTDIR}/usr/share/doc/$${PACKAGE} ;\
+ $${PYTHON}-dbg setup.py \
+ install --without-xslt --no-compile --prefix=$${DESTDIR}/usr ;\
+ done
+ find debian/python-xml-dbg ! -type d ! \( -name '*_d.so' -o -name '*.h' \) \
+ | xargs rm -f
+ find debian/python-xml-dbg -depth -empty -exec rmdir {} \;
+
+ dh_pycentral -a
+ dh_installdocs -a
+ dh_installmenu -a
+ dh_installman -a
+ dh_installchangelogs -a ANNOUNCE
+ rm -rf debian/python-xml-dbg/usr/share/doc/python-xml-dbg
+ ln -s python-xml debian/python-xml-dbg/usr/share/doc/python-xml-dbg
+ dh_strip -ppython-xml --dbg-package=python-xml-dbg
+ dh_compress -a
+ dh_fixperms -a
+ dh_installdeb -a
+ dh_shlibdeps -a
+ dh_gencontrol -a
+ dh_md5sums -a
+ dh_builddeb -a
+
+source diff:
+ @echo >&2 'source and diff are obsolete - use dpkg-source -b'; false
+
+binary: binary-indep binary-arch
+.PHONY: build clean binary-indep binary-arch binary
+
+# ---------------------------------------------------------------------------
+# Various rules to unpack addons and (un)apply patches.
+# Borrowed from DBS
+
+patch_dir = debian/patches
+
+apply-patches: patched-stamp
+reverse-patches:
+ @for stamp in none patched-*; do \
+ case "$$stamp" in none|patched-stamp|patched-\*) continue; esac; \
+ patch=`echo $$stamp | sed -e 's/patched-//'`; \
+ echo "trying to revert patch $$patch ..."; \
+ if [ -x $(patch_dir)/$$patch.dpatch ]; then true; else \
+ chmod +x $(patch_dir)/$$patch.dpatch; fi; \
+ if $(patch_dir)/$$patch.dpatch -unpatch; then \
+ echo "reverted $$patch patch."; \
+ rm -f $$stamp; \
+ else \
+ echo "error in reverting $$patch patch."; \
+ exit 1; \
+ fi; \
+ done
+ @echo "Removing patched-stamp"
+ @rm -f patched-stamp
+
+patched-%: $(patch_dir)/%.dpatch
+ @if [ -x $< ]; then true; else chmod +x $<; fi
+ @if [ -f $@ ]; then \
+ echo "$* patches already applied. $< $@"; exit 1; \
+ fi
+ $< -patch
+ @echo "$* patches applied." > $@
+
+patched-stamp: $(foreach p,$(debian_patches),patched-$(p))
+ @echo -e "\nPatches applied:" >> pxxx
+ @for i in none $(debian_patches); do \
+ if [ -r debian/patches/$$i.dpatch ]; then \
+ echo -e "\n$$i:" >> pxxx; \
+ sed -n 's/^# *DP: */ /p' debian/patches/$$i.dpatch >> pxxx; \
+ fi \
+ done
+ @echo "Writing patched-stamp"
+ @mv -f pxxx patched-stamp
--- python-xml-0.8.4.orig/debian/extra/python.sty
+++ python-xml-0.8.4/debian/extra/python.sty
@@ -0,0 +1,1169 @@
+%
+% python.sty for the Python docummentation [works only with with Latex2e]
+%
+
+\NeedsTeXFormat{LaTeX2e}[1995/12/01]
+\ProvidesPackage{python}
+ [1998/01/11 LaTeX package (Python markup)]
+
+\RequirePackage{longtable}
+
+% Uncomment these two lines to ignore the paper size and make the page
+% size more like a typical published manual.
+%\renewcommand{\paperheight}{9in}
+%\renewcommand{\paperwidth}{8.5in} % typical squarish manual
+%\renewcommand{\paperwidth}{7in} % O'Reilly ``Programmming Python''
+
+% These packages can be used to add marginal annotations which indicate
+% index entries and labels; useful for reviewing this messy documentation!
+%
+%\RequirePackage{showkeys}
+%\RequirePackage{showidx}
+
+% for PDF output, use maximal compression & a lot of other stuff
+% (test for PDF recommended by Tanmoy Bhattacharya )
+%
+\newif\ifpy@doing@page@targets
+\py@doing@page@targetsfalse
+
+\newif\ifpdf\pdffalse
+\ifx\pdfoutput\undefined\else\ifcase\pdfoutput
+\else
+ \pdftrue
+ \input{pdfcolor}
+ \let\py@LinkColor=\NavyBlue
+ \let\py@NormalColor=\Black
+ \pdfcompresslevel=9
+ \pdfpagewidth=\paperwidth % page width of PDF output
+ \pdfpageheight=\paperheight % page height of PDF output
+ %
+ % Pad the number with '0' to 3 digits wide so no page name is a prefix
+ % of any other.
+ %
+ \newcommand{\py@targetno}[1]{\ifnum#1<100 0\fi\ifnum#1<10 0\fi#1}
+ \newcommand{\py@pageno}{\py@targetno\thepage}
+ %
+ % This definition allows the entries in the page-view of the ToC to be
+ % active links. Some work, some don't.
+ %
+ \let\py@OldContentsline=\contentsline
+ %
+ % Macro that takes two args: the name to link to and the content of
+ % the link. This takes care of the PDF magic, getting the colors
+ % the same for each link, and avoids having lots of garbage all over
+ % this style file.
+ \newcommand{\py@linkToName}[2]{%
+ \pdfannotlink attr{/Border [0 0 0]} goto name{#1}%
+ \py@LinkColor#2\py@NormalColor%
+ \pdfendlink%
+ }
+ % Compute the padded page number separately since we end up with a pair of
+ % \relax tokens; this gets the right string computed and works.
+ \renewcommand{\contentsline}[3]{%
+ \def\my@pageno{\py@targetno{#3}}%
+ \py@OldContentsline{#1}{\py@linkToName{page\my@pageno}{#2}}{#3}%
+ }
+ \AtEndDocument{
+ \InputIfFileExists{\jobname.bkm}{\pdfcatalog{/PageMode /UseOutlines}}{}
+ }
+ \newcommand{\py@target}[1]{%
+ \ifpy@doing@page@targets%
+ {\pdfdest name{#1} xyz}%
+ \fi%
+ }
+ \let\py@OldLabel=\label
+ \renewcommand{\label}[1]{%
+ \py@OldLabel{#1}%
+ \py@target{label-#1}%
+ }
+ % This stuff adds a page# destination to every PDF page, where # is three
+ % digits wide, padded with leading zeros. This doesn't really help with
+ % the frontmatter, but does fine with the body.
+ %
+ % This is *heavily* based on the hyperref package.
+ %
+ \def\@begindvi{%
+ \unvbox \@begindvibox
+ \@hyperfixhead
+ }
+ \def\@hyperfixhead{%
+ \let\H@old@thehead\@thehead
+ \global\def\@foo{\py@target{page\py@pageno}}%
+ \expandafter\ifx\expandafter\@empty\H@old@thehead
+ \def\H@old@thehead{\hfil}\fi
+ \def\@thehead{\@foo\relax\H@old@thehead}%
+ }
+\fi\fi
+
+% Increase printable page size (copied from fullpage.sty)
+\topmargin 0pt
+\advance \topmargin by -\headheight
+\advance \topmargin by -\headsep
+
+% attempt to work a little better for A4 users
+\textheight \paperheight
+\advance\textheight by -2in
+
+\oddsidemargin 0pt
+\evensidemargin 0pt
+%\evensidemargin -.25in % for ``manual size'' documents
+\marginparwidth 0.5in
+
+\textwidth \paperwidth
+\advance\textwidth by -2in
+
+
+% Style parameters and macros used by most documents here
+\raggedbottom
+\sloppy
+\parindent = 0mm
+\parskip = 2mm
+\hbadness = 5000 % don't print trivial gripes
+
+\pagestyle{empty} % start this way; change for
+\pagenumbering{roman} % ToC & chapters
+
+% Use this to set the font family for headers and other decor:
+\newcommand{\py@HeaderFamily}{\sffamily}
+
+% Redefine the 'normal' header/footer style when using "fancyhdr" package:
+\@ifundefined{fancyhf}{}{
+ % Use \pagestyle{normal} as the primary pagestyle for text.
+ \fancypagestyle{normal}{
+ \fancyhf{}
+ \fancyfoot[LE,RO]{{\py@HeaderFamily\thepage}}
+ \fancyfoot[LO]{{\py@HeaderFamily\nouppercase{\rightmark}}}
+ \fancyfoot[RE]{{\py@HeaderFamily\nouppercase{\leftmark}}}
+ \renewcommand{\headrulewidth}{0pt}
+ \renewcommand{\footrulewidth}{0.4pt}
+ }
+ % Update the plain style so we get the page number & footer line,
+ % but not a chapter or section title. This is to keep the first
+ % page of a chapter and the blank page between chapters `clean.'
+ \fancypagestyle{plain}{
+ \fancyhf{}
+ \fancyfoot[LE,RO]{{\py@HeaderFamily\thepage}}
+ \renewcommand{\headrulewidth}{0pt}
+ \renewcommand{\footrulewidth}{0.4pt}
+ }
+ % Redefine \cleardoublepage so that the blank page between chapters
+ % gets the plain style and not the fancy style. This is described
+ % in the documentation for the fancyhdr package by Piet von Oostrum.
+ \@ifundefined{chapter}{}{
+ \renewcommand{\cleardoublepage}{
+ \clearpage\if@openright \ifodd\c@page\else
+ \hbox{}
+ \thispagestyle{plain}
+ \newpage
+ \if@twocolumn\hbox{}\newpage\fi\fi\fi
+ }
+ }
+}
+
+% This sets up the {verbatim} environment to be indented and a minipage,
+% and to have all the other mostly nice properties that we want for
+% code samples.
+
+\let\py@OldVerbatim=\verbatim
+\let\py@OldEndVerbatim=\endverbatim
+\RequirePackage{verbatim}
+
+% Variable used by begin code command
+\newlength{\py@codewidth}
+
+\renewcommand{\verbatim}{%
+ \setlength{\parindent}{1cm}%
+ % Calculate the text width for the minipage:
+ \setlength{\py@codewidth}{\linewidth}%
+ \addtolength{\py@codewidth}{-\parindent}%
+ %
+ \par\indent%
+ \begin{minipage}[t]{\py@codewidth}%
+ \small%
+ \py@OldVerbatim%
+}
+\renewcommand{\endverbatim}{%
+ \py@OldEndVerbatim%
+ \end{minipage}%
+}
+
+% This does a similar thing for the {alltt} environment:
+\RequirePackage{alltt}
+\let\py@OldAllTT=\alltt
+\let\py@OldEndAllTT=\endalltt
+
+\renewcommand{\alltt}{%
+ \setlength{\parindent}{1cm}%
+ % Calculate the text width for the minipage:
+ \setlength{\py@codewidth}{\linewidth}%
+ \addtolength{\py@codewidth}{-\parindent}%
+ %
+ \par\indent%
+ \begin{minipage}[t]{\py@codewidth}%
+ \small%
+ \py@OldAllTT%
+}
+\renewcommand{\endalltt}{%
+ \py@OldEndAllTT%
+ \end{minipage}%
+}
+
+
+\newcommand{\py@modulebadkey}{{--just-some-junk--}}
+
+
+%% Lots of index-entry generation support.
+
+% Command to wrap around stuff that refers to function / module /
+% attribute names in the index. Default behavior: like \code{}. To
+% just keep the index entries in the roman font, uncomment the second
+% definition; it matches O'Reilly style more.
+%
+\newcommand{\py@idxcode}[1]{\texttt{#1}}
+%\renewcommand{\py@idxcode}[1]{#1}
+
+% Command to generate two index entries (using subentries)
+\newcommand{\indexii}[2]{\index{#1!#2}\index{#2!#1}}
+
+% And three entries (using only one level of subentries)
+\newcommand{\indexiii}[3]{\index{#1!#2 #3}\index{#2!#3, #1}\index{#3!#1 #2}}
+
+% And four (again, using only one level of subentries)
+\newcommand{\indexiv}[4]{
+\index{#1!#2 #3 #4}
+\index{#2!#3 #4, #1}
+\index{#3!#4, #1 #2}
+\index{#4!#1 #2 #3}
+}
+
+% Command to generate a reference to a function, statement, keyword,
+% operator.
+\newcommand{\kwindex}[1]{\indexii{keyword}{#1@{\py@idxcode{#1}}}}
+\newcommand{\stindex}[1]{\indexii{statement}{#1@{\py@idxcode{#1}}}}
+\newcommand{\opindex}[1]{\indexii{operator}{#1@{\py@idxcode{#1}}}}
+\newcommand{\exindex}[1]{\indexii{exception}{#1@{\py@idxcode{#1}}}}
+\newcommand{\obindex}[1]{\indexii{object}{#1}}
+\newcommand{\bifuncindex}[1]{%
+ \index{#1@{\py@idxcode{#1()}} (built-in function)}}
+
+% Add an index entry for a module
+\newcommand{\py@refmodule}[2]{\index{#1@{\py@idxcode{#1}} (#2module)}}
+\newcommand{\refmodindex}[1]{\py@refmodule{#1}{}}
+\newcommand{\refbimodindex}[1]{\py@refmodule{#1}{built-in }}
+\newcommand{\refexmodindex}[1]{\py@refmodule{#1}{extension }}
+\newcommand{\refstmodindex}[1]{\py@refmodule{#1}{standard }}
+
+% Refer to a module's documentation using a hyperlink of the module's
+% name, at least if we're building PDF:
+\ifpdf
+ \newcommand{\refmodule}[2][\py@modulebadkey]{%
+ \ifx\py@modulebadkey#1\def\py@modulekey{#2}\else\def\py@modulekey{#1}\fi%
+ \py@linkToName{label-module-\py@modulekey}{\module{#2}}%
+ }
+\else
+ \newcommand{\refmodule}[2][\py@modulebadkey]{\module{#2}}
+\fi
+
+% support for the module index
+\newif\ifpy@UseModuleIndex
+\py@UseModuleIndexfalse
+
+\newcommand{\makemodindex}{
+ \newwrite\modindexfile
+ \openout\modindexfile=mod\jobname.idx
+ \py@UseModuleIndextrue
+}
+
+% Add the defining entry for a module
+\newcommand{\py@modindex}[2]{%
+ \renewcommand{\py@thismodule}{#1}
+ \setindexsubitem{(in module #1)}%
+ \index{#1@{\py@idxcode{#1}} (#2module)|textbf}%
+ \ifpy@UseModuleIndex%
+ \@ifundefined{py@modplat@\py@thismodulekey}{
+ \write\modindexfile{\protect\indexentry{#1@{\texttt{#1}}}{\thepage}}%
+ }{\write\modindexfile{\protect\indexentry{#1@{\texttt{#1} %
+ \emph{(\py@platformof[\py@thismodulekey]{})}}}{\thepage}}%
+ }
+ \fi%
+}
+
+% *** XXX *** THE NEXT FOUR MACROS ARE NOW OBSOLETE !!! ***
+
+% built-in & Python modules in the main distribution
+\newcommand{\bimodindex}[1]{\py@modindex{#1}{built-in }%
+ \typeout{*** MACRO bimodindex IS OBSOLETE -- USE declaremodule INSTEAD!}}
+\newcommand{\stmodindex}[1]{\py@modindex{#1}{standard }%
+ \typeout{*** MACRO stmodindex IS OBSOLETE -- USE declaremodule INSTEAD!}}
+
+% Python & extension modules outside the main distribution
+\newcommand{\modindex}[1]{\py@modindex{#1}{}%
+ \typeout{*** MACRO modindex IS OBSOLETE -- USE declaremodule INSTEAD!}}
+\newcommand{\exmodindex}[1]{\py@modindex{#1}{extension }%
+ \typeout{*** MACRO exmodindex IS OBSOLETE -- USE declaremodule INSTEAD!}}
+
+% Additional string for an index entry
+\newif\ifpy@usingsubitem\py@usingsubitemfalse
+\newcommand{\py@indexsubitem}{}
+\newcommand{\setindexsubitem}[1]{\renewcommand{\py@indexsubitem}{ #1}%
+ \py@usingsubitemtrue}
+\newcommand{\ttindex}[1]{%
+ \ifpy@usingsubitem
+ \index{#1@{\py@idxcode{#1}}\py@indexsubitem}%
+ \else%
+ \index{#1@{\py@idxcode{#1}}}%
+ \fi%
+}
+\newcommand{\withsubitem}[2]{%
+ \begingroup%
+ \def\ttindex##1{\index{##1@{\py@idxcode{##1}} #1}}%
+ #2%
+ \endgroup%
+}
+
+
+% Module synopsis processing -----------------------------------------------
+%
+\newcommand{\py@thisclass}{}
+\newcommand{\py@thismodule}{}
+\newcommand{\py@thismodulekey}{}
+\newcommand{\py@thismoduletype}{}
+
+\newcommand{\py@standardIndexModule}[1]{\py@modindex{#1}{standard }}
+\newcommand{\py@builtinIndexModule}[1]{\py@modindex{#1}{built-in }}
+\newcommand{\py@extensionIndexModule}[1]{\py@modindex{#1}{extension }}
+\newcommand{\py@IndexModule}[1]{\py@modindex{#1}{}}
+
+\newif\ifpy@HaveModSynopsis \py@HaveModSynopsisfalse
+\newif\ifpy@ModSynopsisFileIsOpen \py@ModSynopsisFileIsOpenfalse
+\newif\ifpy@HaveModPlatform \py@HaveModPlatformfalse
+
+% \declaremodule[key]{type}{name}
+\newcommand{\declaremodule}[3][\py@modulebadkey]{
+ \py@openModSynopsisFile
+ \renewcommand{\py@thismoduletype}{#2}
+ \ifx\py@modulebadkey#1
+ \renewcommand{\py@thismodulekey}{#3}
+ \else
+ \renewcommand{\py@thismodulekey}{#1}
+ \fi
+ \@ifundefined{py@#2IndexModule}{%
+ \typeout{*** MACRO declaremodule called with unknown module type: `#2'}
+ \py@IndexModule{#3}%
+ }{%
+ \csname py@#2IndexModule\endcsname{#3}%
+ }
+ \label{module-\py@thismodulekey}
+}
+\newif\ifpy@ModPlatformFileIsOpen \py@ModPlatformFileIsOpenfalse
+\newcommand{\py@ModPlatformFilename}{\jobname.pla}
+\newcommand{\platform}[1]{
+ \ifpy@ModPlatformFileIsOpen\else
+ \newwrite\py@ModPlatformFile
+ \openout\py@ModPlatformFile=\py@ModPlatformFilename
+ \py@ModPlatformFileIsOpentrue
+ \fi
+}
+\InputIfFileExists{\jobname.pla}{}{}
+\newcommand{\py@platformof}[2][\py@modulebadkey]{%
+ \ifx\py@modulebadkey#1 \def\py@key{#2}%
+ \else \def\py@key{#1}%
+ \fi%
+ \csname py@modplat@\py@key\endcsname%
+}
+\newcommand{\ignorePlatformAnnotation}[1]{}
+
+% \moduleauthor{name}{email}
+\newcommand{\moduleauthor}[2]{}
+
+% \sectionauthor{name}{email}
+\newcommand{\sectionauthor}[2]{}
+
+
+\newcommand{\py@defsynopsis}{Module has no synopsis.}
+\newcommand{\py@modulesynopsis}{\py@defsynopsis}
+\newcommand{\modulesynopsis}[1]{
+ \py@HaveModSynopsistrue
+ \renewcommand{\py@modulesynopsis}{#1}
+}
+
+% define the file
+\newwrite\py@ModSynopsisFile
+
+% hacked from \addtocontents from latex.ltx:
+\long\def\py@writeModSynopsisFile#1{%
+ \protected@write\py@ModSynopsisFile%
+ {\let\label\@gobble \let\index\@gobble \let\glossary\@gobble}%
+ {\string#1}%
+}
+\newcommand{\py@closeModSynopsisFile}{
+ \ifpy@ModSynopsisFileIsOpen
+ \closeout\py@ModSynopsisFile
+ \py@ModSynopsisFileIsOpenfalse
+ \fi
+}
+\newcommand{\py@openModSynopsisFile}{
+ \ifpy@ModSynopsisFileIsOpen\else
+ \openout\py@ModSynopsisFile=\py@ModSynopsisFilename
+ \py@ModSynopsisFileIsOpentrue
+ \fi
+}
+
+\newcommand{\py@ProcessModSynopsis}{
+ \ifpy@HaveModSynopsis
+ \py@writeModSynopsisFile{\modulesynopsis%
+ {\py@thismodulekey}{\py@thismodule}%
+ {\py@thismoduletype}{\py@modulesynopsis}}%
+ \py@HaveModSynopsisfalse
+ \fi
+ \renewcommand{\py@modulesynopsis}{\py@defsynopsis}
+}
+\AtEndDocument{\py@ProcessModSynopsis\py@closeModSynopsisFile}
+
+
+\long\def\py@writeModPlatformFile#1{%
+ \protected@write\py@ModPlatformFile%
+ {\let\label\@gobble \let\index\@gobble \let\glossary\@gobble}%
+ {\string#1}%
+}
+
+
+\newcommand{\localmoduletable}{
+ \IfFileExists{\py@ModSynopsisFilename}{
+ \begin{synopsistable}
+ \input{\py@ModSynopsisFilename}
+ \end{synopsistable}
+ }{}
+}
+
+\ifpdf
+ \newcommand{\py@ModSynopsisSummary}[4]{%
+ \py@linkToName{label-module-#1}{\bfcode{#2}} & #4\\
+ }
+\else
+ \newcommand{\py@ModSynopsisSummary}[4]{\bfcode{#2} & #4\\}
+\fi
+\newenvironment{synopsistable}{
+ % key, name, type, synopsis
+ \let\modulesynopsis=\py@ModSynopsisSummary
+ \begin{tabular}{ll}
+}{
+ \end{tabular}
+}
+%
+% --------------------------------------------------------------------------
+
+
+\newcommand{\py@reset}{
+ \py@usingsubitemfalse
+ \py@ProcessModSynopsis
+ \renewcommand{\py@thisclass}{}
+ \renewcommand{\py@thismodule}{}
+ \renewcommand{\py@thismodulekey}{}
+ \renewcommand{\py@thismoduletype}{}
+}
+
+% Augment the sectioning commands used to get our own font family in place,
+% and reset some internal data items:
+\renewcommand{\section}{\py@reset%
+ \@startsection{section}{1}{\z@}%
+ {-3.5ex \@plus -1ex \@minus -.2ex}%
+ {2.3ex \@plus.2ex}%
+ {\reset@font\Large\py@HeaderFamily}}
+\renewcommand{\subsection}{\@startsection{subsection}{2}{\z@}%
+ {-3.25ex\@plus -1ex \@minus -.2ex}%
+ {1.5ex \@plus .2ex}%
+ {\reset@font\large\py@HeaderFamily}}
+\renewcommand{\subsubsection}{\@startsection{subsubsection}{3}{\z@}%
+ {-3.25ex\@plus -1ex \@minus -.2ex}%
+ {1.5ex \@plus .2ex}%
+ {\reset@font\normalsize\py@HeaderFamily}}
+\renewcommand{\paragraph}{\@startsection{paragraph}{4}{\z@}%
+ {3.25ex \@plus1ex \@minus.2ex}%
+ {-1em}%
+ {\reset@font\normalsize\py@HeaderFamily}}
+\renewcommand{\subparagraph}{\@startsection{subparagraph}{5}{\parindent}%
+ {3.25ex \@plus1ex \@minus .2ex}%
+ {-1em}%
+ {\reset@font\normalsize\py@HeaderFamily}}
+
+
+% This gets the underscores closer to the right width; the only change
+% from standard LaTeX is the width specified.
+
+\DeclareTextCommandDefault{\textunderscore}{%
+ \leavevmode \kern.06em\vbox{\hrule\@width.55em}}
+
+% Underscore hack (only act like subscript operator if in math mode)
+%
+% The following is due to Mark Wooding (the old version didn't work with
+% Latex 2e.
+
+\DeclareRobustCommand\hackscore{%
+ \ifmmode_\else\textunderscore\fi%
+}
+\begingroup
+\catcode`\_\active
+\def\next{%
+ \AtBeginDocument{\catcode`\_\active\def_{\hackscore{}}}%
+}
+\expandafter\endgroup\next
+
+
+% Now for a lot of semantically-loaded environments that do a ton of magical
+% things to get the right formatting and index entries for the stuff in
+% Python modules and C API.
+
+
+% {fulllineitems} is used in one place in libregex.tex, but is really for
+% internal use in this file.
+%
+\newcommand{\py@itemnewline}[1]{%
+ \@tempdima\linewidth%
+ \advance\@tempdima \leftmargin\makebox[\@tempdima][l]{#1}%
+}
+
+\newenvironment{fulllineitems}{
+ \begin{list}{}{\labelwidth \leftmargin \labelsep 0pt
+ \rightmargin 0pt \topsep -\parskip \partopsep \parskip
+ \itemsep -\parsep
+ \let\makelabel=\py@itemnewline}
+}{\end{list}}
+
+% \optional is mostly for use in the arguments parameters to the various
+% {*desc} environments defined below, but may be used elsewhere. Known to
+% be used in the debugger chapter.
+%
+% Typical usage:
+%
+% \begin{funcdesc}{myfunc}{reqparm\optional{, optparm}}
+% ^^^ ^^^
+% No space here No space here
+%
+% When a function has multiple optional parameters, \optional should be
+% nested, not chained. This is right:
+%
+% \begin{funcdesc}{myfunc}{\optional{parm1\optional{, parm2}}}
+%
+\let\py@badkey=\@undefined
+
+\newcommand{\optional}[1]{%
+ {\textnormal{\Large[}}{#1}\hspace{0.5mm}{\textnormal{\Large]}}}
+
+% This can be used when a function or method accepts an varying number
+% of arguments, such as by using the *args syntax in the parameter list.
+\newcommand{\py@moreargs}{...}
+
+% This can be used when you don't want to document the parameters to a
+% function or method, but simply state that it's an alias for
+% something else.
+\newcommand{\py@unspecified}{...}
+
+% C functions ------------------------------------------------------------
+% \begin{cfuncdesc}[refcount]{type}{name}{arglist}
+% Note that the [refcount] slot should only be filled in by
+% tools/anno-api.py; it pulls the value from the refcounts database.
+\newenvironment{cfuncdesc}[4][\py@badkey]{
+ \begin{fulllineitems}
+ \item[\code{#2 \bfcode{#3}(\py@varvars{#4})}\index{#3@{\py@idxcode{#3()}}}]
+ \ifx#1\@undefined\else%
+ \emph{Return value: \textbf{#1}.}\\
+ \fi
+}{\end{fulllineitems}}
+
+% C variables ------------------------------------------------------------
+% \begin{cvardesc}{type}{name}
+\newenvironment{cvardesc}[2]{
+ \begin{fulllineitems}
+ \item[\code{#1 \bfcode{#2}}\index{#2@{\py@idxcode{#2}}}]
+}{\end{fulllineitems}}
+
+% C data types -----------------------------------------------------------
+% \begin{ctypedesc}[index name]{typedef name}
+\newenvironment{ctypedesc}[2][\py@badkey]{
+ \begin{fulllineitems}
+ \item[\bfcode{#2}%
+ \ifx#1\@undefined%
+ \index{#2@{\py@idxcode{#2}} (C type)}
+ \else%
+ \index{#2@{\py@idxcode{#1}} (C type)}
+ \fi]
+}{\end{fulllineitems}}
+
+% Funky macros -----------------------------------------------------------
+% \begin{csimplemacro}{name}
+% -- "simple" because it has no args; NOT for constant definitions!
+\newenvironment{csimplemacrodesc}[1]{
+ \begin{fulllineitems}
+ \item[\bfcode{#1}\index{#1@{\py@idxcode{#1}} (macro)}]
+}{\end{fulllineitems}}
+
+% simple functions (not methods) -----------------------------------------
+% \begin{funcdesc}{name}{args}
+\newcommand{\funcline}[2]{%
+ \funclineni{#1}{#2}%
+ \index{#1@{\py@idxcode{#1()}} (in module \py@thismodule)}}
+\newenvironment{funcdesc}[2]{
+ \begin{fulllineitems}
+ \funcline{#1}{#2}
+}{\end{fulllineitems}}
+
+% similar to {funcdesc}, but doesn't add to the index
+\newcommand{\funclineni}[2]{\item[\code{\bfcode{#1}(\py@varvars{#2})}]}
+\newenvironment{funcdescni}[2]{
+ \begin{fulllineitems}
+ \funclineni{#1}{#2}
+}{\end{fulllineitems}}
+
+% classes ----------------------------------------------------------------
+% \begin{classdesc}{name}{constructor args}
+\newenvironment{classdesc}[2]{
+ % Using \renewcommand doesn't work for this, for unknown reasons:
+ \global\def\py@thisclass{#1}
+ \begin{fulllineitems}
+ \item[\strong{class }\code{\bfcode{#1}(\py@varvars{#2})}%
+ \index{#1@{\py@idxcode{#1}} (class in \py@thismodule)}]
+}{\end{fulllineitems}}
+
+% \begin{classdesc*}{name}
+\newenvironment{classdesc*}[1]{
+ % Using \renewcommand doesn't work for this, for unknown reasons:
+ \global\def\py@thisclass{#1}
+ \begin{fulllineitems}
+ \item[\strong{class }\code{\bfcode{#1}}%
+ \index{#1@{\py@idxcode{#1}} (class in \py@thismodule)}]
+}{\end{fulllineitems}}
+
+% \begin{excclassdesc}{name}{constructor args}
+% but indexes as an exception
+\newenvironment{excclassdesc}[2]{
+ % Using \renewcommand doesn't work for this, for unknown reasons:
+ \global\def\py@thisclass{#1}
+ \begin{fulllineitems}
+ \item[\strong{exception }\code{\bfcode{#1}(\py@varvars{#2})}%
+ \index{#1@{\py@idxcode{#1}} (exception in \py@thismodule)}]
+}{\end{fulllineitems}}
+
+% There is no corresponding {excclassdesc*} environment. To describe
+% a class exception without parameters, use the {excdesc} environment.
+
+
+\let\py@classbadkey=\@undefined
+
+% object method ----------------------------------------------------------
+% \begin{methoddesc}[classname]{methodname}{args}
+\newcommand{\methodline}[3][\@undefined]{
+ \methodlineni{#2}{#3}
+ \ifx#1\@undefined
+ \index{#2@{\py@idxcode{#2()}} (\py@thisclass\ method)}
+ \else
+ \index{#2@{\py@idxcode{#2()}} (#1 method)}
+ \fi
+}
+\newenvironment{methoddesc}[3][\@undefined]{
+ \begin{fulllineitems}
+ \ifx#1\@undefined
+ \methodline{#2}{#3}
+ \else
+ \def\py@thisclass{#1}
+ \methodline{#2}{#3}
+ \fi
+}{\end{fulllineitems}}
+
+% similar to {methoddesc}, but doesn't add to the index
+% (never actually uses the optional argument)
+\newcommand{\methodlineni}[3][\py@classbadkey]{%
+ \item[\code{\bfcode{#2}(\py@varvars{#3})}]}
+\newenvironment{methoddescni}[3][\py@classbadkey]{
+ \begin{fulllineitems}
+ \methodlineni{#2}{#3}
+}{\end{fulllineitems}}
+
+% object data attribute --------------------------------------------------
+% \begin{memberdesc}[classname]{membername}
+\newcommand{\memberline}[2][\py@classbadkey]{%
+ \ifx#1\@undefined
+ \memberlineni{#2}
+ \index{#2@{\py@idxcode{#2}} (\py@thisclass\ attribute)}
+ \else
+ \memberlineni{#2}
+ \index{#2@{\py@idxcode{#2}} (#1 attribute)}
+ \fi
+}
+\newenvironment{memberdesc}[2][\py@classbadkey]{
+ \begin{fulllineitems}
+ \ifx#1\@undefined
+ \memberline{#2}
+ \else
+ \def\py@thisclass{#1}
+ \memberline{#2}
+ \fi
+}{\end{fulllineitems}}
+
+% similar to {memberdesc}, but doesn't add to the index
+% (never actually uses the optional argument)
+\newcommand{\memberlineni}[2][\py@classbadkey]{\item[\bfcode{#2}]}
+\newenvironment{memberdescni}[2][\py@classbadkey]{
+ \begin{fulllineitems}
+ \memberlineni{#2}
+}{\end{fulllineitems}}
+
+% For exceptions: --------------------------------------------------------
+% \begin{excdesc}{name}
+% -- for constructor information, use excclassdesc instead
+\newenvironment{excdesc}[1]{
+ \begin{fulllineitems}
+ \item[\strong{exception }\bfcode{#1}%
+ \index{#1@{\py@idxcode{#1}} (exception in \py@thismodule)}]
+}{\end{fulllineitems}}
+
+% Module data or constants: ----------------------------------------------
+% \begin{datadesc}{name}
+\newcommand{\dataline}[1]{%
+ \datalineni{#1}\index{#1@{\py@idxcode{#1}} (data in \py@thismodule)}}
+\newenvironment{datadesc}[1]{
+ \begin{fulllineitems}
+ \dataline{#1}
+}{\end{fulllineitems}}
+
+% similar to {datadesc}, but doesn't add to the index
+\newcommand{\datalineni}[1]{\item[\bfcode{#1}]\nopagebreak}
+\newenvironment{datadescni}[1]{
+ \begin{fulllineitems}
+ \datalineni{#1}
+}{\end{fulllineitems}}
+
+% bytecode instruction ---------------------------------------------------
+% \begin{opcodedesc}{name}{var}
+% -- {var} may be {}
+\newenvironment{opcodedesc}[2]{
+ \begin{fulllineitems}
+ \item[\bfcode{#1}\quad\var{#2}]
+}{\end{fulllineitems}}
+
+
+\newcommand{\nodename}[1]{\label{#1}}
+
+% For these commands, use \command{} to get the typography right, not
+% {\command}. This works better with the texinfo translation.
+\newcommand{\ABC}{{\sc abc}}
+\newcommand{\UNIX}{{\sc Unix}}
+\newcommand{\POSIX}{POSIX}
+\newcommand{\ASCII}{{\sc ascii}}
+\newcommand{\Cpp}{C\protect\raisebox{.18ex}{++}}
+\newcommand{\C}{C}
+\newcommand{\EOF}{{\sc eof}}
+\newcommand{\NULL}{\constant{NULL}}
+\newcommand{\infinity}{\ensuremath{\infty}}
+\newcommand{\plusminus}{\ensuremath{\pm}}
+\newcommand{\menuselection}[1]{{\def\sub{ \ensuremath{>} }#1}}
+
+% Also for consistency: spell Python "Python", not "python"!
+
+% code is the most difficult one...
+\newcommand{\code}[1]{\textrm{\@vobeyspaces\@noligs\def\{{\char`\{}\def\}{\char`\}}\def\~{\char`\~}\def\^{\char`\^}\def\e{\char`\\}\def\${\char`\$}\def\#{\char`\#}\def\&{\char`\&}\def\%{\char`\%}%
+\texttt{#1}}}
+
+\newcommand{\bfcode}[1]{\code{\bfseries#1}} % bold-faced code font
+\newcommand{\kbd}[1]{\code{#1}}
+\newcommand{\samp}[1]{`\code{#1}'}
+% This weird definition of \var{} allows it to always appear in roman
+% italics, and won't get funky in code fragments when we play around
+% with fonts. This also works directly in math mode.
+\newcommand{\var}[1]{%
+ \ifmmode%
+ \hbox{\normalsize\textrm{\textit{#1\/}}}%
+ \else%
+ \normalsize\textrm{\textit{#1\/}}%
+ \fi%
+}
+\renewcommand{\emph}[1]{{\em #1}}
+\newcommand{\dfn}[1]{\emph{#1}}
+\newcommand{\strong}[1]{{\bf #1}}
+% let's experiment with a new font:
+\newcommand{\file}[1]{`{\small\textsf{#1}}'}
+\newcommand{\filenq}[1]{{\small\textsf{#1}}}
+
+% Use this def/redef approach for \url{} since hyperref defined this already,
+% but only if we actually used hyperref:
+\ifpdf
+ \newcommand{\url}[1]{{%
+ \pdfannotlink attr{/Border [0 0 0]} user{/S /URI /URI (#1)}%
+ \py@LinkColor% color of the link text
+ \small\sf #1%
+ \py@NormalColor% Turn it back off; these are declarative
+ \pdfendlink}% and don't appear bound to the current
+ }% formatting "box".
+\else
+ \newcommand{\url}[1]{\mbox{\small\textsf{#1}}}
+\fi
+\newcommand{\email}[1]{{\small\textsf{#1}}}
+\newcommand{\newsgroup}[1]{{\small\textsf{#1}}}
+
+\newcommand{\py@varvars}[1]{{%
+ {\let\unspecified=\py@unspecified%
+ \let\moreargs=\py@moreargs%
+ \var{#1}}}}
+
+% I'd really like to get rid of this!
+\newif\iftexi\texifalse
+
+% This is used to get l2h to put the copyright and abstract on
+% a separate HTML page.
+\newif\ifhtml\htmlfalse
+
+
+% These should be used for all references to identifiers which are
+% used to refer to instances of specific language constructs. See the
+% names for specific semantic assignments.
+%
+% For now, don't do anything really fancy with them; just use them as
+% logical markup. This might change in the future.
+%
+\newcommand{\module}[1]{\texttt{#1}}
+\newcommand{\keyword}[1]{\texttt{#1}}
+\newcommand{\exception}[1]{\texttt{#1}}
+\newcommand{\class}[1]{\texttt{#1}}
+\newcommand{\function}[1]{\texttt{#1}}
+\newcommand{\member}[1]{\texttt{#1}}
+\newcommand{\method}[1]{\texttt{#1}}
+
+\newcommand{\pytype}[1]{#1} % built-in Python type
+
+\newcommand{\cfunction}[1]{\texttt{#1}}
+\newcommand{\ctype}[1]{\texttt{#1}} % C struct or typedef name
+\newcommand{\cdata}[1]{\texttt{#1}} % C variable, typically global
+
+\newcommand{\mailheader}[1]{{\small\textsf{#1:}}}
+\newcommand{\mimetype}[1]{{\small\textsf{#1}}}
+% The \! is a "negative thin space" in math mode.
+\newcommand{\regexp}[1]{%
+ {\tiny$^{^\lceil}\!\!$%
+ {\normalsize\code{#1}}%
+ $\!\rfloor\!$%
+ }}
+\newcommand{\envvar}[1]{%
+ #1%
+ \index{#1}%
+ \index{environment variables!{#1}}%
+}
+\newcommand{\makevar}[1]{#1} % variable in a Makefile
+\newcommand{\character}[1]{\samp{#1}}
+
+% constants defined in Python modules or C headers, not language constants:
+\newcommand{\constant}[1]{\code{#1}} % manifest constant, not syntactic
+
+\newcommand{\manpage}[2]{{\emph{#1}(#2)}}
+\newcommand{\pep}[1]{PEP #1\index{Python Enhancement Proposals!PEP #1}}
+\newcommand{\rfc}[1]{RFC #1\index{RFC!RFC #1}}
+\newcommand{\program}[1]{\strong{#1}}
+\newcommand{\programopt}[1]{\strong{#1}}
+% Note that \longprogramopt provides the '--'!
+\newcommand{\longprogramopt}[1]{\strong{-{}-#1}}
+
+% \ulink{link text}{URL}
+\ifpdf
+ % The \noindent here is a hack -- we're forcing pdfTeX into
+ % horizontal mode since \pdfannotlink requires that.
+ \newcommand{\ulink}[2]{\noindent{%
+ \pdfannotlink attr{/Border [0 0 0]} user{/S /URI /URI (#2)}%
+ \py@LinkColor% color of the link text
+ #1%
+ \py@NormalColor% Turn it back off; these are declarative
+ \pdfendlink}% and don't appear bound to the current
+ }% formatting "box".
+\else
+ \newcommand{\ulink}[2]{#1}
+\fi
+
+% cited titles: \citetitle{Title of Work}
+% online: \citetitle[url-to-resource]{Title of Work}
+\ifpdf
+ \newcommand{\citetitle}[2][\py@modulebadkey]{%
+ \ifx\py@modulebadkey#1\emph{#2}\else\ulink{\emph{#2}}{#1}\fi%
+ }
+\else
+ \newcommand{\citetitle}[2][URL]{\emph{#2}}
+\fi
+
+
+
+\newcommand{\grammartoken}[1]{\texttt{#1}}
+\newenvironment{productionlist}[1][\py@badkey]{
+ \def\optional##1{{\Large[}##1{\Large]}}
+ \def\production##1##2{\code{##1}&::=&\code{##2}\\}
+ \def\orgroup##1{{\def\or{\textbar\ }##1}}
+ \def\token##1{##1}
+ \let\grammartoken=\token
+ \begin{center}
+ \begin{tabular}{lcl}
+}{%
+ \end{tabular}
+ \end{center}
+}
+
+\newcommand{\note}[1]{\strong{Note:} #1}
+\newcommand{\warning}[1]{\strong{Warning:} #1}
+
+% Deprecation stuff.
+% Should be extended to allow an index / list of deprecated stuff. But
+% there's a lot of stuff that needs to be done to make that automatable.
+%
+% First parameter is the release number that deprecates the feature, the
+% second is the action the should be taken by users of the feature.
+%
+% Example:
+% \deprecated{1.5.1}{Use \method{frobnicate()} instead.}
+%
+\newcommand{\deprecated}[2]{%
+ \strong{Deprecated since release #1.} #2\par}
+
+% New stuff.
+% This should be used to mark things which have been added to the
+% development tree but that aren't in the release, but are documented.
+% This allows release of documentation that already includes updated
+% descriptions. Place at end of descriptor environment.
+%
+% Example:
+% \versionadded{1.5.2}
+% \versionchanged[short explanation]{2.0}
+%
+\newcommand{\versionadded}[2][\py@badkey]{%
+ \ifx#1\@undefined%
+ { New in version #2. }%
+ \else%
+ { New in version #2:\ #1. }%
+ \fi%
+}
+\newcommand{\versionchanged}[2][\py@badkey]{%
+ \ifx#1\@undefined%
+ { Changed in version #2. }%
+ \else%
+ { Changed in version #2:\ #1. }%
+ \fi%
+}
+
+
+% Tables.
+%
+\newenvironment{tableii}[4]{%
+ \begin{center}%
+ \def\lineii##1##2{\csname#2\endcsname{##1}#2\\}%
+ \begin{tabular}{#1}\strong{#3}&\strong{#4} \\* \hline%
+}{%
+ \end{tabular}%
+ \end{center}%
+}
+
+\newenvironment{longtableii}[4]{%
+ \begin{center}%
+ \def\lineii##1##2{\csname#2\endcsname{##1}#2\\}%
+ \begin{longtable}[c]{#1}\strong{#3}&\strong{#4} \\* \hline\endhead%
+}{%
+ \end{longtable}%
+ \end{center}%
+}
+
+\newenvironment{tableiii}[5]{%
+ \begin{center}%
+ \def\lineiii##1##2##3{\csname#2\endcsname{##1}#2#3\\}%
+ \begin{tabular}{#1}\strong{#3}&\strong{#4}&\strong{#5} \\%
+ \hline%
+}{%
+ \end{tabular}%
+ \end{center}%
+}
+
+\newenvironment{longtableiii}[5]{%
+ \begin{center}%
+ \def\lineiii##1##2##3{\csname#2\endcsname{##1}#2#3\\}%
+ \begin{longtable}[c]{#1}\strong{#3}&\strong{#4}&\strong{#5} \\%
+ \hline\endhead%
+}{%
+ \end{longtable}%
+ \end{center}%
+}
+
+\newenvironment{tableiv}[6]{%
+ \begin{center}%
+ \def\lineiv##1##2##3##4{\csname#2\endcsname{##1}#2#3#4\\}%
+ \begin{tabular}{#1}\strong{#3}&\strong{#4}&\strong{#5}&\strong{#6} \\%
+ \hline%
+}{%
+ \end{tabular}%
+ \end{center}%
+}
+
+\newenvironment{longtableiv}[6]{%
+ \begin{center}%
+ \def\lineiv##1##2##3##4{\csname#2\endcsname{##1}#2#3#4\\}%
+ \begin{longtable}[c]{#1}\strong{#3}&\strong{#4}&\strong{#5}&\strong{#6}%
+ \\%
+ \hline\endhead%
+}{%
+ \end{longtable}%
+ \end{center}%
+}
+
+\newenvironment{tablev}[7]{%
+ \begin{center}%
+ \def\linev##1##2##3##4##5{\csname#2\endcsname{##1}#2#3#4#5\\}%
+ \begin{tabular}{#1}\strong{#3}&\strong{#4}&\strong{#5}&\strong{#6}&\strong{#7} \\%
+ \hline%
+}{%
+ \end{tabular}%
+ \end{center}%
+}
+
+\newenvironment{longtablev}[7]{%
+ \begin{center}%
+ \def\linev##1##2##3##4##5{\csname#2\endcsname{##1}#2#3#4#5\\}%
+ \begin{longtable}[c]{#1}\strong{#3}&\strong{#4}&\strong{#5}&\strong{#6}&\strong{#7}%
+ \\%
+ \hline\endhead%
+}{%
+ \end{longtable}%
+ \end{center}%
+}
+
+% Cross-referencing (AMK, new impl. FLD)
+% Sample usage:
+% \begin{seealso}
+% \seemodule{rand}{Uniform random number generator.}; % Module xref
+% \seetext{\emph{Encyclopedia Britannica}}. % Ref to a book
+%
+% % A funky case: module name contains '_'; have to supply an optional key
+% \seemodule[copyreg]{copy_reg}{Interface constructor registration for
+% \module{pickle}.}
+% \end{seealso}
+%
+% Note that the last parameter for \seemodule and \seetext should be complete
+% sentences and be terminated with the proper punctuation.
+
+\ifpdf
+ \newcommand{\py@seemodule}[3][\py@modulebadkey]{%
+ \par%
+ \ifx\py@modulebadkey#1\def\py@modulekey{#2}\else\def\py@modulekey{#1}\fi%
+ \begin{fulllineitems}
+ \item[\py@linkToName{label-module-\py@modulekey}{Module \module{#2}}
+ (section \ref{module-\py@modulekey}):]
+ #3
+ \end{fulllineitems}
+ }
+\else
+ \newcommand{\py@seemodule}[3][\py@modulebadkey]{%
+ \par%
+ \ifx\py@modulebadkey#1\def\py@modulekey{#2}\else\def\py@modulekey{#1}\fi%
+ \begin{fulllineitems}
+ \item[Module \module{#2} (section \ref{module-\py@modulekey}):]
+ #3
+ \end{fulllineitems}
+ }
+\fi
+
+% \seetitle[url]{title}{why it's interesting}
+\newcommand{\py@seetitle}[3][\py@modulebadkey]{%
+ \par
+ \begin{fulllineitems}
+ \item[\citetitle{#2}]
+ \ifx\py@modulebadkey#1\else
+ \item[{\small{(\url{#1})}}]
+ \fi
+ #3
+ \end{fulllineitems}
+}
+% \seepep{number}{title}{why it's interesting}
+\newcommand{\py@seepep}[3]{%
+ \par%
+ \begin{fulllineitems}
+ \item[\pep{#1}, ``\emph{#2}'']
+ #3
+ \end{fulllineitems}
+}
+% \seerfc{number}{title}{why it's interesting}
+\newcommand{\py@seerfc}[3]{%
+ \par%
+ \begin{fulllineitems}
+ \item[\rfc{#1}, ``\emph{#2}'']
+ #3
+ \end{fulllineitems}
+}
+% \seeurl{url}{why it's interesting}
+\newcommand{\py@seeurl}[2]{%
+ \par%
+ \begin{fulllineitems}
+ \item[\url{#1}]
+ #2
+ \end{fulllineitems}
+}
+\newenvironment{seealso}[0]{
+ \par
+ \strong{See Also:}\par
+ \def\seetext##1{\par{##1}}
+ \let\seemodule=\py@seemodule
+ \let\seepep=\py@seepep
+ \let\seerfc=\py@seerfc
+ \let\seetitle=\py@seetitle
+ \let\seeurl=\py@seeurl
+}{\par}
+
+
+% Allow the Python release number to be specified independently of the
+% \date{}. This allows the date to reflect the document's date and
+% release to specify the Python release that is documented.
+%
+\newcommand{\py@release}{}
+\newcommand{\version}{}
+\newcommand{\shortversion}{}
+\newcommand{\releaseinfo}{}
+\newcommand{\releasename}{Release}
+\newcommand{\release}[1]{%
+ \renewcommand{\py@release}{\releasename\space\version}%
+ \renewcommand{\version}{#1}}
+\newcommand{\setshortversion}[1]{%
+ \renewcommand{\shortversion}{#1}}
+\newcommand{\setreleaseinfo}[1]{%
+ \renewcommand{\releaseinfo}{#1}}
+
+% Allow specification of the author's address separately from the
+% author's name. This can be used to format them differently, which
+% is a good thing.
+%
+\newcommand{\py@authoraddress}{}
+\newcommand{\authoraddress}[1]{\renewcommand{\py@authoraddress}{#1}}
+\let\developersaddress=\authoraddress
+\let\developer=\author
+\let\developers=\author
+
+% This sets up the fancy chapter headings that make the documents look
+% at least a little better than the usual LaTeX output.
+%
+\@ifundefined{ChTitleVar}{}{
+ \ChNameVar{\raggedleft\normalsize\py@HeaderFamily}
+ \ChNumVar{\raggedleft \bfseries\Large\py@HeaderFamily}
+ \ChTitleVar{\raggedleft \rm\Huge\py@HeaderFamily}
+ % This creates chapter heads without the leading \vspace*{}:
+ \def\@makechapterhead#1{%
+ {\parindent \z@ \raggedright \normalfont
+ \ifnum \c@secnumdepth >\m@ne
+ \DOCH
+ \fi
+ \interlinepenalty\@M
+ \DOTI{#1}
+ }
+ }
+}
+
+
+% Definition lists; requested by AMK for HOWTO documents. Probably useful
+% elsewhere as well, so keep in in the general style support.
+%
+\newenvironment{definitions}{%
+ \begin{description}%
+ \def\term##1{\item[##1]\mbox{}\\*[0mm]}
+}{%
+ \end{description}%
+}
+
+% Tell TeX about pathological hyphenation cases:
+\hyphenation{Base-HTTP-Re-quest-Hand-ler}
--- python-xml-0.8.4.orig/debian/extra/pypaper.sty
+++ python-xml-0.8.4/debian/extra/pypaper.sty
@@ -0,0 +1,18 @@
+%
+% Change this to say a4paper instead of letterpaper if you want A4. These
+% are the latex defaults.
+%
+\newcommand{\py@paper}{letterpaper}
+\newcommand{\py@ptsize}{10pt}
+
+% These set up the fonts for the documents.
+%
+% The "times" package makes the default font the PostScript Times
+% font, which makes for smaller PostScript and a font that more people
+% like.
+%
+% The "avant" package causes the AvantGarde font to be used for
+% sans-serif text, instead of the uglier Helvetica set up by the "times"
+% package.
+%
+\RequirePackage{times}\typeout{Using Times instead of Computer Modern.}
--- python-xml-0.8.4.orig/debian/extra/howto.cls
+++ python-xml-0.8.4/debian/extra/howto.cls
@@ -0,0 +1,106 @@
+%
+% howto.cls for the Python documentation
+%
+
+\NeedsTeXFormat{LaTeX2e}[1995/12/01]
+\ProvidesClass{howto}
+ [1998/02/25 Document class (Python HOWTO)]
+
+\RequirePackage{pypaper}
+
+% Change the options here to get a different set of basic options, This
+% is where to add things like "a4paper" or "10pt".
+%
+\LoadClass[twoside]{article}
+
+\setcounter{secnumdepth}{1}
+
+% Optional packages:
+%
+% If processing of these documents fails at your TeX installation,
+% these may be commented out (independently) to make things work.
+% These are both supplied with the current version of the teTeX
+% distribution.
+%
+% The "fancyhdr" package makes nicer page footers reasonable to
+% implement, and is used to put the chapter and section information in
+% the footers.
+%
+\RequirePackage{fancyhdr}\typeout{Using fancier footers than usual.}
+
+
+% Required package:
+%
+% This gives us all the Python-specific markup that we really want.
+% This should come last. Do not change this.
+%
+\RequirePackage{python}
+
+% support for module synopsis sections:
+\newcommand{\py@ModSynopsisFilename}{\jobname.syn}
+
+
+% need to do one of these....
+\newcommand{\py@doHorizontalRule}{\rule{\textwidth}{1pt}}
+
+
+% Change the title page to look a bit better, and fit in with the
+% fncychap ``Bjarne'' style a bit better.
+%
+\renewcommand{\maketitle}{
+ \py@doHorizontalRule
+ \@ifundefined{pdfinfo}{}{{
+ % This \def is required to deal with multi-line authors; it
+ % changes \\ to ', ' (comma-space), making it pass muster for
+ % generating document info in the PDF file.
+ \def\\{, }
+ \pdfinfo{
+ /Author (\@author)
+ /Title (\@title)
+ }
+ }}
+ \begin{flushright}
+ {\rm\Huge\py@HeaderFamily \@title} \par
+ {\em\large\py@HeaderFamily \py@release} \par
+ \vspace{25pt}
+ {\Large\py@HeaderFamily \@author} \par
+ \vspace{25pt}
+ \@date \par
+ \py@authoraddress \par
+ \end{flushright}
+ \@thanks
+ \setcounter{footnote}{0}
+ \let\thanks\relax\let\maketitle\relax
+ \gdef\@thanks{}\gdef\@author{}\gdef\@title{}
+}
+
+
+\let\py@OldTableofcontents=\tableofcontents
+\renewcommand{\tableofcontents}{
+ \begingroup
+ \parskip = 0mm
+ \py@OldTableofcontents
+ \endgroup
+ \py@doHorizontalRule
+ \vspace{12pt}
+ \py@doing@page@targetstrue
+}
+
+% Fix the theindex environment to add an entry to the Table of
+% Contents; this is much nicer than just having to jump to the end of
+% the book and flip around, especially with multiple indexes.
+%
+\let\py@OldTheindex=\theindex
+\renewcommand{\theindex}{
+ \clearpage
+ \py@OldTheindex
+ \addcontentsline{toc}{section}{\indexname}
+}
+
+\@ifundefined{fancyhf}{
+ \pagestyle{plain}}{
+ \pagestyle{normal}} % start this way; change for
+\pagenumbering{arabic} % ToC & chapters
+\setcounter{secnumdepth}{2}
+
+\thispagestyle{empty}
--- python-xml-0.8.4.orig/debian/copyright
+++ python-xml-0.8.4/debian/copyright
@@ -0,0 +1,236 @@
+This package was debianized by Rob Tillotson robt@debian.org on
+Sun, 14 Jun 1998 06:17:44 -0500. It was taken over by Jerome Marant
+jerome@debian.org on Fri, 20 Oct 2000 17:30:13 +0200. It was taken over
+by Alexandre Fayolle on Wed, 12 Jun 2002
+10:07:28 +0200
+
+The original source is the PSA XML-SIG, at http://www.python.org/sigs/xml-sig/.
+
+Copyright:
+
+This package is made up of several parts, which are under a variety of
+DFSG-free licenses. It is expected that by the 1.0 release everything
+will be relicensed under a python-style license, but for now the
+following terms apply:
+
+PyExpat, SAX libraries:
+--------------------------------------------------------------------
+BEOPEN PYTHON OPEN SOURCE LICENSE AGREEMENT VERSION 1
+-----------------------------------------------------
+
+1. This LICENSE AGREEMENT is between BeOpen.com ("BeOpen"), having an
+office at 160 Saratoga Avenue, Santa Clara, CA 95051, and the
+Individual or Organization ("Licensee") accessing and otherwise using
+this software in source or binary form and its associated
+documentation ("the Software").
+
+2. Subject to the terms and conditions of this BeOpen Python License
+Agreement, BeOpen hereby grants Licensee a non-exclusive,
+royalty-free, world-wide license to reproduce, analyze, test, perform
+and/or display publicly, prepare derivative works, distribute, and
+otherwise use the Software alone or in any derivative version,
+provided, however, that the BeOpen Python License is retained in the
+Software, alone or in any derivative version prepared by Licensee.
+
+3. BeOpen is making the Software available to Licensee on an "AS IS"
+basis. BEOPEN MAKES NO REPRESENTATIONS OR WARRANTIES, EXPRESS OR
+IMPLIED. BY WAY OF EXAMPLE, BUT NOT LIMITATION, BEOPEN MAKES NO AND
+DISCLAIMS ANY REPRESENTATION OR WARRANTY OF MERCHANTABILITY OR FITNESS
+FOR ANY PARTICULAR PURPOSE OR THAT THE USE OF THE SOFTWARE WILL NOT
+INFRINGE ANY THIRD PARTY RIGHTS.
+
+4. BEOPEN SHALL NOT BE LIABLE TO LICENSEE OR ANY OTHER USERS OF THE
+SOFTWARE FOR ANY INCIDENTAL, SPECIAL, OR CONSEQUENTIAL DAMAGES OR LOSS
+AS A RESULT OF USING, MODIFYING OR DISTRIBUTING THE SOFTWARE, OR ANY
+DERIVATIVE THEREOF, EVEN IF ADVISED OF THE POSSIBILITY THEREOF.
+
+5. This License Agreement will automatically terminate upon a material
+breach of its terms and conditions.
+
+6. This License Agreement shall be governed by and interpreted in all
+respects by the law of the State of California, excluding conflict of
+law provisions. Nothing in this License Agreement shall be deemed to
+create any relationship of agency, partnership, or joint venture
+between BeOpen and Licensee. This License Agreement does not grant
+permission to use BeOpen trademarks or trade names in a trademark
+sense to endorse or promote products or services of Licensee, or any
+third party. As an exception, the "BeOpen Python" logos available at
+http://www.pythonlabs.com/logos.html may be used according to the
+permissions granted on that web page.
+
+7. By copying, installing or otherwise using the software, Licensee
+agrees to be bound by the terms and conditions of this License
+Agreement.
+
+CNRI OPEN SOURCE LICENSE AGREEMENT
+----------------------------------
+
+Python 1.6 CNRI OPEN SOURCE LICENSE AGREEMENT
+
+IMPORTANT: PLEASE READ THE FOLLOWING AGREEMENT CAREFULLY. BY CLICKING
+ON "ACCEPT" WHERE INDICATED BELOW, OR BY COPYING, INSTALLING OR
+OTHERWISE USING PYTHON 1.6 SOFTWARE, YOU ARE DEEMED TO HAVE AGREED TO
+THE TERMS AND CONDITIONS OF THIS LICENSE AGREEMENT.
+
+1. This LICENSE AGREEMENT is between the Corporation for National
+Research Initiatives, having an office at 1895 Preston White Drive,
+Reston, VA 20191 ("CNRI"), and the Individual or Organization
+("Licensee") accessing and otherwise using Python 1.6 software in
+source or binary form and its associated documentation, as released at
+the www.python.org Internet site on September 5, 2000 ("Python 1.6").
+
+2. Subject to the terms and conditions of this License Agreement, CNRI
+hereby grants Licensee a nonexclusive, royalty-free, world-wide
+license to reproduce, analyze, test, perform and/or display publicly,
+prepare derivative works, distribute, and otherwise use Python 1.6
+alone or in any derivative version, provided, however, that CNRI's
+License Agreement and CNRI's notice of copyright, i.e., "Copyright (c)
+1995-2000 Corporation for National Research Initiatives; All Rights
+Reserved" are retained in Python 1.6 alone or in any derivative
+version prepared by
+
+Licensee. Alternately, in lieu of CNRI's License Agreement, Licensee
+may substitute the following text (omitting the quotes): "Python 1.6
+is made available subject to the terms and conditions in CNRI's
+License Agreement. This Agreement together with Python 1.6 may be
+located on the Internet using the following unique, persistent
+identifier (known as a handle): 1895.22/1012. This Agreement may also
+be obtained from a proxy server on the Internet using the following
+URL: http://hdl.handle.net/1895.22/1012".
+
+3. In the event Licensee prepares a derivative work that is based on
+or incorporates Python 1.6 or any part thereof, and wants to make the
+derivative work available to others as provided herein, then Licensee
+hereby agrees to include in any such work a brief summary of the
+changes made to Python 1.6.
+
+4. CNRI is making Python 1.6 available to Licensee on an "AS IS"
+basis. CNRI MAKES NO REPRESENTATIONS OR WARRANTIES, EXPRESS OR
+IMPLIED. BY WAY OF EXAMPLE, BUT NOT LIMITATION, CNRI MAKES NO AND
+DISCLAIMS ANY REPRESENTATION OR WARRANTY OF MERCHANTABILITY OR FITNESS
+FOR ANY PARTICULAR PURPOSE OR THAT THE USE OF PYTHON 1.6 WILL NOT
+INFRINGE ANY THIRD PARTY RIGHTS.
+
+5. CNRI SHALL NOT BE LIABLE TO LICENSEE OR ANY OTHER USERS OF PYTHON
+1.6 FOR ANY INCIDENTAL, SPECIAL, OR CONSEQUENTIAL DAMAGES OR LOSS AS A
+RESULT OF MODIFYING, DISTRIBUTING, OR OTHERWISE USING PYTHON 1.6, OR
+ANY DERIVATIVE THEREOF, EVEN IF ADVISED OF THE POSSIBILITY THEREOF.
+
+6. This License Agreement will automatically terminate upon a material
+breach of its terms and conditions.
+
+7. This License Agreement shall be governed by and interpreted in all
+respects by the law of the State of Virginia, excluding conflict of
+law provisions. Nothing in this License Agreement shall be deemed to
+create any relationship of agency, partnership, or joint venture
+between CNRI and Licensee. This License Agreement does not grant
+permission to use CNRI trademarks or trade name in a trademark sense
+to endorse or promote products or services of Licensee, or any third
+party.
+
+8. By clicking on the "ACCEPT" button where indicated, or by copying,
+installing or otherwise using Python 1.6, Licensee agrees to be bound
+by the terms and conditions of this License Agreement.
+
+ACCEPT
+
+
+CWI PERMISSIONS STATEMENT AND DISCLAIMER
+----------------------------------------
+
+Copyright (c) 1991 - 1995, Stichting Mathematisch Centrum Amsterdam,
+The Netherlands. All rights reserved.
+
+Permission to use, copy, modify, and distribute this software and its
+documentation for any purpose and without fee is hereby granted,
+provided that the above copyright notice appear in all copies and that
+both that copyright notice and this permission notice appear in
+supporting documentation, and that the name of Stichting Mathematisch
+Centrum or CWI not be used in advertising or publicity pertaining to
+distribution of the software without specific, written prior
+permission.
+
+STICHTING MATHEMATISCH CENTRUM DISCLAIMS ALL WARRANTIES WITH REGARD TO
+THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND
+FITNESS, IN NO EVENT SHALL STICHTING MATHEMATISCH CENTRUM BE LIABLE
+FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
+WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
+ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT
+OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+--------------------------------------------------------------------
+
+qp_xml:
+
+ Written by Greg Stein. Public Domain.
+ No Copyright, no Rights Reserved, and no Warranties.
+
+--------------------------------------------------------------------
+
+sgmlop:
+
+ Copyright (c) 1998 by Secret Labs AB.
+
+ Permission to use, copy, modify, and distribute this software and
+ its associated documentation for any purpose and without fee is
+ hereby granted. This software is provided as is.
+
+--------------------------------------------------------------------
+
+4DOM:
+
+ Copyright (c) 2000 Fourthought Inc, USA
+
+ All Rights Reserved
+
+ Permission to use, copy, modify, and distribute this software and its
+ documentation for any purpose and without fee is hereby granted,
+ provided that the above copyright notice appear in all copies and that
+ both that copyright notice and this permission notice appear in
+ supporting documentation, and that the name of FourThought LLC not be
+ used in advertising or publicity pertaining to distribution of the
+ software without specific, written prior permission.
+
+ FOURTHOUGHT LLC DISCLAIM ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
+ INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS,
+ IN NO EVENT SHALL FOURTHOUGHT BE LIABLE FOR ANY SPECIAL, INDIRECT OR
+ CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF
+ USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
+ OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE
+ USE OR PERFORMANCE OF THIS SOFTWARE.
+
+--------------------------------------------------------------------
+
+xmlproc:
+
+xmlproc is free and you can do as you like with it. If you change it,
+please let the author, Lars Marius Garshol, know about it.
+
+--------------------------------------------------------------------
+
+setupext/install_data.py:
+
+Permission is hereby granted, free of charge, to any person obtaining
+a copy of this software and associated documentation files (the
+"Software"), to deal in the Software without restriction, including
+without limitation the rights to use, copy, modify, merge, publish,
+distribute, sublicense, and/or sell copies of the Software, and to
+permit persons to whom the Software is furnished to do so, subject to
+the following conditions:
+
+The above copyright notice and this permission notice shall be included
+in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
+IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
+CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
+TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+--------------------------------------------------------------------
+
+The source package also contains the expat parser source, which is
+under the MPL; it is not used in the binary, since we have a separate
+library package for expat already. (libxmltok1)
+
--- python-xml-0.8.4.orig/debian/control
+++ python-xml-0.8.4/debian/control
@@ -0,0 +1,75 @@
+Source: python-xml
+Section: python
+Priority: optional
+Maintainer: Ubuntu Core developers
+XSBC-Original-Maintainer: Debian/Ubuntu Zope Team
+Uploaders: Alexandre Fayolle , Fabio Tranchitella , Matthias Klose
+Build-Depends: python-all-dev, python-all-dbg (>= 2.5-0ubuntu5), debhelper (>= 5.0.37.1), python-central (>= 0.4.15)
+Standards-Version: 3.7.2
+XS-Python-Version: all
+
+Package: python-xml
+Architecture: any
+Depends: ${python:Depends}, ${shlibs:Depends}
+Conflicts: python-4suite (<< 0.12), python2.3-xml, python2.4-xml
+Replaces: python2.3-xml, python2.4-xml
+Provides: ${python:Provides}
+Suggests: python-xml-dbg
+XB-Python-Version: ${python:Versions}
+Description: XML tools for Python
+ The Python/XML distribution contains the basic tools required for
+ processing XML data using the Python programming language, assembled
+ into one easy-to-install package. The distribution includes parsers
+ and standard interfaces such as SAX and DOM, along with various other
+ useful modules.
+ .
+ The package currently contains:
+ .
+ * XML parsers: Pyexpat (Jack Jansen), xmlproc (Lars Marius
+ Garshol), sgmlop (Fredrik Lundh).
+ * SAX interface (Lars Marius Garshol)
+ * minidom DOM implementation (Paul Prescod, others)
+ * 4DOM and 4XPath from Fourthought (Uche Ogbuji, Mike Olson)
+ * Schema implementations: TREX (James Tauber)
+ * Various utility modules and functions (various people)
+ * Documentation and example programs (various people)
+
+Package: python-xml-dbg
+Priority: extra
+Architecture: any
+Depends: python-xml (= ${Source-Version}), python-dbg, ${shlibs:Depends}
+Description: XML tools for Python (debug extension)
+ The Python/XML distribution contains the basic tools required for
+ processing XML data using the Python programming language, assembled
+ into one easy-to-install package. The distribution includes parsers
+ and standard interfaces such as SAX and DOM, along with various other
+ useful modules.
+ .
+ This package contains the extension built for the python debug interpreter.
+
+Package: xbel
+Architecture: all
+Section: web
+Depends: sgml-base
+Recommends: xml-core
+Description: XML Bookmark Exchange Language
+ The XML Bookmark Exchange Language (XBEL) is a rich interchange
+ format for "bookmark" data as used by most web browsers.
+ .
+ This package contains XBEL DTDs for 1.0 and 1.1 formats as well
+ as documentation.
+
+Package: xbel-utils
+Architecture: all
+Section: web
+Depends: ${python:Depends}, python-xml (>= ${Source-Version}), xbel
+Replaces: xbel-utils-0.6
+Conflicts: xbel-utils-0.6
+XB-Python-Version: ${python:Versions}
+Description: XML Bookmark Exchange Language Utilities
+ The XML Bookmark Exchange Language (XBEL) is a rich interchange
+ format for "bookmark" data as used by most web browsers.
+ .
+ This package contains several utilities for converting between
+ XBEL and other common bookmark formats.
+
--- python-xml-0.8.4.orig/debian/xbel.sgml-catalog
+++ python-xml-0.8.4/debian/xbel.sgml-catalog
@@ -0,0 +1,4 @@
+ -- SGML catalog for python-xml package --
+
+PUBLIC "+//IDN python.org//DTD XML Bookmark Exchange Language 1.0//EN//XML" "dtd/xbel-1.0.dtd"
+PUBLIC "+//IDN python.org//DTD XML Bookmark Exchange Language 1.1//EN//XML" "dtd/xbel-1.1.dtd"
--- python-xml-0.8.4.orig/debian/python-xml.dirs
+++ python-xml-0.8.4/debian/python-xml.dirs
@@ -0,0 +1,2 @@
+usr/share/doc/python-xml/examples/demo
+usr/share/doc/python-xml/examples/test
--- python-xml-0.8.4.orig/debian/watch
+++ python-xml-0.8.4/debian/watch
@@ -0,0 +1,2 @@
+version=3
+http://prdownloads.sourceforge.net/pyxml/PyXML-(.*)\.tar\.gz
--- python-xml-0.8.4.orig/debian/xbel.postinst
+++ python-xml-0.8.4/debian/xbel.postinst
@@ -0,0 +1,21 @@
+#!/bin/sh -e
+
+## Install SGML catalog entries
+
+PACKAGE=xbel
+CENTRALCAT=/etc/sgml/$PACKAGE.cat
+ORDCATS="misc/xbel/xbel.cat"
+
+if [ "$1" = configure ]
+then
+ for ordcat in $ORDCATS
+ do
+ update-catalog --quiet --add $CENTRALCAT /usr/share/sgml/$ordcat
+ done
+ update-catalog --quiet --add --super $CENTRALCAT
+fi
+
+#DEBHELPER#
+
+exit 0
+
--- python-xml-0.8.4.orig/debian/xbel.README.debian
+++ python-xml-0.8.4/debian/xbel.README.debian
@@ -0,0 +1,14 @@
+xbel for DEBIAN
+---------------
+
+This is an XML DTD for the interchange of web browser bookmarks. It
+is intended to fully represent the bookmarks of all of the major web
+browsers, so that bookmarks can be easily converted between them.
+(XBEL is also supported natively by Grail, the Python web browser from
+CNRI.) XBEL is a project of the Python Software Activity XML-SIG, and
+current information about it can be found at:
+
+ http://www.python.org/topics/xml/xbel/
+
+This package contains just the DTD and documentation. Conversion
+utilities can be found in the 'xbel-utils' package.
--- python-xml-0.8.4.orig/debian/README.Debian
+++ python-xml-0.8.4/debian/README.Debian
@@ -0,0 +1,33 @@
+python-xml for DEBIAN
+----------------------
+
+This is the debianized version of the new and probably incomplete XML
+package for Python. The modules in this package have been developed
+independently by the members of the PSA XML-SIG, and have now been
+collected into a single package tree.
+
+BEWARE!: The diversions xmllib.py and sgmllib.py are now gone, as of
+version 0.5.1-4, and should be removed on upgrade. However, an ugly
+bug in versions from 0.5.1-4 to 0.5.1-6 made xmllib.py and sgmllib.py
+being silently removed from the system at first install time and on
+further upgrades.
+Before filling any bug report about this problem, please first check
+whether these files are present on your system. If not, please
+reinstall in the following order python-base and python-xml to see
+if the two files are back again.
+
+As of version 0.5.1-2, the XBEL DTD and bookmark conversion code,
+formerly in /usr/doc/python-xml/examples/demo/xbel, has been more
+closely integrated into Debian's SGML architecture. The XBEL code
+itself is now in the "xml.xbel" package, the DTD is registered, and
+the utilities are linked to /usr/bin.
+
+Please note that this is beta software, under active development.
+While most of it works quite well, there may still be bugs, and
+some interfaces may change before the 1.0 release. If you intend
+to use this package for serious work, please consider joining the
+discussion on the XML-SIG mailing list.
+
+Jerome Marant , Sat, 28 Oct 2000 14:17:45 +0200
+
+
--- python-xml-0.8.4.orig/debian/python-xml.docs
+++ python-xml-0.8.4/debian/python-xml.docs
@@ -0,0 +1,6 @@
+CREDITS
+README
+README.dom
+README.pyexpat
+README.sgmlop
+TODO
--- python-xml-0.8.4.orig/debian/changelog
+++ python-xml-0.8.4/debian/changelog
@@ -0,0 +1,472 @@
+python-xml (0.8.4-6ubuntu4) feisty; urgency=low
+
+ * Fix PyMem_DEL-->PyObject_DEL. Ubuntu #95649.
+
+ -- Matthias Klose Sat, 31 Mar 2007 11:33:59 +0200
+
+python-xml (0.8.4-6ubuntu3) feisty; urgency=low
+
+ * debian/rules: Fix typo.
+
+ -- Matthias Klose Sat, 17 Feb 2007 12:57:34 +0100
+
+python-xml (0.8.4-6ubuntu2) feisty; urgency=low
+
+ * Build the extension for the python debug interpreter.
+ * Set Ubuntu maintainer address.
+
+ -- Matthias Klose Sat, 17 Feb 2007 02:57:35 +0100
+
+python-xml (0.8.4-6ubuntu1) feisty; urgency=low
+
+ * "Fake sync" from debian because our orig.tar.gz is different
+ from the one in debian
+
+ -- Michael Vogt Wed, 20 Dec 2006 14:01:46 +0100
+
+python-xml (0.8.4-6) unstable; urgency=medium
+
+ * Fixes for documentation and examples:
+ + Applied patch to demo/dom/generate_xml1.py. (Closes: #399410)
+ + Applied patch to demo/xmlproc/catalog.soc. (Closes: #298008)
+ * debian/control:
+ + move debhelper to build-depends. (Closes: #392630)
+ + xbel: recommends xml-core to provide a catalog mapping onto
+ the XBEL DTDs. (Closes: #386720)
+
+ -- Fabio Tranchitella Mon, 18 Dec 2006 20:12:06 +0100
+
+python-xml (0.8.4-5) unstable; urgency=low
+
+ * Convert to Python policy 0.4, using python-central. Closes: #373368.
+
+ -- Matthias Klose Wed, 14 Jun 2006 02:10:44 +0000
+
+python-xml (0.8.4-4) unstable; urgency=low
+
+ * In some conditions and when parsing a utf-8 file, the xmlproc parser
+ eports non-well-formedness errors when it shouldn't; applied a
+ single-line patch to fix this wrong behaviour. (Closes: #367638)
+
+ -- Fabio Tranchitella Tue, 30 May 2006 22:19:10 +0200
+
+python-xml (0.8.4-3) unstable; urgency=low
+
+ * New maintainer (Debian/Ubuntu Zope Team). (Closes: #354012)
+ * Updated debian/watch, thanks Bart Martens! (Closes: #354367)
+ * debian/rules: fixed some sed regular expressions.
+
+ -- Fabio Tranchitella Fri, 7 Apr 2006 08:36:01 +0000
+
+python-xml (0.8.4-2) unstable; urgency=low
+
+ * Dropped support for python2.2 and python2.1 (Closes: #351157, #159280)
+ * Fixed link to xmlproc license in xmlproc documentation (Closes: #296530)
+
+ -- Alexandre Fayolle Mon, 6 Feb 2006 15:17:48 +0100
+
+python-xml (0.8.4-1) unstable; urgency=low
+
+ * New upstream release
+ * Added debian/watch file
+ * Added support for python2.4
+ * Updated maintainer's email
+
+ -- Alexandre Fayolle Tue, 7 Dec 2004 16:38:22 +0100
+
+python-xml (0.8.3-5) unstable; urgency=low
+
+ * Fixed wrong python dependency on xbel-utils. Closes: #210852
+ * removed man pages from diff.gz since they are now in doc/man
+
+ -- Alexandre Fayolle Tue, 23 Sep 2003 16:50:28 +0200
+
+python-xml (0.8.3-4) unstable; urgency=low
+
+ * Chmod +x py files in /usr/lib/python2.3/site-packages/_xmlplus/xbel/. Closes: #208388
+
+ -- Alexandre Fayolle Wed, 3 Sep 2003 14:57:20 +0200
+
+python-xml (0.8.3-3) unstable; urgency=low
+
+ * Fixed bug in debian/rules causing files in xbel-utils to be empty. Closes: #208388
+
+ -- Alexandre Fayolle Tue, 2 Sep 2003 09:45:57 +0200
+
+python-xml (0.8.3-2) unstable; urgency=low
+
+ * changed section of xbel and xbel-utils to 'web' (was interpreters)
+ * Fixed shebangs in xbel-utils and python version in maintainer scripts. Closes: #207835
+ * Standards-Version updated to 3.6.1
+
+ -- Alexandre Fayolle Mon, 1 Sep 2003 12:02:39 +0200
+
+python-xml (0.8.3-1) unstable; urgency=low
+
+ * New upstream release
+ * Fixes broken documentation urls. Closes: #183057
+ * Fixes bad 4Suite.mo file. Closes: #202926
+ * changed section to "python"
+ * updated standards version
+ * Changed default python version to 2.3
+
+ -- Alexandre Fayolle Mon, 11 Aug 2003 08:29:14 +0200
+
+python-xml (0.8.2-3) unstable; urgency=low
+
+ * fixed wrong argument order in xml.sax.expatreader. Closes: Bug#183069
+ * fixed escaping ampershand characters in xml.xbel.bookmark. Closes: Bug#180468
+
+ -- Alexandre Fayolle Tue, 11 Mar 2003 18:00:32 +0100
+
+python-xml (0.8.2-2) unstable; urgency=low
+
+ * Removed dependency on python2.3-xmlbase which no longer exists. Closes: Bug#180965
+
+ -- Alexandre Fayolle Fri, 14 Feb 2003 11:08:39 +0100
+
+python-xml (0.8.2-1) unstable; urgency=low
+
+ * New upstream release
+ * xbel-utils now replaces xbel-utils-0.6
+
+ -- Alexandre Fayolle Mon, 10 Feb 2003 11:25:05 +0100
+
+python-xml (0.8.1-2) unstable; urgency=low
+
+ * fixed python version in xbel-utils postinst script. Closes: Bug#163724
+ * added man page for xmlrpc_parse and xmlproc_val, and fixed dangling symlinks problem. Closes: Bug#128682, Bug#165413
+ * used proper capitalisation of Unicode in debian/control. Closes: Bug#172063
+
+ -- Alexandre Fayolle Tue, 10 Dec 2002 08:59:20 +0100
+
+python-xml (0.8.1-1) unstable; urgency=low
+
+ * New upstream release
+ - fix syntax error in xmlproc_parse and xmlproc_val scripts.
+ Closes: Bug#158987, Bug#158989
+ - fix problem when using pyexpat and the python profiler on python>=2.2.
+ The bug is still there on python2.1 (reported as Bug#159280)
+ * Added patch fixing a problem with TreeWalker. Closes: Bug#161276
+ * Cleaned debian/rules by using 'setup.py install --no-compile'
+ * Updated the python-xml version number xbel-utils depends on to 0.8
+ so that a more recent version of expat is be used.
+ * Added python2.3-xml package
+
+ -- Alexandre Fayolle Thu, 19 Sep 2002 09:56:29 +0200
+
+python-xml (0.8-2.1) unstable; urgency=low
+
+ * Use python2.2 as default python version.
+
+ -- Matthias Klose Sat, 24 Aug 2002 15:17:48 +0200
+
+python-xml (0.8-2) unstable; urgency=low
+
+ * Fix syntax error in msie_parse.py. Closes: Bug#156525, Bug#156796, Bug#157173
+
+ -- Alexandre Fayolle Wed, 21 Aug 2002 11:29:18 +0200
+
+python-xml (0.8-1) unstable; urgency=low
+
+ * New upstream release. Closes: Bug#150565, Bug#152630
+
+ -- Alexandre Fayolle Mon, 12 Aug 2002 14:20:24 +0200
+
+python-xml (0.7.1-2) unstable; urgency=low
+
+ * Applied the following patches:
+ - fix for optional fields in Opera 6 bookmarks. Closes: Bug#148135
+ - fix for ns_parse, xbel2html and xbel-parse breaking entity parsing
+ in titles
+ - removed patches forcing the use of xmlproc in xbel_parse and
+ xbel2html
+ * removed libxmltok1 from Build Dependencies
+
+ -- Alexandre Fayolle Fri, 12 Jul 2002 11:42:58 +0200
+
+python-xml (0.7.1-1) unstable; urgency=low
+
+ * New maintainer.
+ * New upstream release.
+ * Added missing copyrights for schema/trex.py, test/domapi/,
+ and xml/dom/ext/c14n.py.
+ * removed broken 4XSLT (4XPath is in the package)
+
+ -- Alexandre Fayolle Wed, 12 Jun 2002 10:07:28 +0200
+
+python-xml (0.7-3) unstable; urgency=high
+
+ * debian/control: added conflict with python-4suite for versions
+ lower than 0.12. Closes: Bug#145499.
+
+ -- Jerome Marant Thu, 2 May 2002 23:27:11 +0200
+
+python-xml (0.7-2) unstable; urgency=high
+
+ * Applied the following patches:
+ - fix for broken links in xmlproc docs. Closes: Bug#133548.
+ - fix for unescaped namespace attributes in Printer.py. Closes: Bug#140148.
+ - support for annotations in ns_parse and xbel2html.
+ Thanks to Alexandre Fayolle. Closes: Bug#141553.
+ * Provide again 4XPath and 4XSLT since the current 4Suite version
+ cannot be installed along with this version of python-xml any more.
+
+ -- Jerome Marant Wed, 1 May 2002 09:03:44 +0200
+
+python-xml (0.7-1) unstable; urgency=low
+
+ * New upstream release.
+ * We do not provide 4XPath and 4XSLT since they are still part of
+ the current version of python-4suite. They will make their way into
+ the package as soon as the new upstream release of python-4suite
+ comes out.
+ * debian/rules: added installation of xbel 1.1 DTD.
+ * debian/xbel.sgml-catalog: added catalog entry for xbel 1.1.
+ * debian/xbel.{postinst, prerm}: make use of `update-catalog' instead of
+ `install-sgmlcatalog` which is the old catalog management tool.
+ Closes: Bug#124209.
+ * Removed debian/xbel.postrm since the catalog is now removed at
+ prerm time.
+ * debian/control:
+ - modified xbel long description reflecting the existence of multiple
+ DTDs for xbel.
+ - made python-xml depend on python2.1-xml of version Source-Version.
+ * debian/python{2.1, 2.2}-xml.README.debian: added a small paragraph
+ explaining the reasons why we do not ship 4XPath and 4XSLT.
+
+ -- Jerome Marant Fri, 28 Dec 2001 22:21:29 +0100
+
+python-xml (0.6.6-7) unstable; urgency=low
+
+ * Added generation of python2.2-xml, a Python 2.2.x specific version
+ of the package. Closes: Bug#122835.
+
+ -- Jerome Marant Fri, 7 Dec 2001 22:01:01 +0100
+
+python-xml (0.6.6-6) unstable; urgency=low
+
+ * debian/rules: replace python version independent shebang lines
+ of all xbel-utils scripts with python2.1 specific ones.
+ Closes: Bug#122395.
+ * Added extra files that are necessary to make possible the compilation
+ of latex documentation files. Closes: Bug#119771.
+
+ -- Jerome Marant Tue, 4 Dec 2001 21:30:32 +0100
+
+python-xml (0.6.6-5) unstable; urgency=low
+
+ * debian/xbel-utils.postinst: replaced calls to `python' with calls
+ to python2.1 for bytecode compilation. Closes: Bug#119004, Bug#119069.
+ * [xbel-utils]: bookmark parsing now works fine with Python 2.1.x
+ and greater versions (tested with J.H.M. Dassen bookmarks).
+ Closes: Bug#47238.
+
+ -- Jerome Marant Sun, 11 Nov 2001 20:16:41 +0100
+
+python-xml (0.6.6-4) unstable; urgency=low
+
+ * Build python-xml as an architecture independent package.
+
+ -- Jerome Marant Wed, 7 Nov 2001 21:58:19 +0100
+
+python-xml (0.6.6-3) unstable; urgency=low
+
+ * Modified the package with respect to the Python Policy.
+ Closes: Bug#118442.
+ * debian/control:
+ + added python2.1-xml, a Python 2.1.x specific version of the
+ package.
+ + python-xml is now a dummy package that depends on python2.1-xml.
+ + added python2.1-dev in build dependencies.
+ * debian/rules:
+ + install xbel XML files into /usr/share/sgml rather than /usr/lib/sgml.
+ Closes: Bug#115910.
+ + removed support for Python 1.5.x and 2.0.
+ * xbel.dirs: replaced /usr/lib/sgml prefixes with /usr/share/sgml.
+ * [xbel-utils] applied patches from Matthew Swift:
+ + fixed nesting. Closes: Bug#111440.
+ + fixed DOS newlines support: Closes: Bug#111428.
+
+ -- Jerome Marant Tue, 6 Nov 2001 20:20:03 +0100
+
+python-xml (0.6.6-2) unstable; urgency=low
+
+ * [python-xml] debian/rules: shipped c14n.py back. Beware, this
+ file is mandatory but might not work with Python 1.5.x.
+ Closes: Bug#109074.
+ * [xbel-utils] added manpages. Thanks to Jan Schaumann.
+
+ -- Jerome Marant Mon, 20 Aug 2001 10:54:16 +0200
+
+python-xml (0.6.6-1) unstable; urgency=low
+
+ * New upstream version.
+ * Switched Standards-Version to 3.5.6.
+ * debian/rules: added a patch section, borrowed from BDS.
+ * Added a 'debian/patches' subdirectory.
+ * Converted to Debhelper v3.
+ * [xbel-utils] patch #003: changed the default parser to xmlproc in
+ order to handle 8 bits characters. Closes: Bug#103748.
+
+ -- Jerome Marant Mon, 6 Aug 2001 10:56:36 +0200
+
+python-xml (0.6.5-2) unstable; urgency=low
+
+ * Added alternatives in order to share common scripts and
+ manpages between python-xml and python2-xml. Closes: Bug#90683.
+
+ -- Jerome Marant Thu, 22 Mar 2001 12:50:30 +0100
+
+python-xml (0.6.5-1) unstable; urgency=low
+
+ * New upstream version.
+
+ -- Jerome Marant Tue, 20 Mar 2001 12:35:35 +0100
+
+python-xml (0.6.4-2) unstable; urgency=low
+
+ * Changed maintainer email address.
+ * [python2-xml] Replaced the conflict by a dependency
+ on python2-xmlbase : this is necessary in order to avoid breaking
+ applications on `import xml'. Closes: Bug#89823.
+ * python2-xml.README.debian : removed the line mentioning the
+ need to import `_xmlplus' rather than `xml'.
+
+ -- Jerome Marant Sat, 17 Mar 2001 11:43:57 +0100
+
+python-xml (0.6.4-1) unstable; urgency=low
+
+ * New upstream version.
+ * New python2-xml package.
+ * Added python2-dev to build dependencies.
+
+ -- Jerome Marant Tue, 27 Feb 2001 09:35:41 +0100
+
+python-xml (0.6.3-1) unstable; urgency=low
+
+ * New upstream version. Closes: Bug#82882
+ * quotes demo is now using a parser that can handle UTF-8. Closes: Bug#67484
+ * [xbel] Changed the DTD name in xbel.sgml-catalog
+ * [xbel-utils] Changed dependency on python-xml because it does not work
+ with 0.5.x versions any more.
+ * [xbel-utils] Added link to /usr/bin for msie_parse.py: parsing MSIE
+ bookmarks does work. Modifyed README.debian for xbel-utils reflecting
+ this change. Closes: Bug#82538
+ * [xbel-utils] Changed the default parser in xbel2html so that 8 bits
+ characters can be handled.
+ * Updated copyright file.
+
+ -- Jerome Marant Wed, 17 Jan 2001 12:00:19 +0100
+
+python-xml (0.6.2-2) unstable; urgency=low
+
+ * Fix a lintian warning.
+
+ -- Jerome Marant Thu, 23 Nov 2000 09:12:57 +0100
+
+python-xml (0.6.2-1) unstable; urgency=low
+
+ * New upstream version.
+ * Improved postinst for diversion removal. Closes: Bug#77237.
+ * Added a warning section in README.Debian about the former
+ diversion bug.
+
+ -- Jerome Marant Sun, 19 Nov 2000 15:39:11 +0100
+
+python-xml (0.6.1-1) unstable; urgency=low
+
+ * New upstream release.
+ * New maintainer.
+ * Adopted. Closes: Bug#68636.
+ * Fix by Joel Rosdahl for postinst diversion bug. Closes: Bug#74950.
+
+ -- Jerome Marant Fri, 20 Oct 2000 17:30:13 +0200
+
+python-xml (0.5.1-6) unstable frozen; urgency=medium
+
+ * Changed paths of documentation files in debian/doc-base
+ /usr/doc -> /usr/share/doc (closes: #69556).
+ * Added Build-Depends (closes: 72443).
+
+ -- Peter Palfrader Tue, 26 Sep 2000 21:09:05 +0200
+
+python-xml (0.5.1-5) unstable frozen; urgency=medium
+
+ * Re-upload to frozen. Note to release manager: see bug #59885 for
+ discussion of this. The only change to the package is to remove the
+ overrides discussed in the bug report.
+
+ -- Rob Tillotson Mon, 3 Apr 2000 17:48:08 -0500
+
+python-xml (0.5.1-4) frozen unstable; urgency=low
+
+ * [python-xml] Removed diversion of xmllib/sgmllib. (closes: #59885)
+
+ -- Rob Tillotson Tue, 7 Mar 2000 23:21:47 -0600
+
+python-xml (0.5.1-3) unstable; urgency=low
+
+ * [xbel] Test for existence of install-sgmlcatalog in postinst
+ and postrm. (closes: #47376)
+ * [python-xml] Remove extraneous directories. (closes: #39509)
+ * Add #DEBHELPER# sections to all relevant scripts.
+ * Standards-Version 3.0.0.
+ * Move documentation to /usr/share/doc.
+
+ -- Rob Tillotson Mon, 25 Oct 1999 16:31:19 -0500
+
+python-xml (0.5.1-2) unstable; urgency=low
+
+ * Moved XBEL DTD and scripts out of the python-xml binary package,
+ into their own packages. (closes #36853)
+
+ -- Rob Tillotson Thu, 29 Apr 1999 17:09:23 -0500
+
+python-xml (0.5.1-1) unstable; urgency=low
+
+ * New upstream release.
+ * dom/writer.py: added 'link' to the list of empty HTML elements (closes
+ #32474)
+
+ -- Rob Tillotson Sun, 18 Apr 1999 02:13:01 -0500
+
+python-xml (0.5-1) unstable; urgency=low
+
+ * New upstream release.
+ * Registered HTML documentation with doc-base.
+
+ -- Rob Tillotson Sun, 20 Dec 1998 16:49:33 -0600
+
+python-xml (0.4.19981014-1) unstable; urgency=low
+
+ * New upstream CVS snapshot.
+
+ -- Rob Tillotson Wed, 14 Oct 1998 14:31:38 -0400
+
+python-xml (0.4-0.1) unstable; urgency=low
+
+ * Now uses the xmltok1 package rather than its own copy of libexpat.
+
+ -- Rob Tillotson Tue, 29 Sep 1998 15:51:56 -0400
+
+python-xml (0.4-0) unstable; urgency=low
+
+ * New upstream release.
+
+ -- Rob Tillotson Thu, 6 Aug 1998 15:32:35 -0500
+
+python-xml (0.3-0.1) unstable; urgency=low
+
+ * New upstream release.
+
+ -- Rob Tillotson Thu, 25 Jun 1998 15:25:34 -0500
+
+python-xml (0.2-0.1) unstable; urgency=low
+
+ * Initial Release.
+
+ -- Rob Tillotson Sun, 14 Jun 1998 06:17:44 -0500
+
+
+
--- python-xml-0.8.4.orig/debian/xbel.prerm
+++ python-xml-0.8.4/debian/xbel.prerm
@@ -0,0 +1,19 @@
+#!/bin/sh -e
+
+# Remove SGML catalog entries
+
+PACKAGE=xbel
+CENTRALCAT=/etc/sgml/$PACKAGE.cat
+
+if [ "$1" = remove ]; then
+
+ update-catalog --quiet --remove --super $CENTRALCAT
+
+elif [ "$1" = purge ]; then
+
+ rm -f $CENTRALCAT $CENTRALCAT.old
+fi
+
+#DEBHELPER#
+
+exit 0
--- python-xml-0.8.4.orig/debian/xbel.dirs
+++ python-xml-0.8.4/debian/xbel.dirs
@@ -0,0 +1,5 @@
+usr/share/sgml/misc/xbel
+usr/share/sgml/IDN_python.org/dtd
+usr/share/sgml/dtd
+usr/share/doc/xbel
+
--- python-xml-0.8.4.orig/debian/xbel-utils.README.debian
+++ python-xml-0.8.4/debian/xbel-utils.README.debian
@@ -0,0 +1,51 @@
+xbel-utils for DEBIAN
+---------------------
+
+This is an XML DTD for the interchange of web browser bookmarks. It
+is intended to fully represent the bookmarks of all of the major web
+browsers, so that bookmarks can be easily converted between them.
+(XBEL is also supported natively by Grail, the Python web browser from
+CNRI.) XBEL is a project of the Python Software Activity XML-SIG, and
+current information about it can be found at:
+
+ http://www.python.org/topics/xml/xbel/
+
+This package contains conversion utilities for translating between XBEL
+and bookmarks for Lynx, Netscape, Opera, Internet Explorer, and plain
+HTML. The DTD and documentation are in the 'xbel' package.
+
+Converting from browser formats to XBEL:
+
+ lynx_parse [] -- Lynx
+ msie_parse -- MSIE
+ ns_parse [] -- Netscape
+ adr_parse [] -- Opera
+
+ If no XBEL output file is specified, the resulting XBEL instance is
+ dumped to standard output.
+
+ Note that the Lynx conversion utilities take a *directory* as argument,
+ and consider each Lynx bookmark file to be a separate XBEL folder.
+
+Converting XBEL to other formats:
+
+ xbel2html
+ converts an XBEL instance to HTML (on standard output)
+
+ xbel_parse
+ converts an XBEL instance to browser bookmarks. Except when
+ converting to Lynx, the resulting bookmarks are dumped to standard
+ output.
+
+ You MUST specify one of the following browser formats:
+
+ --lynx
+ --msie
+ --netscape
+ --opera
+ --xbel
+
+Please note that these utilities are simple and experimental, and are
+likely unable to handle invalid input. (If you want to write more
+robust XBEL applications, I'm sure the XML-SIG would welcome your
+efforts!)