[SCM] image display tool for astronomy branch, upstream, updated. 8f2997b7aef6aedf10611ac55b976aae53fb2f9f

Ole Streicher debian at liska.ath.cx
Wed Jan 25 09:57:17 UTC 2012


The following commit has been merged in the upstream branch:
commit 8f2997b7aef6aedf10611ac55b976aae53fb2f9f
Author: Ole Streicher <debian at liska.ath.cx>
Date:   Wed Jan 25 10:56:02 2012 +0100

    Remove more packages that are in Debian:
    tkcon-2.5, tclxml-3.2: Both are in Debian

diff --git a/tclxml-3.2/ANNOUNCE b/tclxml-3.2/ANNOUNCE
deleted file mode 100644
index 52d6437..0000000
--- a/tclxml-3.2/ANNOUNCE
+++ /dev/null
@@ -1,21 +0,0 @@
-TclXML version 3.2 is now available.
-
-TclXML is a package that provides XML parsing for the Tcl scripting language.
-It has two implementations of XML parsers: one written purely in Tcl
-and a wrapper for the Gnome libxml2 C library.
-
-The TclXML package now incorporates the TclDOM and TclXSLT packages.
-TclDOM and TclXSLT were previously distributed as separate packages.
-The three packages may still be used as if they were standalone.
-
-Sources, and binaries for Mac OS X and MS Windows, are available now.  
-
-These packages may be downloaded from the TclXML website:
-
-      http://tclxml.sourceforge.net/
-
-Enjoy,
-Steve Ball
-Explain
-http://www.explain.com.au/
-
diff --git a/tclxml-3.2/ChangeLog b/tclxml-3.2/ChangeLog
deleted file mode 100755
index 8a52501..0000000
--- a/tclxml-3.2/ChangeLog
+++ /dev/null
@@ -1,667 +0,0 @@
-2008-12-04  Steve Ball  <Steve.Ball at explain.com.au>
-	* doc/html.xsl, doc/*.xml: Upgrade to DocBook v5.0. Eliminate
-	dependency on DocBook XSL stylesheets.
-
-2008-12-02  Steve Ball  <Steve.Ball at explain.com.au>
-	* configure.in, Makefie.in: fix build problems on Linux.
-
-2008-11-26  Steve Ball  <Steve.Ball at explain.com.au>
-	* Makefile.in, tests/*: reorganised tests subdir and merged
-	tests from all three packages.
-
-2008-11-20  Steve Ball  <Steve.Ball at explain.com.au>
-	* tclxml-tcl/sgmlparser.tcl, tclxml-tcl/tclparser-8.1.tcl:
-	Surround switch labels in braces (bug fix #812051).
-
-2008-07-01  Steve Ball  <Steve.Ball at explain.com.au>
-	* Merged TclDOM and TclXSLT packages into a single TclXML
-	package. Reorganised directory structure. Statically link 
-	libxml2 and libxslt libraries to the TclXML shared library.
-
-2005-12-28  Steve Ball  <Steve.Ball at explain.com.au>
-	* Applied patches for TEA build.  Patches courtesy Daniel Steffen (steffen at ics.mq.edu.au).
-
-==============  Released version 3.1      04/11/2005  ==============
-
-2005-11-04  Steve Ball  <Steve.Ball at explain.com.au>
-	* libxml2/tcllibxml2.c: Cleaned-up memory leaks, bug #1251711 and patch #1112132.
-
-2005-05-13  Steve Ball  <Steve.Ball at explain.com.au>
-	* libxml2/tcllibxml2.c: Added call to end element handler when element is empty.
-
-2005-04-20  Steve Ball  <Steve.Ball at explain.com.au>
-	* tclxml.c, libxml2/tcllibxml2.c, doc/tclxml.xml: changed interpretation of TCL_CONTINUE return code for external entity command
-
-2005-03-02  Steve Ball  <Steve.Ball at explain.com.au>
-	* libxml2/tcllibxml2.c (TclXMLlibxml2ExternalEntityLoader): externalentitycommand is evaluated and returns xmlParserInputPtr
-
-2004-10-24  Steve Ball  <Steve.Ball at zveno.com>
-	* win/makefile.vc: Use DLL on Windows
-
-2004-09-24  Steve Ball  <Steve.Ball at zveno.com>
-	* libxml2/docObj.c (TclXML_libxml2_CreateObjFromDoc): Added Tcl_IncrRefCount (bug fix #1032660, David Welton).
-
-2004-09-15  Steve Ball  <Steve.Ball at zveno.com>
-	* doc/tclxml.xml: Fixed docn bug (missing xml::parserclass info default)
-
-2004-09-03  Steve Ball  <Steve.Ball at zveno.com>
-	* win/makefile.vc: Changed link options for zlib-1.2.1.
-
-2004-08-30  Steve Ball  <Steve.Ball at zveno.com>
-	* libxml2/tcllibxml2.c (Parse): Added support for "-defaultexpandinternalentities" and "-nowhitespace" options.
-	* tclxml.c: Fixed bug in setting -defaultexpandinternalentities option.
-
-2004-08-13  Steve Ball  <Steve.Ball at zveno.com>
-	* configure.in: Bumped version to 3.1
-	* libxml2/docObj.c: added check for intialization to SetErrorNodeFunc function.
-
-==============  Released version 3.0      11/07/2004  ==============
-
-2004-07-11  Steve Ball  <Steve.Ball at zveno.com>
-	* libxml2/configure.in: Modified configure help message to match proper usage.
-	Changed usr/... to /usr/...
-	* win/makefile.vc: Fixed bug in install target
-
-==============  Released version 3.0b2    26/02/2004  ==============
-
-2004-02-20  Steve Ball  <Steve.Ball at zveno.com>
-	* libxml2/docObj.c: Fixed bug in error object management.
-	* tclxml.c: Fixed bug in continue return code handling.
-
-2004-02-02  Steve Ball  <Steve.Ball at zveno.com>
-	* libxml2/tcllibxml2.c: xmlTextReader interface now uses structured error reporting.
-
-2004-01-28  Steve Ball  <Steve.Ball at zveno.com>
-	* tclxml.c: Added "-encoding" option.  If not utf-8 document text is treated as a byte array (ie. binary data).
-	* libxml2/tcllibxml2.c: Use xmlTextReader interface.  Added "-retainpath", "-retainpathns" options.
-
-2003-12-17  Steve Ball  <Steve.Ball at zveno.com>
-	* doc/README.xml: Updated Windows build instructions.
-	* win/makefile.vc: Fixed building with libxml2-2.6.3 binary distro.
-
-==============  Released version 3.0b1    15/12/2003  ==============
-
-2003-12-15  Steve Ball  <Steve.Ball at zveno.com>
-	* doc/tclxml.xml: Added description of structured error messages.
-
-2003-12-09  Steve Ball  <Steve.Ball at zveno.com>
-	* LICENSE: Bug #838361: Clarified permission for copying and distribution.
-	* various: Removed license terms and inserted pointer to LICENSE file.
-
-2003-12-06  Steve Ball  <Steve.Ball at zveno.com>
-	* tclexpat.c: Patch for bug #846987
-	* doc/README.txt: Update for v3.0b1 release
-
-2003-12-03  Steve Ball  <Steve.Ball at zveno.com>
-	* Makefile.in, libxml2/Makefile.in: Fix TEA build system
-
-2003-11-03  Steve Ball  <Steve.Ball at zveno.com>
-	* libxml2/docObj.c, libxml2/tcllibxml2.c: Upgraded to SAX2 interfaces.  Use structured error reporting.
-
-2003-09-10  Steve Ball  <Steve.Ball at zveno.com>
-	* win/makefile.vc: Added for building on Windows using MS VS C++ 6.0.
-	* Various changes for building on Windows.
-	* libxml2/tcllibxml2.c: Include <libxml/globals.h> and remove explicit declaration of libxml2 variable.
-
-2003-08-24  Steve Ball  <Steve.Ball at zveno.com>
-	* tclexpat.c: Applied patch for bug #714316, fixes attribute list declaration handler.
-
-2003-08-22  Steve Ball  <Steve.Ball at zveno.com>
-	* Makefile.in: Fixed tests.
-	* library/sgmlparser.tcl, tclparser-8.1.tcl: Fixed bug #676399 - resolving external entities.
-	* doc/nroff.xsl: Fixed buggy nroff output, bug #693590.
-
-2003-08-21  Steve Ball  <Steve.Ball at zveno.com>
-	* library/sgmlparser.tcl: Fixed escaping bug when parsing comments,
-	check for "xml" anywhere in PI target.
-	Fixed bug #583947 by removing comments in DTD.
-	* library/tclparser-*.tcl, sgmlparser.tcl: Added -baseuri option.  -baseurl is deprecated.
-	* tclxml.c: Fix bug parsing args for creating slave entity.
-
-2003-08-19  Steve Ball  <Steve.Ball at zveno.com>
-	* libxml2/tcllibxml2.c: Fix TEA setup for Linux build.
-
-2003-08-12  Steve Ball  <Steve.Ball at zveno.com>
-	* tclexpat.c: Updated Configure routine.
-	* expat/configure.in, expat/Makefile.in: Update for v3.0.
-	* libxml2/tcllibxml2.h: Fix header file configuration.
-	* libxml2/configure.in, libxml2/Makefile.in, libxml2/docObj.h: Fix include dir.
-
-2003-08-07  Steve Ball  <Steve.Ball at zveno.com>
-	* tclxml.c: Added -baseuri option as a synonym for -baseurl.
-	* libxml2/tcllibxml2.c: Set ::xml::libxml2::libxml2version variable
-	to the version of libxml2 being used.
-
-2003-08-04  Steve Ball  <Steve.Ball at zveno.com>
-	* tclxml.c, libxml2/tcllibxml2.c: Fixed instance configuration.
-
-2003-08-03  Steve Ball  <Steve.Ball at zveno.com>
-	* tests/*: Completed upgrade, test all parser classes.
-
-2003-07-28  Steve Ball  <Steve.Ball at zveno.com>
-	* tclxml.c: Flush PCDATA when parse terminates.
-	* libxml2/tcllibxml2.c, docObj.c: Bug fixes.
-	* tests/*: Upgrade to tcltest v2.2 infrastructure.
-
-2003-06-29  Steve Ball  <Steve.Ball at zveno.com>
-	* libxml2/docObj.c: Improve C API for use with TclDOM/libxml2
-
-2003-06-19  Steve Ball  <Steve.Ball at zveno.com>
-	* tclxml.c, tclexpat.c, libxml2/tcllibxml2.c: Change access to 
-	  global/static data to make the extension thread-oblivious.
-
-2003-06-05  Steve Ball	<Steve.Ball at zveno.com>
-	* libxml2/docObj.c: Initialise hash table.
-	* libxml2/tcllibxml2.c: Call docObj init routine,
-	  fleshed out callbacks to generic layer.
-
-2003-05-28  Steve Ball	<Steve.Ball at zveno.com>
-	* libxml2/*: Added libxml2 wrapper.
-	* Updated v3_0 branch for version 3.0.
-
-2003-04-04  Andreas Kupries  <andreask at activestate.com>
-
-	* expat/configure: Regenerated.
-	* tclconfig/tcl.m4: Updated to newest tcl.m4, again. Added
-	  fallback for exec_prefix.
-
-2003-04-03  Andreas Kupries  <andreask at activestate.com>
-
-	* expat/configure: Regenerated.
-	* tclconfig/tcl.m4: Updated to the newest version.
-
-==============  Released version 2.6    05/03/2003  ==============
-
-2003-03-05  Steve Ball  <Steve.Ball at zveno.com>
-	* win/build.data: Version number is taken from installation data.
-
-2003-03-03  Steve Ball  <Steve.Ball at zveno.com>
-	* install.tcl: removed debugging commands.
-
-2003-02-07  Steve Ball	<Steve.Ball at zveno.com>
-	* Prepare v2.6 release.
-
-2003-02-22  Steve Ball  <Steve.Ball at zveno.com>
-	* doc/README.xml: converted README to XML format.  Added XSL
-	stylesheet to create text format file.
-	
-==============  Released version 2.5    10/12/2002  ==============
-
-2002-12-10  Steve Ball  <Steve.Ball at zveno.com>
-	* library/sgmlparser.tcl: Patch for -final option
-	  (ted at ags.ga.erq.sri.com)
-
-2002-12-06  Steve Ball  <Steve.Ball at zveno.com>
-	* Update for v2.5 release.
-	* library/sgmlparser.tcl (ParseEvent:ElementOpen):
-	  fixed '>' in attribute value in an empty element,
-	  bug #620034.
-
-2002-11-01  Andreas Kupries  <andreask at pliers.activestate.com>
-
-	* Makefile.in: Removed code of target 'install-doc'. We have no
-	  manpages (.n files), and so the code removes everything in the
-	  mann directory in the installaltion area.
-
-==============  Released version 2.4    31/10/2002  ==============
-
-2002-10-31  Steve Ball  <Steve.Ball at zveno.com>
-
-	* README: Updated installation instructions.
-	
-==============  Released version 2.4rc1 29/10/2002  ==============
-
-2002-10-29  Steve Ball  <Steve.Ball at zveno.com>
-	* install.tcl: Remove '-' from install directory, 
-	  fixed UpdateTemplateCopy so that unspecified TEA variables
-	  don't prevent other variables from being substituted.
-	* configure, library/pkgIndex.tcl.macosx: removed: generated files 
-	  or no longer required.
-	* library/tclparser-8.1.tcl (xml::tclparser::reset): Check if the
-	  parser has been properly initialised.  Call create if it hasn't.
-
-2002-10-28  Andreas Kupries  <andreask at activestate.com>
-
-	* expat/xmlwf/readfilemap.c: Added prototypes missing on windows,
-	  and cast to ensure comparison of compatible types. Required for
-	  Windows debug builds as these use -WX, making warnings into
-	  errors.
-
-2002-10-25  Andreas Kupries  <andreask at activestate.com>
-
-	* tclxml.c (TclXMLResetParser): Added cast, removed unused variable 'i'.
-
-	* tclxmlStubLib.c (TclXML_InitStubs): Provide un-const'ed version of
-	  'version' to Tcl_PkgRequireEx to supress warnings.
-
-2002-10-15  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tclconfig/tcl.m4:
-	* expat/configure:
-	* expat/configure.in:
-	* configure:
-	* configure.in: move the CFLAGS definition into TEA_ENABLE_SHARED
-	and make it pick up the env CFLAGS at configure time.
-
-2002-10-15  Andreas Kupries  <andreask at activestate.com>
-
-	* expat/configure.in:
-	* configure.in: Changed to propagate an initial CFLAGS value to
-	  the final definition. A TEA condition (SHARED_BUILD == 1)
-	  squashed it, causing it the build system to loose the
-	  +DAportable we specify for the AS PA-RISC2.2 build host. This is
-	  a problem for _all_ TEA and TEA 2 based configure files.
-
-2002-10-15  Steve Ball  <Steve.Ball at zveno.com>
-
-	* *.in: Updated version numbers for v2.4.
-
-2002-10-02  Andreas Kupries  <andreask at activestate.com>
-
-	* Makefile.in ($($(PACKAGE)stub_LIB_FILE)): Corrected explicit
-	  usage of AR.
-
-2002-09-27  Andreas Kupries  <andreask at activestate.com>
-
-	* expat/configure.in:
-	* expat/Makefile.in: Added code to pick up the tclxml
-	  configuration and stub library.
-	
-	* TclxmlConfig.sh.in: New file.
-	* configure.in: Added code to generate a config.sh file. This will
-	  be used by the expat module to pick up the tclxml stub library.
-
-2002-09-26  Andreas Kupries  <andreask at activestate.com>
-
-	* expat/Makefile.in (Tclexpat_SOURCES): Corrected typo. It is
-	  xmltok.c, not .o. D'oh.
-
-	* tclexpat.c (Tclexpat_Init): Added commands to initialize
-	  classinfo->reset and ->resetCmd. Without this trying to create
-	  an expat-based parser will segfault as the generic layer will
-	  jump through uninitialized pointers. Incomplete realization of
-	  the new option -resetcommand.
-
-2002-09-25  Andreas Kupries  <andreask at activestate.com>
-
-	* expat/Makefile.in:
-	* expat/configure.in:
-	* expat/aclocal.m4: Rewritten to use TEA 2 as base of the build
-	  system. This configure/makefile copiles the expat low-level
-	  stuff and the tcl binding in one go, into one library. The
-	  package index is separate from the generic xml layer.
-
-	* Makefile.in:
-	* configure.in:
-	* library/pkgIndex.tcl.in: Rewritten to use TEA 2 as base of build
-	  system. Refactoring, taking out generation of tclexpat stuff,
-	  this will go into its own configure/Makefile in the expat
-	  directory => Less of a mess for configuring and compiling the
-	  two packages.
-	* tools:
-	* tclconfig: New directories. See above.
-	* tclxml.h: Removed duplicate of TCL_EXTERN stuff.
-
-2002-09-19  Steve Ball  <Steve.Ball at zveno.com>
-
-	* tclxml.c (TclXMLParserClassCmd): Added -resetcommand to parserclass command.
-
-2002-09-13  Andreas Kupries  <andreask at activestate.com>
-
-	* Makefile.in ($(TCLXML_LIB_FILE)_OBJECTS): Added stub objects to
-	  link list for main library. Without we get unsatisfied symbols
-	  when trying to load the library.
-	  (tclxmlStubInit.$(OBJEXT)): 
-	  (tclxmlStubLib.$(OBJEXT)): Added targets to compile the stub sources.
-
-2002-09-12  Andreas Kupries  <andreask at activestate.com>
-
-	* configure.in (MINOR_VERSION): Bumped to 3. Full version now
-	  2.3. Additional changes to make compilation on AIX more robust.
-
-	* Makefile.in: See above, AIX.
-
-==============  Released version 2.3  13/09/2002  ==============
-
-2002-09-13  Steve Ball  <Steve.Ball at zveno.com>
-	* tclxml.c, tclxml.h, Makefile.in, tclxmlDecls.h, tclxml.decls, tclxmlStubInit.c, tclxmlStubLib.c: Applied patches to improve building from Andreas Kupries and patches from David Gravereaux for stubs.
-
-2002-09-09  Steve Ball  <Steve.Ball at zveno.com>
-
-	* library/sgmlparser.tcl (sgml::tokenise): Patch from bug #596959.
-
-==============  Released version 2.3rc2  07/09/2002  ==============
-
-2002-09-06  Steve Ball  <steve at localhost>
-
-	* tests/parser.test, library/sgmlparser.tcl, library/tclparser-8.1.tcl: Fixed bug #579264 by implementing -ignorewhitespace option.
-	* Added check for illegal Unicode characters in PCDATA.
-
-2002-09-04  Steve Ball  <steve at localhost>
-
-	* library/tclparser-8.1.tcl (xml::tclparser::reset): Added reset function.
-
-	* library/xml__tcl.tcl (xml::ParserCmd): Invoke reset command, rather than just deleting and creating a parser.
-
-2002-08-30  Steve Ball  <Steve.Ball at zveno.com>
-
-	* tclexpat.c: Fixed crash in element decl handler.
-
-2002-08-28  Steve Ball  <steve at localhost>
-
-	* library/xml-8.1.tcl, library/xml-8.0.tcl: Added definition of XML Namespace URI
-
-2002-06-28  Mats Bengtsson <matben at privat.utfors.se>
-
-	* library/sgmlparser.tcl: fixes for -final 0 bug #413341.
-	  corrected list structure of all -errorcommand callbacks bug #467785.
-	  catch & -code in -elmentendcallback bug #521740.
-	  checks for state(line) instead for state to handle inits for 
-	  -final 0 correctly
-	* library/tclparser-8.1.tcl: fixes for -final 0 bug #413341.
-	  changed xml::tclparse::configure and calls it in xml::tclparse::parse
-
-2002-06-19  Steve Ball  <steve at localhost>
-
-	* library/xml__tcl.tcl (xml::ParserCmd): free method removes command in caller's namespace. Bug #510418.
-
-2002-06-17  Steve Ball  <steve at localhost>
-
-	* library/sgmlparser.tcl (sgml::DeProtect1): Applied patch #521642.
-
-2002-06-14  Steve Ball  <steve at localhost>
-
-	* library/xpath.tcl (xpath::ParseExpr): Fixed bug #568354 - abbreviated node-type test in predicate.
-
-2002-06-11  Steve Ball  <steve at localhost.webone.com.au>
-
-	* library/tclparser-8.1.tcl (xml::tclparser::ParseAttrs): Fixed bug in character entity dereferencing.  Bug #546295.
-
-	* library/sgmlparser.tcl (sgml::parseEvent): Applied patch for bug #566452 to fix PIs
-
-2002-05-27  Andreas Kupries <andreas_kupries at users.sourceforge.net>
-	
-	* library/sgmlparser.tcl (sgml::Entity): Fixed code defining
-	  'entities' if not defined, using code in parseEvent] as
-	  template.
-
-	* library/tclparser-8.1.tcl
-	  (xml::tclparser::NormalizeAttValue:DeRef): Fixed the errors in
-	  the calls to [string range] (first two branches of the switch).
-
-	* install.tcl (line 306): args needs no default value of empty. Is
-	  empty as per definition of 'args' when used as last argument.
-
-2002-05-20  Steve Ball       <Steve.Ball at zveno.com>
-	* install.data, library/sgmlparser.tcl: Fixed bug 513985.
-	  Replaced 'package require tcllib' with 'package require uri'.
-	* library/sgmlparser.tcl: Fixed bug 495427 (applied suggested patch).
-	* LICENSE: Added
-
-2002-02-19  Andreas Kupries  <andreas_kupries at users.sourceforge.net>
-
-	* Makefile.in (install-lib-binaries): Changed INSTALL_DATA to
-	  INSTALL_PROGRAM to prevent the copy operation from removing the
-	  executable flag for libraries on platforms which do need
-	  it. Like HPUX.
-
-	* tclxml.c (TclXMLCreateParserCmd): Fixed SF TclXML Bug
-	  513909. The code now handles multiple occurences of "-parser
-	  class" and also takes care to hide them when it comes to the
-	  general configuration during creation.
-
-2002-02-06  Andreas Kupries  <andreas_kupries at users.sourceforge.net>
-
-	* tclxml.c (TclXMLConfigureParserInstance): Copied code from
-	  "TclXMLInstanceConfigure" providing the clientdata/instance name
-	  to the parser to configure. This fixes bug 514045.
-
-	* configure:
-	* configure.in:
-	* tclxml.m4: Applied patch 508718 to allow building of expat on
-	  Windows.
-
-	* tclxml.h:
-	* tclexpat.c:
-	* tclxml.c: Updated to TIP 27 (CONST'ness of string tables for
-	  Tcl_GetIndexFromObj).
-
-2002-01-27  Steve Ball       <Steve.Ball at zveno.com>
-	
-	* library/xpath.tcl
-	  Fixed bug in expression parsing.
-	  Reported by Gerard LEDOUBLET.
-
-2001-11-13  Steve Ball       <Steve.Ball at zveno.com>
-
-	* library/sgmlparser.tcl, tests/pcdata.test:
-	  Fixed bug #468029 report by Kenneth Cox.
-
-2001-11-09  Steve Ball       <Steve.Ball at zveno.com>
-
-	* library/sgmlparser.tcl, library/tclparser-8.1.tcl, tests/attribute.test:
-	  Added handling of entity references within an attribute value.
-
-2001-09-05  Andreas Kupries  <andreas_kupries at users.sourceforge.net>
-
-	* Makefile.in (GENERIC_SCRIPTS): Added xpath.tcl to the list of
-	  scripts to install. Fixes [458864].
-
-2001-08-28  Andreas Kupries <andreas_kupries at users.sourceforge.net>
-
-	* tclxml.c (TclXMLInstanceDeleteCmd): Applied the patch fixing SF
-	  Item [456321]. This removes a double free of xmlinfo and also
-	  avoids to access the structure after it was freed.
-
-	* tclxml.c (TclXMLInstanceConfigure): Added a 'Tcl_ResetResult'
-	  before the loop processing the option. This forces the interp
-	  result into a known, unshared state. This also adds Pat Thoyts's
-	  changes to 'instanceConfigureSwitches' declaring some new
-	  '-*command' options and additional argument checks for
-	  'entityparser'. SF Patch [454204].
-
-2001-08-10  Peter Farmer     <Peter.Farmer at zveno.com>     
- 
-        * Makefile.in ($(GENERIC_SCRIPTS)): Fixed bugs in earlier
-          code removed by Andreas and put it back.
-
-.2001-08-02  Steve Ball     <Steve.Ball at zveno.com>
-	--- Released TclXML 2.1theta ---
-
-2001-07-31  Andreas Kupries  <andreas_kupries at users.sourceforge.net>
-
-	* Makefile.in ($(GENERIC_SCRIPTS)): Removed creation of
-	  soft-link. When using a builddirectory below the toplevel
-	  directory the created link is circular and the following cp
-	  operations fails [SF 446485].
-
-2001-07-30  Steve Ball     <Steve.Ball at zveno.com>
-	* library/sgmlparser.tcl
-	Fixed bug #434304: whitespace not accepted in XML Declaration.
-	Side-effect is to improve WF checking.
-	* library/sgmlparser.tcl
-	Fixed bug #431353: entity references plus Tcl specials
-
-2001-02-26  Peter Farmer     <Peter.Farmer at zveno.com>
-	* library/tclparser-8.?.tcl
-        Added missing arg to pass -final thru to document instance parser
-
-2001-02-12  Steve Ball     <Steve.Ball at zveno.com>
-	* library/sgmlparser.tcl
-	* tests/cdata.test, tests/pi.test, tests/decls.test,
-	* tests/entity.test, tests/doctype.test
-	Fixed bug #131878: XML test documents not well-formed.
-	Fixing the tests revealed bugs in the parser.
-
-2001-02-09  Steve Ball     <Steve.Ball at zveno.com>
-	* library/sgmlparser.tcl, tests/cdata.test
-	* library/xmldep.tcl
-	Fixed bug #130127: backslashes in CDATA sections.
-	Added xmldep package (dependency discovery)
-	
-2001-02-06  Peter Farmer   <Peter.Farmer at zveno.com>
-        * install.tcl, install.data, win/build.data, win/install.bat
-        * library/pkgIndex.tcl.in, library/xml__tcl.tcl, tests/*
-        _Many_ significant improvements in the installer. Can now
-        install windows build as well as Unices. Now uses TEA 
-        config files & .in templates, if the build has them, to extract 
-        installation info. Test suite now more portable to new/alternate
-        versions and can test tcl only parser with other parsers present.
-
-2001-01-19  Steve Ball     <Steve.Ball at zveno.com>
-	* library/xpath.tcl
-	Fixed bug in parsing @ abbreviation
-
-2001-01-17  Steve Ball     <Steve.Ball at zveno.com>
-	---   Released TclXML v2.0theta   ---
-
-2001-01-17  Steve Ball     <Steve.Ball at zveno.com>
-	* install.tcl, install.data
-	Generalised PF's pure-Tcl installer.  It now reads the
-	installation data from an external file (script).
-
-2001-01-10  Steve Ball     <Steve.Ball at zveno.com>
-	* library/sgmlparser.tcl, tests/decls.test, tests/entity.test
-	Fixed bugs in external entity parsing and test suite.
-
-2000-12-10  Steve Ball     <Steve.Ball at zveno.com>
-	* library/xml-8.1.tcl
-	Added QName, allWsp
-
-2000-12-01  Steve Ball	   <Steve.Ball at zveno.com>
-	* library/xpath.tcl
-	Support for parsing and constructing XPath location paths.
-	Partial initial implementation.
-
-2000-08-14  Steve Ball     <Steve.Ball at zveno.com>
-	* doc/tclxml.xml, doc/html.xsl, doc/nroff.xsl
-	Updated doco and added XSL stylesheets to produce
-	HTML and NROFF output.
-
-2000-08-01  Steve Ball     <Steve.Ball at zveno.com>
-	* library/sgmlparser.tcl
-	Added support for XML Namespaces
-	
-2000-07-24  Steve Ball     <Steve.Ball at zveno.com>
-	* library/tclparser-8.1.tcl
-	Fixed double backslashes in attribute values
-	
-2000-06-15  Steve Ball     <Steve.Ball at zveno.com>
-	* tclxml.*, tclxerces.cpp, tclexpat.c,
-	  library/tclparser-8.1.tcl
-	Fixed automatic selection of default parser.
-	Fixed registration and running of Tcl-based 
-	parser classes.
-
-2000-06-10  Steve Ball     <Steve.Ball at zveno.com>
-	* library/sgmlparser.tcl, tests/*.test
-	Removed -entityparser option.  Minor fixes to test scripts.
-
-2000-06-01  Steve Ball     <Steve.Ball at zveno.com>
-	* doc/tclxml.xml
-	Completed documenting xml::parser command.
-	
-2000-05-18  Steve Ball     <Steve.Ball at zveno.com>
-	* tclxml.c, tclxerces.cpp, README, doc/tclxml.xml
-	Added -validate configuration option.  TclXerces sets the
-	parser object to validate when performing parsing.
-	Don't have a test, yet.  Also updated README and
-	started documentation (in DocBook).
-
-2000-04-22  Steve Ball     <Steve.Ball at zveno.com>
-	* library/sgmlparser.tcl, library/tclparser-8.1.tcl,
-	  tests/decls.test
-	Added support for external entities.
-	
-2000-04-16  Steve Ball     <Steve.Ball at zveno.com>
-	* library/sgmlparser.tcl, library/tclparser-8.1.tcl,
-	  tests/decls.test
-	Added markup declaration support.  Partial implementation.
-	Also supporting entity substitution.
-
-2000-04-05  Steve Ball     <Steve.Ball at zveno.com>
-	* Makefile.in, configure.in, library/*
-	Fixed Tcl-only package setup and installation.
-	Added Tcl-only parser class framework.
-	Changed Tcl parser implementation to use new parser class
-	framework.
-
-2000-02-10  Steve Ball     <Steve.Ball at zveno.com>
-
-	* tclXerces.cpp, tclXercesHandlers.cpp, tclXercesHandlers.hpp.
-	Added these files.  They implement the "xerces" parser class,
-	providing a wrapper for the Xerces-C (XML4C) XML parser.
-
-2000-01-23  Steve Ball     <Steve.Ball at zveno.com>
-
-	* tclxml.c, tclxml.h: Added these files.  These are the entry points
-	for the tclxml package.  They provide a generic front-end for
-	specific parser class implementations.
-
-	* tclexpat.c: This has been stripped down and is now a back-end
-	parser class implementation.
-
-1999-12-27  Steve Ball     <Steve.Ball at zveno.com>
-
-	* tclexpat.c: Changed class creation command to xml::parser.
-	Propagate error code from application callback,
-	patch from Marshall Rose.  Load xml package on initialisation.
-	Assign unique parser instance command if none given.
-
-	* library/*.tcl, pkgIndex.tcl.in, Makefile.in: 
-	Merged TclXML Tcl scripts into this package.
-
-	* configure.in: Updated to version 2.0
-
-1999-12-12  Steve Ball     <Steve.Ball at zveno.com>
-
-	* tclexpat.c: Accumulate PCDATA in a string object for a single
-	call to -characterdatacommand callback, instead of a call for
-	each line of data.
-
-	* tclexpat.c: Added -ignorewhitespace option.
-
-1999-09-14  Eric Melski  <ericm at scriptics.com>
-
-	* tclexpat.c: In TclExpatAttlistDeclHandler, added a test on attributes
-	to verify that it doesn't point to nothing (ie, a null attlist decl).  This
-	addresses bug 2831.
-
-1999-09-14  Eric Melski  <ericm at scriptics.com>
-
-	* tclexpat.c: Added support for several new callbacks:
-	attlistdecl, elementdecl, {start|end}doctypedecl.  Fixed support
-	for external entity parsing by adding a subcommand (entityparser)
-	to the "instance" command, which allows creation of an external entity
-	parser.  Some minor fixes like removing unused variables.  Added a
-	"free" command to the instance command, which allows user
-	initiated freeing of the parser (required for external entity
-	parsing to function properly).
-	Fixed a compiler warning about const char * and assigning it to a
-	char *.
-
-1999-08-24  Scott Stanton  <stanton at scriptics.com>
-
-	* tclexpat.c: Changed to avoid generating errors on non-standalone
-	documents when no handler is defined.
-
-1999-08-20  Scott Stanton  <stanton at scriptics.com>
-
-	* tclexpat.c: Various lint.  Changed to automatically export
-	public symbols.
-
-	* configure.in: Bumped version number to 1.1
-
-	* Makefile.in: Various changes to support Windows builds.
-
-1999-08-17  Scott Stanton  <stanton at scriptics.com>
-
-	* tclexpat.c: added TCL_STORAGE_CLASS macros to automatically
-	export the _Init symbol.
-
-1999-08-11  Scott Stanton  <stanton at scriptics.com>
-
-	* tclexpat.c: Changed to use Tcl stubs.  Fixed various
-	bugs. Eliminated conditional code for old pre-release versions of
-	8.1.
-
diff --git a/tclxml-3.2/LICENSE b/tclxml-3.2/LICENSE
deleted file mode 100644
index eb6729c..0000000
--- a/tclxml-3.2/LICENSE
+++ /dev/null
@@ -1,35 +0,0 @@
-Copyright (c) 2005 Explain
-http://www.explain.com.au/
-
-Explain makes this software available free of charge for any purpose.
-This software may be copied, and distributed, with or without
-modifications; but this notice must be included on any copy.
-
-The software was developed for research purposes only and Explain does not
-warrant that it is error free or fit for any purpose.  Explain disclaims any
-liability for all claims, expenses, losses, damages and costs any user may
-incur as a result of using, copying or modifying this software.
-
-Copyright (c) 1998-2004 Zveno Pty Ltd
-http://www.zveno.com/
-
-Zveno makes this software available free of charge for any purpose.
-This software may be copied, and distributed, with or without
-modifications; but this notice must be included on any copy.
-
-The software was developed for research purposes only and Zveno does not
-warrant that it is error free or fit for any purpose.  Zveno disclaims any
-liability for all claims, expenses, losses, damages and costs any user may
-incur as a result of using, copying or modifying this software.
-
-Copyright (c) 1997 ANU and CSIRO on behalf of the
-participants in the CRC for Advanced Computational Systems ('ACSys').
- 
-ACSys makes this software and all associated data and documentation 
-('Software') available free of charge for any purpose.  You may make copies 
-of the Software but you must include all of this notice on any copy.
- 
-The Software was developed for research purposes and ACSys does not warrant
-that it is error free or fit for any purpose.  ACSys disclaims any
-liability for all claims, expenses, losses, damages and costs any user may
-incur as a result of using, copying or modifying the Software.
diff --git a/tclxml-3.2/Makefile.in b/tclxml-3.2/Makefile.in
deleted file mode 100755
index 2dadded..0000000
--- a/tclxml-3.2/Makefile.in
+++ /dev/null
@@ -1,530 +0,0 @@
-# Makefile.in --
-#
-#	This file is a Makefile for Tclxml TEA Extension.  If it has the name
-#	"Makefile.in" then it is a template for a Makefile;  to generate the
-#	actual Makefile, run "./configure", which is a configuration script
-#	generated by the "autoconf" program (constructs like "@foo@" will get
-#	replaced in the actual Makefile.
-#
-# Copyright (c) 2007-2008 Explain/Packaged Press.
-# Copyright (c) 2004 Zveno Pty Ltd.
-# Copyright (c) 2002 ActiveState SRL.
-# Copyright (c) 1999 Scriptics Corporation.
-#
-# See the file "license.terms" for information on usage and redistribution
-# of this file, and for a DISCLAIMER OF ALL WARRANTIES.
-#
-# RCS: @(#) $Id: Makefile.in,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-#========================================================================
-# The names of the source files is defined in the configure script.
-# The object files are used for linking into the final library.
-# This will be used when a dist target is added to the Makefile.
-# It is not important to specify the directory, as long as it is the
-# $(srcdir) or in the generic, win or unix subdirectory.
-#========================================================================
-
-PKG_SOURCES	= @PKG_SOURCES@
-PKG_OBJECTS	= @PKG_OBJECTS@ @PKG_STUB_OBJECTS@
-
-PKG_STUB_SOURCES = @PKG_STUB_SOURCES@
-PKG_STUB_OBJECTS = @PKG_STUB_OBJECTS@
-
-#========================================================================
-# PKG_TCL_SOURCES identifies Tcl runtime files that are associated with
-# this package that need to be installed, if any.
-#========================================================================
-
-PKG_TCL_SOURCES = @PKG_TCL_SOURCES@
-
-#========================================================================
-# This is a list of public header files to be installed, if any.
-#========================================================================
-
-PKG_HEADERS     = @PKG_HEADERS@
-
-#========================================================================
-# "PKG_LIB_FILE" refers to the library (dynamic or static as per
-# configuration options) composed of the named objects.
-#========================================================================
-
-PKG_LIB_FILE    = @PKG_LIB_FILE@
-PKG_STUB_LIB_FILE = @PKG_STUB_LIB_FILE@
-
-XML2_VERSION	= @XML2_VERSION@
-XML2_PREFIX	= @XML2_PREFIX@
-XML2_CFLAGS	= @XML2_CFLAGS@
-XML2_LIBS	= @XML2_LIBS@
-
-XSLT_VERSION	= @XSLT_VERSION@
-XSLT_PREFIX	= @XSLT_PREFIX@
-XSLT_LIBS	= @XSLT_LIBS@
-XSLT_CFLAGS	= @XSLT_CFLAGS@
-
-XML_STATIC      = @XML_STATIC@
-FIX_LIB         = @FIX_LIB@
-
-#========================================================================
-# "PKG_LIB_FILE" refers to the library (dynamic or static as per
-# configuration options) composed of the named objects.
-#========================================================================
-
-lib_BINARIES    = $(PKG_LIB_FILE) $(PKG_STUB_LIB_FILE)
-BINARIES        = $(lib_BINARIES)
-
-SHELL		= @SHELL@
-
-srcdir		= @srcdir@
-prefix		= @prefix@
-exec_prefix	= @exec_prefix@
-
-bindir		= @bindir@
-libdir		= @libdir@
-datadir		= @datadir@
-mandir		= @mandir@
-includedir	= @includedir@
-datarootdir     = @datarootdir@
-
-DESTDIR		=
-
-PKG_DIR		= $(PACKAGE_NAME)$(PACKAGE_VERSION)
-pkgdatadir	= $(datadir)/$(PKG_DIR)
-pkglibdir	= $(libdir)/$(PKG_DIR)
-pkgincludedir	= $(includedir)/$(PKG_DIR)
-
-top_builddir	= .
-
-INSTALL		= @INSTALL@
-INSTALL_PROGRAM	= @INSTALL_PROGRAM@
-INSTALL_DATA	= @INSTALL_DATA@
-INSTALL_SCRIPT	= @INSTALL_SCRIPT@
-
-PACKAGE_NAME	= @PACKAGE_NAME@
-PACKAGE_VERSION	= @PACKAGE_VERSION@
-CC		= @CC@
-CFLAGS_DEFAULT  = @CFLAGS_DEFAULT@
-CFLAGS_WARNING  = @CFLAGS_WARNING@
-EXEEXT          = @EXEEXT@
-LDFLAGS_DEFAULT = @LDFLAGS_DEFAULT@
-MAKE_LIB        = @MAKE_LIB@
-MAKE_SHARED_LIB = @MAKE_SHARED_LIB@
-MAKE_STATIC_LIB = @MAKE_STATIC_LIB@
-MAKE_STUB_LIB   = @MAKE_STUB_LIB@
-OBJEXT          = @OBJEXT@
-RANLIB          = @RANLIB@
-RANLIB_STUB     = @RANLIB_STUB@
-SHLIB_CFLAGS    = @SHLIB_CFLAGS@
-SHLIB_LD        = @SHLIB_LD@
-SHLIB_LD_LIBS   = @SHLIB_LD_LIBS@
-STLIB_LD        = @STLIB_LD@
-#TCL_DEFS       = @TCL_DEFS@
-TCL_BIN_DIR     = @TCL_BIN_DIR@
-TCL_SRC_DIR     = @TCL_SRC_DIR@
-#TK_BIN_DIR     = @TK_BIN_DIR@
-#TK_SRC_DIR     = @TK_SRC_DIR@
-
-# Not used, but retained for reference of what libs Tcl required
-#TCL_LIBS       = @TCL_LIBS@
-
-#========================================================================
-# TCLLIBPATH seeds the auto_path in Tcl's init.tcl so we can test our
-# package without installing.  The other environment variables allow us
-# to test against an uninstalled Tcl.  Add special env vars that you
-# require for testing here (like TCLX_LIBRARY).
-#========================================================================
-
-EXTRA_PATH	= $(top_builddir):$(TCL_BIN_DIR)
-#EXTRA_PATH     = $(top_builddir):$(TCL_BIN_DIR):$(TK_BIN_DIR)
-TCLLIBPATH      = $(top_builddir)
-TCLSH_ENV	= TCL_LIBRARY=`@CYGPATH@ $(TCL_SRC_DIR)/library` \
-		  @LD_LIBRARY_PATH_VAR@="$(EXTRA_PATH):$(@LD_LIBRARY_PATH_VAR@)" \
-		  PATH="$(EXTRA_PATH):$(PATH)" \
-		  TCLLIBPATH="$(TCLLIBPATH)"
-#                 TK_LIBRARY=`@CYGPATH@ $(TK_SRC_DIR)/library`
-
-TCLSH_PROG	= @TCLSH_PROG@
-TCLSH		= $(TCLSH_ENV) $(TCLSH_PROG)
-
-SHARED_BUILD	= @SHARED_BUILD@
-
-INCLUDES	= @PKG_INCLUDES@ @TCL_INCLUDES@
-#INCLUDES       = @PKG_INCLUDES@ @TCL_INCLUDES@ @TK_INCLUDES@ @TK_XINCLUDES@
-
-PKG_CFLAGS	= @PKG_CFLAGS@ $(XML2_CFLAGS) $(XSLT_CFLAGS)
-
-# TCL_DEFS is not strictly need here, but if you remove it, then you
-# must make sure that configure.in checks for the necessary components
-# that your library may use.  TCL_DEFS can actually be a problem if
-# you do not compile with a similar machine setup as the Tcl core was
-# compiled with.
-#DEFS           = $(TCL_DEFS) @DEFS@ $(PKG_CFLAGS)
-DEFS		= @DEFS@ $(PKG_CFLAGS)
-
-# Move pkgIndex.tcl to 'BINARIES' var if it is generated in the Makefile
-CONFIG_CLEAN_FILES = Makefile pkgIndex.tcl include/tclxml/tclxml.h
-CLEANFILES	= @CLEANFILES@
-
-CPPFLAGS	= @CPPFLAGS@
-LIBS		= @PKG_LIBS@ @LIBS@ @XML2_LIBS@ @XSLT_LIBS@
-AR		= @AR@
-CFLAGS		= @CFLAGS@
-COMPILE		= $(CC) $(DEFS) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
-
-#========================================================================
-# Start of user-definable TARGETS section
-#========================================================================
-
-#========================================================================
-# TEA TARGETS.  Please note that the "libraries:" target refers to platform
-# independent files, and the "binaries:" target inclues executable programs and
-# platform-dependent libraries.  Modify these targets so that they install
-# the various pieces of your package.  The make and install rules
-# for the BINARIES that you specified above have already been done.
-#========================================================================
-
-# Do not build the documentation by default, since it requires
-# additional dependencies that may not be installed.
-
-all: binaries libraries
-
-#========================================================================
-# The binaries target builds executable programs, Windows .dll's, unix
-# shared/static libraries, and any other platform-dependent files.
-# The list of targets to build for "binaries:" is specified at the top
-# of the Makefile, in the "BINARIES" variable.
-#========================================================================
-
-binaries: $(BINARIES)
-
-libraries:
-
-#========================================================================
-# Your doc target should differentiate from doc builds (by the developer)
-# and doc installs (see install-doc), which just install the docs on the
-# end user machine when building from source.
-#========================================================================
-
-doc:
-	-$(TCLSH) doc/transform.tcl doc/tclxml.xml doc/html.xsl doc/tclxml.html
-	-$(TCLSH) doc/transform.tcl doc/tclxml.xml doc/nroff.xsl doc/tclxml.n
-	-$(TCLSH) doc/transform.tcl doc/tcldom.xml doc/html.xsl doc/tcldom.html
-	-$(TCLSH) doc/transform.tcl doc/tcldom.xml doc/nroff.xsl doc/tcldom.n
-	-$(TCLSH) doc/transform.tcl doc/tclxslt.xml doc/html.xsl doc/tclxslt.html
-	-$(TCLSH) doc/transform.tcl doc/tclxslt.xml doc/nroff.xsl doc/tclxslt.n
-	-$(TCLSH) doc/transform.tcl doc/README.xml doc/html.xsl README.html
-	-$(TCLSH) doc/transform.tcl doc/README.xml doc/txt.xsl -o README
-
-# Do not install the documentation by default,
-# since it may not have been built (see above).
-
-install: all install-binaries install-libraries
-
-install-binaries: binaries install-lib-binaries install-bin-binaries
-	if test "x$(SHARED_BUILD)" = "x1"; then \
-	    $(INSTALL_DATA) pkgIndex.tcl $(DESTDIR)$(pkglibdir); \
-	fi
-
-#========================================================================
-# This rule installs platform-independent files, such as header files.
-# The list=...; for p in $$list handles the empty list case x-platform.
-#========================================================================
-
-install-libraries: libraries
-	@mkdir -p $(DESTDIR)$(includedir)/tclxml
-	@echo "Installing header files in $(DESTDIR)$(includedir)/tclxml"
-	@list='$(PKG_HEADERS)'; for i in $$list; do \
-	    echo "Installing $(srcdir)/$$i" ; \
-	    $(INSTALL_DATA) $(srcdir)/$$i $(DESTDIR)$(includedir)/tclxml ; \
-	done;
-	@echo "libraries done"
-
-#========================================================================
-# Install documentation.  Unix manpages should go in the $(mandir)
-# directory.
-#========================================================================
-
-install-doc: doc
-	@mkdir -p $(DESTDIR)$(mandir)/mann
-	@echo "Installing documentation in $(DESTDIR)$(mandir)"
-	@list='$(srcdir)/doc/*.n'; for i in $$list; do \
-	    echo "Installing $$i"; \
-	    rm -f $(DESTDIR)$(mandir)/mann/`basename $$i`; \
-	    $(INSTALL_DATA) $$i $(DESTDIR)$(mandir)/mann ; \
-	done
-
-testshell	=	$(TCLSH_PROG) $(srcdir)/testshell
-
-#test: binaries libraries
-#	$(TCLSH) `@CYGPATH@ $(srcdir)/tests/all.tcl` $(TESTFLAGS)
-#	$(testshell)	\
-#		-load 'load ./$(Tclxml_LIB_FILE)' \
-#		-testdir $(srcdir)/tea.tests
-
-test: test-tclxml test-tcldom test-tclxslt
-
-test-tclxml:
-	(cd $(srcdir)/tests/tclxml; $(TCLSH) all.tcl)
-
-test-tcldom:
-	(cd $(srcdir)/tests/tcldom; $(TCLSH) all.tcl)
-
-test-tclxslt:
-	(cd $(srcdir)/tests/tclxslt; $(TCLSH) all.tcl)
-
-shell: binaries libraries
-	@$(TCLSH) $(SCRIPT)
-
-gdb:
-	$(TCLSH_ENV) gdb $(TCLSH_PROG) $(SCRIPT)
-
-depend:
-
-#========================================================================
-# $(PKG_LIB_FILE) should be listed as part of the BINARIES variable
-# mentioned above.  That will ensure that this target is built when you
-# run "make binaries".
-#
-# The $(PKG_OBJECTS) objects are created and linked into the final
-# library.  In most cases these object files will correspond to the
-# source files above.
-#========================================================================
-
-$(PKG_LIB_FILE): $(PKG_OBJECTS)
-	-rm -f $(PKG_LIB_FILE)
-	${MAKE_LIB}
-	$(RANLIB) $(PKG_LIB_FILE)
-	$(FIX_LIB) $(PKG_LIB_FILE)
-
-$(PKG_STUB_LIB_FILE): $(PKG_STUB_OBJECTS)
-	-rm -f $(PKG_STUB_LIB_FILE)
-	${MAKE_STUB_LIB}
-	$(RANLIB_STUB) $(PKG_STUB_LIB_FILE)
-
-#========================================================================
-# We need to enumerate the list of .c to .o lines here.
-#
-# In the following lines, $(srcdir) refers to the toplevel directory
-# containing your extension.  If your sources are in a subdirectory,
-# you will have to modify the paths to reflect this:
-#
-# Tclxml.$(OBJEXT): $(srcdir)/generic/Tclxml.c
-# 	$(COMPILE) -c `@CYGPATH@ $(srcdir)/generic/Tclxml.c` -o $@
-#
-# Setting the VPATH variable to a list of paths will cause the makefile
-# to look into these paths when resolving .c to .obj dependencies.
-# As necessary, add $(srcdir):$(srcdir)/compat:....
-#========================================================================
-
-VPATH = $(srcdir):$(srcdir)/generic:$(srcdir)/unix:$(srcdir)/win
-
-.c. at OBJEXT@:
-	$(COMPILE) -c `@CYGPATH@ $<` -o $@
-
-#========================================================================
-# Distribution creation
-# You may need to tweak this target to make it work correctly.
-#========================================================================
-
-#COMPRESS	= tar cvf $(PKG_DIR).tar $(PKG_DIR); compress $(PKG_DIR).tar
-COMPRESS	= gtar zcvf $(PKG_DIR).tar.gz $(PKG_DIR)
-DIST_ROOT	= /tmp/dist
-DIST_DIR	= $(DIST_ROOT)/$(PKG_DIR)
-
-dist-clean:
-	rm -rf $(DIST_DIR) $(DIST_ROOT)/$(PKG_DIR).tar.*
-
-dist: dist-clean doc
-	mkdir -p $(DIST_DIR)
-	cp -p $(srcdir)/ChangeLog $(srcdir)/README* $(srcdir)/doc/license* \
-		$(srcdir)/aclocal.m4 $(srcdir)/configure $(srcdir)/*.in \
-		$(DIST_DIR)/
-	chmod 664 $(DIST_DIR)/Makefile.in $(DIST_DIR)/aclocal.m4
-	chmod 775 $(DIST_DIR)/configure $(DIST_DIR)/configure.in
-
-	for i in $(srcdir)/*.[ch]; do \
-	    if [ -f $$i ]; then \
-	        cp -p $$i $(DIST_DIR)/ ; \
-	    fi; \
-	done;
-
-	mkdir $(DIST_DIR)/tclconfig
-	cp $(srcdir)/tclconfig/install-sh $(srcdir)/tclconfig/tcl.m4 \
-		$(DIST_DIR)/tclconfig/
-	chmod 664 $(DIST_DIR)/tclconfig/tcl.m4
-	chmod +x $(DIST_DIR)/tclconfig/install-sh
-
-	-list='htdocs/art demos generic library mac tests unix win tea.tests tools tools/rules'; \
-	for p in $$list; do \
-	    if test -d $(srcdir)/$$p ; then \
-		mkdir -p $(DIST_DIR)/$$p; \
-		cp -p $(srcdir)/$$p/*.* $(srcdir)/$$p/* $(DIST_DIR)/$$p/; \
-	    fi; \
-	done
-
-	-list='doc'; \
-	for p in $$list; do \
-	    if test -d $$p ; then \
-		mkdir -p $(DIST_DIR)/$$p; \
-		cp -p $$p/*.* $$p/* $(DIST_DIR)/$$p/; \
-	    fi; \
-	done
-	-mv $(DIST_DIR)/htdocs/art $(DIST_DIR)/doc/art
-	rm -rf $(DIST_DIR)/htdocs
-
-	(cd $(DIST_ROOT); $(COMPRESS);)
-
-dist_orig:
-	rm -rf $(PKG_DIR)*
-	ls -d $(srcdir)/* > __FILES
-	mkdir $(PKG_DIR)
-	cp -rf `cat __FILES | grep -v __FILES` $(PKG_DIR)
-	rm __FILES
-	find $(PKG_DIR) -name CVS -prune -exec rm -rf {} \;
-	cd $(PKG_DIR) ; $(TCLSH_PROG) PREPARE
-	-tar cf - $(PKG_DIR) | gzip --best > $(PKG_DIR).tar.gz
-	-tar cf - $(PKG_DIR) | bzip2 > $(PKG_DIR).tar.bz2
-	-zip -r $(PKG_DIR).zip $(PKG_DIR)
-	rm -rf $(PKG_DIR)
-
-release:
-	autoconf
-
-#========================================================================
-# End of user-definable section
-#========================================================================
-
-#========================================================================
-# Don't modify the file to clean here.  Instead, set the "CLEANFILES"
-# variable in configure.in
-#========================================================================
-
-clean:  
-	-test -z "$(BINARIES)" || rm -f $(BINARIES)
-	-rm -f *.$(OBJEXT) core *.core
-	-test -z "$(CLEANFILES)" || rm -f $(CLEANFILES)
-
-distclean: clean
-	-rm -f *.tab.c
-	-rm -f $(CONFIG_CLEAN_FILES)
-	-rm -f config.cache config.log config.status
-
-#========================================================================
-# Install binary object libraries.  On Windows this includes both .dll and
-# .lib files.  Because the .lib files are not explicitly listed anywhere,
-# we need to deduce their existence from the .dll file of the same name.
-# Library files go into the lib directory.
-# In addition, this will generate the pkgIndex.tcl
-# file in the install location (assuming it can find a usable tclsh shell)
-#
-# You should not have to modify this target.
-#========================================================================
-
-install-lib-binaries:
-	@mkdir -p $(DESTDIR)$(pkglibdir)
-	@list='$(lib_BINARIES)'; for p in $$list; do \
-	  if test -f $$p; then \
-	    echo " $(INSTALL_PROGRAM) $$p $(DESTDIR)$(pkglibdir)/$$p"; \
-	    $(INSTALL_PROGRAM) $$p $(DESTDIR)$(pkglibdir)/$$p; \
-	    stub=`echo $$p|sed -e "s/.*\(stub\).*/\1/"`; \
-	    if test "x$$stub" = "xstub"; then \
-	    echo " $(RANLIB_STUB) $(DESTDIR)$(pkglibdir)/$$p"; \
-	    $(RANLIB_STUB) $(DESTDIR)$(pkglibdir)/$$p; \
-	    else \
-	    echo " $(RANLIB) $(DESTDIR)$(pkglibdir)/$$p"; \
-	    $(RANLIB) $(DESTDIR)$(pkglibdir)/$$p; \
-	    fi; \
-	    ext=`echo $$p|sed -e "s/.*\.//"`; \
-	    if test "x$$ext" = "xdll"; then \
-		lib=`basename $$p|sed -e 's/.[^.]*$$//'`.lib; \
-		if test -f $$lib; then \
-		    echo " $(INSTALL_DATA) $$lib $(DESTDIR)$(pkglibdir)/$$lib"; \
-	            $(INSTALL_DATA) $$lib $(DESTDIR)$(pkglibdir)/$$lib; \
-		fi; \
-	    fi; \
-	  fi; \
-	done
-	@list='$(PKG_TCL_SOURCES)'; for p in $$list; do \
-	  if test -f $(srcdir)/$$p; then \
-	    s=`basename $$p`; \
-	    echo " Install $$p $(DESTDIR)$(pkglibdir)/$$s"; \
-	    $(INSTALL_DATA) $(srcdir)/$$p $(DESTDIR)$(pkglibdir)/$$s; \
-	  fi; \
-	done
-	$(INSTALL_DATA) TclxmlConfig.sh $(DESTDIR)$(libdir)
-	$(FIX_LIB) $(DESTDIR)$(pkglibdir)/$(PKG_LIB_FILE)
-
-#========================================================================
-# Install binary executables (e.g. .exe files and dependent .dll files)
-# This is for files that must go in the bin directory (located next to
-# wish and tclsh), like dependent .dll files on Windows.
-#
-# You should not have to modify this target, except to define bin_BINARIES
-# above if necessary.
-#========================================================================
-
-install-bin-binaries:
-	@mkdir -p $(DESTDIR)$(bindir)
-	@list='$(bin_BINARIES)'; for p in $$list; do \
-	  if test -f $$p; then \
-	    echo " $(INSTALL_PROGRAM) $$p $(DESTDIR)$(bindir)/$$p"; \
-	    $(INSTALL_PROGRAM) $$p $(DESTDIR)$(bindir)/$$p; \
-	  fi; \
-	done
-
-.SUFFIXES: .c .$(OBJEXT)
-
-Makefile: $(srcdir)/Makefile.in  $(top_builddir)/config.status
-	cd $(top_builddir) \
-	  && CONFIG_FILES=$@ CONFIG_HEADERS= $(SHELL) ./config.status
-
-uninstall-binaries:
-	list='$(lib_BINARIES)'; for p in $$list; do \
-	  rm -f $(DESTDIR)$(pkglibdir)/$$p; \
-	done
-	list='$(PKG_TCL_SOURCES)'; for p in $$list; do \
-	  p=`basenme $$p`; \
-	  rm -f $(DESTDIR)$(pkglibdir)/$$p; \
-	done
-	list='$(bin_BINARIES)'; for p in $$list; do \
-	  rm -f $(DESTDIR)$(bindir)/$$p; \
-	done
-
-#========================================================================
-#
-# Target to regenerate header files and stub files from the *.decls tables.
-#
-#========================================================================
-
-genstubs:
-	$(TCLSH_PROG)	\
-		$(srcdir)/tools/genStubs.tcl $(srcdir)	\
-		$(srcdir)/tclxml.decls
-
-#========================================================================
-#
-# Target to check that all exported functions have an entry in the stubs
-# tables.
-#
-#========================================================================
-
-Tclxml_DECLS = \
-	$(srcdir)/tclxml.decls
-
-checkstubs:
-	- at for i in `nm -p $(Tclxml_LIB_FILE) | awk '$$2 ~ /T/ { print $$3 }' \
-		| sort -n`; do \
-		match=0; \
-		for j in $(Tclxml_DECLS); do \
-		    if [ `grep -c $$i $$j` -gt 0 ]; then \
-			match=1; \
-		    fi; \
-		done; \
-		if [ $$match -eq 0 ]; then echo $$i; fi \
-	done
-
-
-.PHONY: all binaries clean depend distclean doc install libraries test
-
-# Tell versions [3.59,3.63) of GNU make to not export all variables.
-# Otherwise a system limit (for SysV at least) may be exceeded.
-.NOEXPORT:
diff --git a/tclxml-3.2/Makefile.macosx b/tclxml-3.2/Makefile.macosx
deleted file mode 100644
index f52b386..0000000
--- a/tclxml-3.2/Makefile.macosx
+++ /dev/null
@@ -1,21 +0,0 @@
-########################
-#
-# Makefile to build TclXML/libxml2 for macosx.
-#
-# Usage:
-#	cd tclxml-3.X
-#	make -f Makefile.macosx
-#
-# $Id: Makefile.macosx,v 1.3 2009/12/28 19:25:40 joye Exp $
-#
-########################
-
-PACKAGE_VERSION	:= 3.2
-
-LIBXML2_VERSION	:= $(shell eval echo $$(ls -dt ../libxml2* | head -1 | sed -e '1s/.*\-//'))
-
-all:	build
-
-build:
-	cd macosx; xcodebuild -project tclxml.pbproj -target Make -buildstyle Deployment FRAMEWORK_VERSION=${PACKAGE_VERSION} LIBXML2_VERSION=${LIBXML2_VERSION}
-
diff --git a/tclxml-3.2/Makefile.macosx.in b/tclxml-3.2/Makefile.macosx.in
deleted file mode 100644
index dcd5c3b..0000000
--- a/tclxml-3.2/Makefile.macosx.in
+++ /dev/null
@@ -1,21 +0,0 @@
-########################
-#
-# Makefile to build TclXML/libxml2 for macosx.
-#
-# Usage:
-#	cd tclxml-3.X
-#	make -f Makefile.macosx
-#
-# $Id: Makefile.macosx.in,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-#
-########################
-
-PACKAGE_VERSION	:= @PACKAGE_VERSION@
-
-LIBXML2_VERSION	:= $(shell eval echo $$(ls -dt ../libxml2* | head -1 | sed -e '1s/.*\-//'))
-
-all:	build
-
-build:
-	cd macosx; xcodebuild -project tclxml.pbproj -target Make -buildstyle Deployment FRAMEWORK_VERSION=${PACKAGE_VERSION} LIBXML2_VERSION=${LIBXML2_VERSION}
-
diff --git a/tclxml-3.2/README.html b/tclxml-3.2/README.html
deleted file mode 100644
index a745a13..0000000
--- a/tclxml-3.2/README.html
+++ /dev/null
@@ -1,280 +0,0 @@
-<html>
-<head>
-<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
-<title>XML Support For Tcl</title>
-<link rel="stylesheet" href="tclxml.css">
-</head>
-<body><div class="article">
-<h1 class="title"><a name="id18406">XML Support For Tcl</a></h1>
-<h3>TclXML, TclDOM and TclXSLT</h3>
-<h2>Contents</h2>
-<ul>
-<li><a href="#id18498">TclXML</a></li>
-<li><a href="#id18546">TclDOM</a></li>
-<li><a href="#id18594">TclXSLT</a></li>
-<li>
-<a href="#id18619">Installation</a><ul>
-<li><a href="#id18633">Dependencies</a></li>
-<li><a href="#id18747">Pure-Tcl Installation</a></li>
-<li>
-<a href="#id18776">Compiled Installation</a><ul>
-<li><a href="#id18786">Unix/Linux</a></li>
-<li><a href="#id18948">Windows (MSYS/MINGW)</a></li>
-<li><a href="#id18987">Windows (NMAKE/VC++ 6.0)</a></li>
-<li><a href="#id19109">Macintosh OS X</a></li>
-</ul>
-</li>
-</ul>
-</li>
-<li>
-<a href="#id19193">Usage</a><ul>
-<li><a href="#id19216">Parsing XML, Streaming</a></li>
-<li><a href="#id19244">Parsing XML with DOM</a></li>
-<li><a href="#id19268">Transforming XML with XSLT</a></li>
-</ul>
-</li>
-<li><a href="#id19306">XPath</a></li>
-</ul>
-<h3>TclXML, TclDOM and TclXSLT</h3>
-<p>This package provides XML parsers, DOM scripting and XSL Transformations for <a href="http://www.tcl.tk">Tcl</a>. In previous distributions, these features were supplied as separate packages. Now they have been combined into a single package to make installation easier.</p>
-<p>Contact <a href="mailto:Steve.Ball at explain.com.au">Steve Ball</a> for information about this release.</p>
-<div class="section">
-<h3>
-<a name="id18498"></a>TclXML</h3>
-<p>TclXML provides a streaming parser for XML documents. This is the lowest-level interface for processing XML documents in Tcl. The package has a generic front-end interface with plugin parser implementations.  A number of parser implementations or wrappers are provided:</p>
-<ul>
-<li><p>Gnome libxml2 library.  This package is known as TclXML/libxml2.</p></li>
-<li><p>A generic Tcl implementation (which does not require compilation).  This package is known as TclXML/tcl.</p></li>
-</ul>
-<p>Both of these implementations may be installed at the same time. See <a href="doc/tclxml.html">the manual page</a> for more information.</p>
-</div>
-<div class="section">
-<h3>
-<a name="id18546"></a>TclDOM</h3>
-<p>TclDOM provides a tree view for XML documents. This is usually the best interface for scripting XML documents using Tcl. The package has two implementations:</p>
-<ul>
-<li><p>Gnome libxml2 library.  This package is known as TclDOM/libxml2.</p></li>
-<li><p>A generic Tcl implementation (which does not require compilation).  This package is known as TclDOM/tcl.</p></li>
-</ul>
-<p>Only one of these will be installed.</p>
-<p>See <a href="doc/tcldom.html">the manual page</a> for more information.</p>
-</div>
-<div class="section">
-<h3>
-<a name="id18594"></a>TclXSLT</h3>
-<p>TclXSLT provides a method to invoke XSL Transformations upon XML documents. This package is a wrapper for the libxslt library.</p>
-<p>See <a href="doc/tclxslt.html">the manual page</a> for more information.</p>
-</div>
-<div class="section">
-<h3>
-<a name="id18619"></a>Installation</h3>
-<div class="section">
-<h4>
-<a name="id18633"></a>Dependencies</h4>
-<dl>
-<span class="term">Tcllib</span><dd>
-<p><a href="http://www.tcl.tk/software/tcllib/">http://www.tcl.tk/software/tcllib/</a></p>
-<p>In order for the Tcl-only parser to resolve external entities, the tcllib package must be installed.</p>
-<p>Be sure to get a version which includes the <tt>uri</tt> package.  Version 1.11 or better is recommended.</p>
-<ul>
-<li><p><a href="ftp://prdownloads.sf.net/tcllib/tcllib-1.11.tar.gz">GZip'd tarball</a></p></li>
-<li><p><a href="ftp://prdownloads.sf.net/tcllib/tcllib-1.11.zip">ZIP file</a></p></li>
-</ul>
-<p>The latest CVS snapshot may be found at <a href="http://sourceforge.net/projects/tcllib">the SourceForge project page</a>.</p>
-</dd>
-<span class="term">libxml2</span><dd>
-<p>libxml2 is required for the compiled version of the TclXML/libxml2 package.  libiconv may also be required.</p>
-<p>The source code for libxml2 and libiconv is <em>not</em> supplied with this package.  Download libxml2 from <a href="http://xmlsoft.org/">xmlsoft.org</a> separately. libiconv may also be required; download from a GNU mirror site.</p>
-<p>Version 2.7.2 (or better) is recommended.</p>
-</dd>
-</dl>
-</div>
-<div class="section">
-<h4>
-<a name="id18747"></a>Pure-Tcl Installation</h4>
-<h3>no compilation required</h3>
-<p>Run the configure script and invoke the command:</p>
-<div class="informalexample"><pre><strong>make install</strong></pre></div>
-<p>If the pure-Tcl parser is good enough for you, then read no further.</p>
-</div>
-<div class="section">
-<h4>
-<a name="id18776"></a>Compiled Installation</h4>
-<div class="section">
-<h5>
-<a name="id18786"></a>Unix/Linux</h5>
-<p>You must have Tcl/Tk version 8.2 or better installed on your system.  Tcl/Tk 8.3 or better is recommended.</p>
-<ol>
-<li><p>Make sure you have Tcllib 1.11 (or better) installed.  Tcllib is still required, even for the compiled parser.</p></li>
-<li><p>If you wish to use TclXML/libxml2, make sure libxml2-2.7.2 (or better) is installed.</p></li>
-<li><p>Unpack the TclXML distribution and <strong>cd</strong> into the <tt>tclxml-3.2</tt> directory.</p></li>
-<li>
-<p>Run the <tt>configure</tt> script, with the <span class="arg">--prefix</span> and  <span class="arg">--enable-threads</span> switches (the latter only if Tcl has been built with threads enabled). Use the  <span class="arg">--with-xml2-config</span> switch to specify the location of the libxml2 configuration script, <tt>xml2Conf.sh</tt>. Similarly, use the  <span class="arg">--with-xslt-config</span> if necessary.</p>
-<p>TclXML/libxml2 may be configured to statically link the libxml2 and libxslt libraries to the libtclxml.so shared library. This is advantageous when using TclXML/libxml2 in a StarKit. To statically link the libraries use the <span class="arg">--with-xml-static</span> switch.</p>
-<p>For example, on my system I have Tcl 8.5 installed in <tt>/usr/local/tcl8.5</tt> and libxm2 installed in <tt>/usr/local/gnome</tt>. I also need to statically link the libraries. Therefore I would use the command:</p>
-<div class="programlisting"><pre>./configure --prefix=/usr/local/tcl8.5 --enable-threads --with-xml2-config=/usr/local/gnome/bin/xml2Conf.sh --with-xml-static=1</pre></div>
-</li>
-<li><div class="programlisting"><pre>make</pre></div></li>
-<li><div class="note">Don't test the package using <span class="literal">make test</span> until all of the packages are installed (it is a current deficiency of the build system that the package cannot be tested before installation - we hope to fix this soon!).</div></li>
-<li>
-<div class="programlisting"><pre>make install</pre></div>
-<p>You may need to do this as root, depending on your installation.</p>
-</li>
-<li><div class="programlisting"><pre>make test</pre></div></li>
-<li><div class="programlisting"><pre>make doc</pre></div></li>
-<li><div class="programlisting"><pre>make install-doc</pre></div></li>
-</ol>
-</div>
-<div class="section">
-<h5>
-<a name="id18948"></a>Windows (MSYS/MINGW)</h5>
-<div class="note">[Advice:  ActiveTcl includes binaries for TclXML.]</div>
-<p>You must have Tcl/Tk version 8.2 or better installed on your system.  Tcl/Tk 8.5.5 or better is recommended.</p>
-<p>Before starting, download the binaries for libxml2 (or build them from source).  <a href="http://xmlsoft.org/">xmlsoft</a> has a link to the MS Windows binary distribution.</p>
-<p>If you have a TEA build environment setup, just use the normal <span class="literal">configure/make/make install</span> pattern.</p>
-</div>
-<div class="section">
-<h5>
-<a name="id18987"></a>Windows (NMAKE/VC++ 6.0)</h5>
-<div class="note">TclXML/libxml2 is built with MSYS/MINGW, see above, so this build system is untested.</div>
-<p>Alternatively, the <tt>win</tt> subdirectory contains a <tt>makefile.vc</tt> file for Visual Studio C++ v6.0.  In a Command Prompt window set up your environment so that <tt>nmake</tt> is on the path (by running <tt>VCVARS32.BAT</tt>), then type the following:</p>
-<div class="informalexample"><pre><div class="programlisting"><pre>nmake -f makefile.vc TCLDIR=<em>C:\Path\To\Tcl</em> INSTALLDIR=<em>C:\Path\To\Tcl</em> LIBZDIR=<em>C:\Path\To\libz</em> LIBICONVDIR=<em>C:\Path\To\libiconv</em> LIBXML2DIR=<em>C:\Path\To\libxml2</em> LIBXSLTDIR=<em>C:\Path\To\libxslt</em></pre></div></pre></div>
-<p>As an example, on my system I have Tcl installed in <tt>C:\Tcl</tt> and the libxml2 and libxslt binaries unpacked in the directory <tt>C:\gnome</tt>.  Accordingly, I would use the following command line:</p>
-<div class="informalexample"><pre><div class="programlisting"><pre>nmake -f makefile.vc TCLDIR=C:\Tcl INSTALLDIR=C:\Tcl LIBZDIR=C:\gnome\zlib-1.1.4.win32 LIBICONVDIR=C:\gnome\libiconv-1.9.1.win32 LIBXML2DIR=C:\gnome\libxml2-2.7.2.win32 LIBXSLTDIR=C:\gnome\libxslt-1.1.24.win32</pre></div></pre></div>
-<p>Install the package by appending 'install' to the command line used above, for example:</p>
-<div class="informalexample"><pre><div class="programlisting"><pre>nmake -f makefile.vc TCLDIR=<em>C:\Path\To\Tcl</em> INSTALLDIR=<em>C:\Path\To\Tcl</em> LIBZDIR=<em>C:\Path\To\libz</em> LIBICONVDIR=<em>C:\Path\To\libiconv</em> LIBXML2DIR=<em>C:\Path\To\libxml2</em> LIBXSLTDIR=<em>C:\Path\To\libxslt</em> install</pre></div></pre></div>
-</div>
-<div class="section">
-<h5>
-<a name="id19109"></a>Macintosh OS X</h5>
-<div class="note">Binary distributions of libxml2, libxslt and TclXML as frameworks are provided by <a href="http://www.explain.com.au/oss/">Explain</a>.</div>
-<p>There are two ways to build TclXML under Mac OS X:</p>
-<ol>
-<li><p>The usual Unix way, see above.</p></li>
-<li><p>As an embedded Framework using Xcode.</p></li>
-</ol>
-<p>The <tt>macosx</tt> directory contains the Xcode files for building under OS X (Leopard/Panther).  TclXML/libxml2 has been tested on OS X 10.5 (or is that X.5?).</p>
-<p>Start-up the project.  Make sure that the references to the libxml2 and Tcl external frameworks are correct.  Select the 'Make' target and build.  This builds everything.  The result is two Mac OS X Frameworks; a "normal" and an "embedded".  The embedded framework will be in the <tt>embedded</tt> subdirectory of the Build Products directory.  Copy <tt>tclxml.framework</tt> to any of the usual places for frameworks (<tt>~/Library/Frameworks</tt>, <tt>/Library/Frameworks</tt>, etc).</p>
-<p>For earlier version of OS X using Project Builder, you will have to retrieve a previous version of the Project Builder files from the CVS repository.</p>
-</div>
-</div>
-</div>
-<div class="section">
-<h3>
-<a name="id19193"></a>Usage</h3>
-<p>See <a href="http://tclxml.sourceforge.net/">the website</a> for links to tutorials and the reference manual.</p>
-<p>In the meantime, here's a quick tutorial:</p>
-<div class="section">
-<h4>
-<a name="id19216"></a>Parsing XML, Streaming</h4>
-<p>This is the lowest-level access to an XML document; use SAX-like events to stream through the document. The simple program below counts the number of characters in the content of an XML document.</p>
-<div class="programlisting"><pre>
-package require xml 3.2
-
-set parser [xml::parser]
-$parser configure -elementstartcommand EStart \
-    -characterdatacommand PCData
-
-proc EStart {tag attlist args} {
-    array set attr $attlist
-    puts "Element \"$tag\" started with [array size attr] attributes"
-}
-
-proc PCData text {
-    incr ::count [string length $text]
-}
-
-set count 0
-$parser parse [read stdin]
-
-puts "The document contains $count characters"
-exit 0
-</pre></div>
-</div>
-<div class="section">
-<h4>
-<a name="id19244"></a>Parsing XML with DOM</h4>
-<p>This is the next level up in accessing an XML document; use the Document Object Model (DOM) to view the XML document as a tree. The simple program below counts the number of characters in the content of an XML document.</p>
-<div class="programlisting"><pre>
-package require xml 3.2
-
-set doc [dom::parse [read stdin]]
-set count 0
-foreach textNode [dom::selectNode $doc //text()] {
-    incr count [string length [$textNode cget -nodeValue]]
-}
-
-puts "The document contains $count characters"
-      </pre></div>
-</div>
-<div class="section">
-<h4>
-<a name="id19268"></a>Transforming XML with XSLT</h4>
-<p>This is the highest level in processing an XML document; use a XSL stylesheet to transform a XML document. The simple program below reads two XML documents, compiles one into a XSL stylesheet and performs the transformation.</p>
-<div class="programlisting"><pre>
-package require xml 3.2
-
-set chan [open "count.xsl"]
-set styleDoc [dom::parse [read $chan]]
-close $chan
-set sourceDoc [dom::parse [read stdin]]
-
-set style [xslt::compile $styleDoc]
-set resultDoc [$style transform $sourceDoc]
-
-puts [dom::serialize $resultDoc]
-      </pre></div>
-<p>The XSL stylesheet <tt>count.xsl</tt>, which counts the number of characters in the source document, looks like this:</p>
-<div class="programlisting"><pre>
-<xsl:stylesheet version='1.0'
-  xmlns:xsl='http://www.w3.org/1999/XSL/Transform'>
-
-  <xsl:template match='/'>
-    <xsl:text>The document contains </xsl:text>
-    <xsl:call-template name='add'>
-      <xsl:with-param name='nodes' select='//text()'/>
-    </xsl:call-template>
-    <xsl:text> characters.
-</xsl:text>
-  </xsl:template>
-
-  <xsl:template name='add'>
-    <xsl:param name='sum' select='0'/>
-    <xsl:param name='nodes' select='/..'/>
-
-    <xsl:choose>
-      <xsl:when test='not($nodes)'>
-        <xsl:value-of select='$sum'/>
-      </xsl:when>
-      <xsl:otherwise>
-        <xsl:call-template name='add'>
-          <xsl:with-param name='sum'
-            select='$sum + string-length($nodes[1])'/>
-          <xsl:with-param name='nodes'
-            select='$nodes[position() != 1]'/>
-        </xsl:call-template>
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:template>
-</xsl:stylesheet>
-</pre></div>
-</div>
-</div>
-<div class="section">
-<h3>
-<a name="id19306"></a>XPath</h3>
-<p>In addition to XML parsing packages, TclXML also provides a package for parsing XPath location paths.  The XPath package only parsing the path's syntax, it does interpret the path.  See <a href="http://tclxml.sourceforge.net/tcldom.html">TclDOM</a> for a package that will interpret XPath location paths.</p>
-<div class="note">This package is in its infancy, and does not support the full range of XPath features.  Only a very limited subset of location paths are supported, of the form "/simple/example[2]".  Paths within predicates will definitely fail.</div>
-<p>To use the XPath package:</p>
-<div class="programlisting"><pre>
-package require xpath
-</pre></div>
-<p>To parse a location path:</p>
-<div class="programlisting"><pre>
-xpath::split {/simple/example}
-</pre></div>
-<p>This returns a Tcl list, each element of which is a three element sublist: {axis node-test {?predicate ...?}}.</p>
-</div>
-</div></body>
-</html>
-
diff --git a/tclxml-3.2/TclxmlConfig.sh b/tclxml-3.2/TclxmlConfig.sh
deleted file mode 100644
index 99bf826..0000000
--- a/tclxml-3.2/TclxmlConfig.sh
+++ /dev/null
@@ -1,56 +0,0 @@
-# tclxmlConfig.sh --
-# 
-# This shell script (for sh) is generated automatically by Tclxml's
-# configure script.  It will create shell variables for most of
-# the configuration options discovered by the configure script.
-# This script is intended to be included by the configure scripts
-# for Tclxml extensions so that they don't have to figure this all
-# out for themselves.  This file does not duplicate information
-# already provided by tclConfig.sh, so you may need to use that
-# file in addition to this one.
-#
-# The information in this file is specific to a single platform.
-
-# Tclxml's version number.
-Tclxml_VERSION='3.2'
-
-# The name of the Tclxml library (may be either a .a file or a shared library):
-Tclxml_LIB_FILE='libTclxml3.2.dylib'
-
-# String to pass to linker to pick up the Tclxml library from its
-# build directory.
-Tclxml_BUILD_LIB_SPEC='-L/Users/steve/Projects/tclxml-3.2 -lTclxml3.2'
-
-# String to pass to linker to pick up the Tclxml library from its
-# installed directory.
-Tclxml_LIB_SPEC='-L/usr/local/lib/Tclxml3.2 -lTclxml3.2'
-
-# The name of the Tclxml stub library (a .a file):
-Tclxml_STUB_LIB_FILE='libTclxmlstub3.2.a'
-
-# String to pass to linker to pick up the Tclxml stub library from its
-# build directory.
-Tclxml_BUILD_STUB_LIB_SPEC='-L/Users/steve/Projects/tclxml-3.2 -lTclxmlstub3.2'
-
-# String to pass to linker to pick up the Tclxml stub library from its
-# installed directory.
-Tclxml_STUB_LIB_SPEC='-L/usr/local/lib/Tclxml3.2 -lTclxmlstub3.2'
-
-# String to pass to linker to pick up the Tclxml stub library from its
-# build directory.
-Tclxml_BUILD_STUB_LIB_PATH='/Users/steve/Projects/tclxml-3.2/'
-
-# String to pass to linker to pick up the Tclxml stub library from its
-# installed directory.
-Tclxml_STUB_LIB_PATH='/usr/local/lib/Tclxml3.2/'
-
-# String to pass to the compiler so that an extension can find
-# installed header.
-Tclxml_INCLUDE_SPEC='-I/usr/local/include'
-
-# Location of the top-level source directories from which [incr Tcl]
-# was built.  This is the directory that contains generic, unix, etc.
-# If [incr Tcl] was compiled in a different place than the directory
-# containing the source files, this points to the location of the sources,
-# not the location where [incr Tcl] was compiled.
-Tclxml_SRC_DIR='.'
diff --git a/tclxml-3.2/TclxmlConfig.sh.in b/tclxml-3.2/TclxmlConfig.sh.in
deleted file mode 100644
index 2e0b09c..0000000
--- a/tclxml-3.2/TclxmlConfig.sh.in
+++ /dev/null
@@ -1,56 +0,0 @@
-# tclxmlConfig.sh --
-# 
-# This shell script (for sh) is generated automatically by Tclxml's
-# configure script.  It will create shell variables for most of
-# the configuration options discovered by the configure script.
-# This script is intended to be included by the configure scripts
-# for Tclxml extensions so that they don't have to figure this all
-# out for themselves.  This file does not duplicate information
-# already provided by tclConfig.sh, so you may need to use that
-# file in addition to this one.
-#
-# The information in this file is specific to a single platform.
-
-# Tclxml's version number.
-Tclxml_VERSION='@PACKAGE_VERSION@'
-
-# The name of the Tclxml library (may be either a .a file or a shared library):
-Tclxml_LIB_FILE='@PKG_LIB_FILE@'
-
-# String to pass to linker to pick up the Tclxml library from its
-# build directory.
-Tclxml_BUILD_LIB_SPEC='@Tclxml_BUILD_LIB_SPEC@'
-
-# String to pass to linker to pick up the Tclxml library from its
-# installed directory.
-Tclxml_LIB_SPEC='@Tclxml_LIB_SPEC@'
-
-# The name of the Tclxml stub library (a .a file):
-Tclxml_STUB_LIB_FILE='@PKG_STUB_LIB_FILE@'
-
-# String to pass to linker to pick up the Tclxml stub library from its
-# build directory.
-Tclxml_BUILD_STUB_LIB_SPEC='@Tclxml_BUILD_STUB_LIB_SPEC@'
-
-# String to pass to linker to pick up the Tclxml stub library from its
-# installed directory.
-Tclxml_STUB_LIB_SPEC='@Tclxml_STUB_LIB_SPEC@'
-
-# String to pass to linker to pick up the Tclxml stub library from its
-# build directory.
-Tclxml_BUILD_STUB_LIB_PATH='@Tclxml_BUILD_STUB_LIB_PATH@'
-
-# String to pass to linker to pick up the Tclxml stub library from its
-# installed directory.
-Tclxml_STUB_LIB_PATH='@Tclxml_STUB_LIB_PATH@'
-
-# String to pass to the compiler so that an extension can find
-# installed header.
-Tclxml_INCLUDE_SPEC='@Tclxml_INCLUDE_SPEC@'
-
-# Location of the top-level source directories from which [incr Tcl]
-# was built.  This is the directory that contains generic, unix, etc.
-# If [incr Tcl] was compiled in a different place than the directory
-# containing the source files, this points to the location of the sources,
-# not the location where [incr Tcl] was compiled.
-Tclxml_SRC_DIR='@srcdir@'
diff --git a/tclxml-3.2/aclocal.m4 b/tclxml-3.2/aclocal.m4
deleted file mode 100755
index 0b05739..0000000
--- a/tclxml-3.2/aclocal.m4
+++ /dev/null
@@ -1,9 +0,0 @@
-#
-# Include the TEA standard macro set
-#
-
-builtin(include,tclconfig/tcl.m4)
-
-#
-# Add here whatever m4 macros you want to define for your package
-#
diff --git a/tclxml-3.2/autom4te.cache/output.0 b/tclxml-3.2/autom4te.cache/output.0
deleted file mode 100644
index 740d83e..0000000
--- a/tclxml-3.2/autom4te.cache/output.0
+++ /dev/null
@@ -1,11564 +0,0 @@
-@%:@! /bin/sh
-@%:@ Guess values for system-dependent variables and create Makefiles.
-@%:@ Generated by GNU Autoconf 2.61 for Tclxml 3.2.
-@%:@ 
-@%:@ Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
-@%:@ 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
-@%:@ This configure script is free software; the Free Software Foundation
-@%:@ gives unlimited permission to copy, distribute and modify it.
-## --------------------- ##
-## M4sh Initialization.  ##
-## --------------------- ##
-
-# Be more Bourne compatible
-DUALCASE=1; export DUALCASE # for MKS sh
-if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
-  emulate sh
-  NULLCMD=:
-  # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
-  # is contrary to our usage.  Disable this feature.
-  alias -g '${1+"$@"}'='"$@"'
-  setopt NO_GLOB_SUBST
-else
-  case `(set -o) 2>/dev/null` in
-  *posix*) set -o posix ;;
-esac
-
-fi
-
-
-
-
-# PATH needs CR
-# Avoid depending upon Character Ranges.
-as_cr_letters='abcdefghijklmnopqrstuvwxyz'
-as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
-as_cr_Letters=$as_cr_letters$as_cr_LETTERS
-as_cr_digits='0123456789'
-as_cr_alnum=$as_cr_Letters$as_cr_digits
-
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
-  echo "#! /bin/sh" >conf$$.sh
-  echo  "exit 0"   >>conf$$.sh
-  chmod +x conf$$.sh
-  if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
-    PATH_SEPARATOR=';'
-  else
-    PATH_SEPARATOR=:
-  fi
-  rm -f conf$$.sh
-fi
-
-# Support unset when possible.
-if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
-  as_unset=unset
-else
-  as_unset=false
-fi
-
-
-# IFS
-# We need space, tab and new line, in precisely that order.  Quoting is
-# there to prevent editors from complaining about space-tab.
-# (If _AS_PATH_WALK were called with IFS unset, it would disable word
-# splitting by setting IFS to empty value.)
-as_nl='
-'
-IFS=" ""	$as_nl"
-
-# Find who we are.  Look in the path if we contain no directory separator.
-case $0 in
-  *[\\/]* ) as_myself=$0 ;;
-  *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
-done
-IFS=$as_save_IFS
-
-     ;;
-esac
-# We did not find ourselves, most probably we were run as `sh COMMAND'
-# in which case we are not to be found in the path.
-if test "x$as_myself" = x; then
-  as_myself=$0
-fi
-if test ! -f "$as_myself"; then
-  echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
-  { (exit 1); exit 1; }
-fi
-
-# Work around bugs in pre-3.0 UWIN ksh.
-for as_var in ENV MAIL MAILPATH
-do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
-done
-PS1='$ '
-PS2='> '
-PS4='+ '
-
-# NLS nuisances.
-for as_var in \
-  LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
-  LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
-  LC_TELEPHONE LC_TIME
-do
-  if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
-    eval $as_var=C; export $as_var
-  else
-    ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
-  fi
-done
-
-# Required to use basename.
-if expr a : '\(a\)' >/dev/null 2>&1 &&
-   test "X`expr 00001 : '.*\(...\)'`" = X001; then
-  as_expr=expr
-else
-  as_expr=false
-fi
-
-if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
-  as_basename=basename
-else
-  as_basename=false
-fi
-
-
-# Name of the executable.
-as_me=`$as_basename -- "$0" ||
-$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
-	 X"$0" : 'X\(//\)$' \| \
-	 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
-echo X/"$0" |
-    sed '/^.*\/\([^/][^/]*\)\/*$/{
-	    s//\1/
-	    q
-	  }
-	  /^X\/\(\/\/\)$/{
-	    s//\1/
-	    q
-	  }
-	  /^X\/\(\/\).*/{
-	    s//\1/
-	    q
-	  }
-	  s/.*/./; q'`
-
-# CDPATH.
-$as_unset CDPATH
-
-
-if test "x$CONFIG_SHELL" = x; then
-  if (eval ":") 2>/dev/null; then
-  as_have_required=yes
-else
-  as_have_required=no
-fi
-
-  if test $as_have_required = yes && 	 (eval ":
-(as_func_return () {
-  (exit \$1)
-}
-as_func_success () {
-  as_func_return 0
-}
-as_func_failure () {
-  as_func_return 1
-}
-as_func_ret_success () {
-  return 0
-}
-as_func_ret_failure () {
-  return 1
-}
-
-exitcode=0
-if as_func_success; then
-  :
-else
-  exitcode=1
-  echo as_func_success failed.
-fi
-
-if as_func_failure; then
-  exitcode=1
-  echo as_func_failure succeeded.
-fi
-
-if as_func_ret_success; then
-  :
-else
-  exitcode=1
-  echo as_func_ret_success failed.
-fi
-
-if as_func_ret_failure; then
-  exitcode=1
-  echo as_func_ret_failure succeeded.
-fi
-
-if ( set x; as_func_ret_success y && test x = \"\$1\" ); then
-  :
-else
-  exitcode=1
-  echo positional parameters were not saved.
-fi
-
-test \$exitcode = 0) || { (exit 1); exit 1; }
-
-(
-  as_lineno_1=\$LINENO
-  as_lineno_2=\$LINENO
-  test \"x\$as_lineno_1\" != \"x\$as_lineno_2\" &&
-  test \"x\`expr \$as_lineno_1 + 1\`\" = \"x\$as_lineno_2\") || { (exit 1); exit 1; }
-") 2> /dev/null; then
-  :
-else
-  as_candidate_shells=
-    as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  case $as_dir in
-	 /*)
-	   for as_base in sh bash ksh sh5; do
-	     as_candidate_shells="$as_candidate_shells $as_dir/$as_base"
-	   done;;
-       esac
-done
-IFS=$as_save_IFS
-
-
-      for as_shell in $as_candidate_shells $SHELL; do
-	 # Try only shells that exist, to save several forks.
-	 if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
-		{ ("$as_shell") 2> /dev/null <<\_ASEOF
-if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
-  emulate sh
-  NULLCMD=:
-  # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
-  # is contrary to our usage.  Disable this feature.
-  alias -g '${1+"$@"}'='"$@"'
-  setopt NO_GLOB_SUBST
-else
-  case `(set -o) 2>/dev/null` in
-  *posix*) set -o posix ;;
-esac
-
-fi
-
-
-:
-_ASEOF
-}; then
-  CONFIG_SHELL=$as_shell
-	       as_have_required=yes
-	       if { "$as_shell" 2> /dev/null <<\_ASEOF
-if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
-  emulate sh
-  NULLCMD=:
-  # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
-  # is contrary to our usage.  Disable this feature.
-  alias -g '${1+"$@"}'='"$@"'
-  setopt NO_GLOB_SUBST
-else
-  case `(set -o) 2>/dev/null` in
-  *posix*) set -o posix ;;
-esac
-
-fi
-
-
-:
-(as_func_return () {
-  (exit $1)
-}
-as_func_success () {
-  as_func_return 0
-}
-as_func_failure () {
-  as_func_return 1
-}
-as_func_ret_success () {
-  return 0
-}
-as_func_ret_failure () {
-  return 1
-}
-
-exitcode=0
-if as_func_success; then
-  :
-else
-  exitcode=1
-  echo as_func_success failed.
-fi
-
-if as_func_failure; then
-  exitcode=1
-  echo as_func_failure succeeded.
-fi
-
-if as_func_ret_success; then
-  :
-else
-  exitcode=1
-  echo as_func_ret_success failed.
-fi
-
-if as_func_ret_failure; then
-  exitcode=1
-  echo as_func_ret_failure succeeded.
-fi
-
-if ( set x; as_func_ret_success y && test x = "$1" ); then
-  :
-else
-  exitcode=1
-  echo positional parameters were not saved.
-fi
-
-test $exitcode = 0) || { (exit 1); exit 1; }
-
-(
-  as_lineno_1=$LINENO
-  as_lineno_2=$LINENO
-  test "x$as_lineno_1" != "x$as_lineno_2" &&
-  test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2") || { (exit 1); exit 1; }
-
-_ASEOF
-}; then
-  break
-fi
-
-fi
-
-      done
-
-      if test "x$CONFIG_SHELL" != x; then
-  for as_var in BASH_ENV ENV
-        do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
-        done
-        export CONFIG_SHELL
-        exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"}
-fi
-
-
-    if test $as_have_required = no; then
-  echo This script requires a shell more modern than all the
-      echo shells that I found on your system.  Please install a
-      echo modern shell, or manually run the script under such a
-      echo shell if you do have one.
-      { (exit 1); exit 1; }
-fi
-
-    
-fi
-
-fi
-
-
-
-(eval "as_func_return () {
-  (exit \$1)
-}
-as_func_success () {
-  as_func_return 0
-}
-as_func_failure () {
-  as_func_return 1
-}
-as_func_ret_success () {
-  return 0
-}
-as_func_ret_failure () {
-  return 1
-}
-
-exitcode=0
-if as_func_success; then
-  :
-else
-  exitcode=1
-  echo as_func_success failed.
-fi
-
-if as_func_failure; then
-  exitcode=1
-  echo as_func_failure succeeded.
-fi
-
-if as_func_ret_success; then
-  :
-else
-  exitcode=1
-  echo as_func_ret_success failed.
-fi
-
-if as_func_ret_failure; then
-  exitcode=1
-  echo as_func_ret_failure succeeded.
-fi
-
-if ( set x; as_func_ret_success y && test x = \"\$1\" ); then
-  :
-else
-  exitcode=1
-  echo positional parameters were not saved.
-fi
-
-test \$exitcode = 0") || {
-  echo No shell found that supports shell functions.
-  echo Please tell autoconf at gnu.org about your system,
-  echo including any error possibly output before this
-  echo message
-}
-
-
-
-  as_lineno_1=$LINENO
-  as_lineno_2=$LINENO
-  test "x$as_lineno_1" != "x$as_lineno_2" &&
-  test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || {
-
-  # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
-  # uniformly replaced by the line number.  The first 'sed' inserts a
-  # line-number line after each line using $LINENO; the second 'sed'
-  # does the real work.  The second script uses 'N' to pair each
-  # line-number line with the line containing $LINENO, and appends
-  # trailing '-' during substitution so that $LINENO is not a special
-  # case at line end.
-  # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
-  # scripts with optimization help from Paolo Bonzini.  Blame Lee
-  # E. McMahon (1931-1989) for sed's syntax.  :-)
-  sed -n '
-    p
-    /[$]LINENO/=
-  ' <$as_myself |
-    sed '
-      s/[$]LINENO.*/&-/
-      t lineno
-      b
-      :lineno
-      N
-      :loop
-      s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
-      t loop
-      s/-\n.*//
-    ' >$as_me.lineno &&
-  chmod +x "$as_me.lineno" ||
-    { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
-   { (exit 1); exit 1; }; }
-
-  # Don't try to exec as it changes $[0], causing all sort of problems
-  # (the dirname of $[0] is not the place where we might find the
-  # original and so on.  Autoconf is especially sensitive to this).
-  . "./$as_me.lineno"
-  # Exit status is that of the last command.
-  exit
-}
-
-
-if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
-  as_dirname=dirname
-else
-  as_dirname=false
-fi
-
-ECHO_C= ECHO_N= ECHO_T=
-case `echo -n x` in
--n*)
-  case `echo 'x\c'` in
-  *c*) ECHO_T='	';;	# ECHO_T is single tab character.
-  *)   ECHO_C='\c';;
-  esac;;
-*)
-  ECHO_N='-n';;
-esac
-
-if expr a : '\(a\)' >/dev/null 2>&1 &&
-   test "X`expr 00001 : '.*\(...\)'`" = X001; then
-  as_expr=expr
-else
-  as_expr=false
-fi
-
-rm -f conf$$ conf$$.exe conf$$.file
-if test -d conf$$.dir; then
-  rm -f conf$$.dir/conf$$.file
-else
-  rm -f conf$$.dir
-  mkdir conf$$.dir
-fi
-echo >conf$$.file
-if ln -s conf$$.file conf$$ 2>/dev/null; then
-  as_ln_s='ln -s'
-  # ... but there are two gotchas:
-  # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
-  # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
-  # In both cases, we have to default to `cp -p'.
-  ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
-    as_ln_s='cp -p'
-elif ln conf$$.file conf$$ 2>/dev/null; then
-  as_ln_s=ln
-else
-  as_ln_s='cp -p'
-fi
-rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
-rmdir conf$$.dir 2>/dev/null
-
-if mkdir -p . 2>/dev/null; then
-  as_mkdir_p=:
-else
-  test -d ./-p && rmdir ./-p
-  as_mkdir_p=false
-fi
-
-if test -x / >/dev/null 2>&1; then
-  as_test_x='test -x'
-else
-  if ls -dL / >/dev/null 2>&1; then
-    as_ls_L_option=L
-  else
-    as_ls_L_option=
-  fi
-  as_test_x='
-    eval sh -c '\''
-      if test -d "$1"; then
-        test -d "$1/.";
-      else
-	case $1 in
-        -*)set "./$1";;
-	esac;
-	case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in
-	???[sx]*):;;*)false;;esac;fi
-    '\'' sh
-  '
-fi
-as_executable_p=$as_test_x
-
-# Sed expression to map a string onto a valid CPP name.
-as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
-
-# Sed expression to map a string onto a valid variable name.
-as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
-
-
-
-exec 7<&0 </dev/null 6>&1
-
-# Name of the host.
-# hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
-# so uname gets run too.
-ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
-
-#
-# Initializations.
-#
-ac_default_prefix=/usr/local
-ac_clean_files=
-ac_config_libobj_dir=.
-LIB@&t at OBJS=
-cross_compiling=no
-subdirs=
-MFLAGS=
-MAKEFLAGS=
-SHELL=${CONFIG_SHELL-/bin/sh}
-
-# Identity of this package.
-PACKAGE_NAME='Tclxml'
-PACKAGE_TARNAME='tclxml'
-PACKAGE_VERSION='3.2'
-PACKAGE_STRING='Tclxml 3.2'
-PACKAGE_BUGREPORT=''
-
-# Factoring default headers for most tests.
-ac_includes_default="\
-#include <stdio.h>
-#ifdef HAVE_SYS_TYPES_H
-# include <sys/types.h>
-#endif
-#ifdef HAVE_SYS_STAT_H
-# include <sys/stat.h>
-#endif
-#ifdef STDC_HEADERS
-# include <stdlib.h>
-# include <stddef.h>
-#else
-# ifdef HAVE_STDLIB_H
-#  include <stdlib.h>
-# endif
-#endif
-#ifdef HAVE_STRING_H
-# if !defined STDC_HEADERS && defined HAVE_MEMORY_H
-#  include <memory.h>
-# endif
-# include <string.h>
-#endif
-#ifdef HAVE_STRINGS_H
-# include <strings.h>
-#endif
-#ifdef HAVE_INTTYPES_H
-# include <inttypes.h>
-#endif
-#ifdef HAVE_STDINT_H
-# include <stdint.h>
-#endif
-#ifdef HAVE_UNISTD_H
-# include <unistd.h>
-#endif"
-
-ac_subst_vars='SHELL
-PATH_SEPARATOR
-PACKAGE_NAME
-PACKAGE_TARNAME
-PACKAGE_VERSION
-PACKAGE_STRING
-PACKAGE_BUGREPORT
-exec_prefix
-prefix
-program_transform_name
-bindir
-sbindir
-libexecdir
-datarootdir
-datadir
-sysconfdir
-sharedstatedir
-localstatedir
-includedir
-oldincludedir
-docdir
-infodir
-htmldir
-dvidir
-pdfdir
-psdir
-libdir
-localedir
-mandir
-DEFS
-ECHO_C
-ECHO_N
-ECHO_T
-LIBS
-build_alias
-host_alias
-target_alias
-CYGPATH
-EXEEXT
-PKG_LIB_FILE
-PKG_STUB_LIB_FILE
-PKG_STUB_SOURCES
-PKG_STUB_OBJECTS
-PKG_TCL_SOURCES
-PKG_HEADERS
-PKG_INCLUDES
-PKG_LIBS
-PKG_CFLAGS
-TCL_VERSION
-TCL_BIN_DIR
-TCL_SRC_DIR
-TCL_LIB_FILE
-TCL_LIB_FLAG
-TCL_LIB_SPEC
-TCL_STUB_LIB_FILE
-TCL_STUB_LIB_FLAG
-TCL_STUB_LIB_SPEC
-TCL_LIBS
-TCL_DEFS
-TCL_EXTRA_CFLAGS
-TCL_LD_FLAGS
-TCL_SHLIB_LD_LIBS
-CC
-CFLAGS
-LDFLAGS
-CPPFLAGS
-ac_ct_CC
-OBJEXT
-CPP
-INSTALL_PROGRAM
-INSTALL_SCRIPT
-INSTALL_DATA
-SET_MAKE
-RANLIB
-GREP
-EGREP
-MATH_LIBS
-PKG_SOURCES
-PKG_OBJECTS
-CLEANFILES
-TCL_INCLUDES
-TCL_THREADS
-SHARED_BUILD
-AR
-CELIB_DIR
-LIB@&t at OBJS
-DL_LIBS
-CFLAGS_DEBUG
-CFLAGS_OPTIMIZE
-CFLAGS_WARNING
-STLIB_LD
-SHLIB_LD
-SHLIB_LD_LIBS
-SHLIB_CFLAGS
-LD_LIBRARY_PATH_VAR
-TCL_DBGX
-CFLAGS_DEFAULT
-LDFLAGS_DEFAULT
-MAKE_LIB
-MAKE_SHARED_LIB
-MAKE_STATIC_LIB
-MAKE_STUB_LIB
-RANLIB_STUB
-XML2_PREFIX
-XML2_CFLAGS
-XML2_VERSION
-XSLT_VERSION
-XSLT_PREFIX
-XSLT_CFLAGS
-XML_STATIC
-XML2_LIBS
-XSLT_LIBS
-FIX_LIB
-TCLSH_PROG
-Tclxml_BUILD_LIB_SPEC
-Tclxml_LIB_SPEC
-Tclxml_BUILD_STUB_LIB_SPEC
-Tclxml_STUB_LIB_SPEC
-Tclxml_BUILD_STUB_LIB_PATH
-Tclxml_STUB_LIB_PATH
-Tclxml_INCLUDE_SPEC
-XSLTPROC
-LTLIBOBJS'
-ac_subst_files=''
-      ac_precious_vars='build_alias
-host_alias
-target_alias
-CC
-CFLAGS
-LDFLAGS
-LIBS
-CPPFLAGS
-CPP'
-
-
-# Initialize some variables set by options.
-ac_init_help=
-ac_init_version=false
-# The variables have the same names as the options, with
-# dashes changed to underlines.
-cache_file=/dev/null
-exec_prefix=NONE
-no_create=
-no_recursion=
-prefix=NONE
-program_prefix=NONE
-program_suffix=NONE
-program_transform_name=s,x,x,
-silent=
-site=
-srcdir=
-verbose=
-x_includes=NONE
-x_libraries=NONE
-
-# Installation directory options.
-# These are left unexpanded so users can "make install exec_prefix=/foo"
-# and all the variables that are supposed to be based on exec_prefix
-# by default will actually change.
-# Use braces instead of parens because sh, perl, etc. also accept them.
-# (The list follows the same order as the GNU Coding Standards.)
-bindir='${exec_prefix}/bin'
-sbindir='${exec_prefix}/sbin'
-libexecdir='${exec_prefix}/libexec'
-datarootdir='${prefix}/share'
-datadir='${datarootdir}'
-sysconfdir='${prefix}/etc'
-sharedstatedir='${prefix}/com'
-localstatedir='${prefix}/var'
-includedir='${prefix}/include'
-oldincludedir='/usr/include'
-docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
-infodir='${datarootdir}/info'
-htmldir='${docdir}'
-dvidir='${docdir}'
-pdfdir='${docdir}'
-psdir='${docdir}'
-libdir='${exec_prefix}/lib'
-localedir='${datarootdir}/locale'
-mandir='${datarootdir}/man'
-
-ac_prev=
-ac_dashdash=
-for ac_option
-do
-  # If the previous option needs an argument, assign it.
-  if test -n "$ac_prev"; then
-    eval $ac_prev=\$ac_option
-    ac_prev=
-    continue
-  fi
-
-  case $ac_option in
-  *=*)	ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
-  *)	ac_optarg=yes ;;
-  esac
-
-  # Accept the important Cygnus configure options, so we can diagnose typos.
-
-  case $ac_dashdash$ac_option in
-  --)
-    ac_dashdash=yes ;;
-
-  -bindir | --bindir | --bindi | --bind | --bin | --bi)
-    ac_prev=bindir ;;
-  -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
-    bindir=$ac_optarg ;;
-
-  -build | --build | --buil | --bui | --bu)
-    ac_prev=build_alias ;;
-  -build=* | --build=* | --buil=* | --bui=* | --bu=*)
-    build_alias=$ac_optarg ;;
-
-  -cache-file | --cache-file | --cache-fil | --cache-fi \
-  | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
-    ac_prev=cache_file ;;
-  -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
-  | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
-    cache_file=$ac_optarg ;;
-
-  --config-cache | -C)
-    cache_file=config.cache ;;
-
-  -datadir | --datadir | --datadi | --datad)
-    ac_prev=datadir ;;
-  -datadir=* | --datadir=* | --datadi=* | --datad=*)
-    datadir=$ac_optarg ;;
-
-  -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
-  | --dataroo | --dataro | --datar)
-    ac_prev=datarootdir ;;
-  -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
-  | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
-    datarootdir=$ac_optarg ;;
-
-  -disable-* | --disable-*)
-    ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
-    # Reject names that are not valid shell variable names.
-    expr "x$ac_feature" : ".*[^-._$as_cr_alnum]" >/dev/null &&
-      { echo "$as_me: error: invalid feature name: $ac_feature" >&2
-   { (exit 1); exit 1; }; }
-    ac_feature=`echo $ac_feature | sed 's/[-.]/_/g'`
-    eval enable_$ac_feature=no ;;
-
-  -docdir | --docdir | --docdi | --doc | --do)
-    ac_prev=docdir ;;
-  -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
-    docdir=$ac_optarg ;;
-
-  -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
-    ac_prev=dvidir ;;
-  -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
-    dvidir=$ac_optarg ;;
-
-  -enable-* | --enable-*)
-    ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
-    # Reject names that are not valid shell variable names.
-    expr "x$ac_feature" : ".*[^-._$as_cr_alnum]" >/dev/null &&
-      { echo "$as_me: error: invalid feature name: $ac_feature" >&2
-   { (exit 1); exit 1; }; }
-    ac_feature=`echo $ac_feature | sed 's/[-.]/_/g'`
-    eval enable_$ac_feature=\$ac_optarg ;;
-
-  -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
-  | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
-  | --exec | --exe | --ex)
-    ac_prev=exec_prefix ;;
-  -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
-  | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
-  | --exec=* | --exe=* | --ex=*)
-    exec_prefix=$ac_optarg ;;
-
-  -gas | --gas | --ga | --g)
-    # Obsolete; use --with-gas.
-    with_gas=yes ;;
-
-  -help | --help | --hel | --he | -h)
-    ac_init_help=long ;;
-  -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
-    ac_init_help=recursive ;;
-  -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
-    ac_init_help=short ;;
-
-  -host | --host | --hos | --ho)
-    ac_prev=host_alias ;;
-  -host=* | --host=* | --hos=* | --ho=*)
-    host_alias=$ac_optarg ;;
-
-  -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
-    ac_prev=htmldir ;;
-  -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
-  | --ht=*)
-    htmldir=$ac_optarg ;;
-
-  -includedir | --includedir | --includedi | --included | --include \
-  | --includ | --inclu | --incl | --inc)
-    ac_prev=includedir ;;
-  -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
-  | --includ=* | --inclu=* | --incl=* | --inc=*)
-    includedir=$ac_optarg ;;
-
-  -infodir | --infodir | --infodi | --infod | --info | --inf)
-    ac_prev=infodir ;;
-  -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
-    infodir=$ac_optarg ;;
-
-  -libdir | --libdir | --libdi | --libd)
-    ac_prev=libdir ;;
-  -libdir=* | --libdir=* | --libdi=* | --libd=*)
-    libdir=$ac_optarg ;;
-
-  -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
-  | --libexe | --libex | --libe)
-    ac_prev=libexecdir ;;
-  -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
-  | --libexe=* | --libex=* | --libe=*)
-    libexecdir=$ac_optarg ;;
-
-  -localedir | --localedir | --localedi | --localed | --locale)
-    ac_prev=localedir ;;
-  -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
-    localedir=$ac_optarg ;;
-
-  -localstatedir | --localstatedir | --localstatedi | --localstated \
-  | --localstate | --localstat | --localsta | --localst | --locals)
-    ac_prev=localstatedir ;;
-  -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
-  | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
-    localstatedir=$ac_optarg ;;
-
-  -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
-    ac_prev=mandir ;;
-  -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
-    mandir=$ac_optarg ;;
-
-  -nfp | --nfp | --nf)
-    # Obsolete; use --without-fp.
-    with_fp=no ;;
-
-  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
-  | --no-cr | --no-c | -n)
-    no_create=yes ;;
-
-  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
-  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
-    no_recursion=yes ;;
-
-  -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
-  | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
-  | --oldin | --oldi | --old | --ol | --o)
-    ac_prev=oldincludedir ;;
-  -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
-  | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
-  | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
-    oldincludedir=$ac_optarg ;;
-
-  -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
-    ac_prev=prefix ;;
-  -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
-    prefix=$ac_optarg ;;
-
-  -program-prefix | --program-prefix | --program-prefi | --program-pref \
-  | --program-pre | --program-pr | --program-p)
-    ac_prev=program_prefix ;;
-  -program-prefix=* | --program-prefix=* | --program-prefi=* \
-  | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
-    program_prefix=$ac_optarg ;;
-
-  -program-suffix | --program-suffix | --program-suffi | --program-suff \
-  | --program-suf | --program-su | --program-s)
-    ac_prev=program_suffix ;;
-  -program-suffix=* | --program-suffix=* | --program-suffi=* \
-  | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
-    program_suffix=$ac_optarg ;;
-
-  -program-transform-name | --program-transform-name \
-  | --program-transform-nam | --program-transform-na \
-  | --program-transform-n | --program-transform- \
-  | --program-transform | --program-transfor \
-  | --program-transfo | --program-transf \
-  | --program-trans | --program-tran \
-  | --progr-tra | --program-tr | --program-t)
-    ac_prev=program_transform_name ;;
-  -program-transform-name=* | --program-transform-name=* \
-  | --program-transform-nam=* | --program-transform-na=* \
-  | --program-transform-n=* | --program-transform-=* \
-  | --program-transform=* | --program-transfor=* \
-  | --program-transfo=* | --program-transf=* \
-  | --program-trans=* | --program-tran=* \
-  | --progr-tra=* | --program-tr=* | --program-t=*)
-    program_transform_name=$ac_optarg ;;
-
-  -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
-    ac_prev=pdfdir ;;
-  -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
-    pdfdir=$ac_optarg ;;
-
-  -psdir | --psdir | --psdi | --psd | --ps)
-    ac_prev=psdir ;;
-  -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
-    psdir=$ac_optarg ;;
-
-  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
-  | -silent | --silent | --silen | --sile | --sil)
-    silent=yes ;;
-
-  -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
-    ac_prev=sbindir ;;
-  -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
-  | --sbi=* | --sb=*)
-    sbindir=$ac_optarg ;;
-
-  -sharedstatedir | --sharedstatedir | --sharedstatedi \
-  | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
-  | --sharedst | --shareds | --shared | --share | --shar \
-  | --sha | --sh)
-    ac_prev=sharedstatedir ;;
-  -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
-  | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
-  | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
-  | --sha=* | --sh=*)
-    sharedstatedir=$ac_optarg ;;
-
-  -site | --site | --sit)
-    ac_prev=site ;;
-  -site=* | --site=* | --sit=*)
-    site=$ac_optarg ;;
-
-  -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
-    ac_prev=srcdir ;;
-  -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
-    srcdir=$ac_optarg ;;
-
-  -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
-  | --syscon | --sysco | --sysc | --sys | --sy)
-    ac_prev=sysconfdir ;;
-  -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
-  | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
-    sysconfdir=$ac_optarg ;;
-
-  -target | --target | --targe | --targ | --tar | --ta | --t)
-    ac_prev=target_alias ;;
-  -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
-    target_alias=$ac_optarg ;;
-
-  -v | -verbose | --verbose | --verbos | --verbo | --verb)
-    verbose=yes ;;
-
-  -version | --version | --versio | --versi | --vers | -V)
-    ac_init_version=: ;;
-
-  -with-* | --with-*)
-    ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
-    # Reject names that are not valid shell variable names.
-    expr "x$ac_package" : ".*[^-._$as_cr_alnum]" >/dev/null &&
-      { echo "$as_me: error: invalid package name: $ac_package" >&2
-   { (exit 1); exit 1; }; }
-    ac_package=`echo $ac_package | sed 's/[-.]/_/g'`
-    eval with_$ac_package=\$ac_optarg ;;
-
-  -without-* | --without-*)
-    ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
-    # Reject names that are not valid shell variable names.
-    expr "x$ac_package" : ".*[^-._$as_cr_alnum]" >/dev/null &&
-      { echo "$as_me: error: invalid package name: $ac_package" >&2
-   { (exit 1); exit 1; }; }
-    ac_package=`echo $ac_package | sed 's/[-.]/_/g'`
-    eval with_$ac_package=no ;;
-
-  --x)
-    # Obsolete; use --with-x.
-    with_x=yes ;;
-
-  -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
-  | --x-incl | --x-inc | --x-in | --x-i)
-    ac_prev=x_includes ;;
-  -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
-  | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
-    x_includes=$ac_optarg ;;
-
-  -x-libraries | --x-libraries | --x-librarie | --x-librari \
-  | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
-    ac_prev=x_libraries ;;
-  -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
-  | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
-    x_libraries=$ac_optarg ;;
-
-  -*) { echo "$as_me: error: unrecognized option: $ac_option
-Try \`$0 --help' for more information." >&2
-   { (exit 1); exit 1; }; }
-    ;;
-
-  *=*)
-    ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
-    # Reject names that are not valid shell variable names.
-    expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
-      { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
-   { (exit 1); exit 1; }; }
-    eval $ac_envvar=\$ac_optarg
-    export $ac_envvar ;;
-
-  *)
-    # FIXME: should be removed in autoconf 3.0.
-    echo "$as_me: WARNING: you should use --build, --host, --target" >&2
-    expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
-      echo "$as_me: WARNING: invalid host type: $ac_option" >&2
-    : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
-    ;;
-
-  esac
-done
-
-if test -n "$ac_prev"; then
-  ac_option=--`echo $ac_prev | sed 's/_/-/g'`
-  { echo "$as_me: error: missing argument to $ac_option" >&2
-   { (exit 1); exit 1; }; }
-fi
-
-# Be sure to have absolute directory names.
-for ac_var in	exec_prefix prefix bindir sbindir libexecdir datarootdir \
-		datadir sysconfdir sharedstatedir localstatedir includedir \
-		oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
-		libdir localedir mandir
-do
-  eval ac_val=\$$ac_var
-  case $ac_val in
-    [\\/$]* | ?:[\\/]* )  continue;;
-    NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
-  esac
-  { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
-   { (exit 1); exit 1; }; }
-done
-
-# There might be people who depend on the old broken behavior: `$host'
-# used to hold the argument of --host etc.
-# FIXME: To remove some day.
-build=$build_alias
-host=$host_alias
-target=$target_alias
-
-# FIXME: To remove some day.
-if test "x$host_alias" != x; then
-  if test "x$build_alias" = x; then
-    cross_compiling=maybe
-    echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
-    If a cross compiler is detected then cross compile mode will be used." >&2
-  elif test "x$build_alias" != "x$host_alias"; then
-    cross_compiling=yes
-  fi
-fi
-
-ac_tool_prefix=
-test -n "$host_alias" && ac_tool_prefix=$host_alias-
-
-test "$silent" = yes && exec 6>/dev/null
-
-
-ac_pwd=`pwd` && test -n "$ac_pwd" &&
-ac_ls_di=`ls -di .` &&
-ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
-  { echo "$as_me: error: Working directory cannot be determined" >&2
-   { (exit 1); exit 1; }; }
-test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
-  { echo "$as_me: error: pwd does not report name of working directory" >&2
-   { (exit 1); exit 1; }; }
-
-
-# Find the source files, if location was not specified.
-if test -z "$srcdir"; then
-  ac_srcdir_defaulted=yes
-  # Try the directory containing this script, then the parent directory.
-  ac_confdir=`$as_dirname -- "$0" ||
-$as_expr X"$0" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
-	 X"$0" : 'X\(//\)[^/]' \| \
-	 X"$0" : 'X\(//\)$' \| \
-	 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
-echo X"$0" |
-    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
-	    s//\1/
-	    q
-	  }
-	  /^X\(\/\/\)[^/].*/{
-	    s//\1/
-	    q
-	  }
-	  /^X\(\/\/\)$/{
-	    s//\1/
-	    q
-	  }
-	  /^X\(\/\).*/{
-	    s//\1/
-	    q
-	  }
-	  s/.*/./; q'`
-  srcdir=$ac_confdir
-  if test ! -r "$srcdir/$ac_unique_file"; then
-    srcdir=..
-  fi
-else
-  ac_srcdir_defaulted=no
-fi
-if test ! -r "$srcdir/$ac_unique_file"; then
-  test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
-  { echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
-   { (exit 1); exit 1; }; }
-fi
-ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
-ac_abs_confdir=`(
-	cd "$srcdir" && test -r "./$ac_unique_file" || { echo "$as_me: error: $ac_msg" >&2
-   { (exit 1); exit 1; }; }
-	pwd)`
-# When building in place, set srcdir=.
-if test "$ac_abs_confdir" = "$ac_pwd"; then
-  srcdir=.
-fi
-# Remove unnecessary trailing slashes from srcdir.
-# Double slashes in file names in object file debugging info
-# mess up M-x gdb in Emacs.
-case $srcdir in
-*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
-esac
-for ac_var in $ac_precious_vars; do
-  eval ac_env_${ac_var}_set=\${${ac_var}+set}
-  eval ac_env_${ac_var}_value=\$${ac_var}
-  eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
-  eval ac_cv_env_${ac_var}_value=\$${ac_var}
-done
-
-#
-# Report the --help message.
-#
-if test "$ac_init_help" = "long"; then
-  # Omit some internal or obsolete options to make the list less imposing.
-  # This message is too long to be a string in the A/UX 3.1 sh.
-  cat <<_ACEOF
-\`configure' configures Tclxml 3.2 to adapt to many kinds of systems.
-
-Usage: $0 [OPTION]... [VAR=VALUE]...
-
-To assign environment variables (e.g., CC, CFLAGS...), specify them as
-VAR=VALUE.  See below for descriptions of some of the useful variables.
-
-Defaults for the options are specified in brackets.
-
-Configuration:
-  -h, --help              display this help and exit
-      --help=short        display options specific to this package
-      --help=recursive    display the short help of all the included packages
-  -V, --version           display version information and exit
-  -q, --quiet, --silent   do not print \`checking...' messages
-      --cache-file=FILE   cache test results in FILE [disabled]
-  -C, --config-cache      alias for \`--cache-file=config.cache'
-  -n, --no-create         do not create output files
-      --srcdir=DIR        find the sources in DIR [configure dir or \`..']
-
-Installation directories:
-  --prefix=PREFIX         install architecture-independent files in PREFIX
-			  [$ac_default_prefix]
-  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
-			  [PREFIX]
-
-By default, \`make install' will install all the files in
-\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
-an installation prefix other than \`$ac_default_prefix' using \`--prefix',
-for instance \`--prefix=\$HOME'.
-
-For better control, use the options below.
-
-Fine tuning of the installation directories:
-  --bindir=DIR           user executables [EPREFIX/bin]
-  --sbindir=DIR          system admin executables [EPREFIX/sbin]
-  --libexecdir=DIR       program executables [EPREFIX/libexec]
-  --sysconfdir=DIR       read-only single-machine data [PREFIX/etc]
-  --sharedstatedir=DIR   modifiable architecture-independent data [PREFIX/com]
-  --localstatedir=DIR    modifiable single-machine data [PREFIX/var]
-  --libdir=DIR           object code libraries [EPREFIX/lib]
-  --includedir=DIR       C header files [PREFIX/include]
-  --oldincludedir=DIR    C header files for non-gcc [/usr/include]
-  --datarootdir=DIR      read-only arch.-independent data root [PREFIX/share]
-  --datadir=DIR          read-only architecture-independent data [DATAROOTDIR]
-  --infodir=DIR          info documentation [DATAROOTDIR/info]
-  --localedir=DIR        locale-dependent data [DATAROOTDIR/locale]
-  --mandir=DIR           man documentation [DATAROOTDIR/man]
-  --docdir=DIR           documentation root @<:@DATAROOTDIR/doc/tclxml@:>@
-  --htmldir=DIR          html documentation [DOCDIR]
-  --dvidir=DIR           dvi documentation [DOCDIR]
-  --pdfdir=DIR           pdf documentation [DOCDIR]
-  --psdir=DIR            ps documentation [DOCDIR]
-_ACEOF
-
-  cat <<\_ACEOF
-_ACEOF
-fi
-
-if test -n "$ac_init_help"; then
-  case $ac_init_help in
-     short | recursive ) echo "Configuration of Tclxml 3.2:";;
-   esac
-  cat <<\_ACEOF
-
-Optional Features:
-  --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
-  --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
-  --enable-threads        build with threads
-  --enable-shared         build and link with shared libraries (default: on)
-  --enable-64bit          enable 64bit support (default: off)
-  --enable-64bit-vis      enable 64bit Sparc VIS support (default: off)
-  --enable-wince          enable Win/CE support (where applicable)
-  --enable-load           allow dynamic loading and "load" command (default:
-                          on)
-  --enable-symbols        build with debugging symbols (default: off)
-  --enable-framework      build as a Mac OS X framework
-
-Optional Packages:
-  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
-  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
-  --with-tcl              directory containing tcl configuration
-                          (tclConfig.sh)
-  --with-tclinclude       directory containing the public Tcl header files
-  --with-celib=DIR        use Windows/CE support library from DIR
-  --with-xml2-config      the xml2-config configuration script
-  --with-xslt-config      the xslt-config configuration script
-  --with-xml-static      statically link the XML libraries
-
-Some influential environment variables:
-  CC          C compiler command
-  CFLAGS      C compiler flags
-  LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
-              nonstandard directory <lib dir>
-  LIBS        libraries to pass to the linker, e.g. -l<library>
-  CPPFLAGS    C/C++/Objective C preprocessor flags, e.g. -I<include dir> if
-              you have headers in a nonstandard directory <include dir>
-  CPP         C preprocessor
-
-Use these variables to override the choices made by `configure' or to help
-it to find libraries and programs with nonstandard names/locations.
-
-_ACEOF
-ac_status=$?
-fi
-
-if test "$ac_init_help" = "recursive"; then
-  # If there are subdirs, report their specific --help.
-  for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
-    test -d "$ac_dir" || continue
-    ac_builddir=.
-
-case "$ac_dir" in
-.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
-*)
-  ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
-  # A ".." for each directory in $ac_dir_suffix.
-  ac_top_builddir_sub=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,/..,g;s,/,,'`
-  case $ac_top_builddir_sub in
-  "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
-  *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
-  esac ;;
-esac
-ac_abs_top_builddir=$ac_pwd
-ac_abs_builddir=$ac_pwd$ac_dir_suffix
-# for backward compatibility:
-ac_top_builddir=$ac_top_build_prefix
-
-case $srcdir in
-  .)  # We are building in place.
-    ac_srcdir=.
-    ac_top_srcdir=$ac_top_builddir_sub
-    ac_abs_top_srcdir=$ac_pwd ;;
-  [\\/]* | ?:[\\/]* )  # Absolute name.
-    ac_srcdir=$srcdir$ac_dir_suffix;
-    ac_top_srcdir=$srcdir
-    ac_abs_top_srcdir=$srcdir ;;
-  *) # Relative name.
-    ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
-    ac_top_srcdir=$ac_top_build_prefix$srcdir
-    ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
-esac
-ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
-
-    cd "$ac_dir" || { ac_status=$?; continue; }
-    # Check for guested configure.
-    if test -f "$ac_srcdir/configure.gnu"; then
-      echo &&
-      $SHELL "$ac_srcdir/configure.gnu" --help=recursive
-    elif test -f "$ac_srcdir/configure"; then
-      echo &&
-      $SHELL "$ac_srcdir/configure" --help=recursive
-    else
-      echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
-    fi || ac_status=$?
-    cd "$ac_pwd" || { ac_status=$?; break; }
-  done
-fi
-
-test -n "$ac_init_help" && exit $ac_status
-if $ac_init_version; then
-  cat <<\_ACEOF
-Tclxml configure 3.2
-generated by GNU Autoconf 2.61
-
-Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
-2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
-This configure script is free software; the Free Software Foundation
-gives unlimited permission to copy, distribute and modify it.
-_ACEOF
-  exit
-fi
-cat >config.log <<_ACEOF
-This file contains any messages produced by compilers while
-running configure, to aid debugging if configure makes a mistake.
-
-It was created by Tclxml $as_me 3.2, which was
-generated by GNU Autoconf 2.61.  Invocation command line was
-
-  $ $0 $@
-
-_ACEOF
-exec 5>>config.log
-{
-cat <<_ASUNAME
-@%:@@%:@ --------- @%:@@%:@
-@%:@@%:@ Platform. @%:@@%:@
-@%:@@%:@ --------- @%:@@%:@
-
-hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
-uname -m = `(uname -m) 2>/dev/null || echo unknown`
-uname -r = `(uname -r) 2>/dev/null || echo unknown`
-uname -s = `(uname -s) 2>/dev/null || echo unknown`
-uname -v = `(uname -v) 2>/dev/null || echo unknown`
-
-/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
-/bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
-
-/bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
-/usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
-/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
-/usr/bin/hostinfo      = `(/usr/bin/hostinfo) 2>/dev/null      || echo unknown`
-/bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
-/usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
-/bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
-
-_ASUNAME
-
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  echo "PATH: $as_dir"
-done
-IFS=$as_save_IFS
-
-} >&5
-
-cat >&5 <<_ACEOF
-
-
-@%:@@%:@ ----------- @%:@@%:@
-@%:@@%:@ Core tests. @%:@@%:@
-@%:@@%:@ ----------- @%:@@%:@
-
-_ACEOF
-
-
-# Keep a trace of the command line.
-# Strip out --no-create and --no-recursion so they do not pile up.
-# Strip out --silent because we don't want to record it for future runs.
-# Also quote any args containing shell meta-characters.
-# Make two passes to allow for proper duplicate-argument suppression.
-ac_configure_args=
-ac_configure_args0=
-ac_configure_args1=
-ac_must_keep_next=false
-for ac_pass in 1 2
-do
-  for ac_arg
-  do
-    case $ac_arg in
-    -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
-    -q | -quiet | --quiet | --quie | --qui | --qu | --q \
-    | -silent | --silent | --silen | --sile | --sil)
-      continue ;;
-    *\'*)
-      ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
-    esac
-    case $ac_pass in
-    1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
-    2)
-      ac_configure_args1="$ac_configure_args1 '$ac_arg'"
-      if test $ac_must_keep_next = true; then
-	ac_must_keep_next=false # Got value, back to normal.
-      else
-	case $ac_arg in
-	  *=* | --config-cache | -C | -disable-* | --disable-* \
-	  | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
-	  | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
-	  | -with-* | --with-* | -without-* | --without-* | --x)
-	    case "$ac_configure_args0 " in
-	      "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
-	    esac
-	    ;;
-	  -* ) ac_must_keep_next=true ;;
-	esac
-      fi
-      ac_configure_args="$ac_configure_args '$ac_arg'"
-      ;;
-    esac
-  done
-done
-$as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
-$as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
-
-# When interrupted or exit'd, cleanup temporary files, and complete
-# config.log.  We remove comments because anyway the quotes in there
-# would cause problems or look ugly.
-# WARNING: Use '\'' to represent an apostrophe within the trap.
-# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
-trap 'exit_status=$?
-  # Save into config.log some information that might help in debugging.
-  {
-    echo
-
-    cat <<\_ASBOX
-@%:@@%:@ ---------------- @%:@@%:@
-@%:@@%:@ Cache variables. @%:@@%:@
-@%:@@%:@ ---------------- @%:@@%:@
-_ASBOX
-    echo
-    # The following way of writing the cache mishandles newlines in values,
-(
-  for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
-    eval ac_val=\$$ac_var
-    case $ac_val in #(
-    *${as_nl}*)
-      case $ac_var in #(
-      *_cv_*) { echo "$as_me:$LINENO: WARNING: Cache variable $ac_var contains a newline." >&5
-echo "$as_me: WARNING: Cache variable $ac_var contains a newline." >&2;} ;;
-      esac
-      case $ac_var in #(
-      _ | IFS | as_nl) ;; #(
-      *) $as_unset $ac_var ;;
-      esac ;;
-    esac
-  done
-  (set) 2>&1 |
-    case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
-    *${as_nl}ac_space=\ *)
-      sed -n \
-	"s/'\''/'\''\\\\'\'''\''/g;
-	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
-      ;; #(
-    *)
-      sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
-      ;;
-    esac |
-    sort
-)
-    echo
-
-    cat <<\_ASBOX
-@%:@@%:@ ----------------- @%:@@%:@
-@%:@@%:@ Output variables. @%:@@%:@
-@%:@@%:@ ----------------- @%:@@%:@
-_ASBOX
-    echo
-    for ac_var in $ac_subst_vars
-    do
-      eval ac_val=\$$ac_var
-      case $ac_val in
-      *\'\''*) ac_val=`echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
-      esac
-      echo "$ac_var='\''$ac_val'\''"
-    done | sort
-    echo
-
-    if test -n "$ac_subst_files"; then
-      cat <<\_ASBOX
-@%:@@%:@ ------------------- @%:@@%:@
-@%:@@%:@ File substitutions. @%:@@%:@
-@%:@@%:@ ------------------- @%:@@%:@
-_ASBOX
-      echo
-      for ac_var in $ac_subst_files
-      do
-	eval ac_val=\$$ac_var
-	case $ac_val in
-	*\'\''*) ac_val=`echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
-	esac
-	echo "$ac_var='\''$ac_val'\''"
-      done | sort
-      echo
-    fi
-
-    if test -s confdefs.h; then
-      cat <<\_ASBOX
-@%:@@%:@ ----------- @%:@@%:@
-@%:@@%:@ confdefs.h. @%:@@%:@
-@%:@@%:@ ----------- @%:@@%:@
-_ASBOX
-      echo
-      cat confdefs.h
-      echo
-    fi
-    test "$ac_signal" != 0 &&
-      echo "$as_me: caught signal $ac_signal"
-    echo "$as_me: exit $exit_status"
-  } >&5
-  rm -f core *.core core.conftest.* &&
-    rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
-    exit $exit_status
-' 0
-for ac_signal in 1 2 13 15; do
-  trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
-done
-ac_signal=0
-
-# confdefs.h avoids OS command line length limits that DEFS can exceed.
-rm -f -r conftest* confdefs.h
-
-# Predefined preprocessor variables.
-
-cat >>confdefs.h <<_ACEOF
-@%:@define PACKAGE_NAME "$PACKAGE_NAME"
-_ACEOF
-
-
-cat >>confdefs.h <<_ACEOF
-@%:@define PACKAGE_TARNAME "$PACKAGE_TARNAME"
-_ACEOF
-
-
-cat >>confdefs.h <<_ACEOF
-@%:@define PACKAGE_VERSION "$PACKAGE_VERSION"
-_ACEOF
-
-
-cat >>confdefs.h <<_ACEOF
-@%:@define PACKAGE_STRING "$PACKAGE_STRING"
-_ACEOF
-
-
-cat >>confdefs.h <<_ACEOF
-@%:@define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
-_ACEOF
-
-
-# Let the site file select an alternate cache file if it wants to.
-# Prefer explicitly selected file to automatically selected ones.
-if test -n "$CONFIG_SITE"; then
-  set x "$CONFIG_SITE"
-elif test "x$prefix" != xNONE; then
-  set x "$prefix/share/config.site" "$prefix/etc/config.site"
-else
-  set x "$ac_default_prefix/share/config.site" \
-	"$ac_default_prefix/etc/config.site"
-fi
-shift
-for ac_site_file
-do
-  if test -r "$ac_site_file"; then
-    { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
-echo "$as_me: loading site script $ac_site_file" >&6;}
-    sed 's/^/| /' "$ac_site_file" >&5
-    . "$ac_site_file"
-  fi
-done
-
-if test -r "$cache_file"; then
-  # Some versions of bash will fail to source /dev/null (special
-  # files actually), so we avoid doing that.
-  if test -f "$cache_file"; then
-    { echo "$as_me:$LINENO: loading cache $cache_file" >&5
-echo "$as_me: loading cache $cache_file" >&6;}
-    case $cache_file in
-      [\\/]* | ?:[\\/]* ) . "$cache_file";;
-      *)                      . "./$cache_file";;
-    esac
-  fi
-else
-  { echo "$as_me:$LINENO: creating cache $cache_file" >&5
-echo "$as_me: creating cache $cache_file" >&6;}
-  >$cache_file
-fi
-
-# Check that the precious variables saved in the cache have kept the same
-# value.
-ac_cache_corrupted=false
-for ac_var in $ac_precious_vars; do
-  eval ac_old_set=\$ac_cv_env_${ac_var}_set
-  eval ac_new_set=\$ac_env_${ac_var}_set
-  eval ac_old_val=\$ac_cv_env_${ac_var}_value
-  eval ac_new_val=\$ac_env_${ac_var}_value
-  case $ac_old_set,$ac_new_set in
-    set,)
-      { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
-echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
-      ac_cache_corrupted=: ;;
-    ,set)
-      { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
-echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
-      ac_cache_corrupted=: ;;
-    ,);;
-    *)
-      if test "x$ac_old_val" != "x$ac_new_val"; then
-	{ echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
-echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
-	{ echo "$as_me:$LINENO:   former value:  $ac_old_val" >&5
-echo "$as_me:   former value:  $ac_old_val" >&2;}
-	{ echo "$as_me:$LINENO:   current value: $ac_new_val" >&5
-echo "$as_me:   current value: $ac_new_val" >&2;}
-	ac_cache_corrupted=:
-      fi;;
-  esac
-  # Pass precious variables to config.status.
-  if test "$ac_new_set" = set; then
-    case $ac_new_val in
-    *\'*) ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
-    *) ac_arg=$ac_var=$ac_new_val ;;
-    esac
-    case " $ac_configure_args " in
-      *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
-      *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
-    esac
-  fi
-done
-if $ac_cache_corrupted; then
-  { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
-echo "$as_me: error: changes in the environment can compromise the build" >&2;}
-  { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
-echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
-   { (exit 1); exit 1; }; }
-fi
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-
-PACKAGE_NAME=Tclxml
-PACKAGE_VERSION=3.2
-
-
-    # TEA extensions pass this us the version of TEA they think they
-    # are compatible with.
-    TEA_VERSION="3.6"
-
-    { echo "$as_me:$LINENO: checking for correct TEA configuration" >&5
-echo $ECHO_N "checking for correct TEA configuration... $ECHO_C" >&6; }
-    if test x"${PACKAGE_NAME}" = x ; then
-	{ { echo "$as_me:$LINENO: error: 
-The PACKAGE_NAME variable must be defined by your TEA configure.in" >&5
-echo "$as_me: error: 
-The PACKAGE_NAME variable must be defined by your TEA configure.in" >&2;}
-   { (exit 1); exit 1; }; }
-    fi
-    if test x"3.6" = x ; then
-	{ { echo "$as_me:$LINENO: error: 
-TEA version not specified." >&5
-echo "$as_me: error: 
-TEA version not specified." >&2;}
-   { (exit 1); exit 1; }; }
-    elif test "3.6" != "${TEA_VERSION}" ; then
-	{ echo "$as_me:$LINENO: result: warning: requested TEA version \"3.6\", have \"${TEA_VERSION}\"" >&5
-echo "${ECHO_T}warning: requested TEA version \"3.6\", have \"${TEA_VERSION}\"" >&6; }
-    else
-	{ echo "$as_me:$LINENO: result: ok (TEA ${TEA_VERSION})" >&5
-echo "${ECHO_T}ok (TEA ${TEA_VERSION})" >&6; }
-    fi
-    case "`uname -s`" in
-	*win32*|*WIN32*|*CYGWIN_NT*|*CYGWIN_9*|*CYGWIN_ME*|*MINGW32_*)
-	    # Extract the first word of "cygpath", so it can be a program name with args.
-set dummy cygpath; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
-if test "${ac_cv_prog_CYGPATH+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$CYGPATH"; then
-  ac_cv_prog_CYGPATH="$CYGPATH" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_CYGPATH="cygpath -w"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
-
-  test -z "$ac_cv_prog_CYGPATH" && ac_cv_prog_CYGPATH="echo"
-fi
-fi
-CYGPATH=$ac_cv_prog_CYGPATH
-if test -n "$CYGPATH"; then
-  { echo "$as_me:$LINENO: result: $CYGPATH" >&5
-echo "${ECHO_T}$CYGPATH" >&6; }
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-fi
-
-
-	    EXEEXT=".exe"
-	    TEA_PLATFORM="windows"
-	    ;;
-	*)
-	    CYGPATH=echo
-	    EXEEXT=""
-	    TEA_PLATFORM="unix"
-	    ;;
-    esac
-
-    # Check if exec_prefix is set. If not use fall back to prefix.
-    # Note when adjusted, so that TEA_PREFIX can correct for this.
-    # This is needed for recursive configures, since autoconf propagates
-    # $prefix, but not $exec_prefix (doh!).
-    if test x$exec_prefix = xNONE ; then
-	exec_prefix_default=yes
-	exec_prefix=$prefix
-    fi
-
-    
-    
-
-    # This package name must be replaced statically for AC_SUBST to work
-    
-    # Substitute STUB_LIB_FILE in case package creates a stub library too.
-    
-
-    # We AC_SUBST these here to ensure they are subst'ed,
-    # in case the user doesn't call TEA_ADD_...
-    
-    
-    
-    
-    
-    
-    
-
-ac_aux_dir=
-for ac_dir in tclconfig "$srcdir"/tclconfig; do
-  if test -f "$ac_dir/install-sh"; then
-    ac_aux_dir=$ac_dir
-    ac_install_sh="$ac_aux_dir/install-sh -c"
-    break
-  elif test -f "$ac_dir/install.sh"; then
-    ac_aux_dir=$ac_dir
-    ac_install_sh="$ac_aux_dir/install.sh -c"
-    break
-  elif test -f "$ac_dir/shtool"; then
-    ac_aux_dir=$ac_dir
-    ac_install_sh="$ac_aux_dir/shtool install -c"
-    break
-  fi
-done
-if test -z "$ac_aux_dir"; then
-  { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in tclconfig \"$srcdir\"/tclconfig" >&5
-echo "$as_me: error: cannot find install-sh or install.sh in tclconfig \"$srcdir\"/tclconfig" >&2;}
-   { (exit 1); exit 1; }; }
-fi
-
-# These three variables are undocumented and unsupported,
-# and are intended to be withdrawn in a future Autoconf release.
-# They can cause serious problems if a builder's source tree is in a directory
-# whose full name contains unusual characters.
-ac_config_guess="$SHELL $ac_aux_dir/config.guess"  # Please don't use this var.
-ac_config_sub="$SHELL $ac_aux_dir/config.sub"  # Please don't use this var.
-ac_configure="$SHELL $ac_aux_dir/configure"  # Please don't use this var.
-
-
-
-
-        
-    #
-    # Ok, lets find the tcl configuration
-    # First, look for one uninstalled.
-    # the alternative search directory is invoked by --with-tcl
-    #
-
-    if test x"${no_tcl}" = x ; then
-	# we reset no_tcl in case something fails here
-	no_tcl=true
-	
-# Check whether --with-tcl was given.
-if test "${with_tcl+set}" = set; then
-  withval=$with_tcl; with_tclconfig=${withval}
-fi
-
-	{ echo "$as_me:$LINENO: checking for Tcl configuration" >&5
-echo $ECHO_N "checking for Tcl configuration... $ECHO_C" >&6; }
-	if test "${ac_cv_c_tclconfig+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  
-
-	    # First check to see if --with-tcl was specified.
-	    if test x"${with_tclconfig}" != x ; then
-		case ${with_tclconfig} in
-		    */tclConfig.sh )
-			if test -f ${with_tclconfig}; then
-			    { echo "$as_me:$LINENO: WARNING: --with-tcl argument should refer to directory containing tclConfig.sh, not to tclConfig.sh itself" >&5
-echo "$as_me: WARNING: --with-tcl argument should refer to directory containing tclConfig.sh, not to tclConfig.sh itself" >&2;}
-			    with_tclconfig=`echo ${with_tclconfig} | sed 's!/tclConfig\.sh$!!'`
-			fi ;;
-		esac
-		if test -f "${with_tclconfig}/tclConfig.sh" ; then
-		    ac_cv_c_tclconfig=`(cd ${with_tclconfig}; pwd)`
-		else
-		    { { echo "$as_me:$LINENO: error: ${with_tclconfig} directory doesn't contain tclConfig.sh" >&5
-echo "$as_me: error: ${with_tclconfig} directory doesn't contain tclConfig.sh" >&2;}
-   { (exit 1); exit 1; }; }
-		fi
-	    fi
-
-	    # then check for a private Tcl installation
-	    if test x"${ac_cv_c_tclconfig}" = x ; then
-		for i in \
-			../tcl \
-			`ls -dr ../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
-			`ls -dr ../tcl[8-9].[0-9] 2>/dev/null` \
-			`ls -dr ../tcl[8-9].[0-9]* 2>/dev/null` \
-			../../tcl \
-			`ls -dr ../../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
-			`ls -dr ../../tcl[8-9].[0-9] 2>/dev/null` \
-			`ls -dr ../../tcl[8-9].[0-9]* 2>/dev/null` \
-			../../../tcl \
-			`ls -dr ../../../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
-			`ls -dr ../../../tcl[8-9].[0-9] 2>/dev/null` \
-			`ls -dr ../../../tcl[8-9].[0-9]* 2>/dev/null` ; do
-		    if test -f "$i/unix/tclConfig.sh" ; then
-			ac_cv_c_tclconfig=`(cd $i/unix; pwd)`
-			break
-		    fi
-		done
-	    fi
-
-	    # on Darwin, check in Framework installation locations
-	    if test "`uname -s`" = "Darwin" -a x"${ac_cv_c_tclconfig}" = x ; then
-		for i in `ls -d ~/Library/Frameworks 2>/dev/null` \
-			`ls -d /Library/Frameworks 2>/dev/null` \
-			`ls -d /Network/Library/Frameworks 2>/dev/null` \
-			`ls -d /System/Library/Frameworks 2>/dev/null` \
-			; do
-		    if test -f "$i/Tcl.framework/tclConfig.sh" ; then
-			ac_cv_c_tclconfig=`(cd $i/Tcl.framework; pwd)`
-			break
-		    fi
-		done
-	    fi
-
-	    # on Windows, check in common installation locations
-	    if test "${TEA_PLATFORM}" = "windows" \
-		-a x"${ac_cv_c_tclconfig}" = x ; then
-		for i in `ls -d C:/Tcl/lib 2>/dev/null` \
-			`ls -d C:/Progra~1/Tcl/lib 2>/dev/null` \
-			; do
-		    if test -f "$i/tclConfig.sh" ; then
-			ac_cv_c_tclconfig=`(cd $i; pwd)`
-			break
-		    fi
-		done
-	    fi
-
-	    # check in a few common install locations
-	    # Bug fix #1367779 (by Wart)
-	    if test x"${ac_cv_c_tclconfig}" = x ; then
-		for i in `ls -d ${libdir} 2>/dev/null` \
-			`ls -d ${exec_prefix}/lib 2>/dev/null` \
-			`ls -d ${prefix}/lib 2>/dev/null` \
-			`ls -d /usr/local/lib 2>/dev/null` \
-			`ls -d /usr/contrib/lib 2>/dev/null` \
-			`ls -d /usr/lib64 2>/dev/null` \
-			`ls -d /usr/lib 2>/dev/null` \
-			; do
-		    if test -f "$i/tclConfig.sh" ; then
-			ac_cv_c_tclconfig=`(cd $i; pwd)`
-			break
-		    fi
-		done
-	    fi
-
-	    # check in a few other private locations
-	    if test x"${ac_cv_c_tclconfig}" = x ; then
-		for i in \
-			${srcdir}/../tcl \
-			`ls -dr ${srcdir}/../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
-			`ls -dr ${srcdir}/../tcl[8-9].[0-9] 2>/dev/null` \
-			`ls -dr ${srcdir}/../tcl[8-9].[0-9]* 2>/dev/null` ; do
-		    if test -f "$i/unix/tclConfig.sh" ; then
-		    ac_cv_c_tclconfig=`(cd $i/unix; pwd)`
-		    break
-		fi
-		done
-	    fi
-	
-fi
-
-
-	if test x"${ac_cv_c_tclconfig}" = x ; then
-	    TCL_BIN_DIR="# no Tcl configs found"
-	    { echo "$as_me:$LINENO: WARNING: Can't find Tcl configuration definitions" >&5
-echo "$as_me: WARNING: Can't find Tcl configuration definitions" >&2;}
-	    exit 0
-	else
-	    no_tcl=
-	    TCL_BIN_DIR=${ac_cv_c_tclconfig}
-	    { echo "$as_me:$LINENO: result: found ${TCL_BIN_DIR}/tclConfig.sh" >&5
-echo "${ECHO_T}found ${TCL_BIN_DIR}/tclConfig.sh" >&6; }
-	fi
-    fi
-
-
-    { echo "$as_me:$LINENO: checking for existence of ${TCL_BIN_DIR}/tclConfig.sh" >&5
-echo $ECHO_N "checking for existence of ${TCL_BIN_DIR}/tclConfig.sh... $ECHO_C" >&6; }
-
-    if test -f "${TCL_BIN_DIR}/tclConfig.sh" ; then
-        { echo "$as_me:$LINENO: result: loading" >&5
-echo "${ECHO_T}loading" >&6; }
-	. "${TCL_BIN_DIR}/tclConfig.sh"
-    else
-        { echo "$as_me:$LINENO: result: could not find ${TCL_BIN_DIR}/tclConfig.sh" >&5
-echo "${ECHO_T}could not find ${TCL_BIN_DIR}/tclConfig.sh" >&6; }
-    fi
-
-    # eval is required to do the TCL_DBGX substitution
-    eval "TCL_LIB_FILE=\"${TCL_LIB_FILE}\""
-    eval "TCL_STUB_LIB_FILE=\"${TCL_STUB_LIB_FILE}\""
-
-    # If the TCL_BIN_DIR is the build directory (not the install directory),
-    # then set the common variable name to the value of the build variables.
-    # For example, the variable TCL_LIB_SPEC will be set to the value
-    # of TCL_BUILD_LIB_SPEC. An extension should make use of TCL_LIB_SPEC
-    # instead of TCL_BUILD_LIB_SPEC since it will work with both an
-    # installed and uninstalled version of Tcl.
-    if test -f "${TCL_BIN_DIR}/Makefile" ; then
-        TCL_LIB_SPEC=${TCL_BUILD_LIB_SPEC}
-        TCL_STUB_LIB_SPEC=${TCL_BUILD_STUB_LIB_SPEC}
-        TCL_STUB_LIB_PATH=${TCL_BUILD_STUB_LIB_PATH}
-    elif test "`uname -s`" = "Darwin"; then
-	# If Tcl was built as a framework, attempt to use the libraries
-	# from the framework at the given location so that linking works
-	# against Tcl.framework installed in an arbitary location.
-	case ${TCL_DEFS} in
-	    *TCL_FRAMEWORK*)
-		if test -f "${TCL_BIN_DIR}/${TCL_LIB_FILE}"; then
-		    for i in "`cd ${TCL_BIN_DIR}; pwd`" \
-			     "`cd ${TCL_BIN_DIR}/../..; pwd`"; do
-			if test "`basename "$i"`" = "${TCL_LIB_FILE}.framework"; then
-			    TCL_LIB_SPEC="-F`dirname "$i"` -framework ${TCL_LIB_FILE}"
-			    break
-			fi
-		    done
-		fi
-		if test -f "${TCL_BIN_DIR}/${TCL_STUB_LIB_FILE}"; then
-		    TCL_STUB_LIB_SPEC="-L${TCL_BIN_DIR} ${TCL_STUB_LIB_FLAG}"
-		    TCL_STUB_LIB_PATH="${TCL_BIN_DIR}/${TCL_STUB_LIB_FILE}"
-		fi
-		;;
-	esac
-    fi
-
-    # eval is required to do the TCL_DBGX substitution
-    eval "TCL_LIB_FLAG=\"${TCL_LIB_FLAG}\""
-    eval "TCL_LIB_SPEC=\"${TCL_LIB_SPEC}\""
-    eval "TCL_STUB_LIB_FLAG=\"${TCL_STUB_LIB_FLAG}\""
-    eval "TCL_STUB_LIB_SPEC=\"${TCL_STUB_LIB_SPEC}\""
-
-    
-    
-    
-
-    
-    
-    
-
-    
-    
-    
-
-    
-    
-    
-    
-    
-
-
-
-    if test "${prefix}" = "NONE"; then
-	prefix_default=yes
-	if test x"${TCL_PREFIX}" != x; then
-	    { echo "$as_me:$LINENO: --prefix defaulting to TCL_PREFIX ${TCL_PREFIX}" >&5
-echo "$as_me: --prefix defaulting to TCL_PREFIX ${TCL_PREFIX}" >&6;}
-	    prefix=${TCL_PREFIX}
-	else
-	    { echo "$as_me:$LINENO: --prefix defaulting to /usr/local" >&5
-echo "$as_me: --prefix defaulting to /usr/local" >&6;}
-	    prefix=/usr/local
-	fi
-    fi
-    if test "${exec_prefix}" = "NONE" -a x"${prefix_default}" = x"yes" \
-	-o x"${exec_prefix_default}" = x"yes" ; then
-	if test x"${TCL_EXEC_PREFIX}" != x; then
-	    { echo "$as_me:$LINENO: --exec-prefix defaulting to TCL_EXEC_PREFIX ${TCL_EXEC_PREFIX}" >&5
-echo "$as_me: --exec-prefix defaulting to TCL_EXEC_PREFIX ${TCL_EXEC_PREFIX}" >&6;}
-	    exec_prefix=${TCL_EXEC_PREFIX}
-	else
-	    { echo "$as_me:$LINENO: --exec-prefix defaulting to ${prefix}" >&5
-echo "$as_me: --exec-prefix defaulting to ${prefix}" >&6;}
-	    exec_prefix=$prefix
-	fi
-    fi
-
-
-
-    # Don't put any macros that use the compiler (e.g. AC_TRY_COMPILE)
-    # in this macro, they need to go into TEA_SETUP_COMPILER instead.
-
-    # If the user did not set CFLAGS, set it now to keep
-    # the AC_PROG_CC macro from adding "-g -O2".
-    if test "${CFLAGS+set}" != "set" ; then
-	CFLAGS=""
-    fi
-
-    ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-if test -n "$ac_tool_prefix"; then
-  # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
-set dummy ${ac_tool_prefix}gcc; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
-if test "${ac_cv_prog_CC+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$CC"; then
-  ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_CC="${ac_tool_prefix}gcc"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
-
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
-  { echo "$as_me:$LINENO: result: $CC" >&5
-echo "${ECHO_T}$CC" >&6; }
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_CC"; then
-  ac_ct_CC=$CC
-  # Extract the first word of "gcc", so it can be a program name with args.
-set dummy gcc; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
-if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$ac_ct_CC"; then
-  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_ac_ct_CC="gcc"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_CC=$ac_cv_prog_ac_ct_CC
-if test -n "$ac_ct_CC"; then
-  { echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
-echo "${ECHO_T}$ac_ct_CC" >&6; }
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-fi
-
-  if test "x$ac_ct_CC" = x; then
-    CC=""
-  else
-    case $cross_compiling:$ac_tool_warned in
-yes:)
-{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
-whose name does not start with the host triplet.  If you think this
-configuration is useful to you, please write to autoconf at gnu.org." >&5
-echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
-whose name does not start with the host triplet.  If you think this
-configuration is useful to you, please write to autoconf at gnu.org." >&2;}
-ac_tool_warned=yes ;;
-esac
-    CC=$ac_ct_CC
-  fi
-else
-  CC="$ac_cv_prog_CC"
-fi
-
-if test -z "$CC"; then
-          if test -n "$ac_tool_prefix"; then
-    # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
-set dummy ${ac_tool_prefix}cc; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
-if test "${ac_cv_prog_CC+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$CC"; then
-  ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_CC="${ac_tool_prefix}cc"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
-
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
-  { echo "$as_me:$LINENO: result: $CC" >&5
-echo "${ECHO_T}$CC" >&6; }
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-fi
-
-
-  fi
-fi
-if test -z "$CC"; then
-  # Extract the first word of "cc", so it can be a program name with args.
-set dummy cc; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
-if test "${ac_cv_prog_CC+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$CC"; then
-  ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-  ac_prog_rejected=no
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
-       ac_prog_rejected=yes
-       continue
-     fi
-    ac_cv_prog_CC="cc"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
-
-if test $ac_prog_rejected = yes; then
-  # We found a bogon in the path, so make sure we never use it.
-  set dummy $ac_cv_prog_CC
-  shift
-  if test $@%:@ != 0; then
-    # We chose a different compiler from the bogus one.
-    # However, it has the same basename, so the bogon will be chosen
-    # first if we set CC to just the basename; use the full file name.
-    shift
-    ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
-  fi
-fi
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
-  { echo "$as_me:$LINENO: result: $CC" >&5
-echo "${ECHO_T}$CC" >&6; }
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-fi
-
-
-fi
-if test -z "$CC"; then
-  if test -n "$ac_tool_prefix"; then
-  for ac_prog in cl.exe
-  do
-    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
-set dummy $ac_tool_prefix$ac_prog; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
-if test "${ac_cv_prog_CC+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$CC"; then
-  ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
-
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
-  { echo "$as_me:$LINENO: result: $CC" >&5
-echo "${ECHO_T}$CC" >&6; }
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-fi
-
-
-    test -n "$CC" && break
-  done
-fi
-if test -z "$CC"; then
-  ac_ct_CC=$CC
-  for ac_prog in cl.exe
-do
-  # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
-if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$ac_ct_CC"; then
-  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_ac_ct_CC="$ac_prog"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_CC=$ac_cv_prog_ac_ct_CC
-if test -n "$ac_ct_CC"; then
-  { echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
-echo "${ECHO_T}$ac_ct_CC" >&6; }
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-fi
-
-
-  test -n "$ac_ct_CC" && break
-done
-
-  if test "x$ac_ct_CC" = x; then
-    CC=""
-  else
-    case $cross_compiling:$ac_tool_warned in
-yes:)
-{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
-whose name does not start with the host triplet.  If you think this
-configuration is useful to you, please write to autoconf at gnu.org." >&5
-echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
-whose name does not start with the host triplet.  If you think this
-configuration is useful to you, please write to autoconf at gnu.org." >&2;}
-ac_tool_warned=yes ;;
-esac
-    CC=$ac_ct_CC
-  fi
-fi
-
-fi
-
-
-test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
-See \`config.log' for more details." >&5
-echo "$as_me: error: no acceptable C compiler found in \$PATH
-See \`config.log' for more details." >&2;}
-   { (exit 1); exit 1; }; }
-
-# Provide some information about the compiler.
-echo "$as_me:$LINENO: checking for C compiler version" >&5
-ac_compiler=`set X $ac_compile; echo $2`
-{ (ac_try="$ac_compiler --version >&5"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compiler --version >&5") 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }
-{ (ac_try="$ac_compiler -v >&5"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compiler -v >&5") 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }
-{ (ac_try="$ac_compiler -V >&5"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compiler -V >&5") 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }
-
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-int
-main ()
-{
-
-  ;
-  return 0;
-}
-_ACEOF
-ac_clean_files_save=$ac_clean_files
-ac_clean_files="$ac_clean_files a.out a.exe b.out"
-# Try to create an executable without -o first, disregard a.out.
-# It will help us diagnose broken compilers, and finding out an intuition
-# of exeext.
-{ echo "$as_me:$LINENO: checking for C compiler default output file name" >&5
-echo $ECHO_N "checking for C compiler default output file name... $ECHO_C" >&6; }
-ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
-#
-# List of possible output files, starting from the most likely.
-# The algorithm is not robust to junk in `.', hence go to wildcards (a.*)
-# only as a last resort.  b.out is created by i960 compilers.
-ac_files='a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out'
-#
-# The IRIX 6 linker writes into existing files which may not be
-# executable, retaining their permissions.  Remove them first so a
-# subsequent execution test works.
-ac_rmfiles=
-for ac_file in $ac_files
-do
-  case $ac_file in
-    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
-    * ) ac_rmfiles="$ac_rmfiles $ac_file";;
-  esac
-done
-rm -f $ac_rmfiles
-
-if { (ac_try="$ac_link_default"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link_default") 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; then
-  # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
-# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
-# in a Makefile.  We should not override ac_cv_exeext if it was cached,
-# so that the user can short-circuit this test for compilers unknown to
-# Autoconf.
-for ac_file in $ac_files ''
-do
-  test -f "$ac_file" || continue
-  case $ac_file in
-    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj )
-	;;
-    [ab].out )
-	# We found the default executable, but exeext='' is most
-	# certainly right.
-	break;;
-    *.* )
-        if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
-	then :; else
-	   ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
-	fi
-	# We set ac_cv_exeext here because the later test for it is not
-	# safe: cross compilers may not add the suffix if given an `-o'
-	# argument, so we may need to know it at that point already.
-	# Even if this section looks crufty: it has the advantage of
-	# actually working.
-	break;;
-    * )
-	break;;
-  esac
-done
-test "$ac_cv_exeext" = no && ac_cv_exeext=
-
-else
-  ac_file=''
-fi
-
-{ echo "$as_me:$LINENO: result: $ac_file" >&5
-echo "${ECHO_T}$ac_file" >&6; }
-if test -z "$ac_file"; then
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-{ { echo "$as_me:$LINENO: error: C compiler cannot create executables
-See \`config.log' for more details." >&5
-echo "$as_me: error: C compiler cannot create executables
-See \`config.log' for more details." >&2;}
-   { (exit 77); exit 77; }; }
-fi
-
-ac_exeext=$ac_cv_exeext
-
-# Check that the compiler produces executables we can run.  If not, either
-# the compiler is broken, or we cross compile.
-{ echo "$as_me:$LINENO: checking whether the C compiler works" >&5
-echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6; }
-# FIXME: These cross compiler hacks should be removed for Autoconf 3.0
-# If not cross compiling, check that we can run a simple program.
-if test "$cross_compiling" != yes; then
-  if { ac_try='./$ac_file'
-  { (case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_try") 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; }; then
-    cross_compiling=no
-  else
-    if test "$cross_compiling" = maybe; then
-	cross_compiling=yes
-    else
-	{ { echo "$as_me:$LINENO: error: cannot run C compiled programs.
-If you meant to cross compile, use \`--host'.
-See \`config.log' for more details." >&5
-echo "$as_me: error: cannot run C compiled programs.
-If you meant to cross compile, use \`--host'.
-See \`config.log' for more details." >&2;}
-   { (exit 1); exit 1; }; }
-    fi
-  fi
-fi
-{ echo "$as_me:$LINENO: result: yes" >&5
-echo "${ECHO_T}yes" >&6; }
-
-rm -f a.out a.exe conftest$ac_cv_exeext b.out
-ac_clean_files=$ac_clean_files_save
-# Check that the compiler produces executables we can run.  If not, either
-# the compiler is broken, or we cross compile.
-{ echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
-echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6; }
-{ echo "$as_me:$LINENO: result: $cross_compiling" >&5
-echo "${ECHO_T}$cross_compiling" >&6; }
-
-{ echo "$as_me:$LINENO: checking for suffix of executables" >&5
-echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6; }
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; then
-  # If both `conftest.exe' and `conftest' are `present' (well, observable)
-# catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
-# work properly (i.e., refer to `conftest.exe'), while it won't with
-# `rm'.
-for ac_file in conftest.exe conftest conftest.*; do
-  test -f "$ac_file" || continue
-  case $ac_file in
-    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
-    *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
-	  break;;
-    * ) break;;
-  esac
-done
-else
-  { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
-See \`config.log' for more details." >&5
-echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
-See \`config.log' for more details." >&2;}
-   { (exit 1); exit 1; }; }
-fi
-
-rm -f conftest$ac_cv_exeext
-{ echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
-echo "${ECHO_T}$ac_cv_exeext" >&6; }
-
-rm -f conftest.$ac_ext
-EXEEXT=$ac_cv_exeext
-ac_exeext=$EXEEXT
-{ echo "$as_me:$LINENO: checking for suffix of object files" >&5
-echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6; }
-if test "${ac_cv_objext+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-int
-main ()
-{
-
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.o conftest.obj
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; then
-  for ac_file in conftest.o conftest.obj conftest.*; do
-  test -f "$ac_file" || continue;
-  case $ac_file in
-    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf ) ;;
-    *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
-       break;;
-  esac
-done
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-{ { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
-See \`config.log' for more details." >&5
-echo "$as_me: error: cannot compute suffix of object files: cannot compile
-See \`config.log' for more details." >&2;}
-   { (exit 1); exit 1; }; }
-fi
-
-rm -f conftest.$ac_cv_objext conftest.$ac_ext
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
-echo "${ECHO_T}$ac_cv_objext" >&6; }
-OBJEXT=$ac_cv_objext
-ac_objext=$OBJEXT
-{ echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
-echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6; }
-if test "${ac_cv_c_compiler_gnu+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-int
-main ()
-{
-#ifndef __GNUC__
-       choke me
-#endif
-
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ac_compiler_gnu=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_compiler_gnu=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-ac_cv_c_compiler_gnu=$ac_compiler_gnu
-
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
-echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6; }
-GCC=`test $ac_compiler_gnu = yes && echo yes`
-ac_test_CFLAGS=${CFLAGS+set}
-ac_save_CFLAGS=$CFLAGS
-{ echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
-echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6; }
-if test "${ac_cv_prog_cc_g+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_save_c_werror_flag=$ac_c_werror_flag
-   ac_c_werror_flag=yes
-   ac_cv_prog_cc_g=no
-   CFLAGS="-g"
-   cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-int
-main ()
-{
-
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ac_cv_prog_cc_g=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	CFLAGS=""
-      cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-int
-main ()
-{
-
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  :
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_c_werror_flag=$ac_save_c_werror_flag
-	 CFLAGS="-g"
-	 cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-int
-main ()
-{
-
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ac_cv_prog_cc_g=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-   ac_c_werror_flag=$ac_save_c_werror_flag
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
-echo "${ECHO_T}$ac_cv_prog_cc_g" >&6; }
-if test "$ac_test_CFLAGS" = set; then
-  CFLAGS=$ac_save_CFLAGS
-elif test $ac_cv_prog_cc_g = yes; then
-  if test "$GCC" = yes; then
-    CFLAGS="-g -O2"
-  else
-    CFLAGS="-g"
-  fi
-else
-  if test "$GCC" = yes; then
-    CFLAGS="-O2"
-  else
-    CFLAGS=
-  fi
-fi
-{ echo "$as_me:$LINENO: checking for $CC option to accept ISO C89" >&5
-echo $ECHO_N "checking for $CC option to accept ISO C89... $ECHO_C" >&6; }
-if test "${ac_cv_prog_cc_c89+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_cv_prog_cc_c89=no
-ac_save_CC=$CC
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <stdarg.h>
-#include <stdio.h>
-#include <sys/types.h>
-#include <sys/stat.h>
-/* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
-struct buf { int x; };
-FILE * (*rcsopen) (struct buf *, struct stat *, int);
-static char *e (p, i)
-     char **p;
-     int i;
-{
-  return p[i];
-}
-static char *f (char * (*g) (char **, int), char **p, ...)
-{
-  char *s;
-  va_list v;
-  va_start (v,p);
-  s = g (p, va_arg (v,int));
-  va_end (v);
-  return s;
-}
-
-/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
-   function prototypes and stuff, but not '\xHH' hex character constants.
-   These don't provoke an error unfortunately, instead are silently treated
-   as 'x'.  The following induces an error, until -std is added to get
-   proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
-   array size at least.  It's necessary to write '\x00'==0 to get something
-   that's true only with -std.  */
-int osf4_cc_array ['\x00' == 0 ? 1 : -1];
-
-/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
-   inside strings and character constants.  */
-#define FOO(x) 'x'
-int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
-
-int test (int i, double x);
-struct s1 {int (*f) (int a);};
-struct s2 {int (*f) (double a);};
-int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
-int argc;
-char **argv;
-int
-main ()
-{
-return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
-  ;
-  return 0;
-}
-_ACEOF
-for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
-	-Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
-do
-  CC="$ac_save_CC $ac_arg"
-  rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ac_cv_prog_cc_c89=$ac_arg
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	
-fi
-
-rm -f core conftest.err conftest.$ac_objext 
-  test "x$ac_cv_prog_cc_c89" != "xno" && break
-done
-rm -f conftest.$ac_ext
-CC=$ac_save_CC
-
-fi
-# AC_CACHE_VAL
-case "x$ac_cv_prog_cc_c89" in
-  x)
-    { echo "$as_me:$LINENO: result: none needed" >&5
-echo "${ECHO_T}none needed" >&6; } ;;
-  xno)
-    { echo "$as_me:$LINENO: result: unsupported" >&5
-echo "${ECHO_T}unsupported" >&6; } ;;
-  *)
-    CC="$CC $ac_cv_prog_cc_c89"
-    { echo "$as_me:$LINENO: result: $ac_cv_prog_cc_c89" >&5
-echo "${ECHO_T}$ac_cv_prog_cc_c89" >&6; } ;;
-esac
-
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-    ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-{ echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
-echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6; }
-# On Suns, sometimes $CPP names a directory.
-if test -n "$CPP" && test -d "$CPP"; then
-  CPP=
-fi
-if test -z "$CPP"; then
-  if test "${ac_cv_prog_CPP+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-      # Double quotes because CPP needs to be expanded
-    for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
-    do
-      ac_preproc_ok=false
-for ac_c_preproc_warn_flag in '' yes
-do
-  # Use a header file that comes with gcc, so configuring glibc
-  # with a fresh cross-compiler works.
-  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
-  # <limits.h> exists even on freestanding compilers.
-  # On the NeXT, cc -E runs the code through the compiler's parser,
-  # not just through cpp. "Syntax error" is here to catch this case.
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-@%:@ifdef __STDC__
-@%:@ include <limits.h>
-@%:@else
-@%:@ include <assert.h>
-@%:@endif
-		     Syntax error
-_ACEOF
-if { (ac_try="$ac_cpp conftest.$ac_ext"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } >/dev/null && {
-	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       }; then
-  :
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-  # Broken: fails on valid input.
-continue
-fi
-
-rm -f conftest.err conftest.$ac_ext
-
-  # OK, works on sane cases.  Now check whether nonexistent headers
-  # can be detected and how.
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-@%:@include <ac_nonexistent.h>
-_ACEOF
-if { (ac_try="$ac_cpp conftest.$ac_ext"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } >/dev/null && {
-	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       }; then
-  # Broken: success on invalid input.
-continue
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-  # Passes both tests.
-ac_preproc_ok=:
-break
-fi
-
-rm -f conftest.err conftest.$ac_ext
-
-done
-# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
-rm -f conftest.err conftest.$ac_ext
-if $ac_preproc_ok; then
-  break
-fi
-
-    done
-    ac_cv_prog_CPP=$CPP
-  
-fi
-  CPP=$ac_cv_prog_CPP
-else
-  ac_cv_prog_CPP=$CPP
-fi
-{ echo "$as_me:$LINENO: result: $CPP" >&5
-echo "${ECHO_T}$CPP" >&6; }
-ac_preproc_ok=false
-for ac_c_preproc_warn_flag in '' yes
-do
-  # Use a header file that comes with gcc, so configuring glibc
-  # with a fresh cross-compiler works.
-  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
-  # <limits.h> exists even on freestanding compilers.
-  # On the NeXT, cc -E runs the code through the compiler's parser,
-  # not just through cpp. "Syntax error" is here to catch this case.
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-@%:@ifdef __STDC__
-@%:@ include <limits.h>
-@%:@else
-@%:@ include <assert.h>
-@%:@endif
-		     Syntax error
-_ACEOF
-if { (ac_try="$ac_cpp conftest.$ac_ext"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } >/dev/null && {
-	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       }; then
-  :
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-  # Broken: fails on valid input.
-continue
-fi
-
-rm -f conftest.err conftest.$ac_ext
-
-  # OK, works on sane cases.  Now check whether nonexistent headers
-  # can be detected and how.
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-@%:@include <ac_nonexistent.h>
-_ACEOF
-if { (ac_try="$ac_cpp conftest.$ac_ext"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } >/dev/null && {
-	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       }; then
-  # Broken: success on invalid input.
-continue
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-  # Passes both tests.
-ac_preproc_ok=:
-break
-fi
-
-rm -f conftest.err conftest.$ac_ext
-
-done
-# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
-rm -f conftest.err conftest.$ac_ext
-if $ac_preproc_ok; then
-  :
-else
-  { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
-See \`config.log' for more details." >&5
-echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
-See \`config.log' for more details." >&2;}
-   { (exit 1); exit 1; }; }
-fi
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-
-    # Find a good install program.  We prefer a C program (faster),
-# so one script is as good as another.  But avoid the broken or
-# incompatible versions:
-# SysV /etc/install, /usr/sbin/install
-# SunOS /usr/etc/install
-# IRIX /sbin/install
-# AIX /bin/install
-# AmigaOS /C/install, which installs bootblocks on floppy discs
-# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
-# AFS /usr/afsws/bin/install, which mishandles nonexistent args
-# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
-# OS/2's system install, which has a completely different semantic
-# ./install, which can be erroneously created by make from ./install.sh.
-{ echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
-echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6; }
-if test -z "$INSTALL"; then
-if test "${ac_cv_path_install+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  # Account for people who put trailing slashes in PATH elements.
-case $as_dir/ in
-  ./ | .// | /cC/* | \
-  /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
-  ?:\\/os2\\/install\\/* | ?:\\/OS2\\/INSTALL\\/* | \
-  /usr/ucb/* ) ;;
-  *)
-    # OSF1 and SCO ODT 3.0 have their own names for install.
-    # Don't use installbsd from OSF since it installs stuff as root
-    # by default.
-    for ac_prog in ginstall scoinst install; do
-      for ac_exec_ext in '' $ac_executable_extensions; do
-	if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
-	  if test $ac_prog = install &&
-	    grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
-	    # AIX install.  It has an incompatible calling convention.
-	    :
-	  elif test $ac_prog = install &&
-	    grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
-	    # program-specific install script used by HP pwplus--don't use.
-	    :
-	  else
-	    ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
-	    break 3
-	  fi
-	fi
-      done
-    done
-    ;;
-esac
-done
-IFS=$as_save_IFS
-
-
-fi
-  if test "${ac_cv_path_install+set}" = set; then
-    INSTALL=$ac_cv_path_install
-  else
-    # As a last resort, use the slow shell script.  Don't cache a
-    # value for INSTALL within a source directory, because that will
-    # break other packages using the cache if that directory is
-    # removed, or if the value is a relative name.
-    INSTALL=$ac_install_sh
-  fi
-fi
-{ echo "$as_me:$LINENO: result: $INSTALL" >&5
-echo "${ECHO_T}$INSTALL" >&6; }
-
-# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
-# It thinks the first close brace ends the variable substitution.
-test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
-
-test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
-
-test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
-
-
-    #--------------------------------------------------------------------
-    # Checks to see if the make program sets the $MAKE variable.
-    #--------------------------------------------------------------------
-
-    { echo "$as_me:$LINENO: checking whether ${MAKE-make} sets \$(MAKE)" >&5
-echo $ECHO_N "checking whether ${MAKE-make} sets \$(MAKE)... $ECHO_C" >&6; }
-set x ${MAKE-make}; ac_make=`echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
-if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.make <<\_ACEOF
-SHELL = /bin/sh
-all:
-	@echo '@@@%%%=$(MAKE)=@@@%%%'
-_ACEOF
-# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
-case `${MAKE-make} -f conftest.make 2>/dev/null` in
-  *@@@%%%=?*=@@@%%%*)
-    eval ac_cv_prog_make_${ac_make}_set=yes;;
-  *)
-    eval ac_cv_prog_make_${ac_make}_set=no;;
-esac
-rm -f conftest.make
-fi
-if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
-  { echo "$as_me:$LINENO: result: yes" >&5
-echo "${ECHO_T}yes" >&6; }
-  SET_MAKE=
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-  SET_MAKE="MAKE=${MAKE-make}"
-fi
-
-
-    #--------------------------------------------------------------------
-    # Find ranlib
-    #--------------------------------------------------------------------
-
-    if test -n "$ac_tool_prefix"; then
-  # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
-set dummy ${ac_tool_prefix}ranlib; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
-if test "${ac_cv_prog_RANLIB+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$RANLIB"; then
-  ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
-
-fi
-fi
-RANLIB=$ac_cv_prog_RANLIB
-if test -n "$RANLIB"; then
-  { echo "$as_me:$LINENO: result: $RANLIB" >&5
-echo "${ECHO_T}$RANLIB" >&6; }
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_RANLIB"; then
-  ac_ct_RANLIB=$RANLIB
-  # Extract the first word of "ranlib", so it can be a program name with args.
-set dummy ranlib; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
-if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$ac_ct_RANLIB"; then
-  ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_ac_ct_RANLIB="ranlib"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
-if test -n "$ac_ct_RANLIB"; then
-  { echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
-echo "${ECHO_T}$ac_ct_RANLIB" >&6; }
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-fi
-
-  if test "x$ac_ct_RANLIB" = x; then
-    RANLIB=":"
-  else
-    case $cross_compiling:$ac_tool_warned in
-yes:)
-{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
-whose name does not start with the host triplet.  If you think this
-configuration is useful to you, please write to autoconf at gnu.org." >&5
-echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
-whose name does not start with the host triplet.  If you think this
-configuration is useful to you, please write to autoconf at gnu.org." >&2;}
-ac_tool_warned=yes ;;
-esac
-    RANLIB=$ac_ct_RANLIB
-  fi
-else
-  RANLIB="$ac_cv_prog_RANLIB"
-fi
-
-
-    #--------------------------------------------------------------------
-    # Determines the correct binary file extension (.o, .obj, .exe etc.)
-    #--------------------------------------------------------------------
-
-    
-    
-
-
-
-{ echo "$as_me:$LINENO: checking for grep that handles long lines and -e" >&5
-echo $ECHO_N "checking for grep that handles long lines and -e... $ECHO_C" >&6; }
-if test "${ac_cv_path_GREP+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  # Extract the first word of "grep ggrep" to use in msg output
-if test -z "$GREP"; then
-set dummy grep ggrep; ac_prog_name=$2
-if test "${ac_cv_path_GREP+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_path_GREP_found=false
-# Loop through the user's path and test for each of PROGNAME-LIST
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_prog in grep ggrep; do
-  for ac_exec_ext in '' $ac_executable_extensions; do
-    ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
-    { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
-    # Check for GNU ac_path_GREP and select it if it is found.
-  # Check for GNU $ac_path_GREP
-case `"$ac_path_GREP" --version 2>&1` in
-*GNU*)
-  ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
-*)
-  ac_count=0
-  echo $ECHO_N "0123456789$ECHO_C" >"conftest.in"
-  while :
-  do
-    cat "conftest.in" "conftest.in" >"conftest.tmp"
-    mv "conftest.tmp" "conftest.in"
-    cp "conftest.in" "conftest.nl"
-    echo 'GREP' >> "conftest.nl"
-    "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
-    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
-    ac_count=`expr $ac_count + 1`
-    if test $ac_count -gt ${ac_path_GREP_max-0}; then
-      # Best one so far, save it but keep looking for a better one
-      ac_cv_path_GREP="$ac_path_GREP"
-      ac_path_GREP_max=$ac_count
-    fi
-    # 10*(2^10) chars as input seems more than enough
-    test $ac_count -gt 10 && break
-  done
-  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
-esac
-
-
-    $ac_path_GREP_found && break 3
-  done
-done
-
-done
-IFS=$as_save_IFS
-
-
-fi
-
-GREP="$ac_cv_path_GREP"
-if test -z "$GREP"; then
-  { { echo "$as_me:$LINENO: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
-echo "$as_me: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
-   { (exit 1); exit 1; }; }
-fi
-
-else
-  ac_cv_path_GREP=$GREP
-fi
-
-
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_path_GREP" >&5
-echo "${ECHO_T}$ac_cv_path_GREP" >&6; }
- GREP="$ac_cv_path_GREP"
- 
-
-{ echo "$as_me:$LINENO: checking for egrep" >&5
-echo $ECHO_N "checking for egrep... $ECHO_C" >&6; }
-if test "${ac_cv_path_EGREP+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
-   then ac_cv_path_EGREP="$GREP -E"
-   else
-     # Extract the first word of "egrep" to use in msg output
-if test -z "$EGREP"; then
-set dummy egrep; ac_prog_name=$2
-if test "${ac_cv_path_EGREP+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_path_EGREP_found=false
-# Loop through the user's path and test for each of PROGNAME-LIST
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_prog in egrep; do
-  for ac_exec_ext in '' $ac_executable_extensions; do
-    ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
-    { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
-    # Check for GNU ac_path_EGREP and select it if it is found.
-  # Check for GNU $ac_path_EGREP
-case `"$ac_path_EGREP" --version 2>&1` in
-*GNU*)
-  ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
-*)
-  ac_count=0
-  echo $ECHO_N "0123456789$ECHO_C" >"conftest.in"
-  while :
-  do
-    cat "conftest.in" "conftest.in" >"conftest.tmp"
-    mv "conftest.tmp" "conftest.in"
-    cp "conftest.in" "conftest.nl"
-    echo 'EGREP' >> "conftest.nl"
-    "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
-    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
-    ac_count=`expr $ac_count + 1`
-    if test $ac_count -gt ${ac_path_EGREP_max-0}; then
-      # Best one so far, save it but keep looking for a better one
-      ac_cv_path_EGREP="$ac_path_EGREP"
-      ac_path_EGREP_max=$ac_count
-    fi
-    # 10*(2^10) chars as input seems more than enough
-    test $ac_count -gt 10 && break
-  done
-  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
-esac
-
-
-    $ac_path_EGREP_found && break 3
-  done
-done
-
-done
-IFS=$as_save_IFS
-
-
-fi
-
-EGREP="$ac_cv_path_EGREP"
-if test -z "$EGREP"; then
-  { { echo "$as_me:$LINENO: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
-echo "$as_me: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
-   { (exit 1); exit 1; }; }
-fi
-
-else
-  ac_cv_path_EGREP=$EGREP
-fi
-
-
-   fi
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_path_EGREP" >&5
-echo "${ECHO_T}$ac_cv_path_EGREP" >&6; }
- EGREP="$ac_cv_path_EGREP"
- 
-
-{ echo "$as_me:$LINENO: checking for ANSI C header files" >&5
-echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6; }
-if test "${ac_cv_header_stdc+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <stdlib.h>
-#include <stdarg.h>
-#include <string.h>
-#include <float.h>
-
-int
-main ()
-{
-
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ac_cv_header_stdc=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_header_stdc=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-
-if test $ac_cv_header_stdc = yes; then
-  # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <string.h>
-
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-  $EGREP "memchr" >/dev/null 2>&1; then
-  :
-else
-  ac_cv_header_stdc=no
-fi
-rm -f conftest*
-
-fi
-
-if test $ac_cv_header_stdc = yes; then
-  # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <stdlib.h>
-
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-  $EGREP "free" >/dev/null 2>&1; then
-  :
-else
-  ac_cv_header_stdc=no
-fi
-rm -f conftest*
-
-fi
-
-if test $ac_cv_header_stdc = yes; then
-  # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
-  if test "$cross_compiling" = yes; then
-  :
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <ctype.h>
-#include <stdlib.h>
-#if ((' ' & 0x0FF) == 0x020)
-# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
-# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
-#else
-# define ISLOWER(c) \
-		   (('a' <= (c) && (c) <= 'i') \
-		     || ('j' <= (c) && (c) <= 'r') \
-		     || ('s' <= (c) && (c) <= 'z'))
-# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
-#endif
-
-#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
-int
-main ()
-{
-  int i;
-  for (i = 0; i < 256; i++)
-    if (XOR (islower (i), ISLOWER (i))
-	|| toupper (i) != TOUPPER (i))
-      return 2;
-  return 0;
-}
-_ACEOF
-rm -f conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
-  { (case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_try") 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; }; then
-  :
-else
-  echo "$as_me: program exited with status $ac_status" >&5
-echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-( exit $ac_status )
-ac_cv_header_stdc=no
-fi
-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
-fi
-
-
-fi
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
-echo "${ECHO_T}$ac_cv_header_stdc" >&6; }
-if test $ac_cv_header_stdc = yes; then
-  
-cat >>confdefs.h <<\_ACEOF
-@%:@define STDC_HEADERS 1
-_ACEOF
-
-fi
-
-# On IRIX 5.3, sys/types and inttypes.h are conflicting.
-
-
-
-
-
-
-
-
-
-for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
-		  inttypes.h stdint.h unistd.h
-do
-as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
-{ echo "$as_me:$LINENO: checking for $ac_header" >&5
-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
-if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-$ac_includes_default
-
-@%:@include <$ac_header>
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  eval "$as_ac_Header=yes"
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	eval "$as_ac_Header=no"
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-ac_res=`eval echo '${'$as_ac_Header'}'`
-	       { echo "$as_me:$LINENO: result: $ac_res" >&5
-echo "${ECHO_T}$ac_res" >&6; }
-if test `eval echo '${'$as_ac_Header'}'` = yes; then
-  cat >>confdefs.h <<_ACEOF
-@%:@define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
-_ACEOF
- 
-fi
-
-done
-
-
-
-    # Any macros that use the compiler (e.g. AC_TRY_COMPILE) have to go here.
-    
-
-    #------------------------------------------------------------------------
-    # If we're using GCC, see if the compiler understands -pipe. If so, use it.
-    # It makes compiling go faster.  (This is only a performance feature.)
-    #------------------------------------------------------------------------
-
-    if test -z "$no_pipe" -a -n "$GCC"; then
-	{ echo "$as_me:$LINENO: checking if the compiler understands -pipe" >&5
-echo $ECHO_N "checking if the compiler understands -pipe... $ECHO_C" >&6; }
-if test "${tcl_cv_cc_pipe+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  
-	    hold_cflags=$CFLAGS; CFLAGS="$CFLAGS -pipe"
-	    cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-int
-main ()
-{
-
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  tcl_cv_cc_pipe=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	tcl_cv_cc_pipe=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-	    CFLAGS=$hold_cflags
-fi
-{ echo "$as_me:$LINENO: result: $tcl_cv_cc_pipe" >&5
-echo "${ECHO_T}$tcl_cv_cc_pipe" >&6; }
-	if test $tcl_cv_cc_pipe = yes; then
-	    CFLAGS="$CFLAGS -pipe"
-	fi
-    fi
-
-    #--------------------------------------------------------------------
-    # Common compiler flag setup
-    #--------------------------------------------------------------------
-
-    { echo "$as_me:$LINENO: checking whether byte ordering is bigendian" >&5
-echo $ECHO_N "checking whether byte ordering is bigendian... $ECHO_C" >&6; }
-if test "${ac_cv_c_bigendian+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  # See if sys/param.h defines the BYTE_ORDER macro.
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <sys/types.h>
-#include <sys/param.h>
-
-int
-main ()
-{
-#if  ! (defined BYTE_ORDER && defined BIG_ENDIAN && defined LITTLE_ENDIAN \
-	&& BYTE_ORDER && BIG_ENDIAN && LITTLE_ENDIAN)
- bogus endian macros
-#endif
-
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  # It does; now see whether it defined to BIG_ENDIAN or not.
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <sys/types.h>
-#include <sys/param.h>
-
-int
-main ()
-{
-#if BYTE_ORDER != BIG_ENDIAN
- not big endian
-#endif
-
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ac_cv_c_bigendian=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_c_bigendian=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	# It does not; compile a test program.
-if test "$cross_compiling" = yes; then
-  # try to guess the endianness by grepping values into an object file
-  ac_cv_c_bigendian=unknown
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-short int ascii_mm[] = { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
-short int ascii_ii[] = { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
-void _ascii () { char *s = (char *) ascii_mm; s = (char *) ascii_ii; }
-short int ebcdic_ii[] = { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
-short int ebcdic_mm[] = { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
-void _ebcdic () { char *s = (char *) ebcdic_mm; s = (char *) ebcdic_ii; }
-int
-main ()
-{
- _ascii (); _ebcdic (); 
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  if grep BIGenDianSyS conftest.$ac_objext >/dev/null ; then
-  ac_cv_c_bigendian=yes
-fi
-if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
-  if test "$ac_cv_c_bigendian" = unknown; then
-    ac_cv_c_bigendian=no
-  else
-    # finding both strings is unlikely to happen, but who knows?
-    ac_cv_c_bigendian=unknown
-  fi
-fi
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-$ac_includes_default
-int
-main ()
-{
-
-  /* Are we little or big endian?  From Harbison&Steele.  */
-  union
-  {
-    long int l;
-    char c[sizeof (long int)];
-  } u;
-  u.l = 1;
-  return u.c[sizeof (long int) - 1] == 1;
-
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
-  { (case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_try") 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; }; then
-  ac_cv_c_bigendian=no
-else
-  echo "$as_me: program exited with status $ac_status" >&5
-echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-( exit $ac_status )
-ac_cv_c_bigendian=yes
-fi
-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
-fi
-
-
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_c_bigendian" >&5
-echo "${ECHO_T}$ac_cv_c_bigendian" >&6; }
-case $ac_cv_c_bigendian in
-  yes)
-    
-cat >>confdefs.h <<\_ACEOF
-@%:@define WORDS_BIGENDIAN 1
-_ACEOF
- ;;
-  no)
-     ;;
-  *)
-    { { echo "$as_me:$LINENO: error: unknown endianness
-presetting ac_cv_c_bigendian=no (or yes) will help" >&5
-echo "$as_me: error: unknown endianness
-presetting ac_cv_c_bigendian=no (or yes) will help" >&2;}
-   { (exit 1); exit 1; }; } ;;
-esac
-
-    if test "${TEA_PLATFORM}" = "unix" ; then
-	
-    #--------------------------------------------------------------------
-    # On a few very rare systems, all of the libm.a stuff is
-    # already in libc.a.  Set compiler flags accordingly.
-    # Also, Linux requires the "ieee" library for math to work
-    # right (and it must appear before "-lm").
-    #--------------------------------------------------------------------
-
-    { echo "$as_me:$LINENO: checking for sin" >&5
-echo $ECHO_N "checking for sin... $ECHO_C" >&6; }
-if test "${ac_cv_func_sin+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-/* Define sin to an innocuous variant, in case <limits.h> declares sin.
-   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
-#define sin innocuous_sin
-
-/* System header to define __stub macros and hopefully few prototypes,
-    which can conflict with char sin (); below.
-    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
-    <limits.h> exists even on freestanding compilers.  */
-
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
-
-#undef sin
-
-/* Override any GCC internal prototype to avoid an error.
-   Use char because int might match the return type of a GCC
-   builtin and then its argument prototype would still apply.  */
-#ifdef __cplusplus
-extern "C"
-#endif
-char sin ();
-/* The GNU C library defines this for functions which it implements
-    to always fail with ENOSYS.  Some functions are actually named
-    something starting with __ and the normal name is an alias.  */
-#if defined __stub_sin || defined __stub___sin
-choke me
-#endif
-
-int
-main ()
-{
-return sin ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_func_sin=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_func_sin=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_func_sin" >&5
-echo "${ECHO_T}$ac_cv_func_sin" >&6; }
-if test $ac_cv_func_sin = yes; then
-  MATH_LIBS=""
-else
-  MATH_LIBS="-lm"
-fi
-
-    { echo "$as_me:$LINENO: checking for main in -lieee" >&5
-echo $ECHO_N "checking for main in -lieee... $ECHO_C" >&6; }
-if test "${ac_cv_lib_ieee_main+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-lieee  $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-
-int
-main ()
-{
-return main ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_ieee_main=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_lib_ieee_main=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_ieee_main" >&5
-echo "${ECHO_T}$ac_cv_lib_ieee_main" >&6; }
-if test $ac_cv_lib_ieee_main = yes; then
-  MATH_LIBS="-lieee $MATH_LIBS"
-fi
-
-
-    #--------------------------------------------------------------------
-    # Interactive UNIX requires -linet instead of -lsocket, plus it
-    # needs net/errno.h to define the socket-related error codes.
-    #--------------------------------------------------------------------
-
-    { echo "$as_me:$LINENO: checking for main in -linet" >&5
-echo $ECHO_N "checking for main in -linet... $ECHO_C" >&6; }
-if test "${ac_cv_lib_inet_main+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-linet  $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-
-int
-main ()
-{
-return main ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_inet_main=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_lib_inet_main=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_inet_main" >&5
-echo "${ECHO_T}$ac_cv_lib_inet_main" >&6; }
-if test $ac_cv_lib_inet_main = yes; then
-  LIBS="$LIBS -linet"
-fi
-
-    if test "${ac_cv_header_net_errno_h+set}" = set; then
-  { echo "$as_me:$LINENO: checking for net/errno.h" >&5
-echo $ECHO_N "checking for net/errno.h... $ECHO_C" >&6; }
-if test "${ac_cv_header_net_errno_h+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_net_errno_h" >&5
-echo "${ECHO_T}$ac_cv_header_net_errno_h" >&6; }
-else
-  # Is the header compilable?
-{ echo "$as_me:$LINENO: checking net/errno.h usability" >&5
-echo $ECHO_N "checking net/errno.h usability... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-$ac_includes_default
-@%:@include <net/errno.h>
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ac_header_compiler=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_header_compiler=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
-echo "${ECHO_T}$ac_header_compiler" >&6; }
-
-# Is the header present?
-{ echo "$as_me:$LINENO: checking net/errno.h presence" >&5
-echo $ECHO_N "checking net/errno.h presence... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-@%:@include <net/errno.h>
-_ACEOF
-if { (ac_try="$ac_cpp conftest.$ac_ext"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } >/dev/null && {
-	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       }; then
-  ac_header_preproc=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-  ac_header_preproc=no
-fi
-
-rm -f conftest.err conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
-echo "${ECHO_T}$ac_header_preproc" >&6; }
-
-# So?  What about this header?
-case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
-  yes:no: )
-    { echo "$as_me:$LINENO: WARNING: net/errno.h: accepted by the compiler, rejected by the preprocessor!" >&5
-echo "$as_me: WARNING: net/errno.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
-    { echo "$as_me:$LINENO: WARNING: net/errno.h: proceeding with the compiler's result" >&5
-echo "$as_me: WARNING: net/errno.h: proceeding with the compiler's result" >&2;}
-    ac_header_preproc=yes
-    ;;
-  no:yes:* )
-    { echo "$as_me:$LINENO: WARNING: net/errno.h: present but cannot be compiled" >&5
-echo "$as_me: WARNING: net/errno.h: present but cannot be compiled" >&2;}
-    { echo "$as_me:$LINENO: WARNING: net/errno.h:     check for missing prerequisite headers?" >&5
-echo "$as_me: WARNING: net/errno.h:     check for missing prerequisite headers?" >&2;}
-    { echo "$as_me:$LINENO: WARNING: net/errno.h: see the Autoconf documentation" >&5
-echo "$as_me: WARNING: net/errno.h: see the Autoconf documentation" >&2;}
-    { echo "$as_me:$LINENO: WARNING: net/errno.h:     section \"Present But Cannot Be Compiled\"" >&5
-echo "$as_me: WARNING: net/errno.h:     section \"Present But Cannot Be Compiled\"" >&2;}
-    { echo "$as_me:$LINENO: WARNING: net/errno.h: proceeding with the preprocessor's result" >&5
-echo "$as_me: WARNING: net/errno.h: proceeding with the preprocessor's result" >&2;}
-    { echo "$as_me:$LINENO: WARNING: net/errno.h: in the future, the compiler will take precedence" >&5
-echo "$as_me: WARNING: net/errno.h: in the future, the compiler will take precedence" >&2;}
-    
-    ;;
-esac
-{ echo "$as_me:$LINENO: checking for net/errno.h" >&5
-echo $ECHO_N "checking for net/errno.h... $ECHO_C" >&6; }
-if test "${ac_cv_header_net_errno_h+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_cv_header_net_errno_h=$ac_header_preproc
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_net_errno_h" >&5
-echo "${ECHO_T}$ac_cv_header_net_errno_h" >&6; }
-
-fi
-if test $ac_cv_header_net_errno_h = yes; then
-  
-	
-cat >>confdefs.h <<\_ACEOF
-@%:@define HAVE_NET_ERRNO_H 1
-_ACEOF
-
-fi
-
-
-
-    #--------------------------------------------------------------------
-    #	Check for the existence of the -lsocket and -lnsl libraries.
-    #	The order here is important, so that they end up in the right
-    #	order in the command line generated by make.  Here are some
-    #	special considerations:
-    #	1. Use "connect" and "accept" to check for -lsocket, and
-    #	   "gethostbyname" to check for -lnsl.
-    #	2. Use each function name only once:  can't redo a check because
-    #	   autoconf caches the results of the last check and won't redo it.
-    #	3. Use -lnsl and -lsocket only if they supply procedures that
-    #	   aren't already present in the normal libraries.  This is because
-    #	   IRIX 5.2 has libraries, but they aren't needed and they're
-    #	   bogus:  they goof up name resolution if used.
-    #	4. On some SVR4 systems, can't use -lsocket without -lnsl too.
-    #	   To get around this problem, check for both libraries together
-    #	   if -lsocket doesn't work by itself.
-    #--------------------------------------------------------------------
-
-    tcl_checkBoth=0
-    { echo "$as_me:$LINENO: checking for connect" >&5
-echo $ECHO_N "checking for connect... $ECHO_C" >&6; }
-if test "${ac_cv_func_connect+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-/* Define connect to an innocuous variant, in case <limits.h> declares connect.
-   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
-#define connect innocuous_connect
-
-/* System header to define __stub macros and hopefully few prototypes,
-    which can conflict with char connect (); below.
-    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
-    <limits.h> exists even on freestanding compilers.  */
-
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
-
-#undef connect
-
-/* Override any GCC internal prototype to avoid an error.
-   Use char because int might match the return type of a GCC
-   builtin and then its argument prototype would still apply.  */
-#ifdef __cplusplus
-extern "C"
-#endif
-char connect ();
-/* The GNU C library defines this for functions which it implements
-    to always fail with ENOSYS.  Some functions are actually named
-    something starting with __ and the normal name is an alias.  */
-#if defined __stub_connect || defined __stub___connect
-choke me
-#endif
-
-int
-main ()
-{
-return connect ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_func_connect=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_func_connect=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_func_connect" >&5
-echo "${ECHO_T}$ac_cv_func_connect" >&6; }
-if test $ac_cv_func_connect = yes; then
-  tcl_checkSocket=0
-else
-  tcl_checkSocket=1
-fi
-
-    if test "$tcl_checkSocket" = 1; then
-	{ echo "$as_me:$LINENO: checking for setsockopt" >&5
-echo $ECHO_N "checking for setsockopt... $ECHO_C" >&6; }
-if test "${ac_cv_func_setsockopt+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-/* Define setsockopt to an innocuous variant, in case <limits.h> declares setsockopt.
-   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
-#define setsockopt innocuous_setsockopt
-
-/* System header to define __stub macros and hopefully few prototypes,
-    which can conflict with char setsockopt (); below.
-    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
-    <limits.h> exists even on freestanding compilers.  */
-
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
-
-#undef setsockopt
-
-/* Override any GCC internal prototype to avoid an error.
-   Use char because int might match the return type of a GCC
-   builtin and then its argument prototype would still apply.  */
-#ifdef __cplusplus
-extern "C"
-#endif
-char setsockopt ();
-/* The GNU C library defines this for functions which it implements
-    to always fail with ENOSYS.  Some functions are actually named
-    something starting with __ and the normal name is an alias.  */
-#if defined __stub_setsockopt || defined __stub___setsockopt
-choke me
-#endif
-
-int
-main ()
-{
-return setsockopt ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_func_setsockopt=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_func_setsockopt=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_func_setsockopt" >&5
-echo "${ECHO_T}$ac_cv_func_setsockopt" >&6; }
-if test $ac_cv_func_setsockopt = yes; then
-  :
-else
-  { echo "$as_me:$LINENO: checking for setsockopt in -lsocket" >&5
-echo $ECHO_N "checking for setsockopt in -lsocket... $ECHO_C" >&6; }
-if test "${ac_cv_lib_socket_setsockopt+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-lsocket  $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-/* Override any GCC internal prototype to avoid an error.
-   Use char because int might match the return type of a GCC
-   builtin and then its argument prototype would still apply.  */
-#ifdef __cplusplus
-extern "C"
-#endif
-char setsockopt ();
-int
-main ()
-{
-return setsockopt ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_socket_setsockopt=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_lib_socket_setsockopt=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_socket_setsockopt" >&5
-echo "${ECHO_T}$ac_cv_lib_socket_setsockopt" >&6; }
-if test $ac_cv_lib_socket_setsockopt = yes; then
-  LIBS="$LIBS -lsocket"
-else
-  tcl_checkBoth=1
-fi
-
-fi
-
-    fi
-    if test "$tcl_checkBoth" = 1; then
-	tk_oldLibs=$LIBS
-	LIBS="$LIBS -lsocket -lnsl"
-	{ echo "$as_me:$LINENO: checking for accept" >&5
-echo $ECHO_N "checking for accept... $ECHO_C" >&6; }
-if test "${ac_cv_func_accept+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-/* Define accept to an innocuous variant, in case <limits.h> declares accept.
-   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
-#define accept innocuous_accept
-
-/* System header to define __stub macros and hopefully few prototypes,
-    which can conflict with char accept (); below.
-    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
-    <limits.h> exists even on freestanding compilers.  */
-
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
-
-#undef accept
-
-/* Override any GCC internal prototype to avoid an error.
-   Use char because int might match the return type of a GCC
-   builtin and then its argument prototype would still apply.  */
-#ifdef __cplusplus
-extern "C"
-#endif
-char accept ();
-/* The GNU C library defines this for functions which it implements
-    to always fail with ENOSYS.  Some functions are actually named
-    something starting with __ and the normal name is an alias.  */
-#if defined __stub_accept || defined __stub___accept
-choke me
-#endif
-
-int
-main ()
-{
-return accept ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_func_accept=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_func_accept=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_func_accept" >&5
-echo "${ECHO_T}$ac_cv_func_accept" >&6; }
-if test $ac_cv_func_accept = yes; then
-  tcl_checkNsl=0
-else
-  LIBS=$tk_oldLibs
-fi
-
-    fi
-    { echo "$as_me:$LINENO: checking for gethostbyname" >&5
-echo $ECHO_N "checking for gethostbyname... $ECHO_C" >&6; }
-if test "${ac_cv_func_gethostbyname+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-/* Define gethostbyname to an innocuous variant, in case <limits.h> declares gethostbyname.
-   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
-#define gethostbyname innocuous_gethostbyname
-
-/* System header to define __stub macros and hopefully few prototypes,
-    which can conflict with char gethostbyname (); below.
-    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
-    <limits.h> exists even on freestanding compilers.  */
-
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
-
-#undef gethostbyname
-
-/* Override any GCC internal prototype to avoid an error.
-   Use char because int might match the return type of a GCC
-   builtin and then its argument prototype would still apply.  */
-#ifdef __cplusplus
-extern "C"
-#endif
-char gethostbyname ();
-/* The GNU C library defines this for functions which it implements
-    to always fail with ENOSYS.  Some functions are actually named
-    something starting with __ and the normal name is an alias.  */
-#if defined __stub_gethostbyname || defined __stub___gethostbyname
-choke me
-#endif
-
-int
-main ()
-{
-return gethostbyname ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_func_gethostbyname=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_func_gethostbyname=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_func_gethostbyname" >&5
-echo "${ECHO_T}$ac_cv_func_gethostbyname" >&6; }
-if test $ac_cv_func_gethostbyname = yes; then
-  :
-else
-  { echo "$as_me:$LINENO: checking for gethostbyname in -lnsl" >&5
-echo $ECHO_N "checking for gethostbyname in -lnsl... $ECHO_C" >&6; }
-if test "${ac_cv_lib_nsl_gethostbyname+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-lnsl  $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-/* Override any GCC internal prototype to avoid an error.
-   Use char because int might match the return type of a GCC
-   builtin and then its argument prototype would still apply.  */
-#ifdef __cplusplus
-extern "C"
-#endif
-char gethostbyname ();
-int
-main ()
-{
-return gethostbyname ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_nsl_gethostbyname=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_lib_nsl_gethostbyname=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_nsl_gethostbyname" >&5
-echo "${ECHO_T}$ac_cv_lib_nsl_gethostbyname" >&6; }
-if test $ac_cv_lib_nsl_gethostbyname = yes; then
-  LIBS="$LIBS -lnsl"
-fi
-
-fi
-
-    
-    # Don't perform the eval of the libraries here because DL_LIBS
-    # won't be set until we call TEA_CONFIG_CFLAGS
-
-    TCL_LIBS='${DL_LIBS} ${LIBS} ${MATH_LIBS}'
-    
-    
-
-	
-    { echo "$as_me:$LINENO: checking dirent.h" >&5
-echo $ECHO_N "checking dirent.h... $ECHO_C" >&6; }
-if test "${tcl_cv_dirent_h+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  
-    cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <sys/types.h>
-#include <dirent.h>
-int
-main ()
-{
-
-#ifndef _POSIX_SOURCE
-#   ifdef __Lynx__
-	/*
-	 * Generate compilation error to make the test fail:  Lynx headers
-	 * are only valid if really in the POSIX environment.
-	 */
-
-	missing_procedure();
-#   endif
-#endif
-DIR *d;
-struct dirent *entryPtr;
-char *p;
-d = opendir("foobar");
-entryPtr = readdir(d);
-p = entryPtr->d_name;
-closedir(d);
-
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  tcl_cv_dirent_h=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	tcl_cv_dirent_h=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-fi
-{ echo "$as_me:$LINENO: result: $tcl_cv_dirent_h" >&5
-echo "${ECHO_T}$tcl_cv_dirent_h" >&6; }
-
-    if test $tcl_cv_dirent_h = no; then
-	
-cat >>confdefs.h <<\_ACEOF
-@%:@define NO_DIRENT_H 1
-_ACEOF
-
-    fi
-
-    if test "${ac_cv_header_errno_h+set}" = set; then
-  { echo "$as_me:$LINENO: checking for errno.h" >&5
-echo $ECHO_N "checking for errno.h... $ECHO_C" >&6; }
-if test "${ac_cv_header_errno_h+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_errno_h" >&5
-echo "${ECHO_T}$ac_cv_header_errno_h" >&6; }
-else
-  # Is the header compilable?
-{ echo "$as_me:$LINENO: checking errno.h usability" >&5
-echo $ECHO_N "checking errno.h usability... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-$ac_includes_default
-@%:@include <errno.h>
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ac_header_compiler=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_header_compiler=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
-echo "${ECHO_T}$ac_header_compiler" >&6; }
-
-# Is the header present?
-{ echo "$as_me:$LINENO: checking errno.h presence" >&5
-echo $ECHO_N "checking errno.h presence... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-@%:@include <errno.h>
-_ACEOF
-if { (ac_try="$ac_cpp conftest.$ac_ext"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } >/dev/null && {
-	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       }; then
-  ac_header_preproc=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-  ac_header_preproc=no
-fi
-
-rm -f conftest.err conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
-echo "${ECHO_T}$ac_header_preproc" >&6; }
-
-# So?  What about this header?
-case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
-  yes:no: )
-    { echo "$as_me:$LINENO: WARNING: errno.h: accepted by the compiler, rejected by the preprocessor!" >&5
-echo "$as_me: WARNING: errno.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
-    { echo "$as_me:$LINENO: WARNING: errno.h: proceeding with the compiler's result" >&5
-echo "$as_me: WARNING: errno.h: proceeding with the compiler's result" >&2;}
-    ac_header_preproc=yes
-    ;;
-  no:yes:* )
-    { echo "$as_me:$LINENO: WARNING: errno.h: present but cannot be compiled" >&5
-echo "$as_me: WARNING: errno.h: present but cannot be compiled" >&2;}
-    { echo "$as_me:$LINENO: WARNING: errno.h:     check for missing prerequisite headers?" >&5
-echo "$as_me: WARNING: errno.h:     check for missing prerequisite headers?" >&2;}
-    { echo "$as_me:$LINENO: WARNING: errno.h: see the Autoconf documentation" >&5
-echo "$as_me: WARNING: errno.h: see the Autoconf documentation" >&2;}
-    { echo "$as_me:$LINENO: WARNING: errno.h:     section \"Present But Cannot Be Compiled\"" >&5
-echo "$as_me: WARNING: errno.h:     section \"Present But Cannot Be Compiled\"" >&2;}
-    { echo "$as_me:$LINENO: WARNING: errno.h: proceeding with the preprocessor's result" >&5
-echo "$as_me: WARNING: errno.h: proceeding with the preprocessor's result" >&2;}
-    { echo "$as_me:$LINENO: WARNING: errno.h: in the future, the compiler will take precedence" >&5
-echo "$as_me: WARNING: errno.h: in the future, the compiler will take precedence" >&2;}
-    
-    ;;
-esac
-{ echo "$as_me:$LINENO: checking for errno.h" >&5
-echo $ECHO_N "checking for errno.h... $ECHO_C" >&6; }
-if test "${ac_cv_header_errno_h+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_cv_header_errno_h=$ac_header_preproc
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_errno_h" >&5
-echo "${ECHO_T}$ac_cv_header_errno_h" >&6; }
-
-fi
-if test $ac_cv_header_errno_h = yes; then
-  :
-else
-  
-cat >>confdefs.h <<\_ACEOF
-@%:@define NO_ERRNO_H 1
-_ACEOF
-
-fi
-
-
-    if test "${ac_cv_header_float_h+set}" = set; then
-  { echo "$as_me:$LINENO: checking for float.h" >&5
-echo $ECHO_N "checking for float.h... $ECHO_C" >&6; }
-if test "${ac_cv_header_float_h+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_float_h" >&5
-echo "${ECHO_T}$ac_cv_header_float_h" >&6; }
-else
-  # Is the header compilable?
-{ echo "$as_me:$LINENO: checking float.h usability" >&5
-echo $ECHO_N "checking float.h usability... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-$ac_includes_default
-@%:@include <float.h>
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ac_header_compiler=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_header_compiler=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
-echo "${ECHO_T}$ac_header_compiler" >&6; }
-
-# Is the header present?
-{ echo "$as_me:$LINENO: checking float.h presence" >&5
-echo $ECHO_N "checking float.h presence... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-@%:@include <float.h>
-_ACEOF
-if { (ac_try="$ac_cpp conftest.$ac_ext"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } >/dev/null && {
-	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       }; then
-  ac_header_preproc=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-  ac_header_preproc=no
-fi
-
-rm -f conftest.err conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
-echo "${ECHO_T}$ac_header_preproc" >&6; }
-
-# So?  What about this header?
-case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
-  yes:no: )
-    { echo "$as_me:$LINENO: WARNING: float.h: accepted by the compiler, rejected by the preprocessor!" >&5
-echo "$as_me: WARNING: float.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
-    { echo "$as_me:$LINENO: WARNING: float.h: proceeding with the compiler's result" >&5
-echo "$as_me: WARNING: float.h: proceeding with the compiler's result" >&2;}
-    ac_header_preproc=yes
-    ;;
-  no:yes:* )
-    { echo "$as_me:$LINENO: WARNING: float.h: present but cannot be compiled" >&5
-echo "$as_me: WARNING: float.h: present but cannot be compiled" >&2;}
-    { echo "$as_me:$LINENO: WARNING: float.h:     check for missing prerequisite headers?" >&5
-echo "$as_me: WARNING: float.h:     check for missing prerequisite headers?" >&2;}
-    { echo "$as_me:$LINENO: WARNING: float.h: see the Autoconf documentation" >&5
-echo "$as_me: WARNING: float.h: see the Autoconf documentation" >&2;}
-    { echo "$as_me:$LINENO: WARNING: float.h:     section \"Present But Cannot Be Compiled\"" >&5
-echo "$as_me: WARNING: float.h:     section \"Present But Cannot Be Compiled\"" >&2;}
-    { echo "$as_me:$LINENO: WARNING: float.h: proceeding with the preprocessor's result" >&5
-echo "$as_me: WARNING: float.h: proceeding with the preprocessor's result" >&2;}
-    { echo "$as_me:$LINENO: WARNING: float.h: in the future, the compiler will take precedence" >&5
-echo "$as_me: WARNING: float.h: in the future, the compiler will take precedence" >&2;}
-    
-    ;;
-esac
-{ echo "$as_me:$LINENO: checking for float.h" >&5
-echo $ECHO_N "checking for float.h... $ECHO_C" >&6; }
-if test "${ac_cv_header_float_h+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_cv_header_float_h=$ac_header_preproc
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_float_h" >&5
-echo "${ECHO_T}$ac_cv_header_float_h" >&6; }
-
-fi
-if test $ac_cv_header_float_h = yes; then
-  :
-else
-  
-cat >>confdefs.h <<\_ACEOF
-@%:@define NO_FLOAT_H 1
-_ACEOF
-
-fi
-
-
-    if test "${ac_cv_header_values_h+set}" = set; then
-  { echo "$as_me:$LINENO: checking for values.h" >&5
-echo $ECHO_N "checking for values.h... $ECHO_C" >&6; }
-if test "${ac_cv_header_values_h+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_values_h" >&5
-echo "${ECHO_T}$ac_cv_header_values_h" >&6; }
-else
-  # Is the header compilable?
-{ echo "$as_me:$LINENO: checking values.h usability" >&5
-echo $ECHO_N "checking values.h usability... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-$ac_includes_default
-@%:@include <values.h>
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ac_header_compiler=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_header_compiler=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
-echo "${ECHO_T}$ac_header_compiler" >&6; }
-
-# Is the header present?
-{ echo "$as_me:$LINENO: checking values.h presence" >&5
-echo $ECHO_N "checking values.h presence... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-@%:@include <values.h>
-_ACEOF
-if { (ac_try="$ac_cpp conftest.$ac_ext"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } >/dev/null && {
-	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       }; then
-  ac_header_preproc=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-  ac_header_preproc=no
-fi
-
-rm -f conftest.err conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
-echo "${ECHO_T}$ac_header_preproc" >&6; }
-
-# So?  What about this header?
-case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
-  yes:no: )
-    { echo "$as_me:$LINENO: WARNING: values.h: accepted by the compiler, rejected by the preprocessor!" >&5
-echo "$as_me: WARNING: values.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
-    { echo "$as_me:$LINENO: WARNING: values.h: proceeding with the compiler's result" >&5
-echo "$as_me: WARNING: values.h: proceeding with the compiler's result" >&2;}
-    ac_header_preproc=yes
-    ;;
-  no:yes:* )
-    { echo "$as_me:$LINENO: WARNING: values.h: present but cannot be compiled" >&5
-echo "$as_me: WARNING: values.h: present but cannot be compiled" >&2;}
-    { echo "$as_me:$LINENO: WARNING: values.h:     check for missing prerequisite headers?" >&5
-echo "$as_me: WARNING: values.h:     check for missing prerequisite headers?" >&2;}
-    { echo "$as_me:$LINENO: WARNING: values.h: see the Autoconf documentation" >&5
-echo "$as_me: WARNING: values.h: see the Autoconf documentation" >&2;}
-    { echo "$as_me:$LINENO: WARNING: values.h:     section \"Present But Cannot Be Compiled\"" >&5
-echo "$as_me: WARNING: values.h:     section \"Present But Cannot Be Compiled\"" >&2;}
-    { echo "$as_me:$LINENO: WARNING: values.h: proceeding with the preprocessor's result" >&5
-echo "$as_me: WARNING: values.h: proceeding with the preprocessor's result" >&2;}
-    { echo "$as_me:$LINENO: WARNING: values.h: in the future, the compiler will take precedence" >&5
-echo "$as_me: WARNING: values.h: in the future, the compiler will take precedence" >&2;}
-    
-    ;;
-esac
-{ echo "$as_me:$LINENO: checking for values.h" >&5
-echo $ECHO_N "checking for values.h... $ECHO_C" >&6; }
-if test "${ac_cv_header_values_h+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_cv_header_values_h=$ac_header_preproc
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_values_h" >&5
-echo "${ECHO_T}$ac_cv_header_values_h" >&6; }
-
-fi
-if test $ac_cv_header_values_h = yes; then
-  :
-else
-  
-cat >>confdefs.h <<\_ACEOF
-@%:@define NO_VALUES_H 1
-_ACEOF
-
-fi
-
-
-    if test "${ac_cv_header_limits_h+set}" = set; then
-  { echo "$as_me:$LINENO: checking for limits.h" >&5
-echo $ECHO_N "checking for limits.h... $ECHO_C" >&6; }
-if test "${ac_cv_header_limits_h+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_limits_h" >&5
-echo "${ECHO_T}$ac_cv_header_limits_h" >&6; }
-else
-  # Is the header compilable?
-{ echo "$as_me:$LINENO: checking limits.h usability" >&5
-echo $ECHO_N "checking limits.h usability... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-$ac_includes_default
-@%:@include <limits.h>
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ac_header_compiler=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_header_compiler=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
-echo "${ECHO_T}$ac_header_compiler" >&6; }
-
-# Is the header present?
-{ echo "$as_me:$LINENO: checking limits.h presence" >&5
-echo $ECHO_N "checking limits.h presence... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-@%:@include <limits.h>
-_ACEOF
-if { (ac_try="$ac_cpp conftest.$ac_ext"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } >/dev/null && {
-	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       }; then
-  ac_header_preproc=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-  ac_header_preproc=no
-fi
-
-rm -f conftest.err conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
-echo "${ECHO_T}$ac_header_preproc" >&6; }
-
-# So?  What about this header?
-case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
-  yes:no: )
-    { echo "$as_me:$LINENO: WARNING: limits.h: accepted by the compiler, rejected by the preprocessor!" >&5
-echo "$as_me: WARNING: limits.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
-    { echo "$as_me:$LINENO: WARNING: limits.h: proceeding with the compiler's result" >&5
-echo "$as_me: WARNING: limits.h: proceeding with the compiler's result" >&2;}
-    ac_header_preproc=yes
-    ;;
-  no:yes:* )
-    { echo "$as_me:$LINENO: WARNING: limits.h: present but cannot be compiled" >&5
-echo "$as_me: WARNING: limits.h: present but cannot be compiled" >&2;}
-    { echo "$as_me:$LINENO: WARNING: limits.h:     check for missing prerequisite headers?" >&5
-echo "$as_me: WARNING: limits.h:     check for missing prerequisite headers?" >&2;}
-    { echo "$as_me:$LINENO: WARNING: limits.h: see the Autoconf documentation" >&5
-echo "$as_me: WARNING: limits.h: see the Autoconf documentation" >&2;}
-    { echo "$as_me:$LINENO: WARNING: limits.h:     section \"Present But Cannot Be Compiled\"" >&5
-echo "$as_me: WARNING: limits.h:     section \"Present But Cannot Be Compiled\"" >&2;}
-    { echo "$as_me:$LINENO: WARNING: limits.h: proceeding with the preprocessor's result" >&5
-echo "$as_me: WARNING: limits.h: proceeding with the preprocessor's result" >&2;}
-    { echo "$as_me:$LINENO: WARNING: limits.h: in the future, the compiler will take precedence" >&5
-echo "$as_me: WARNING: limits.h: in the future, the compiler will take precedence" >&2;}
-    
-    ;;
-esac
-{ echo "$as_me:$LINENO: checking for limits.h" >&5
-echo $ECHO_N "checking for limits.h... $ECHO_C" >&6; }
-if test "${ac_cv_header_limits_h+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_cv_header_limits_h=$ac_header_preproc
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_limits_h" >&5
-echo "${ECHO_T}$ac_cv_header_limits_h" >&6; }
-
-fi
-if test $ac_cv_header_limits_h = yes; then
-  
-cat >>confdefs.h <<\_ACEOF
-@%:@define HAVE_LIMITS_H 1
-_ACEOF
-
-else
-  
-cat >>confdefs.h <<\_ACEOF
-@%:@define NO_LIMITS_H 1
-_ACEOF
-
-fi
-
-
-    if test "${ac_cv_header_stdlib_h+set}" = set; then
-  { echo "$as_me:$LINENO: checking for stdlib.h" >&5
-echo $ECHO_N "checking for stdlib.h... $ECHO_C" >&6; }
-if test "${ac_cv_header_stdlib_h+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_stdlib_h" >&5
-echo "${ECHO_T}$ac_cv_header_stdlib_h" >&6; }
-else
-  # Is the header compilable?
-{ echo "$as_me:$LINENO: checking stdlib.h usability" >&5
-echo $ECHO_N "checking stdlib.h usability... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-$ac_includes_default
-@%:@include <stdlib.h>
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ac_header_compiler=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_header_compiler=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
-echo "${ECHO_T}$ac_header_compiler" >&6; }
-
-# Is the header present?
-{ echo "$as_me:$LINENO: checking stdlib.h presence" >&5
-echo $ECHO_N "checking stdlib.h presence... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-@%:@include <stdlib.h>
-_ACEOF
-if { (ac_try="$ac_cpp conftest.$ac_ext"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } >/dev/null && {
-	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       }; then
-  ac_header_preproc=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-  ac_header_preproc=no
-fi
-
-rm -f conftest.err conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
-echo "${ECHO_T}$ac_header_preproc" >&6; }
-
-# So?  What about this header?
-case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
-  yes:no: )
-    { echo "$as_me:$LINENO: WARNING: stdlib.h: accepted by the compiler, rejected by the preprocessor!" >&5
-echo "$as_me: WARNING: stdlib.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
-    { echo "$as_me:$LINENO: WARNING: stdlib.h: proceeding with the compiler's result" >&5
-echo "$as_me: WARNING: stdlib.h: proceeding with the compiler's result" >&2;}
-    ac_header_preproc=yes
-    ;;
-  no:yes:* )
-    { echo "$as_me:$LINENO: WARNING: stdlib.h: present but cannot be compiled" >&5
-echo "$as_me: WARNING: stdlib.h: present but cannot be compiled" >&2;}
-    { echo "$as_me:$LINENO: WARNING: stdlib.h:     check for missing prerequisite headers?" >&5
-echo "$as_me: WARNING: stdlib.h:     check for missing prerequisite headers?" >&2;}
-    { echo "$as_me:$LINENO: WARNING: stdlib.h: see the Autoconf documentation" >&5
-echo "$as_me: WARNING: stdlib.h: see the Autoconf documentation" >&2;}
-    { echo "$as_me:$LINENO: WARNING: stdlib.h:     section \"Present But Cannot Be Compiled\"" >&5
-echo "$as_me: WARNING: stdlib.h:     section \"Present But Cannot Be Compiled\"" >&2;}
-    { echo "$as_me:$LINENO: WARNING: stdlib.h: proceeding with the preprocessor's result" >&5
-echo "$as_me: WARNING: stdlib.h: proceeding with the preprocessor's result" >&2;}
-    { echo "$as_me:$LINENO: WARNING: stdlib.h: in the future, the compiler will take precedence" >&5
-echo "$as_me: WARNING: stdlib.h: in the future, the compiler will take precedence" >&2;}
-    
-    ;;
-esac
-{ echo "$as_me:$LINENO: checking for stdlib.h" >&5
-echo $ECHO_N "checking for stdlib.h... $ECHO_C" >&6; }
-if test "${ac_cv_header_stdlib_h+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_cv_header_stdlib_h=$ac_header_preproc
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_stdlib_h" >&5
-echo "${ECHO_T}$ac_cv_header_stdlib_h" >&6; }
-
-fi
-if test $ac_cv_header_stdlib_h = yes; then
-  tcl_ok=1
-else
-  tcl_ok=0
-fi
-
-
-    cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <stdlib.h>
-
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-  $EGREP "strtol" >/dev/null 2>&1; then
-  :
-else
-  tcl_ok=0
-fi
-rm -f conftest*
-
-    cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <stdlib.h>
-
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-  $EGREP "strtoul" >/dev/null 2>&1; then
-  :
-else
-  tcl_ok=0
-fi
-rm -f conftest*
-
-    cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <stdlib.h>
-
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-  $EGREP "strtod" >/dev/null 2>&1; then
-  :
-else
-  tcl_ok=0
-fi
-rm -f conftest*
-
-    if test $tcl_ok = 0; then
-	
-cat >>confdefs.h <<\_ACEOF
-@%:@define NO_STDLIB_H 1
-_ACEOF
-
-    fi
-    if test "${ac_cv_header_string_h+set}" = set; then
-  { echo "$as_me:$LINENO: checking for string.h" >&5
-echo $ECHO_N "checking for string.h... $ECHO_C" >&6; }
-if test "${ac_cv_header_string_h+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_string_h" >&5
-echo "${ECHO_T}$ac_cv_header_string_h" >&6; }
-else
-  # Is the header compilable?
-{ echo "$as_me:$LINENO: checking string.h usability" >&5
-echo $ECHO_N "checking string.h usability... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-$ac_includes_default
-@%:@include <string.h>
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ac_header_compiler=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_header_compiler=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
-echo "${ECHO_T}$ac_header_compiler" >&6; }
-
-# Is the header present?
-{ echo "$as_me:$LINENO: checking string.h presence" >&5
-echo $ECHO_N "checking string.h presence... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-@%:@include <string.h>
-_ACEOF
-if { (ac_try="$ac_cpp conftest.$ac_ext"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } >/dev/null && {
-	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       }; then
-  ac_header_preproc=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-  ac_header_preproc=no
-fi
-
-rm -f conftest.err conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
-echo "${ECHO_T}$ac_header_preproc" >&6; }
-
-# So?  What about this header?
-case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
-  yes:no: )
-    { echo "$as_me:$LINENO: WARNING: string.h: accepted by the compiler, rejected by the preprocessor!" >&5
-echo "$as_me: WARNING: string.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
-    { echo "$as_me:$LINENO: WARNING: string.h: proceeding with the compiler's result" >&5
-echo "$as_me: WARNING: string.h: proceeding with the compiler's result" >&2;}
-    ac_header_preproc=yes
-    ;;
-  no:yes:* )
-    { echo "$as_me:$LINENO: WARNING: string.h: present but cannot be compiled" >&5
-echo "$as_me: WARNING: string.h: present but cannot be compiled" >&2;}
-    { echo "$as_me:$LINENO: WARNING: string.h:     check for missing prerequisite headers?" >&5
-echo "$as_me: WARNING: string.h:     check for missing prerequisite headers?" >&2;}
-    { echo "$as_me:$LINENO: WARNING: string.h: see the Autoconf documentation" >&5
-echo "$as_me: WARNING: string.h: see the Autoconf documentation" >&2;}
-    { echo "$as_me:$LINENO: WARNING: string.h:     section \"Present But Cannot Be Compiled\"" >&5
-echo "$as_me: WARNING: string.h:     section \"Present But Cannot Be Compiled\"" >&2;}
-    { echo "$as_me:$LINENO: WARNING: string.h: proceeding with the preprocessor's result" >&5
-echo "$as_me: WARNING: string.h: proceeding with the preprocessor's result" >&2;}
-    { echo "$as_me:$LINENO: WARNING: string.h: in the future, the compiler will take precedence" >&5
-echo "$as_me: WARNING: string.h: in the future, the compiler will take precedence" >&2;}
-    
-    ;;
-esac
-{ echo "$as_me:$LINENO: checking for string.h" >&5
-echo $ECHO_N "checking for string.h... $ECHO_C" >&6; }
-if test "${ac_cv_header_string_h+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_cv_header_string_h=$ac_header_preproc
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_string_h" >&5
-echo "${ECHO_T}$ac_cv_header_string_h" >&6; }
-
-fi
-if test $ac_cv_header_string_h = yes; then
-  tcl_ok=1
-else
-  tcl_ok=0
-fi
-
-
-    cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <string.h>
-
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-  $EGREP "strstr" >/dev/null 2>&1; then
-  :
-else
-  tcl_ok=0
-fi
-rm -f conftest*
-
-    cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <string.h>
-
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-  $EGREP "strerror" >/dev/null 2>&1; then
-  :
-else
-  tcl_ok=0
-fi
-rm -f conftest*
-
-
-    # See also memmove check below for a place where NO_STRING_H can be
-    # set and why.
-
-    if test $tcl_ok = 0; then
-	
-cat >>confdefs.h <<\_ACEOF
-@%:@define NO_STRING_H 1
-_ACEOF
-
-    fi
-
-    if test "${ac_cv_header_sys_wait_h+set}" = set; then
-  { echo "$as_me:$LINENO: checking for sys/wait.h" >&5
-echo $ECHO_N "checking for sys/wait.h... $ECHO_C" >&6; }
-if test "${ac_cv_header_sys_wait_h+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_sys_wait_h" >&5
-echo "${ECHO_T}$ac_cv_header_sys_wait_h" >&6; }
-else
-  # Is the header compilable?
-{ echo "$as_me:$LINENO: checking sys/wait.h usability" >&5
-echo $ECHO_N "checking sys/wait.h usability... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-$ac_includes_default
-@%:@include <sys/wait.h>
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ac_header_compiler=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_header_compiler=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
-echo "${ECHO_T}$ac_header_compiler" >&6; }
-
-# Is the header present?
-{ echo "$as_me:$LINENO: checking sys/wait.h presence" >&5
-echo $ECHO_N "checking sys/wait.h presence... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-@%:@include <sys/wait.h>
-_ACEOF
-if { (ac_try="$ac_cpp conftest.$ac_ext"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } >/dev/null && {
-	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       }; then
-  ac_header_preproc=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-  ac_header_preproc=no
-fi
-
-rm -f conftest.err conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
-echo "${ECHO_T}$ac_header_preproc" >&6; }
-
-# So?  What about this header?
-case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
-  yes:no: )
-    { echo "$as_me:$LINENO: WARNING: sys/wait.h: accepted by the compiler, rejected by the preprocessor!" >&5
-echo "$as_me: WARNING: sys/wait.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
-    { echo "$as_me:$LINENO: WARNING: sys/wait.h: proceeding with the compiler's result" >&5
-echo "$as_me: WARNING: sys/wait.h: proceeding with the compiler's result" >&2;}
-    ac_header_preproc=yes
-    ;;
-  no:yes:* )
-    { echo "$as_me:$LINENO: WARNING: sys/wait.h: present but cannot be compiled" >&5
-echo "$as_me: WARNING: sys/wait.h: present but cannot be compiled" >&2;}
-    { echo "$as_me:$LINENO: WARNING: sys/wait.h:     check for missing prerequisite headers?" >&5
-echo "$as_me: WARNING: sys/wait.h:     check for missing prerequisite headers?" >&2;}
-    { echo "$as_me:$LINENO: WARNING: sys/wait.h: see the Autoconf documentation" >&5
-echo "$as_me: WARNING: sys/wait.h: see the Autoconf documentation" >&2;}
-    { echo "$as_me:$LINENO: WARNING: sys/wait.h:     section \"Present But Cannot Be Compiled\"" >&5
-echo "$as_me: WARNING: sys/wait.h:     section \"Present But Cannot Be Compiled\"" >&2;}
-    { echo "$as_me:$LINENO: WARNING: sys/wait.h: proceeding with the preprocessor's result" >&5
-echo "$as_me: WARNING: sys/wait.h: proceeding with the preprocessor's result" >&2;}
-    { echo "$as_me:$LINENO: WARNING: sys/wait.h: in the future, the compiler will take precedence" >&5
-echo "$as_me: WARNING: sys/wait.h: in the future, the compiler will take precedence" >&2;}
-    
-    ;;
-esac
-{ echo "$as_me:$LINENO: checking for sys/wait.h" >&5
-echo $ECHO_N "checking for sys/wait.h... $ECHO_C" >&6; }
-if test "${ac_cv_header_sys_wait_h+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_cv_header_sys_wait_h=$ac_header_preproc
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_sys_wait_h" >&5
-echo "${ECHO_T}$ac_cv_header_sys_wait_h" >&6; }
-
-fi
-if test $ac_cv_header_sys_wait_h = yes; then
-  :
-else
-  
-cat >>confdefs.h <<\_ACEOF
-@%:@define NO_SYS_WAIT_H 1
-_ACEOF
-
-fi
-
-
-    if test "${ac_cv_header_dlfcn_h+set}" = set; then
-  { echo "$as_me:$LINENO: checking for dlfcn.h" >&5
-echo $ECHO_N "checking for dlfcn.h... $ECHO_C" >&6; }
-if test "${ac_cv_header_dlfcn_h+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_dlfcn_h" >&5
-echo "${ECHO_T}$ac_cv_header_dlfcn_h" >&6; }
-else
-  # Is the header compilable?
-{ echo "$as_me:$LINENO: checking dlfcn.h usability" >&5
-echo $ECHO_N "checking dlfcn.h usability... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-$ac_includes_default
-@%:@include <dlfcn.h>
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ac_header_compiler=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_header_compiler=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
-echo "${ECHO_T}$ac_header_compiler" >&6; }
-
-# Is the header present?
-{ echo "$as_me:$LINENO: checking dlfcn.h presence" >&5
-echo $ECHO_N "checking dlfcn.h presence... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-@%:@include <dlfcn.h>
-_ACEOF
-if { (ac_try="$ac_cpp conftest.$ac_ext"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } >/dev/null && {
-	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       }; then
-  ac_header_preproc=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-  ac_header_preproc=no
-fi
-
-rm -f conftest.err conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
-echo "${ECHO_T}$ac_header_preproc" >&6; }
-
-# So?  What about this header?
-case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
-  yes:no: )
-    { echo "$as_me:$LINENO: WARNING: dlfcn.h: accepted by the compiler, rejected by the preprocessor!" >&5
-echo "$as_me: WARNING: dlfcn.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
-    { echo "$as_me:$LINENO: WARNING: dlfcn.h: proceeding with the compiler's result" >&5
-echo "$as_me: WARNING: dlfcn.h: proceeding with the compiler's result" >&2;}
-    ac_header_preproc=yes
-    ;;
-  no:yes:* )
-    { echo "$as_me:$LINENO: WARNING: dlfcn.h: present but cannot be compiled" >&5
-echo "$as_me: WARNING: dlfcn.h: present but cannot be compiled" >&2;}
-    { echo "$as_me:$LINENO: WARNING: dlfcn.h:     check for missing prerequisite headers?" >&5
-echo "$as_me: WARNING: dlfcn.h:     check for missing prerequisite headers?" >&2;}
-    { echo "$as_me:$LINENO: WARNING: dlfcn.h: see the Autoconf documentation" >&5
-echo "$as_me: WARNING: dlfcn.h: see the Autoconf documentation" >&2;}
-    { echo "$as_me:$LINENO: WARNING: dlfcn.h:     section \"Present But Cannot Be Compiled\"" >&5
-echo "$as_me: WARNING: dlfcn.h:     section \"Present But Cannot Be Compiled\"" >&2;}
-    { echo "$as_me:$LINENO: WARNING: dlfcn.h: proceeding with the preprocessor's result" >&5
-echo "$as_me: WARNING: dlfcn.h: proceeding with the preprocessor's result" >&2;}
-    { echo "$as_me:$LINENO: WARNING: dlfcn.h: in the future, the compiler will take precedence" >&5
-echo "$as_me: WARNING: dlfcn.h: in the future, the compiler will take precedence" >&2;}
-    
-    ;;
-esac
-{ echo "$as_me:$LINENO: checking for dlfcn.h" >&5
-echo $ECHO_N "checking for dlfcn.h... $ECHO_C" >&6; }
-if test "${ac_cv_header_dlfcn_h+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_cv_header_dlfcn_h=$ac_header_preproc
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_dlfcn_h" >&5
-echo "${ECHO_T}$ac_cv_header_dlfcn_h" >&6; }
-
-fi
-if test $ac_cv_header_dlfcn_h = yes; then
-  :
-else
-  
-cat >>confdefs.h <<\_ACEOF
-@%:@define NO_DLFCN_H 1
-_ACEOF
-
-fi
-
-
-
-    # OS/390 lacks sys/param.h (and doesn't need it, by chance).
-    
-for ac_header in sys/param.h
-do
-as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
-if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
-  { echo "$as_me:$LINENO: checking for $ac_header" >&5
-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
-if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-fi
-ac_res=`eval echo '${'$as_ac_Header'}'`
-	       { echo "$as_me:$LINENO: result: $ac_res" >&5
-echo "${ECHO_T}$ac_res" >&6; }
-else
-  # Is the header compilable?
-{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
-echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-$ac_includes_default
-@%:@include <$ac_header>
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ac_header_compiler=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_header_compiler=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
-echo "${ECHO_T}$ac_header_compiler" >&6; }
-
-# Is the header present?
-{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
-echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-@%:@include <$ac_header>
-_ACEOF
-if { (ac_try="$ac_cpp conftest.$ac_ext"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } >/dev/null && {
-	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       }; then
-  ac_header_preproc=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-  ac_header_preproc=no
-fi
-
-rm -f conftest.err conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
-echo "${ECHO_T}$ac_header_preproc" >&6; }
-
-# So?  What about this header?
-case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
-  yes:no: )
-    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
-echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
-    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
-echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
-    ac_header_preproc=yes
-    ;;
-  no:yes:* )
-    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
-echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
-    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
-echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
-    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
-echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
-    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
-echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
-    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
-echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
-    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
-echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
-    
-    ;;
-esac
-{ echo "$as_me:$LINENO: checking for $ac_header" >&5
-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
-if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  eval "$as_ac_Header=\$ac_header_preproc"
-fi
-ac_res=`eval echo '${'$as_ac_Header'}'`
-	       { echo "$as_me:$LINENO: result: $ac_res" >&5
-echo "${ECHO_T}$ac_res" >&6; }
-
-fi
-if test `eval echo '${'$as_ac_Header'}'` = yes; then
-  cat >>confdefs.h <<_ACEOF
-@%:@define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
-_ACEOF
- 
-fi
-
-done
-
-
-	# Let the user call this, because if it triggers, they will
-	# need a compat/strtod.c that is correct.  Users can also
-	# use Tcl_GetDouble(FromObj) instead.
-	#TEA_BUGGY_STRTOD
-    fi
-
-
-#-----------------------------------------------------------------------
-# Specify the C source files to compile in TEA_ADD_SOURCES,
-# public headers that need to be installed in TEA_ADD_HEADERS,
-# stub library C source files to compile in TEA_ADD_STUB_SOURCES,
-# and runtime Tcl library files in TEA_ADD_TCL_SOURCES.
-# This defines PKG(_STUB)_SOURCES, PKG(_STUB)_OBJECTS, PKG_HEADERS
-# and PKG_TCL_SOURCES.
-#-----------------------------------------------------------------------
-
-
-    vars="tclxml.c docObj.c tclxml-libxml2.c nodeObj.c tcldom-libxml2.c tclxslt-libxslt.c"
-    for i in $vars; do
-	case $i in
-	    \$*)
-		# allow $-var names
-		PKG_SOURCES="$PKG_SOURCES $i"
-		PKG_OBJECTS="$PKG_OBJECTS $i"
-		;;
-	    *)
-		# check for existence - allows for generic/win/unix VPATH
-		if test ! -f "${srcdir}/$i" -a ! -f "${srcdir}/generic/$i" \
-		    -a ! -f "${srcdir}/win/$i" -a ! -f "${srcdir}/unix/$i" \
-		    ; then
-		    { { echo "$as_me:$LINENO: error: could not find source file '$i'" >&5
-echo "$as_me: error: could not find source file '$i'" >&2;}
-   { (exit 1); exit 1; }; }
-		fi
-		PKG_SOURCES="$PKG_SOURCES $i"
-		# this assumes it is in a VPATH dir
-		i=`basename $i`
-		# handle user calling this before or after TEA_SETUP_COMPILER
-		if test x"${OBJEXT}" != x ; then
-		    j="`echo $i | sed -e 's/\.[^.]*$//'`.${OBJEXT}"
-		else
-		    j="`echo $i | sed -e 's/\.[^.]*$//'`.\${OBJEXT}"
-		fi
-		PKG_OBJECTS="$PKG_OBJECTS $j"
-		;;
-	esac
-    done
-    
-    
-
-
-    vars="include/tclxml-libxml2/docObj.h include/tclxml-libxml2/tclxml-libxml2.h include/tcldom/tcldom.h include/tcldom-libxml2/tcldom-libxml2.h include/tclxslt/tclxslt.h"
-    for i in $vars; do
-	# check for existence, be strict because it is installed
-	if test ! -f "${srcdir}/$i" ; then
-	    { { echo "$as_me:$LINENO: error: could not find header file '${srcdir}/$i'" >&5
-echo "$as_me: error: could not find header file '${srcdir}/$i'" >&2;}
-   { (exit 1); exit 1; }; }
-	fi
-	PKG_HEADERS="$PKG_HEADERS $i"
-    done
-    
-
-
-    vars="-Iinclude"
-    for i in $vars; do
-	PKG_INCLUDES="$PKG_INCLUDES $i"
-    done
-    
-
-#TEA_ADD_LIBS([-lexslt])
-
-    vars=""
-    for i in $vars; do
-	if test "${TEA_PLATFORM}" = "windows" -a "$GCC" = "yes" ; then
-	    # Convert foo.lib to -lfoo for GCC.  No-op if not *.lib
-	    i=`echo "$i" | sed -e 's/^\([^-].*\)\.lib$/-l\1/i'`
-	fi
-	PKG_LIBS="$PKG_LIBS $i"
-    done
-    
-
-
-    PKG_CFLAGS="$PKG_CFLAGS "
-    
-
-
-    vars="tclxmlStubInit.c tclxmlStubLib.c"
-    for i in $vars; do
-	# check for existence - allows for generic/win/unix VPATH
-	if test ! -f "${srcdir}/$i" -a ! -f "${srcdir}/generic/$i" \
-	    -a ! -f "${srcdir}/win/$i" -a ! -f "${srcdir}/unix/$i" \
-	    ; then
-	    { { echo "$as_me:$LINENO: error: could not find stub source file '$i'" >&5
-echo "$as_me: error: could not find stub source file '$i'" >&2;}
-   { (exit 1); exit 1; }; }
-	fi
-	PKG_STUB_SOURCES="$PKG_STUB_SOURCES $i"
-	# this assumes it is in a VPATH dir
-	i=`basename $i`
-	# handle user calling this before or after TEA_SETUP_COMPILER
-	if test x"${OBJEXT}" != x ; then
-	    j="`echo $i | sed -e 's/\.[^.]*$//'`.${OBJEXT}"
-	else
-	    j="`echo $i | sed -e 's/\.[^.]*$//'`.\${OBJEXT}"
-	fi
-	PKG_STUB_OBJECTS="$PKG_STUB_OBJECTS $j"
-    done
-    
-    
-
-
-    vars="tclxml-tcl/xml__tcl.tcl tclxml-tcl/sgml-8.0.tcl tclxml-tcl/sgml-8.1.tcl tclxml-tcl/xml-8.0.tcl tclxml-tcl/xml-8.1.tcl tclxml-tcl/sgmlparser.tcl tclxml-tcl/tclparser-8.0.tcl tclxml-tcl/tclparser-8.1.tcl tclxml-tcl/xmldep.tcl tclxml-tcl/xpath.tcl tcldom-libxml2.tcl tcldom-tcl/xmlswitch.tcl tclxslt/process.tcl tclxslt/resources.tcl tclxslt/utilities.tcl tclxslt/xsltcache.tcl tclxslt-libxslt.tcl"
-    for i in $vars; do
-	# check for existence, be strict because it is installed
-	if test ! -f "${srcdir}/$i" ; then
-	    { { echo "$as_me:$LINENO: error: could not find tcl source file '${srcdir}/$i'" >&5
-echo "$as_me: error: could not find tcl source file '${srcdir}/$i'" >&2;}
-   { (exit 1); exit 1; }; }
-	fi
-	PKG_TCL_SOURCES="$PKG_TCL_SOURCES $i"
-    done
-    
-
-
-#--------------------------------------------------------------------
-# A few miscellaneous platform-specific items:
-#
-# We have to define a special symbol for Windows (BUILD_Tclxml in this
-# case) so that we create the export library with the dll.
-#
-# Windows creates a few extra files that need to be cleaned up.
-# We can add more files to clean if our extension creates any extra
-# files in the future.
-#
-# TEA_ADD_* any platform specific compiler/build info here.
-#--------------------------------------------------------------------
-
-CLEANFILES=pkgIndex.tcl
-if test "${TEA_PLATFORM}" = "windows" ; then
-    
-cat >>confdefs.h <<\_ACEOF
-@%:@define BUILD_Tclxml 1
-_ACEOF
-
-    CLEANFILES="$CLEANFILES *.lib *.dll *.exp *.ilk *.pdb vc*.pch"
-else
-    :
-fi
-
-
-
-    { echo "$as_me:$LINENO: checking for Tcl public headers" >&5
-echo $ECHO_N "checking for Tcl public headers... $ECHO_C" >&6; }
-
-    
-# Check whether --with-tclinclude was given.
-if test "${with_tclinclude+set}" = set; then
-  withval=$with_tclinclude; with_tclinclude=${withval}
-fi
-
-
-    if test "${ac_cv_c_tclh+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  
-	# Use the value from --with-tclinclude, if it was given
-
-	if test x"${with_tclinclude}" != x ; then
-	    if test -f "${with_tclinclude}/tcl.h" ; then
-		ac_cv_c_tclh=${with_tclinclude}
-	    else
-		{ { echo "$as_me:$LINENO: error: ${with_tclinclude} directory does not contain tcl.h" >&5
-echo "$as_me: error: ${with_tclinclude} directory does not contain tcl.h" >&2;}
-   { (exit 1); exit 1; }; }
-	    fi
-	else
-	    if test "`uname -s`" = "Darwin"; then
-		# If Tcl was built as a framework, attempt to use
-		# the framework's Headers directory
-		case ${TCL_DEFS} in
-		    *TCL_FRAMEWORK*)
-			list="`ls -d ${TCL_BIN_DIR}/Headers 2>/dev/null`"
-			;;
-		esac
-	    fi
-
-	    # Look in the source dir only if Tcl is not installed,
-	    # and in that situation, look there before installed locations.
-	    if test -f "${TCL_BIN_DIR}/Makefile" ; then
-		list="$list `ls -d ${TCL_SRC_DIR}/generic 2>/dev/null`"
-	    fi
-
-	    # Check order: pkg --prefix location, Tcl's --prefix location,
-	    # relative to directory of tclConfig.sh.
-
-	    eval "temp_includedir=${includedir}"
-	    list="$list \
-		`ls -d ${temp_includedir}        2>/dev/null` \
-		`ls -d ${TCL_PREFIX}/include     2>/dev/null` \
-		`ls -d ${TCL_BIN_DIR}/../include 2>/dev/null`"
-	    if test "${TEA_PLATFORM}" != "windows" -o "$GCC" = "yes"; then
-		list="$list /usr/local/include /usr/include"
-		if test x"${TCL_INCLUDE_SPEC}" != x ; then
-		    d=`echo "${TCL_INCLUDE_SPEC}" | sed -e 's/^-I//'`
-		    list="$list `ls -d ${d} 2>/dev/null`"
-		fi
-	    fi
-	    for i in $list ; do
-		if test -f "$i/tcl.h" ; then
-		    ac_cv_c_tclh=$i
-		    break
-		fi
-	    done
-	fi
-    
-fi
-
-
-    # Print a message based on how we determined the include path
-
-    if test x"${ac_cv_c_tclh}" = x ; then
-	{ { echo "$as_me:$LINENO: error: tcl.h not found.  Please specify its location with --with-tclinclude" >&5
-echo "$as_me: error: tcl.h not found.  Please specify its location with --with-tclinclude" >&2;}
-   { (exit 1); exit 1; }; }
-    else
-	{ echo "$as_me:$LINENO: result: ${ac_cv_c_tclh}" >&5
-echo "${ECHO_T}${ac_cv_c_tclh}" >&6; }
-    fi
-
-    # Convert to a native path and substitute into the output files.
-
-    INCLUDE_DIR_NATIVE=`${CYGPATH} ${ac_cv_c_tclh}`
-
-    TCL_INCLUDES=-I\"${INCLUDE_DIR_NATIVE}\"
-
-    
-
-
-#--------------------------------------------------------------------
-# Check whether --enable-threads or --disable-threads was given.
-# So far only Tcl responds to this one.
-#--------------------------------------------------------------------
-
-
-    # Check whether --enable-threads was given.
-if test "${enable_threads+set}" = set; then
-  enableval=$enable_threads; tcl_ok=$enableval
-else
-  tcl_ok=yes
-fi
-
-
-    if test "${enable_threads+set}" = set; then
-	enableval="$enable_threads"
-	tcl_ok=$enableval
-    else
-	tcl_ok=yes
-    fi
-
-    if test "$tcl_ok" = "yes" -o "${TCL_THREADS}" = 1; then
-	TCL_THREADS=1
-
-	if test "${TEA_PLATFORM}" != "windows" ; then
-	    # We are always OK on Windows, so check what this platform wants:
-    
-	    # USE_THREAD_ALLOC tells us to try the special thread-based
-	    # allocator that significantly reduces lock contention
-	    
-cat >>confdefs.h <<\_ACEOF
-@%:@define USE_THREAD_ALLOC 1
-_ACEOF
-
-	    
-cat >>confdefs.h <<\_ACEOF
-@%:@define _REENTRANT 1
-_ACEOF
-
-	    if test "`uname -s`" = "SunOS" ; then
-		
-cat >>confdefs.h <<\_ACEOF
-@%:@define _POSIX_PTHREAD_SEMANTICS 1
-_ACEOF
-
-	    fi
-	    
-cat >>confdefs.h <<\_ACEOF
-@%:@define _THREAD_SAFE 1
-_ACEOF
-
-	    { echo "$as_me:$LINENO: checking for pthread_mutex_init in -lpthread" >&5
-echo $ECHO_N "checking for pthread_mutex_init in -lpthread... $ECHO_C" >&6; }
-if test "${ac_cv_lib_pthread_pthread_mutex_init+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-lpthread  $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-/* Override any GCC internal prototype to avoid an error.
-   Use char because int might match the return type of a GCC
-   builtin and then its argument prototype would still apply.  */
-#ifdef __cplusplus
-extern "C"
-#endif
-char pthread_mutex_init ();
-int
-main ()
-{
-return pthread_mutex_init ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_pthread_pthread_mutex_init=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_lib_pthread_pthread_mutex_init=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_pthread_pthread_mutex_init" >&5
-echo "${ECHO_T}$ac_cv_lib_pthread_pthread_mutex_init" >&6; }
-if test $ac_cv_lib_pthread_pthread_mutex_init = yes; then
-  tcl_ok=yes
-else
-  tcl_ok=no
-fi
-
-	    if test "$tcl_ok" = "no"; then
-		# Check a little harder for __pthread_mutex_init in the same
-		# library, as some systems hide it there until pthread.h is
-		# defined.  We could alternatively do an AC_TRY_COMPILE with
-		# pthread.h, but that will work with libpthread really doesn't
-		# exist, like AIX 4.2.  [Bug: 4359]
-		{ echo "$as_me:$LINENO: checking for __pthread_mutex_init in -lpthread" >&5
-echo $ECHO_N "checking for __pthread_mutex_init in -lpthread... $ECHO_C" >&6; }
-if test "${ac_cv_lib_pthread___pthread_mutex_init+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-lpthread  $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-/* Override any GCC internal prototype to avoid an error.
-   Use char because int might match the return type of a GCC
-   builtin and then its argument prototype would still apply.  */
-#ifdef __cplusplus
-extern "C"
-#endif
-char __pthread_mutex_init ();
-int
-main ()
-{
-return __pthread_mutex_init ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_pthread___pthread_mutex_init=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_lib_pthread___pthread_mutex_init=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_pthread___pthread_mutex_init" >&5
-echo "${ECHO_T}$ac_cv_lib_pthread___pthread_mutex_init" >&6; }
-if test $ac_cv_lib_pthread___pthread_mutex_init = yes; then
-  tcl_ok=yes
-else
-  tcl_ok=no
-fi
-
-	    fi
-
-	    if test "$tcl_ok" = "yes"; then
-		# The space is needed
-		THREADS_LIBS=" -lpthread"
-	    else
-		{ echo "$as_me:$LINENO: checking for pthread_mutex_init in -lpthreads" >&5
-echo $ECHO_N "checking for pthread_mutex_init in -lpthreads... $ECHO_C" >&6; }
-if test "${ac_cv_lib_pthreads_pthread_mutex_init+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-lpthreads  $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-/* Override any GCC internal prototype to avoid an error.
-   Use char because int might match the return type of a GCC
-   builtin and then its argument prototype would still apply.  */
-#ifdef __cplusplus
-extern "C"
-#endif
-char pthread_mutex_init ();
-int
-main ()
-{
-return pthread_mutex_init ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_pthreads_pthread_mutex_init=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_lib_pthreads_pthread_mutex_init=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_pthreads_pthread_mutex_init" >&5
-echo "${ECHO_T}$ac_cv_lib_pthreads_pthread_mutex_init" >&6; }
-if test $ac_cv_lib_pthreads_pthread_mutex_init = yes; then
-  tcl_ok=yes
-else
-  tcl_ok=no
-fi
-
-		if test "$tcl_ok" = "yes"; then
-		    # The space is needed
-		    THREADS_LIBS=" -lpthreads"
-		else
-		    { echo "$as_me:$LINENO: checking for pthread_mutex_init in -lc" >&5
-echo $ECHO_N "checking for pthread_mutex_init in -lc... $ECHO_C" >&6; }
-if test "${ac_cv_lib_c_pthread_mutex_init+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-lc  $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-/* Override any GCC internal prototype to avoid an error.
-   Use char because int might match the return type of a GCC
-   builtin and then its argument prototype would still apply.  */
-#ifdef __cplusplus
-extern "C"
-#endif
-char pthread_mutex_init ();
-int
-main ()
-{
-return pthread_mutex_init ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_c_pthread_mutex_init=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_lib_c_pthread_mutex_init=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_c_pthread_mutex_init" >&5
-echo "${ECHO_T}$ac_cv_lib_c_pthread_mutex_init" >&6; }
-if test $ac_cv_lib_c_pthread_mutex_init = yes; then
-  tcl_ok=yes
-else
-  tcl_ok=no
-fi
-
-		    if test "$tcl_ok" = "no"; then
-			{ echo "$as_me:$LINENO: checking for pthread_mutex_init in -lc_r" >&5
-echo $ECHO_N "checking for pthread_mutex_init in -lc_r... $ECHO_C" >&6; }
-if test "${ac_cv_lib_c_r_pthread_mutex_init+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-lc_r  $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-/* Override any GCC internal prototype to avoid an error.
-   Use char because int might match the return type of a GCC
-   builtin and then its argument prototype would still apply.  */
-#ifdef __cplusplus
-extern "C"
-#endif
-char pthread_mutex_init ();
-int
-main ()
-{
-return pthread_mutex_init ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_c_r_pthread_mutex_init=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_lib_c_r_pthread_mutex_init=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_c_r_pthread_mutex_init" >&5
-echo "${ECHO_T}$ac_cv_lib_c_r_pthread_mutex_init" >&6; }
-if test $ac_cv_lib_c_r_pthread_mutex_init = yes; then
-  tcl_ok=yes
-else
-  tcl_ok=no
-fi
-
-			if test "$tcl_ok" = "yes"; then
-			    # The space is needed
-			    THREADS_LIBS=" -pthread"
-			else
-			    TCL_THREADS=0
-			    { echo "$as_me:$LINENO: WARNING: Do not know how to find pthread lib on your system - thread support disabled" >&5
-echo "$as_me: WARNING: Do not know how to find pthread lib on your system - thread support disabled" >&2;}
-			fi
-		    fi
-		fi
-	    fi
-	fi
-    else
-	TCL_THREADS=0
-    fi
-    # Do checking message here to not mess up interleaved configure output
-    { echo "$as_me:$LINENO: checking for building with threads" >&5
-echo $ECHO_N "checking for building with threads... $ECHO_C" >&6; }
-    if test "${TCL_THREADS}" = 1; then
-	
-cat >>confdefs.h <<\_ACEOF
-@%:@define TCL_THREADS 1
-_ACEOF
-
-	{ echo "$as_me:$LINENO: result: yes (default)" >&5
-echo "${ECHO_T}yes (default)" >&6; }
-    else
-	{ echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-    fi
-    # TCL_THREADS sanity checking.  See if our request for building with
-    # threads is the same as the way Tcl was built.  If not, warn the user.
-    case ${TCL_DEFS} in
-	*THREADS=1*)
-	    if test "${TCL_THREADS}" = "0"; then
-		{ echo "$as_me:$LINENO: WARNING: 
-    Building ${PACKAGE_NAME} without threads enabled, but building against Tcl
-    that IS thread-enabled.  It is recommended to use --enable-threads." >&5
-echo "$as_me: WARNING: 
-    Building ${PACKAGE_NAME} without threads enabled, but building against Tcl
-    that IS thread-enabled.  It is recommended to use --enable-threads." >&2;}
-	    fi
-	    ;;
-	*)
-	    if test "${TCL_THREADS}" = "1"; then
-		{ echo "$as_me:$LINENO: WARNING: 
-    --enable-threads requested, but building against a Tcl that is NOT
-    thread-enabled.  This is an OK configuration that will also run in
-    a thread-enabled core." >&5
-echo "$as_me: WARNING: 
-    --enable-threads requested, but building against a Tcl that is NOT
-    thread-enabled.  This is an OK configuration that will also run in
-    a thread-enabled core." >&2;}
-	    fi
-	    ;;
-    esac
-    
-
-
-#--------------------------------------------------------------------
-# The statement below defines a collection of symbols related to
-# building as a shared library instead of a static library.
-#--------------------------------------------------------------------
-
-
-    { echo "$as_me:$LINENO: checking how to build libraries" >&5
-echo $ECHO_N "checking how to build libraries... $ECHO_C" >&6; }
-    # Check whether --enable-shared was given.
-if test "${enable_shared+set}" = set; then
-  enableval=$enable_shared; tcl_ok=$enableval
-else
-  tcl_ok=yes
-fi
-
-
-    if test "${enable_shared+set}" = set; then
-	enableval="$enable_shared"
-	tcl_ok=$enableval
-    else
-	tcl_ok=yes
-    fi
-
-    if test "$tcl_ok" = "yes" ; then
-	{ echo "$as_me:$LINENO: result: shared" >&5
-echo "${ECHO_T}shared" >&6; }
-	SHARED_BUILD=1
-    else
-	{ echo "$as_me:$LINENO: result: static" >&5
-echo "${ECHO_T}static" >&6; }
-	SHARED_BUILD=0
-	
-cat >>confdefs.h <<\_ACEOF
-@%:@define STATIC_BUILD 1
-_ACEOF
-
-    fi
-    
-
-
-#--------------------------------------------------------------------
-# This macro figures out what flags to use with the compiler/linker
-# when building shared/static debug/optimized objects.  This information
-# can be taken from the tclConfig.sh file, but this figures it all out.
-#--------------------------------------------------------------------
-
-
-        
-
-    # Step 0.a: Enable 64 bit support?
-
-    { echo "$as_me:$LINENO: checking if 64bit support is requested" >&5
-echo $ECHO_N "checking if 64bit support is requested... $ECHO_C" >&6; }
-    # Check whether --enable-64bit was given.
-if test "${enable_64bit+set}" = set; then
-  enableval=$enable_64bit; do64bit=$enableval
-else
-  do64bit=no
-fi
-
-    { echo "$as_me:$LINENO: result: $do64bit" >&5
-echo "${ECHO_T}$do64bit" >&6; }
-
-    # Step 0.b: Enable Solaris 64 bit VIS support?
-
-    { echo "$as_me:$LINENO: checking if 64bit Sparc VIS support is requested" >&5
-echo $ECHO_N "checking if 64bit Sparc VIS support is requested... $ECHO_C" >&6; }
-    # Check whether --enable-64bit-vis was given.
-if test "${enable_64bit_vis+set}" = set; then
-  enableval=$enable_64bit_vis; do64bitVIS=$enableval
-else
-  do64bitVIS=no
-fi
-
-    { echo "$as_me:$LINENO: result: $do64bitVIS" >&5
-echo "${ECHO_T}$do64bitVIS" >&6; }
-
-    if test "$do64bitVIS" = "yes"; then
-	# Force 64bit on with VIS
-	do64bit=yes
-    fi
-
-    # Step 0.c: Cross-compiling options for Windows/CE builds?
-
-    if test "${TEA_PLATFORM}" = "windows" ; then
-	{ echo "$as_me:$LINENO: checking if Windows/CE build is requested" >&5
-echo $ECHO_N "checking if Windows/CE build is requested... $ECHO_C" >&6; }
-	# Check whether --enable-wince was given.
-if test "${enable_wince+set}" = set; then
-  enableval=$enable_wince; doWince=$enableval
-else
-  doWince=no
-fi
-
-	{ echo "$as_me:$LINENO: result: $doWince" >&5
-echo "${ECHO_T}$doWince" >&6; }
-    fi
-
-    # Step 1: set the variable "system" to hold the name and version number
-    # for the system.
-
-    
-    { echo "$as_me:$LINENO: checking system version" >&5
-echo $ECHO_N "checking system version... $ECHO_C" >&6; }
-if test "${tcl_cv_sys_version+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  
-	if test "${TEA_PLATFORM}" = "windows" ; then
-	    tcl_cv_sys_version=windows
-	elif test -f /usr/lib/NextStep/software_version; then
-	    tcl_cv_sys_version=NEXTSTEP-`awk '/3/,/3/' /usr/lib/NextStep/software_version`
-	else
-	    tcl_cv_sys_version=`uname -s`-`uname -r`
-	    if test "$?" -ne 0 ; then
-		{ echo "$as_me:$LINENO: WARNING: can't find uname command" >&5
-echo "$as_me: WARNING: can't find uname command" >&2;}
-		tcl_cv_sys_version=unknown
-	    else
-		# Special check for weird MP-RAS system (uname returns weird
-		# results, and the version is kept in special file).
-
-		if test -r /etc/.relid -a "X`uname -n`" = "X`uname -s`" ; then
-		    tcl_cv_sys_version=MP-RAS-`awk '{print $3}' /etc/.relid`
-		fi
-		if test "`uname -s`" = "AIX" ; then
-		    tcl_cv_sys_version=AIX-`uname -v`.`uname -r`
-		fi
-	    fi
-	fi
-    
-fi
-{ echo "$as_me:$LINENO: result: $tcl_cv_sys_version" >&5
-echo "${ECHO_T}$tcl_cv_sys_version" >&6; }
-    system=$tcl_cv_sys_version
-
-
-    # Step 2: check for existence of -ldl library.  This is needed because
-    # Linux can use either -ldl or -ldld for dynamic loading.
-
-    { echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5
-echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6; }
-if test "${ac_cv_lib_dl_dlopen+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-ldl  $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-/* Override any GCC internal prototype to avoid an error.
-   Use char because int might match the return type of a GCC
-   builtin and then its argument prototype would still apply.  */
-#ifdef __cplusplus
-extern "C"
-#endif
-char dlopen ();
-int
-main ()
-{
-return dlopen ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_dl_dlopen=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_lib_dl_dlopen=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5
-echo "${ECHO_T}$ac_cv_lib_dl_dlopen" >&6; }
-if test $ac_cv_lib_dl_dlopen = yes; then
-  have_dl=yes
-else
-  have_dl=no
-fi
-
-
-    # Require ranlib early so we can override it in special cases below.
-
-    
-
-    # Step 3: set configuration options based on system name and version.
-    # This is similar to Tcl's unix/tcl.m4 except that we've added a
-    # "windows" case.
-
-    do64bit_ok=no
-    LDFLAGS_ORIG="$LDFLAGS"
-    # When ld needs options to work in 64-bit mode, put them in
-    # LDFLAGS_ARCH so they eventually end up in LDFLAGS even if [load]
-    # is disabled by the user. [Bug 1016796]
-    LDFLAGS_ARCH=""
-    TCL_EXPORT_FILE_SUFFIX=""
-    UNSHARED_LIB_SUFFIX=""
-    TCL_TRIM_DOTS='`echo ${PACKAGE_VERSION} | tr -d .`'
-    ECHO_VERSION='`echo ${PACKAGE_VERSION}`'
-    TCL_LIB_VERSIONS_OK=ok
-    CFLAGS_DEBUG=-g
-    CFLAGS_OPTIMIZE=-O
-    if test "$GCC" = "yes" ; then
-	CFLAGS_OPTIMIZE=-O2
-	CFLAGS_WARNING="-Wall -Wno-implicit-int"
-    else
-	CFLAGS_WARNING=""
-    fi
-    TCL_NEEDS_EXP_FILE=0
-    TCL_BUILD_EXP_FILE=""
-    TCL_EXP_FILE=""
-    # Extract the first word of "ar", so it can be a program name with args.
-set dummy ar; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
-if test "${ac_cv_prog_AR+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$AR"; then
-  ac_cv_prog_AR="$AR" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_AR="ar"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
-
-fi
-fi
-AR=$ac_cv_prog_AR
-if test -n "$AR"; then
-  { echo "$as_me:$LINENO: result: $AR" >&5
-echo "${ECHO_T}$AR" >&6; }
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-fi
-
-
-    STLIB_LD='${AR} cr'
-    LD_LIBRARY_PATH_VAR="LD_LIBRARY_PATH"
-    case $system in
-	windows)
-	    # This is a 2-stage check to make sure we have the 64-bit SDK
-	    # We have to know where the SDK is installed.
-	    # This magic is based on MS Platform SDK for Win2003 SP1 - hobbs
-	    # MACHINE is IX86 for LINK, but this is used by the manifest,
-	    # which requires x86|amd64|ia64.
-	    MACHINE="X86"
-	    if test "$do64bit" != "no" ; then
-		if test "x${MSSDK}x" = "xx" ; then
-		    MSSDK="C:/Progra~1/Microsoft Platform SDK"
-		fi
-		MSSDK=`echo "$MSSDK" | sed -e  's!\\\!/!g'`
-		PATH64=""
-		case "$do64bit" in
-		    amd64|x64|yes)
-			MACHINE="AMD64" ; # default to AMD64 64-bit build
-			PATH64="${MSSDK}/Bin/Win64/x86/AMD64"
-			;;
-		    ia64)
-			MACHINE="IA64"
-			PATH64="${MSSDK}/Bin/Win64"
-			;;
-		esac
-		if test ! -d "${PATH64}" ; then
-		    { echo "$as_me:$LINENO: WARNING: Could not find 64-bit $MACHINE SDK to enable 64bit mode" >&5
-echo "$as_me: WARNING: Could not find 64-bit $MACHINE SDK to enable 64bit mode" >&2;}
-		    { echo "$as_me:$LINENO: WARNING: Ensure latest Platform SDK is installed" >&5
-echo "$as_me: WARNING: Ensure latest Platform SDK is installed" >&2;}
-		    do64bit="no"
-		else
-		    { echo "$as_me:$LINENO: result:    Using 64-bit $MACHINE mode" >&5
-echo "${ECHO_T}   Using 64-bit $MACHINE mode" >&6; }
-		    do64bit_ok="yes"
-		fi
-	    fi
-
-	    if test "$doWince" != "no" ; then
-		if test "$do64bit" != "no" ; then
-		    { { echo "$as_me:$LINENO: error: Windows/CE and 64-bit builds incompatible" >&5
-echo "$as_me: error: Windows/CE and 64-bit builds incompatible" >&2;}
-   { (exit 1); exit 1; }; }
-		fi
-		if test "$GCC" = "yes" ; then
-		    { { echo "$as_me:$LINENO: error: Windows/CE and GCC builds incompatible" >&5
-echo "$as_me: error: Windows/CE and GCC builds incompatible" >&2;}
-   { (exit 1); exit 1; }; }
-		fi
-		
-    # First, look for one uninstalled.
-    # the alternative search directory is invoked by --with-celib
-
-    if test x"${no_celib}" = x ; then
-	# we reset no_celib in case something fails here
-	no_celib=true
-	
-# Check whether --with-celib was given.
-if test "${with_celib+set}" = set; then
-  withval=$with_celib; with_celibconfig=${withval}
-fi
-
-	{ echo "$as_me:$LINENO: checking for Windows/CE celib directory" >&5
-echo $ECHO_N "checking for Windows/CE celib directory... $ECHO_C" >&6; }
-	if test "${ac_cv_c_celibconfig+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  
-	    # First check to see if --with-celibconfig was specified.
-	    if test x"${with_celibconfig}" != x ; then
-		if test -d "${with_celibconfig}/inc" ; then
-		    ac_cv_c_celibconfig=`(cd ${with_celibconfig}; pwd)`
-		else
-		    { { echo "$as_me:$LINENO: error: ${with_celibconfig} directory doesn't contain inc directory" >&5
-echo "$as_me: error: ${with_celibconfig} directory doesn't contain inc directory" >&2;}
-   { (exit 1); exit 1; }; }
-		fi
-	    fi
-
-	    # then check for a celib library
-	    if test x"${ac_cv_c_celibconfig}" = x ; then
-		for i in \
-			../celib-palm-3.0 \
-			../celib \
-			../../celib-palm-3.0 \
-			../../celib \
-			`ls -dr ../celib-*3.[0-9]* 2>/dev/null` \
-			${srcdir}/../celib-palm-3.0 \
-			${srcdir}/../celib \
-			`ls -dr ${srcdir}/../celib-*3.[0-9]* 2>/dev/null` \
-			; do
-		    if test -d "$i/inc" ; then
-			ac_cv_c_celibconfig=`(cd $i; pwd)`
-			break
-		    fi
-		done
-	    fi
-	
-fi
-
-	if test x"${ac_cv_c_celibconfig}" = x ; then
-	    { { echo "$as_me:$LINENO: error: Cannot find celib support library directory" >&5
-echo "$as_me: error: Cannot find celib support library directory" >&2;}
-   { (exit 1); exit 1; }; }
-	else
-	    no_celib=
-	    CELIB_DIR=${ac_cv_c_celibconfig}
-	    CELIB_DIR=`echo "$CELIB_DIR" | sed -e 's!\\\!/!g'`
-	    { echo "$as_me:$LINENO: result: found $CELIB_DIR" >&5
-echo "${ECHO_T}found $CELIB_DIR" >&6; }
-	fi
-    fi
-
-		# Set defaults for common evc4/PPC2003 setup
-		# Currently Tcl requires 300+, possibly 420+ for sockets
-		CEVERSION=420; 		# could be 211 300 301 400 420 ...
-		TARGETCPU=ARMV4;	# could be ARMV4 ARM MIPS SH3 X86 ...
-		ARCH=ARM;		# could be ARM MIPS X86EM ...
-		PLATFORM="Pocket PC 2003"; # or "Pocket PC 2002"
-		if test "$doWince" != "yes"; then
-		    # If !yes then the user specified something
-		    # Reset ARCH to allow user to skip specifying it
-		    ARCH=
-		    eval `echo $doWince | awk -F, '{ \
-	    if (length($1)) { printf "CEVERSION=\"%s\"\n", $1; \
-	    if ($1 < 400)   { printf "PLATFORM=\"Pocket PC 2002\"\n" } }; \
-	    if (length($2)) { printf "TARGETCPU=\"%s\"\n", toupper($2) }; \
-	    if (length($3)) { printf "ARCH=\"%s\"\n", toupper($3) }; \
-	    if (length($4)) { printf "PLATFORM=\"%s\"\n", $4 }; \
-		    }'`
-		    if test "x${ARCH}" = "x" ; then
-			ARCH=$TARGETCPU;
-		    fi
-		fi
-		OSVERSION=WCE$CEVERSION;
-	    	if test "x${WCEROOT}" = "x" ; then
-			WCEROOT="C:/Program Files/Microsoft eMbedded C++ 4.0"
-		    if test ! -d "${WCEROOT}" ; then
-			WCEROOT="C:/Program Files/Microsoft eMbedded Tools"
-		    fi
-		fi
-		if test "x${SDKROOT}" = "x" ; then
-		    SDKROOT="C:/Program Files/Windows CE Tools"
-		    if test ! -d "${SDKROOT}" ; then
-			SDKROOT="C:/Windows CE Tools"
-		    fi
-		fi
-		WCEROOT=`echo "$WCEROOT" | sed -e 's!\\\!/!g'`
-		SDKROOT=`echo "$SDKROOT" | sed -e 's!\\\!/!g'`
-		if test ! -d "${SDKROOT}/${OSVERSION}/${PLATFORM}/Lib/${TARGETCPU}" \
-		    -o ! -d "${WCEROOT}/EVC/${OSVERSION}/bin"; then
-		    { { echo "$as_me:$LINENO: error: could not find PocketPC SDK or target compiler to enable WinCE mode $CEVERSION,$TARGETCPU,$ARCH,$PLATFORM" >&5
-echo "$as_me: error: could not find PocketPC SDK or target compiler to enable WinCE mode $CEVERSION,$TARGETCPU,$ARCH,$PLATFORM" >&2;}
-   { (exit 1); exit 1; }; }
-		    doWince="no"
-		else
-		    # We could PATH_NOSPACE these, but that's not important,
-		    # as long as we quote them when used.
-		    CEINCLUDE="${SDKROOT}/${OSVERSION}/${PLATFORM}/include"
-		    if test -d "${CEINCLUDE}/${TARGETCPU}" ; then
-			CEINCLUDE="${CEINCLUDE}/${TARGETCPU}"
-		    fi
-		    CELIBPATH="${SDKROOT}/${OSVERSION}/${PLATFORM}/Lib/${TARGETCPU}"
-    		fi
-	    fi
-
-	    if test "$GCC" != "yes" ; then
-	        if test "${SHARED_BUILD}" = "0" ; then
-		    runtime=-MT
-	        else
-		    runtime=-MD
-	        fi
-
-                if test "$do64bit" != "no" ; then
-		    # All this magic is necessary for the Win64 SDK RC1 - hobbs
-		    CC="\"${PATH64}/cl.exe\""
-		    CFLAGS="${CFLAGS} -I\"${MSSDK}/Include\" -I\"${MSSDK}/Include/crt\" -I\"${MSSDK}/Include/crt/sys\""
-		    RC="\"${MSSDK}/bin/rc.exe\""
-		    lflags="-nologo -MACHINE:${MACHINE} -LIBPATH:\"${MSSDK}/Lib/${MACHINE}\""
-		    LINKBIN="\"${PATH64}/link.exe\""
-		    CFLAGS_DEBUG="-nologo -Zi -Od -W3 ${runtime}d"
-		    CFLAGS_OPTIMIZE="-nologo -O2 -W2 ${runtime}"
-		    # Avoid 'unresolved external symbol __security_cookie'
-		    # errors, c.f. http://support.microsoft.com/?id=894573
-		    
-    vars="bufferoverflowU.lib"
-    for i in $vars; do
-	if test "${TEA_PLATFORM}" = "windows" -a "$GCC" = "yes" ; then
-	    # Convert foo.lib to -lfoo for GCC.  No-op if not *.lib
-	    i=`echo "$i" | sed -e 's/^\([^-].*\)\.lib$/-l\1/i'`
-	fi
-	PKG_LIBS="$PKG_LIBS $i"
-    done
-    
-
-		elif test "$doWince" != "no" ; then
-		    CEBINROOT="${WCEROOT}/EVC/${OSVERSION}/bin"
-		    if test "${TARGETCPU}" = "X86"; then
-			CC="\"${CEBINROOT}/cl.exe\""
-		    else
-			CC="\"${CEBINROOT}/cl${ARCH}.exe\""
-		    fi
-		    CFLAGS="$CFLAGS -I\"${CELIB_DIR}/inc\" -I\"${CEINCLUDE}\""
-		    RC="\"${WCEROOT}/Common/EVC/bin/rc.exe\""
-		    arch=`echo ${ARCH} | awk '{print tolower($0)}'`
-		    defs="${ARCH} _${ARCH}_ ${arch} PALM_SIZE _MT _WINDOWS"
-		    if test "${SHARED_BUILD}" = "1" ; then
-			# Static CE builds require static celib as well
-		    	defs="${defs} _DLL"
-		    fi
-		    for i in $defs ; do
-			
-cat >>confdefs.h <<_ACEOF
-@%:@define $i 1
-_ACEOF
-
-		    done
-		    
-cat >>confdefs.h <<_ACEOF
-@%:@define _WIN32_WCE $CEVERSION
-_ACEOF
-
-		    
-cat >>confdefs.h <<_ACEOF
-@%:@define UNDER_CE $CEVERSION
-_ACEOF
-
-		    CFLAGS_DEBUG="-nologo -Zi -Od"
-		    CFLAGS_OPTIMIZE="-nologo -Ox"
-		    lversion=`echo ${CEVERSION} | sed -e 's/\(.\)\(..\)/\1\.\2/'`
-		    lflags="-MACHINE:${ARCH} -LIBPATH:\"${CELIBPATH}\" -subsystem:windowsce,${lversion} -nologo"
-		    LINKBIN="\"${CEBINROOT}/link.exe\""
-		    
-		else
-		    RC="rc"
-		    lflags="-nologo"
-    		    LINKBIN="link"
-		    CFLAGS_DEBUG="-nologo -Z7 -Od -W3 -WX ${runtime}d"
-		    CFLAGS_OPTIMIZE="-nologo -O2 -W2 ${runtime}"
-		fi
-	    fi
-
-	    if test "$GCC" = "yes"; then
-		# mingw gcc mode
-		RC="windres"
-		CFLAGS_DEBUG="-g"
-		CFLAGS_OPTIMIZE="-O2 -fomit-frame-pointer"
-		SHLIB_LD="$CC -shared"
-		UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.a'
-		LDFLAGS_CONSOLE="-wl,--subsystem,console ${lflags}"
-		LDFLAGS_WINDOW="-wl,--subsystem,windows ${lflags}"
-	    else
-		SHLIB_LD="${LINKBIN} -dll ${lflags}"
-		# link -lib only works when -lib is the first arg
-		STLIB_LD="${LINKBIN} -lib ${lflags}"
-		UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.lib'
-		PATHTYPE=-w
-		# For information on what debugtype is most useful, see:
-		# http://msdn.microsoft.com/library/en-us/dnvc60/html/gendepdebug.asp
-		# This essentially turns it all on.
-		LDFLAGS_DEBUG="-debug:full -debugtype:both -warn:2"
-		LDFLAGS_OPTIMIZE="-release"
-		if test "$doWince" != "no" ; then
-		    LDFLAGS_CONSOLE="-link ${lflags}"
-		    LDFLAGS_WINDOW=${LDFLAGS_CONSOLE}
-		else
-		    LDFLAGS_CONSOLE="-link -subsystem:console ${lflags}"
-		    LDFLAGS_WINDOW="-link -subsystem:windows ${lflags}"
-		fi
-	    fi
-
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".dll"
-	    SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.dll'
-
-	    TCL_LIB_VERSIONS_OK=nodots
-	    # Bogus to avoid getting this turned off
-	    DL_OBJS="tclLoadNone.obj"
-    	    ;;
-	AIX-*)
-	    if test "${TCL_THREADS}" = "1" -a "$GCC" != "yes" ; then
-		# AIX requires the _r compiler when gcc isn't being used
-		case "${CC}" in
-		    *_r)
-			# ok ...
-			;;
-		    *)
-			CC=${CC}_r
-			;;
-		esac
-		{ echo "$as_me:$LINENO: result: Using $CC for compiling with threads" >&5
-echo "${ECHO_T}Using $CC for compiling with threads" >&6; }
-	    fi
-	    LIBS="$LIBS -lc"
-	    SHLIB_CFLAGS=""
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-
-	    DL_OBJS="tclLoadDl.o"
-	    LD_LIBRARY_PATH_VAR="LIBPATH"
-
-	    # Check to enable 64-bit flags for compiler/linker on AIX 4+
-	    if test "$do64bit" = "yes" -a "`uname -v`" -gt "3" ; then
-		if test "$GCC" = "yes" ; then
-		    { echo "$as_me:$LINENO: WARNING: 64bit mode not supported with GCC on $system" >&5
-echo "$as_me: WARNING: 64bit mode not supported with GCC on $system" >&2;}
-		else 
-		    do64bit_ok=yes
-		    CFLAGS="$CFLAGS -q64"
-		    LDFLAGS_ARCH="-q64"
-		    RANLIB="${RANLIB} -X64"
-		    AR="${AR} -X64"
-		    SHLIB_LD_FLAGS="-b64"
-		fi
-	    fi
-
-	    if test "`uname -m`" = "ia64" ; then
-		# AIX-5 uses ELF style dynamic libraries on IA-64, but not PPC
-		SHLIB_LD="/usr/ccs/bin/ld -G -z text"
-		# AIX-5 has dl* in libc.so
-		DL_LIBS=""
-		if test "$GCC" = "yes" ; then
-		    CC_SEARCH_FLAGS='-Wl,-R,${LIB_RUNTIME_DIR}'
-		else
-		    CC_SEARCH_FLAGS='-R${LIB_RUNTIME_DIR}'
-		fi
-		LD_SEARCH_FLAGS='-R ${LIB_RUNTIME_DIR}'
-	    else
-		if test "$GCC" = "yes" ; then
-		    SHLIB_LD="gcc -shared"
-		else
-		    SHLIB_LD="/bin/ld -bhalt:4 -bM:SRE -bE:lib.exp -H512 -T512 -bnoentry"
-		fi
-		SHLIB_LD="${TCL_SRC_DIR}/unix/ldAix ${SHLIB_LD} ${SHLIB_LD_FLAGS}"
-		DL_LIBS="-ldl"
-		CC_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}'
-		LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
-		TCL_NEEDS_EXP_FILE=1
-		TCL_EXPORT_FILE_SUFFIX='${PACKAGE_VERSION}.exp'
-	    fi
-
-	    # AIX v<=4.1 has some different flags than 4.2+
-	    if test "$system" = "AIX-4.1" -o "`uname -v`" -lt "4" ; then
-		case " $LIB@&t at OBJS " in
-  *" tclLoadAix.$ac_objext "* ) ;;
-  *) LIB@&t at OBJS="$LIB@&t at OBJS tclLoadAix.$ac_objext"
- ;;
-esac
-
-		DL_LIBS="-lld"
-	    fi
-
-	    # On AIX <=v4 systems, libbsd.a has to be linked in to support
-	    # non-blocking file IO.  This library has to be linked in after
-	    # the MATH_LIBS or it breaks the pow() function.  The way to
-	    # insure proper sequencing, is to add it to the tail of MATH_LIBS.
-	    # This library also supplies gettimeofday.
-	    #
-	    # AIX does not have a timezone field in struct tm. When the AIX
-	    # bsd library is used, the timezone global and the gettimeofday
-	    # methods are to be avoided for timezone deduction instead, we
-	    # deduce the timezone by comparing the localtime result on a
-	    # known GMT value.
-
-	    { echo "$as_me:$LINENO: checking for gettimeofday in -lbsd" >&5
-echo $ECHO_N "checking for gettimeofday in -lbsd... $ECHO_C" >&6; }
-if test "${ac_cv_lib_bsd_gettimeofday+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-lbsd  $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-/* Override any GCC internal prototype to avoid an error.
-   Use char because int might match the return type of a GCC
-   builtin and then its argument prototype would still apply.  */
-#ifdef __cplusplus
-extern "C"
-#endif
-char gettimeofday ();
-int
-main ()
-{
-return gettimeofday ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_bsd_gettimeofday=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_lib_bsd_gettimeofday=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_bsd_gettimeofday" >&5
-echo "${ECHO_T}$ac_cv_lib_bsd_gettimeofday" >&6; }
-if test $ac_cv_lib_bsd_gettimeofday = yes; then
-  libbsd=yes
-else
-  libbsd=no
-fi
-
-	    if test $libbsd = yes; then
-	    	MATH_LIBS="$MATH_LIBS -lbsd"
-	    	
-cat >>confdefs.h <<\_ACEOF
-@%:@define USE_DELTA_FOR_TZ 1
-_ACEOF
-
-	    fi
-	    ;;
-	BeOS*)
-	    SHLIB_CFLAGS="-fPIC"
-	    SHLIB_LD="${CC} -nostart"
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS="-ldl"
-
-	    #-----------------------------------------------------------
-	    # Check for inet_ntoa in -lbind, for BeOS (which also needs
-	    # -lsocket, even if the network functions are in -lnet which
-	    # is always linked to, for compatibility.
-	    #-----------------------------------------------------------
-	    { echo "$as_me:$LINENO: checking for inet_ntoa in -lbind" >&5
-echo $ECHO_N "checking for inet_ntoa in -lbind... $ECHO_C" >&6; }
-if test "${ac_cv_lib_bind_inet_ntoa+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-lbind  $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-/* Override any GCC internal prototype to avoid an error.
-   Use char because int might match the return type of a GCC
-   builtin and then its argument prototype would still apply.  */
-#ifdef __cplusplus
-extern "C"
-#endif
-char inet_ntoa ();
-int
-main ()
-{
-return inet_ntoa ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_bind_inet_ntoa=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_lib_bind_inet_ntoa=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_bind_inet_ntoa" >&5
-echo "${ECHO_T}$ac_cv_lib_bind_inet_ntoa" >&6; }
-if test $ac_cv_lib_bind_inet_ntoa = yes; then
-  LIBS="$LIBS -lbind -lsocket"
-fi
-
-	    ;;
-	BSD/OS-2.1*|BSD/OS-3*)
-	    SHLIB_CFLAGS=""
-	    SHLIB_LD="shlicc -r"
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS="-ldl"
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    ;;
-	BSD/OS-4.*)
-	    SHLIB_CFLAGS="-export-dynamic -fPIC"
-	    SHLIB_LD="cc -shared"
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS="-ldl"
-	    LDFLAGS="$LDFLAGS -export-dynamic"
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    ;;
-	dgux*)
-	    SHLIB_CFLAGS="-K PIC"
-	    SHLIB_LD="cc -G"
-	    SHLIB_LD_LIBS=""
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS="-ldl"
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    ;;
-	HP-UX-*.11.*)
-	    # Use updated header definitions where possible
-	    
-cat >>confdefs.h <<\_ACEOF
-@%:@define _XOPEN_SOURCE_EXTENDED 1
-_ACEOF
-
-	    # Needed by Tcl, but not most extensions
-	    #AC_DEFINE(_XOPEN_SOURCE, 1, [Do we want to use the XOPEN network library?])
-	    #LIBS="$LIBS -lxnet"               # Use the XOPEN network library
-
-	    if test "`uname -m`" = "ia64" ; then
-		SHLIB_SUFFIX=".so"
-	    else
-		SHLIB_SUFFIX=".sl"
-	    fi
-	    { echo "$as_me:$LINENO: checking for shl_load in -ldld" >&5
-echo $ECHO_N "checking for shl_load in -ldld... $ECHO_C" >&6; }
-if test "${ac_cv_lib_dld_shl_load+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-ldld  $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-/* Override any GCC internal prototype to avoid an error.
-   Use char because int might match the return type of a GCC
-   builtin and then its argument prototype would still apply.  */
-#ifdef __cplusplus
-extern "C"
-#endif
-char shl_load ();
-int
-main ()
-{
-return shl_load ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_dld_shl_load=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_lib_dld_shl_load=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_dld_shl_load" >&5
-echo "${ECHO_T}$ac_cv_lib_dld_shl_load" >&6; }
-if test $ac_cv_lib_dld_shl_load = yes; then
-  tcl_ok=yes
-else
-  tcl_ok=no
-fi
-
-	    if test "$tcl_ok" = yes; then
-		SHLIB_CFLAGS="+z"
-		SHLIB_LD="ld -b"
-		SHLIB_LD_LIBS='${LIBS}'
-		DL_OBJS="tclLoadShl.o"
-		DL_LIBS="-ldld"
-		LDFLAGS="$LDFLAGS -Wl,-E"
-		CC_SEARCH_FLAGS='-Wl,+s,+b,${LIB_RUNTIME_DIR}:.'
-		LD_SEARCH_FLAGS='+s +b ${LIB_RUNTIME_DIR}:.'
-		LD_LIBRARY_PATH_VAR="SHLIB_PATH"
-	    fi
-	    if test "$GCC" = "yes" ; then
-		SHLIB_LD="gcc -shared"
-		SHLIB_LD_LIBS='${LIBS}'
-		LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
-	    fi
-
-	    # Users may want PA-RISC 1.1/2.0 portable code - needs HP cc
-	    #CFLAGS="$CFLAGS +DAportable"
-
-	    # Check to enable 64-bit flags for compiler/linker
-	    if test "$do64bit" = "yes" ; then
-		if test "$GCC" = "yes" ; then
-		    hpux_arch=`${CC} -dumpmachine`
-		    case $hpux_arch in
-			hppa64*)
-			    # 64-bit gcc in use.  Fix flags for GNU ld.
-			    do64bit_ok=yes
-			    SHLIB_LD="${CC} -shared"
-			    SHLIB_LD_LIBS='${LIBS}'
-			    CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
-			    LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
-			    ;;
-			*)
-			    { echo "$as_me:$LINENO: WARNING: 64bit mode not supported with GCC on $system" >&5
-echo "$as_me: WARNING: 64bit mode not supported with GCC on $system" >&2;}
-			    ;;
-		    esac
-		else
-		    do64bit_ok=yes
-		    CFLAGS="$CFLAGS +DD64"
-		    LDFLAGS_ARCH="+DD64"
-		fi
-	    fi
-	    ;;
-	HP-UX-*.08.*|HP-UX-*.09.*|HP-UX-*.10.*)
-	    SHLIB_SUFFIX=".sl"
-	    { echo "$as_me:$LINENO: checking for shl_load in -ldld" >&5
-echo $ECHO_N "checking for shl_load in -ldld... $ECHO_C" >&6; }
-if test "${ac_cv_lib_dld_shl_load+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-ldld  $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-/* Override any GCC internal prototype to avoid an error.
-   Use char because int might match the return type of a GCC
-   builtin and then its argument prototype would still apply.  */
-#ifdef __cplusplus
-extern "C"
-#endif
-char shl_load ();
-int
-main ()
-{
-return shl_load ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_dld_shl_load=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_lib_dld_shl_load=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_dld_shl_load" >&5
-echo "${ECHO_T}$ac_cv_lib_dld_shl_load" >&6; }
-if test $ac_cv_lib_dld_shl_load = yes; then
-  tcl_ok=yes
-else
-  tcl_ok=no
-fi
-
-	    if test "$tcl_ok" = yes; then
-		SHLIB_CFLAGS="+z"
-		SHLIB_LD="ld -b"
-		SHLIB_LD_LIBS=""
-		DL_OBJS="tclLoadShl.o"
-		DL_LIBS="-ldld"
-		LDFLAGS="$LDFLAGS -Wl,-E"
-		CC_SEARCH_FLAGS='-Wl,+s,+b,${LIB_RUNTIME_DIR}:.'
-		LD_SEARCH_FLAGS='+s +b ${LIB_RUNTIME_DIR}:.'
-		LD_LIBRARY_PATH_VAR="SHLIB_PATH"
-	    fi
-	    ;;
-	IRIX-5.*)
-	    SHLIB_CFLAGS=""
-	    SHLIB_LD="ld -shared -rdata_shared"
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS=""
-	    CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
-	    LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}'
-	    ;;
-	IRIX-6.*)
-	    SHLIB_CFLAGS=""
-	    SHLIB_LD="ld -n32 -shared -rdata_shared"
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS=""
-	    CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
-	    LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}'
-	    if test "$GCC" = "yes" ; then
-		CFLAGS="$CFLAGS -mabi=n32"
-		LDFLAGS="$LDFLAGS -mabi=n32"
-	    else
-		case $system in
-		    IRIX-6.3)
-			# Use to build 6.2 compatible binaries on 6.3.
-			CFLAGS="$CFLAGS -n32 -D_OLD_TERMIOS"
-			;;
-		    *)
-			CFLAGS="$CFLAGS -n32"
-			;;
-		esac
-		LDFLAGS="$LDFLAGS -n32"
-	    fi
-	    ;;
-	IRIX64-6.*)
-	    SHLIB_CFLAGS=""
-	    SHLIB_LD="ld -n32 -shared -rdata_shared"
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS=""
-	    CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
-	    LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}'
-
-	    # Check to enable 64-bit flags for compiler/linker
-
-	    if test "$do64bit" = "yes" ; then
-	        if test "$GCC" = "yes" ; then
-	            { echo "$as_me:$LINENO: WARNING: 64bit mode not supported by gcc" >&5
-echo "$as_me: WARNING: 64bit mode not supported by gcc" >&2;}
-	        else
-	            do64bit_ok=yes
-	            SHLIB_LD="ld -64 -shared -rdata_shared"
-	            CFLAGS="$CFLAGS -64"
-	            LDFLAGS_ARCH="-64"
-	        fi
-	    fi
-	    ;;
-	Linux*)
-	    SHLIB_CFLAGS="-fPIC"
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-
-	    CFLAGS_OPTIMIZE="-O2 -fomit-frame-pointer"
-	    # egcs-2.91.66 on Redhat Linux 6.0 generates lots of warnings 
-	    # when you inline the string and math operations.  Turn this off to
-	    # get rid of the warnings.
-	    #CFLAGS_OPTIMIZE="${CFLAGS_OPTIMIZE} -D__NO_STRING_INLINES -D__NO_MATH_INLINES"
-
-	    # TEA specific: use LDFLAGS_DEFAULT instead of LDFLAGS here:
-	    SHLIB_LD='${CC} -shared ${CFLAGS} ${LDFLAGS_DEFAULT}'
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS="-ldl"
-	    LDFLAGS="$LDFLAGS -Wl,--export-dynamic"
-	    CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
-	    LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
-	    if test "`uname -m`" = "alpha" ; then
-		CFLAGS="$CFLAGS -mieee"
-	    fi
-	    if test $do64bit = yes; then
-		{ echo "$as_me:$LINENO: checking if compiler accepts -m64 flag" >&5
-echo $ECHO_N "checking if compiler accepts -m64 flag... $ECHO_C" >&6; }
-if test "${tcl_cv_cc_m64+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  
-		    hold_cflags=$CFLAGS
-		    CFLAGS="$CFLAGS -m64"
-		    cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-int
-main ()
-{
-
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  tcl_cv_cc_m64=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	tcl_cv_cc_m64=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-		    CFLAGS=$hold_cflags
-fi
-{ echo "$as_me:$LINENO: result: $tcl_cv_cc_m64" >&5
-echo "${ECHO_T}$tcl_cv_cc_m64" >&6; }
-		if test $tcl_cv_cc_m64 = yes; then
-		    CFLAGS="$CFLAGS -m64"
-		    do64bit_ok=yes
-		fi
-	    fi
-
-	    # The combo of gcc + glibc has a bug related
-	    # to inlining of functions like strtod(). The
-	    # -fno-builtin flag should address this problem
-	    # but it does not work. The -fno-inline flag
-	    # is kind of overkill but it works.
-	    # Disable inlining only when one of the
-	    # files in compat/*.c is being linked in.
-	    if test x"${USE_COMPAT}" != x ; then
-	        CFLAGS="$CFLAGS -fno-inline"
-	    fi
-
-	    ;;
-	GNU*)
-	    SHLIB_CFLAGS="-fPIC"
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-
-	    SHLIB_LD="${CC} -shared"
-	    DL_OBJS=""
-	    DL_LIBS="-ldl"
-	    LDFLAGS="$LDFLAGS -Wl,--export-dynamic"
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    if test "`uname -m`" = "alpha" ; then
-		CFLAGS="$CFLAGS -mieee"
-	    fi
-	    ;;
-	Lynx*)
-	    SHLIB_CFLAGS="-fPIC"
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-	    CFLAGS_OPTIMIZE=-02
-	    SHLIB_LD="${CC} -shared "
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS="-mshared -ldl"
-	    LD_FLAGS="-Wl,--export-dynamic"
-	    CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
-	    LD_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
-	    ;;
-	MP-RAS-02*)
-	    SHLIB_CFLAGS="-K PIC"
-	    SHLIB_LD="cc -G"
-	    SHLIB_LD_LIBS=""
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS="-ldl"
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    ;;
-	MP-RAS-*)
-	    SHLIB_CFLAGS="-K PIC"
-	    SHLIB_LD="cc -G"
-	    SHLIB_LD_LIBS=""
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS="-ldl"
-	    LDFLAGS="$LDFLAGS -Wl,-Bexport"
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    ;;
-	NetBSD-*|FreeBSD-[1-2].*)
-	    # NetBSD/SPARC needs -fPIC, -fpic will not do.
-	    SHLIB_CFLAGS="-fPIC"
-	    SHLIB_LD="ld -Bshareable -x"
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS=""
-	    CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
-	    LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}'
-	    { echo "$as_me:$LINENO: checking for ELF" >&5
-echo $ECHO_N "checking for ELF... $ECHO_C" >&6; }
-if test "${tcl_cv_ld_elf+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  
-		cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-#ifdef __ELF__
-	yes
-#endif
-		
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-  $EGREP "yes" >/dev/null 2>&1; then
-  tcl_cv_ld_elf=yes
-else
-  tcl_cv_ld_elf=no
-fi
-rm -f conftest*
-
-fi
-{ echo "$as_me:$LINENO: result: $tcl_cv_ld_elf" >&5
-echo "${ECHO_T}$tcl_cv_ld_elf" >&6; }
-	    if test $tcl_cv_ld_elf = yes; then
-		SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.so'
-	    else
-		SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.so.1.0'
-	    fi
-
-	    # Ancient FreeBSD doesn't handle version numbers with dots.
-
-	    UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.a'
-	    TCL_LIB_VERSIONS_OK=nodots
-	    ;;
-	OpenBSD-*)
-	    # OpenBSD/SPARC[64] needs -fPIC, -fpic will not do.
-	    case `machine` in
-	    sparc|sparc64)
-		SHLIB_CFLAGS="-fPIC";;
-	    *)
-		SHLIB_CFLAGS="-fpic";;
-	    esac
-	    SHLIB_LD="${CC} -shared ${SHLIB_CFLAGS}"
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS=""
-	    CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
-	    LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
-	    SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.so.1.0'
-	    { echo "$as_me:$LINENO: checking for ELF" >&5
-echo $ECHO_N "checking for ELF... $ECHO_C" >&6; }
-if test "${tcl_cv_ld_elf+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  
-		cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-#ifdef __ELF__
-	yes
-#endif
-		
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-  $EGREP "yes" >/dev/null 2>&1; then
-  tcl_cv_ld_elf=yes
-else
-  tcl_cv_ld_elf=no
-fi
-rm -f conftest*
-
-fi
-{ echo "$as_me:$LINENO: result: $tcl_cv_ld_elf" >&5
-echo "${ECHO_T}$tcl_cv_ld_elf" >&6; }
-	    if test $tcl_cv_ld_elf = yes; then
-		LDFLAGS=-Wl,-export-dynamic
-	    else
-		LDFLAGS=""
-	    fi
-
-	    # OpenBSD doesn't do version numbers with dots.
-	    UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.a'
-	    TCL_LIB_VERSIONS_OK=nodots
-	    ;;
-	FreeBSD-*)
-	    # FreeBSD 3.* and greater have ELF.
-	    SHLIB_CFLAGS="-fPIC"
-	    SHLIB_LD="ld -Bshareable -x"
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS=""
-	    LDFLAGS="$LDFLAGS -export-dynamic"
-	    CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
-	    LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}'
-	    if test "${TCL_THREADS}" = "1" ; then
-		# The -pthread needs to go in the CFLAGS, not LIBS
-		LIBS=`echo $LIBS | sed s/-pthread//`
-		CFLAGS="$CFLAGS -pthread"
-	    	LDFLAGS="$LDFLAGS -pthread"
-	    fi
-	    case $system in
-	    FreeBSD-3.*)
-	    	# FreeBSD-3 doesn't handle version numbers with dots.
-	    	UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.a'
-	    	SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.so'
-	    	TCL_LIB_VERSIONS_OK=nodots
-		;;
-	    esac
-	    ;;
-	Darwin-*)
-	    CFLAGS_OPTIMIZE="-Os"
-	    SHLIB_CFLAGS="-fno-common"
-	    # To avoid discrepancies between what headers configure sees during
-	    # preprocessing tests and compiling tests, move any -isysroot and
-	    # -mmacosx-version-min flags from CFLAGS to CPPFLAGS:
-	    CPPFLAGS="${CPPFLAGS} `echo " ${CFLAGS}" | \
-		awk 'BEGIN {FS=" +-";ORS=" "}; {for (i=2;i<=NF;i++) \
-		if ($i~/^(isysroot|mmacosx-version-min)/) print "-"$i}'`"
-	    CFLAGS="`echo " ${CFLAGS}" | \
-		awk 'BEGIN {FS=" +-";ORS=" "}; {for (i=2;i<=NF;i++) \
-		if (!($i~/^(isysroot|mmacosx-version-min)/)) print "-"$i}'`"
-	    if test $do64bit = yes; then
-		case `arch` in
-		    ppc)
-			{ echo "$as_me:$LINENO: checking if compiler accepts -arch ppc64 flag" >&5
-echo $ECHO_N "checking if compiler accepts -arch ppc64 flag... $ECHO_C" >&6; }
-if test "${tcl_cv_cc_arch_ppc64+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  
-			    hold_cflags=$CFLAGS
-			    CFLAGS="$CFLAGS -arch ppc64 -mpowerpc64 -mcpu=G5"
-			    cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-int
-main ()
-{
-
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  tcl_cv_cc_arch_ppc64=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	tcl_cv_cc_arch_ppc64=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-			    CFLAGS=$hold_cflags
-fi
-{ echo "$as_me:$LINENO: result: $tcl_cv_cc_arch_ppc64" >&5
-echo "${ECHO_T}$tcl_cv_cc_arch_ppc64" >&6; }
-			if test $tcl_cv_cc_arch_ppc64 = yes; then
-			    CFLAGS="$CFLAGS -arch ppc64 -mpowerpc64 -mcpu=G5"
-			    do64bit_ok=yes
-			fi;;
-		    i386)
-			{ echo "$as_me:$LINENO: checking if compiler accepts -arch x86_64 flag" >&5
-echo $ECHO_N "checking if compiler accepts -arch x86_64 flag... $ECHO_C" >&6; }
-if test "${tcl_cv_cc_arch_x86_64+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  
-			    hold_cflags=$CFLAGS
-			    CFLAGS="$CFLAGS -arch x86_64"
-			    cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-int
-main ()
-{
-
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  tcl_cv_cc_arch_x86_64=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	tcl_cv_cc_arch_x86_64=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-			    CFLAGS=$hold_cflags
-fi
-{ echo "$as_me:$LINENO: result: $tcl_cv_cc_arch_x86_64" >&5
-echo "${ECHO_T}$tcl_cv_cc_arch_x86_64" >&6; }
-			if test $tcl_cv_cc_arch_x86_64 = yes; then
-			    CFLAGS="$CFLAGS -arch x86_64"
-			    do64bit_ok=yes
-			fi;;
-		    *)
-			{ echo "$as_me:$LINENO: WARNING: Don't know how enable 64-bit on architecture \`arch\`" >&5
-echo "$as_me: WARNING: Don't know how enable 64-bit on architecture \`arch\`" >&2;};;
-		esac
-	    else
-		# Check for combined 32-bit and 64-bit fat build
-		echo "$CFLAGS " | grep -E -q -- '-arch (ppc64|x86_64) ' && \
-		    echo "$CFLAGS " | grep -E -q -- '-arch (ppc|i386) ' && \
-		    fat_32_64=yes
-	    fi
-	    # TEA specific: use LDFLAGS_DEFAULT instead of LDFLAGS here:
-	    SHLIB_LD='${CC} -dynamiclib ${CFLAGS} ${LDFLAGS_DEFAULT}'
-	    { echo "$as_me:$LINENO: checking if ld accepts -single_module flag" >&5
-echo $ECHO_N "checking if ld accepts -single_module flag... $ECHO_C" >&6; }
-if test "${tcl_cv_ld_single_module+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  
-		hold_ldflags=$LDFLAGS
-		LDFLAGS="$LDFLAGS -dynamiclib -Wl,-single_module"
-		cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-int
-main ()
-{
-int i;
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  tcl_cv_ld_single_module=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	tcl_cv_ld_single_module=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-		LDFLAGS=$hold_ldflags
-fi
-{ echo "$as_me:$LINENO: result: $tcl_cv_ld_single_module" >&5
-echo "${ECHO_T}$tcl_cv_ld_single_module" >&6; }
-	    if test $tcl_cv_ld_single_module = yes; then
-		SHLIB_LD="${SHLIB_LD} -Wl,-single_module"
-	    fi
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".dylib"
-	    DL_OBJS="tclLoadDyld.o"
-	    DL_LIBS=""
-	    # Don't use -prebind when building for Mac OS X 10.4 or later only:
-	    test "`echo "${MACOSX_DEPLOYMENT_TARGET}" | awk -F '10\\.' '{print int($2)}'`" -lt 4 -a \
-		"`echo "${CPPFLAGS}" | awk -F '-mmacosx-version-min=10\\.' '{print int($2)}'`" -lt 4 && \
-		LDFLAGS="$LDFLAGS -prebind"
-	    LDFLAGS="$LDFLAGS -headerpad_max_install_names"
-	    { echo "$as_me:$LINENO: checking if ld accepts -search_paths_first flag" >&5
-echo $ECHO_N "checking if ld accepts -search_paths_first flag... $ECHO_C" >&6; }
-if test "${tcl_cv_ld_search_paths_first+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  
-		hold_ldflags=$LDFLAGS
-		LDFLAGS="$LDFLAGS -Wl,-search_paths_first"
-		cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-int
-main ()
-{
-int i;
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  tcl_cv_ld_search_paths_first=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	tcl_cv_ld_search_paths_first=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-		LDFLAGS=$hold_ldflags
-fi
-{ echo "$as_me:$LINENO: result: $tcl_cv_ld_search_paths_first" >&5
-echo "${ECHO_T}$tcl_cv_ld_search_paths_first" >&6; }
-	    if test $tcl_cv_ld_search_paths_first = yes; then
-		LDFLAGS="$LDFLAGS -Wl,-search_paths_first"
-	    fi
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    LD_LIBRARY_PATH_VAR="DYLD_LIBRARY_PATH"
-
-	    # TEA specific: for Tk extensions, remove 64-bit arch flags from
-	    # CFLAGS et al. for combined 32 & 64 bit fat builds as neither
-	    # TkAqua nor TkX11 can be built for 64-bit at present.
-	    test "$fat_32_64" = yes && test -n "${TK_BIN_DIR}" && for v in CFLAGS CPPFLAGS LDFLAGS; do
-		eval $v'="`echo "$'$v' "|sed -e "s/-arch ppc64 / /g" -e "s/-arch x86_64 / /g"`"'; done
-	    ;;
-	NEXTSTEP-*)
-	    SHLIB_CFLAGS=""
-	    SHLIB_LD="cc -nostdlib -r"
-	    SHLIB_LD_LIBS=""
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadNext.o"
-	    DL_LIBS=""
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    ;;
-	OS/390-*)
-	    CFLAGS_OPTIMIZE=""		# Optimizer is buggy
-	    
-cat >>confdefs.h <<\_ACEOF
-@%:@define _OE_SOCKETS 1
-_ACEOF
-
-	    ;;      
-	OSF1-1.0|OSF1-1.1|OSF1-1.2)
-	    # OSF/1 1.[012] from OSF, and derivatives, including Paragon OSF/1
-	    SHLIB_CFLAGS=""
-	    # Hack: make package name same as library name
-	    SHLIB_LD='ld -R -export :'
-	    SHLIB_LD_LIBS=""
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadOSF.o"
-	    DL_LIBS=""
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    ;;
-	OSF1-1.*)
-	    # OSF/1 1.3 from OSF using ELF, and derivatives, including AD2
-	    SHLIB_CFLAGS="-fPIC"
-	    if test "$SHARED_BUILD" = "1" ; then
-	        SHLIB_LD="ld -shared"
-	    else
-	        SHLIB_LD="ld -non_shared"
-	    fi
-	    SHLIB_LD_LIBS=""
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS=""
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    ;;
-	OSF1-V*)
-	    # Digital OSF/1
-	    SHLIB_CFLAGS=""
-	    if test "$SHARED_BUILD" = "1" ; then
-	        SHLIB_LD='ld -shared -expect_unresolved "*"'
-	    else
-	        SHLIB_LD='ld -non_shared -expect_unresolved "*"'
-	    fi
-	    SHLIB_LD_LIBS=""
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS=""
-	    CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
-	    LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}'
-	    if test "$GCC" = "yes" ; then
-		CFLAGS="$CFLAGS -mieee"
-            else
-		CFLAGS="$CFLAGS -DHAVE_TZSET -std1 -ieee"
-	    fi
-	    # see pthread_intro(3) for pthread support on osf1, k.furukawa
-	    if test "${TCL_THREADS}" = "1" ; then
-		CFLAGS="$CFLAGS -DHAVE_PTHREAD_ATTR_SETSTACKSIZE"
-		CFLAGS="$CFLAGS -DTCL_THREAD_STACK_MIN=PTHREAD_STACK_MIN*64"
-		LIBS=`echo $LIBS | sed s/-lpthreads//`
-		if test "$GCC" = "yes" ; then
-		    LIBS="$LIBS -lpthread -lmach -lexc"
-		else
-		    CFLAGS="$CFLAGS -pthread"
-		    LDFLAGS="$LDFLAGS -pthread"
-		fi
-	    fi
-
-	    ;;
-	QNX-6*)
-	    # QNX RTP
-	    # This may work for all QNX, but it was only reported for v6.
-	    SHLIB_CFLAGS="-fPIC"
-	    SHLIB_LD="ld -Bshareable -x"
-	    SHLIB_LD_LIBS=""
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    # dlopen is in -lc on QNX
-	    DL_LIBS=""
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    ;;
-	SCO_SV-3.2*)
-	    # Note, dlopen is available only on SCO 3.2.5 and greater. However,
-	    # this test works, since "uname -s" was non-standard in 3.2.4 and
-	    # below.
-	    if test "$GCC" = "yes" ; then
-	    	SHLIB_CFLAGS="-fPIC -melf"
-	    	LDFLAGS="$LDFLAGS -melf -Wl,-Bexport"
-	    else
-	    	SHLIB_CFLAGS="-Kpic -belf"
-	    	LDFLAGS="$LDFLAGS -belf -Wl,-Bexport"
-	    fi
-	    SHLIB_LD="ld -G"
-	    SHLIB_LD_LIBS=""
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS=""
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    ;;
-	SINIX*5.4*)
-	    SHLIB_CFLAGS="-K PIC"
-	    SHLIB_LD="cc -G"
-	    SHLIB_LD_LIBS=""
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS="-ldl"
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    ;;
-	SunOS-4*)
-	    SHLIB_CFLAGS="-PIC"
-	    SHLIB_LD="ld"
-	    SHLIB_LD_LIBS=""
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS="-ldl"
-	    CC_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}'
-	    LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
-
-	    # SunOS can't handle version numbers with dots in them in library
-	    # specs, like -ltcl7.5, so use -ltcl75 instead.  Also, it
-	    # requires an extra version number at the end of .so file names.
-	    # So, the library has to have a name like libtcl75.so.1.0
-
-	    SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.so.1.0'
-	    UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.a'
-	    TCL_LIB_VERSIONS_OK=nodots
-	    ;;
-	SunOS-5.[0-6])
-	    # Careful to not let 5.10+ fall into this case
-
-	    # Note: If _REENTRANT isn't defined, then Solaris
-	    # won't define thread-safe library routines.
-
-	    
-cat >>confdefs.h <<\_ACEOF
-@%:@define _REENTRANT 1
-_ACEOF
-
-	    
-cat >>confdefs.h <<\_ACEOF
-@%:@define _POSIX_PTHREAD_SEMANTICS 1
-_ACEOF
-
-
-	    SHLIB_CFLAGS="-KPIC"
-
-	    # Note: need the LIBS below, otherwise Tk won't find Tcl's
-	    # symbols when dynamically loaded into tclsh.
-
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS="-ldl"
-	    if test "$GCC" = "yes" ; then
-		SHLIB_LD="$CC -shared"
-		CC_SEARCH_FLAGS='-Wl,-R,${LIB_RUNTIME_DIR}'
-		LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
-	    else
-		SHLIB_LD="/usr/ccs/bin/ld -G -z text"
-		CC_SEARCH_FLAGS='-R ${LIB_RUNTIME_DIR}'
-		LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
-	    fi
-	    ;;
-	SunOS-5*)
-	    # Note: If _REENTRANT isn't defined, then Solaris
-	    # won't define thread-safe library routines.
-
-	    
-cat >>confdefs.h <<\_ACEOF
-@%:@define _REENTRANT 1
-_ACEOF
-
-	    
-cat >>confdefs.h <<\_ACEOF
-@%:@define _POSIX_PTHREAD_SEMANTICS 1
-_ACEOF
-
-
-	    SHLIB_CFLAGS="-KPIC"
-
-	    # Check to enable 64-bit flags for compiler/linker
-	    if test "$do64bit" = "yes" ; then
-		arch=`isainfo`
-		if test "$arch" = "sparcv9 sparc" ; then
-			if test "$GCC" = "yes" ; then
-			    if test "`gcc -dumpversion | awk -F. '{print $1}'`" -lt "3" ; then
-				{ echo "$as_me:$LINENO: WARNING: 64bit mode not supported with GCC < 3.2 on $system" >&5
-echo "$as_me: WARNING: 64bit mode not supported with GCC < 3.2 on $system" >&2;}
-			    else
-				do64bit_ok=yes
-				CFLAGS="$CFLAGS -m64 -mcpu=v9"
-				LDFLAGS="$LDFLAGS -m64 -mcpu=v9"
-				SHLIB_CFLAGS="-fPIC"
-			    fi
-			else
-			    do64bit_ok=yes
-			    if test "$do64bitVIS" = "yes" ; then
-				CFLAGS="$CFLAGS -xarch=v9a"
-			    	LDFLAGS_ARCH="-xarch=v9a"
-			    else
-				CFLAGS="$CFLAGS -xarch=v9"
-			    	LDFLAGS_ARCH="-xarch=v9"
-			    fi
-			    # Solaris 64 uses this as well
-			    #LD_LIBRARY_PATH_VAR="LD_LIBRARY_PATH_64"
-			fi
-		elif test "$arch" = "amd64 i386" ; then
-		    if test "$GCC" = "yes" ; then
-			{ echo "$as_me:$LINENO: WARNING: 64bit mode not supported with GCC on $system" >&5
-echo "$as_me: WARNING: 64bit mode not supported with GCC on $system" >&2;}
-		    else
-			do64bit_ok=yes
-			CFLAGS="$CFLAGS -xarch=amd64"
-			LDFLAGS="$LDFLAGS -xarch=amd64"
-		    fi
-		else
-		    { echo "$as_me:$LINENO: WARNING: 64bit mode not supported for $arch" >&5
-echo "$as_me: WARNING: 64bit mode not supported for $arch" >&2;}
-		fi
-	    fi
-	    
-	    # Note: need the LIBS below, otherwise Tk won't find Tcl's
-	    # symbols when dynamically loaded into tclsh.
-
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS="-ldl"
-	    if test "$GCC" = "yes" ; then
-		SHLIB_LD="$CC -shared"
-		CC_SEARCH_FLAGS='-Wl,-R,${LIB_RUNTIME_DIR}'
-		LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
-		if test "$do64bit_ok" = "yes" ; then
-		    # We need to specify -static-libgcc or we need to
-		    # add the path to the sparv9 libgcc.
-		    # JH: static-libgcc is necessary for core Tcl, but may
-		    # not be necessary for extensions.
-		    SHLIB_LD="$SHLIB_LD -m64 -mcpu=v9 -static-libgcc"
-		    # for finding sparcv9 libgcc, get the regular libgcc
-		    # path, remove so name and append 'sparcv9'
-		    #v9gcclibdir="`gcc -print-file-name=libgcc_s.so` | ..."
-		    #CC_SEARCH_FLAGS="${CC_SEARCH_FLAGS},-R,$v9gcclibdir"
-		fi
-	    else
-		SHLIB_LD="/usr/ccs/bin/ld -G -z text"
-		CC_SEARCH_FLAGS='-Wl,-R,${LIB_RUNTIME_DIR}'
-		LD_SEARCH_FLAGS='-R ${LIB_RUNTIME_DIR}'
-	    fi
-	    ;;
-	UNIX_SV* | UnixWare-5*)
-	    SHLIB_CFLAGS="-KPIC"
-	    SHLIB_LD="cc -G"
-	    SHLIB_LD_LIBS=""
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS="-ldl"
-	    # Some UNIX_SV* systems (unixware 1.1.2 for example) have linkers
-	    # that don't grok the -Bexport option.  Test that it does.
-	    { echo "$as_me:$LINENO: checking for ld accepts -Bexport flag" >&5
-echo $ECHO_N "checking for ld accepts -Bexport flag... $ECHO_C" >&6; }
-if test "${tcl_cv_ld_Bexport+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  
-		hold_ldflags=$LDFLAGS
-		LDFLAGS="$LDFLAGS -Wl,-Bexport"
-		cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-int
-main ()
-{
-int i;
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  tcl_cv_ld_Bexport=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	tcl_cv_ld_Bexport=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-	        LDFLAGS=$hold_ldflags
-fi
-{ echo "$as_me:$LINENO: result: $tcl_cv_ld_Bexport" >&5
-echo "${ECHO_T}$tcl_cv_ld_Bexport" >&6; }
-	    if test $tcl_cv_ld_Bexport = yes; then
-		LDFLAGS="$LDFLAGS -Wl,-Bexport"
-	    fi
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    ;;
-    esac
-
-    if test "$do64bit" = "yes" -a "$do64bit_ok" = "no" ; then
-	{ echo "$as_me:$LINENO: WARNING: 64bit support being disabled -- don't know magic for this platform" >&5
-echo "$as_me: WARNING: 64bit support being disabled -- don't know magic for this platform" >&2;}
-    fi
-
-    
-
-    # Step 4: disable dynamic loading if requested via a command-line switch.
-
-    # Check whether --enable-load was given.
-if test "${enable_load+set}" = set; then
-  enableval=$enable_load; tcl_ok=$enableval
-else
-  tcl_ok=yes
-fi
-
-    if test "$tcl_ok" = "no"; then
-	DL_OBJS=""
-    fi
-
-    if test "x$DL_OBJS" != "x" ; then
-	BUILD_DLTEST="\$(DLTEST_TARGETS)"
-    else
-	echo "Can't figure out how to do dynamic loading or shared libraries"
-	echo "on this system."
-	SHLIB_CFLAGS=""
-	SHLIB_LD=""
-	SHLIB_SUFFIX=""
-	DL_OBJS="tclLoadNone.o"
-	DL_LIBS=""
-	LDFLAGS="$LDFLAGS_ORIG"
-	CC_SEARCH_FLAGS=""
-	LD_SEARCH_FLAGS=""
-	BUILD_DLTEST=""
-    fi
-    LDFLAGS="$LDFLAGS $LDFLAGS_ARCH"
-
-    # If we're running gcc, then change the C flags for compiling shared
-    # libraries to the right flags for gcc, instead of those for the
-    # standard manufacturer compiler.
-
-    if test "$DL_OBJS" != "tclLoadNone.o" ; then
-	if test "$GCC" = "yes" ; then
-	    case $system in
-		AIX-*)
-		    ;;
-		BSD/OS*)
-		    ;;
-		IRIX*)
-		    ;;
-		NetBSD-*|FreeBSD-*)
-		    ;;
-		Darwin-*)
-		    ;;
-		SCO_SV-3.2*)
-		    ;;
-		windows)
-		    ;;
-		*)
-		    SHLIB_CFLAGS="-fPIC"
-		    ;;
-	    esac
-	fi
-    fi
-
-    if test "$SHARED_LIB_SUFFIX" = "" ; then
-	SHARED_LIB_SUFFIX='${PACKAGE_VERSION}${SHLIB_SUFFIX}'
-    fi
-    if test "$UNSHARED_LIB_SUFFIX" = "" ; then
-	UNSHARED_LIB_SUFFIX='${PACKAGE_VERSION}.a'
-    fi
-
-    
-
-    
-    
-    
-
-    
-    
-
-    
-    
-
-    
-
-    # These must be called after we do the basic CFLAGS checks and
-    # verify any possible 64-bit or similar switches are necessary
-    
-    { echo "$as_me:$LINENO: checking for required early compiler flags" >&5
-echo $ECHO_N "checking for required early compiler flags... $ECHO_C" >&6; }
-    tcl_flags=""
-    
-    if test "${tcl_cv_flag__isoc99_source+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <stdlib.h>
-int
-main ()
-{
-char *p = (char *)strtoll; char *q = (char *)strtoull;
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  tcl_cv_flag__isoc99_source=no
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#define _ISOC99_SOURCE 1
-#include <stdlib.h>
-int
-main ()
-{
-char *p = (char *)strtoll; char *q = (char *)strtoull;
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  tcl_cv_flag__isoc99_source=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	tcl_cv_flag__isoc99_source=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
-    if test "x${tcl_cv_flag__isoc99_source}" = "xyes" ; then
-	
-cat >>confdefs.h <<\_ACEOF
-@%:@define _ISOC99_SOURCE 1
-_ACEOF
-
-	tcl_flags="$tcl_flags _ISOC99_SOURCE"
-    fi
-
-    
-    if test "${tcl_cv_flag__largefile64_source+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <sys/stat.h>
-int
-main ()
-{
-struct stat64 buf; int i = stat64("/", &buf);
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  tcl_cv_flag__largefile64_source=no
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#define _LARGEFILE64_SOURCE 1
-#include <sys/stat.h>
-int
-main ()
-{
-struct stat64 buf; int i = stat64("/", &buf);
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  tcl_cv_flag__largefile64_source=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	tcl_cv_flag__largefile64_source=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
-    if test "x${tcl_cv_flag__largefile64_source}" = "xyes" ; then
-	
-cat >>confdefs.h <<\_ACEOF
-@%:@define _LARGEFILE64_SOURCE 1
-_ACEOF
-
-	tcl_flags="$tcl_flags _LARGEFILE64_SOURCE"
-    fi
-
-    
-    if test "${tcl_cv_flag__largefile_source64+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <sys/stat.h>
-int
-main ()
-{
-char *p = (char *)open64;
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  tcl_cv_flag__largefile_source64=no
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#define _LARGEFILE_SOURCE64 1
-#include <sys/stat.h>
-int
-main ()
-{
-char *p = (char *)open64;
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  tcl_cv_flag__largefile_source64=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	tcl_cv_flag__largefile_source64=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
-    if test "x${tcl_cv_flag__largefile_source64}" = "xyes" ; then
-	
-cat >>confdefs.h <<\_ACEOF
-@%:@define _LARGEFILE_SOURCE64 1
-_ACEOF
-
-	tcl_flags="$tcl_flags _LARGEFILE_SOURCE64"
-    fi
-
-    if test "x${tcl_flags}" = "x" ; then
-	{ echo "$as_me:$LINENO: result: none" >&5
-echo "${ECHO_T}none" >&6; }
-    else
-	{ echo "$as_me:$LINENO: result: ${tcl_flags}" >&5
-echo "${ECHO_T}${tcl_flags}" >&6; }
-    fi
-
-    
-    { echo "$as_me:$LINENO: checking for 64-bit integer type" >&5
-echo $ECHO_N "checking for 64-bit integer type... $ECHO_C" >&6; }
-    if test "${tcl_cv_type_64bit+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  
-	tcl_cv_type_64bit=none
-	# See if the compiler knows natively about __int64
-	cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-int
-main ()
-{
-__int64 value = (__int64) 0;
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  tcl_type_64bit=__int64
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	tcl_type_64bit="long long"
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-	# See if we should use long anyway  Note that we substitute in the
-	# type that is our current guess for a 64-bit type inside this check
-	# program, so it should be modified only carefully...
-        cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-int
-main ()
-{
-switch (0) { 
-            case 1: case (sizeof(${tcl_type_64bit})==sizeof(long)): ; 
-        }
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  tcl_cv_type_64bit=${tcl_type_64bit}
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
-    if test "${tcl_cv_type_64bit}" = none ; then
-	
-cat >>confdefs.h <<\_ACEOF
-@%:@define TCL_WIDE_INT_IS_LONG 1
-_ACEOF
-
-	{ echo "$as_me:$LINENO: result: using long" >&5
-echo "${ECHO_T}using long" >&6; }
-    elif test "${tcl_cv_type_64bit}" = "__int64" \
-		-a "${TEA_PLATFORM}" = "windows" ; then
-	# We actually want to use the default tcl.h checks in this
-	# case to handle both TCL_WIDE_INT_TYPE and TCL_LL_MODIFIER*
-	{ echo "$as_me:$LINENO: result: using Tcl header defaults" >&5
-echo "${ECHO_T}using Tcl header defaults" >&6; }
-    else
-	
-cat >>confdefs.h <<_ACEOF
-@%:@define TCL_WIDE_INT_TYPE ${tcl_cv_type_64bit}
-_ACEOF
-
-	{ echo "$as_me:$LINENO: result: ${tcl_cv_type_64bit}" >&5
-echo "${ECHO_T}${tcl_cv_type_64bit}" >&6; }
-
-	# Now check for auxiliary declarations
-	{ echo "$as_me:$LINENO: checking for struct dirent64" >&5
-echo $ECHO_N "checking for struct dirent64... $ECHO_C" >&6; }
-if test "${tcl_cv_struct_dirent64+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  
-	    cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <sys/types.h>
-#include <sys/dirent.h>
-int
-main ()
-{
-struct dirent64 p;
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  tcl_cv_struct_dirent64=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	tcl_cv_struct_dirent64=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-{ echo "$as_me:$LINENO: result: $tcl_cv_struct_dirent64" >&5
-echo "${ECHO_T}$tcl_cv_struct_dirent64" >&6; }
-	if test "x${tcl_cv_struct_dirent64}" = "xyes" ; then
-	    
-cat >>confdefs.h <<\_ACEOF
-@%:@define HAVE_STRUCT_DIRENT64 1
-_ACEOF
-
-	fi
-
-	{ echo "$as_me:$LINENO: checking for struct stat64" >&5
-echo $ECHO_N "checking for struct stat64... $ECHO_C" >&6; }
-if test "${tcl_cv_struct_stat64+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  
-	    cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <sys/stat.h>
-int
-main ()
-{
-struct stat64 p;
-
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  tcl_cv_struct_stat64=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	tcl_cv_struct_stat64=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-{ echo "$as_me:$LINENO: result: $tcl_cv_struct_stat64" >&5
-echo "${ECHO_T}$tcl_cv_struct_stat64" >&6; }
-	if test "x${tcl_cv_struct_stat64}" = "xyes" ; then
-	    
-cat >>confdefs.h <<\_ACEOF
-@%:@define HAVE_STRUCT_STAT64 1
-_ACEOF
-
-	fi
-
-	
-
-for ac_func in open64 lseek64
-do
-as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
-{ echo "$as_me:$LINENO: checking for $ac_func" >&5
-echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
-if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
-   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
-#define $ac_func innocuous_$ac_func
-
-/* System header to define __stub macros and hopefully few prototypes,
-    which can conflict with char $ac_func (); below.
-    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
-    <limits.h> exists even on freestanding compilers.  */
-
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
-
-#undef $ac_func
-
-/* Override any GCC internal prototype to avoid an error.
-   Use char because int might match the return type of a GCC
-   builtin and then its argument prototype would still apply.  */
-#ifdef __cplusplus
-extern "C"
-#endif
-char $ac_func ();
-/* The GNU C library defines this for functions which it implements
-    to always fail with ENOSYS.  Some functions are actually named
-    something starting with __ and the normal name is an alias.  */
-#if defined __stub_$ac_func || defined __stub___$ac_func
-choke me
-#endif
-
-int
-main ()
-{
-return $ac_func ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  eval "$as_ac_var=yes"
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	eval "$as_ac_var=no"
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-fi
-ac_res=`eval echo '${'$as_ac_var'}'`
-	       { echo "$as_me:$LINENO: result: $ac_res" >&5
-echo "${ECHO_T}$ac_res" >&6; }
-if test `eval echo '${'$as_ac_var'}'` = yes; then
-  cat >>confdefs.h <<_ACEOF
-@%:@define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
-_ACEOF
- 
-fi
-done
-
-	{ echo "$as_me:$LINENO: checking for off64_t" >&5
-echo $ECHO_N "checking for off64_t... $ECHO_C" >&6; }
-	if test "${tcl_cv_type_off64_t+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  
-	    cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <sys/types.h>
-int
-main ()
-{
-off64_t offset;
-
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  tcl_cv_type_off64_t=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	tcl_cv_type_off64_t=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
-			if test "x${tcl_cv_type_off64_t}" = "xyes" && \
-	        test "x${ac_cv_func_lseek64}" = "xyes" && \
-	        test "x${ac_cv_func_open64}" = "xyes" ; then
-	    
-cat >>confdefs.h <<\_ACEOF
-@%:@define HAVE_TYPE_OFF64_T 1
-_ACEOF
-
-	    { echo "$as_me:$LINENO: result: yes" >&5
-echo "${ECHO_T}yes" >&6; }
-	else
-	    { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-	fi
-    fi
-
-
-
-#--------------------------------------------------------------------
-# Set the default compiler switches based on the --enable-symbols option.
-#--------------------------------------------------------------------
-
-
-        
-    { echo "$as_me:$LINENO: checking for build with symbols" >&5
-echo $ECHO_N "checking for build with symbols... $ECHO_C" >&6; }
-    # Check whether --enable-symbols was given.
-if test "${enable_symbols+set}" = set; then
-  enableval=$enable_symbols; tcl_ok=$enableval
-else
-  tcl_ok=no
-fi
-
-    DBGX=""
-    if test "$tcl_ok" = "no"; then
-	CFLAGS_DEFAULT="${CFLAGS_OPTIMIZE}"
-	LDFLAGS_DEFAULT="${LDFLAGS_OPTIMIZE}"
-	{ echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-    else
-	CFLAGS_DEFAULT="${CFLAGS_DEBUG}"
-	LDFLAGS_DEFAULT="${LDFLAGS_DEBUG}"
-	if test "$tcl_ok" = "yes"; then
-	    { echo "$as_me:$LINENO: result: yes (standard debugging)" >&5
-echo "${ECHO_T}yes (standard debugging)" >&6; }
-	fi
-    fi
-    if test "${TEA_PLATFORM}" != "windows" ; then
-	LDFLAGS_DEFAULT="${LDFLAGS}"
-    fi
-
-    
-    
-    
-
-    if test "$tcl_ok" = "mem" -o "$tcl_ok" = "all"; then
-	
-cat >>confdefs.h <<\_ACEOF
-@%:@define TCL_MEM_DEBUG 1
-_ACEOF
-
-    fi
-
-    if test "$tcl_ok" != "yes" -a "$tcl_ok" != "no"; then
-	if test "$tcl_ok" = "all"; then
-	    { echo "$as_me:$LINENO: result: enabled symbols mem debugging" >&5
-echo "${ECHO_T}enabled symbols mem debugging" >&6; }
-	else
-	    { echo "$as_me:$LINENO: result: enabled $tcl_ok debugging" >&5
-echo "${ECHO_T}enabled $tcl_ok debugging" >&6; }
-	fi
-    fi
-
-
-#--------------------------------------------------------------------
-# Everyone should be linking against the Tcl stub library.  If you
-# can't for some reason, remove this definition.  If you aren't using
-# stubs, you also need to modify the SHLIB_LD_LIBS setting below to
-# link against the non-stubbed Tcl library.
-#--------------------------------------------------------------------
-
-
-cat >>confdefs.h <<\_ACEOF
-@%:@define USE_TCL_STUBS 1
-_ACEOF
-
-
-#--------------------------------------------------------------------
-# This macro generates a line to use when building a library.  It
-# depends on values set by the TEA_ENABLE_SHARED, TEA_ENABLE_SYMBOLS,
-# and TEA_LOAD_TCLCONFIG macros above.
-#--------------------------------------------------------------------
-
-
-    if test "${TEA_PLATFORM}" = "windows" -a "$GCC" != "yes"; then
-	MAKE_STATIC_LIB="\${STLIB_LD} -out:\$@ \$(PKG_OBJECTS)"
-	MAKE_SHARED_LIB="\${SHLIB_LD} \${SHLIB_LD_LIBS} \${LDFLAGS_DEFAULT} -out:\$@ \$(PKG_OBJECTS)"
-	MAKE_STUB_LIB="\${STLIB_LD} -out:\$@ \$(PKG_STUB_OBJECTS)"
-    else
-	MAKE_STATIC_LIB="\${STLIB_LD} \$@ \$(PKG_OBJECTS)"
-	MAKE_SHARED_LIB="\${SHLIB_LD} -o \$@ \$(PKG_OBJECTS) \${SHLIB_LD_LIBS}"
-	MAKE_STUB_LIB="\${STLIB_LD} \$@ \$(PKG_STUB_OBJECTS)"
-    fi
-
-    if test "${SHARED_BUILD}" = "1" ; then
-	MAKE_LIB="${MAKE_SHARED_LIB} "
-    else
-	MAKE_LIB="${MAKE_STATIC_LIB} "
-    fi
-
-    #--------------------------------------------------------------------
-    # Shared libraries and static libraries have different names.
-    # Use the double eval to make sure any variables in the suffix is
-    # substituted. (@@@ Might not be necessary anymore)
-    #--------------------------------------------------------------------
-
-    if test "${TEA_PLATFORM}" = "windows" ; then
-	if test "${SHARED_BUILD}" = "1" ; then
-	    # We force the unresolved linking of symbols that are really in
-	    # the private libraries of Tcl and Tk.
-	    SHLIB_LD_LIBS="${SHLIB_LD_LIBS} \"`${CYGPATH} ${TCL_BIN_DIR}/${TCL_STUB_LIB_FILE}`\""
-	    if test x"${TK_BIN_DIR}" != x ; then
-		SHLIB_LD_LIBS="${SHLIB_LD_LIBS} \"`${CYGPATH} ${TK_BIN_DIR}/${TK_STUB_LIB_FILE}`\""
-	    fi
-	    eval eval "PKG_LIB_FILE=${PACKAGE_NAME}${SHARED_LIB_SUFFIX}"
-	else
-	    eval eval "PKG_LIB_FILE=${PACKAGE_NAME}${UNSHARED_LIB_SUFFIX}"
-	fi
-	# Some packages build their own stubs libraries
-	eval eval "PKG_STUB_LIB_FILE=${PACKAGE_NAME}stub${UNSHARED_LIB_SUFFIX}"
-	if test "$GCC" = "yes"; then
-	    PKG_STUB_LIB_FILE=lib${PKG_STUB_LIB_FILE}
-	fi
-	# These aren't needed on Windows (either MSVC or gcc)
-	RANLIB=:
-	RANLIB_STUB=:
-    else
-	RANLIB_STUB="${RANLIB}"
-	if test "${SHARED_BUILD}" = "1" ; then
-	    SHLIB_LD_LIBS="${SHLIB_LD_LIBS} ${TCL_STUB_LIB_SPEC}"
-	    if test x"${TK_BIN_DIR}" != x ; then
-		SHLIB_LD_LIBS="${SHLIB_LD_LIBS} ${TK_STUB_LIB_SPEC}"
-	    fi
-	    eval eval "PKG_LIB_FILE=lib${PACKAGE_NAME}${SHARED_LIB_SUFFIX}"
-	    RANLIB=:
-	else
-	    eval eval "PKG_LIB_FILE=lib${PACKAGE_NAME}${UNSHARED_LIB_SUFFIX}"
-	fi
-	# Some packages build their own stubs libraries
-	eval eval "PKG_STUB_LIB_FILE=lib${PACKAGE_NAME}stub${UNSHARED_LIB_SUFFIX}"
-    fi
-
-    # These are escaped so that only CFLAGS is picked up at configure time.
-    # The other values will be substituted at make time.
-    CFLAGS="${CFLAGS} \${CFLAGS_DEFAULT} \${CFLAGS_WARNING}"
-    if test "${SHARED_BUILD}" = "1" ; then
-	CFLAGS="${CFLAGS} \${SHLIB_CFLAGS}"
-    fi
-
-    
-    
-    
-    
-    
-
-
-#--------------------------------------------------------------------
-# On Mac OS X we may want to build as a framework.
-# This affects the location and naming of headers and libaries.
-#--------------------------------------------------------------------
-
-# Check whether --enable-framework was given.
-if test "${enable_framework+set}" = set; then
-  enableval=$enable_framework; tcl_ok=$enableval
-else
-  tcl_ok=$1
-fi
-
-
-#--------------------------------------------------------------------
-# Load libxml2 configuration
-#--------------------------------------------------------------------
-
-{ echo "$as_me:$LINENO: checking for xml2-config script" >&5
-echo $ECHO_N "checking for xml2-config script... $ECHO_C" >&6; }
-
-
-# Check whether --with-xml2-config was given.
-if test "${with_xml2_config+set}" = set; then
-  withval=$with_xml2_config; with_xml2_config=${withval}
-fi
-
-
-LIBXML2_CONFIG=
-if test "x${with_xml2_config}" = "x" ; then
-    for c in \
-	/Library/Frameworks/libxml.framework/Resources/Scripts/xml2-config \
-	${prefix}/bin/xml2-config \
-	/usr/bin/xml2-config \
-	/usr/local/bin/xml2-config
-    do
-	if test -x "$c" ; then
-	    LIBXML2_CONFIG="$c"
-	    break
-	fi
-    done
-else
-    LIBXML2_CONFIG="${with_xml2_config}"
-fi
-if test "x$LIBXML2_CONFIG" = "x" ; then
-    { { echo "$as_me:$LINENO: error: unable to find xml2-config" >&5
-echo "$as_me: error: unable to find xml2-config" >&2;}
-   { (exit 1); exit 1; }; }
-else
-    { echo "$as_me:$LINENO: result: ${LIBXML2_CONFIG}" >&5
-echo "${ECHO_T}${LIBXML2_CONFIG}" >&6; }
-    XML2_VERSION=`${LIBXML2_CONFIG} --version`
-    XML2_PREFIX=`${LIBXML2_CONFIG} --prefix`
-    XML2_LIBS="`${LIBXML2_CONFIG} --libs`"
-    XML2_CFLAGS=`${LIBXML2_CONFIG} --cflags`
-fi
-
-
-
-
-
-#--------------------------------------------------------------------
-# Load libxslt configuration
-#--------------------------------------------------------------------
-
-{ echo "$as_me:$LINENO: checking for xslt-config script" >&5
-echo $ECHO_N "checking for xslt-config script... $ECHO_C" >&6; }
-
-
-# Check whether --with-xslt-config was given.
-if test "${with_xslt_config+set}" = set; then
-  withval=$with_xslt_config; with_xslt_config=${withval}
-fi
-
-
-LIBXSLT_CONFIG=
-if test "x${with_xslt_config}" = "x" ; then
-    if test "x${with_xml2_config}" = "x" ; then
-	:
-    else
-	if test -x "`dirname ${with_xml2_config}`/xslt-config" ; then
-	    LIBXSLT_CONFIG="`dirname ${with_xml2_config}`/xslt-config"
-	fi
-    fi
-else
-    LIBXSLT_CONFIG="${with_xslt_config}"
-fi
-if test "x${LIBXSLT_CONFIG}" = "x" ; then
-    for c in \
-	/Library/Frameworks/libxslt.framework/Resources/Scripts/xslt-config \
-	${prefix}/bin/xslt-config \
-	/usr/bin/xslt-config \
-	/usr/local/bin/xslt-config
-    do
-	if test -x "$c" ; then
-	    LIBXSLT_CONFIG="$c"
-	    break
-	fi
-    done
-fi
-if test "x$LIBXSLT_CONFIG" = "x" ; then
-    { { echo "$as_me:$LINENO: error: unable to find xslt-config script" >&5
-echo "$as_me: error: unable to find xslt-config script" >&2;}
-   { (exit 1); exit 1; }; }
-else
-    { echo "$as_me:$LINENO: result: ${LIBXSLT_CONFIG}" >&5
-echo "${ECHO_T}${LIBXSLT_CONFIG}" >&6; }
-    XSLT_VERSION=`${LIBXSLT_CONFIG} --version`
-    XSLT_PREFIX=`${LIBXSLT_CONFIG} --prefix`
-    XSLT_CFLAGS=`${LIBXSLT_CONFIG} --cflags`
-    XSLT_LIBS="`${LIBXSLT_CONFIG} --libs` -lexslt"
-fi
-
-
-
-
-
-#--------------------------------------------------------------------
-# See if we want to statically link the libxml2 and libxslt
-# libraries. This is desirable for Tclkit.
-#--------------------------------------------------------------------
-
-{ echo "$as_me:$LINENO: checking for static linking of XML/XSLT libraries" >&5
-echo $ECHO_N "checking for static linking of XML/XSLT libraries... $ECHO_C" >&6; }
-
-
-# Check whether --with-xml-static was given.
-if test "${with_xml_static+set}" = set; then
-  withval=$with_xml_static; with_xml_static=${withval}
-fi
-
-
-XML_STATIC="0"
-if test "${with_xml_static}" = "1" ; then
-    XML_STATIC="1"
-    { echo "$as_me:$LINENO: result: use static linking" >&5
-echo "${ECHO_T}use static linking" >&6; }
-else
-    { echo "$as_me:$LINENO: result: use dynamic linking" >&5
-echo "${ECHO_T}use dynamic linking" >&6; }
-fi
-
-
-
-#--------------------------------------------------------------------
-# __CHANGE__
-# Add platform libs to LIBS or SHLIB_LD_LIBS as necessary.
-#--------------------------------------------------------------------
-
-FIX_LIB=":"
-if test "${TEA_PLATFORM}" = "windows" -a "$GCC" != "yes" ; then
-    SHLIB_LD_LIBS="${SHLIB_LD_LIBS} \"`${CYGPATH} ${LIBXSLT_LIBDIR}/libxslt.lib`\""
-    SHLIB_LD_LIBS="${SHLIB_LD_LIBS} \"`${CYGPATH} ${LIBXSLT_LIBDIR}/libexslt.lib`\""
-    SHLIB_LD_LIBS="${SHLIB_LD_LIBS} \"`${CYGPATH} ${LIBXML2_LIBDIR}/libxml2.lib`\""
-else
-if test "${XML_STATIC}" = "0" ; then
-    echo "setting up dynamic linking"
-    SHLIB_LD_LIBS="${SHLIB_LD_LIBS} \${XSLT_LIBS}"
-else
-    SHLIB_LD_LIBS="${SHLIB_LD_LIBS} ${XSLT_PREFIX}/lib/libexslt.a"
-    SHLIB_LD_LIBS="${SHLIB_LD_LIBS} ${XSLT_PREFIX}/lib/libxslt.a"
-    SHLIB_LD_LIBS="${SHLIB_LD_LIBS} ${XML2_PREFIX}/lib/libxml2.a"
-    SHLIB_LD_LIBS="${SHLIB_LD_LIBS} -L/usr/lib -lgcrypt -lgpg-error -lz -lm"
-    XML2_LIBS=
-    XSLT_LIBS=
-    FIX_LIB="chcon -t texrel_shlib_t"
-fi
-fi
-
-# Enabling static linking modifies the setting of the libraries,
-# so delay substitution until this point.
-
-
-
-
-#--------------------------------------------------------------------
-# Find tclsh so that we can run pkg_mkIndex to generate the pkgIndex.tcl
-# file during the install process.  Don't run the TCLSH_PROG through
-# ${CYGPATH} because it's being used directly by make.
-# Require that we use a tclsh shell version 8.2 or later since earlier
-# versions have bugs in the pkg_mkIndex routine.
-# Add WISH as well if this is a Tk extension.
-#--------------------------------------------------------------------
-
-
-    { echo "$as_me:$LINENO: checking for tclsh" >&5
-echo $ECHO_N "checking for tclsh... $ECHO_C" >&6; }
-    if test -f "${TCL_BIN_DIR}/Makefile" ; then
-        # tclConfig.sh is in Tcl build directory
-        if test "${TEA_PLATFORM}" = "windows"; then
-            TCLSH_PROG="${TCL_BIN_DIR}/tclsh${TCL_MAJOR_VERSION}${TCL_MINOR_VERSION}${TCL_DBGX}${EXEEXT}"
-        else
-            TCLSH_PROG="${TCL_BIN_DIR}/tclsh"
-        fi
-    else
-        # tclConfig.sh is in install location
-        if test "${TEA_PLATFORM}" = "windows"; then
-            TCLSH_PROG="tclsh${TCL_MAJOR_VERSION}${TCL_MINOR_VERSION}${TCL_DBGX}${EXEEXT}"
-        else
-            TCLSH_PROG="tclsh${TCL_MAJOR_VERSION}.${TCL_MINOR_VERSION}${TCL_DBGX}"
-        fi
-        list="`ls -d ${TCL_BIN_DIR}/../bin 2>/dev/null` \
-              `ls -d ${TCL_BIN_DIR}/..     2>/dev/null` \
-              `ls -d ${TCL_PREFIX}/bin     2>/dev/null`"
-        for i in $list ; do
-            if test -f "$i/${TCLSH_PROG}" ; then
-                REAL_TCL_BIN_DIR="`cd "$i"; pwd`/"
-                break
-            fi
-        done
-        TCLSH_PROG="${REAL_TCL_BIN_DIR}${TCLSH_PROG}"
-    fi
-    { echo "$as_me:$LINENO: result: ${TCLSH_PROG}" >&5
-echo "${ECHO_T}${TCLSH_PROG}" >&6; }
-    
-
-
-#--------------------------------------------------------------------
-# These are for tclxmlConfig.sh
-#--------------------------------------------------------------------
-
-# pkglibdir must be a fully qualified path and (not ${exec_prefix}/lib)
-eval pkglibdir="${libdir}/${PACKAGE_NAME}${PACKAGE_VERSION}"
-if test "${TCL_LIB_VERSIONS_OK}" = "ok"; then
-    eval Tclxml_LIB_FLAG="-l${PACKAGE_NAME}${PACKAGE_VERSION}${DBGX}"
-else
-    eval Tclxml_LIB_FLAG="-l${PACKAGE_NAME}`echo ${PACKAGE_VERSION} | tr -d .`${DBGX}"
-fi
-Tclxml_BUILD_LIB_SPEC="-L`pwd` ${Tclxml_LIB_FLAG}"
-Tclxml_LIB_SPEC="-L${pkglibdir} ${Tclxml_LIB_FLAG}"
-
-if test "${TCL_LIB_VERSIONS_OK}" = "ok"; then
-    eval Tclxml_STUB_LIB_FLAG="-l${PACKAGE_NAME}stub${PACKAGE_VERSION}${DBGX}"
-else
-    eval Tclxml_STUB_LIB_FLAG="-l${PACKAGE_NAME}stub`echo ${PACKAGE_VERSION} | tr -d .`${DBGX}"
-fi
-Tclxml_BUILD_STUB_LIB_SPEC="-L`pwd` ${Tclxml_STUB_LIB_FLAG}"
-Tclxml_STUB_LIB_SPEC="-L${pkglibdir} ${Tclxml_STUB_LIB_FLAG}"
-Tclxml_BUILD_STUB_LIB_PATH="`pwd`/${Tclxmlstub_LIB_FILE}"
-Tclxml_STUB_LIB_PATH="${pkglibdir}/${Tclxmlstub_LIB_FILE}"
-eval pkgincludedir="${includedir}"
-Tclxml_INCLUDE_SPEC="-I${pkgincludedir}"
-
-
-
-
-
-
-
-
-
-#--------------------------------------------------------------------
-# TODO: search for an appropriate xsltproc to use
-#--------------------------------------------------------------------
-
-XSLTPROC=xsltproc
-
-
-#--------------------------------------------------------------------
-# Finally, substitute all of the various values into the Makefile.
-# You may alternatively have a special pkgIndex.tcl.in or other files
-# which require substituting th AC variables in.  Include these here.
-#--------------------------------------------------------------------
-
-ac_config_files="$ac_config_files Makefile Makefile.macosx pkgIndex.tcl TclxmlConfig.sh include/tclxml/tclxml.h doc/tclxml.xml doc/tcldom.xml doc/tclxslt.xml doc/README.xml"
-
-cat >confcache <<\_ACEOF
-# This file is a shell script that caches the results of configure
-# tests run on this system so they can be shared between configure
-# scripts and configure runs, see configure's option --config-cache.
-# It is not useful on other systems.  If it contains results you don't
-# want to keep, you may remove or edit it.
-#
-# config.status only pays attention to the cache file if you give it
-# the --recheck option to rerun configure.
-#
-# `ac_cv_env_foo' variables (set or unset) will be overridden when
-# loading this file, other *unset* `ac_cv_foo' will be assigned the
-# following values.
-
-_ACEOF
-
-# The following way of writing the cache mishandles newlines in values,
-# but we know of no workaround that is simple, portable, and efficient.
-# So, we kill variables containing newlines.
-# Ultrix sh set writes to stderr and can't be redirected directly,
-# and sets the high bit in the cache file unless we assign to the vars.
-(
-  for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
-    eval ac_val=\$$ac_var
-    case $ac_val in #(
-    *${as_nl}*)
-      case $ac_var in #(
-      *_cv_*) { echo "$as_me:$LINENO: WARNING: Cache variable $ac_var contains a newline." >&5
-echo "$as_me: WARNING: Cache variable $ac_var contains a newline." >&2;} ;;
-      esac
-      case $ac_var in #(
-      _ | IFS | as_nl) ;; #(
-      *) $as_unset $ac_var ;;
-      esac ;;
-    esac
-  done
-
-  (set) 2>&1 |
-    case $as_nl`(ac_space=' '; set) 2>&1` in #(
-    *${as_nl}ac_space=\ *)
-      # `set' does not quote correctly, so add quotes (double-quote
-      # substitution turns \\\\ into \\, and sed turns \\ into \).
-      sed -n \
-	"s/'/'\\\\''/g;
-	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
-      ;; #(
-    *)
-      # `set' quotes correctly as required by POSIX, so do not add quotes.
-      sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
-      ;;
-    esac |
-    sort
-) |
-  sed '
-     /^ac_cv_env_/b end
-     t clear
-     :clear
-     s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
-     t end
-     s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
-     :end' >>confcache
-if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
-  if test -w "$cache_file"; then
-    test "x$cache_file" != "x/dev/null" &&
-      { echo "$as_me:$LINENO: updating cache $cache_file" >&5
-echo "$as_me: updating cache $cache_file" >&6;}
-    cat confcache >$cache_file
-  else
-    { echo "$as_me:$LINENO: not updating unwritable cache $cache_file" >&5
-echo "$as_me: not updating unwritable cache $cache_file" >&6;}
-  fi
-fi
-rm -f confcache
-
-test "x$prefix" = xNONE && prefix=$ac_default_prefix
-# Let make expand exec_prefix.
-test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
-
-# Transform confdefs.h into DEFS.
-# Protect against shell expansion while executing Makefile rules.
-# Protect against Makefile macro expansion.
-#
-# If the first sed substitution is executed (which looks for macros that
-# take arguments), then branch to the quote section.  Otherwise,
-# look for a macro that doesn't take arguments.
-ac_script='
-t clear
-:clear
-s/^[	 ]*#[	 ]*define[	 ][	 ]*\([^	 (][^	 (]*([^)]*)\)[	 ]*\(.*\)/-D\1=\2/g
-t quote
-s/^[	 ]*#[	 ]*define[	 ][	 ]*\([^	 ][^	 ]*\)[	 ]*\(.*\)/-D\1=\2/g
-t quote
-b any
-:quote
-s/[	 `~#$^&*(){}\\|;'\''"<>?]/\\&/g
-s/\[/\\&/g
-s/\]/\\&/g
-s/\$/$$/g
-H
-:any
-${
-	g
-	s/^\n//
-	s/\n/ /g
-	p
-}
-'
-DEFS=`sed -n "$ac_script" confdefs.h`
-
-
-ac_libobjs=
-ac_ltlibobjs=
-for ac_i in : $LIB@&t at OBJS; do test "x$ac_i" = x: && continue
-  # 1. Remove the extension, and $U if already installed.
-  ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
-  ac_i=`echo "$ac_i" | sed "$ac_script"`
-  # 2. Prepend LIBOBJDIR.  When used with automake>=1.10 LIBOBJDIR
-  #    will be set to the directory where LIBOBJS objects are built.
-  ac_libobjs="$ac_libobjs \${LIBOBJDIR}$ac_i\$U.$ac_objext"
-  ac_ltlibobjs="$ac_ltlibobjs \${LIBOBJDIR}$ac_i"'$U.lo'
-done
-LIB@&t at OBJS=$ac_libobjs
-
-LTLIBOBJS=$ac_ltlibobjs
-
-
-CFLAGS="${CFLAGS} ${CPPFLAGS}"; CPPFLAGS=""
-
-: ${CONFIG_STATUS=./config.status}
-ac_clean_files_save=$ac_clean_files
-ac_clean_files="$ac_clean_files $CONFIG_STATUS"
-{ echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
-echo "$as_me: creating $CONFIG_STATUS" >&6;}
-cat >$CONFIG_STATUS <<_ACEOF
-#! $SHELL
-# Generated by $as_me.
-# Run this file to recreate the current configuration.
-# Compiler output produced by configure, useful for debugging
-# configure, is in config.log if it exists.
-
-debug=false
-ac_cs_recheck=false
-ac_cs_silent=false
-SHELL=\${CONFIG_SHELL-$SHELL}
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF
-## --------------------- ##
-## M4sh Initialization.  ##
-## --------------------- ##
-
-# Be more Bourne compatible
-DUALCASE=1; export DUALCASE # for MKS sh
-if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
-  emulate sh
-  NULLCMD=:
-  # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
-  # is contrary to our usage.  Disable this feature.
-  alias -g '${1+"$@"}'='"$@"'
-  setopt NO_GLOB_SUBST
-else
-  case `(set -o) 2>/dev/null` in
-  *posix*) set -o posix ;;
-esac
-
-fi
-
-
-
-
-# PATH needs CR
-# Avoid depending upon Character Ranges.
-as_cr_letters='abcdefghijklmnopqrstuvwxyz'
-as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
-as_cr_Letters=$as_cr_letters$as_cr_LETTERS
-as_cr_digits='0123456789'
-as_cr_alnum=$as_cr_Letters$as_cr_digits
-
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
-  echo "#! /bin/sh" >conf$$.sh
-  echo  "exit 0"   >>conf$$.sh
-  chmod +x conf$$.sh
-  if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
-    PATH_SEPARATOR=';'
-  else
-    PATH_SEPARATOR=:
-  fi
-  rm -f conf$$.sh
-fi
-
-# Support unset when possible.
-if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
-  as_unset=unset
-else
-  as_unset=false
-fi
-
-
-# IFS
-# We need space, tab and new line, in precisely that order.  Quoting is
-# there to prevent editors from complaining about space-tab.
-# (If _AS_PATH_WALK were called with IFS unset, it would disable word
-# splitting by setting IFS to empty value.)
-as_nl='
-'
-IFS=" ""	$as_nl"
-
-# Find who we are.  Look in the path if we contain no directory separator.
-case $0 in
-  *[\\/]* ) as_myself=$0 ;;
-  *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
-done
-IFS=$as_save_IFS
-
-     ;;
-esac
-# We did not find ourselves, most probably we were run as `sh COMMAND'
-# in which case we are not to be found in the path.
-if test "x$as_myself" = x; then
-  as_myself=$0
-fi
-if test ! -f "$as_myself"; then
-  echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
-  { (exit 1); exit 1; }
-fi
-
-# Work around bugs in pre-3.0 UWIN ksh.
-for as_var in ENV MAIL MAILPATH
-do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
-done
-PS1='$ '
-PS2='> '
-PS4='+ '
-
-# NLS nuisances.
-for as_var in \
-  LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
-  LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
-  LC_TELEPHONE LC_TIME
-do
-  if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
-    eval $as_var=C; export $as_var
-  else
-    ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
-  fi
-done
-
-# Required to use basename.
-if expr a : '\(a\)' >/dev/null 2>&1 &&
-   test "X`expr 00001 : '.*\(...\)'`" = X001; then
-  as_expr=expr
-else
-  as_expr=false
-fi
-
-if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
-  as_basename=basename
-else
-  as_basename=false
-fi
-
-
-# Name of the executable.
-as_me=`$as_basename -- "$0" ||
-$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
-	 X"$0" : 'X\(//\)$' \| \
-	 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
-echo X/"$0" |
-    sed '/^.*\/\([^/][^/]*\)\/*$/{
-	    s//\1/
-	    q
-	  }
-	  /^X\/\(\/\/\)$/{
-	    s//\1/
-	    q
-	  }
-	  /^X\/\(\/\).*/{
-	    s//\1/
-	    q
-	  }
-	  s/.*/./; q'`
-
-# CDPATH.
-$as_unset CDPATH
-
-
-
-  as_lineno_1=$LINENO
-  as_lineno_2=$LINENO
-  test "x$as_lineno_1" != "x$as_lineno_2" &&
-  test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || {
-
-  # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
-  # uniformly replaced by the line number.  The first 'sed' inserts a
-  # line-number line after each line using $LINENO; the second 'sed'
-  # does the real work.  The second script uses 'N' to pair each
-  # line-number line with the line containing $LINENO, and appends
-  # trailing '-' during substitution so that $LINENO is not a special
-  # case at line end.
-  # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
-  # scripts with optimization help from Paolo Bonzini.  Blame Lee
-  # E. McMahon (1931-1989) for sed's syntax.  :-)
-  sed -n '
-    p
-    /[$]LINENO/=
-  ' <$as_myself |
-    sed '
-      s/[$]LINENO.*/&-/
-      t lineno
-      b
-      :lineno
-      N
-      :loop
-      s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
-      t loop
-      s/-\n.*//
-    ' >$as_me.lineno &&
-  chmod +x "$as_me.lineno" ||
-    { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
-   { (exit 1); exit 1; }; }
-
-  # Don't try to exec as it changes $[0], causing all sort of problems
-  # (the dirname of $[0] is not the place where we might find the
-  # original and so on.  Autoconf is especially sensitive to this).
-  . "./$as_me.lineno"
-  # Exit status is that of the last command.
-  exit
-}
-
-
-if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
-  as_dirname=dirname
-else
-  as_dirname=false
-fi
-
-ECHO_C= ECHO_N= ECHO_T=
-case `echo -n x` in
--n*)
-  case `echo 'x\c'` in
-  *c*) ECHO_T='	';;	# ECHO_T is single tab character.
-  *)   ECHO_C='\c';;
-  esac;;
-*)
-  ECHO_N='-n';;
-esac
-
-if expr a : '\(a\)' >/dev/null 2>&1 &&
-   test "X`expr 00001 : '.*\(...\)'`" = X001; then
-  as_expr=expr
-else
-  as_expr=false
-fi
-
-rm -f conf$$ conf$$.exe conf$$.file
-if test -d conf$$.dir; then
-  rm -f conf$$.dir/conf$$.file
-else
-  rm -f conf$$.dir
-  mkdir conf$$.dir
-fi
-echo >conf$$.file
-if ln -s conf$$.file conf$$ 2>/dev/null; then
-  as_ln_s='ln -s'
-  # ... but there are two gotchas:
-  # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
-  # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
-  # In both cases, we have to default to `cp -p'.
-  ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
-    as_ln_s='cp -p'
-elif ln conf$$.file conf$$ 2>/dev/null; then
-  as_ln_s=ln
-else
-  as_ln_s='cp -p'
-fi
-rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
-rmdir conf$$.dir 2>/dev/null
-
-if mkdir -p . 2>/dev/null; then
-  as_mkdir_p=:
-else
-  test -d ./-p && rmdir ./-p
-  as_mkdir_p=false
-fi
-
-if test -x / >/dev/null 2>&1; then
-  as_test_x='test -x'
-else
-  if ls -dL / >/dev/null 2>&1; then
-    as_ls_L_option=L
-  else
-    as_ls_L_option=
-  fi
-  as_test_x='
-    eval sh -c '\''
-      if test -d "$1"; then
-        test -d "$1/.";
-      else
-	case $1 in
-        -*)set "./$1";;
-	esac;
-	case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in
-	???[sx]*):;;*)false;;esac;fi
-    '\'' sh
-  '
-fi
-as_executable_p=$as_test_x
-
-# Sed expression to map a string onto a valid CPP name.
-as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
-
-# Sed expression to map a string onto a valid variable name.
-as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
-
-
-exec 6>&1
-
-# Save the log message, to keep $[0] and so on meaningful, and to
-# report actual input values of CONFIG_FILES etc. instead of their
-# values after options handling.
-ac_log="
-This file was extended by Tclxml $as_me 3.2, which was
-generated by GNU Autoconf 2.61.  Invocation command line was
-
-  CONFIG_FILES    = $CONFIG_FILES
-  CONFIG_HEADERS  = $CONFIG_HEADERS
-  CONFIG_LINKS    = $CONFIG_LINKS
-  CONFIG_COMMANDS = $CONFIG_COMMANDS
-  $ $0 $@
-
-on `(hostname || uname -n) 2>/dev/null | sed 1q`
-"
-
-_ACEOF
-
-cat >>$CONFIG_STATUS <<_ACEOF
-# Files that config.status was made for.
-config_files="$ac_config_files"
-
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF
-ac_cs_usage="\
-\`$as_me' instantiates files from templates according to the
-current configuration.
-
-Usage: $0 [OPTIONS] [FILE]...
-
-  -h, --help       print this help, then exit
-  -V, --version    print version number and configuration settings, then exit
-  -q, --quiet      do not print progress messages
-  -d, --debug      don't remove temporary files
-      --recheck    update $as_me by reconfiguring in the same conditions
-  --file=FILE[:TEMPLATE]
-		   instantiate the configuration file FILE
-
-Configuration files:
-$config_files
-
-Report bugs to <bug-autoconf at gnu.org>."
-
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF
-ac_cs_version="\\
-Tclxml config.status 3.2
-configured by $0, generated by GNU Autoconf 2.61,
-  with options \\"`echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
-
-Copyright (C) 2006 Free Software Foundation, Inc.
-This config.status script is free software; the Free Software Foundation
-gives unlimited permission to copy, distribute and modify it."
-
-ac_pwd='$ac_pwd'
-srcdir='$srcdir'
-INSTALL='$INSTALL'
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF
-# If no file are specified by the user, then we need to provide default
-# value.  By we need to know if files were specified by the user.
-ac_need_defaults=:
-while test $# != 0
-do
-  case $1 in
-  --*=*)
-    ac_option=`expr "X$1" : 'X\([^=]*\)='`
-    ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
-    ac_shift=:
-    ;;
-  *)
-    ac_option=$1
-    ac_optarg=$2
-    ac_shift=shift
-    ;;
-  esac
-
-  case $ac_option in
-  # Handling of the options.
-  -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
-    ac_cs_recheck=: ;;
-  --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
-    echo "$ac_cs_version"; exit ;;
-  --debug | --debu | --deb | --de | --d | -d )
-    debug=: ;;
-  --file | --fil | --fi | --f )
-    $ac_shift
-    CONFIG_FILES="$CONFIG_FILES $ac_optarg"
-    ac_need_defaults=false;;
-  --he | --h |  --help | --hel | -h )
-    echo "$ac_cs_usage"; exit ;;
-  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
-  | -silent | --silent | --silen | --sile | --sil | --si | --s)
-    ac_cs_silent=: ;;
-
-  # This is an error.
-  -*) { echo "$as_me: error: unrecognized option: $1
-Try \`$0 --help' for more information." >&2
-   { (exit 1); exit 1; }; } ;;
-
-  *) ac_config_targets="$ac_config_targets $1"
-     ac_need_defaults=false ;;
-
-  esac
-  shift
-done
-
-ac_configure_extra_args=
-
-if $ac_cs_silent; then
-  exec 6>/dev/null
-  ac_configure_extra_args="$ac_configure_extra_args --silent"
-fi
-
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF
-if \$ac_cs_recheck; then
-  echo "running CONFIG_SHELL=$SHELL $SHELL $0 "$ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6
-  CONFIG_SHELL=$SHELL
-  export CONFIG_SHELL
-  exec $SHELL "$0"$ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
-fi
-
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF
-exec 5>>config.log
-{
-  echo
-  sed 'h;s/./-/g;s/^.../@%:@@%:@ /;s/...$/ @%:@@%:@/;p;x;p;x' <<_ASBOX
-@%:@@%:@ Running $as_me. @%:@@%:@
-_ASBOX
-  echo "$ac_log"
-} >&5
-
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF
-
-# Handling of arguments.
-for ac_config_target in $ac_config_targets
-do
-  case $ac_config_target in
-    "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
-    "Makefile.macosx") CONFIG_FILES="$CONFIG_FILES Makefile.macosx" ;;
-    "pkgIndex.tcl") CONFIG_FILES="$CONFIG_FILES pkgIndex.tcl" ;;
-    "TclxmlConfig.sh") CONFIG_FILES="$CONFIG_FILES TclxmlConfig.sh" ;;
-    "include/tclxml/tclxml.h") CONFIG_FILES="$CONFIG_FILES include/tclxml/tclxml.h" ;;
-    "doc/tclxml.xml") CONFIG_FILES="$CONFIG_FILES doc/tclxml.xml" ;;
-    "doc/tcldom.xml") CONFIG_FILES="$CONFIG_FILES doc/tcldom.xml" ;;
-    "doc/tclxslt.xml") CONFIG_FILES="$CONFIG_FILES doc/tclxslt.xml" ;;
-    "doc/README.xml") CONFIG_FILES="$CONFIG_FILES doc/README.xml" ;;
-
-  *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
-echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
-   { (exit 1); exit 1; }; };;
-  esac
-done
-
-
-# If the user did not use the arguments to specify the items to instantiate,
-# then the envvar interface is used.  Set only those that are not.
-# We use the long form for the default assignment because of an extremely
-# bizarre bug on SunOS 4.1.3.
-if $ac_need_defaults; then
-  test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
-fi
-
-# Have a temporary directory for convenience.  Make it in the build tree
-# simply because there is no reason against having it here, and in addition,
-# creating and moving files from /tmp can sometimes cause problems.
-# Hook for its removal unless debugging.
-# Note that there is a small window in which the directory will not be cleaned:
-# after its creation but before its name has been assigned to `$tmp'.
-$debug ||
-{
-  tmp=
-  trap 'exit_status=$?
-  { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
-' 0
-  trap '{ (exit 1); exit 1; }' 1 2 13 15
-}
-# Create a (secure) tmp directory for tmp files.
-
-{
-  tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
-  test -n "$tmp" && test -d "$tmp"
-}  ||
-{
-  tmp=./conf$$-$RANDOM
-  (umask 077 && mkdir "$tmp")
-} ||
-{
-   echo "$me: cannot create a temporary directory in ." >&2
-   { (exit 1); exit 1; }
-}
-
-#
-# Set up the sed scripts for CONFIG_FILES section.
-#
-
-# No need to generate the scripts if there are no CONFIG_FILES.
-# This happens for instance when ./config.status config.h
-if test -n "$CONFIG_FILES"; then
-
-_ACEOF
-
-
-
-ac_delim='%!_!# '
-for ac_last_try in false false false false false :; do
-  cat >conf$$subs.sed <<_ACEOF
-SHELL!$SHELL$ac_delim
-PATH_SEPARATOR!$PATH_SEPARATOR$ac_delim
-PACKAGE_NAME!$PACKAGE_NAME$ac_delim
-PACKAGE_TARNAME!$PACKAGE_TARNAME$ac_delim
-PACKAGE_VERSION!$PACKAGE_VERSION$ac_delim
-PACKAGE_STRING!$PACKAGE_STRING$ac_delim
-PACKAGE_BUGREPORT!$PACKAGE_BUGREPORT$ac_delim
-exec_prefix!$exec_prefix$ac_delim
-prefix!$prefix$ac_delim
-program_transform_name!$program_transform_name$ac_delim
-bindir!$bindir$ac_delim
-sbindir!$sbindir$ac_delim
-libexecdir!$libexecdir$ac_delim
-datarootdir!$datarootdir$ac_delim
-datadir!$datadir$ac_delim
-sysconfdir!$sysconfdir$ac_delim
-sharedstatedir!$sharedstatedir$ac_delim
-localstatedir!$localstatedir$ac_delim
-includedir!$includedir$ac_delim
-oldincludedir!$oldincludedir$ac_delim
-docdir!$docdir$ac_delim
-infodir!$infodir$ac_delim
-htmldir!$htmldir$ac_delim
-dvidir!$dvidir$ac_delim
-pdfdir!$pdfdir$ac_delim
-psdir!$psdir$ac_delim
-libdir!$libdir$ac_delim
-localedir!$localedir$ac_delim
-mandir!$mandir$ac_delim
-DEFS!$DEFS$ac_delim
-ECHO_C!$ECHO_C$ac_delim
-ECHO_N!$ECHO_N$ac_delim
-ECHO_T!$ECHO_T$ac_delim
-LIBS!$LIBS$ac_delim
-build_alias!$build_alias$ac_delim
-host_alias!$host_alias$ac_delim
-target_alias!$target_alias$ac_delim
-CYGPATH!$CYGPATH$ac_delim
-EXEEXT!$EXEEXT$ac_delim
-PKG_LIB_FILE!$PKG_LIB_FILE$ac_delim
-PKG_STUB_LIB_FILE!$PKG_STUB_LIB_FILE$ac_delim
-PKG_STUB_SOURCES!$PKG_STUB_SOURCES$ac_delim
-PKG_STUB_OBJECTS!$PKG_STUB_OBJECTS$ac_delim
-PKG_TCL_SOURCES!$PKG_TCL_SOURCES$ac_delim
-PKG_HEADERS!$PKG_HEADERS$ac_delim
-PKG_INCLUDES!$PKG_INCLUDES$ac_delim
-PKG_LIBS!$PKG_LIBS$ac_delim
-PKG_CFLAGS!$PKG_CFLAGS$ac_delim
-TCL_VERSION!$TCL_VERSION$ac_delim
-TCL_BIN_DIR!$TCL_BIN_DIR$ac_delim
-TCL_SRC_DIR!$TCL_SRC_DIR$ac_delim
-TCL_LIB_FILE!$TCL_LIB_FILE$ac_delim
-TCL_LIB_FLAG!$TCL_LIB_FLAG$ac_delim
-TCL_LIB_SPEC!$TCL_LIB_SPEC$ac_delim
-TCL_STUB_LIB_FILE!$TCL_STUB_LIB_FILE$ac_delim
-TCL_STUB_LIB_FLAG!$TCL_STUB_LIB_FLAG$ac_delim
-TCL_STUB_LIB_SPEC!$TCL_STUB_LIB_SPEC$ac_delim
-TCL_LIBS!$TCL_LIBS$ac_delim
-TCL_DEFS!$TCL_DEFS$ac_delim
-TCL_EXTRA_CFLAGS!$TCL_EXTRA_CFLAGS$ac_delim
-TCL_LD_FLAGS!$TCL_LD_FLAGS$ac_delim
-TCL_SHLIB_LD_LIBS!$TCL_SHLIB_LD_LIBS$ac_delim
-CC!$CC$ac_delim
-CFLAGS!$CFLAGS$ac_delim
-LDFLAGS!$LDFLAGS$ac_delim
-CPPFLAGS!$CPPFLAGS$ac_delim
-ac_ct_CC!$ac_ct_CC$ac_delim
-OBJEXT!$OBJEXT$ac_delim
-CPP!$CPP$ac_delim
-INSTALL_PROGRAM!$INSTALL_PROGRAM$ac_delim
-INSTALL_SCRIPT!$INSTALL_SCRIPT$ac_delim
-INSTALL_DATA!$INSTALL_DATA$ac_delim
-SET_MAKE!$SET_MAKE$ac_delim
-RANLIB!$RANLIB$ac_delim
-GREP!$GREP$ac_delim
-EGREP!$EGREP$ac_delim
-MATH_LIBS!$MATH_LIBS$ac_delim
-PKG_SOURCES!$PKG_SOURCES$ac_delim
-PKG_OBJECTS!$PKG_OBJECTS$ac_delim
-CLEANFILES!$CLEANFILES$ac_delim
-TCL_INCLUDES!$TCL_INCLUDES$ac_delim
-TCL_THREADS!$TCL_THREADS$ac_delim
-SHARED_BUILD!$SHARED_BUILD$ac_delim
-AR!$AR$ac_delim
-CELIB_DIR!$CELIB_DIR$ac_delim
-LIB@&t at OBJS!$LIB@&t at OBJS$ac_delim
-DL_LIBS!$DL_LIBS$ac_delim
-CFLAGS_DEBUG!$CFLAGS_DEBUG$ac_delim
-CFLAGS_OPTIMIZE!$CFLAGS_OPTIMIZE$ac_delim
-CFLAGS_WARNING!$CFLAGS_WARNING$ac_delim
-STLIB_LD!$STLIB_LD$ac_delim
-SHLIB_LD!$SHLIB_LD$ac_delim
-SHLIB_LD_LIBS!$SHLIB_LD_LIBS$ac_delim
-SHLIB_CFLAGS!$SHLIB_CFLAGS$ac_delim
-LD_LIBRARY_PATH_VAR!$LD_LIBRARY_PATH_VAR$ac_delim
-TCL_DBGX!$TCL_DBGX$ac_delim
-CFLAGS_DEFAULT!$CFLAGS_DEFAULT$ac_delim
-_ACEOF
-
-  if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 97; then
-    break
-  elif $ac_last_try; then
-    { { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
-echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
-   { (exit 1); exit 1; }; }
-  else
-    ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
-  fi
-done
-
-ac_eof=`sed -n '/^CEOF[0-9]*$/s/CEOF/0/p' conf$$subs.sed`
-if test -n "$ac_eof"; then
-  ac_eof=`echo "$ac_eof" | sort -nru | sed 1q`
-  ac_eof=`expr $ac_eof + 1`
-fi
-
-cat >>$CONFIG_STATUS <<_ACEOF
-cat >"\$tmp/subs-1.sed" <<\CEOF$ac_eof
-/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
-_ACEOF
-sed '
-s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g
-s/^/s,@/; s/!/@,|#_!!_#|/
-:n
-t n
-s/'"$ac_delim"'$/,g/; t
-s/$/\\/; p
-N; s/^.*\n//; s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g; b n
-' >>$CONFIG_STATUS <conf$$subs.sed
-rm -f conf$$subs.sed
-cat >>$CONFIG_STATUS <<_ACEOF
-CEOF$ac_eof
-_ACEOF
-
-
-ac_delim='%!_!# '
-for ac_last_try in false false false false false :; do
-  cat >conf$$subs.sed <<_ACEOF
-LDFLAGS_DEFAULT!$LDFLAGS_DEFAULT$ac_delim
-MAKE_LIB!$MAKE_LIB$ac_delim
-MAKE_SHARED_LIB!$MAKE_SHARED_LIB$ac_delim
-MAKE_STATIC_LIB!$MAKE_STATIC_LIB$ac_delim
-MAKE_STUB_LIB!$MAKE_STUB_LIB$ac_delim
-RANLIB_STUB!$RANLIB_STUB$ac_delim
-XML2_PREFIX!$XML2_PREFIX$ac_delim
-XML2_CFLAGS!$XML2_CFLAGS$ac_delim
-XML2_VERSION!$XML2_VERSION$ac_delim
-XSLT_VERSION!$XSLT_VERSION$ac_delim
-XSLT_PREFIX!$XSLT_PREFIX$ac_delim
-XSLT_CFLAGS!$XSLT_CFLAGS$ac_delim
-XML_STATIC!$XML_STATIC$ac_delim
-XML2_LIBS!$XML2_LIBS$ac_delim
-XSLT_LIBS!$XSLT_LIBS$ac_delim
-FIX_LIB!$FIX_LIB$ac_delim
-TCLSH_PROG!$TCLSH_PROG$ac_delim
-Tclxml_BUILD_LIB_SPEC!$Tclxml_BUILD_LIB_SPEC$ac_delim
-Tclxml_LIB_SPEC!$Tclxml_LIB_SPEC$ac_delim
-Tclxml_BUILD_STUB_LIB_SPEC!$Tclxml_BUILD_STUB_LIB_SPEC$ac_delim
-Tclxml_STUB_LIB_SPEC!$Tclxml_STUB_LIB_SPEC$ac_delim
-Tclxml_BUILD_STUB_LIB_PATH!$Tclxml_BUILD_STUB_LIB_PATH$ac_delim
-Tclxml_STUB_LIB_PATH!$Tclxml_STUB_LIB_PATH$ac_delim
-Tclxml_INCLUDE_SPEC!$Tclxml_INCLUDE_SPEC$ac_delim
-XSLTPROC!$XSLTPROC$ac_delim
-LTLIBOBJS!$LTLIBOBJS$ac_delim
-_ACEOF
-
-  if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 26; then
-    break
-  elif $ac_last_try; then
-    { { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
-echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
-   { (exit 1); exit 1; }; }
-  else
-    ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
-  fi
-done
-
-ac_eof=`sed -n '/^CEOF[0-9]*$/s/CEOF/0/p' conf$$subs.sed`
-if test -n "$ac_eof"; then
-  ac_eof=`echo "$ac_eof" | sort -nru | sed 1q`
-  ac_eof=`expr $ac_eof + 1`
-fi
-
-cat >>$CONFIG_STATUS <<_ACEOF
-cat >"\$tmp/subs-2.sed" <<\CEOF$ac_eof
-/@[a-zA-Z_][a-zA-Z_0-9]*@/!b end
-_ACEOF
-sed '
-s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g
-s/^/s,@/; s/!/@,|#_!!_#|/
-:n
-t n
-s/'"$ac_delim"'$/,g/; t
-s/$/\\/; p
-N; s/^.*\n//; s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g; b n
-' >>$CONFIG_STATUS <conf$$subs.sed
-rm -f conf$$subs.sed
-cat >>$CONFIG_STATUS <<_ACEOF
-:end
-s/|#_!!_#|//g
-CEOF$ac_eof
-_ACEOF
-
-
-# VPATH may cause trouble with some makes, so we remove $(srcdir),
-# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
-# trailing colons and then remove the whole line if VPATH becomes empty
-# (actually we leave an empty line to preserve line numbers).
-if test "x$srcdir" = x.; then
-  ac_vpsub='/^[	 ]*VPATH[	 ]*=/{
-s/:*\$(srcdir):*/:/
-s/:*\${srcdir}:*/:/
-s/:*@srcdir@:*/:/
-s/^\([^=]*=[	 ]*\):*/\1/
-s/:*$//
-s/^[^=]*=[	 ]*$//
-}'
-fi
-
-cat >>$CONFIG_STATUS <<\_ACEOF
-fi # test -n "$CONFIG_FILES"
-
-
-for ac_tag in  :F $CONFIG_FILES      
-do
-  case $ac_tag in
-  :[FHLC]) ac_mode=$ac_tag; continue;;
-  esac
-  case $ac_mode$ac_tag in
-  :[FHL]*:*);;
-  :L* | :C*:*) { { echo "$as_me:$LINENO: error: Invalid tag $ac_tag." >&5
-echo "$as_me: error: Invalid tag $ac_tag." >&2;}
-   { (exit 1); exit 1; }; };;
-  :[FH]-) ac_tag=-:-;;
-  :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
-  esac
-  ac_save_IFS=$IFS
-  IFS=:
-  set x $ac_tag
-  IFS=$ac_save_IFS
-  shift
-  ac_file=$1
-  shift
-
-  case $ac_mode in
-  :L) ac_source=$1;;
-  :[FH])
-    ac_file_inputs=
-    for ac_f
-    do
-      case $ac_f in
-      -) ac_f="$tmp/stdin";;
-      *) # Look for the file first in the build tree, then in the source tree
-	 # (if the path is not absolute).  The absolute path cannot be DOS-style,
-	 # because $ac_f cannot contain `:'.
-	 test -f "$ac_f" ||
-	   case $ac_f in
-	   [\\/$]*) false;;
-	   *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
-	   esac ||
-	   { { echo "$as_me:$LINENO: error: cannot find input file: $ac_f" >&5
-echo "$as_me: error: cannot find input file: $ac_f" >&2;}
-   { (exit 1); exit 1; }; };;
-      esac
-      ac_file_inputs="$ac_file_inputs $ac_f"
-    done
-
-    # Let's still pretend it is `configure' which instantiates (i.e., don't
-    # use $as_me), people would be surprised to read:
-    #    /* config.h.  Generated by config.status.  */
-    configure_input="Generated from "`IFS=:
-	  echo $* | sed 's|^[^:]*/||;s|:[^:]*/|, |g'`" by configure."
-    if test x"$ac_file" != x-; then
-      configure_input="$ac_file.  $configure_input"
-      { echo "$as_me:$LINENO: creating $ac_file" >&5
-echo "$as_me: creating $ac_file" >&6;}
-    fi
-
-    case $ac_tag in
-    *:-:* | *:-) cat >"$tmp/stdin";;
-    esac
-    ;;
-  esac
-
-  ac_dir=`$as_dirname -- "$ac_file" ||
-$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
-	 X"$ac_file" : 'X\(//\)[^/]' \| \
-	 X"$ac_file" : 'X\(//\)$' \| \
-	 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
-echo X"$ac_file" |
-    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
-	    s//\1/
-	    q
-	  }
-	  /^X\(\/\/\)[^/].*/{
-	    s//\1/
-	    q
-	  }
-	  /^X\(\/\/\)$/{
-	    s//\1/
-	    q
-	  }
-	  /^X\(\/\).*/{
-	    s//\1/
-	    q
-	  }
-	  s/.*/./; q'`
-  { as_dir="$ac_dir"
-  case $as_dir in #(
-  -*) as_dir=./$as_dir;;
-  esac
-  test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || {
-    as_dirs=
-    while :; do
-      case $as_dir in #(
-      *\'*) as_qdir=`echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #(
-      *) as_qdir=$as_dir;;
-      esac
-      as_dirs="'$as_qdir' $as_dirs"
-      as_dir=`$as_dirname -- "$as_dir" ||
-$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
-	 X"$as_dir" : 'X\(//\)[^/]' \| \
-	 X"$as_dir" : 'X\(//\)$' \| \
-	 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
-echo X"$as_dir" |
-    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
-	    s//\1/
-	    q
-	  }
-	  /^X\(\/\/\)[^/].*/{
-	    s//\1/
-	    q
-	  }
-	  /^X\(\/\/\)$/{
-	    s//\1/
-	    q
-	  }
-	  /^X\(\/\).*/{
-	    s//\1/
-	    q
-	  }
-	  s/.*/./; q'`
-      test -d "$as_dir" && break
-    done
-    test -z "$as_dirs" || eval "mkdir $as_dirs"
-  } || test -d "$as_dir" || { { echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5
-echo "$as_me: error: cannot create directory $as_dir" >&2;}
-   { (exit 1); exit 1; }; }; }
-  ac_builddir=.
-
-case "$ac_dir" in
-.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
-*)
-  ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
-  # A ".." for each directory in $ac_dir_suffix.
-  ac_top_builddir_sub=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,/..,g;s,/,,'`
-  case $ac_top_builddir_sub in
-  "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
-  *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
-  esac ;;
-esac
-ac_abs_top_builddir=$ac_pwd
-ac_abs_builddir=$ac_pwd$ac_dir_suffix
-# for backward compatibility:
-ac_top_builddir=$ac_top_build_prefix
-
-case $srcdir in
-  .)  # We are building in place.
-    ac_srcdir=.
-    ac_top_srcdir=$ac_top_builddir_sub
-    ac_abs_top_srcdir=$ac_pwd ;;
-  [\\/]* | ?:[\\/]* )  # Absolute name.
-    ac_srcdir=$srcdir$ac_dir_suffix;
-    ac_top_srcdir=$srcdir
-    ac_abs_top_srcdir=$srcdir ;;
-  *) # Relative name.
-    ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
-    ac_top_srcdir=$ac_top_build_prefix$srcdir
-    ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
-esac
-ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
-
-
-  case $ac_mode in
-  :F)
-  #
-  # CONFIG_FILE
-  #
-
-  case $INSTALL in
-  [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
-  *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
-  esac
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF
-# If the template does not know about datarootdir, expand it.
-# FIXME: This hack should be removed a few years after 2.60.
-ac_datarootdir_hack=; ac_datarootdir_seen=
-
-case `sed -n '/datarootdir/ {
-  p
-  q
-}
-/@datadir@/p
-/@docdir@/p
-/@infodir@/p
-/@localedir@/p
-/@mandir@/p
-' $ac_file_inputs` in
-*datarootdir*) ac_datarootdir_seen=yes;;
-*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
-  { echo "$as_me:$LINENO: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
-echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF
-  ac_datarootdir_hack='
-  s&@datadir@&$datadir&g
-  s&@docdir@&$docdir&g
-  s&@infodir@&$infodir&g
-  s&@localedir@&$localedir&g
-  s&@mandir@&$mandir&g
-    s&\\\${datarootdir}&$datarootdir&g' ;;
-esac
-_ACEOF
-
-# Neutralize VPATH when `$srcdir' = `.'.
-# Shell code in configure.ac might set extrasub.
-# FIXME: do we really want to maintain this feature?
-cat >>$CONFIG_STATUS <<_ACEOF
-  sed "$ac_vpsub
-$extrasub
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF
-:t
-/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
-s&@configure_input@&$configure_input&;t t
-s&@top_builddir@&$ac_top_builddir_sub&;t t
-s&@srcdir@&$ac_srcdir&;t t
-s&@abs_srcdir@&$ac_abs_srcdir&;t t
-s&@top_srcdir@&$ac_top_srcdir&;t t
-s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
-s&@builddir@&$ac_builddir&;t t
-s&@abs_builddir@&$ac_abs_builddir&;t t
-s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
-s&@INSTALL@&$ac_INSTALL&;t t
-$ac_datarootdir_hack
-" $ac_file_inputs | sed -f "$tmp/subs-1.sed" | sed -f "$tmp/subs-2.sed" >$tmp/out
-
-test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
-  { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
-  { ac_out=`sed -n '/^[	 ]*datarootdir[	 ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
-  { echo "$as_me:$LINENO: WARNING: $ac_file contains a reference to the variable \`datarootdir'
-which seems to be undefined.  Please make sure it is defined." >&5
-echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
-which seems to be undefined.  Please make sure it is defined." >&2;}
-
-  rm -f "$tmp/stdin"
-  case $ac_file in
-  -) cat "$tmp/out"; rm -f "$tmp/out";;
-  *) rm -f "$ac_file"; mv "$tmp/out" $ac_file;;
-  esac
- ;;
-  
-  
-  
-  esac
-
-done # for ac_tag
-
-
-{ (exit 0); exit 0; }
-_ACEOF
-chmod +x $CONFIG_STATUS
-ac_clean_files=$ac_clean_files_save
-
-
-# configure is writing to config.log, and then calls config.status.
-# config.status does its own redirection, appending to config.log.
-# Unfortunately, on DOS this fails, as config.log is still kept open
-# by configure, so config.status won't be able to write to it; its
-# output is simply discarded.  So we exec the FD to /dev/null,
-# effectively closing config.log, so it can be properly (re)opened and
-# appended to by config.status.  When coming back to configure, we
-# need to make the FD available again.
-if test "$no_create" != yes; then
-  ac_cs_success=:
-  ac_config_status_args=
-  test "$silent" = yes &&
-    ac_config_status_args="$ac_config_status_args --quiet"
-  exec 5>/dev/null
-  $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
-  exec 5>>config.log
-  # Use ||, not &&, to avoid exiting from the if with $? = 1, which
-  # would make configure fail if this is the last instruction.
-  $ac_cs_success || { (exit 1); exit 1; }
-fi
-
-
-#--------------------------------------------------------------------
diff --git a/tclxml-3.2/autom4te.cache/requests b/tclxml-3.2/autom4te.cache/requests
deleted file mode 100644
index dae03e2..0000000
--- a/tclxml-3.2/autom4te.cache/requests
+++ /dev/null
@@ -1,64 +0,0 @@
-# This file was generated.
-# It contains the lists of macros which have been traced.
-# It can be safely removed.
-
- at request = (
-             bless( [
-                      '0',
-                      1,
-                      [
-                        '/usr/share/autoconf'
-                      ],
-                      [
-                        '/usr/share/autoconf/autoconf/autoconf.m4f',
-                        'aclocal.m4',
-                        'configure.in'
-                      ],
-                      {
-                        '_LT_AC_TAGCONFIG' => 1,
-                        'AM_PROG_F77_C_O' => 1,
-                        'AC_INIT' => 1,
-                        'm4_pattern_forbid' => 1,
-                        'AC_CANONICAL_TARGET' => 1,
-                        'AC_SUBST' => 1,
-                        'AC_CONFIG_LIBOBJ_DIR' => 1,
-                        'AC_FC_SRCEXT' => 1,
-                        'AC_CANONICAL_HOST' => 1,
-                        'AC_PROG_LIBTOOL' => 1,
-                        'AM_INIT_AUTOMAKE' => 1,
-                        'AC_CONFIG_SUBDIRS' => 1,
-                        'AM_AUTOMAKE_VERSION' => 1,
-                        'LT_CONFIG_LTDL_DIR' => 1,
-                        'AC_REQUIRE_AUX_FILE' => 1,
-                        'AC_CONFIG_LINKS' => 1,
-                        'm4_sinclude' => 1,
-                        'LT_SUPPORTED_TAG' => 1,
-                        'AM_MAINTAINER_MODE' => 1,
-                        'AM_GNU_GETTEXT_INTL_SUBDIR' => 1,
-                        '_m4_warn' => 1,
-                        'AM_PROG_CXX_C_O' => 1,
-                        'AM_ENABLE_MULTILIB' => 1,
-                        'AC_CONFIG_FILES' => 1,
-                        'include' => 1,
-                        'LT_INIT' => 1,
-                        'AM_GNU_GETTEXT' => 1,
-                        'AC_LIBSOURCE' => 1,
-                        'AM_PROG_FC_C_O' => 1,
-                        'AC_CANONICAL_BUILD' => 1,
-                        'AC_FC_FREEFORM' => 1,
-                        'AH_OUTPUT' => 1,
-                        '_AM_SUBST_NOTMAKE' => 1,
-                        'AC_CONFIG_AUX_DIR' => 1,
-                        'sinclude' => 1,
-                        'm4_pattern_allow' => 1,
-                        'AM_PROG_CC_C_O' => 1,
-                        'AC_CANONICAL_SYSTEM' => 1,
-                        'AM_CONDITIONAL' => 1,
-                        'AC_CONFIG_HEADERS' => 1,
-                        'AC_DEFINE_TRACE_LITERAL' => 1,
-                        'm4_include' => 1,
-                        'AC_SUBST_TRACE' => 1
-                      }
-                    ], 'Autom4te::Request' )
-           );
-
diff --git a/tclxml-3.2/autom4te.cache/traces.0 b/tclxml-3.2/autom4te.cache/traces.0
deleted file mode 100644
index dafe9e0..0000000
--- a/tclxml-3.2/autom4te.cache/traces.0
+++ /dev/null
@@ -1,821 +0,0 @@
-m4trace:configure.in:21: -1- AC_INIT([Tclxml], [3.2])
-m4trace:configure.in:21: -1- m4_pattern_forbid([^_?A[CHUM]_])
-m4trace:configure.in:21: -1- m4_pattern_forbid([_AC_])
-m4trace:configure.in:21: -1- m4_pattern_forbid([^LIBOBJS$], [do not use LIBOBJS directly, use AC_LIBOBJ (see section `AC_LIBOBJ vs LIBOBJS'])
-m4trace:configure.in:21: -1- m4_pattern_allow([^AS_FLAGS$])
-m4trace:configure.in:21: -1- m4_pattern_forbid([^_?m4_])
-m4trace:configure.in:21: -1- m4_pattern_forbid([^dnl$])
-m4trace:configure.in:21: -1- m4_pattern_forbid([^_?AS_])
-m4trace:configure.in:21: -1- AC_SUBST([SHELL], [${CONFIG_SHELL-/bin/sh}])
-m4trace:configure.in:21: -1- AC_SUBST_TRACE([SHELL])
-m4trace:configure.in:21: -1- m4_pattern_allow([^SHELL$])
-m4trace:configure.in:21: -1- AC_SUBST([PATH_SEPARATOR])
-m4trace:configure.in:21: -1- AC_SUBST_TRACE([PATH_SEPARATOR])
-m4trace:configure.in:21: -1- m4_pattern_allow([^PATH_SEPARATOR$])
-m4trace:configure.in:21: -1- AC_SUBST([PACKAGE_NAME], [m4_ifdef([AC_PACKAGE_NAME],      ['AC_PACKAGE_NAME'])])
-m4trace:configure.in:21: -1- AC_SUBST_TRACE([PACKAGE_NAME])
-m4trace:configure.in:21: -1- m4_pattern_allow([^PACKAGE_NAME$])
-m4trace:configure.in:21: -1- AC_SUBST([PACKAGE_TARNAME], [m4_ifdef([AC_PACKAGE_TARNAME],   ['AC_PACKAGE_TARNAME'])])
-m4trace:configure.in:21: -1- AC_SUBST_TRACE([PACKAGE_TARNAME])
-m4trace:configure.in:21: -1- m4_pattern_allow([^PACKAGE_TARNAME$])
-m4trace:configure.in:21: -1- AC_SUBST([PACKAGE_VERSION], [m4_ifdef([AC_PACKAGE_VERSION],   ['AC_PACKAGE_VERSION'])])
-m4trace:configure.in:21: -1- AC_SUBST_TRACE([PACKAGE_VERSION])
-m4trace:configure.in:21: -1- m4_pattern_allow([^PACKAGE_VERSION$])
-m4trace:configure.in:21: -1- AC_SUBST([PACKAGE_STRING], [m4_ifdef([AC_PACKAGE_STRING],    ['AC_PACKAGE_STRING'])])
-m4trace:configure.in:21: -1- AC_SUBST_TRACE([PACKAGE_STRING])
-m4trace:configure.in:21: -1- m4_pattern_allow([^PACKAGE_STRING$])
-m4trace:configure.in:21: -1- AC_SUBST([PACKAGE_BUGREPORT], [m4_ifdef([AC_PACKAGE_BUGREPORT], ['AC_PACKAGE_BUGREPORT'])])
-m4trace:configure.in:21: -1- AC_SUBST_TRACE([PACKAGE_BUGREPORT])
-m4trace:configure.in:21: -1- m4_pattern_allow([^PACKAGE_BUGREPORT$])
-m4trace:configure.in:21: -1- AC_SUBST([exec_prefix], [NONE])
-m4trace:configure.in:21: -1- AC_SUBST_TRACE([exec_prefix])
-m4trace:configure.in:21: -1- m4_pattern_allow([^exec_prefix$])
-m4trace:configure.in:21: -1- AC_SUBST([prefix], [NONE])
-m4trace:configure.in:21: -1- AC_SUBST_TRACE([prefix])
-m4trace:configure.in:21: -1- m4_pattern_allow([^prefix$])
-m4trace:configure.in:21: -1- AC_SUBST([program_transform_name], [s,x,x,])
-m4trace:configure.in:21: -1- AC_SUBST_TRACE([program_transform_name])
-m4trace:configure.in:21: -1- m4_pattern_allow([^program_transform_name$])
-m4trace:configure.in:21: -1- AC_SUBST([bindir], ['${exec_prefix}/bin'])
-m4trace:configure.in:21: -1- AC_SUBST_TRACE([bindir])
-m4trace:configure.in:21: -1- m4_pattern_allow([^bindir$])
-m4trace:configure.in:21: -1- AC_SUBST([sbindir], ['${exec_prefix}/sbin'])
-m4trace:configure.in:21: -1- AC_SUBST_TRACE([sbindir])
-m4trace:configure.in:21: -1- m4_pattern_allow([^sbindir$])
-m4trace:configure.in:21: -1- AC_SUBST([libexecdir], ['${exec_prefix}/libexec'])
-m4trace:configure.in:21: -1- AC_SUBST_TRACE([libexecdir])
-m4trace:configure.in:21: -1- m4_pattern_allow([^libexecdir$])
-m4trace:configure.in:21: -1- AC_SUBST([datarootdir], ['${prefix}/share'])
-m4trace:configure.in:21: -1- AC_SUBST_TRACE([datarootdir])
-m4trace:configure.in:21: -1- m4_pattern_allow([^datarootdir$])
-m4trace:configure.in:21: -1- AC_SUBST([datadir], ['${datarootdir}'])
-m4trace:configure.in:21: -1- AC_SUBST_TRACE([datadir])
-m4trace:configure.in:21: -1- m4_pattern_allow([^datadir$])
-m4trace:configure.in:21: -1- AC_SUBST([sysconfdir], ['${prefix}/etc'])
-m4trace:configure.in:21: -1- AC_SUBST_TRACE([sysconfdir])
-m4trace:configure.in:21: -1- m4_pattern_allow([^sysconfdir$])
-m4trace:configure.in:21: -1- AC_SUBST([sharedstatedir], ['${prefix}/com'])
-m4trace:configure.in:21: -1- AC_SUBST_TRACE([sharedstatedir])
-m4trace:configure.in:21: -1- m4_pattern_allow([^sharedstatedir$])
-m4trace:configure.in:21: -1- AC_SUBST([localstatedir], ['${prefix}/var'])
-m4trace:configure.in:21: -1- AC_SUBST_TRACE([localstatedir])
-m4trace:configure.in:21: -1- m4_pattern_allow([^localstatedir$])
-m4trace:configure.in:21: -1- AC_SUBST([includedir], ['${prefix}/include'])
-m4trace:configure.in:21: -1- AC_SUBST_TRACE([includedir])
-m4trace:configure.in:21: -1- m4_pattern_allow([^includedir$])
-m4trace:configure.in:21: -1- AC_SUBST([oldincludedir], ['/usr/include'])
-m4trace:configure.in:21: -1- AC_SUBST_TRACE([oldincludedir])
-m4trace:configure.in:21: -1- m4_pattern_allow([^oldincludedir$])
-m4trace:configure.in:21: -1- AC_SUBST([docdir], [m4_ifset([AC_PACKAGE_TARNAME],
-				     ['${datarootdir}/doc/${PACKAGE_TARNAME}'],
-				     ['${datarootdir}/doc/${PACKAGE}'])])
-m4trace:configure.in:21: -1- AC_SUBST_TRACE([docdir])
-m4trace:configure.in:21: -1- m4_pattern_allow([^docdir$])
-m4trace:configure.in:21: -1- AC_SUBST([infodir], ['${datarootdir}/info'])
-m4trace:configure.in:21: -1- AC_SUBST_TRACE([infodir])
-m4trace:configure.in:21: -1- m4_pattern_allow([^infodir$])
-m4trace:configure.in:21: -1- AC_SUBST([htmldir], ['${docdir}'])
-m4trace:configure.in:21: -1- AC_SUBST_TRACE([htmldir])
-m4trace:configure.in:21: -1- m4_pattern_allow([^htmldir$])
-m4trace:configure.in:21: -1- AC_SUBST([dvidir], ['${docdir}'])
-m4trace:configure.in:21: -1- AC_SUBST_TRACE([dvidir])
-m4trace:configure.in:21: -1- m4_pattern_allow([^dvidir$])
-m4trace:configure.in:21: -1- AC_SUBST([pdfdir], ['${docdir}'])
-m4trace:configure.in:21: -1- AC_SUBST_TRACE([pdfdir])
-m4trace:configure.in:21: -1- m4_pattern_allow([^pdfdir$])
-m4trace:configure.in:21: -1- AC_SUBST([psdir], ['${docdir}'])
-m4trace:configure.in:21: -1- AC_SUBST_TRACE([psdir])
-m4trace:configure.in:21: -1- m4_pattern_allow([^psdir$])
-m4trace:configure.in:21: -1- AC_SUBST([libdir], ['${exec_prefix}/lib'])
-m4trace:configure.in:21: -1- AC_SUBST_TRACE([libdir])
-m4trace:configure.in:21: -1- m4_pattern_allow([^libdir$])
-m4trace:configure.in:21: -1- AC_SUBST([localedir], ['${datarootdir}/locale'])
-m4trace:configure.in:21: -1- AC_SUBST_TRACE([localedir])
-m4trace:configure.in:21: -1- m4_pattern_allow([^localedir$])
-m4trace:configure.in:21: -1- AC_SUBST([mandir], ['${datarootdir}/man'])
-m4trace:configure.in:21: -1- AC_SUBST_TRACE([mandir])
-m4trace:configure.in:21: -1- m4_pattern_allow([^mandir$])
-m4trace:configure.in:21: -1- AC_DEFINE_TRACE_LITERAL([PACKAGE_NAME])
-m4trace:configure.in:21: -1- m4_pattern_allow([^PACKAGE_NAME$])
-m4trace:configure.in:21: -1- AH_OUTPUT([PACKAGE_NAME], [/* Define to the full name of this package. */
-#undef PACKAGE_NAME])
-m4trace:configure.in:21: -1- AC_DEFINE_TRACE_LITERAL([PACKAGE_TARNAME])
-m4trace:configure.in:21: -1- m4_pattern_allow([^PACKAGE_TARNAME$])
-m4trace:configure.in:21: -1- AH_OUTPUT([PACKAGE_TARNAME], [/* Define to the one symbol short name of this package. */
-#undef PACKAGE_TARNAME])
-m4trace:configure.in:21: -1- AC_DEFINE_TRACE_LITERAL([PACKAGE_VERSION])
-m4trace:configure.in:21: -1- m4_pattern_allow([^PACKAGE_VERSION$])
-m4trace:configure.in:21: -1- AH_OUTPUT([PACKAGE_VERSION], [/* Define to the version of this package. */
-#undef PACKAGE_VERSION])
-m4trace:configure.in:21: -1- AC_DEFINE_TRACE_LITERAL([PACKAGE_STRING])
-m4trace:configure.in:21: -1- m4_pattern_allow([^PACKAGE_STRING$])
-m4trace:configure.in:21: -1- AH_OUTPUT([PACKAGE_STRING], [/* Define to the full name and version of this package. */
-#undef PACKAGE_STRING])
-m4trace:configure.in:21: -1- AC_DEFINE_TRACE_LITERAL([PACKAGE_BUGREPORT])
-m4trace:configure.in:21: -1- m4_pattern_allow([^PACKAGE_BUGREPORT$])
-m4trace:configure.in:21: -1- AH_OUTPUT([PACKAGE_BUGREPORT], [/* Define to the address where bug reports for this package should be sent. */
-#undef PACKAGE_BUGREPORT])
-m4trace:configure.in:21: -1- AC_SUBST([DEFS])
-m4trace:configure.in:21: -1- AC_SUBST_TRACE([DEFS])
-m4trace:configure.in:21: -1- m4_pattern_allow([^DEFS$])
-m4trace:configure.in:21: -1- AC_SUBST([ECHO_C])
-m4trace:configure.in:21: -1- AC_SUBST_TRACE([ECHO_C])
-m4trace:configure.in:21: -1- m4_pattern_allow([^ECHO_C$])
-m4trace:configure.in:21: -1- AC_SUBST([ECHO_N])
-m4trace:configure.in:21: -1- AC_SUBST_TRACE([ECHO_N])
-m4trace:configure.in:21: -1- m4_pattern_allow([^ECHO_N$])
-m4trace:configure.in:21: -1- AC_SUBST([ECHO_T])
-m4trace:configure.in:21: -1- AC_SUBST_TRACE([ECHO_T])
-m4trace:configure.in:21: -1- m4_pattern_allow([^ECHO_T$])
-m4trace:configure.in:21: -1- AC_SUBST([LIBS])
-m4trace:configure.in:21: -1- AC_SUBST_TRACE([LIBS])
-m4trace:configure.in:21: -1- m4_pattern_allow([^LIBS$])
-m4trace:configure.in:21: -1- AC_SUBST([build_alias])
-m4trace:configure.in:21: -1- AC_SUBST_TRACE([build_alias])
-m4trace:configure.in:21: -1- m4_pattern_allow([^build_alias$])
-m4trace:configure.in:21: -1- AC_SUBST([host_alias])
-m4trace:configure.in:21: -1- AC_SUBST_TRACE([host_alias])
-m4trace:configure.in:21: -1- m4_pattern_allow([^host_alias$])
-m4trace:configure.in:21: -1- AC_SUBST([target_alias])
-m4trace:configure.in:21: -1- AC_SUBST_TRACE([target_alias])
-m4trace:configure.in:21: -1- m4_pattern_allow([^target_alias$])
-m4trace:configure.in:25: -1- AC_SUBST([CYGPATH])
-m4trace:configure.in:25: -1- AC_SUBST_TRACE([CYGPATH])
-m4trace:configure.in:25: -1- m4_pattern_allow([^CYGPATH$])
-m4trace:configure.in:25: -1- AC_SUBST([EXEEXT])
-m4trace:configure.in:25: -1- AC_SUBST_TRACE([EXEEXT])
-m4trace:configure.in:25: -1- m4_pattern_allow([^EXEEXT$])
-m4trace:configure.in:25: -1- AC_SUBST([CYGPATH])
-m4trace:configure.in:25: -1- AC_SUBST_TRACE([CYGPATH])
-m4trace:configure.in:25: -1- m4_pattern_allow([^CYGPATH$])
-m4trace:configure.in:25: -1- AC_SUBST([PKG_LIB_FILE])
-m4trace:configure.in:25: -1- AC_SUBST_TRACE([PKG_LIB_FILE])
-m4trace:configure.in:25: -1- m4_pattern_allow([^PKG_LIB_FILE$])
-m4trace:configure.in:25: -1- AC_SUBST([PKG_STUB_LIB_FILE])
-m4trace:configure.in:25: -1- AC_SUBST_TRACE([PKG_STUB_LIB_FILE])
-m4trace:configure.in:25: -1- m4_pattern_allow([^PKG_STUB_LIB_FILE$])
-m4trace:configure.in:25: -1- AC_SUBST([PKG_STUB_SOURCES])
-m4trace:configure.in:25: -1- AC_SUBST_TRACE([PKG_STUB_SOURCES])
-m4trace:configure.in:25: -1- m4_pattern_allow([^PKG_STUB_SOURCES$])
-m4trace:configure.in:25: -1- AC_SUBST([PKG_STUB_OBJECTS])
-m4trace:configure.in:25: -1- AC_SUBST_TRACE([PKG_STUB_OBJECTS])
-m4trace:configure.in:25: -1- m4_pattern_allow([^PKG_STUB_OBJECTS$])
-m4trace:configure.in:25: -1- AC_SUBST([PKG_TCL_SOURCES])
-m4trace:configure.in:25: -1- AC_SUBST_TRACE([PKG_TCL_SOURCES])
-m4trace:configure.in:25: -1- m4_pattern_allow([^PKG_TCL_SOURCES$])
-m4trace:configure.in:25: -1- AC_SUBST([PKG_HEADERS])
-m4trace:configure.in:25: -1- AC_SUBST_TRACE([PKG_HEADERS])
-m4trace:configure.in:25: -1- m4_pattern_allow([^PKG_HEADERS$])
-m4trace:configure.in:25: -1- AC_SUBST([PKG_INCLUDES])
-m4trace:configure.in:25: -1- AC_SUBST_TRACE([PKG_INCLUDES])
-m4trace:configure.in:25: -1- m4_pattern_allow([^PKG_INCLUDES$])
-m4trace:configure.in:25: -1- AC_SUBST([PKG_LIBS])
-m4trace:configure.in:25: -1- AC_SUBST_TRACE([PKG_LIBS])
-m4trace:configure.in:25: -1- m4_pattern_allow([^PKG_LIBS$])
-m4trace:configure.in:25: -1- AC_SUBST([PKG_CFLAGS])
-m4trace:configure.in:25: -1- AC_SUBST_TRACE([PKG_CFLAGS])
-m4trace:configure.in:25: -1- m4_pattern_allow([^PKG_CFLAGS$])
-m4trace:configure.in:26: -1- AC_CONFIG_AUX_DIR([tclconfig])
-m4trace:configure.in:28: -2- _m4_warn([obsolete], [The macro `AC_HELP_STRING' is obsolete.
-You should run autoupdate.], [/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:209: AC_HELP_STRING is expanded from...
-tclconfig/tcl.m4:172: TEA_PATH_TCLCONFIG is expanded from...
-configure.in:28: the top level])
-m4trace:configure.in:29: -1- AC_SUBST([TCL_VERSION])
-m4trace:configure.in:29: -1- AC_SUBST_TRACE([TCL_VERSION])
-m4trace:configure.in:29: -1- m4_pattern_allow([^TCL_VERSION$])
-m4trace:configure.in:29: -1- AC_SUBST([TCL_BIN_DIR])
-m4trace:configure.in:29: -1- AC_SUBST_TRACE([TCL_BIN_DIR])
-m4trace:configure.in:29: -1- m4_pattern_allow([^TCL_BIN_DIR$])
-m4trace:configure.in:29: -1- AC_SUBST([TCL_SRC_DIR])
-m4trace:configure.in:29: -1- AC_SUBST_TRACE([TCL_SRC_DIR])
-m4trace:configure.in:29: -1- m4_pattern_allow([^TCL_SRC_DIR$])
-m4trace:configure.in:29: -1- AC_SUBST([TCL_LIB_FILE])
-m4trace:configure.in:29: -1- AC_SUBST_TRACE([TCL_LIB_FILE])
-m4trace:configure.in:29: -1- m4_pattern_allow([^TCL_LIB_FILE$])
-m4trace:configure.in:29: -1- AC_SUBST([TCL_LIB_FLAG])
-m4trace:configure.in:29: -1- AC_SUBST_TRACE([TCL_LIB_FLAG])
-m4trace:configure.in:29: -1- m4_pattern_allow([^TCL_LIB_FLAG$])
-m4trace:configure.in:29: -1- AC_SUBST([TCL_LIB_SPEC])
-m4trace:configure.in:29: -1- AC_SUBST_TRACE([TCL_LIB_SPEC])
-m4trace:configure.in:29: -1- m4_pattern_allow([^TCL_LIB_SPEC$])
-m4trace:configure.in:29: -1- AC_SUBST([TCL_STUB_LIB_FILE])
-m4trace:configure.in:29: -1- AC_SUBST_TRACE([TCL_STUB_LIB_FILE])
-m4trace:configure.in:29: -1- m4_pattern_allow([^TCL_STUB_LIB_FILE$])
-m4trace:configure.in:29: -1- AC_SUBST([TCL_STUB_LIB_FLAG])
-m4trace:configure.in:29: -1- AC_SUBST_TRACE([TCL_STUB_LIB_FLAG])
-m4trace:configure.in:29: -1- m4_pattern_allow([^TCL_STUB_LIB_FLAG$])
-m4trace:configure.in:29: -1- AC_SUBST([TCL_STUB_LIB_SPEC])
-m4trace:configure.in:29: -1- AC_SUBST_TRACE([TCL_STUB_LIB_SPEC])
-m4trace:configure.in:29: -1- m4_pattern_allow([^TCL_STUB_LIB_SPEC$])
-m4trace:configure.in:29: -1- AC_SUBST([TCL_LIBS])
-m4trace:configure.in:29: -1- AC_SUBST_TRACE([TCL_LIBS])
-m4trace:configure.in:29: -1- m4_pattern_allow([^TCL_LIBS$])
-m4trace:configure.in:29: -1- AC_SUBST([TCL_DEFS])
-m4trace:configure.in:29: -1- AC_SUBST_TRACE([TCL_DEFS])
-m4trace:configure.in:29: -1- m4_pattern_allow([^TCL_DEFS$])
-m4trace:configure.in:29: -1- AC_SUBST([TCL_EXTRA_CFLAGS])
-m4trace:configure.in:29: -1- AC_SUBST_TRACE([TCL_EXTRA_CFLAGS])
-m4trace:configure.in:29: -1- m4_pattern_allow([^TCL_EXTRA_CFLAGS$])
-m4trace:configure.in:29: -1- AC_SUBST([TCL_LD_FLAGS])
-m4trace:configure.in:29: -1- AC_SUBST_TRACE([TCL_LD_FLAGS])
-m4trace:configure.in:29: -1- m4_pattern_allow([^TCL_LD_FLAGS$])
-m4trace:configure.in:29: -1- AC_SUBST([TCL_SHLIB_LD_LIBS])
-m4trace:configure.in:29: -1- AC_SUBST_TRACE([TCL_SHLIB_LD_LIBS])
-m4trace:configure.in:29: -1- m4_pattern_allow([^TCL_SHLIB_LD_LIBS$])
-m4trace:configure.in:33: -1- AC_SUBST([CC])
-m4trace:configure.in:33: -1- AC_SUBST_TRACE([CC])
-m4trace:configure.in:33: -1- m4_pattern_allow([^CC$])
-m4trace:configure.in:33: -1- AC_SUBST([CFLAGS])
-m4trace:configure.in:33: -1- AC_SUBST_TRACE([CFLAGS])
-m4trace:configure.in:33: -1- m4_pattern_allow([^CFLAGS$])
-m4trace:configure.in:33: -1- AC_SUBST([LDFLAGS])
-m4trace:configure.in:33: -1- AC_SUBST_TRACE([LDFLAGS])
-m4trace:configure.in:33: -1- m4_pattern_allow([^LDFLAGS$])
-m4trace:configure.in:33: -1- AC_SUBST([LIBS])
-m4trace:configure.in:33: -1- AC_SUBST_TRACE([LIBS])
-m4trace:configure.in:33: -1- m4_pattern_allow([^LIBS$])
-m4trace:configure.in:33: -1- AC_SUBST([CPPFLAGS])
-m4trace:configure.in:33: -1- AC_SUBST_TRACE([CPPFLAGS])
-m4trace:configure.in:33: -1- m4_pattern_allow([^CPPFLAGS$])
-m4trace:configure.in:33: -1- AC_SUBST([CC])
-m4trace:configure.in:33: -1- AC_SUBST_TRACE([CC])
-m4trace:configure.in:33: -1- m4_pattern_allow([^CC$])
-m4trace:configure.in:33: -1- AC_SUBST([CC])
-m4trace:configure.in:33: -1- AC_SUBST_TRACE([CC])
-m4trace:configure.in:33: -1- m4_pattern_allow([^CC$])
-m4trace:configure.in:33: -1- AC_SUBST([CC])
-m4trace:configure.in:33: -1- AC_SUBST_TRACE([CC])
-m4trace:configure.in:33: -1- m4_pattern_allow([^CC$])
-m4trace:configure.in:33: -1- AC_SUBST([CC])
-m4trace:configure.in:33: -1- AC_SUBST_TRACE([CC])
-m4trace:configure.in:33: -1- m4_pattern_allow([^CC$])
-m4trace:configure.in:33: -1- AC_SUBST([ac_ct_CC])
-m4trace:configure.in:33: -1- AC_SUBST_TRACE([ac_ct_CC])
-m4trace:configure.in:33: -1- m4_pattern_allow([^ac_ct_CC$])
-m4trace:configure.in:33: -1- AC_SUBST([EXEEXT], [$ac_cv_exeext])
-m4trace:configure.in:33: -1- AC_SUBST_TRACE([EXEEXT])
-m4trace:configure.in:33: -1- m4_pattern_allow([^EXEEXT$])
-m4trace:configure.in:33: -1- AC_SUBST([OBJEXT], [$ac_cv_objext])
-m4trace:configure.in:33: -1- AC_SUBST_TRACE([OBJEXT])
-m4trace:configure.in:33: -1- m4_pattern_allow([^OBJEXT$])
-m4trace:configure.in:33: -1- AC_SUBST([CPP])
-m4trace:configure.in:33: -1- AC_SUBST_TRACE([CPP])
-m4trace:configure.in:33: -1- m4_pattern_allow([^CPP$])
-m4trace:configure.in:33: -1- AC_SUBST([CPPFLAGS])
-m4trace:configure.in:33: -1- AC_SUBST_TRACE([CPPFLAGS])
-m4trace:configure.in:33: -1- m4_pattern_allow([^CPPFLAGS$])
-m4trace:configure.in:33: -1- AC_SUBST([CPP])
-m4trace:configure.in:33: -1- AC_SUBST_TRACE([CPP])
-m4trace:configure.in:33: -1- m4_pattern_allow([^CPP$])
-m4trace:configure.in:33: -1- AC_REQUIRE_AUX_FILE([install-sh])
-m4trace:configure.in:33: -1- AC_SUBST([INSTALL_PROGRAM])
-m4trace:configure.in:33: -1- AC_SUBST_TRACE([INSTALL_PROGRAM])
-m4trace:configure.in:33: -1- m4_pattern_allow([^INSTALL_PROGRAM$])
-m4trace:configure.in:33: -1- AC_SUBST([INSTALL_SCRIPT])
-m4trace:configure.in:33: -1- AC_SUBST_TRACE([INSTALL_SCRIPT])
-m4trace:configure.in:33: -1- m4_pattern_allow([^INSTALL_SCRIPT$])
-m4trace:configure.in:33: -1- AC_SUBST([INSTALL_DATA])
-m4trace:configure.in:33: -1- AC_SUBST_TRACE([INSTALL_DATA])
-m4trace:configure.in:33: -1- m4_pattern_allow([^INSTALL_DATA$])
-m4trace:configure.in:33: -1- AC_SUBST([SET_MAKE])
-m4trace:configure.in:33: -1- AC_SUBST_TRACE([SET_MAKE])
-m4trace:configure.in:33: -1- m4_pattern_allow([^SET_MAKE$])
-m4trace:configure.in:33: -1- AC_SUBST([RANLIB])
-m4trace:configure.in:33: -1- AC_SUBST_TRACE([RANLIB])
-m4trace:configure.in:33: -1- m4_pattern_allow([^RANLIB$])
-m4trace:configure.in:33: -1- _m4_warn([obsolete], [The macro `AC_TRY_COMPILE' is obsolete.
-You should run autoupdate.], [/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:2368: AC_TRY_COMPILE is expanded from...
-/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/m4sugar/m4sh.m4:523: AS_IF is expanded from...
-/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:1905: AC_CACHE_VAL is expanded from...
-/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:1918: AC_CACHE_CHECK is expanded from...
-tclconfig/tcl.m4:3187: TEA_SETUP_COMPILER is expanded from...
-configure.in:33: the top level])
-m4trace:configure.in:33: -1- AC_SUBST([GREP])
-m4trace:configure.in:33: -1- AC_SUBST_TRACE([GREP])
-m4trace:configure.in:33: -1- m4_pattern_allow([^GREP$])
-m4trace:configure.in:33: -1- AC_SUBST([GREP])
-m4trace:configure.in:33: -1- AC_SUBST_TRACE([GREP])
-m4trace:configure.in:33: -1- m4_pattern_allow([^GREP$])
-m4trace:configure.in:33: -1- AC_SUBST([EGREP])
-m4trace:configure.in:33: -1- AC_SUBST_TRACE([EGREP])
-m4trace:configure.in:33: -1- m4_pattern_allow([^EGREP$])
-m4trace:configure.in:33: -1- AC_SUBST([EGREP])
-m4trace:configure.in:33: -1- AC_SUBST_TRACE([EGREP])
-m4trace:configure.in:33: -1- m4_pattern_allow([^EGREP$])
-m4trace:configure.in:33: -1- AC_DEFINE_TRACE_LITERAL([STDC_HEADERS])
-m4trace:configure.in:33: -1- m4_pattern_allow([^STDC_HEADERS$])
-m4trace:configure.in:33: -1- AH_OUTPUT([STDC_HEADERS], [/* Define to 1 if you have the ANSI C header files. */
-#undef STDC_HEADERS])
-m4trace:configure.in:33: -1- AH_OUTPUT([HAVE_SYS_TYPES_H], [/* Define to 1 if you have the <sys/types.h> header file. */
-#undef HAVE_SYS_TYPES_H])
-m4trace:configure.in:33: -1- AH_OUTPUT([HAVE_SYS_STAT_H], [/* Define to 1 if you have the <sys/stat.h> header file. */
-#undef HAVE_SYS_STAT_H])
-m4trace:configure.in:33: -1- AH_OUTPUT([HAVE_STDLIB_H], [/* Define to 1 if you have the <stdlib.h> header file. */
-#undef HAVE_STDLIB_H])
-m4trace:configure.in:33: -1- AH_OUTPUT([HAVE_STRING_H], [/* Define to 1 if you have the <string.h> header file. */
-#undef HAVE_STRING_H])
-m4trace:configure.in:33: -1- AH_OUTPUT([HAVE_MEMORY_H], [/* Define to 1 if you have the <memory.h> header file. */
-#undef HAVE_MEMORY_H])
-m4trace:configure.in:33: -1- AH_OUTPUT([HAVE_STRINGS_H], [/* Define to 1 if you have the <strings.h> header file. */
-#undef HAVE_STRINGS_H])
-m4trace:configure.in:33: -1- AH_OUTPUT([HAVE_INTTYPES_H], [/* Define to 1 if you have the <inttypes.h> header file. */
-#undef HAVE_INTTYPES_H])
-m4trace:configure.in:33: -1- AH_OUTPUT([HAVE_STDINT_H], [/* Define to 1 if you have the <stdint.h> header file. */
-#undef HAVE_STDINT_H])
-m4trace:configure.in:33: -1- AH_OUTPUT([HAVE_UNISTD_H], [/* Define to 1 if you have the <unistd.h> header file. */
-#undef HAVE_UNISTD_H])
-m4trace:configure.in:33: -1- AC_DEFINE_TRACE_LITERAL([WORDS_BIGENDIAN])
-m4trace:configure.in:33: -1- m4_pattern_allow([^WORDS_BIGENDIAN$])
-m4trace:configure.in:33: -1- AH_OUTPUT([WORDS_BIGENDIAN], [/* Define to 1 if your processor stores words with the most significant byte
-   first (like Motorola and SPARC, unlike Intel and VAX). */
-#undef WORDS_BIGENDIAN])
-m4trace:configure.in:33: -1- AC_DEFINE_TRACE_LITERAL([HAVE_NET_ERRNO_H])
-m4trace:configure.in:33: -1- m4_pattern_allow([^HAVE_NET_ERRNO_H$])
-m4trace:configure.in:33: -1- AH_OUTPUT([HAVE_NET_ERRNO_H], [/* Do we have <net/errno.h>? */
-#undef HAVE_NET_ERRNO_H])
-m4trace:configure.in:33: -1- AC_SUBST([TCL_LIBS])
-m4trace:configure.in:33: -1- AC_SUBST_TRACE([TCL_LIBS])
-m4trace:configure.in:33: -1- m4_pattern_allow([^TCL_LIBS$])
-m4trace:configure.in:33: -1- AC_SUBST([MATH_LIBS])
-m4trace:configure.in:33: -1- AC_SUBST_TRACE([MATH_LIBS])
-m4trace:configure.in:33: -1- m4_pattern_allow([^MATH_LIBS$])
-m4trace:configure.in:33: -1- _m4_warn([obsolete], [The macro `AC_TRY_LINK' is obsolete.
-You should run autoupdate.], [/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:2415: AC_TRY_LINK is expanded from...
-/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/m4sugar/m4sh.m4:523: AS_IF is expanded from...
-/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:1905: AC_CACHE_VAL is expanded from...
-/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:1918: AC_CACHE_CHECK is expanded from...
-tclconfig/tcl.m4:2268: TEA_MISSING_POSIX_HEADERS is expanded from...
-tclconfig/tcl.m4:3187: TEA_SETUP_COMPILER is expanded from...
-configure.in:33: the top level])
-m4trace:configure.in:33: -1- AC_DEFINE_TRACE_LITERAL([NO_DIRENT_H])
-m4trace:configure.in:33: -1- m4_pattern_allow([^NO_DIRENT_H$])
-m4trace:configure.in:33: -1- AH_OUTPUT([NO_DIRENT_H], [/* Do we have <dirent.h>? */
-#undef NO_DIRENT_H])
-m4trace:configure.in:33: -1- AC_DEFINE_TRACE_LITERAL([NO_ERRNO_H])
-m4trace:configure.in:33: -1- m4_pattern_allow([^NO_ERRNO_H$])
-m4trace:configure.in:33: -1- AH_OUTPUT([NO_ERRNO_H], [/* Do we have <errno.h>? */
-#undef NO_ERRNO_H])
-m4trace:configure.in:33: -1- AC_DEFINE_TRACE_LITERAL([NO_FLOAT_H])
-m4trace:configure.in:33: -1- m4_pattern_allow([^NO_FLOAT_H$])
-m4trace:configure.in:33: -1- AH_OUTPUT([NO_FLOAT_H], [/* Do we have <float.h>? */
-#undef NO_FLOAT_H])
-m4trace:configure.in:33: -1- AC_DEFINE_TRACE_LITERAL([NO_VALUES_H])
-m4trace:configure.in:33: -1- m4_pattern_allow([^NO_VALUES_H$])
-m4trace:configure.in:33: -1- AH_OUTPUT([NO_VALUES_H], [/* Do we have <values.h>? */
-#undef NO_VALUES_H])
-m4trace:configure.in:33: -1- AC_DEFINE_TRACE_LITERAL([HAVE_LIMITS_H])
-m4trace:configure.in:33: -1- m4_pattern_allow([^HAVE_LIMITS_H$])
-m4trace:configure.in:33: -1- AH_OUTPUT([HAVE_LIMITS_H], [/* Do we have <limits.h>? */
-#undef HAVE_LIMITS_H])
-m4trace:configure.in:33: -1- AC_DEFINE_TRACE_LITERAL([NO_LIMITS_H])
-m4trace:configure.in:33: -1- m4_pattern_allow([^NO_LIMITS_H$])
-m4trace:configure.in:33: -1- AH_OUTPUT([NO_LIMITS_H], [/* Do we have <limits.h>? */
-#undef NO_LIMITS_H])
-m4trace:configure.in:33: -1- AC_DEFINE_TRACE_LITERAL([NO_STDLIB_H])
-m4trace:configure.in:33: -1- m4_pattern_allow([^NO_STDLIB_H$])
-m4trace:configure.in:33: -1- AH_OUTPUT([NO_STDLIB_H], [/* Do we have <stdlib.h>? */
-#undef NO_STDLIB_H])
-m4trace:configure.in:33: -1- AC_DEFINE_TRACE_LITERAL([NO_STRING_H])
-m4trace:configure.in:33: -1- m4_pattern_allow([^NO_STRING_H$])
-m4trace:configure.in:33: -1- AH_OUTPUT([NO_STRING_H], [/* Do we have <string.h>? */
-#undef NO_STRING_H])
-m4trace:configure.in:33: -1- AC_DEFINE_TRACE_LITERAL([NO_SYS_WAIT_H])
-m4trace:configure.in:33: -1- m4_pattern_allow([^NO_SYS_WAIT_H$])
-m4trace:configure.in:33: -1- AH_OUTPUT([NO_SYS_WAIT_H], [/* Do we have <sys/wait.h>? */
-#undef NO_SYS_WAIT_H])
-m4trace:configure.in:33: -1- AC_DEFINE_TRACE_LITERAL([NO_DLFCN_H])
-m4trace:configure.in:33: -1- m4_pattern_allow([^NO_DLFCN_H$])
-m4trace:configure.in:33: -1- AH_OUTPUT([NO_DLFCN_H], [/* Do we have <dlfcn.h>? */
-#undef NO_DLFCN_H])
-m4trace:configure.in:33: -1- _m4_warn([obsolete], [The macro `AC_HAVE_HEADERS' is obsolete.
-You should run autoupdate.], [/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/oldnames.m4:56: AC_HAVE_HEADERS is expanded from...
-tclconfig/tcl.m4:2268: TEA_MISSING_POSIX_HEADERS is expanded from...
-tclconfig/tcl.m4:3187: TEA_SETUP_COMPILER is expanded from...
-configure.in:33: the top level])
-m4trace:configure.in:33: -1- AH_OUTPUT([HAVE_SYS_PARAM_H], [/* Define to 1 if you have the <sys/param.h> header file. */
-#undef HAVE_SYS_PARAM_H])
-m4trace:configure.in:44: -1- AC_SUBST([PKG_SOURCES])
-m4trace:configure.in:44: -1- AC_SUBST_TRACE([PKG_SOURCES])
-m4trace:configure.in:44: -1- m4_pattern_allow([^PKG_SOURCES$])
-m4trace:configure.in:44: -1- AC_SUBST([PKG_OBJECTS])
-m4trace:configure.in:44: -1- AC_SUBST_TRACE([PKG_OBJECTS])
-m4trace:configure.in:44: -1- m4_pattern_allow([^PKG_OBJECTS$])
-m4trace:configure.in:45: -1- AC_SUBST([PKG_HEADERS])
-m4trace:configure.in:45: -1- AC_SUBST_TRACE([PKG_HEADERS])
-m4trace:configure.in:45: -1- m4_pattern_allow([^PKG_HEADERS$])
-m4trace:configure.in:46: -1- AC_SUBST([PKG_INCLUDES])
-m4trace:configure.in:46: -1- AC_SUBST_TRACE([PKG_INCLUDES])
-m4trace:configure.in:46: -1- m4_pattern_allow([^PKG_INCLUDES$])
-m4trace:configure.in:48: -1- AC_SUBST([PKG_LIBS])
-m4trace:configure.in:48: -1- AC_SUBST_TRACE([PKG_LIBS])
-m4trace:configure.in:48: -1- m4_pattern_allow([^PKG_LIBS$])
-m4trace:configure.in:49: -1- AC_SUBST([PKG_CFLAGS])
-m4trace:configure.in:49: -1- AC_SUBST_TRACE([PKG_CFLAGS])
-m4trace:configure.in:49: -1- m4_pattern_allow([^PKG_CFLAGS$])
-m4trace:configure.in:50: -1- AC_SUBST([PKG_STUB_SOURCES])
-m4trace:configure.in:50: -1- AC_SUBST_TRACE([PKG_STUB_SOURCES])
-m4trace:configure.in:50: -1- m4_pattern_allow([^PKG_STUB_SOURCES$])
-m4trace:configure.in:50: -1- AC_SUBST([PKG_STUB_OBJECTS])
-m4trace:configure.in:50: -1- AC_SUBST_TRACE([PKG_STUB_OBJECTS])
-m4trace:configure.in:50: -1- m4_pattern_allow([^PKG_STUB_OBJECTS$])
-m4trace:configure.in:51: -1- AC_SUBST([PKG_TCL_SOURCES])
-m4trace:configure.in:51: -1- AC_SUBST_TRACE([PKG_TCL_SOURCES])
-m4trace:configure.in:51: -1- m4_pattern_allow([^PKG_TCL_SOURCES$])
-m4trace:configure.in:68: -1- AC_DEFINE_TRACE_LITERAL([BUILD_Tclxml])
-m4trace:configure.in:68: -1- m4_pattern_allow([^BUILD_Tclxml$])
-m4trace:configure.in:68: -1- AH_OUTPUT([BUILD_Tclxml], [/* Build windows export dll */
-#undef BUILD_Tclxml])
-m4trace:configure.in:73: -1- AC_SUBST([CLEANFILES])
-m4trace:configure.in:73: -1- AC_SUBST_TRACE([CLEANFILES])
-m4trace:configure.in:73: -1- m4_pattern_allow([^CLEANFILES$])
-m4trace:configure.in:75: -1- AC_SUBST([TCL_INCLUDES])
-m4trace:configure.in:75: -1- AC_SUBST_TRACE([TCL_INCLUDES])
-m4trace:configure.in:75: -1- m4_pattern_allow([^TCL_INCLUDES$])
-m4trace:configure.in:82: -2- _m4_warn([obsolete], [The macro `AC_HELP_STRING' is obsolete.
-You should run autoupdate.], [/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:209: AC_HELP_STRING is expanded from...
-tclconfig/tcl.m4:684: TEA_ENABLE_THREADS is expanded from...
-configure.in:82: the top level])
-m4trace:configure.in:82: -1- AC_DEFINE_TRACE_LITERAL([USE_THREAD_ALLOC])
-m4trace:configure.in:82: -1- m4_pattern_allow([^USE_THREAD_ALLOC$])
-m4trace:configure.in:82: -1- AH_OUTPUT([USE_THREAD_ALLOC], [/* Do we want to use the threaded memory allocator? */
-#undef USE_THREAD_ALLOC])
-m4trace:configure.in:82: -1- AC_DEFINE_TRACE_LITERAL([_REENTRANT])
-m4trace:configure.in:82: -1- m4_pattern_allow([^_REENTRANT$])
-m4trace:configure.in:82: -1- AH_OUTPUT([_REENTRANT], [/* Do we want the reentrant OS API? */
-#undef _REENTRANT])
-m4trace:configure.in:82: -1- AC_DEFINE_TRACE_LITERAL([_POSIX_PTHREAD_SEMANTICS])
-m4trace:configure.in:82: -1- m4_pattern_allow([^_POSIX_PTHREAD_SEMANTICS$])
-m4trace:configure.in:82: -1- AH_OUTPUT([_POSIX_PTHREAD_SEMANTICS], [/* Do we really want to follow the standard? Yes we do! */
-#undef _POSIX_PTHREAD_SEMANTICS])
-m4trace:configure.in:82: -1- AC_DEFINE_TRACE_LITERAL([_THREAD_SAFE])
-m4trace:configure.in:82: -1- m4_pattern_allow([^_THREAD_SAFE$])
-m4trace:configure.in:82: -1- AH_OUTPUT([_THREAD_SAFE], [/* Do we want the thread-safe OS API? */
-#undef _THREAD_SAFE])
-m4trace:configure.in:82: -1- AC_DEFINE_TRACE_LITERAL([TCL_THREADS])
-m4trace:configure.in:82: -1- m4_pattern_allow([^TCL_THREADS$])
-m4trace:configure.in:82: -1- AH_OUTPUT([TCL_THREADS], [/* Are we building with threads enabled? */
-#undef TCL_THREADS])
-m4trace:configure.in:82: -1- AC_SUBST([TCL_THREADS])
-m4trace:configure.in:82: -1- AC_SUBST_TRACE([TCL_THREADS])
-m4trace:configure.in:82: -1- m4_pattern_allow([^TCL_THREADS$])
-m4trace:configure.in:89: -2- _m4_warn([obsolete], [The macro `AC_HELP_STRING' is obsolete.
-You should run autoupdate.], [/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:209: AC_HELP_STRING is expanded from...
-tclconfig/tcl.m4:552: TEA_ENABLE_SHARED is expanded from...
-configure.in:89: the top level])
-m4trace:configure.in:89: -1- AC_DEFINE_TRACE_LITERAL([STATIC_BUILD])
-m4trace:configure.in:89: -1- m4_pattern_allow([^STATIC_BUILD$])
-m4trace:configure.in:89: -1- AH_OUTPUT([STATIC_BUILD], [/* Is this a static build? */
-#undef STATIC_BUILD])
-m4trace:configure.in:89: -1- AC_SUBST([SHARED_BUILD])
-m4trace:configure.in:89: -1- AC_SUBST_TRACE([SHARED_BUILD])
-m4trace:configure.in:89: -1- m4_pattern_allow([^SHARED_BUILD$])
-m4trace:configure.in:97: -2- _m4_warn([obsolete], [The macro `AC_HELP_STRING' is obsolete.
-You should run autoupdate.], [/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:209: AC_HELP_STRING is expanded from...
-tclconfig/tcl.m4:2060: TEA_CONFIG_CFLAGS is expanded from...
-configure.in:97: the top level])
-m4trace:configure.in:97: -2- _m4_warn([obsolete], [The macro `AC_HELP_STRING' is obsolete.
-You should run autoupdate.], [/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:209: AC_HELP_STRING is expanded from...
-tclconfig/tcl.m4:2060: TEA_CONFIG_CFLAGS is expanded from...
-configure.in:97: the top level])
-m4trace:configure.in:97: -1- AC_SUBST([AR])
-m4trace:configure.in:97: -1- AC_SUBST_TRACE([AR])
-m4trace:configure.in:97: -1- m4_pattern_allow([^AR$])
-m4trace:configure.in:97: -1- AC_SUBST([PKG_LIBS])
-m4trace:configure.in:97: -1- AC_SUBST_TRACE([PKG_LIBS])
-m4trace:configure.in:97: -1- m4_pattern_allow([^PKG_LIBS$])
-m4trace:configure.in:97: -1- AC_DEFINE_TRACE_LITERAL([_WIN32_WCE])
-m4trace:configure.in:97: -1- m4_pattern_allow([^_WIN32_WCE$])
-m4trace:configure.in:97: -1- AH_OUTPUT([_WIN32_WCE], [/* _WIN32_WCE version */
-#undef _WIN32_WCE])
-m4trace:configure.in:97: -1- AC_DEFINE_TRACE_LITERAL([UNDER_CE])
-m4trace:configure.in:97: -1- m4_pattern_allow([^UNDER_CE$])
-m4trace:configure.in:97: -1- AH_OUTPUT([UNDER_CE], [/* UNDER_CE version */
-#undef UNDER_CE])
-m4trace:configure.in:97: -1- AC_SUBST([CELIB_DIR])
-m4trace:configure.in:97: -1- AC_SUBST_TRACE([CELIB_DIR])
-m4trace:configure.in:97: -1- m4_pattern_allow([^CELIB_DIR$])
-m4trace:configure.in:97: -1- AC_LIBSOURCE([tclLoadAix.c])
-m4trace:configure.in:97: -1- AC_SUBST([LIB@&t at OBJS], ["$LIB@&t at OBJS tclLoadAix.$ac_objext"])
-m4trace:configure.in:97: -1- AC_SUBST_TRACE([LIB@&t at OBJS])
-m4trace:configure.in:97: -1- m4_pattern_allow([^LIB@&t at OBJS$])
-m4trace:configure.in:97: -1- AC_DEFINE_TRACE_LITERAL([USE_DELTA_FOR_TZ])
-m4trace:configure.in:97: -1- m4_pattern_allow([^USE_DELTA_FOR_TZ$])
-m4trace:configure.in:97: -1- AH_OUTPUT([USE_DELTA_FOR_TZ], [/* Do we need a special AIX hack for timezones? */
-#undef USE_DELTA_FOR_TZ])
-m4trace:configure.in:97: -1- AC_DEFINE_TRACE_LITERAL([_XOPEN_SOURCE_EXTENDED])
-m4trace:configure.in:97: -1- m4_pattern_allow([^_XOPEN_SOURCE_EXTENDED$])
-m4trace:configure.in:97: -1- AH_OUTPUT([_XOPEN_SOURCE_EXTENDED], [/* Do we want to use the XOPEN network library? */
-#undef _XOPEN_SOURCE_EXTENDED])
-m4trace:configure.in:97: -1- _m4_warn([obsolete], [The macro `AC_TRY_LINK' is obsolete.
-You should run autoupdate.], [/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:2415: AC_TRY_LINK is expanded from...
-/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/m4sugar/m4sh.m4:523: AS_IF is expanded from...
-/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:1905: AC_CACHE_VAL is expanded from...
-/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:1918: AC_CACHE_CHECK is expanded from...
-tclconfig/tcl.m4:2060: TEA_CONFIG_CFLAGS is expanded from...
-configure.in:97: the top level])
-m4trace:configure.in:97: -1- _m4_warn([obsolete], [The macro `AC_TRY_LINK' is obsolete.
-You should run autoupdate.], [/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:2415: AC_TRY_LINK is expanded from...
-/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/m4sugar/m4sh.m4:523: AS_IF is expanded from...
-/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:1905: AC_CACHE_VAL is expanded from...
-/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:1918: AC_CACHE_CHECK is expanded from...
-tclconfig/tcl.m4:2060: TEA_CONFIG_CFLAGS is expanded from...
-configure.in:97: the top level])
-m4trace:configure.in:97: -1- _m4_warn([obsolete], [The macro `AC_TRY_LINK' is obsolete.
-You should run autoupdate.], [/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:2415: AC_TRY_LINK is expanded from...
-/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/m4sugar/m4sh.m4:523: AS_IF is expanded from...
-/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:1905: AC_CACHE_VAL is expanded from...
-/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:1918: AC_CACHE_CHECK is expanded from...
-tclconfig/tcl.m4:2060: TEA_CONFIG_CFLAGS is expanded from...
-configure.in:97: the top level])
-m4trace:configure.in:97: -1- _m4_warn([obsolete], [The macro `AC_TRY_LINK' is obsolete.
-You should run autoupdate.], [/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:2415: AC_TRY_LINK is expanded from...
-/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/m4sugar/m4sh.m4:523: AS_IF is expanded from...
-/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:1905: AC_CACHE_VAL is expanded from...
-/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:1918: AC_CACHE_CHECK is expanded from...
-tclconfig/tcl.m4:2060: TEA_CONFIG_CFLAGS is expanded from...
-configure.in:97: the top level])
-m4trace:configure.in:97: -1- _m4_warn([obsolete], [The macro `AC_TRY_LINK' is obsolete.
-You should run autoupdate.], [/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:2415: AC_TRY_LINK is expanded from...
-/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/m4sugar/m4sh.m4:523: AS_IF is expanded from...
-/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:1905: AC_CACHE_VAL is expanded from...
-/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:1918: AC_CACHE_CHECK is expanded from...
-tclconfig/tcl.m4:2060: TEA_CONFIG_CFLAGS is expanded from...
-configure.in:97: the top level])
-m4trace:configure.in:97: -1- AC_DEFINE_TRACE_LITERAL([_OE_SOCKETS])
-m4trace:configure.in:97: -1- m4_pattern_allow([^_OE_SOCKETS$])
-m4trace:configure.in:97: -1- AH_OUTPUT([_OE_SOCKETS], [/* # needed in sys/socket.h Should OS/390 do the right thing with sockets? */
-#undef _OE_SOCKETS])
-m4trace:configure.in:97: -1- AC_DEFINE_TRACE_LITERAL([_REENTRANT])
-m4trace:configure.in:97: -1- m4_pattern_allow([^_REENTRANT$])
-m4trace:configure.in:97: -1- AH_OUTPUT([_REENTRANT], [/* Do we want the reentrant OS API? */
-#undef _REENTRANT])
-m4trace:configure.in:97: -1- AC_DEFINE_TRACE_LITERAL([_POSIX_PTHREAD_SEMANTICS])
-m4trace:configure.in:97: -1- m4_pattern_allow([^_POSIX_PTHREAD_SEMANTICS$])
-m4trace:configure.in:97: -1- AH_OUTPUT([_POSIX_PTHREAD_SEMANTICS], [/* Do we really want to follow the standard? Yes we do! */
-#undef _POSIX_PTHREAD_SEMANTICS])
-m4trace:configure.in:97: -1- AC_DEFINE_TRACE_LITERAL([_REENTRANT])
-m4trace:configure.in:97: -1- m4_pattern_allow([^_REENTRANT$])
-m4trace:configure.in:97: -1- AH_OUTPUT([_REENTRANT], [/* Do we want the reentrant OS API? */
-#undef _REENTRANT])
-m4trace:configure.in:97: -1- AC_DEFINE_TRACE_LITERAL([_POSIX_PTHREAD_SEMANTICS])
-m4trace:configure.in:97: -1- m4_pattern_allow([^_POSIX_PTHREAD_SEMANTICS$])
-m4trace:configure.in:97: -1- AH_OUTPUT([_POSIX_PTHREAD_SEMANTICS], [/* Do we really want to follow the standard? Yes we do! */
-#undef _POSIX_PTHREAD_SEMANTICS])
-m4trace:configure.in:97: -1- _m4_warn([obsolete], [The macro `AC_TRY_LINK' is obsolete.
-You should run autoupdate.], [/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:2415: AC_TRY_LINK is expanded from...
-/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/m4sugar/m4sh.m4:523: AS_IF is expanded from...
-/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:1905: AC_CACHE_VAL is expanded from...
-/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:1918: AC_CACHE_CHECK is expanded from...
-tclconfig/tcl.m4:2060: TEA_CONFIG_CFLAGS is expanded from...
-configure.in:97: the top level])
-m4trace:configure.in:97: -2- _m4_warn([obsolete], [The macro `AC_HELP_STRING' is obsolete.
-You should run autoupdate.], [/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:209: AC_HELP_STRING is expanded from...
-tclconfig/tcl.m4:2060: TEA_CONFIG_CFLAGS is expanded from...
-configure.in:97: the top level])
-m4trace:configure.in:97: -1- AC_SUBST([DL_LIBS])
-m4trace:configure.in:97: -1- AC_SUBST_TRACE([DL_LIBS])
-m4trace:configure.in:97: -1- m4_pattern_allow([^DL_LIBS$])
-m4trace:configure.in:97: -1- AC_SUBST([CFLAGS_DEBUG])
-m4trace:configure.in:97: -1- AC_SUBST_TRACE([CFLAGS_DEBUG])
-m4trace:configure.in:97: -1- m4_pattern_allow([^CFLAGS_DEBUG$])
-m4trace:configure.in:97: -1- AC_SUBST([CFLAGS_OPTIMIZE])
-m4trace:configure.in:97: -1- AC_SUBST_TRACE([CFLAGS_OPTIMIZE])
-m4trace:configure.in:97: -1- m4_pattern_allow([^CFLAGS_OPTIMIZE$])
-m4trace:configure.in:97: -1- AC_SUBST([CFLAGS_WARNING])
-m4trace:configure.in:97: -1- AC_SUBST_TRACE([CFLAGS_WARNING])
-m4trace:configure.in:97: -1- m4_pattern_allow([^CFLAGS_WARNING$])
-m4trace:configure.in:97: -1- AC_SUBST([STLIB_LD])
-m4trace:configure.in:97: -1- AC_SUBST_TRACE([STLIB_LD])
-m4trace:configure.in:97: -1- m4_pattern_allow([^STLIB_LD$])
-m4trace:configure.in:97: -1- AC_SUBST([SHLIB_LD])
-m4trace:configure.in:97: -1- AC_SUBST_TRACE([SHLIB_LD])
-m4trace:configure.in:97: -1- m4_pattern_allow([^SHLIB_LD$])
-m4trace:configure.in:97: -1- AC_SUBST([SHLIB_LD_LIBS])
-m4trace:configure.in:97: -1- AC_SUBST_TRACE([SHLIB_LD_LIBS])
-m4trace:configure.in:97: -1- m4_pattern_allow([^SHLIB_LD_LIBS$])
-m4trace:configure.in:97: -1- AC_SUBST([SHLIB_CFLAGS])
-m4trace:configure.in:97: -1- AC_SUBST_TRACE([SHLIB_CFLAGS])
-m4trace:configure.in:97: -1- m4_pattern_allow([^SHLIB_CFLAGS$])
-m4trace:configure.in:97: -1- AC_SUBST([LD_LIBRARY_PATH_VAR])
-m4trace:configure.in:97: -1- AC_SUBST_TRACE([LD_LIBRARY_PATH_VAR])
-m4trace:configure.in:97: -1- m4_pattern_allow([^LD_LIBRARY_PATH_VAR$])
-m4trace:configure.in:97: -3- _m4_warn([obsolete], [The macro `AC_TRY_COMPILE' is obsolete.
-You should run autoupdate.], [/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:2368: AC_TRY_COMPILE is expanded from...
-tclconfig/tcl.m4:2652: TEA_TCL_EARLY_FLAG is expanded from...
-tclconfig/tcl.m4:2668: TEA_TCL_EARLY_FLAGS is expanded from...
-tclconfig/tcl.m4:2060: TEA_CONFIG_CFLAGS is expanded from...
-configure.in:97: the top level])
-m4trace:configure.in:97: -2- _m4_warn([obsolete], [The macro `AC_TRY_COMPILE' is obsolete.
-You should run autoupdate.], [/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:2368: AC_TRY_COMPILE is expanded from...
-tclconfig/tcl.m4:2652: TEA_TCL_EARLY_FLAG is expanded from...
-tclconfig/tcl.m4:2668: TEA_TCL_EARLY_FLAGS is expanded from...
-tclconfig/tcl.m4:2060: TEA_CONFIG_CFLAGS is expanded from...
-configure.in:97: the top level])
-m4trace:configure.in:97: -1- AC_DEFINE_TRACE_LITERAL([_ISOC99_SOURCE])
-m4trace:configure.in:97: -1- m4_pattern_allow([^_ISOC99_SOURCE$])
-m4trace:configure.in:97: -1- AH_OUTPUT([_ISOC99_SOURCE], [/* Add the _ISOC99_SOURCE flag when building */
-#undef _ISOC99_SOURCE])
-m4trace:configure.in:97: -3- _m4_warn([obsolete], [The macro `AC_TRY_COMPILE' is obsolete.
-You should run autoupdate.], [/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:2368: AC_TRY_COMPILE is expanded from...
-tclconfig/tcl.m4:2652: TEA_TCL_EARLY_FLAG is expanded from...
-tclconfig/tcl.m4:2668: TEA_TCL_EARLY_FLAGS is expanded from...
-tclconfig/tcl.m4:2060: TEA_CONFIG_CFLAGS is expanded from...
-configure.in:97: the top level])
-m4trace:configure.in:97: -2- _m4_warn([obsolete], [The macro `AC_TRY_COMPILE' is obsolete.
-You should run autoupdate.], [/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:2368: AC_TRY_COMPILE is expanded from...
-tclconfig/tcl.m4:2652: TEA_TCL_EARLY_FLAG is expanded from...
-tclconfig/tcl.m4:2668: TEA_TCL_EARLY_FLAGS is expanded from...
-tclconfig/tcl.m4:2060: TEA_CONFIG_CFLAGS is expanded from...
-configure.in:97: the top level])
-m4trace:configure.in:97: -1- AC_DEFINE_TRACE_LITERAL([_LARGEFILE64_SOURCE])
-m4trace:configure.in:97: -1- m4_pattern_allow([^_LARGEFILE64_SOURCE$])
-m4trace:configure.in:97: -1- AH_OUTPUT([_LARGEFILE64_SOURCE], [/* Add the _LARGEFILE64_SOURCE flag when building */
-#undef _LARGEFILE64_SOURCE])
-m4trace:configure.in:97: -3- _m4_warn([obsolete], [The macro `AC_TRY_COMPILE' is obsolete.
-You should run autoupdate.], [/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:2368: AC_TRY_COMPILE is expanded from...
-tclconfig/tcl.m4:2652: TEA_TCL_EARLY_FLAG is expanded from...
-tclconfig/tcl.m4:2668: TEA_TCL_EARLY_FLAGS is expanded from...
-tclconfig/tcl.m4:2060: TEA_CONFIG_CFLAGS is expanded from...
-configure.in:97: the top level])
-m4trace:configure.in:97: -2- _m4_warn([obsolete], [The macro `AC_TRY_COMPILE' is obsolete.
-You should run autoupdate.], [/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:2368: AC_TRY_COMPILE is expanded from...
-tclconfig/tcl.m4:2652: TEA_TCL_EARLY_FLAG is expanded from...
-tclconfig/tcl.m4:2668: TEA_TCL_EARLY_FLAGS is expanded from...
-tclconfig/tcl.m4:2060: TEA_CONFIG_CFLAGS is expanded from...
-configure.in:97: the top level])
-m4trace:configure.in:97: -1- AC_DEFINE_TRACE_LITERAL([_LARGEFILE_SOURCE64])
-m4trace:configure.in:97: -1- m4_pattern_allow([^_LARGEFILE_SOURCE64$])
-m4trace:configure.in:97: -1- AH_OUTPUT([_LARGEFILE_SOURCE64], [/* Add the _LARGEFILE_SOURCE64 flag when building */
-#undef _LARGEFILE_SOURCE64])
-m4trace:configure.in:97: -1- _m4_warn([obsolete], [The macro `AC_TRY_COMPILE' is obsolete.
-You should run autoupdate.], [/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:2368: AC_TRY_COMPILE is expanded from...
-/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/m4sugar/m4sh.m4:523: AS_IF is expanded from...
-/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:1905: AC_CACHE_VAL is expanded from...
-tclconfig/tcl.m4:2749: TEA_TCL_64BIT_FLAGS is expanded from...
-tclconfig/tcl.m4:2060: TEA_CONFIG_CFLAGS is expanded from...
-configure.in:97: the top level])
-m4trace:configure.in:97: -1- _m4_warn([obsolete], [The macro `AC_TRY_COMPILE' is obsolete.
-You should run autoupdate.], [/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:2368: AC_TRY_COMPILE is expanded from...
-/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/m4sugar/m4sh.m4:523: AS_IF is expanded from...
-/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:1905: AC_CACHE_VAL is expanded from...
-tclconfig/tcl.m4:2749: TEA_TCL_64BIT_FLAGS is expanded from...
-tclconfig/tcl.m4:2060: TEA_CONFIG_CFLAGS is expanded from...
-configure.in:97: the top level])
-m4trace:configure.in:97: -1- AC_DEFINE_TRACE_LITERAL([TCL_WIDE_INT_IS_LONG])
-m4trace:configure.in:97: -1- m4_pattern_allow([^TCL_WIDE_INT_IS_LONG$])
-m4trace:configure.in:97: -1- AH_OUTPUT([TCL_WIDE_INT_IS_LONG], [/* Are wide integers to be implemented with C \'long\'s? */
-#undef TCL_WIDE_INT_IS_LONG])
-m4trace:configure.in:97: -1- AC_DEFINE_TRACE_LITERAL([TCL_WIDE_INT_TYPE])
-m4trace:configure.in:97: -1- m4_pattern_allow([^TCL_WIDE_INT_TYPE$])
-m4trace:configure.in:97: -1- AH_OUTPUT([TCL_WIDE_INT_TYPE], [/* What type should be used to define wide integers? */
-#undef TCL_WIDE_INT_TYPE])
-m4trace:configure.in:97: -1- _m4_warn([obsolete], [The macro `AC_TRY_COMPILE' is obsolete.
-You should run autoupdate.], [/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:2368: AC_TRY_COMPILE is expanded from...
-/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/m4sugar/m4sh.m4:523: AS_IF is expanded from...
-/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:1905: AC_CACHE_VAL is expanded from...
-/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:1918: AC_CACHE_CHECK is expanded from...
-tclconfig/tcl.m4:2749: TEA_TCL_64BIT_FLAGS is expanded from...
-tclconfig/tcl.m4:2060: TEA_CONFIG_CFLAGS is expanded from...
-configure.in:97: the top level])
-m4trace:configure.in:97: -1- AC_DEFINE_TRACE_LITERAL([HAVE_STRUCT_DIRENT64])
-m4trace:configure.in:97: -1- m4_pattern_allow([^HAVE_STRUCT_DIRENT64$])
-m4trace:configure.in:97: -1- AH_OUTPUT([HAVE_STRUCT_DIRENT64], [/* Is \'struct dirent64\' in <sys/types.h>? */
-#undef HAVE_STRUCT_DIRENT64])
-m4trace:configure.in:97: -1- _m4_warn([obsolete], [The macro `AC_TRY_COMPILE' is obsolete.
-You should run autoupdate.], [/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:2368: AC_TRY_COMPILE is expanded from...
-/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/m4sugar/m4sh.m4:523: AS_IF is expanded from...
-/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:1905: AC_CACHE_VAL is expanded from...
-/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:1918: AC_CACHE_CHECK is expanded from...
-tclconfig/tcl.m4:2749: TEA_TCL_64BIT_FLAGS is expanded from...
-tclconfig/tcl.m4:2060: TEA_CONFIG_CFLAGS is expanded from...
-configure.in:97: the top level])
-m4trace:configure.in:97: -1- AC_DEFINE_TRACE_LITERAL([HAVE_STRUCT_STAT64])
-m4trace:configure.in:97: -1- m4_pattern_allow([^HAVE_STRUCT_STAT64$])
-m4trace:configure.in:97: -1- AH_OUTPUT([HAVE_STRUCT_STAT64], [/* Is \'struct stat64\' in <sys/stat.h>? */
-#undef HAVE_STRUCT_STAT64])
-m4trace:configure.in:97: -1- AH_OUTPUT([HAVE_OPEN64], [/* Define to 1 if you have the `open64\' function. */
-#undef HAVE_OPEN64])
-m4trace:configure.in:97: -1- AH_OUTPUT([HAVE_LSEEK64], [/* Define to 1 if you have the `lseek64\' function. */
-#undef HAVE_LSEEK64])
-m4trace:configure.in:97: -1- _m4_warn([obsolete], [The macro `AC_TRY_COMPILE' is obsolete.
-You should run autoupdate.], [/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:2368: AC_TRY_COMPILE is expanded from...
-/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/m4sugar/m4sh.m4:523: AS_IF is expanded from...
-/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:1905: AC_CACHE_VAL is expanded from...
-tclconfig/tcl.m4:2749: TEA_TCL_64BIT_FLAGS is expanded from...
-tclconfig/tcl.m4:2060: TEA_CONFIG_CFLAGS is expanded from...
-configure.in:97: the top level])
-m4trace:configure.in:97: -1- AC_DEFINE_TRACE_LITERAL([HAVE_TYPE_OFF64_T])
-m4trace:configure.in:97: -1- m4_pattern_allow([^HAVE_TYPE_OFF64_T$])
-m4trace:configure.in:97: -1- AH_OUTPUT([HAVE_TYPE_OFF64_T], [/* Is off64_t in <sys/types.h>? */
-#undef HAVE_TYPE_OFF64_T])
-m4trace:configure.in:103: -2- _m4_warn([obsolete], [The macro `AC_HELP_STRING' is obsolete.
-You should run autoupdate.], [/var/tmp/autoconf/autoconf-14~76/SRC/autoconf/lib/autoconf/general.m4:209: AC_HELP_STRING is expanded from...
-tclconfig/tcl.m4:755: TEA_ENABLE_SYMBOLS is expanded from...
-configure.in:103: the top level])
-m4trace:configure.in:103: -1- AC_SUBST([TCL_DBGX])
-m4trace:configure.in:103: -1- AC_SUBST_TRACE([TCL_DBGX])
-m4trace:configure.in:103: -1- m4_pattern_allow([^TCL_DBGX$])
-m4trace:configure.in:103: -1- AC_SUBST([CFLAGS_DEFAULT])
-m4trace:configure.in:103: -1- AC_SUBST_TRACE([CFLAGS_DEFAULT])
-m4trace:configure.in:103: -1- m4_pattern_allow([^CFLAGS_DEFAULT$])
-m4trace:configure.in:103: -1- AC_SUBST([LDFLAGS_DEFAULT])
-m4trace:configure.in:103: -1- AC_SUBST_TRACE([LDFLAGS_DEFAULT])
-m4trace:configure.in:103: -1- m4_pattern_allow([^LDFLAGS_DEFAULT$])
-m4trace:configure.in:103: -1- AC_DEFINE_TRACE_LITERAL([TCL_MEM_DEBUG])
-m4trace:configure.in:103: -1- m4_pattern_allow([^TCL_MEM_DEBUG$])
-m4trace:configure.in:103: -1- AH_OUTPUT([TCL_MEM_DEBUG], [/* Is memory debugging enabled? */
-#undef TCL_MEM_DEBUG])
-m4trace:configure.in:112: -1- AC_DEFINE_TRACE_LITERAL([USE_TCL_STUBS])
-m4trace:configure.in:112: -1- m4_pattern_allow([^USE_TCL_STUBS$])
-m4trace:configure.in:112: -1- AH_OUTPUT([USE_TCL_STUBS], [/* Use Tcl stubs */
-#undef USE_TCL_STUBS])
-m4trace:configure.in:120: -1- AC_SUBST([MAKE_LIB])
-m4trace:configure.in:120: -1- AC_SUBST_TRACE([MAKE_LIB])
-m4trace:configure.in:120: -1- m4_pattern_allow([^MAKE_LIB$])
-m4trace:configure.in:120: -1- AC_SUBST([MAKE_SHARED_LIB])
-m4trace:configure.in:120: -1- AC_SUBST_TRACE([MAKE_SHARED_LIB])
-m4trace:configure.in:120: -1- m4_pattern_allow([^MAKE_SHARED_LIB$])
-m4trace:configure.in:120: -1- AC_SUBST([MAKE_STATIC_LIB])
-m4trace:configure.in:120: -1- AC_SUBST_TRACE([MAKE_STATIC_LIB])
-m4trace:configure.in:120: -1- m4_pattern_allow([^MAKE_STATIC_LIB$])
-m4trace:configure.in:120: -1- AC_SUBST([MAKE_STUB_LIB])
-m4trace:configure.in:120: -1- AC_SUBST_TRACE([MAKE_STUB_LIB])
-m4trace:configure.in:120: -1- m4_pattern_allow([^MAKE_STUB_LIB$])
-m4trace:configure.in:120: -1- AC_SUBST([RANLIB_STUB])
-m4trace:configure.in:120: -1- AC_SUBST_TRACE([RANLIB_STUB])
-m4trace:configure.in:120: -1- m4_pattern_allow([^RANLIB_STUB$])
-m4trace:configure.in:166: -1- AC_SUBST([XML2_PREFIX])
-m4trace:configure.in:166: -1- AC_SUBST_TRACE([XML2_PREFIX])
-m4trace:configure.in:166: -1- m4_pattern_allow([^XML2_PREFIX$])
-m4trace:configure.in:167: -1- AC_SUBST([XML2_CFLAGS])
-m4trace:configure.in:167: -1- AC_SUBST_TRACE([XML2_CFLAGS])
-m4trace:configure.in:167: -1- m4_pattern_allow([^XML2_CFLAGS$])
-m4trace:configure.in:168: -1- AC_SUBST([XML2_VERSION])
-m4trace:configure.in:168: -1- AC_SUBST_TRACE([XML2_VERSION])
-m4trace:configure.in:168: -1- m4_pattern_allow([^XML2_VERSION$])
-m4trace:configure.in:215: -1- AC_SUBST([XSLT_VERSION])
-m4trace:configure.in:215: -1- AC_SUBST_TRACE([XSLT_VERSION])
-m4trace:configure.in:215: -1- m4_pattern_allow([^XSLT_VERSION$])
-m4trace:configure.in:216: -1- AC_SUBST([XSLT_PREFIX])
-m4trace:configure.in:216: -1- AC_SUBST_TRACE([XSLT_PREFIX])
-m4trace:configure.in:216: -1- m4_pattern_allow([^XSLT_PREFIX$])
-m4trace:configure.in:217: -1- AC_SUBST([XSLT_CFLAGS])
-m4trace:configure.in:217: -1- AC_SUBST_TRACE([XSLT_CFLAGS])
-m4trace:configure.in:217: -1- m4_pattern_allow([^XSLT_CFLAGS$])
-m4trace:configure.in:238: -1- AC_SUBST([XML_STATIC])
-m4trace:configure.in:238: -1- AC_SUBST_TRACE([XML_STATIC])
-m4trace:configure.in:238: -1- m4_pattern_allow([^XML_STATIC$])
-m4trace:configure.in:267: -1- AC_SUBST([XML2_LIBS])
-m4trace:configure.in:267: -1- AC_SUBST_TRACE([XML2_LIBS])
-m4trace:configure.in:267: -1- m4_pattern_allow([^XML2_LIBS$])
-m4trace:configure.in:268: -1- AC_SUBST([XSLT_LIBS])
-m4trace:configure.in:268: -1- AC_SUBST_TRACE([XSLT_LIBS])
-m4trace:configure.in:268: -1- m4_pattern_allow([^XSLT_LIBS$])
-m4trace:configure.in:269: -1- AC_SUBST([FIX_LIB])
-m4trace:configure.in:269: -1- AC_SUBST_TRACE([FIX_LIB])
-m4trace:configure.in:269: -1- m4_pattern_allow([^FIX_LIB$])
-m4trace:configure.in:280: -1- AC_SUBST([TCLSH_PROG])
-m4trace:configure.in:280: -1- AC_SUBST_TRACE([TCLSH_PROG])
-m4trace:configure.in:280: -1- m4_pattern_allow([^TCLSH_PROG$])
-m4trace:configure.in:308: -1- AC_SUBST([Tclxml_BUILD_LIB_SPEC])
-m4trace:configure.in:308: -1- AC_SUBST_TRACE([Tclxml_BUILD_LIB_SPEC])
-m4trace:configure.in:308: -1- m4_pattern_allow([^Tclxml_BUILD_LIB_SPEC$])
-m4trace:configure.in:309: -1- AC_SUBST([Tclxml_LIB_SPEC])
-m4trace:configure.in:309: -1- AC_SUBST_TRACE([Tclxml_LIB_SPEC])
-m4trace:configure.in:309: -1- m4_pattern_allow([^Tclxml_LIB_SPEC$])
-m4trace:configure.in:310: -1- AC_SUBST([Tclxml_BUILD_STUB_LIB_SPEC])
-m4trace:configure.in:310: -1- AC_SUBST_TRACE([Tclxml_BUILD_STUB_LIB_SPEC])
-m4trace:configure.in:310: -1- m4_pattern_allow([^Tclxml_BUILD_STUB_LIB_SPEC$])
-m4trace:configure.in:311: -1- AC_SUBST([Tclxml_STUB_LIB_SPEC])
-m4trace:configure.in:311: -1- AC_SUBST_TRACE([Tclxml_STUB_LIB_SPEC])
-m4trace:configure.in:311: -1- m4_pattern_allow([^Tclxml_STUB_LIB_SPEC$])
-m4trace:configure.in:312: -1- AC_SUBST([Tclxml_BUILD_STUB_LIB_PATH])
-m4trace:configure.in:312: -1- AC_SUBST_TRACE([Tclxml_BUILD_STUB_LIB_PATH])
-m4trace:configure.in:312: -1- m4_pattern_allow([^Tclxml_BUILD_STUB_LIB_PATH$])
-m4trace:configure.in:313: -1- AC_SUBST([Tclxml_STUB_LIB_PATH])
-m4trace:configure.in:313: -1- AC_SUBST_TRACE([Tclxml_STUB_LIB_PATH])
-m4trace:configure.in:313: -1- m4_pattern_allow([^Tclxml_STUB_LIB_PATH$])
-m4trace:configure.in:314: -1- AC_SUBST([Tclxml_INCLUDE_SPEC])
-m4trace:configure.in:314: -1- AC_SUBST_TRACE([Tclxml_INCLUDE_SPEC])
-m4trace:configure.in:314: -1- m4_pattern_allow([^Tclxml_INCLUDE_SPEC$])
-m4trace:configure.in:321: -1- AC_SUBST([XSLTPROC])
-m4trace:configure.in:321: -1- AC_SUBST_TRACE([XSLTPROC])
-m4trace:configure.in:321: -1- m4_pattern_allow([^XSLTPROC$])
-m4trace:configure.in:329: -1- AC_CONFIG_FILES([Makefile Makefile.macosx pkgIndex.tcl TclxmlConfig.sh include/tclxml/tclxml.h doc/tclxml.xml doc/tcldom.xml doc/tclxslt.xml doc/README.xml])
-m4trace:configure.in:329: -1- _m4_warn([obsolete], [AC_OUTPUT should be used without arguments.
-You should run autoupdate.], [])
-m4trace:configure.in:329: -1- AC_SUBST([LIB@&t at OBJS], [$ac_libobjs])
-m4trace:configure.in:329: -1- AC_SUBST_TRACE([LIB@&t at OBJS])
-m4trace:configure.in:329: -1- m4_pattern_allow([^LIB@&t at OBJS$])
-m4trace:configure.in:329: -1- AC_SUBST([LTLIBOBJS], [$ac_ltlibobjs])
-m4trace:configure.in:329: -1- AC_SUBST_TRACE([LTLIBOBJS])
-m4trace:configure.in:329: -1- m4_pattern_allow([^LTLIBOBJS$])
-m4trace:configure.in:329: -1- AC_SUBST_TRACE([top_builddir])
-m4trace:configure.in:329: -1- AC_SUBST_TRACE([srcdir])
-m4trace:configure.in:329: -1- AC_SUBST_TRACE([abs_srcdir])
-m4trace:configure.in:329: -1- AC_SUBST_TRACE([top_srcdir])
-m4trace:configure.in:329: -1- AC_SUBST_TRACE([abs_top_srcdir])
-m4trace:configure.in:329: -1- AC_SUBST_TRACE([builddir])
-m4trace:configure.in:329: -1- AC_SUBST_TRACE([abs_builddir])
-m4trace:configure.in:329: -1- AC_SUBST_TRACE([abs_top_builddir])
-m4trace:configure.in:329: -1- AC_SUBST_TRACE([INSTALL])
diff --git a/tclxml-3.2/configure b/tclxml-3.2/configure
deleted file mode 100755
index adcea87..0000000
--- a/tclxml-3.2/configure
+++ /dev/null
@@ -1,11566 +0,0 @@
-#! /bin/sh
-# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.61 for Tclxml 3.2.
-#
-# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
-# 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
-# This configure script is free software; the Free Software Foundation
-# gives unlimited permission to copy, distribute and modify it.
-## --------------------- ##
-## M4sh Initialization.  ##
-## --------------------- ##
-
-# Be more Bourne compatible
-DUALCASE=1; export DUALCASE # for MKS sh
-if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
-  emulate sh
-  NULLCMD=:
-  # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
-  # is contrary to our usage.  Disable this feature.
-  alias -g '${1+"$@"}'='"$@"'
-  setopt NO_GLOB_SUBST
-else
-  case `(set -o) 2>/dev/null` in
-  *posix*) set -o posix ;;
-esac
-
-fi
-
-
-
-
-# PATH needs CR
-# Avoid depending upon Character Ranges.
-as_cr_letters='abcdefghijklmnopqrstuvwxyz'
-as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
-as_cr_Letters=$as_cr_letters$as_cr_LETTERS
-as_cr_digits='0123456789'
-as_cr_alnum=$as_cr_Letters$as_cr_digits
-
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
-  echo "#! /bin/sh" >conf$$.sh
-  echo  "exit 0"   >>conf$$.sh
-  chmod +x conf$$.sh
-  if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
-    PATH_SEPARATOR=';'
-  else
-    PATH_SEPARATOR=:
-  fi
-  rm -f conf$$.sh
-fi
-
-# Support unset when possible.
-if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
-  as_unset=unset
-else
-  as_unset=false
-fi
-
-
-# IFS
-# We need space, tab and new line, in precisely that order.  Quoting is
-# there to prevent editors from complaining about space-tab.
-# (If _AS_PATH_WALK were called with IFS unset, it would disable word
-# splitting by setting IFS to empty value.)
-as_nl='
-'
-IFS=" ""	$as_nl"
-
-# Find who we are.  Look in the path if we contain no directory separator.
-case $0 in
-  *[\\/]* ) as_myself=$0 ;;
-  *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
-done
-IFS=$as_save_IFS
-
-     ;;
-esac
-# We did not find ourselves, most probably we were run as `sh COMMAND'
-# in which case we are not to be found in the path.
-if test "x$as_myself" = x; then
-  as_myself=$0
-fi
-if test ! -f "$as_myself"; then
-  echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
-  { (exit 1); exit 1; }
-fi
-
-# Work around bugs in pre-3.0 UWIN ksh.
-for as_var in ENV MAIL MAILPATH
-do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
-done
-PS1='$ '
-PS2='> '
-PS4='+ '
-
-# NLS nuisances.
-for as_var in \
-  LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
-  LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
-  LC_TELEPHONE LC_TIME
-do
-  if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
-    eval $as_var=C; export $as_var
-  else
-    ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
-  fi
-done
-
-# Required to use basename.
-if expr a : '\(a\)' >/dev/null 2>&1 &&
-   test "X`expr 00001 : '.*\(...\)'`" = X001; then
-  as_expr=expr
-else
-  as_expr=false
-fi
-
-if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
-  as_basename=basename
-else
-  as_basename=false
-fi
-
-
-# Name of the executable.
-as_me=`$as_basename -- "$0" ||
-$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
-	 X"$0" : 'X\(//\)$' \| \
-	 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
-echo X/"$0" |
-    sed '/^.*\/\([^/][^/]*\)\/*$/{
-	    s//\1/
-	    q
-	  }
-	  /^X\/\(\/\/\)$/{
-	    s//\1/
-	    q
-	  }
-	  /^X\/\(\/\).*/{
-	    s//\1/
-	    q
-	  }
-	  s/.*/./; q'`
-
-# CDPATH.
-$as_unset CDPATH
-
-
-if test "x$CONFIG_SHELL" = x; then
-  if (eval ":") 2>/dev/null; then
-  as_have_required=yes
-else
-  as_have_required=no
-fi
-
-  if test $as_have_required = yes && 	 (eval ":
-(as_func_return () {
-  (exit \$1)
-}
-as_func_success () {
-  as_func_return 0
-}
-as_func_failure () {
-  as_func_return 1
-}
-as_func_ret_success () {
-  return 0
-}
-as_func_ret_failure () {
-  return 1
-}
-
-exitcode=0
-if as_func_success; then
-  :
-else
-  exitcode=1
-  echo as_func_success failed.
-fi
-
-if as_func_failure; then
-  exitcode=1
-  echo as_func_failure succeeded.
-fi
-
-if as_func_ret_success; then
-  :
-else
-  exitcode=1
-  echo as_func_ret_success failed.
-fi
-
-if as_func_ret_failure; then
-  exitcode=1
-  echo as_func_ret_failure succeeded.
-fi
-
-if ( set x; as_func_ret_success y && test x = \"\$1\" ); then
-  :
-else
-  exitcode=1
-  echo positional parameters were not saved.
-fi
-
-test \$exitcode = 0) || { (exit 1); exit 1; }
-
-(
-  as_lineno_1=\$LINENO
-  as_lineno_2=\$LINENO
-  test \"x\$as_lineno_1\" != \"x\$as_lineno_2\" &&
-  test \"x\`expr \$as_lineno_1 + 1\`\" = \"x\$as_lineno_2\") || { (exit 1); exit 1; }
-") 2> /dev/null; then
-  :
-else
-  as_candidate_shells=
-    as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  case $as_dir in
-	 /*)
-	   for as_base in sh bash ksh sh5; do
-	     as_candidate_shells="$as_candidate_shells $as_dir/$as_base"
-	   done;;
-       esac
-done
-IFS=$as_save_IFS
-
-
-      for as_shell in $as_candidate_shells $SHELL; do
-	 # Try only shells that exist, to save several forks.
-	 if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
-		{ ("$as_shell") 2> /dev/null <<\_ASEOF
-if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
-  emulate sh
-  NULLCMD=:
-  # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
-  # is contrary to our usage.  Disable this feature.
-  alias -g '${1+"$@"}'='"$@"'
-  setopt NO_GLOB_SUBST
-else
-  case `(set -o) 2>/dev/null` in
-  *posix*) set -o posix ;;
-esac
-
-fi
-
-
-:
-_ASEOF
-}; then
-  CONFIG_SHELL=$as_shell
-	       as_have_required=yes
-	       if { "$as_shell" 2> /dev/null <<\_ASEOF
-if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
-  emulate sh
-  NULLCMD=:
-  # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
-  # is contrary to our usage.  Disable this feature.
-  alias -g '${1+"$@"}'='"$@"'
-  setopt NO_GLOB_SUBST
-else
-  case `(set -o) 2>/dev/null` in
-  *posix*) set -o posix ;;
-esac
-
-fi
-
-
-:
-(as_func_return () {
-  (exit $1)
-}
-as_func_success () {
-  as_func_return 0
-}
-as_func_failure () {
-  as_func_return 1
-}
-as_func_ret_success () {
-  return 0
-}
-as_func_ret_failure () {
-  return 1
-}
-
-exitcode=0
-if as_func_success; then
-  :
-else
-  exitcode=1
-  echo as_func_success failed.
-fi
-
-if as_func_failure; then
-  exitcode=1
-  echo as_func_failure succeeded.
-fi
-
-if as_func_ret_success; then
-  :
-else
-  exitcode=1
-  echo as_func_ret_success failed.
-fi
-
-if as_func_ret_failure; then
-  exitcode=1
-  echo as_func_ret_failure succeeded.
-fi
-
-if ( set x; as_func_ret_success y && test x = "$1" ); then
-  :
-else
-  exitcode=1
-  echo positional parameters were not saved.
-fi
-
-test $exitcode = 0) || { (exit 1); exit 1; }
-
-(
-  as_lineno_1=$LINENO
-  as_lineno_2=$LINENO
-  test "x$as_lineno_1" != "x$as_lineno_2" &&
-  test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2") || { (exit 1); exit 1; }
-
-_ASEOF
-}; then
-  break
-fi
-
-fi
-
-      done
-
-      if test "x$CONFIG_SHELL" != x; then
-  for as_var in BASH_ENV ENV
-        do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
-        done
-        export CONFIG_SHELL
-        exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"}
-fi
-
-
-    if test $as_have_required = no; then
-  echo This script requires a shell more modern than all the
-      echo shells that I found on your system.  Please install a
-      echo modern shell, or manually run the script under such a
-      echo shell if you do have one.
-      { (exit 1); exit 1; }
-fi
-
-
-fi
-
-fi
-
-
-
-(eval "as_func_return () {
-  (exit \$1)
-}
-as_func_success () {
-  as_func_return 0
-}
-as_func_failure () {
-  as_func_return 1
-}
-as_func_ret_success () {
-  return 0
-}
-as_func_ret_failure () {
-  return 1
-}
-
-exitcode=0
-if as_func_success; then
-  :
-else
-  exitcode=1
-  echo as_func_success failed.
-fi
-
-if as_func_failure; then
-  exitcode=1
-  echo as_func_failure succeeded.
-fi
-
-if as_func_ret_success; then
-  :
-else
-  exitcode=1
-  echo as_func_ret_success failed.
-fi
-
-if as_func_ret_failure; then
-  exitcode=1
-  echo as_func_ret_failure succeeded.
-fi
-
-if ( set x; as_func_ret_success y && test x = \"\$1\" ); then
-  :
-else
-  exitcode=1
-  echo positional parameters were not saved.
-fi
-
-test \$exitcode = 0") || {
-  echo No shell found that supports shell functions.
-  echo Please tell autoconf at gnu.org about your system,
-  echo including any error possibly output before this
-  echo message
-}
-
-
-
-  as_lineno_1=$LINENO
-  as_lineno_2=$LINENO
-  test "x$as_lineno_1" != "x$as_lineno_2" &&
-  test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || {
-
-  # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
-  # uniformly replaced by the line number.  The first 'sed' inserts a
-  # line-number line after each line using $LINENO; the second 'sed'
-  # does the real work.  The second script uses 'N' to pair each
-  # line-number line with the line containing $LINENO, and appends
-  # trailing '-' during substitution so that $LINENO is not a special
-  # case at line end.
-  # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
-  # scripts with optimization help from Paolo Bonzini.  Blame Lee
-  # E. McMahon (1931-1989) for sed's syntax.  :-)
-  sed -n '
-    p
-    /[$]LINENO/=
-  ' <$as_myself |
-    sed '
-      s/[$]LINENO.*/&-/
-      t lineno
-      b
-      :lineno
-      N
-      :loop
-      s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
-      t loop
-      s/-\n.*//
-    ' >$as_me.lineno &&
-  chmod +x "$as_me.lineno" ||
-    { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
-   { (exit 1); exit 1; }; }
-
-  # Don't try to exec as it changes $[0], causing all sort of problems
-  # (the dirname of $[0] is not the place where we might find the
-  # original and so on.  Autoconf is especially sensitive to this).
-  . "./$as_me.lineno"
-  # Exit status is that of the last command.
-  exit
-}
-
-
-if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
-  as_dirname=dirname
-else
-  as_dirname=false
-fi
-
-ECHO_C= ECHO_N= ECHO_T=
-case `echo -n x` in
--n*)
-  case `echo 'x\c'` in
-  *c*) ECHO_T='	';;	# ECHO_T is single tab character.
-  *)   ECHO_C='\c';;
-  esac;;
-*)
-  ECHO_N='-n';;
-esac
-
-if expr a : '\(a\)' >/dev/null 2>&1 &&
-   test "X`expr 00001 : '.*\(...\)'`" = X001; then
-  as_expr=expr
-else
-  as_expr=false
-fi
-
-rm -f conf$$ conf$$.exe conf$$.file
-if test -d conf$$.dir; then
-  rm -f conf$$.dir/conf$$.file
-else
-  rm -f conf$$.dir
-  mkdir conf$$.dir
-fi
-echo >conf$$.file
-if ln -s conf$$.file conf$$ 2>/dev/null; then
-  as_ln_s='ln -s'
-  # ... but there are two gotchas:
-  # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
-  # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
-  # In both cases, we have to default to `cp -p'.
-  ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
-    as_ln_s='cp -p'
-elif ln conf$$.file conf$$ 2>/dev/null; then
-  as_ln_s=ln
-else
-  as_ln_s='cp -p'
-fi
-rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
-rmdir conf$$.dir 2>/dev/null
-
-if mkdir -p . 2>/dev/null; then
-  as_mkdir_p=:
-else
-  test -d ./-p && rmdir ./-p
-  as_mkdir_p=false
-fi
-
-if test -x / >/dev/null 2>&1; then
-  as_test_x='test -x'
-else
-  if ls -dL / >/dev/null 2>&1; then
-    as_ls_L_option=L
-  else
-    as_ls_L_option=
-  fi
-  as_test_x='
-    eval sh -c '\''
-      if test -d "$1"; then
-        test -d "$1/.";
-      else
-	case $1 in
-        -*)set "./$1";;
-	esac;
-	case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in
-	???[sx]*):;;*)false;;esac;fi
-    '\'' sh
-  '
-fi
-as_executable_p=$as_test_x
-
-# Sed expression to map a string onto a valid CPP name.
-as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
-
-# Sed expression to map a string onto a valid variable name.
-as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
-
-
-
-exec 7<&0 </dev/null 6>&1
-
-# Name of the host.
-# hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
-# so uname gets run too.
-ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
-
-#
-# Initializations.
-#
-ac_default_prefix=/usr/local
-ac_clean_files=
-ac_config_libobj_dir=.
-LIBOBJS=
-cross_compiling=no
-subdirs=
-MFLAGS=
-MAKEFLAGS=
-SHELL=${CONFIG_SHELL-/bin/sh}
-
-# Identity of this package.
-PACKAGE_NAME='Tclxml'
-PACKAGE_TARNAME='tclxml'
-PACKAGE_VERSION='3.2'
-PACKAGE_STRING='Tclxml 3.2'
-PACKAGE_BUGREPORT=''
-
-# Factoring default headers for most tests.
-ac_includes_default="\
-#include <stdio.h>
-#ifdef HAVE_SYS_TYPES_H
-# include <sys/types.h>
-#endif
-#ifdef HAVE_SYS_STAT_H
-# include <sys/stat.h>
-#endif
-#ifdef STDC_HEADERS
-# include <stdlib.h>
-# include <stddef.h>
-#else
-# ifdef HAVE_STDLIB_H
-#  include <stdlib.h>
-# endif
-#endif
-#ifdef HAVE_STRING_H
-# if !defined STDC_HEADERS && defined HAVE_MEMORY_H
-#  include <memory.h>
-# endif
-# include <string.h>
-#endif
-#ifdef HAVE_STRINGS_H
-# include <strings.h>
-#endif
-#ifdef HAVE_INTTYPES_H
-# include <inttypes.h>
-#endif
-#ifdef HAVE_STDINT_H
-# include <stdint.h>
-#endif
-#ifdef HAVE_UNISTD_H
-# include <unistd.h>
-#endif"
-
-ac_subst_vars='SHELL
-PATH_SEPARATOR
-PACKAGE_NAME
-PACKAGE_TARNAME
-PACKAGE_VERSION
-PACKAGE_STRING
-PACKAGE_BUGREPORT
-exec_prefix
-prefix
-program_transform_name
-bindir
-sbindir
-libexecdir
-datarootdir
-datadir
-sysconfdir
-sharedstatedir
-localstatedir
-includedir
-oldincludedir
-docdir
-infodir
-htmldir
-dvidir
-pdfdir
-psdir
-libdir
-localedir
-mandir
-DEFS
-ECHO_C
-ECHO_N
-ECHO_T
-LIBS
-build_alias
-host_alias
-target_alias
-CYGPATH
-EXEEXT
-PKG_LIB_FILE
-PKG_STUB_LIB_FILE
-PKG_STUB_SOURCES
-PKG_STUB_OBJECTS
-PKG_TCL_SOURCES
-PKG_HEADERS
-PKG_INCLUDES
-PKG_LIBS
-PKG_CFLAGS
-TCL_VERSION
-TCL_BIN_DIR
-TCL_SRC_DIR
-TCL_LIB_FILE
-TCL_LIB_FLAG
-TCL_LIB_SPEC
-TCL_STUB_LIB_FILE
-TCL_STUB_LIB_FLAG
-TCL_STUB_LIB_SPEC
-TCL_LIBS
-TCL_DEFS
-TCL_EXTRA_CFLAGS
-TCL_LD_FLAGS
-TCL_SHLIB_LD_LIBS
-CC
-CFLAGS
-LDFLAGS
-CPPFLAGS
-ac_ct_CC
-OBJEXT
-CPP
-INSTALL_PROGRAM
-INSTALL_SCRIPT
-INSTALL_DATA
-SET_MAKE
-RANLIB
-GREP
-EGREP
-MATH_LIBS
-PKG_SOURCES
-PKG_OBJECTS
-CLEANFILES
-TCL_INCLUDES
-TCL_THREADS
-SHARED_BUILD
-AR
-CELIB_DIR
-LIBOBJS
-DL_LIBS
-CFLAGS_DEBUG
-CFLAGS_OPTIMIZE
-CFLAGS_WARNING
-STLIB_LD
-SHLIB_LD
-SHLIB_LD_LIBS
-SHLIB_CFLAGS
-LD_LIBRARY_PATH_VAR
-TCL_DBGX
-CFLAGS_DEFAULT
-LDFLAGS_DEFAULT
-MAKE_LIB
-MAKE_SHARED_LIB
-MAKE_STATIC_LIB
-MAKE_STUB_LIB
-RANLIB_STUB
-XML2_PREFIX
-XML2_CFLAGS
-XML2_VERSION
-XSLT_VERSION
-XSLT_PREFIX
-XSLT_CFLAGS
-XML_STATIC
-XML2_LIBS
-XSLT_LIBS
-FIX_LIB
-TCLSH_PROG
-Tclxml_BUILD_LIB_SPEC
-Tclxml_LIB_SPEC
-Tclxml_BUILD_STUB_LIB_SPEC
-Tclxml_STUB_LIB_SPEC
-Tclxml_BUILD_STUB_LIB_PATH
-Tclxml_STUB_LIB_PATH
-Tclxml_INCLUDE_SPEC
-XSLTPROC
-LTLIBOBJS'
-ac_subst_files=''
-      ac_precious_vars='build_alias
-host_alias
-target_alias
-CC
-CFLAGS
-LDFLAGS
-LIBS
-CPPFLAGS
-CPP'
-
-
-# Initialize some variables set by options.
-ac_init_help=
-ac_init_version=false
-# The variables have the same names as the options, with
-# dashes changed to underlines.
-cache_file=/dev/null
-exec_prefix=NONE
-no_create=
-no_recursion=
-prefix=NONE
-program_prefix=NONE
-program_suffix=NONE
-program_transform_name=s,x,x,
-silent=
-site=
-srcdir=
-verbose=
-x_includes=NONE
-x_libraries=NONE
-
-# Installation directory options.
-# These are left unexpanded so users can "make install exec_prefix=/foo"
-# and all the variables that are supposed to be based on exec_prefix
-# by default will actually change.
-# Use braces instead of parens because sh, perl, etc. also accept them.
-# (The list follows the same order as the GNU Coding Standards.)
-bindir='${exec_prefix}/bin'
-sbindir='${exec_prefix}/sbin'
-libexecdir='${exec_prefix}/libexec'
-datarootdir='${prefix}/share'
-datadir='${datarootdir}'
-sysconfdir='${prefix}/etc'
-sharedstatedir='${prefix}/com'
-localstatedir='${prefix}/var'
-includedir='${prefix}/include'
-oldincludedir='/usr/include'
-docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
-infodir='${datarootdir}/info'
-htmldir='${docdir}'
-dvidir='${docdir}'
-pdfdir='${docdir}'
-psdir='${docdir}'
-libdir='${exec_prefix}/lib'
-localedir='${datarootdir}/locale'
-mandir='${datarootdir}/man'
-
-ac_prev=
-ac_dashdash=
-for ac_option
-do
-  # If the previous option needs an argument, assign it.
-  if test -n "$ac_prev"; then
-    eval $ac_prev=\$ac_option
-    ac_prev=
-    continue
-  fi
-
-  case $ac_option in
-  *=*)	ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
-  *)	ac_optarg=yes ;;
-  esac
-
-  # Accept the important Cygnus configure options, so we can diagnose typos.
-
-  case $ac_dashdash$ac_option in
-  --)
-    ac_dashdash=yes ;;
-
-  -bindir | --bindir | --bindi | --bind | --bin | --bi)
-    ac_prev=bindir ;;
-  -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
-    bindir=$ac_optarg ;;
-
-  -build | --build | --buil | --bui | --bu)
-    ac_prev=build_alias ;;
-  -build=* | --build=* | --buil=* | --bui=* | --bu=*)
-    build_alias=$ac_optarg ;;
-
-  -cache-file | --cache-file | --cache-fil | --cache-fi \
-  | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
-    ac_prev=cache_file ;;
-  -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
-  | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
-    cache_file=$ac_optarg ;;
-
-  --config-cache | -C)
-    cache_file=config.cache ;;
-
-  -datadir | --datadir | --datadi | --datad)
-    ac_prev=datadir ;;
-  -datadir=* | --datadir=* | --datadi=* | --datad=*)
-    datadir=$ac_optarg ;;
-
-  -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
-  | --dataroo | --dataro | --datar)
-    ac_prev=datarootdir ;;
-  -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
-  | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
-    datarootdir=$ac_optarg ;;
-
-  -disable-* | --disable-*)
-    ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
-    # Reject names that are not valid shell variable names.
-    expr "x$ac_feature" : ".*[^-._$as_cr_alnum]" >/dev/null &&
-      { echo "$as_me: error: invalid feature name: $ac_feature" >&2
-   { (exit 1); exit 1; }; }
-    ac_feature=`echo $ac_feature | sed 's/[-.]/_/g'`
-    eval enable_$ac_feature=no ;;
-
-  -docdir | --docdir | --docdi | --doc | --do)
-    ac_prev=docdir ;;
-  -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
-    docdir=$ac_optarg ;;
-
-  -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
-    ac_prev=dvidir ;;
-  -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
-    dvidir=$ac_optarg ;;
-
-  -enable-* | --enable-*)
-    ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
-    # Reject names that are not valid shell variable names.
-    expr "x$ac_feature" : ".*[^-._$as_cr_alnum]" >/dev/null &&
-      { echo "$as_me: error: invalid feature name: $ac_feature" >&2
-   { (exit 1); exit 1; }; }
-    ac_feature=`echo $ac_feature | sed 's/[-.]/_/g'`
-    eval enable_$ac_feature=\$ac_optarg ;;
-
-  -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
-  | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
-  | --exec | --exe | --ex)
-    ac_prev=exec_prefix ;;
-  -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
-  | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
-  | --exec=* | --exe=* | --ex=*)
-    exec_prefix=$ac_optarg ;;
-
-  -gas | --gas | --ga | --g)
-    # Obsolete; use --with-gas.
-    with_gas=yes ;;
-
-  -help | --help | --hel | --he | -h)
-    ac_init_help=long ;;
-  -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
-    ac_init_help=recursive ;;
-  -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
-    ac_init_help=short ;;
-
-  -host | --host | --hos | --ho)
-    ac_prev=host_alias ;;
-  -host=* | --host=* | --hos=* | --ho=*)
-    host_alias=$ac_optarg ;;
-
-  -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
-    ac_prev=htmldir ;;
-  -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
-  | --ht=*)
-    htmldir=$ac_optarg ;;
-
-  -includedir | --includedir | --includedi | --included | --include \
-  | --includ | --inclu | --incl | --inc)
-    ac_prev=includedir ;;
-  -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
-  | --includ=* | --inclu=* | --incl=* | --inc=*)
-    includedir=$ac_optarg ;;
-
-  -infodir | --infodir | --infodi | --infod | --info | --inf)
-    ac_prev=infodir ;;
-  -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
-    infodir=$ac_optarg ;;
-
-  -libdir | --libdir | --libdi | --libd)
-    ac_prev=libdir ;;
-  -libdir=* | --libdir=* | --libdi=* | --libd=*)
-    libdir=$ac_optarg ;;
-
-  -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
-  | --libexe | --libex | --libe)
-    ac_prev=libexecdir ;;
-  -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
-  | --libexe=* | --libex=* | --libe=*)
-    libexecdir=$ac_optarg ;;
-
-  -localedir | --localedir | --localedi | --localed | --locale)
-    ac_prev=localedir ;;
-  -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
-    localedir=$ac_optarg ;;
-
-  -localstatedir | --localstatedir | --localstatedi | --localstated \
-  | --localstate | --localstat | --localsta | --localst | --locals)
-    ac_prev=localstatedir ;;
-  -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
-  | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
-    localstatedir=$ac_optarg ;;
-
-  -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
-    ac_prev=mandir ;;
-  -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
-    mandir=$ac_optarg ;;
-
-  -nfp | --nfp | --nf)
-    # Obsolete; use --without-fp.
-    with_fp=no ;;
-
-  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
-  | --no-cr | --no-c | -n)
-    no_create=yes ;;
-
-  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
-  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
-    no_recursion=yes ;;
-
-  -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
-  | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
-  | --oldin | --oldi | --old | --ol | --o)
-    ac_prev=oldincludedir ;;
-  -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
-  | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
-  | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
-    oldincludedir=$ac_optarg ;;
-
-  -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
-    ac_prev=prefix ;;
-  -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
-    prefix=$ac_optarg ;;
-
-  -program-prefix | --program-prefix | --program-prefi | --program-pref \
-  | --program-pre | --program-pr | --program-p)
-    ac_prev=program_prefix ;;
-  -program-prefix=* | --program-prefix=* | --program-prefi=* \
-  | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
-    program_prefix=$ac_optarg ;;
-
-  -program-suffix | --program-suffix | --program-suffi | --program-suff \
-  | --program-suf | --program-su | --program-s)
-    ac_prev=program_suffix ;;
-  -program-suffix=* | --program-suffix=* | --program-suffi=* \
-  | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
-    program_suffix=$ac_optarg ;;
-
-  -program-transform-name | --program-transform-name \
-  | --program-transform-nam | --program-transform-na \
-  | --program-transform-n | --program-transform- \
-  | --program-transform | --program-transfor \
-  | --program-transfo | --program-transf \
-  | --program-trans | --program-tran \
-  | --progr-tra | --program-tr | --program-t)
-    ac_prev=program_transform_name ;;
-  -program-transform-name=* | --program-transform-name=* \
-  | --program-transform-nam=* | --program-transform-na=* \
-  | --program-transform-n=* | --program-transform-=* \
-  | --program-transform=* | --program-transfor=* \
-  | --program-transfo=* | --program-transf=* \
-  | --program-trans=* | --program-tran=* \
-  | --progr-tra=* | --program-tr=* | --program-t=*)
-    program_transform_name=$ac_optarg ;;
-
-  -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
-    ac_prev=pdfdir ;;
-  -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
-    pdfdir=$ac_optarg ;;
-
-  -psdir | --psdir | --psdi | --psd | --ps)
-    ac_prev=psdir ;;
-  -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
-    psdir=$ac_optarg ;;
-
-  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
-  | -silent | --silent | --silen | --sile | --sil)
-    silent=yes ;;
-
-  -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
-    ac_prev=sbindir ;;
-  -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
-  | --sbi=* | --sb=*)
-    sbindir=$ac_optarg ;;
-
-  -sharedstatedir | --sharedstatedir | --sharedstatedi \
-  | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
-  | --sharedst | --shareds | --shared | --share | --shar \
-  | --sha | --sh)
-    ac_prev=sharedstatedir ;;
-  -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
-  | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
-  | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
-  | --sha=* | --sh=*)
-    sharedstatedir=$ac_optarg ;;
-
-  -site | --site | --sit)
-    ac_prev=site ;;
-  -site=* | --site=* | --sit=*)
-    site=$ac_optarg ;;
-
-  -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
-    ac_prev=srcdir ;;
-  -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
-    srcdir=$ac_optarg ;;
-
-  -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
-  | --syscon | --sysco | --sysc | --sys | --sy)
-    ac_prev=sysconfdir ;;
-  -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
-  | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
-    sysconfdir=$ac_optarg ;;
-
-  -target | --target | --targe | --targ | --tar | --ta | --t)
-    ac_prev=target_alias ;;
-  -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
-    target_alias=$ac_optarg ;;
-
-  -v | -verbose | --verbose | --verbos | --verbo | --verb)
-    verbose=yes ;;
-
-  -version | --version | --versio | --versi | --vers | -V)
-    ac_init_version=: ;;
-
-  -with-* | --with-*)
-    ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
-    # Reject names that are not valid shell variable names.
-    expr "x$ac_package" : ".*[^-._$as_cr_alnum]" >/dev/null &&
-      { echo "$as_me: error: invalid package name: $ac_package" >&2
-   { (exit 1); exit 1; }; }
-    ac_package=`echo $ac_package | sed 's/[-.]/_/g'`
-    eval with_$ac_package=\$ac_optarg ;;
-
-  -without-* | --without-*)
-    ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
-    # Reject names that are not valid shell variable names.
-    expr "x$ac_package" : ".*[^-._$as_cr_alnum]" >/dev/null &&
-      { echo "$as_me: error: invalid package name: $ac_package" >&2
-   { (exit 1); exit 1; }; }
-    ac_package=`echo $ac_package | sed 's/[-.]/_/g'`
-    eval with_$ac_package=no ;;
-
-  --x)
-    # Obsolete; use --with-x.
-    with_x=yes ;;
-
-  -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
-  | --x-incl | --x-inc | --x-in | --x-i)
-    ac_prev=x_includes ;;
-  -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
-  | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
-    x_includes=$ac_optarg ;;
-
-  -x-libraries | --x-libraries | --x-librarie | --x-librari \
-  | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
-    ac_prev=x_libraries ;;
-  -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
-  | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
-    x_libraries=$ac_optarg ;;
-
-  -*) { echo "$as_me: error: unrecognized option: $ac_option
-Try \`$0 --help' for more information." >&2
-   { (exit 1); exit 1; }; }
-    ;;
-
-  *=*)
-    ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
-    # Reject names that are not valid shell variable names.
-    expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
-      { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
-   { (exit 1); exit 1; }; }
-    eval $ac_envvar=\$ac_optarg
-    export $ac_envvar ;;
-
-  *)
-    # FIXME: should be removed in autoconf 3.0.
-    echo "$as_me: WARNING: you should use --build, --host, --target" >&2
-    expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
-      echo "$as_me: WARNING: invalid host type: $ac_option" >&2
-    : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
-    ;;
-
-  esac
-done
-
-if test -n "$ac_prev"; then
-  ac_option=--`echo $ac_prev | sed 's/_/-/g'`
-  { echo "$as_me: error: missing argument to $ac_option" >&2
-   { (exit 1); exit 1; }; }
-fi
-
-# Be sure to have absolute directory names.
-for ac_var in	exec_prefix prefix bindir sbindir libexecdir datarootdir \
-		datadir sysconfdir sharedstatedir localstatedir includedir \
-		oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
-		libdir localedir mandir
-do
-  eval ac_val=\$$ac_var
-  case $ac_val in
-    [\\/$]* | ?:[\\/]* )  continue;;
-    NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
-  esac
-  { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
-   { (exit 1); exit 1; }; }
-done
-
-# There might be people who depend on the old broken behavior: `$host'
-# used to hold the argument of --host etc.
-# FIXME: To remove some day.
-build=$build_alias
-host=$host_alias
-target=$target_alias
-
-# FIXME: To remove some day.
-if test "x$host_alias" != x; then
-  if test "x$build_alias" = x; then
-    cross_compiling=maybe
-    echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
-    If a cross compiler is detected then cross compile mode will be used." >&2
-  elif test "x$build_alias" != "x$host_alias"; then
-    cross_compiling=yes
-  fi
-fi
-
-ac_tool_prefix=
-test -n "$host_alias" && ac_tool_prefix=$host_alias-
-
-test "$silent" = yes && exec 6>/dev/null
-
-
-ac_pwd=`pwd` && test -n "$ac_pwd" &&
-ac_ls_di=`ls -di .` &&
-ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
-  { echo "$as_me: error: Working directory cannot be determined" >&2
-   { (exit 1); exit 1; }; }
-test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
-  { echo "$as_me: error: pwd does not report name of working directory" >&2
-   { (exit 1); exit 1; }; }
-
-
-# Find the source files, if location was not specified.
-if test -z "$srcdir"; then
-  ac_srcdir_defaulted=yes
-  # Try the directory containing this script, then the parent directory.
-  ac_confdir=`$as_dirname -- "$0" ||
-$as_expr X"$0" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
-	 X"$0" : 'X\(//\)[^/]' \| \
-	 X"$0" : 'X\(//\)$' \| \
-	 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
-echo X"$0" |
-    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
-	    s//\1/
-	    q
-	  }
-	  /^X\(\/\/\)[^/].*/{
-	    s//\1/
-	    q
-	  }
-	  /^X\(\/\/\)$/{
-	    s//\1/
-	    q
-	  }
-	  /^X\(\/\).*/{
-	    s//\1/
-	    q
-	  }
-	  s/.*/./; q'`
-  srcdir=$ac_confdir
-  if test ! -r "$srcdir/$ac_unique_file"; then
-    srcdir=..
-  fi
-else
-  ac_srcdir_defaulted=no
-fi
-if test ! -r "$srcdir/$ac_unique_file"; then
-  test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
-  { echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
-   { (exit 1); exit 1; }; }
-fi
-ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
-ac_abs_confdir=`(
-	cd "$srcdir" && test -r "./$ac_unique_file" || { echo "$as_me: error: $ac_msg" >&2
-   { (exit 1); exit 1; }; }
-	pwd)`
-# When building in place, set srcdir=.
-if test "$ac_abs_confdir" = "$ac_pwd"; then
-  srcdir=.
-fi
-# Remove unnecessary trailing slashes from srcdir.
-# Double slashes in file names in object file debugging info
-# mess up M-x gdb in Emacs.
-case $srcdir in
-*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
-esac
-for ac_var in $ac_precious_vars; do
-  eval ac_env_${ac_var}_set=\${${ac_var}+set}
-  eval ac_env_${ac_var}_value=\$${ac_var}
-  eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
-  eval ac_cv_env_${ac_var}_value=\$${ac_var}
-done
-
-#
-# Report the --help message.
-#
-if test "$ac_init_help" = "long"; then
-  # Omit some internal or obsolete options to make the list less imposing.
-  # This message is too long to be a string in the A/UX 3.1 sh.
-  cat <<_ACEOF
-\`configure' configures Tclxml 3.2 to adapt to many kinds of systems.
-
-Usage: $0 [OPTION]... [VAR=VALUE]...
-
-To assign environment variables (e.g., CC, CFLAGS...), specify them as
-VAR=VALUE.  See below for descriptions of some of the useful variables.
-
-Defaults for the options are specified in brackets.
-
-Configuration:
-  -h, --help              display this help and exit
-      --help=short        display options specific to this package
-      --help=recursive    display the short help of all the included packages
-  -V, --version           display version information and exit
-  -q, --quiet, --silent   do not print \`checking...' messages
-      --cache-file=FILE   cache test results in FILE [disabled]
-  -C, --config-cache      alias for \`--cache-file=config.cache'
-  -n, --no-create         do not create output files
-      --srcdir=DIR        find the sources in DIR [configure dir or \`..']
-
-Installation directories:
-  --prefix=PREFIX         install architecture-independent files in PREFIX
-			  [$ac_default_prefix]
-  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
-			  [PREFIX]
-
-By default, \`make install' will install all the files in
-\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
-an installation prefix other than \`$ac_default_prefix' using \`--prefix',
-for instance \`--prefix=\$HOME'.
-
-For better control, use the options below.
-
-Fine tuning of the installation directories:
-  --bindir=DIR           user executables [EPREFIX/bin]
-  --sbindir=DIR          system admin executables [EPREFIX/sbin]
-  --libexecdir=DIR       program executables [EPREFIX/libexec]
-  --sysconfdir=DIR       read-only single-machine data [PREFIX/etc]
-  --sharedstatedir=DIR   modifiable architecture-independent data [PREFIX/com]
-  --localstatedir=DIR    modifiable single-machine data [PREFIX/var]
-  --libdir=DIR           object code libraries [EPREFIX/lib]
-  --includedir=DIR       C header files [PREFIX/include]
-  --oldincludedir=DIR    C header files for non-gcc [/usr/include]
-  --datarootdir=DIR      read-only arch.-independent data root [PREFIX/share]
-  --datadir=DIR          read-only architecture-independent data [DATAROOTDIR]
-  --infodir=DIR          info documentation [DATAROOTDIR/info]
-  --localedir=DIR        locale-dependent data [DATAROOTDIR/locale]
-  --mandir=DIR           man documentation [DATAROOTDIR/man]
-  --docdir=DIR           documentation root [DATAROOTDIR/doc/tclxml]
-  --htmldir=DIR          html documentation [DOCDIR]
-  --dvidir=DIR           dvi documentation [DOCDIR]
-  --pdfdir=DIR           pdf documentation [DOCDIR]
-  --psdir=DIR            ps documentation [DOCDIR]
-_ACEOF
-
-  cat <<\_ACEOF
-_ACEOF
-fi
-
-if test -n "$ac_init_help"; then
-  case $ac_init_help in
-     short | recursive ) echo "Configuration of Tclxml 3.2:";;
-   esac
-  cat <<\_ACEOF
-
-Optional Features:
-  --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
-  --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
-  --enable-threads        build with threads
-  --enable-shared         build and link with shared libraries (default: on)
-  --enable-64bit          enable 64bit support (default: off)
-  --enable-64bit-vis      enable 64bit Sparc VIS support (default: off)
-  --enable-wince          enable Win/CE support (where applicable)
-  --enable-load           allow dynamic loading and "load" command (default:
-                          on)
-  --enable-symbols        build with debugging symbols (default: off)
-  --enable-framework      build as a Mac OS X framework
-
-Optional Packages:
-  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
-  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
-  --with-tcl              directory containing tcl configuration
-                          (tclConfig.sh)
-  --with-tclinclude       directory containing the public Tcl header files
-  --with-celib=DIR        use Windows/CE support library from DIR
-  --with-xml2-config      the xml2-config configuration script
-  --with-xslt-config      the xslt-config configuration script
-  --with-xml-static      statically link the XML libraries
-
-Some influential environment variables:
-  CC          C compiler command
-  CFLAGS      C compiler flags
-  LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
-              nonstandard directory <lib dir>
-  LIBS        libraries to pass to the linker, e.g. -l<library>
-  CPPFLAGS    C/C++/Objective C preprocessor flags, e.g. -I<include dir> if
-              you have headers in a nonstandard directory <include dir>
-  CPP         C preprocessor
-
-Use these variables to override the choices made by `configure' or to help
-it to find libraries and programs with nonstandard names/locations.
-
-_ACEOF
-ac_status=$?
-fi
-
-if test "$ac_init_help" = "recursive"; then
-  # If there are subdirs, report their specific --help.
-  for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
-    test -d "$ac_dir" || continue
-    ac_builddir=.
-
-case "$ac_dir" in
-.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
-*)
-  ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
-  # A ".." for each directory in $ac_dir_suffix.
-  ac_top_builddir_sub=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,/..,g;s,/,,'`
-  case $ac_top_builddir_sub in
-  "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
-  *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
-  esac ;;
-esac
-ac_abs_top_builddir=$ac_pwd
-ac_abs_builddir=$ac_pwd$ac_dir_suffix
-# for backward compatibility:
-ac_top_builddir=$ac_top_build_prefix
-
-case $srcdir in
-  .)  # We are building in place.
-    ac_srcdir=.
-    ac_top_srcdir=$ac_top_builddir_sub
-    ac_abs_top_srcdir=$ac_pwd ;;
-  [\\/]* | ?:[\\/]* )  # Absolute name.
-    ac_srcdir=$srcdir$ac_dir_suffix;
-    ac_top_srcdir=$srcdir
-    ac_abs_top_srcdir=$srcdir ;;
-  *) # Relative name.
-    ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
-    ac_top_srcdir=$ac_top_build_prefix$srcdir
-    ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
-esac
-ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
-
-    cd "$ac_dir" || { ac_status=$?; continue; }
-    # Check for guested configure.
-    if test -f "$ac_srcdir/configure.gnu"; then
-      echo &&
-      $SHELL "$ac_srcdir/configure.gnu" --help=recursive
-    elif test -f "$ac_srcdir/configure"; then
-      echo &&
-      $SHELL "$ac_srcdir/configure" --help=recursive
-    else
-      echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
-    fi || ac_status=$?
-    cd "$ac_pwd" || { ac_status=$?; break; }
-  done
-fi
-
-test -n "$ac_init_help" && exit $ac_status
-if $ac_init_version; then
-  cat <<\_ACEOF
-Tclxml configure 3.2
-generated by GNU Autoconf 2.61
-
-Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
-2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
-This configure script is free software; the Free Software Foundation
-gives unlimited permission to copy, distribute and modify it.
-_ACEOF
-  exit
-fi
-cat >config.log <<_ACEOF
-This file contains any messages produced by compilers while
-running configure, to aid debugging if configure makes a mistake.
-
-It was created by Tclxml $as_me 3.2, which was
-generated by GNU Autoconf 2.61.  Invocation command line was
-
-  $ $0 $@
-
-_ACEOF
-exec 5>>config.log
-{
-cat <<_ASUNAME
-## --------- ##
-## Platform. ##
-## --------- ##
-
-hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
-uname -m = `(uname -m) 2>/dev/null || echo unknown`
-uname -r = `(uname -r) 2>/dev/null || echo unknown`
-uname -s = `(uname -s) 2>/dev/null || echo unknown`
-uname -v = `(uname -v) 2>/dev/null || echo unknown`
-
-/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
-/bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
-
-/bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
-/usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
-/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
-/usr/bin/hostinfo      = `(/usr/bin/hostinfo) 2>/dev/null      || echo unknown`
-/bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
-/usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
-/bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
-
-_ASUNAME
-
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  echo "PATH: $as_dir"
-done
-IFS=$as_save_IFS
-
-} >&5
-
-cat >&5 <<_ACEOF
-
-
-## ----------- ##
-## Core tests. ##
-## ----------- ##
-
-_ACEOF
-
-
-# Keep a trace of the command line.
-# Strip out --no-create and --no-recursion so they do not pile up.
-# Strip out --silent because we don't want to record it for future runs.
-# Also quote any args containing shell meta-characters.
-# Make two passes to allow for proper duplicate-argument suppression.
-ac_configure_args=
-ac_configure_args0=
-ac_configure_args1=
-ac_must_keep_next=false
-for ac_pass in 1 2
-do
-  for ac_arg
-  do
-    case $ac_arg in
-    -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
-    -q | -quiet | --quiet | --quie | --qui | --qu | --q \
-    | -silent | --silent | --silen | --sile | --sil)
-      continue ;;
-    *\'*)
-      ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
-    esac
-    case $ac_pass in
-    1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
-    2)
-      ac_configure_args1="$ac_configure_args1 '$ac_arg'"
-      if test $ac_must_keep_next = true; then
-	ac_must_keep_next=false # Got value, back to normal.
-      else
-	case $ac_arg in
-	  *=* | --config-cache | -C | -disable-* | --disable-* \
-	  | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
-	  | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
-	  | -with-* | --with-* | -without-* | --without-* | --x)
-	    case "$ac_configure_args0 " in
-	      "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
-	    esac
-	    ;;
-	  -* ) ac_must_keep_next=true ;;
-	esac
-      fi
-      ac_configure_args="$ac_configure_args '$ac_arg'"
-      ;;
-    esac
-  done
-done
-$as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
-$as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
-
-# When interrupted or exit'd, cleanup temporary files, and complete
-# config.log.  We remove comments because anyway the quotes in there
-# would cause problems or look ugly.
-# WARNING: Use '\'' to represent an apostrophe within the trap.
-# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
-trap 'exit_status=$?
-  # Save into config.log some information that might help in debugging.
-  {
-    echo
-
-    cat <<\_ASBOX
-## ---------------- ##
-## Cache variables. ##
-## ---------------- ##
-_ASBOX
-    echo
-    # The following way of writing the cache mishandles newlines in values,
-(
-  for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
-    eval ac_val=\$$ac_var
-    case $ac_val in #(
-    *${as_nl}*)
-      case $ac_var in #(
-      *_cv_*) { echo "$as_me:$LINENO: WARNING: Cache variable $ac_var contains a newline." >&5
-echo "$as_me: WARNING: Cache variable $ac_var contains a newline." >&2;} ;;
-      esac
-      case $ac_var in #(
-      _ | IFS | as_nl) ;; #(
-      *) $as_unset $ac_var ;;
-      esac ;;
-    esac
-  done
-  (set) 2>&1 |
-    case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
-    *${as_nl}ac_space=\ *)
-      sed -n \
-	"s/'\''/'\''\\\\'\'''\''/g;
-	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
-      ;; #(
-    *)
-      sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
-      ;;
-    esac |
-    sort
-)
-    echo
-
-    cat <<\_ASBOX
-## ----------------- ##
-## Output variables. ##
-## ----------------- ##
-_ASBOX
-    echo
-    for ac_var in $ac_subst_vars
-    do
-      eval ac_val=\$$ac_var
-      case $ac_val in
-      *\'\''*) ac_val=`echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
-      esac
-      echo "$ac_var='\''$ac_val'\''"
-    done | sort
-    echo
-
-    if test -n "$ac_subst_files"; then
-      cat <<\_ASBOX
-## ------------------- ##
-## File substitutions. ##
-## ------------------- ##
-_ASBOX
-      echo
-      for ac_var in $ac_subst_files
-      do
-	eval ac_val=\$$ac_var
-	case $ac_val in
-	*\'\''*) ac_val=`echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
-	esac
-	echo "$ac_var='\''$ac_val'\''"
-      done | sort
-      echo
-    fi
-
-    if test -s confdefs.h; then
-      cat <<\_ASBOX
-## ----------- ##
-## confdefs.h. ##
-## ----------- ##
-_ASBOX
-      echo
-      cat confdefs.h
-      echo
-    fi
-    test "$ac_signal" != 0 &&
-      echo "$as_me: caught signal $ac_signal"
-    echo "$as_me: exit $exit_status"
-  } >&5
-  rm -f core *.core core.conftest.* &&
-    rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
-    exit $exit_status
-' 0
-for ac_signal in 1 2 13 15; do
-  trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
-done
-ac_signal=0
-
-# confdefs.h avoids OS command line length limits that DEFS can exceed.
-rm -f -r conftest* confdefs.h
-
-# Predefined preprocessor variables.
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_NAME "$PACKAGE_NAME"
-_ACEOF
-
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
-_ACEOF
-
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_VERSION "$PACKAGE_VERSION"
-_ACEOF
-
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_STRING "$PACKAGE_STRING"
-_ACEOF
-
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
-_ACEOF
-
-
-# Let the site file select an alternate cache file if it wants to.
-# Prefer explicitly selected file to automatically selected ones.
-if test -n "$CONFIG_SITE"; then
-  set x "$CONFIG_SITE"
-elif test "x$prefix" != xNONE; then
-  set x "$prefix/share/config.site" "$prefix/etc/config.site"
-else
-  set x "$ac_default_prefix/share/config.site" \
-	"$ac_default_prefix/etc/config.site"
-fi
-shift
-for ac_site_file
-do
-  if test -r "$ac_site_file"; then
-    { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
-echo "$as_me: loading site script $ac_site_file" >&6;}
-    sed 's/^/| /' "$ac_site_file" >&5
-    . "$ac_site_file"
-  fi
-done
-
-if test -r "$cache_file"; then
-  # Some versions of bash will fail to source /dev/null (special
-  # files actually), so we avoid doing that.
-  if test -f "$cache_file"; then
-    { echo "$as_me:$LINENO: loading cache $cache_file" >&5
-echo "$as_me: loading cache $cache_file" >&6;}
-    case $cache_file in
-      [\\/]* | ?:[\\/]* ) . "$cache_file";;
-      *)                      . "./$cache_file";;
-    esac
-  fi
-else
-  { echo "$as_me:$LINENO: creating cache $cache_file" >&5
-echo "$as_me: creating cache $cache_file" >&6;}
-  >$cache_file
-fi
-
-# Check that the precious variables saved in the cache have kept the same
-# value.
-ac_cache_corrupted=false
-for ac_var in $ac_precious_vars; do
-  eval ac_old_set=\$ac_cv_env_${ac_var}_set
-  eval ac_new_set=\$ac_env_${ac_var}_set
-  eval ac_old_val=\$ac_cv_env_${ac_var}_value
-  eval ac_new_val=\$ac_env_${ac_var}_value
-  case $ac_old_set,$ac_new_set in
-    set,)
-      { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
-echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
-      ac_cache_corrupted=: ;;
-    ,set)
-      { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
-echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
-      ac_cache_corrupted=: ;;
-    ,);;
-    *)
-      if test "x$ac_old_val" != "x$ac_new_val"; then
-	{ echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
-echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
-	{ echo "$as_me:$LINENO:   former value:  $ac_old_val" >&5
-echo "$as_me:   former value:  $ac_old_val" >&2;}
-	{ echo "$as_me:$LINENO:   current value: $ac_new_val" >&5
-echo "$as_me:   current value: $ac_new_val" >&2;}
-	ac_cache_corrupted=:
-      fi;;
-  esac
-  # Pass precious variables to config.status.
-  if test "$ac_new_set" = set; then
-    case $ac_new_val in
-    *\'*) ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
-    *) ac_arg=$ac_var=$ac_new_val ;;
-    esac
-    case " $ac_configure_args " in
-      *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
-      *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
-    esac
-  fi
-done
-if $ac_cache_corrupted; then
-  { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
-echo "$as_me: error: changes in the environment can compromise the build" >&2;}
-  { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
-echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
-   { (exit 1); exit 1; }; }
-fi
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-
-PACKAGE_NAME=Tclxml
-PACKAGE_VERSION=3.2
-
-
-    # TEA extensions pass this us the version of TEA they think they
-    # are compatible with.
-    TEA_VERSION="3.6"
-
-    { echo "$as_me:$LINENO: checking for correct TEA configuration" >&5
-echo $ECHO_N "checking for correct TEA configuration... $ECHO_C" >&6; }
-    if test x"${PACKAGE_NAME}" = x ; then
-	{ { echo "$as_me:$LINENO: error:
-The PACKAGE_NAME variable must be defined by your TEA configure.in" >&5
-echo "$as_me: error:
-The PACKAGE_NAME variable must be defined by your TEA configure.in" >&2;}
-   { (exit 1); exit 1; }; }
-    fi
-    if test x"3.6" = x ; then
-	{ { echo "$as_me:$LINENO: error:
-TEA version not specified." >&5
-echo "$as_me: error:
-TEA version not specified." >&2;}
-   { (exit 1); exit 1; }; }
-    elif test "3.6" != "${TEA_VERSION}" ; then
-	{ echo "$as_me:$LINENO: result: warning: requested TEA version \"3.6\", have \"${TEA_VERSION}\"" >&5
-echo "${ECHO_T}warning: requested TEA version \"3.6\", have \"${TEA_VERSION}\"" >&6; }
-    else
-	{ echo "$as_me:$LINENO: result: ok (TEA ${TEA_VERSION})" >&5
-echo "${ECHO_T}ok (TEA ${TEA_VERSION})" >&6; }
-    fi
-    case "`uname -s`" in
-	*win32*|*WIN32*|*CYGWIN_NT*|*CYGWIN_9*|*CYGWIN_ME*|*MINGW32_*)
-	    # Extract the first word of "cygpath", so it can be a program name with args.
-set dummy cygpath; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
-if test "${ac_cv_prog_CYGPATH+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$CYGPATH"; then
-  ac_cv_prog_CYGPATH="$CYGPATH" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_CYGPATH="cygpath -w"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
-
-  test -z "$ac_cv_prog_CYGPATH" && ac_cv_prog_CYGPATH="echo"
-fi
-fi
-CYGPATH=$ac_cv_prog_CYGPATH
-if test -n "$CYGPATH"; then
-  { echo "$as_me:$LINENO: result: $CYGPATH" >&5
-echo "${ECHO_T}$CYGPATH" >&6; }
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-fi
-
-
-	    EXEEXT=".exe"
-	    TEA_PLATFORM="windows"
-	    ;;
-	*)
-	    CYGPATH=echo
-	    EXEEXT=""
-	    TEA_PLATFORM="unix"
-	    ;;
-    esac
-
-    # Check if exec_prefix is set. If not use fall back to prefix.
-    # Note when adjusted, so that TEA_PREFIX can correct for this.
-    # This is needed for recursive configures, since autoconf propagates
-    # $prefix, but not $exec_prefix (doh!).
-    if test x$exec_prefix = xNONE ; then
-	exec_prefix_default=yes
-	exec_prefix=$prefix
-    fi
-
-
-
-
-    # This package name must be replaced statically for AC_SUBST to work
-
-    # Substitute STUB_LIB_FILE in case package creates a stub library too.
-
-
-    # We AC_SUBST these here to ensure they are subst'ed,
-    # in case the user doesn't call TEA_ADD_...
-
-
-
-
-
-
-
-
-ac_aux_dir=
-for ac_dir in tclconfig "$srcdir"/tclconfig; do
-  if test -f "$ac_dir/install-sh"; then
-    ac_aux_dir=$ac_dir
-    ac_install_sh="$ac_aux_dir/install-sh -c"
-    break
-  elif test -f "$ac_dir/install.sh"; then
-    ac_aux_dir=$ac_dir
-    ac_install_sh="$ac_aux_dir/install.sh -c"
-    break
-  elif test -f "$ac_dir/shtool"; then
-    ac_aux_dir=$ac_dir
-    ac_install_sh="$ac_aux_dir/shtool install -c"
-    break
-  fi
-done
-if test -z "$ac_aux_dir"; then
-  { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in tclconfig \"$srcdir\"/tclconfig" >&5
-echo "$as_me: error: cannot find install-sh or install.sh in tclconfig \"$srcdir\"/tclconfig" >&2;}
-   { (exit 1); exit 1; }; }
-fi
-
-# These three variables are undocumented and unsupported,
-# and are intended to be withdrawn in a future Autoconf release.
-# They can cause serious problems if a builder's source tree is in a directory
-# whose full name contains unusual characters.
-ac_config_guess="$SHELL $ac_aux_dir/config.guess"  # Please don't use this var.
-ac_config_sub="$SHELL $ac_aux_dir/config.sub"  # Please don't use this var.
-ac_configure="$SHELL $ac_aux_dir/configure"  # Please don't use this var.
-
-
-
-
-
-    #
-    # Ok, lets find the tcl configuration
-    # First, look for one uninstalled.
-    # the alternative search directory is invoked by --with-tcl
-    #
-
-    if test x"${no_tcl}" = x ; then
-	# we reset no_tcl in case something fails here
-	no_tcl=true
-
-# Check whether --with-tcl was given.
-if test "${with_tcl+set}" = set; then
-  withval=$with_tcl; with_tclconfig=${withval}
-fi
-
-	{ echo "$as_me:$LINENO: checking for Tcl configuration" >&5
-echo $ECHO_N "checking for Tcl configuration... $ECHO_C" >&6; }
-	if test "${ac_cv_c_tclconfig+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-
-
-	    # First check to see if --with-tcl was specified.
-	    if test x"${with_tclconfig}" != x ; then
-		case ${with_tclconfig} in
-		    */tclConfig.sh )
-			if test -f ${with_tclconfig}; then
-			    { echo "$as_me:$LINENO: WARNING: --with-tcl argument should refer to directory containing tclConfig.sh, not to tclConfig.sh itself" >&5
-echo "$as_me: WARNING: --with-tcl argument should refer to directory containing tclConfig.sh, not to tclConfig.sh itself" >&2;}
-			    with_tclconfig=`echo ${with_tclconfig} | sed 's!/tclConfig\.sh$!!'`
-			fi ;;
-		esac
-		if test -f "${with_tclconfig}/tclConfig.sh" ; then
-		    ac_cv_c_tclconfig=`(cd ${with_tclconfig}; pwd)`
-		else
-		    { { echo "$as_me:$LINENO: error: ${with_tclconfig} directory doesn't contain tclConfig.sh" >&5
-echo "$as_me: error: ${with_tclconfig} directory doesn't contain tclConfig.sh" >&2;}
-   { (exit 1); exit 1; }; }
-		fi
-	    fi
-
-	    # then check for a private Tcl installation
-	    if test x"${ac_cv_c_tclconfig}" = x ; then
-		for i in \
-			../tcl \
-			`ls -dr ../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
-			`ls -dr ../tcl[8-9].[0-9] 2>/dev/null` \
-			`ls -dr ../tcl[8-9].[0-9]* 2>/dev/null` \
-			../../tcl \
-			`ls -dr ../../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
-			`ls -dr ../../tcl[8-9].[0-9] 2>/dev/null` \
-			`ls -dr ../../tcl[8-9].[0-9]* 2>/dev/null` \
-			../../../tcl \
-			`ls -dr ../../../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
-			`ls -dr ../../../tcl[8-9].[0-9] 2>/dev/null` \
-			`ls -dr ../../../tcl[8-9].[0-9]* 2>/dev/null` ; do
-		    if test -f "$i/unix/tclConfig.sh" ; then
-			ac_cv_c_tclconfig=`(cd $i/unix; pwd)`
-			break
-		    fi
-		done
-	    fi
-
-	    # on Darwin, check in Framework installation locations
-	    if test "`uname -s`" = "Darwin" -a x"${ac_cv_c_tclconfig}" = x ; then
-		for i in `ls -d ~/Library/Frameworks 2>/dev/null` \
-			`ls -d /Library/Frameworks 2>/dev/null` \
-			`ls -d /Network/Library/Frameworks 2>/dev/null` \
-			`ls -d /System/Library/Frameworks 2>/dev/null` \
-			; do
-		    if test -f "$i/Tcl.framework/tclConfig.sh" ; then
-			ac_cv_c_tclconfig=`(cd $i/Tcl.framework; pwd)`
-			break
-		    fi
-		done
-	    fi
-
-	    # on Windows, check in common installation locations
-	    if test "${TEA_PLATFORM}" = "windows" \
-		-a x"${ac_cv_c_tclconfig}" = x ; then
-		for i in `ls -d C:/Tcl/lib 2>/dev/null` \
-			`ls -d C:/Progra~1/Tcl/lib 2>/dev/null` \
-			; do
-		    if test -f "$i/tclConfig.sh" ; then
-			ac_cv_c_tclconfig=`(cd $i; pwd)`
-			break
-		    fi
-		done
-	    fi
-
-	    # check in a few common install locations
-	    # Bug fix #1367779 (by Wart)
-	    if test x"${ac_cv_c_tclconfig}" = x ; then
-		for i in `ls -d ${libdir} 2>/dev/null` \
-			`ls -d ${exec_prefix}/lib 2>/dev/null` \
-			`ls -d ${prefix}/lib 2>/dev/null` \
-			`ls -d /usr/local/lib 2>/dev/null` \
-			`ls -d /usr/contrib/lib 2>/dev/null` \
-			`ls -d /usr/lib64 2>/dev/null` \
-			`ls -d /usr/lib 2>/dev/null` \
-			; do
-		    if test -f "$i/tclConfig.sh" ; then
-			ac_cv_c_tclconfig=`(cd $i; pwd)`
-			break
-		    fi
-		done
-	    fi
-
-	    # check in a few other private locations
-	    if test x"${ac_cv_c_tclconfig}" = x ; then
-		for i in \
-			${srcdir}/../tcl \
-			`ls -dr ${srcdir}/../tcl[8-9].[0-9].[0-9]* 2>/dev/null` \
-			`ls -dr ${srcdir}/../tcl[8-9].[0-9] 2>/dev/null` \
-			`ls -dr ${srcdir}/../tcl[8-9].[0-9]* 2>/dev/null` ; do
-		    if test -f "$i/unix/tclConfig.sh" ; then
-		    ac_cv_c_tclconfig=`(cd $i/unix; pwd)`
-		    break
-		fi
-		done
-	    fi
-
-fi
-
-
-	if test x"${ac_cv_c_tclconfig}" = x ; then
-	    TCL_BIN_DIR="# no Tcl configs found"
-	    { echo "$as_me:$LINENO: WARNING: Can't find Tcl configuration definitions" >&5
-echo "$as_me: WARNING: Can't find Tcl configuration definitions" >&2;}
-	    exit 0
-	else
-	    no_tcl=
-	    TCL_BIN_DIR=${ac_cv_c_tclconfig}
-	    { echo "$as_me:$LINENO: result: found ${TCL_BIN_DIR}/tclConfig.sh" >&5
-echo "${ECHO_T}found ${TCL_BIN_DIR}/tclConfig.sh" >&6; }
-	fi
-    fi
-
-
-    { echo "$as_me:$LINENO: checking for existence of ${TCL_BIN_DIR}/tclConfig.sh" >&5
-echo $ECHO_N "checking for existence of ${TCL_BIN_DIR}/tclConfig.sh... $ECHO_C" >&6; }
-
-    if test -f "${TCL_BIN_DIR}/tclConfig.sh" ; then
-        { echo "$as_me:$LINENO: result: loading" >&5
-echo "${ECHO_T}loading" >&6; }
-	. "${TCL_BIN_DIR}/tclConfig.sh"
-    else
-        { echo "$as_me:$LINENO: result: could not find ${TCL_BIN_DIR}/tclConfig.sh" >&5
-echo "${ECHO_T}could not find ${TCL_BIN_DIR}/tclConfig.sh" >&6; }
-    fi
-
-    # eval is required to do the TCL_DBGX substitution
-    eval "TCL_LIB_FILE=\"${TCL_LIB_FILE}\""
-    eval "TCL_STUB_LIB_FILE=\"${TCL_STUB_LIB_FILE}\""
-
-    # If the TCL_BIN_DIR is the build directory (not the install directory),
-    # then set the common variable name to the value of the build variables.
-    # For example, the variable TCL_LIB_SPEC will be set to the value
-    # of TCL_BUILD_LIB_SPEC. An extension should make use of TCL_LIB_SPEC
-    # instead of TCL_BUILD_LIB_SPEC since it will work with both an
-    # installed and uninstalled version of Tcl.
-    if test -f "${TCL_BIN_DIR}/Makefile" ; then
-        TCL_LIB_SPEC=${TCL_BUILD_LIB_SPEC}
-        TCL_STUB_LIB_SPEC=${TCL_BUILD_STUB_LIB_SPEC}
-        TCL_STUB_LIB_PATH=${TCL_BUILD_STUB_LIB_PATH}
-    elif test "`uname -s`" = "Darwin"; then
-	# If Tcl was built as a framework, attempt to use the libraries
-	# from the framework at the given location so that linking works
-	# against Tcl.framework installed in an arbitary location.
-	case ${TCL_DEFS} in
-	    *TCL_FRAMEWORK*)
-		if test -f "${TCL_BIN_DIR}/${TCL_LIB_FILE}"; then
-		    for i in "`cd ${TCL_BIN_DIR}; pwd`" \
-			     "`cd ${TCL_BIN_DIR}/../..; pwd`"; do
-			if test "`basename "$i"`" = "${TCL_LIB_FILE}.framework"; then
-			    TCL_LIB_SPEC="-F`dirname "$i"` -framework ${TCL_LIB_FILE}"
-			    break
-			fi
-		    done
-		fi
-		if test -f "${TCL_BIN_DIR}/${TCL_STUB_LIB_FILE}"; then
-		    TCL_STUB_LIB_SPEC="-L${TCL_BIN_DIR} ${TCL_STUB_LIB_FLAG}"
-		    TCL_STUB_LIB_PATH="${TCL_BIN_DIR}/${TCL_STUB_LIB_FILE}"
-		fi
-		;;
-	esac
-    fi
-
-    # eval is required to do the TCL_DBGX substitution
-    eval "TCL_LIB_FLAG=\"${TCL_LIB_FLAG}\""
-    eval "TCL_LIB_SPEC=\"${TCL_LIB_SPEC}\""
-    eval "TCL_STUB_LIB_FLAG=\"${TCL_STUB_LIB_FLAG}\""
-    eval "TCL_STUB_LIB_SPEC=\"${TCL_STUB_LIB_SPEC}\""
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-    if test "${prefix}" = "NONE"; then
-	prefix_default=yes
-	if test x"${TCL_PREFIX}" != x; then
-	    { echo "$as_me:$LINENO: --prefix defaulting to TCL_PREFIX ${TCL_PREFIX}" >&5
-echo "$as_me: --prefix defaulting to TCL_PREFIX ${TCL_PREFIX}" >&6;}
-	    prefix=${TCL_PREFIX}
-	else
-	    { echo "$as_me:$LINENO: --prefix defaulting to /usr/local" >&5
-echo "$as_me: --prefix defaulting to /usr/local" >&6;}
-	    prefix=/usr/local
-	fi
-    fi
-    if test "${exec_prefix}" = "NONE" -a x"${prefix_default}" = x"yes" \
-	-o x"${exec_prefix_default}" = x"yes" ; then
-	if test x"${TCL_EXEC_PREFIX}" != x; then
-	    { echo "$as_me:$LINENO: --exec-prefix defaulting to TCL_EXEC_PREFIX ${TCL_EXEC_PREFIX}" >&5
-echo "$as_me: --exec-prefix defaulting to TCL_EXEC_PREFIX ${TCL_EXEC_PREFIX}" >&6;}
-	    exec_prefix=${TCL_EXEC_PREFIX}
-	else
-	    { echo "$as_me:$LINENO: --exec-prefix defaulting to ${prefix}" >&5
-echo "$as_me: --exec-prefix defaulting to ${prefix}" >&6;}
-	    exec_prefix=$prefix
-	fi
-    fi
-
-
-
-    # Don't put any macros that use the compiler (e.g. AC_TRY_COMPILE)
-    # in this macro, they need to go into TEA_SETUP_COMPILER instead.
-
-    # If the user did not set CFLAGS, set it now to keep
-    # the AC_PROG_CC macro from adding "-g -O2".
-    if test "${CFLAGS+set}" != "set" ; then
-	CFLAGS=""
-    fi
-
-    ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-if test -n "$ac_tool_prefix"; then
-  # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
-set dummy ${ac_tool_prefix}gcc; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
-if test "${ac_cv_prog_CC+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$CC"; then
-  ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_CC="${ac_tool_prefix}gcc"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
-
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
-  { echo "$as_me:$LINENO: result: $CC" >&5
-echo "${ECHO_T}$CC" >&6; }
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_CC"; then
-  ac_ct_CC=$CC
-  # Extract the first word of "gcc", so it can be a program name with args.
-set dummy gcc; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
-if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$ac_ct_CC"; then
-  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_ac_ct_CC="gcc"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_CC=$ac_cv_prog_ac_ct_CC
-if test -n "$ac_ct_CC"; then
-  { echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
-echo "${ECHO_T}$ac_ct_CC" >&6; }
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-fi
-
-  if test "x$ac_ct_CC" = x; then
-    CC=""
-  else
-    case $cross_compiling:$ac_tool_warned in
-yes:)
-{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
-whose name does not start with the host triplet.  If you think this
-configuration is useful to you, please write to autoconf at gnu.org." >&5
-echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
-whose name does not start with the host triplet.  If you think this
-configuration is useful to you, please write to autoconf at gnu.org." >&2;}
-ac_tool_warned=yes ;;
-esac
-    CC=$ac_ct_CC
-  fi
-else
-  CC="$ac_cv_prog_CC"
-fi
-
-if test -z "$CC"; then
-          if test -n "$ac_tool_prefix"; then
-    # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
-set dummy ${ac_tool_prefix}cc; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
-if test "${ac_cv_prog_CC+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$CC"; then
-  ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_CC="${ac_tool_prefix}cc"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
-
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
-  { echo "$as_me:$LINENO: result: $CC" >&5
-echo "${ECHO_T}$CC" >&6; }
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-fi
-
-
-  fi
-fi
-if test -z "$CC"; then
-  # Extract the first word of "cc", so it can be a program name with args.
-set dummy cc; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
-if test "${ac_cv_prog_CC+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$CC"; then
-  ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-  ac_prog_rejected=no
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
-       ac_prog_rejected=yes
-       continue
-     fi
-    ac_cv_prog_CC="cc"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
-
-if test $ac_prog_rejected = yes; then
-  # We found a bogon in the path, so make sure we never use it.
-  set dummy $ac_cv_prog_CC
-  shift
-  if test $# != 0; then
-    # We chose a different compiler from the bogus one.
-    # However, it has the same basename, so the bogon will be chosen
-    # first if we set CC to just the basename; use the full file name.
-    shift
-    ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
-  fi
-fi
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
-  { echo "$as_me:$LINENO: result: $CC" >&5
-echo "${ECHO_T}$CC" >&6; }
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-fi
-
-
-fi
-if test -z "$CC"; then
-  if test -n "$ac_tool_prefix"; then
-  for ac_prog in cl.exe
-  do
-    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
-set dummy $ac_tool_prefix$ac_prog; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
-if test "${ac_cv_prog_CC+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$CC"; then
-  ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
-
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
-  { echo "$as_me:$LINENO: result: $CC" >&5
-echo "${ECHO_T}$CC" >&6; }
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-fi
-
-
-    test -n "$CC" && break
-  done
-fi
-if test -z "$CC"; then
-  ac_ct_CC=$CC
-  for ac_prog in cl.exe
-do
-  # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
-if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$ac_ct_CC"; then
-  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_ac_ct_CC="$ac_prog"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_CC=$ac_cv_prog_ac_ct_CC
-if test -n "$ac_ct_CC"; then
-  { echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
-echo "${ECHO_T}$ac_ct_CC" >&6; }
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-fi
-
-
-  test -n "$ac_ct_CC" && break
-done
-
-  if test "x$ac_ct_CC" = x; then
-    CC=""
-  else
-    case $cross_compiling:$ac_tool_warned in
-yes:)
-{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
-whose name does not start with the host triplet.  If you think this
-configuration is useful to you, please write to autoconf at gnu.org." >&5
-echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
-whose name does not start with the host triplet.  If you think this
-configuration is useful to you, please write to autoconf at gnu.org." >&2;}
-ac_tool_warned=yes ;;
-esac
-    CC=$ac_ct_CC
-  fi
-fi
-
-fi
-
-
-test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
-See \`config.log' for more details." >&5
-echo "$as_me: error: no acceptable C compiler found in \$PATH
-See \`config.log' for more details." >&2;}
-   { (exit 1); exit 1; }; }
-
-# Provide some information about the compiler.
-echo "$as_me:$LINENO: checking for C compiler version" >&5
-ac_compiler=`set X $ac_compile; echo $2`
-{ (ac_try="$ac_compiler --version >&5"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compiler --version >&5") 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }
-{ (ac_try="$ac_compiler -v >&5"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compiler -v >&5") 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }
-{ (ac_try="$ac_compiler -V >&5"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compiler -V >&5") 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }
-
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-int
-main ()
-{
-
-  ;
-  return 0;
-}
-_ACEOF
-ac_clean_files_save=$ac_clean_files
-ac_clean_files="$ac_clean_files a.out a.exe b.out"
-# Try to create an executable without -o first, disregard a.out.
-# It will help us diagnose broken compilers, and finding out an intuition
-# of exeext.
-{ echo "$as_me:$LINENO: checking for C compiler default output file name" >&5
-echo $ECHO_N "checking for C compiler default output file name... $ECHO_C" >&6; }
-ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
-#
-# List of possible output files, starting from the most likely.
-# The algorithm is not robust to junk in `.', hence go to wildcards (a.*)
-# only as a last resort.  b.out is created by i960 compilers.
-ac_files='a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out'
-#
-# The IRIX 6 linker writes into existing files which may not be
-# executable, retaining their permissions.  Remove them first so a
-# subsequent execution test works.
-ac_rmfiles=
-for ac_file in $ac_files
-do
-  case $ac_file in
-    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
-    * ) ac_rmfiles="$ac_rmfiles $ac_file";;
-  esac
-done
-rm -f $ac_rmfiles
-
-if { (ac_try="$ac_link_default"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link_default") 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; then
-  # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
-# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
-# in a Makefile.  We should not override ac_cv_exeext if it was cached,
-# so that the user can short-circuit this test for compilers unknown to
-# Autoconf.
-for ac_file in $ac_files ''
-do
-  test -f "$ac_file" || continue
-  case $ac_file in
-    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj )
-	;;
-    [ab].out )
-	# We found the default executable, but exeext='' is most
-	# certainly right.
-	break;;
-    *.* )
-        if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
-	then :; else
-	   ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
-	fi
-	# We set ac_cv_exeext here because the later test for it is not
-	# safe: cross compilers may not add the suffix if given an `-o'
-	# argument, so we may need to know it at that point already.
-	# Even if this section looks crufty: it has the advantage of
-	# actually working.
-	break;;
-    * )
-	break;;
-  esac
-done
-test "$ac_cv_exeext" = no && ac_cv_exeext=
-
-else
-  ac_file=''
-fi
-
-{ echo "$as_me:$LINENO: result: $ac_file" >&5
-echo "${ECHO_T}$ac_file" >&6; }
-if test -z "$ac_file"; then
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-{ { echo "$as_me:$LINENO: error: C compiler cannot create executables
-See \`config.log' for more details." >&5
-echo "$as_me: error: C compiler cannot create executables
-See \`config.log' for more details." >&2;}
-   { (exit 77); exit 77; }; }
-fi
-
-ac_exeext=$ac_cv_exeext
-
-# Check that the compiler produces executables we can run.  If not, either
-# the compiler is broken, or we cross compile.
-{ echo "$as_me:$LINENO: checking whether the C compiler works" >&5
-echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6; }
-# FIXME: These cross compiler hacks should be removed for Autoconf 3.0
-# If not cross compiling, check that we can run a simple program.
-if test "$cross_compiling" != yes; then
-  if { ac_try='./$ac_file'
-  { (case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_try") 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; }; then
-    cross_compiling=no
-  else
-    if test "$cross_compiling" = maybe; then
-	cross_compiling=yes
-    else
-	{ { echo "$as_me:$LINENO: error: cannot run C compiled programs.
-If you meant to cross compile, use \`--host'.
-See \`config.log' for more details." >&5
-echo "$as_me: error: cannot run C compiled programs.
-If you meant to cross compile, use \`--host'.
-See \`config.log' for more details." >&2;}
-   { (exit 1); exit 1; }; }
-    fi
-  fi
-fi
-{ echo "$as_me:$LINENO: result: yes" >&5
-echo "${ECHO_T}yes" >&6; }
-
-rm -f a.out a.exe conftest$ac_cv_exeext b.out
-ac_clean_files=$ac_clean_files_save
-# Check that the compiler produces executables we can run.  If not, either
-# the compiler is broken, or we cross compile.
-{ echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
-echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6; }
-{ echo "$as_me:$LINENO: result: $cross_compiling" >&5
-echo "${ECHO_T}$cross_compiling" >&6; }
-
-{ echo "$as_me:$LINENO: checking for suffix of executables" >&5
-echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6; }
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; then
-  # If both `conftest.exe' and `conftest' are `present' (well, observable)
-# catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
-# work properly (i.e., refer to `conftest.exe'), while it won't with
-# `rm'.
-for ac_file in conftest.exe conftest conftest.*; do
-  test -f "$ac_file" || continue
-  case $ac_file in
-    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
-    *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
-	  break;;
-    * ) break;;
-  esac
-done
-else
-  { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
-See \`config.log' for more details." >&5
-echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
-See \`config.log' for more details." >&2;}
-   { (exit 1); exit 1; }; }
-fi
-
-rm -f conftest$ac_cv_exeext
-{ echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
-echo "${ECHO_T}$ac_cv_exeext" >&6; }
-
-rm -f conftest.$ac_ext
-EXEEXT=$ac_cv_exeext
-ac_exeext=$EXEEXT
-{ echo "$as_me:$LINENO: checking for suffix of object files" >&5
-echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6; }
-if test "${ac_cv_objext+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-int
-main ()
-{
-
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.o conftest.obj
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; then
-  for ac_file in conftest.o conftest.obj conftest.*; do
-  test -f "$ac_file" || continue;
-  case $ac_file in
-    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf ) ;;
-    *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
-       break;;
-  esac
-done
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-{ { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
-See \`config.log' for more details." >&5
-echo "$as_me: error: cannot compute suffix of object files: cannot compile
-See \`config.log' for more details." >&2;}
-   { (exit 1); exit 1; }; }
-fi
-
-rm -f conftest.$ac_cv_objext conftest.$ac_ext
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
-echo "${ECHO_T}$ac_cv_objext" >&6; }
-OBJEXT=$ac_cv_objext
-ac_objext=$OBJEXT
-{ echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
-echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6; }
-if test "${ac_cv_c_compiler_gnu+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-int
-main ()
-{
-#ifndef __GNUC__
-       choke me
-#endif
-
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ac_compiler_gnu=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_compiler_gnu=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-ac_cv_c_compiler_gnu=$ac_compiler_gnu
-
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
-echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6; }
-GCC=`test $ac_compiler_gnu = yes && echo yes`
-ac_test_CFLAGS=${CFLAGS+set}
-ac_save_CFLAGS=$CFLAGS
-{ echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
-echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6; }
-if test "${ac_cv_prog_cc_g+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_save_c_werror_flag=$ac_c_werror_flag
-   ac_c_werror_flag=yes
-   ac_cv_prog_cc_g=no
-   CFLAGS="-g"
-   cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-int
-main ()
-{
-
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ac_cv_prog_cc_g=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	CFLAGS=""
-      cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-int
-main ()
-{
-
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  :
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_c_werror_flag=$ac_save_c_werror_flag
-	 CFLAGS="-g"
-	 cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-int
-main ()
-{
-
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ac_cv_prog_cc_g=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-   ac_c_werror_flag=$ac_save_c_werror_flag
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
-echo "${ECHO_T}$ac_cv_prog_cc_g" >&6; }
-if test "$ac_test_CFLAGS" = set; then
-  CFLAGS=$ac_save_CFLAGS
-elif test $ac_cv_prog_cc_g = yes; then
-  if test "$GCC" = yes; then
-    CFLAGS="-g -O2"
-  else
-    CFLAGS="-g"
-  fi
-else
-  if test "$GCC" = yes; then
-    CFLAGS="-O2"
-  else
-    CFLAGS=
-  fi
-fi
-{ echo "$as_me:$LINENO: checking for $CC option to accept ISO C89" >&5
-echo $ECHO_N "checking for $CC option to accept ISO C89... $ECHO_C" >&6; }
-if test "${ac_cv_prog_cc_c89+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_cv_prog_cc_c89=no
-ac_save_CC=$CC
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <stdarg.h>
-#include <stdio.h>
-#include <sys/types.h>
-#include <sys/stat.h>
-/* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
-struct buf { int x; };
-FILE * (*rcsopen) (struct buf *, struct stat *, int);
-static char *e (p, i)
-     char **p;
-     int i;
-{
-  return p[i];
-}
-static char *f (char * (*g) (char **, int), char **p, ...)
-{
-  char *s;
-  va_list v;
-  va_start (v,p);
-  s = g (p, va_arg (v,int));
-  va_end (v);
-  return s;
-}
-
-/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
-   function prototypes and stuff, but not '\xHH' hex character constants.
-   These don't provoke an error unfortunately, instead are silently treated
-   as 'x'.  The following induces an error, until -std is added to get
-   proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
-   array size at least.  It's necessary to write '\x00'==0 to get something
-   that's true only with -std.  */
-int osf4_cc_array ['\x00' == 0 ? 1 : -1];
-
-/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
-   inside strings and character constants.  */
-#define FOO(x) 'x'
-int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
-
-int test (int i, double x);
-struct s1 {int (*f) (int a);};
-struct s2 {int (*f) (double a);};
-int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
-int argc;
-char **argv;
-int
-main ()
-{
-return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
-  ;
-  return 0;
-}
-_ACEOF
-for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
-	-Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
-do
-  CC="$ac_save_CC $ac_arg"
-  rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ac_cv_prog_cc_c89=$ac_arg
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-
-fi
-
-rm -f core conftest.err conftest.$ac_objext
-  test "x$ac_cv_prog_cc_c89" != "xno" && break
-done
-rm -f conftest.$ac_ext
-CC=$ac_save_CC
-
-fi
-# AC_CACHE_VAL
-case "x$ac_cv_prog_cc_c89" in
-  x)
-    { echo "$as_me:$LINENO: result: none needed" >&5
-echo "${ECHO_T}none needed" >&6; } ;;
-  xno)
-    { echo "$as_me:$LINENO: result: unsupported" >&5
-echo "${ECHO_T}unsupported" >&6; } ;;
-  *)
-    CC="$CC $ac_cv_prog_cc_c89"
-    { echo "$as_me:$LINENO: result: $ac_cv_prog_cc_c89" >&5
-echo "${ECHO_T}$ac_cv_prog_cc_c89" >&6; } ;;
-esac
-
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-    ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-{ echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
-echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6; }
-# On Suns, sometimes $CPP names a directory.
-if test -n "$CPP" && test -d "$CPP"; then
-  CPP=
-fi
-if test -z "$CPP"; then
-  if test "${ac_cv_prog_CPP+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-      # Double quotes because CPP needs to be expanded
-    for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
-    do
-      ac_preproc_ok=false
-for ac_c_preproc_warn_flag in '' yes
-do
-  # Use a header file that comes with gcc, so configuring glibc
-  # with a fresh cross-compiler works.
-  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
-  # <limits.h> exists even on freestanding compilers.
-  # On the NeXT, cc -E runs the code through the compiler's parser,
-  # not just through cpp. "Syntax error" is here to catch this case.
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
-		     Syntax error
-_ACEOF
-if { (ac_try="$ac_cpp conftest.$ac_ext"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } >/dev/null && {
-	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       }; then
-  :
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-  # Broken: fails on valid input.
-continue
-fi
-
-rm -f conftest.err conftest.$ac_ext
-
-  # OK, works on sane cases.  Now check whether nonexistent headers
-  # can be detected and how.
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <ac_nonexistent.h>
-_ACEOF
-if { (ac_try="$ac_cpp conftest.$ac_ext"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } >/dev/null && {
-	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       }; then
-  # Broken: success on invalid input.
-continue
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-  # Passes both tests.
-ac_preproc_ok=:
-break
-fi
-
-rm -f conftest.err conftest.$ac_ext
-
-done
-# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
-rm -f conftest.err conftest.$ac_ext
-if $ac_preproc_ok; then
-  break
-fi
-
-    done
-    ac_cv_prog_CPP=$CPP
-
-fi
-  CPP=$ac_cv_prog_CPP
-else
-  ac_cv_prog_CPP=$CPP
-fi
-{ echo "$as_me:$LINENO: result: $CPP" >&5
-echo "${ECHO_T}$CPP" >&6; }
-ac_preproc_ok=false
-for ac_c_preproc_warn_flag in '' yes
-do
-  # Use a header file that comes with gcc, so configuring glibc
-  # with a fresh cross-compiler works.
-  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
-  # <limits.h> exists even on freestanding compilers.
-  # On the NeXT, cc -E runs the code through the compiler's parser,
-  # not just through cpp. "Syntax error" is here to catch this case.
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
-		     Syntax error
-_ACEOF
-if { (ac_try="$ac_cpp conftest.$ac_ext"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } >/dev/null && {
-	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       }; then
-  :
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-  # Broken: fails on valid input.
-continue
-fi
-
-rm -f conftest.err conftest.$ac_ext
-
-  # OK, works on sane cases.  Now check whether nonexistent headers
-  # can be detected and how.
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <ac_nonexistent.h>
-_ACEOF
-if { (ac_try="$ac_cpp conftest.$ac_ext"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } >/dev/null && {
-	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       }; then
-  # Broken: success on invalid input.
-continue
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-  # Passes both tests.
-ac_preproc_ok=:
-break
-fi
-
-rm -f conftest.err conftest.$ac_ext
-
-done
-# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
-rm -f conftest.err conftest.$ac_ext
-if $ac_preproc_ok; then
-  :
-else
-  { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
-See \`config.log' for more details." >&5
-echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
-See \`config.log' for more details." >&2;}
-   { (exit 1); exit 1; }; }
-fi
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-
-    # Find a good install program.  We prefer a C program (faster),
-# so one script is as good as another.  But avoid the broken or
-# incompatible versions:
-# SysV /etc/install, /usr/sbin/install
-# SunOS /usr/etc/install
-# IRIX /sbin/install
-# AIX /bin/install
-# AmigaOS /C/install, which installs bootblocks on floppy discs
-# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
-# AFS /usr/afsws/bin/install, which mishandles nonexistent args
-# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
-# OS/2's system install, which has a completely different semantic
-# ./install, which can be erroneously created by make from ./install.sh.
-{ echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
-echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6; }
-if test -z "$INSTALL"; then
-if test "${ac_cv_path_install+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  # Account for people who put trailing slashes in PATH elements.
-case $as_dir/ in
-  ./ | .// | /cC/* | \
-  /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
-  ?:\\/os2\\/install\\/* | ?:\\/OS2\\/INSTALL\\/* | \
-  /usr/ucb/* ) ;;
-  *)
-    # OSF1 and SCO ODT 3.0 have their own names for install.
-    # Don't use installbsd from OSF since it installs stuff as root
-    # by default.
-    for ac_prog in ginstall scoinst install; do
-      for ac_exec_ext in '' $ac_executable_extensions; do
-	if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
-	  if test $ac_prog = install &&
-	    grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
-	    # AIX install.  It has an incompatible calling convention.
-	    :
-	  elif test $ac_prog = install &&
-	    grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
-	    # program-specific install script used by HP pwplus--don't use.
-	    :
-	  else
-	    ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
-	    break 3
-	  fi
-	fi
-      done
-    done
-    ;;
-esac
-done
-IFS=$as_save_IFS
-
-
-fi
-  if test "${ac_cv_path_install+set}" = set; then
-    INSTALL=$ac_cv_path_install
-  else
-    # As a last resort, use the slow shell script.  Don't cache a
-    # value for INSTALL within a source directory, because that will
-    # break other packages using the cache if that directory is
-    # removed, or if the value is a relative name.
-    INSTALL=$ac_install_sh
-  fi
-fi
-{ echo "$as_me:$LINENO: result: $INSTALL" >&5
-echo "${ECHO_T}$INSTALL" >&6; }
-
-# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
-# It thinks the first close brace ends the variable substitution.
-test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
-
-test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
-
-test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
-
-
-    #--------------------------------------------------------------------
-    # Checks to see if the make program sets the $MAKE variable.
-    #--------------------------------------------------------------------
-
-    { echo "$as_me:$LINENO: checking whether ${MAKE-make} sets \$(MAKE)" >&5
-echo $ECHO_N "checking whether ${MAKE-make} sets \$(MAKE)... $ECHO_C" >&6; }
-set x ${MAKE-make}; ac_make=`echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
-if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.make <<\_ACEOF
-SHELL = /bin/sh
-all:
-	@echo '@@@%%%=$(MAKE)=@@@%%%'
-_ACEOF
-# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
-case `${MAKE-make} -f conftest.make 2>/dev/null` in
-  *@@@%%%=?*=@@@%%%*)
-    eval ac_cv_prog_make_${ac_make}_set=yes;;
-  *)
-    eval ac_cv_prog_make_${ac_make}_set=no;;
-esac
-rm -f conftest.make
-fi
-if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
-  { echo "$as_me:$LINENO: result: yes" >&5
-echo "${ECHO_T}yes" >&6; }
-  SET_MAKE=
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-  SET_MAKE="MAKE=${MAKE-make}"
-fi
-
-
-    #--------------------------------------------------------------------
-    # Find ranlib
-    #--------------------------------------------------------------------
-
-    if test -n "$ac_tool_prefix"; then
-  # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
-set dummy ${ac_tool_prefix}ranlib; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
-if test "${ac_cv_prog_RANLIB+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$RANLIB"; then
-  ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
-
-fi
-fi
-RANLIB=$ac_cv_prog_RANLIB
-if test -n "$RANLIB"; then
-  { echo "$as_me:$LINENO: result: $RANLIB" >&5
-echo "${ECHO_T}$RANLIB" >&6; }
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_RANLIB"; then
-  ac_ct_RANLIB=$RANLIB
-  # Extract the first word of "ranlib", so it can be a program name with args.
-set dummy ranlib; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
-if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$ac_ct_RANLIB"; then
-  ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_ac_ct_RANLIB="ranlib"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
-if test -n "$ac_ct_RANLIB"; then
-  { echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
-echo "${ECHO_T}$ac_ct_RANLIB" >&6; }
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-fi
-
-  if test "x$ac_ct_RANLIB" = x; then
-    RANLIB=":"
-  else
-    case $cross_compiling:$ac_tool_warned in
-yes:)
-{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
-whose name does not start with the host triplet.  If you think this
-configuration is useful to you, please write to autoconf at gnu.org." >&5
-echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
-whose name does not start with the host triplet.  If you think this
-configuration is useful to you, please write to autoconf at gnu.org." >&2;}
-ac_tool_warned=yes ;;
-esac
-    RANLIB=$ac_ct_RANLIB
-  fi
-else
-  RANLIB="$ac_cv_prog_RANLIB"
-fi
-
-
-    #--------------------------------------------------------------------
-    # Determines the correct binary file extension (.o, .obj, .exe etc.)
-    #--------------------------------------------------------------------
-
-
-
-
-
-
-{ echo "$as_me:$LINENO: checking for grep that handles long lines and -e" >&5
-echo $ECHO_N "checking for grep that handles long lines and -e... $ECHO_C" >&6; }
-if test "${ac_cv_path_GREP+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  # Extract the first word of "grep ggrep" to use in msg output
-if test -z "$GREP"; then
-set dummy grep ggrep; ac_prog_name=$2
-if test "${ac_cv_path_GREP+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_path_GREP_found=false
-# Loop through the user's path and test for each of PROGNAME-LIST
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_prog in grep ggrep; do
-  for ac_exec_ext in '' $ac_executable_extensions; do
-    ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
-    { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
-    # Check for GNU ac_path_GREP and select it if it is found.
-  # Check for GNU $ac_path_GREP
-case `"$ac_path_GREP" --version 2>&1` in
-*GNU*)
-  ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
-*)
-  ac_count=0
-  echo $ECHO_N "0123456789$ECHO_C" >"conftest.in"
-  while :
-  do
-    cat "conftest.in" "conftest.in" >"conftest.tmp"
-    mv "conftest.tmp" "conftest.in"
-    cp "conftest.in" "conftest.nl"
-    echo 'GREP' >> "conftest.nl"
-    "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
-    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
-    ac_count=`expr $ac_count + 1`
-    if test $ac_count -gt ${ac_path_GREP_max-0}; then
-      # Best one so far, save it but keep looking for a better one
-      ac_cv_path_GREP="$ac_path_GREP"
-      ac_path_GREP_max=$ac_count
-    fi
-    # 10*(2^10) chars as input seems more than enough
-    test $ac_count -gt 10 && break
-  done
-  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
-esac
-
-
-    $ac_path_GREP_found && break 3
-  done
-done
-
-done
-IFS=$as_save_IFS
-
-
-fi
-
-GREP="$ac_cv_path_GREP"
-if test -z "$GREP"; then
-  { { echo "$as_me:$LINENO: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
-echo "$as_me: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
-   { (exit 1); exit 1; }; }
-fi
-
-else
-  ac_cv_path_GREP=$GREP
-fi
-
-
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_path_GREP" >&5
-echo "${ECHO_T}$ac_cv_path_GREP" >&6; }
- GREP="$ac_cv_path_GREP"
-
-
-{ echo "$as_me:$LINENO: checking for egrep" >&5
-echo $ECHO_N "checking for egrep... $ECHO_C" >&6; }
-if test "${ac_cv_path_EGREP+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
-   then ac_cv_path_EGREP="$GREP -E"
-   else
-     # Extract the first word of "egrep" to use in msg output
-if test -z "$EGREP"; then
-set dummy egrep; ac_prog_name=$2
-if test "${ac_cv_path_EGREP+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_path_EGREP_found=false
-# Loop through the user's path and test for each of PROGNAME-LIST
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_prog in egrep; do
-  for ac_exec_ext in '' $ac_executable_extensions; do
-    ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
-    { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
-    # Check for GNU ac_path_EGREP and select it if it is found.
-  # Check for GNU $ac_path_EGREP
-case `"$ac_path_EGREP" --version 2>&1` in
-*GNU*)
-  ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
-*)
-  ac_count=0
-  echo $ECHO_N "0123456789$ECHO_C" >"conftest.in"
-  while :
-  do
-    cat "conftest.in" "conftest.in" >"conftest.tmp"
-    mv "conftest.tmp" "conftest.in"
-    cp "conftest.in" "conftest.nl"
-    echo 'EGREP' >> "conftest.nl"
-    "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
-    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
-    ac_count=`expr $ac_count + 1`
-    if test $ac_count -gt ${ac_path_EGREP_max-0}; then
-      # Best one so far, save it but keep looking for a better one
-      ac_cv_path_EGREP="$ac_path_EGREP"
-      ac_path_EGREP_max=$ac_count
-    fi
-    # 10*(2^10) chars as input seems more than enough
-    test $ac_count -gt 10 && break
-  done
-  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
-esac
-
-
-    $ac_path_EGREP_found && break 3
-  done
-done
-
-done
-IFS=$as_save_IFS
-
-
-fi
-
-EGREP="$ac_cv_path_EGREP"
-if test -z "$EGREP"; then
-  { { echo "$as_me:$LINENO: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
-echo "$as_me: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
-   { (exit 1); exit 1; }; }
-fi
-
-else
-  ac_cv_path_EGREP=$EGREP
-fi
-
-
-   fi
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_path_EGREP" >&5
-echo "${ECHO_T}$ac_cv_path_EGREP" >&6; }
- EGREP="$ac_cv_path_EGREP"
-
-
-{ echo "$as_me:$LINENO: checking for ANSI C header files" >&5
-echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6; }
-if test "${ac_cv_header_stdc+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <stdlib.h>
-#include <stdarg.h>
-#include <string.h>
-#include <float.h>
-
-int
-main ()
-{
-
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ac_cv_header_stdc=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_header_stdc=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-
-if test $ac_cv_header_stdc = yes; then
-  # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <string.h>
-
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-  $EGREP "memchr" >/dev/null 2>&1; then
-  :
-else
-  ac_cv_header_stdc=no
-fi
-rm -f conftest*
-
-fi
-
-if test $ac_cv_header_stdc = yes; then
-  # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <stdlib.h>
-
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-  $EGREP "free" >/dev/null 2>&1; then
-  :
-else
-  ac_cv_header_stdc=no
-fi
-rm -f conftest*
-
-fi
-
-if test $ac_cv_header_stdc = yes; then
-  # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
-  if test "$cross_compiling" = yes; then
-  :
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <ctype.h>
-#include <stdlib.h>
-#if ((' ' & 0x0FF) == 0x020)
-# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
-# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
-#else
-# define ISLOWER(c) \
-		   (('a' <= (c) && (c) <= 'i') \
-		     || ('j' <= (c) && (c) <= 'r') \
-		     || ('s' <= (c) && (c) <= 'z'))
-# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
-#endif
-
-#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
-int
-main ()
-{
-  int i;
-  for (i = 0; i < 256; i++)
-    if (XOR (islower (i), ISLOWER (i))
-	|| toupper (i) != TOUPPER (i))
-      return 2;
-  return 0;
-}
-_ACEOF
-rm -f conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
-  { (case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_try") 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; }; then
-  :
-else
-  echo "$as_me: program exited with status $ac_status" >&5
-echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-( exit $ac_status )
-ac_cv_header_stdc=no
-fi
-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
-fi
-
-
-fi
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
-echo "${ECHO_T}$ac_cv_header_stdc" >&6; }
-if test $ac_cv_header_stdc = yes; then
-
-cat >>confdefs.h <<\_ACEOF
-#define STDC_HEADERS 1
-_ACEOF
-
-fi
-
-# On IRIX 5.3, sys/types and inttypes.h are conflicting.
-
-
-
-
-
-
-
-
-
-for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
-		  inttypes.h stdint.h unistd.h
-do
-as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
-{ echo "$as_me:$LINENO: checking for $ac_header" >&5
-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
-if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-$ac_includes_default
-
-#include <$ac_header>
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  eval "$as_ac_Header=yes"
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	eval "$as_ac_Header=no"
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-ac_res=`eval echo '${'$as_ac_Header'}'`
-	       { echo "$as_me:$LINENO: result: $ac_res" >&5
-echo "${ECHO_T}$ac_res" >&6; }
-if test `eval echo '${'$as_ac_Header'}'` = yes; then
-  cat >>confdefs.h <<_ACEOF
-#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
-_ACEOF
-
-fi
-
-done
-
-
-
-    # Any macros that use the compiler (e.g. AC_TRY_COMPILE) have to go here.
-
-
-    #------------------------------------------------------------------------
-    # If we're using GCC, see if the compiler understands -pipe. If so, use it.
-    # It makes compiling go faster.  (This is only a performance feature.)
-    #------------------------------------------------------------------------
-
-    if test -z "$no_pipe" -a -n "$GCC"; then
-	{ echo "$as_me:$LINENO: checking if the compiler understands -pipe" >&5
-echo $ECHO_N "checking if the compiler understands -pipe... $ECHO_C" >&6; }
-if test "${tcl_cv_cc_pipe+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-
-	    hold_cflags=$CFLAGS; CFLAGS="$CFLAGS -pipe"
-	    cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-int
-main ()
-{
-
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  tcl_cv_cc_pipe=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	tcl_cv_cc_pipe=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-	    CFLAGS=$hold_cflags
-fi
-{ echo "$as_me:$LINENO: result: $tcl_cv_cc_pipe" >&5
-echo "${ECHO_T}$tcl_cv_cc_pipe" >&6; }
-	if test $tcl_cv_cc_pipe = yes; then
-	    CFLAGS="$CFLAGS -pipe"
-	fi
-    fi
-
-    #--------------------------------------------------------------------
-    # Common compiler flag setup
-    #--------------------------------------------------------------------
-
-    { echo "$as_me:$LINENO: checking whether byte ordering is bigendian" >&5
-echo $ECHO_N "checking whether byte ordering is bigendian... $ECHO_C" >&6; }
-if test "${ac_cv_c_bigendian+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  # See if sys/param.h defines the BYTE_ORDER macro.
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <sys/types.h>
-#include <sys/param.h>
-
-int
-main ()
-{
-#if  ! (defined BYTE_ORDER && defined BIG_ENDIAN && defined LITTLE_ENDIAN \
-	&& BYTE_ORDER && BIG_ENDIAN && LITTLE_ENDIAN)
- bogus endian macros
-#endif
-
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  # It does; now see whether it defined to BIG_ENDIAN or not.
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <sys/types.h>
-#include <sys/param.h>
-
-int
-main ()
-{
-#if BYTE_ORDER != BIG_ENDIAN
- not big endian
-#endif
-
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ac_cv_c_bigendian=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_c_bigendian=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	# It does not; compile a test program.
-if test "$cross_compiling" = yes; then
-  # try to guess the endianness by grepping values into an object file
-  ac_cv_c_bigendian=unknown
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-short int ascii_mm[] = { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
-short int ascii_ii[] = { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
-void _ascii () { char *s = (char *) ascii_mm; s = (char *) ascii_ii; }
-short int ebcdic_ii[] = { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
-short int ebcdic_mm[] = { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
-void _ebcdic () { char *s = (char *) ebcdic_mm; s = (char *) ebcdic_ii; }
-int
-main ()
-{
- _ascii (); _ebcdic ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  if grep BIGenDianSyS conftest.$ac_objext >/dev/null ; then
-  ac_cv_c_bigendian=yes
-fi
-if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
-  if test "$ac_cv_c_bigendian" = unknown; then
-    ac_cv_c_bigendian=no
-  else
-    # finding both strings is unlikely to happen, but who knows?
-    ac_cv_c_bigendian=unknown
-  fi
-fi
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-$ac_includes_default
-int
-main ()
-{
-
-  /* Are we little or big endian?  From Harbison&Steele.  */
-  union
-  {
-    long int l;
-    char c[sizeof (long int)];
-  } u;
-  u.l = 1;
-  return u.c[sizeof (long int) - 1] == 1;
-
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
-  { (case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_try") 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; }; then
-  ac_cv_c_bigendian=no
-else
-  echo "$as_me: program exited with status $ac_status" >&5
-echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-( exit $ac_status )
-ac_cv_c_bigendian=yes
-fi
-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
-fi
-
-
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_c_bigendian" >&5
-echo "${ECHO_T}$ac_cv_c_bigendian" >&6; }
-case $ac_cv_c_bigendian in
-  yes)
-
-cat >>confdefs.h <<\_ACEOF
-#define WORDS_BIGENDIAN 1
-_ACEOF
- ;;
-  no)
-     ;;
-  *)
-    { { echo "$as_me:$LINENO: error: unknown endianness
-presetting ac_cv_c_bigendian=no (or yes) will help" >&5
-echo "$as_me: error: unknown endianness
-presetting ac_cv_c_bigendian=no (or yes) will help" >&2;}
-   { (exit 1); exit 1; }; } ;;
-esac
-
-    if test "${TEA_PLATFORM}" = "unix" ; then
-
-    #--------------------------------------------------------------------
-    # On a few very rare systems, all of the libm.a stuff is
-    # already in libc.a.  Set compiler flags accordingly.
-    # Also, Linux requires the "ieee" library for math to work
-    # right (and it must appear before "-lm").
-    #--------------------------------------------------------------------
-
-    { echo "$as_me:$LINENO: checking for sin" >&5
-echo $ECHO_N "checking for sin... $ECHO_C" >&6; }
-if test "${ac_cv_func_sin+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-/* Define sin to an innocuous variant, in case <limits.h> declares sin.
-   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
-#define sin innocuous_sin
-
-/* System header to define __stub macros and hopefully few prototypes,
-    which can conflict with char sin (); below.
-    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
-    <limits.h> exists even on freestanding compilers.  */
-
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
-
-#undef sin
-
-/* Override any GCC internal prototype to avoid an error.
-   Use char because int might match the return type of a GCC
-   builtin and then its argument prototype would still apply.  */
-#ifdef __cplusplus
-extern "C"
-#endif
-char sin ();
-/* The GNU C library defines this for functions which it implements
-    to always fail with ENOSYS.  Some functions are actually named
-    something starting with __ and the normal name is an alias.  */
-#if defined __stub_sin || defined __stub___sin
-choke me
-#endif
-
-int
-main ()
-{
-return sin ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_func_sin=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_func_sin=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_func_sin" >&5
-echo "${ECHO_T}$ac_cv_func_sin" >&6; }
-if test $ac_cv_func_sin = yes; then
-  MATH_LIBS=""
-else
-  MATH_LIBS="-lm"
-fi
-
-    { echo "$as_me:$LINENO: checking for main in -lieee" >&5
-echo $ECHO_N "checking for main in -lieee... $ECHO_C" >&6; }
-if test "${ac_cv_lib_ieee_main+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-lieee  $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-
-int
-main ()
-{
-return main ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_ieee_main=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_lib_ieee_main=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_ieee_main" >&5
-echo "${ECHO_T}$ac_cv_lib_ieee_main" >&6; }
-if test $ac_cv_lib_ieee_main = yes; then
-  MATH_LIBS="-lieee $MATH_LIBS"
-fi
-
-
-    #--------------------------------------------------------------------
-    # Interactive UNIX requires -linet instead of -lsocket, plus it
-    # needs net/errno.h to define the socket-related error codes.
-    #--------------------------------------------------------------------
-
-    { echo "$as_me:$LINENO: checking for main in -linet" >&5
-echo $ECHO_N "checking for main in -linet... $ECHO_C" >&6; }
-if test "${ac_cv_lib_inet_main+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-linet  $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-
-int
-main ()
-{
-return main ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_inet_main=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_lib_inet_main=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_inet_main" >&5
-echo "${ECHO_T}$ac_cv_lib_inet_main" >&6; }
-if test $ac_cv_lib_inet_main = yes; then
-  LIBS="$LIBS -linet"
-fi
-
-    if test "${ac_cv_header_net_errno_h+set}" = set; then
-  { echo "$as_me:$LINENO: checking for net/errno.h" >&5
-echo $ECHO_N "checking for net/errno.h... $ECHO_C" >&6; }
-if test "${ac_cv_header_net_errno_h+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_net_errno_h" >&5
-echo "${ECHO_T}$ac_cv_header_net_errno_h" >&6; }
-else
-  # Is the header compilable?
-{ echo "$as_me:$LINENO: checking net/errno.h usability" >&5
-echo $ECHO_N "checking net/errno.h usability... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-$ac_includes_default
-#include <net/errno.h>
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ac_header_compiler=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_header_compiler=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
-echo "${ECHO_T}$ac_header_compiler" >&6; }
-
-# Is the header present?
-{ echo "$as_me:$LINENO: checking net/errno.h presence" >&5
-echo $ECHO_N "checking net/errno.h presence... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <net/errno.h>
-_ACEOF
-if { (ac_try="$ac_cpp conftest.$ac_ext"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } >/dev/null && {
-	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       }; then
-  ac_header_preproc=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-  ac_header_preproc=no
-fi
-
-rm -f conftest.err conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
-echo "${ECHO_T}$ac_header_preproc" >&6; }
-
-# So?  What about this header?
-case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
-  yes:no: )
-    { echo "$as_me:$LINENO: WARNING: net/errno.h: accepted by the compiler, rejected by the preprocessor!" >&5
-echo "$as_me: WARNING: net/errno.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
-    { echo "$as_me:$LINENO: WARNING: net/errno.h: proceeding with the compiler's result" >&5
-echo "$as_me: WARNING: net/errno.h: proceeding with the compiler's result" >&2;}
-    ac_header_preproc=yes
-    ;;
-  no:yes:* )
-    { echo "$as_me:$LINENO: WARNING: net/errno.h: present but cannot be compiled" >&5
-echo "$as_me: WARNING: net/errno.h: present but cannot be compiled" >&2;}
-    { echo "$as_me:$LINENO: WARNING: net/errno.h:     check for missing prerequisite headers?" >&5
-echo "$as_me: WARNING: net/errno.h:     check for missing prerequisite headers?" >&2;}
-    { echo "$as_me:$LINENO: WARNING: net/errno.h: see the Autoconf documentation" >&5
-echo "$as_me: WARNING: net/errno.h: see the Autoconf documentation" >&2;}
-    { echo "$as_me:$LINENO: WARNING: net/errno.h:     section \"Present But Cannot Be Compiled\"" >&5
-echo "$as_me: WARNING: net/errno.h:     section \"Present But Cannot Be Compiled\"" >&2;}
-    { echo "$as_me:$LINENO: WARNING: net/errno.h: proceeding with the preprocessor's result" >&5
-echo "$as_me: WARNING: net/errno.h: proceeding with the preprocessor's result" >&2;}
-    { echo "$as_me:$LINENO: WARNING: net/errno.h: in the future, the compiler will take precedence" >&5
-echo "$as_me: WARNING: net/errno.h: in the future, the compiler will take precedence" >&2;}
-
-    ;;
-esac
-{ echo "$as_me:$LINENO: checking for net/errno.h" >&5
-echo $ECHO_N "checking for net/errno.h... $ECHO_C" >&6; }
-if test "${ac_cv_header_net_errno_h+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_cv_header_net_errno_h=$ac_header_preproc
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_net_errno_h" >&5
-echo "${ECHO_T}$ac_cv_header_net_errno_h" >&6; }
-
-fi
-if test $ac_cv_header_net_errno_h = yes; then
-
-
-cat >>confdefs.h <<\_ACEOF
-#define HAVE_NET_ERRNO_H 1
-_ACEOF
-
-fi
-
-
-
-    #--------------------------------------------------------------------
-    #	Check for the existence of the -lsocket and -lnsl libraries.
-    #	The order here is important, so that they end up in the right
-    #	order in the command line generated by make.  Here are some
-    #	special considerations:
-    #	1. Use "connect" and "accept" to check for -lsocket, and
-    #	   "gethostbyname" to check for -lnsl.
-    #	2. Use each function name only once:  can't redo a check because
-    #	   autoconf caches the results of the last check and won't redo it.
-    #	3. Use -lnsl and -lsocket only if they supply procedures that
-    #	   aren't already present in the normal libraries.  This is because
-    #	   IRIX 5.2 has libraries, but they aren't needed and they're
-    #	   bogus:  they goof up name resolution if used.
-    #	4. On some SVR4 systems, can't use -lsocket without -lnsl too.
-    #	   To get around this problem, check for both libraries together
-    #	   if -lsocket doesn't work by itself.
-    #--------------------------------------------------------------------
-
-    tcl_checkBoth=0
-    { echo "$as_me:$LINENO: checking for connect" >&5
-echo $ECHO_N "checking for connect... $ECHO_C" >&6; }
-if test "${ac_cv_func_connect+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-/* Define connect to an innocuous variant, in case <limits.h> declares connect.
-   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
-#define connect innocuous_connect
-
-/* System header to define __stub macros and hopefully few prototypes,
-    which can conflict with char connect (); below.
-    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
-    <limits.h> exists even on freestanding compilers.  */
-
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
-
-#undef connect
-
-/* Override any GCC internal prototype to avoid an error.
-   Use char because int might match the return type of a GCC
-   builtin and then its argument prototype would still apply.  */
-#ifdef __cplusplus
-extern "C"
-#endif
-char connect ();
-/* The GNU C library defines this for functions which it implements
-    to always fail with ENOSYS.  Some functions are actually named
-    something starting with __ and the normal name is an alias.  */
-#if defined __stub_connect || defined __stub___connect
-choke me
-#endif
-
-int
-main ()
-{
-return connect ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_func_connect=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_func_connect=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_func_connect" >&5
-echo "${ECHO_T}$ac_cv_func_connect" >&6; }
-if test $ac_cv_func_connect = yes; then
-  tcl_checkSocket=0
-else
-  tcl_checkSocket=1
-fi
-
-    if test "$tcl_checkSocket" = 1; then
-	{ echo "$as_me:$LINENO: checking for setsockopt" >&5
-echo $ECHO_N "checking for setsockopt... $ECHO_C" >&6; }
-if test "${ac_cv_func_setsockopt+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-/* Define setsockopt to an innocuous variant, in case <limits.h> declares setsockopt.
-   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
-#define setsockopt innocuous_setsockopt
-
-/* System header to define __stub macros and hopefully few prototypes,
-    which can conflict with char setsockopt (); below.
-    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
-    <limits.h> exists even on freestanding compilers.  */
-
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
-
-#undef setsockopt
-
-/* Override any GCC internal prototype to avoid an error.
-   Use char because int might match the return type of a GCC
-   builtin and then its argument prototype would still apply.  */
-#ifdef __cplusplus
-extern "C"
-#endif
-char setsockopt ();
-/* The GNU C library defines this for functions which it implements
-    to always fail with ENOSYS.  Some functions are actually named
-    something starting with __ and the normal name is an alias.  */
-#if defined __stub_setsockopt || defined __stub___setsockopt
-choke me
-#endif
-
-int
-main ()
-{
-return setsockopt ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_func_setsockopt=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_func_setsockopt=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_func_setsockopt" >&5
-echo "${ECHO_T}$ac_cv_func_setsockopt" >&6; }
-if test $ac_cv_func_setsockopt = yes; then
-  :
-else
-  { echo "$as_me:$LINENO: checking for setsockopt in -lsocket" >&5
-echo $ECHO_N "checking for setsockopt in -lsocket... $ECHO_C" >&6; }
-if test "${ac_cv_lib_socket_setsockopt+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-lsocket  $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-/* Override any GCC internal prototype to avoid an error.
-   Use char because int might match the return type of a GCC
-   builtin and then its argument prototype would still apply.  */
-#ifdef __cplusplus
-extern "C"
-#endif
-char setsockopt ();
-int
-main ()
-{
-return setsockopt ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_socket_setsockopt=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_lib_socket_setsockopt=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_socket_setsockopt" >&5
-echo "${ECHO_T}$ac_cv_lib_socket_setsockopt" >&6; }
-if test $ac_cv_lib_socket_setsockopt = yes; then
-  LIBS="$LIBS -lsocket"
-else
-  tcl_checkBoth=1
-fi
-
-fi
-
-    fi
-    if test "$tcl_checkBoth" = 1; then
-	tk_oldLibs=$LIBS
-	LIBS="$LIBS -lsocket -lnsl"
-	{ echo "$as_me:$LINENO: checking for accept" >&5
-echo $ECHO_N "checking for accept... $ECHO_C" >&6; }
-if test "${ac_cv_func_accept+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-/* Define accept to an innocuous variant, in case <limits.h> declares accept.
-   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
-#define accept innocuous_accept
-
-/* System header to define __stub macros and hopefully few prototypes,
-    which can conflict with char accept (); below.
-    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
-    <limits.h> exists even on freestanding compilers.  */
-
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
-
-#undef accept
-
-/* Override any GCC internal prototype to avoid an error.
-   Use char because int might match the return type of a GCC
-   builtin and then its argument prototype would still apply.  */
-#ifdef __cplusplus
-extern "C"
-#endif
-char accept ();
-/* The GNU C library defines this for functions which it implements
-    to always fail with ENOSYS.  Some functions are actually named
-    something starting with __ and the normal name is an alias.  */
-#if defined __stub_accept || defined __stub___accept
-choke me
-#endif
-
-int
-main ()
-{
-return accept ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_func_accept=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_func_accept=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_func_accept" >&5
-echo "${ECHO_T}$ac_cv_func_accept" >&6; }
-if test $ac_cv_func_accept = yes; then
-  tcl_checkNsl=0
-else
-  LIBS=$tk_oldLibs
-fi
-
-    fi
-    { echo "$as_me:$LINENO: checking for gethostbyname" >&5
-echo $ECHO_N "checking for gethostbyname... $ECHO_C" >&6; }
-if test "${ac_cv_func_gethostbyname+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-/* Define gethostbyname to an innocuous variant, in case <limits.h> declares gethostbyname.
-   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
-#define gethostbyname innocuous_gethostbyname
-
-/* System header to define __stub macros and hopefully few prototypes,
-    which can conflict with char gethostbyname (); below.
-    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
-    <limits.h> exists even on freestanding compilers.  */
-
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
-
-#undef gethostbyname
-
-/* Override any GCC internal prototype to avoid an error.
-   Use char because int might match the return type of a GCC
-   builtin and then its argument prototype would still apply.  */
-#ifdef __cplusplus
-extern "C"
-#endif
-char gethostbyname ();
-/* The GNU C library defines this for functions which it implements
-    to always fail with ENOSYS.  Some functions are actually named
-    something starting with __ and the normal name is an alias.  */
-#if defined __stub_gethostbyname || defined __stub___gethostbyname
-choke me
-#endif
-
-int
-main ()
-{
-return gethostbyname ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_func_gethostbyname=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_func_gethostbyname=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_func_gethostbyname" >&5
-echo "${ECHO_T}$ac_cv_func_gethostbyname" >&6; }
-if test $ac_cv_func_gethostbyname = yes; then
-  :
-else
-  { echo "$as_me:$LINENO: checking for gethostbyname in -lnsl" >&5
-echo $ECHO_N "checking for gethostbyname in -lnsl... $ECHO_C" >&6; }
-if test "${ac_cv_lib_nsl_gethostbyname+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-lnsl  $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-/* Override any GCC internal prototype to avoid an error.
-   Use char because int might match the return type of a GCC
-   builtin and then its argument prototype would still apply.  */
-#ifdef __cplusplus
-extern "C"
-#endif
-char gethostbyname ();
-int
-main ()
-{
-return gethostbyname ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_nsl_gethostbyname=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_lib_nsl_gethostbyname=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_nsl_gethostbyname" >&5
-echo "${ECHO_T}$ac_cv_lib_nsl_gethostbyname" >&6; }
-if test $ac_cv_lib_nsl_gethostbyname = yes; then
-  LIBS="$LIBS -lnsl"
-fi
-
-fi
-
-
-    # Don't perform the eval of the libraries here because DL_LIBS
-    # won't be set until we call TEA_CONFIG_CFLAGS
-
-    TCL_LIBS='${DL_LIBS} ${LIBS} ${MATH_LIBS}'
-
-
-
-
-    { echo "$as_me:$LINENO: checking dirent.h" >&5
-echo $ECHO_N "checking dirent.h... $ECHO_C" >&6; }
-if test "${tcl_cv_dirent_h+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-
-    cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <sys/types.h>
-#include <dirent.h>
-int
-main ()
-{
-
-#ifndef _POSIX_SOURCE
-#   ifdef __Lynx__
-	/*
-	 * Generate compilation error to make the test fail:  Lynx headers
-	 * are only valid if really in the POSIX environment.
-	 */
-
-	missing_procedure();
-#   endif
-#endif
-DIR *d;
-struct dirent *entryPtr;
-char *p;
-d = opendir("foobar");
-entryPtr = readdir(d);
-p = entryPtr->d_name;
-closedir(d);
-
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  tcl_cv_dirent_h=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	tcl_cv_dirent_h=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-fi
-{ echo "$as_me:$LINENO: result: $tcl_cv_dirent_h" >&5
-echo "${ECHO_T}$tcl_cv_dirent_h" >&6; }
-
-    if test $tcl_cv_dirent_h = no; then
-
-cat >>confdefs.h <<\_ACEOF
-#define NO_DIRENT_H 1
-_ACEOF
-
-    fi
-
-    if test "${ac_cv_header_errno_h+set}" = set; then
-  { echo "$as_me:$LINENO: checking for errno.h" >&5
-echo $ECHO_N "checking for errno.h... $ECHO_C" >&6; }
-if test "${ac_cv_header_errno_h+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_errno_h" >&5
-echo "${ECHO_T}$ac_cv_header_errno_h" >&6; }
-else
-  # Is the header compilable?
-{ echo "$as_me:$LINENO: checking errno.h usability" >&5
-echo $ECHO_N "checking errno.h usability... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-$ac_includes_default
-#include <errno.h>
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ac_header_compiler=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_header_compiler=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
-echo "${ECHO_T}$ac_header_compiler" >&6; }
-
-# Is the header present?
-{ echo "$as_me:$LINENO: checking errno.h presence" >&5
-echo $ECHO_N "checking errno.h presence... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <errno.h>
-_ACEOF
-if { (ac_try="$ac_cpp conftest.$ac_ext"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } >/dev/null && {
-	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       }; then
-  ac_header_preproc=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-  ac_header_preproc=no
-fi
-
-rm -f conftest.err conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
-echo "${ECHO_T}$ac_header_preproc" >&6; }
-
-# So?  What about this header?
-case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
-  yes:no: )
-    { echo "$as_me:$LINENO: WARNING: errno.h: accepted by the compiler, rejected by the preprocessor!" >&5
-echo "$as_me: WARNING: errno.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
-    { echo "$as_me:$LINENO: WARNING: errno.h: proceeding with the compiler's result" >&5
-echo "$as_me: WARNING: errno.h: proceeding with the compiler's result" >&2;}
-    ac_header_preproc=yes
-    ;;
-  no:yes:* )
-    { echo "$as_me:$LINENO: WARNING: errno.h: present but cannot be compiled" >&5
-echo "$as_me: WARNING: errno.h: present but cannot be compiled" >&2;}
-    { echo "$as_me:$LINENO: WARNING: errno.h:     check for missing prerequisite headers?" >&5
-echo "$as_me: WARNING: errno.h:     check for missing prerequisite headers?" >&2;}
-    { echo "$as_me:$LINENO: WARNING: errno.h: see the Autoconf documentation" >&5
-echo "$as_me: WARNING: errno.h: see the Autoconf documentation" >&2;}
-    { echo "$as_me:$LINENO: WARNING: errno.h:     section \"Present But Cannot Be Compiled\"" >&5
-echo "$as_me: WARNING: errno.h:     section \"Present But Cannot Be Compiled\"" >&2;}
-    { echo "$as_me:$LINENO: WARNING: errno.h: proceeding with the preprocessor's result" >&5
-echo "$as_me: WARNING: errno.h: proceeding with the preprocessor's result" >&2;}
-    { echo "$as_me:$LINENO: WARNING: errno.h: in the future, the compiler will take precedence" >&5
-echo "$as_me: WARNING: errno.h: in the future, the compiler will take precedence" >&2;}
-
-    ;;
-esac
-{ echo "$as_me:$LINENO: checking for errno.h" >&5
-echo $ECHO_N "checking for errno.h... $ECHO_C" >&6; }
-if test "${ac_cv_header_errno_h+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_cv_header_errno_h=$ac_header_preproc
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_errno_h" >&5
-echo "${ECHO_T}$ac_cv_header_errno_h" >&6; }
-
-fi
-if test $ac_cv_header_errno_h = yes; then
-  :
-else
-
-cat >>confdefs.h <<\_ACEOF
-#define NO_ERRNO_H 1
-_ACEOF
-
-fi
-
-
-    if test "${ac_cv_header_float_h+set}" = set; then
-  { echo "$as_me:$LINENO: checking for float.h" >&5
-echo $ECHO_N "checking for float.h... $ECHO_C" >&6; }
-if test "${ac_cv_header_float_h+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_float_h" >&5
-echo "${ECHO_T}$ac_cv_header_float_h" >&6; }
-else
-  # Is the header compilable?
-{ echo "$as_me:$LINENO: checking float.h usability" >&5
-echo $ECHO_N "checking float.h usability... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-$ac_includes_default
-#include <float.h>
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ac_header_compiler=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_header_compiler=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
-echo "${ECHO_T}$ac_header_compiler" >&6; }
-
-# Is the header present?
-{ echo "$as_me:$LINENO: checking float.h presence" >&5
-echo $ECHO_N "checking float.h presence... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <float.h>
-_ACEOF
-if { (ac_try="$ac_cpp conftest.$ac_ext"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } >/dev/null && {
-	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       }; then
-  ac_header_preproc=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-  ac_header_preproc=no
-fi
-
-rm -f conftest.err conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
-echo "${ECHO_T}$ac_header_preproc" >&6; }
-
-# So?  What about this header?
-case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
-  yes:no: )
-    { echo "$as_me:$LINENO: WARNING: float.h: accepted by the compiler, rejected by the preprocessor!" >&5
-echo "$as_me: WARNING: float.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
-    { echo "$as_me:$LINENO: WARNING: float.h: proceeding with the compiler's result" >&5
-echo "$as_me: WARNING: float.h: proceeding with the compiler's result" >&2;}
-    ac_header_preproc=yes
-    ;;
-  no:yes:* )
-    { echo "$as_me:$LINENO: WARNING: float.h: present but cannot be compiled" >&5
-echo "$as_me: WARNING: float.h: present but cannot be compiled" >&2;}
-    { echo "$as_me:$LINENO: WARNING: float.h:     check for missing prerequisite headers?" >&5
-echo "$as_me: WARNING: float.h:     check for missing prerequisite headers?" >&2;}
-    { echo "$as_me:$LINENO: WARNING: float.h: see the Autoconf documentation" >&5
-echo "$as_me: WARNING: float.h: see the Autoconf documentation" >&2;}
-    { echo "$as_me:$LINENO: WARNING: float.h:     section \"Present But Cannot Be Compiled\"" >&5
-echo "$as_me: WARNING: float.h:     section \"Present But Cannot Be Compiled\"" >&2;}
-    { echo "$as_me:$LINENO: WARNING: float.h: proceeding with the preprocessor's result" >&5
-echo "$as_me: WARNING: float.h: proceeding with the preprocessor's result" >&2;}
-    { echo "$as_me:$LINENO: WARNING: float.h: in the future, the compiler will take precedence" >&5
-echo "$as_me: WARNING: float.h: in the future, the compiler will take precedence" >&2;}
-
-    ;;
-esac
-{ echo "$as_me:$LINENO: checking for float.h" >&5
-echo $ECHO_N "checking for float.h... $ECHO_C" >&6; }
-if test "${ac_cv_header_float_h+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_cv_header_float_h=$ac_header_preproc
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_float_h" >&5
-echo "${ECHO_T}$ac_cv_header_float_h" >&6; }
-
-fi
-if test $ac_cv_header_float_h = yes; then
-  :
-else
-
-cat >>confdefs.h <<\_ACEOF
-#define NO_FLOAT_H 1
-_ACEOF
-
-fi
-
-
-    if test "${ac_cv_header_values_h+set}" = set; then
-  { echo "$as_me:$LINENO: checking for values.h" >&5
-echo $ECHO_N "checking for values.h... $ECHO_C" >&6; }
-if test "${ac_cv_header_values_h+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_values_h" >&5
-echo "${ECHO_T}$ac_cv_header_values_h" >&6; }
-else
-  # Is the header compilable?
-{ echo "$as_me:$LINENO: checking values.h usability" >&5
-echo $ECHO_N "checking values.h usability... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-$ac_includes_default
-#include <values.h>
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ac_header_compiler=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_header_compiler=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
-echo "${ECHO_T}$ac_header_compiler" >&6; }
-
-# Is the header present?
-{ echo "$as_me:$LINENO: checking values.h presence" >&5
-echo $ECHO_N "checking values.h presence... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <values.h>
-_ACEOF
-if { (ac_try="$ac_cpp conftest.$ac_ext"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } >/dev/null && {
-	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       }; then
-  ac_header_preproc=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-  ac_header_preproc=no
-fi
-
-rm -f conftest.err conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
-echo "${ECHO_T}$ac_header_preproc" >&6; }
-
-# So?  What about this header?
-case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
-  yes:no: )
-    { echo "$as_me:$LINENO: WARNING: values.h: accepted by the compiler, rejected by the preprocessor!" >&5
-echo "$as_me: WARNING: values.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
-    { echo "$as_me:$LINENO: WARNING: values.h: proceeding with the compiler's result" >&5
-echo "$as_me: WARNING: values.h: proceeding with the compiler's result" >&2;}
-    ac_header_preproc=yes
-    ;;
-  no:yes:* )
-    { echo "$as_me:$LINENO: WARNING: values.h: present but cannot be compiled" >&5
-echo "$as_me: WARNING: values.h: present but cannot be compiled" >&2;}
-    { echo "$as_me:$LINENO: WARNING: values.h:     check for missing prerequisite headers?" >&5
-echo "$as_me: WARNING: values.h:     check for missing prerequisite headers?" >&2;}
-    { echo "$as_me:$LINENO: WARNING: values.h: see the Autoconf documentation" >&5
-echo "$as_me: WARNING: values.h: see the Autoconf documentation" >&2;}
-    { echo "$as_me:$LINENO: WARNING: values.h:     section \"Present But Cannot Be Compiled\"" >&5
-echo "$as_me: WARNING: values.h:     section \"Present But Cannot Be Compiled\"" >&2;}
-    { echo "$as_me:$LINENO: WARNING: values.h: proceeding with the preprocessor's result" >&5
-echo "$as_me: WARNING: values.h: proceeding with the preprocessor's result" >&2;}
-    { echo "$as_me:$LINENO: WARNING: values.h: in the future, the compiler will take precedence" >&5
-echo "$as_me: WARNING: values.h: in the future, the compiler will take precedence" >&2;}
-
-    ;;
-esac
-{ echo "$as_me:$LINENO: checking for values.h" >&5
-echo $ECHO_N "checking for values.h... $ECHO_C" >&6; }
-if test "${ac_cv_header_values_h+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_cv_header_values_h=$ac_header_preproc
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_values_h" >&5
-echo "${ECHO_T}$ac_cv_header_values_h" >&6; }
-
-fi
-if test $ac_cv_header_values_h = yes; then
-  :
-else
-
-cat >>confdefs.h <<\_ACEOF
-#define NO_VALUES_H 1
-_ACEOF
-
-fi
-
-
-    if test "${ac_cv_header_limits_h+set}" = set; then
-  { echo "$as_me:$LINENO: checking for limits.h" >&5
-echo $ECHO_N "checking for limits.h... $ECHO_C" >&6; }
-if test "${ac_cv_header_limits_h+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_limits_h" >&5
-echo "${ECHO_T}$ac_cv_header_limits_h" >&6; }
-else
-  # Is the header compilable?
-{ echo "$as_me:$LINENO: checking limits.h usability" >&5
-echo $ECHO_N "checking limits.h usability... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-$ac_includes_default
-#include <limits.h>
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ac_header_compiler=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_header_compiler=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
-echo "${ECHO_T}$ac_header_compiler" >&6; }
-
-# Is the header present?
-{ echo "$as_me:$LINENO: checking limits.h presence" >&5
-echo $ECHO_N "checking limits.h presence... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <limits.h>
-_ACEOF
-if { (ac_try="$ac_cpp conftest.$ac_ext"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } >/dev/null && {
-	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       }; then
-  ac_header_preproc=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-  ac_header_preproc=no
-fi
-
-rm -f conftest.err conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
-echo "${ECHO_T}$ac_header_preproc" >&6; }
-
-# So?  What about this header?
-case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
-  yes:no: )
-    { echo "$as_me:$LINENO: WARNING: limits.h: accepted by the compiler, rejected by the preprocessor!" >&5
-echo "$as_me: WARNING: limits.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
-    { echo "$as_me:$LINENO: WARNING: limits.h: proceeding with the compiler's result" >&5
-echo "$as_me: WARNING: limits.h: proceeding with the compiler's result" >&2;}
-    ac_header_preproc=yes
-    ;;
-  no:yes:* )
-    { echo "$as_me:$LINENO: WARNING: limits.h: present but cannot be compiled" >&5
-echo "$as_me: WARNING: limits.h: present but cannot be compiled" >&2;}
-    { echo "$as_me:$LINENO: WARNING: limits.h:     check for missing prerequisite headers?" >&5
-echo "$as_me: WARNING: limits.h:     check for missing prerequisite headers?" >&2;}
-    { echo "$as_me:$LINENO: WARNING: limits.h: see the Autoconf documentation" >&5
-echo "$as_me: WARNING: limits.h: see the Autoconf documentation" >&2;}
-    { echo "$as_me:$LINENO: WARNING: limits.h:     section \"Present But Cannot Be Compiled\"" >&5
-echo "$as_me: WARNING: limits.h:     section \"Present But Cannot Be Compiled\"" >&2;}
-    { echo "$as_me:$LINENO: WARNING: limits.h: proceeding with the preprocessor's result" >&5
-echo "$as_me: WARNING: limits.h: proceeding with the preprocessor's result" >&2;}
-    { echo "$as_me:$LINENO: WARNING: limits.h: in the future, the compiler will take precedence" >&5
-echo "$as_me: WARNING: limits.h: in the future, the compiler will take precedence" >&2;}
-
-    ;;
-esac
-{ echo "$as_me:$LINENO: checking for limits.h" >&5
-echo $ECHO_N "checking for limits.h... $ECHO_C" >&6; }
-if test "${ac_cv_header_limits_h+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_cv_header_limits_h=$ac_header_preproc
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_limits_h" >&5
-echo "${ECHO_T}$ac_cv_header_limits_h" >&6; }
-
-fi
-if test $ac_cv_header_limits_h = yes; then
-
-cat >>confdefs.h <<\_ACEOF
-#define HAVE_LIMITS_H 1
-_ACEOF
-
-else
-
-cat >>confdefs.h <<\_ACEOF
-#define NO_LIMITS_H 1
-_ACEOF
-
-fi
-
-
-    if test "${ac_cv_header_stdlib_h+set}" = set; then
-  { echo "$as_me:$LINENO: checking for stdlib.h" >&5
-echo $ECHO_N "checking for stdlib.h... $ECHO_C" >&6; }
-if test "${ac_cv_header_stdlib_h+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_stdlib_h" >&5
-echo "${ECHO_T}$ac_cv_header_stdlib_h" >&6; }
-else
-  # Is the header compilable?
-{ echo "$as_me:$LINENO: checking stdlib.h usability" >&5
-echo $ECHO_N "checking stdlib.h usability... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-$ac_includes_default
-#include <stdlib.h>
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ac_header_compiler=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_header_compiler=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
-echo "${ECHO_T}$ac_header_compiler" >&6; }
-
-# Is the header present?
-{ echo "$as_me:$LINENO: checking stdlib.h presence" >&5
-echo $ECHO_N "checking stdlib.h presence... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <stdlib.h>
-_ACEOF
-if { (ac_try="$ac_cpp conftest.$ac_ext"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } >/dev/null && {
-	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       }; then
-  ac_header_preproc=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-  ac_header_preproc=no
-fi
-
-rm -f conftest.err conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
-echo "${ECHO_T}$ac_header_preproc" >&6; }
-
-# So?  What about this header?
-case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
-  yes:no: )
-    { echo "$as_me:$LINENO: WARNING: stdlib.h: accepted by the compiler, rejected by the preprocessor!" >&5
-echo "$as_me: WARNING: stdlib.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
-    { echo "$as_me:$LINENO: WARNING: stdlib.h: proceeding with the compiler's result" >&5
-echo "$as_me: WARNING: stdlib.h: proceeding with the compiler's result" >&2;}
-    ac_header_preproc=yes
-    ;;
-  no:yes:* )
-    { echo "$as_me:$LINENO: WARNING: stdlib.h: present but cannot be compiled" >&5
-echo "$as_me: WARNING: stdlib.h: present but cannot be compiled" >&2;}
-    { echo "$as_me:$LINENO: WARNING: stdlib.h:     check for missing prerequisite headers?" >&5
-echo "$as_me: WARNING: stdlib.h:     check for missing prerequisite headers?" >&2;}
-    { echo "$as_me:$LINENO: WARNING: stdlib.h: see the Autoconf documentation" >&5
-echo "$as_me: WARNING: stdlib.h: see the Autoconf documentation" >&2;}
-    { echo "$as_me:$LINENO: WARNING: stdlib.h:     section \"Present But Cannot Be Compiled\"" >&5
-echo "$as_me: WARNING: stdlib.h:     section \"Present But Cannot Be Compiled\"" >&2;}
-    { echo "$as_me:$LINENO: WARNING: stdlib.h: proceeding with the preprocessor's result" >&5
-echo "$as_me: WARNING: stdlib.h: proceeding with the preprocessor's result" >&2;}
-    { echo "$as_me:$LINENO: WARNING: stdlib.h: in the future, the compiler will take precedence" >&5
-echo "$as_me: WARNING: stdlib.h: in the future, the compiler will take precedence" >&2;}
-
-    ;;
-esac
-{ echo "$as_me:$LINENO: checking for stdlib.h" >&5
-echo $ECHO_N "checking for stdlib.h... $ECHO_C" >&6; }
-if test "${ac_cv_header_stdlib_h+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_cv_header_stdlib_h=$ac_header_preproc
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_stdlib_h" >&5
-echo "${ECHO_T}$ac_cv_header_stdlib_h" >&6; }
-
-fi
-if test $ac_cv_header_stdlib_h = yes; then
-  tcl_ok=1
-else
-  tcl_ok=0
-fi
-
-
-    cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <stdlib.h>
-
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-  $EGREP "strtol" >/dev/null 2>&1; then
-  :
-else
-  tcl_ok=0
-fi
-rm -f conftest*
-
-    cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <stdlib.h>
-
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-  $EGREP "strtoul" >/dev/null 2>&1; then
-  :
-else
-  tcl_ok=0
-fi
-rm -f conftest*
-
-    cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <stdlib.h>
-
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-  $EGREP "strtod" >/dev/null 2>&1; then
-  :
-else
-  tcl_ok=0
-fi
-rm -f conftest*
-
-    if test $tcl_ok = 0; then
-
-cat >>confdefs.h <<\_ACEOF
-#define NO_STDLIB_H 1
-_ACEOF
-
-    fi
-    if test "${ac_cv_header_string_h+set}" = set; then
-  { echo "$as_me:$LINENO: checking for string.h" >&5
-echo $ECHO_N "checking for string.h... $ECHO_C" >&6; }
-if test "${ac_cv_header_string_h+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_string_h" >&5
-echo "${ECHO_T}$ac_cv_header_string_h" >&6; }
-else
-  # Is the header compilable?
-{ echo "$as_me:$LINENO: checking string.h usability" >&5
-echo $ECHO_N "checking string.h usability... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-$ac_includes_default
-#include <string.h>
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ac_header_compiler=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_header_compiler=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
-echo "${ECHO_T}$ac_header_compiler" >&6; }
-
-# Is the header present?
-{ echo "$as_me:$LINENO: checking string.h presence" >&5
-echo $ECHO_N "checking string.h presence... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <string.h>
-_ACEOF
-if { (ac_try="$ac_cpp conftest.$ac_ext"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } >/dev/null && {
-	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       }; then
-  ac_header_preproc=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-  ac_header_preproc=no
-fi
-
-rm -f conftest.err conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
-echo "${ECHO_T}$ac_header_preproc" >&6; }
-
-# So?  What about this header?
-case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
-  yes:no: )
-    { echo "$as_me:$LINENO: WARNING: string.h: accepted by the compiler, rejected by the preprocessor!" >&5
-echo "$as_me: WARNING: string.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
-    { echo "$as_me:$LINENO: WARNING: string.h: proceeding with the compiler's result" >&5
-echo "$as_me: WARNING: string.h: proceeding with the compiler's result" >&2;}
-    ac_header_preproc=yes
-    ;;
-  no:yes:* )
-    { echo "$as_me:$LINENO: WARNING: string.h: present but cannot be compiled" >&5
-echo "$as_me: WARNING: string.h: present but cannot be compiled" >&2;}
-    { echo "$as_me:$LINENO: WARNING: string.h:     check for missing prerequisite headers?" >&5
-echo "$as_me: WARNING: string.h:     check for missing prerequisite headers?" >&2;}
-    { echo "$as_me:$LINENO: WARNING: string.h: see the Autoconf documentation" >&5
-echo "$as_me: WARNING: string.h: see the Autoconf documentation" >&2;}
-    { echo "$as_me:$LINENO: WARNING: string.h:     section \"Present But Cannot Be Compiled\"" >&5
-echo "$as_me: WARNING: string.h:     section \"Present But Cannot Be Compiled\"" >&2;}
-    { echo "$as_me:$LINENO: WARNING: string.h: proceeding with the preprocessor's result" >&5
-echo "$as_me: WARNING: string.h: proceeding with the preprocessor's result" >&2;}
-    { echo "$as_me:$LINENO: WARNING: string.h: in the future, the compiler will take precedence" >&5
-echo "$as_me: WARNING: string.h: in the future, the compiler will take precedence" >&2;}
-
-    ;;
-esac
-{ echo "$as_me:$LINENO: checking for string.h" >&5
-echo $ECHO_N "checking for string.h... $ECHO_C" >&6; }
-if test "${ac_cv_header_string_h+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_cv_header_string_h=$ac_header_preproc
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_string_h" >&5
-echo "${ECHO_T}$ac_cv_header_string_h" >&6; }
-
-fi
-if test $ac_cv_header_string_h = yes; then
-  tcl_ok=1
-else
-  tcl_ok=0
-fi
-
-
-    cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <string.h>
-
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-  $EGREP "strstr" >/dev/null 2>&1; then
-  :
-else
-  tcl_ok=0
-fi
-rm -f conftest*
-
-    cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <string.h>
-
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-  $EGREP "strerror" >/dev/null 2>&1; then
-  :
-else
-  tcl_ok=0
-fi
-rm -f conftest*
-
-
-    # See also memmove check below for a place where NO_STRING_H can be
-    # set and why.
-
-    if test $tcl_ok = 0; then
-
-cat >>confdefs.h <<\_ACEOF
-#define NO_STRING_H 1
-_ACEOF
-
-    fi
-
-    if test "${ac_cv_header_sys_wait_h+set}" = set; then
-  { echo "$as_me:$LINENO: checking for sys/wait.h" >&5
-echo $ECHO_N "checking for sys/wait.h... $ECHO_C" >&6; }
-if test "${ac_cv_header_sys_wait_h+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_sys_wait_h" >&5
-echo "${ECHO_T}$ac_cv_header_sys_wait_h" >&6; }
-else
-  # Is the header compilable?
-{ echo "$as_me:$LINENO: checking sys/wait.h usability" >&5
-echo $ECHO_N "checking sys/wait.h usability... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-$ac_includes_default
-#include <sys/wait.h>
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ac_header_compiler=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_header_compiler=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
-echo "${ECHO_T}$ac_header_compiler" >&6; }
-
-# Is the header present?
-{ echo "$as_me:$LINENO: checking sys/wait.h presence" >&5
-echo $ECHO_N "checking sys/wait.h presence... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <sys/wait.h>
-_ACEOF
-if { (ac_try="$ac_cpp conftest.$ac_ext"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } >/dev/null && {
-	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       }; then
-  ac_header_preproc=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-  ac_header_preproc=no
-fi
-
-rm -f conftest.err conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
-echo "${ECHO_T}$ac_header_preproc" >&6; }
-
-# So?  What about this header?
-case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
-  yes:no: )
-    { echo "$as_me:$LINENO: WARNING: sys/wait.h: accepted by the compiler, rejected by the preprocessor!" >&5
-echo "$as_me: WARNING: sys/wait.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
-    { echo "$as_me:$LINENO: WARNING: sys/wait.h: proceeding with the compiler's result" >&5
-echo "$as_me: WARNING: sys/wait.h: proceeding with the compiler's result" >&2;}
-    ac_header_preproc=yes
-    ;;
-  no:yes:* )
-    { echo "$as_me:$LINENO: WARNING: sys/wait.h: present but cannot be compiled" >&5
-echo "$as_me: WARNING: sys/wait.h: present but cannot be compiled" >&2;}
-    { echo "$as_me:$LINENO: WARNING: sys/wait.h:     check for missing prerequisite headers?" >&5
-echo "$as_me: WARNING: sys/wait.h:     check for missing prerequisite headers?" >&2;}
-    { echo "$as_me:$LINENO: WARNING: sys/wait.h: see the Autoconf documentation" >&5
-echo "$as_me: WARNING: sys/wait.h: see the Autoconf documentation" >&2;}
-    { echo "$as_me:$LINENO: WARNING: sys/wait.h:     section \"Present But Cannot Be Compiled\"" >&5
-echo "$as_me: WARNING: sys/wait.h:     section \"Present But Cannot Be Compiled\"" >&2;}
-    { echo "$as_me:$LINENO: WARNING: sys/wait.h: proceeding with the preprocessor's result" >&5
-echo "$as_me: WARNING: sys/wait.h: proceeding with the preprocessor's result" >&2;}
-    { echo "$as_me:$LINENO: WARNING: sys/wait.h: in the future, the compiler will take precedence" >&5
-echo "$as_me: WARNING: sys/wait.h: in the future, the compiler will take precedence" >&2;}
-
-    ;;
-esac
-{ echo "$as_me:$LINENO: checking for sys/wait.h" >&5
-echo $ECHO_N "checking for sys/wait.h... $ECHO_C" >&6; }
-if test "${ac_cv_header_sys_wait_h+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_cv_header_sys_wait_h=$ac_header_preproc
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_sys_wait_h" >&5
-echo "${ECHO_T}$ac_cv_header_sys_wait_h" >&6; }
-
-fi
-if test $ac_cv_header_sys_wait_h = yes; then
-  :
-else
-
-cat >>confdefs.h <<\_ACEOF
-#define NO_SYS_WAIT_H 1
-_ACEOF
-
-fi
-
-
-    if test "${ac_cv_header_dlfcn_h+set}" = set; then
-  { echo "$as_me:$LINENO: checking for dlfcn.h" >&5
-echo $ECHO_N "checking for dlfcn.h... $ECHO_C" >&6; }
-if test "${ac_cv_header_dlfcn_h+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_dlfcn_h" >&5
-echo "${ECHO_T}$ac_cv_header_dlfcn_h" >&6; }
-else
-  # Is the header compilable?
-{ echo "$as_me:$LINENO: checking dlfcn.h usability" >&5
-echo $ECHO_N "checking dlfcn.h usability... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-$ac_includes_default
-#include <dlfcn.h>
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ac_header_compiler=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_header_compiler=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
-echo "${ECHO_T}$ac_header_compiler" >&6; }
-
-# Is the header present?
-{ echo "$as_me:$LINENO: checking dlfcn.h presence" >&5
-echo $ECHO_N "checking dlfcn.h presence... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <dlfcn.h>
-_ACEOF
-if { (ac_try="$ac_cpp conftest.$ac_ext"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } >/dev/null && {
-	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       }; then
-  ac_header_preproc=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-  ac_header_preproc=no
-fi
-
-rm -f conftest.err conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
-echo "${ECHO_T}$ac_header_preproc" >&6; }
-
-# So?  What about this header?
-case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
-  yes:no: )
-    { echo "$as_me:$LINENO: WARNING: dlfcn.h: accepted by the compiler, rejected by the preprocessor!" >&5
-echo "$as_me: WARNING: dlfcn.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
-    { echo "$as_me:$LINENO: WARNING: dlfcn.h: proceeding with the compiler's result" >&5
-echo "$as_me: WARNING: dlfcn.h: proceeding with the compiler's result" >&2;}
-    ac_header_preproc=yes
-    ;;
-  no:yes:* )
-    { echo "$as_me:$LINENO: WARNING: dlfcn.h: present but cannot be compiled" >&5
-echo "$as_me: WARNING: dlfcn.h: present but cannot be compiled" >&2;}
-    { echo "$as_me:$LINENO: WARNING: dlfcn.h:     check for missing prerequisite headers?" >&5
-echo "$as_me: WARNING: dlfcn.h:     check for missing prerequisite headers?" >&2;}
-    { echo "$as_me:$LINENO: WARNING: dlfcn.h: see the Autoconf documentation" >&5
-echo "$as_me: WARNING: dlfcn.h: see the Autoconf documentation" >&2;}
-    { echo "$as_me:$LINENO: WARNING: dlfcn.h:     section \"Present But Cannot Be Compiled\"" >&5
-echo "$as_me: WARNING: dlfcn.h:     section \"Present But Cannot Be Compiled\"" >&2;}
-    { echo "$as_me:$LINENO: WARNING: dlfcn.h: proceeding with the preprocessor's result" >&5
-echo "$as_me: WARNING: dlfcn.h: proceeding with the preprocessor's result" >&2;}
-    { echo "$as_me:$LINENO: WARNING: dlfcn.h: in the future, the compiler will take precedence" >&5
-echo "$as_me: WARNING: dlfcn.h: in the future, the compiler will take precedence" >&2;}
-
-    ;;
-esac
-{ echo "$as_me:$LINENO: checking for dlfcn.h" >&5
-echo $ECHO_N "checking for dlfcn.h... $ECHO_C" >&6; }
-if test "${ac_cv_header_dlfcn_h+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_cv_header_dlfcn_h=$ac_header_preproc
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_dlfcn_h" >&5
-echo "${ECHO_T}$ac_cv_header_dlfcn_h" >&6; }
-
-fi
-if test $ac_cv_header_dlfcn_h = yes; then
-  :
-else
-
-cat >>confdefs.h <<\_ACEOF
-#define NO_DLFCN_H 1
-_ACEOF
-
-fi
-
-
-
-    # OS/390 lacks sys/param.h (and doesn't need it, by chance).
-
-for ac_header in sys/param.h
-do
-as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
-if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
-  { echo "$as_me:$LINENO: checking for $ac_header" >&5
-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
-if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-fi
-ac_res=`eval echo '${'$as_ac_Header'}'`
-	       { echo "$as_me:$LINENO: result: $ac_res" >&5
-echo "${ECHO_T}$ac_res" >&6; }
-else
-  # Is the header compilable?
-{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
-echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-$ac_includes_default
-#include <$ac_header>
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ac_header_compiler=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_header_compiler=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
-echo "${ECHO_T}$ac_header_compiler" >&6; }
-
-# Is the header present?
-{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
-echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <$ac_header>
-_ACEOF
-if { (ac_try="$ac_cpp conftest.$ac_ext"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } >/dev/null && {
-	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       }; then
-  ac_header_preproc=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-  ac_header_preproc=no
-fi
-
-rm -f conftest.err conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
-echo "${ECHO_T}$ac_header_preproc" >&6; }
-
-# So?  What about this header?
-case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
-  yes:no: )
-    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
-echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
-    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
-echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
-    ac_header_preproc=yes
-    ;;
-  no:yes:* )
-    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
-echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
-    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
-echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
-    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
-echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
-    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
-echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
-    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
-echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
-    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
-echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
-
-    ;;
-esac
-{ echo "$as_me:$LINENO: checking for $ac_header" >&5
-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
-if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  eval "$as_ac_Header=\$ac_header_preproc"
-fi
-ac_res=`eval echo '${'$as_ac_Header'}'`
-	       { echo "$as_me:$LINENO: result: $ac_res" >&5
-echo "${ECHO_T}$ac_res" >&6; }
-
-fi
-if test `eval echo '${'$as_ac_Header'}'` = yes; then
-  cat >>confdefs.h <<_ACEOF
-#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
-_ACEOF
-
-fi
-
-done
-
-
-	# Let the user call this, because if it triggers, they will
-	# need a compat/strtod.c that is correct.  Users can also
-	# use Tcl_GetDouble(FromObj) instead.
-	#TEA_BUGGY_STRTOD
-    fi
-
-
-#-----------------------------------------------------------------------
-# Specify the C source files to compile in TEA_ADD_SOURCES,
-# public headers that need to be installed in TEA_ADD_HEADERS,
-# stub library C source files to compile in TEA_ADD_STUB_SOURCES,
-# and runtime Tcl library files in TEA_ADD_TCL_SOURCES.
-# This defines PKG(_STUB)_SOURCES, PKG(_STUB)_OBJECTS, PKG_HEADERS
-# and PKG_TCL_SOURCES.
-#-----------------------------------------------------------------------
-
-
-#    vars="tclxml.c docObj.c tclxml-libxml2.c nodeObj.c tcldom-libxml2.c tclxslt-libxslt.c"
-    vars="tclxml.c docObj.c tclxml-libxml2.c"
-    for i in $vars; do
-	case $i in
-	    \$*)
-		# allow $-var names
-		PKG_SOURCES="$PKG_SOURCES $i"
-		PKG_OBJECTS="$PKG_OBJECTS $i"
-		;;
-	    *)
-		# check for existence - allows for generic/win/unix VPATH
-		if test ! -f "${srcdir}/$i" -a ! -f "${srcdir}/generic/$i" \
-		    -a ! -f "${srcdir}/win/$i" -a ! -f "${srcdir}/unix/$i" \
-		    ; then
-		    { { echo "$as_me:$LINENO: error: could not find source file '$i'" >&5
-echo "$as_me: error: could not find source file '$i'" >&2;}
-   { (exit 1); exit 1; }; }
-		fi
-		PKG_SOURCES="$PKG_SOURCES $i"
-		# this assumes it is in a VPATH dir
-		i=`basename $i`
-		# handle user calling this before or after TEA_SETUP_COMPILER
-		if test x"${OBJEXT}" != x ; then
-		    j="`echo $i | sed -e 's/\.[^.]*$//'`.${OBJEXT}"
-		else
-		    j="`echo $i | sed -e 's/\.[^.]*$//'`.\${OBJEXT}"
-		fi
-		PKG_OBJECTS="$PKG_OBJECTS $j"
-		;;
-	esac
-    done
-
-
-
-
-#    vars="include/tclxml-libxml2/docObj.h include/tclxml-libxml2/tclxml-libxml2.h include/tcldom/tcldom.h include/tcldom-libxml2/tcldom-libxml2.h include/tclxslt/tclxslt.h"
-    vars="include/tclxml-libxml2/docObj.h include/tclxml-libxml2/tclxml-libxml2.h"
-    for i in $vars; do
-	# check for existence, be strict because it is installed
-	if test ! -f "${srcdir}/$i" ; then
-	    { { echo "$as_me:$LINENO: error: could not find header file '${srcdir}/$i'" >&5
-echo "$as_me: error: could not find header file '${srcdir}/$i'" >&2;}
-   { (exit 1); exit 1; }; }
-	fi
-	PKG_HEADERS="$PKG_HEADERS $i"
-    done
-
-
-
-    vars="-Iinclude"
-    for i in $vars; do
-	PKG_INCLUDES="$PKG_INCLUDES $i"
-    done
-
-
-#TEA_ADD_LIBS([-lexslt])
-
-    vars=""
-    for i in $vars; do
-	if test "${TEA_PLATFORM}" = "windows" -a "$GCC" = "yes" ; then
-	    # Convert foo.lib to -lfoo for GCC.  No-op if not *.lib
-	    i=`echo "$i" | sed -e 's/^\([^-].*\)\.lib$/-l\1/i'`
-	fi
-	PKG_LIBS="$PKG_LIBS $i"
-    done
-
-
-
-    PKG_CFLAGS="$PKG_CFLAGS "
-
-
-
-    vars="tclxmlStubInit.c tclxmlStubLib.c"
-    for i in $vars; do
-	# check for existence - allows for generic/win/unix VPATH
-	if test ! -f "${srcdir}/$i" -a ! -f "${srcdir}/generic/$i" \
-	    -a ! -f "${srcdir}/win/$i" -a ! -f "${srcdir}/unix/$i" \
-	    ; then
-	    { { echo "$as_me:$LINENO: error: could not find stub source file '$i'" >&5
-echo "$as_me: error: could not find stub source file '$i'" >&2;}
-   { (exit 1); exit 1; }; }
-	fi
-	PKG_STUB_SOURCES="$PKG_STUB_SOURCES $i"
-	# this assumes it is in a VPATH dir
-	i=`basename $i`
-	# handle user calling this before or after TEA_SETUP_COMPILER
-	if test x"${OBJEXT}" != x ; then
-	    j="`echo $i | sed -e 's/\.[^.]*$//'`.${OBJEXT}"
-	else
-	    j="`echo $i | sed -e 's/\.[^.]*$//'`.\${OBJEXT}"
-	fi
-	PKG_STUB_OBJECTS="$PKG_STUB_OBJECTS $j"
-    done
-
-
-
-
-    vars="tclxml-tcl/xml__tcl.tcl tclxml-tcl/sgml-8.0.tcl tclxml-tcl/sgml-8.1.tcl tclxml-tcl/xml-8.0.tcl tclxml-tcl/xml-8.1.tcl tclxml-tcl/sgmlparser.tcl tclxml-tcl/tclparser-8.0.tcl tclxml-tcl/tclparser-8.1.tcl tclxml-tcl/xmldep.tcl tclxml-tcl/xpath.tcl tcldom-libxml2.tcl tcldom-tcl/xmlswitch.tcl tclxslt/process.tcl tclxslt/resources.tcl tclxslt/utilities.tcl tclxslt/xsltcache.tcl tclxslt-libxslt.tcl"
-    for i in $vars; do
-	# check for existence, be strict because it is installed
-	if test ! -f "${srcdir}/$i" ; then
-	    { { echo "$as_me:$LINENO: error: could not find tcl source file '${srcdir}/$i'" >&5
-echo "$as_me: error: could not find tcl source file '${srcdir}/$i'" >&2;}
-   { (exit 1); exit 1; }; }
-	fi
-	PKG_TCL_SOURCES="$PKG_TCL_SOURCES $i"
-    done
-
-
-
-#--------------------------------------------------------------------
-# A few miscellaneous platform-specific items:
-#
-# We have to define a special symbol for Windows (BUILD_Tclxml in this
-# case) so that we create the export library with the dll.
-#
-# Windows creates a few extra files that need to be cleaned up.
-# We can add more files to clean if our extension creates any extra
-# files in the future.
-#
-# TEA_ADD_* any platform specific compiler/build info here.
-#--------------------------------------------------------------------
-
-CLEANFILES=pkgIndex.tcl
-if test "${TEA_PLATFORM}" = "windows" ; then
-
-cat >>confdefs.h <<\_ACEOF
-#define BUILD_Tclxml 1
-_ACEOF
-
-    CLEANFILES="$CLEANFILES *.lib *.dll *.exp *.ilk *.pdb vc*.pch"
-else
-    :
-fi
-
-
-
-    { echo "$as_me:$LINENO: checking for Tcl public headers" >&5
-echo $ECHO_N "checking for Tcl public headers... $ECHO_C" >&6; }
-
-
-# Check whether --with-tclinclude was given.
-if test "${with_tclinclude+set}" = set; then
-  withval=$with_tclinclude; with_tclinclude=${withval}
-fi
-
-
-    if test "${ac_cv_c_tclh+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-
-	# Use the value from --with-tclinclude, if it was given
-
-	if test x"${with_tclinclude}" != x ; then
-	    if test -f "${with_tclinclude}/tcl.h" ; then
-		ac_cv_c_tclh=${with_tclinclude}
-	    else
-		{ { echo "$as_me:$LINENO: error: ${with_tclinclude} directory does not contain tcl.h" >&5
-echo "$as_me: error: ${with_tclinclude} directory does not contain tcl.h" >&2;}
-   { (exit 1); exit 1; }; }
-	    fi
-	else
-	    if test "`uname -s`" = "Darwin"; then
-		# If Tcl was built as a framework, attempt to use
-		# the framework's Headers directory
-		case ${TCL_DEFS} in
-		    *TCL_FRAMEWORK*)
-			list="`ls -d ${TCL_BIN_DIR}/Headers 2>/dev/null`"
-			;;
-		esac
-	    fi
-
-	    # Look in the source dir only if Tcl is not installed,
-	    # and in that situation, look there before installed locations.
-	    if test -f "${TCL_BIN_DIR}/Makefile" ; then
-		list="$list `ls -d ${TCL_SRC_DIR}/generic 2>/dev/null`"
-	    fi
-
-	    # Check order: pkg --prefix location, Tcl's --prefix location,
-	    # relative to directory of tclConfig.sh.
-
-	    eval "temp_includedir=${includedir}"
-	    list="$list \
-		`ls -d ${temp_includedir}        2>/dev/null` \
-		`ls -d ${TCL_PREFIX}/include     2>/dev/null` \
-		`ls -d ${TCL_BIN_DIR}/../include 2>/dev/null`"
-	    if test "${TEA_PLATFORM}" != "windows" -o "$GCC" = "yes"; then
-		list="$list /usr/local/include /usr/include"
-		if test x"${TCL_INCLUDE_SPEC}" != x ; then
-		    d=`echo "${TCL_INCLUDE_SPEC}" | sed -e 's/^-I//'`
-		    list="$list `ls -d ${d} 2>/dev/null`"
-		fi
-	    fi
-	    for i in $list ; do
-		if test -f "$i/tcl.h" ; then
-		    ac_cv_c_tclh=$i
-		    break
-		fi
-	    done
-	fi
-
-fi
-
-
-    # Print a message based on how we determined the include path
-
-    if test x"${ac_cv_c_tclh}" = x ; then
-	{ { echo "$as_me:$LINENO: error: tcl.h not found.  Please specify its location with --with-tclinclude" >&5
-echo "$as_me: error: tcl.h not found.  Please specify its location with --with-tclinclude" >&2;}
-   { (exit 1); exit 1; }; }
-    else
-	{ echo "$as_me:$LINENO: result: ${ac_cv_c_tclh}" >&5
-echo "${ECHO_T}${ac_cv_c_tclh}" >&6; }
-    fi
-
-    # Convert to a native path and substitute into the output files.
-
-    INCLUDE_DIR_NATIVE=`${CYGPATH} ${ac_cv_c_tclh}`
-
-    TCL_INCLUDES=-I\"${INCLUDE_DIR_NATIVE}\"
-
-
-
-
-#--------------------------------------------------------------------
-# Check whether --enable-threads or --disable-threads was given.
-# So far only Tcl responds to this one.
-#--------------------------------------------------------------------
-
-
-    # Check whether --enable-threads was given.
-if test "${enable_threads+set}" = set; then
-  enableval=$enable_threads; tcl_ok=$enableval
-else
-  tcl_ok=yes
-fi
-
-
-    if test "${enable_threads+set}" = set; then
-	enableval="$enable_threads"
-	tcl_ok=$enableval
-    else
-	tcl_ok=yes
-    fi
-
-    if test "$tcl_ok" = "yes" -o "${TCL_THREADS}" = 1; then
-	TCL_THREADS=1
-
-	if test "${TEA_PLATFORM}" != "windows" ; then
-	    # We are always OK on Windows, so check what this platform wants:
-
-	    # USE_THREAD_ALLOC tells us to try the special thread-based
-	    # allocator that significantly reduces lock contention
-
-cat >>confdefs.h <<\_ACEOF
-#define USE_THREAD_ALLOC 1
-_ACEOF
-
-
-cat >>confdefs.h <<\_ACEOF
-#define _REENTRANT 1
-_ACEOF
-
-	    if test "`uname -s`" = "SunOS" ; then
-
-cat >>confdefs.h <<\_ACEOF
-#define _POSIX_PTHREAD_SEMANTICS 1
-_ACEOF
-
-	    fi
-
-cat >>confdefs.h <<\_ACEOF
-#define _THREAD_SAFE 1
-_ACEOF
-
-	    { echo "$as_me:$LINENO: checking for pthread_mutex_init in -lpthread" >&5
-echo $ECHO_N "checking for pthread_mutex_init in -lpthread... $ECHO_C" >&6; }
-if test "${ac_cv_lib_pthread_pthread_mutex_init+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-lpthread  $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-/* Override any GCC internal prototype to avoid an error.
-   Use char because int might match the return type of a GCC
-   builtin and then its argument prototype would still apply.  */
-#ifdef __cplusplus
-extern "C"
-#endif
-char pthread_mutex_init ();
-int
-main ()
-{
-return pthread_mutex_init ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_pthread_pthread_mutex_init=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_lib_pthread_pthread_mutex_init=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_pthread_pthread_mutex_init" >&5
-echo "${ECHO_T}$ac_cv_lib_pthread_pthread_mutex_init" >&6; }
-if test $ac_cv_lib_pthread_pthread_mutex_init = yes; then
-  tcl_ok=yes
-else
-  tcl_ok=no
-fi
-
-	    if test "$tcl_ok" = "no"; then
-		# Check a little harder for __pthread_mutex_init in the same
-		# library, as some systems hide it there until pthread.h is
-		# defined.  We could alternatively do an AC_TRY_COMPILE with
-		# pthread.h, but that will work with libpthread really doesn't
-		# exist, like AIX 4.2.  [Bug: 4359]
-		{ echo "$as_me:$LINENO: checking for __pthread_mutex_init in -lpthread" >&5
-echo $ECHO_N "checking for __pthread_mutex_init in -lpthread... $ECHO_C" >&6; }
-if test "${ac_cv_lib_pthread___pthread_mutex_init+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-lpthread  $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-/* Override any GCC internal prototype to avoid an error.
-   Use char because int might match the return type of a GCC
-   builtin and then its argument prototype would still apply.  */
-#ifdef __cplusplus
-extern "C"
-#endif
-char __pthread_mutex_init ();
-int
-main ()
-{
-return __pthread_mutex_init ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_pthread___pthread_mutex_init=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_lib_pthread___pthread_mutex_init=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_pthread___pthread_mutex_init" >&5
-echo "${ECHO_T}$ac_cv_lib_pthread___pthread_mutex_init" >&6; }
-if test $ac_cv_lib_pthread___pthread_mutex_init = yes; then
-  tcl_ok=yes
-else
-  tcl_ok=no
-fi
-
-	    fi
-
-	    if test "$tcl_ok" = "yes"; then
-		# The space is needed
-		THREADS_LIBS=" -lpthread"
-	    else
-		{ echo "$as_me:$LINENO: checking for pthread_mutex_init in -lpthreads" >&5
-echo $ECHO_N "checking for pthread_mutex_init in -lpthreads... $ECHO_C" >&6; }
-if test "${ac_cv_lib_pthreads_pthread_mutex_init+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-lpthreads  $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-/* Override any GCC internal prototype to avoid an error.
-   Use char because int might match the return type of a GCC
-   builtin and then its argument prototype would still apply.  */
-#ifdef __cplusplus
-extern "C"
-#endif
-char pthread_mutex_init ();
-int
-main ()
-{
-return pthread_mutex_init ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_pthreads_pthread_mutex_init=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_lib_pthreads_pthread_mutex_init=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_pthreads_pthread_mutex_init" >&5
-echo "${ECHO_T}$ac_cv_lib_pthreads_pthread_mutex_init" >&6; }
-if test $ac_cv_lib_pthreads_pthread_mutex_init = yes; then
-  tcl_ok=yes
-else
-  tcl_ok=no
-fi
-
-		if test "$tcl_ok" = "yes"; then
-		    # The space is needed
-		    THREADS_LIBS=" -lpthreads"
-		else
-		    { echo "$as_me:$LINENO: checking for pthread_mutex_init in -lc" >&5
-echo $ECHO_N "checking for pthread_mutex_init in -lc... $ECHO_C" >&6; }
-if test "${ac_cv_lib_c_pthread_mutex_init+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-lc  $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-/* Override any GCC internal prototype to avoid an error.
-   Use char because int might match the return type of a GCC
-   builtin and then its argument prototype would still apply.  */
-#ifdef __cplusplus
-extern "C"
-#endif
-char pthread_mutex_init ();
-int
-main ()
-{
-return pthread_mutex_init ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_c_pthread_mutex_init=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_lib_c_pthread_mutex_init=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_c_pthread_mutex_init" >&5
-echo "${ECHO_T}$ac_cv_lib_c_pthread_mutex_init" >&6; }
-if test $ac_cv_lib_c_pthread_mutex_init = yes; then
-  tcl_ok=yes
-else
-  tcl_ok=no
-fi
-
-		    if test "$tcl_ok" = "no"; then
-			{ echo "$as_me:$LINENO: checking for pthread_mutex_init in -lc_r" >&5
-echo $ECHO_N "checking for pthread_mutex_init in -lc_r... $ECHO_C" >&6; }
-if test "${ac_cv_lib_c_r_pthread_mutex_init+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-lc_r  $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-/* Override any GCC internal prototype to avoid an error.
-   Use char because int might match the return type of a GCC
-   builtin and then its argument prototype would still apply.  */
-#ifdef __cplusplus
-extern "C"
-#endif
-char pthread_mutex_init ();
-int
-main ()
-{
-return pthread_mutex_init ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_c_r_pthread_mutex_init=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_lib_c_r_pthread_mutex_init=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_c_r_pthread_mutex_init" >&5
-echo "${ECHO_T}$ac_cv_lib_c_r_pthread_mutex_init" >&6; }
-if test $ac_cv_lib_c_r_pthread_mutex_init = yes; then
-  tcl_ok=yes
-else
-  tcl_ok=no
-fi
-
-			if test "$tcl_ok" = "yes"; then
-			    # The space is needed
-			    THREADS_LIBS=" -pthread"
-			else
-			    TCL_THREADS=0
-			    { echo "$as_me:$LINENO: WARNING: Do not know how to find pthread lib on your system - thread support disabled" >&5
-echo "$as_me: WARNING: Do not know how to find pthread lib on your system - thread support disabled" >&2;}
-			fi
-		    fi
-		fi
-	    fi
-	fi
-    else
-	TCL_THREADS=0
-    fi
-    # Do checking message here to not mess up interleaved configure output
-    { echo "$as_me:$LINENO: checking for building with threads" >&5
-echo $ECHO_N "checking for building with threads... $ECHO_C" >&6; }
-    if test "${TCL_THREADS}" = 1; then
-
-cat >>confdefs.h <<\_ACEOF
-#define TCL_THREADS 1
-_ACEOF
-
-	{ echo "$as_me:$LINENO: result: yes (default)" >&5
-echo "${ECHO_T}yes (default)" >&6; }
-    else
-	{ echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-    fi
-    # TCL_THREADS sanity checking.  See if our request for building with
-    # threads is the same as the way Tcl was built.  If not, warn the user.
-    case ${TCL_DEFS} in
-	*THREADS=1*)
-	    if test "${TCL_THREADS}" = "0"; then
-		{ echo "$as_me:$LINENO: WARNING:
-    Building ${PACKAGE_NAME} without threads enabled, but building against Tcl
-    that IS thread-enabled.  It is recommended to use --enable-threads." >&5
-echo "$as_me: WARNING:
-    Building ${PACKAGE_NAME} without threads enabled, but building against Tcl
-    that IS thread-enabled.  It is recommended to use --enable-threads." >&2;}
-	    fi
-	    ;;
-	*)
-	    if test "${TCL_THREADS}" = "1"; then
-		{ echo "$as_me:$LINENO: WARNING:
-    --enable-threads requested, but building against a Tcl that is NOT
-    thread-enabled.  This is an OK configuration that will also run in
-    a thread-enabled core." >&5
-echo "$as_me: WARNING:
-    --enable-threads requested, but building against a Tcl that is NOT
-    thread-enabled.  This is an OK configuration that will also run in
-    a thread-enabled core." >&2;}
-	    fi
-	    ;;
-    esac
-
-
-
-#--------------------------------------------------------------------
-# The statement below defines a collection of symbols related to
-# building as a shared library instead of a static library.
-#--------------------------------------------------------------------
-
-
-    { echo "$as_me:$LINENO: checking how to build libraries" >&5
-echo $ECHO_N "checking how to build libraries... $ECHO_C" >&6; }
-    # Check whether --enable-shared was given.
-if test "${enable_shared+set}" = set; then
-  enableval=$enable_shared; tcl_ok=$enableval
-else
-  tcl_ok=yes
-fi
-
-
-    if test "${enable_shared+set}" = set; then
-	enableval="$enable_shared"
-	tcl_ok=$enableval
-    else
-	tcl_ok=yes
-    fi
-
-    if test "$tcl_ok" = "yes" ; then
-	{ echo "$as_me:$LINENO: result: shared" >&5
-echo "${ECHO_T}shared" >&6; }
-	SHARED_BUILD=1
-    else
-	{ echo "$as_me:$LINENO: result: static" >&5
-echo "${ECHO_T}static" >&6; }
-	SHARED_BUILD=0
-
-cat >>confdefs.h <<\_ACEOF
-#define STATIC_BUILD 1
-_ACEOF
-
-    fi
-
-
-
-#--------------------------------------------------------------------
-# This macro figures out what flags to use with the compiler/linker
-# when building shared/static debug/optimized objects.  This information
-# can be taken from the tclConfig.sh file, but this figures it all out.
-#--------------------------------------------------------------------
-
-
-
-
-    # Step 0.a: Enable 64 bit support?
-
-    { echo "$as_me:$LINENO: checking if 64bit support is requested" >&5
-echo $ECHO_N "checking if 64bit support is requested... $ECHO_C" >&6; }
-    # Check whether --enable-64bit was given.
-if test "${enable_64bit+set}" = set; then
-  enableval=$enable_64bit; do64bit=$enableval
-else
-  do64bit=no
-fi
-
-    { echo "$as_me:$LINENO: result: $do64bit" >&5
-echo "${ECHO_T}$do64bit" >&6; }
-
-    # Step 0.b: Enable Solaris 64 bit VIS support?
-
-    { echo "$as_me:$LINENO: checking if 64bit Sparc VIS support is requested" >&5
-echo $ECHO_N "checking if 64bit Sparc VIS support is requested... $ECHO_C" >&6; }
-    # Check whether --enable-64bit-vis was given.
-if test "${enable_64bit_vis+set}" = set; then
-  enableval=$enable_64bit_vis; do64bitVIS=$enableval
-else
-  do64bitVIS=no
-fi
-
-    { echo "$as_me:$LINENO: result: $do64bitVIS" >&5
-echo "${ECHO_T}$do64bitVIS" >&6; }
-
-    if test "$do64bitVIS" = "yes"; then
-	# Force 64bit on with VIS
-	do64bit=yes
-    fi
-
-    # Step 0.c: Cross-compiling options for Windows/CE builds?
-
-    if test "${TEA_PLATFORM}" = "windows" ; then
-	{ echo "$as_me:$LINENO: checking if Windows/CE build is requested" >&5
-echo $ECHO_N "checking if Windows/CE build is requested... $ECHO_C" >&6; }
-	# Check whether --enable-wince was given.
-if test "${enable_wince+set}" = set; then
-  enableval=$enable_wince; doWince=$enableval
-else
-  doWince=no
-fi
-
-	{ echo "$as_me:$LINENO: result: $doWince" >&5
-echo "${ECHO_T}$doWince" >&6; }
-    fi
-
-    # Step 1: set the variable "system" to hold the name and version number
-    # for the system.
-
-
-    { echo "$as_me:$LINENO: checking system version" >&5
-echo $ECHO_N "checking system version... $ECHO_C" >&6; }
-if test "${tcl_cv_sys_version+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-
-	if test "${TEA_PLATFORM}" = "windows" ; then
-	    tcl_cv_sys_version=windows
-	elif test -f /usr/lib/NextStep/software_version; then
-	    tcl_cv_sys_version=NEXTSTEP-`awk '/3/,/3/' /usr/lib/NextStep/software_version`
-	else
-	    tcl_cv_sys_version=`uname -s`-`uname -r`
-	    if test "$?" -ne 0 ; then
-		{ echo "$as_me:$LINENO: WARNING: can't find uname command" >&5
-echo "$as_me: WARNING: can't find uname command" >&2;}
-		tcl_cv_sys_version=unknown
-	    else
-		# Special check for weird MP-RAS system (uname returns weird
-		# results, and the version is kept in special file).
-
-		if test -r /etc/.relid -a "X`uname -n`" = "X`uname -s`" ; then
-		    tcl_cv_sys_version=MP-RAS-`awk '{print $3}' /etc/.relid`
-		fi
-		if test "`uname -s`" = "AIX" ; then
-		    tcl_cv_sys_version=AIX-`uname -v`.`uname -r`
-		fi
-	    fi
-	fi
-
-fi
-{ echo "$as_me:$LINENO: result: $tcl_cv_sys_version" >&5
-echo "${ECHO_T}$tcl_cv_sys_version" >&6; }
-    system=$tcl_cv_sys_version
-
-
-    # Step 2: check for existence of -ldl library.  This is needed because
-    # Linux can use either -ldl or -ldld for dynamic loading.
-
-    { echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5
-echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6; }
-if test "${ac_cv_lib_dl_dlopen+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-ldl  $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-/* Override any GCC internal prototype to avoid an error.
-   Use char because int might match the return type of a GCC
-   builtin and then its argument prototype would still apply.  */
-#ifdef __cplusplus
-extern "C"
-#endif
-char dlopen ();
-int
-main ()
-{
-return dlopen ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_dl_dlopen=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_lib_dl_dlopen=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5
-echo "${ECHO_T}$ac_cv_lib_dl_dlopen" >&6; }
-if test $ac_cv_lib_dl_dlopen = yes; then
-  have_dl=yes
-else
-  have_dl=no
-fi
-
-
-    # Require ranlib early so we can override it in special cases below.
-
-
-
-    # Step 3: set configuration options based on system name and version.
-    # This is similar to Tcl's unix/tcl.m4 except that we've added a
-    # "windows" case.
-
-    do64bit_ok=no
-    LDFLAGS_ORIG="$LDFLAGS"
-    # When ld needs options to work in 64-bit mode, put them in
-    # LDFLAGS_ARCH so they eventually end up in LDFLAGS even if [load]
-    # is disabled by the user. [Bug 1016796]
-    LDFLAGS_ARCH=""
-    TCL_EXPORT_FILE_SUFFIX=""
-    UNSHARED_LIB_SUFFIX=""
-    TCL_TRIM_DOTS='`echo ${PACKAGE_VERSION} | tr -d .`'
-    ECHO_VERSION='`echo ${PACKAGE_VERSION}`'
-    TCL_LIB_VERSIONS_OK=ok
-    CFLAGS_DEBUG=-g
-    CFLAGS_OPTIMIZE=-O
-    if test "$GCC" = "yes" ; then
-	CFLAGS_OPTIMIZE=-O2
-	CFLAGS_WARNING="-Wall -Wno-implicit-int"
-    else
-	CFLAGS_WARNING=""
-    fi
-    TCL_NEEDS_EXP_FILE=0
-    TCL_BUILD_EXP_FILE=""
-    TCL_EXP_FILE=""
-    # Extract the first word of "ar", so it can be a program name with args.
-set dummy ar; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
-if test "${ac_cv_prog_AR+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$AR"; then
-  ac_cv_prog_AR="$AR" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_AR="ar"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
-
-fi
-fi
-AR=$ac_cv_prog_AR
-if test -n "$AR"; then
-  { echo "$as_me:$LINENO: result: $AR" >&5
-echo "${ECHO_T}$AR" >&6; }
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-fi
-
-
-    STLIB_LD='${AR} cr'
-    LD_LIBRARY_PATH_VAR="LD_LIBRARY_PATH"
-    case $system in
-	windows)
-	    # This is a 2-stage check to make sure we have the 64-bit SDK
-	    # We have to know where the SDK is installed.
-	    # This magic is based on MS Platform SDK for Win2003 SP1 - hobbs
-	    # MACHINE is IX86 for LINK, but this is used by the manifest,
-	    # which requires x86|amd64|ia64.
-	    MACHINE="X86"
-	    if test "$do64bit" != "no" ; then
-		if test "x${MSSDK}x" = "xx" ; then
-		    MSSDK="C:/Progra~1/Microsoft Platform SDK"
-		fi
-		MSSDK=`echo "$MSSDK" | sed -e  's!\\\!/!g'`
-		PATH64=""
-		case "$do64bit" in
-		    amd64|x64|yes)
-			MACHINE="AMD64" ; # default to AMD64 64-bit build
-			PATH64="${MSSDK}/Bin/Win64/x86/AMD64"
-			;;
-		    ia64)
-			MACHINE="IA64"
-			PATH64="${MSSDK}/Bin/Win64"
-			;;
-		esac
-		if test ! -d "${PATH64}" ; then
-		    { echo "$as_me:$LINENO: WARNING: Could not find 64-bit $MACHINE SDK to enable 64bit mode" >&5
-echo "$as_me: WARNING: Could not find 64-bit $MACHINE SDK to enable 64bit mode" >&2;}
-		    { echo "$as_me:$LINENO: WARNING: Ensure latest Platform SDK is installed" >&5
-echo "$as_me: WARNING: Ensure latest Platform SDK is installed" >&2;}
-		    do64bit="no"
-		else
-		    { echo "$as_me:$LINENO: result:    Using 64-bit $MACHINE mode" >&5
-echo "${ECHO_T}   Using 64-bit $MACHINE mode" >&6; }
-		    do64bit_ok="yes"
-		fi
-	    fi
-
-	    if test "$doWince" != "no" ; then
-		if test "$do64bit" != "no" ; then
-		    { { echo "$as_me:$LINENO: error: Windows/CE and 64-bit builds incompatible" >&5
-echo "$as_me: error: Windows/CE and 64-bit builds incompatible" >&2;}
-   { (exit 1); exit 1; }; }
-		fi
-		if test "$GCC" = "yes" ; then
-		    { { echo "$as_me:$LINENO: error: Windows/CE and GCC builds incompatible" >&5
-echo "$as_me: error: Windows/CE and GCC builds incompatible" >&2;}
-   { (exit 1); exit 1; }; }
-		fi
-
-    # First, look for one uninstalled.
-    # the alternative search directory is invoked by --with-celib
-
-    if test x"${no_celib}" = x ; then
-	# we reset no_celib in case something fails here
-	no_celib=true
-
-# Check whether --with-celib was given.
-if test "${with_celib+set}" = set; then
-  withval=$with_celib; with_celibconfig=${withval}
-fi
-
-	{ echo "$as_me:$LINENO: checking for Windows/CE celib directory" >&5
-echo $ECHO_N "checking for Windows/CE celib directory... $ECHO_C" >&6; }
-	if test "${ac_cv_c_celibconfig+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-
-	    # First check to see if --with-celibconfig was specified.
-	    if test x"${with_celibconfig}" != x ; then
-		if test -d "${with_celibconfig}/inc" ; then
-		    ac_cv_c_celibconfig=`(cd ${with_celibconfig}; pwd)`
-		else
-		    { { echo "$as_me:$LINENO: error: ${with_celibconfig} directory doesn't contain inc directory" >&5
-echo "$as_me: error: ${with_celibconfig} directory doesn't contain inc directory" >&2;}
-   { (exit 1); exit 1; }; }
-		fi
-	    fi
-
-	    # then check for a celib library
-	    if test x"${ac_cv_c_celibconfig}" = x ; then
-		for i in \
-			../celib-palm-3.0 \
-			../celib \
-			../../celib-palm-3.0 \
-			../../celib \
-			`ls -dr ../celib-*3.[0-9]* 2>/dev/null` \
-			${srcdir}/../celib-palm-3.0 \
-			${srcdir}/../celib \
-			`ls -dr ${srcdir}/../celib-*3.[0-9]* 2>/dev/null` \
-			; do
-		    if test -d "$i/inc" ; then
-			ac_cv_c_celibconfig=`(cd $i; pwd)`
-			break
-		    fi
-		done
-	    fi
-
-fi
-
-	if test x"${ac_cv_c_celibconfig}" = x ; then
-	    { { echo "$as_me:$LINENO: error: Cannot find celib support library directory" >&5
-echo "$as_me: error: Cannot find celib support library directory" >&2;}
-   { (exit 1); exit 1; }; }
-	else
-	    no_celib=
-	    CELIB_DIR=${ac_cv_c_celibconfig}
-	    CELIB_DIR=`echo "$CELIB_DIR" | sed -e 's!\\\!/!g'`
-	    { echo "$as_me:$LINENO: result: found $CELIB_DIR" >&5
-echo "${ECHO_T}found $CELIB_DIR" >&6; }
-	fi
-    fi
-
-		# Set defaults for common evc4/PPC2003 setup
-		# Currently Tcl requires 300+, possibly 420+ for sockets
-		CEVERSION=420; 		# could be 211 300 301 400 420 ...
-		TARGETCPU=ARMV4;	# could be ARMV4 ARM MIPS SH3 X86 ...
-		ARCH=ARM;		# could be ARM MIPS X86EM ...
-		PLATFORM="Pocket PC 2003"; # or "Pocket PC 2002"
-		if test "$doWince" != "yes"; then
-		    # If !yes then the user specified something
-		    # Reset ARCH to allow user to skip specifying it
-		    ARCH=
-		    eval `echo $doWince | awk -F, '{ \
-	    if (length($1)) { printf "CEVERSION=\"%s\"\n", $1; \
-	    if ($1 < 400)   { printf "PLATFORM=\"Pocket PC 2002\"\n" } }; \
-	    if (length($2)) { printf "TARGETCPU=\"%s\"\n", toupper($2) }; \
-	    if (length($3)) { printf "ARCH=\"%s\"\n", toupper($3) }; \
-	    if (length($4)) { printf "PLATFORM=\"%s\"\n", $4 }; \
-		    }'`
-		    if test "x${ARCH}" = "x" ; then
-			ARCH=$TARGETCPU;
-		    fi
-		fi
-		OSVERSION=WCE$CEVERSION;
-	    	if test "x${WCEROOT}" = "x" ; then
-			WCEROOT="C:/Program Files/Microsoft eMbedded C++ 4.0"
-		    if test ! -d "${WCEROOT}" ; then
-			WCEROOT="C:/Program Files/Microsoft eMbedded Tools"
-		    fi
-		fi
-		if test "x${SDKROOT}" = "x" ; then
-		    SDKROOT="C:/Program Files/Windows CE Tools"
-		    if test ! -d "${SDKROOT}" ; then
-			SDKROOT="C:/Windows CE Tools"
-		    fi
-		fi
-		WCEROOT=`echo "$WCEROOT" | sed -e 's!\\\!/!g'`
-		SDKROOT=`echo "$SDKROOT" | sed -e 's!\\\!/!g'`
-		if test ! -d "${SDKROOT}/${OSVERSION}/${PLATFORM}/Lib/${TARGETCPU}" \
-		    -o ! -d "${WCEROOT}/EVC/${OSVERSION}/bin"; then
-		    { { echo "$as_me:$LINENO: error: could not find PocketPC SDK or target compiler to enable WinCE mode $CEVERSION,$TARGETCPU,$ARCH,$PLATFORM" >&5
-echo "$as_me: error: could not find PocketPC SDK or target compiler to enable WinCE mode $CEVERSION,$TARGETCPU,$ARCH,$PLATFORM" >&2;}
-   { (exit 1); exit 1; }; }
-		    doWince="no"
-		else
-		    # We could PATH_NOSPACE these, but that's not important,
-		    # as long as we quote them when used.
-		    CEINCLUDE="${SDKROOT}/${OSVERSION}/${PLATFORM}/include"
-		    if test -d "${CEINCLUDE}/${TARGETCPU}" ; then
-			CEINCLUDE="${CEINCLUDE}/${TARGETCPU}"
-		    fi
-		    CELIBPATH="${SDKROOT}/${OSVERSION}/${PLATFORM}/Lib/${TARGETCPU}"
-    		fi
-	    fi
-
-	    if test "$GCC" != "yes" ; then
-	        if test "${SHARED_BUILD}" = "0" ; then
-		    runtime=-MT
-	        else
-		    runtime=-MD
-	        fi
-
-                if test "$do64bit" != "no" ; then
-		    # All this magic is necessary for the Win64 SDK RC1 - hobbs
-		    CC="\"${PATH64}/cl.exe\""
-		    CFLAGS="${CFLAGS} -I\"${MSSDK}/Include\" -I\"${MSSDK}/Include/crt\" -I\"${MSSDK}/Include/crt/sys\""
-		    RC="\"${MSSDK}/bin/rc.exe\""
-		    lflags="-nologo -MACHINE:${MACHINE} -LIBPATH:\"${MSSDK}/Lib/${MACHINE}\""
-		    LINKBIN="\"${PATH64}/link.exe\""
-		    CFLAGS_DEBUG="-nologo -Zi -Od -W3 ${runtime}d"
-		    CFLAGS_OPTIMIZE="-nologo -O2 -W2 ${runtime}"
-		    # Avoid 'unresolved external symbol __security_cookie'
-		    # errors, c.f. http://support.microsoft.com/?id=894573
-
-    vars="bufferoverflowU.lib"
-    for i in $vars; do
-	if test "${TEA_PLATFORM}" = "windows" -a "$GCC" = "yes" ; then
-	    # Convert foo.lib to -lfoo for GCC.  No-op if not *.lib
-	    i=`echo "$i" | sed -e 's/^\([^-].*\)\.lib$/-l\1/i'`
-	fi
-	PKG_LIBS="$PKG_LIBS $i"
-    done
-
-
-		elif test "$doWince" != "no" ; then
-		    CEBINROOT="${WCEROOT}/EVC/${OSVERSION}/bin"
-		    if test "${TARGETCPU}" = "X86"; then
-			CC="\"${CEBINROOT}/cl.exe\""
-		    else
-			CC="\"${CEBINROOT}/cl${ARCH}.exe\""
-		    fi
-		    CFLAGS="$CFLAGS -I\"${CELIB_DIR}/inc\" -I\"${CEINCLUDE}\""
-		    RC="\"${WCEROOT}/Common/EVC/bin/rc.exe\""
-		    arch=`echo ${ARCH} | awk '{print tolower($0)}'`
-		    defs="${ARCH} _${ARCH}_ ${arch} PALM_SIZE _MT _WINDOWS"
-		    if test "${SHARED_BUILD}" = "1" ; then
-			# Static CE builds require static celib as well
-		    	defs="${defs} _DLL"
-		    fi
-		    for i in $defs ; do
-
-cat >>confdefs.h <<_ACEOF
-#define $i 1
-_ACEOF
-
-		    done
-
-cat >>confdefs.h <<_ACEOF
-#define _WIN32_WCE $CEVERSION
-_ACEOF
-
-
-cat >>confdefs.h <<_ACEOF
-#define UNDER_CE $CEVERSION
-_ACEOF
-
-		    CFLAGS_DEBUG="-nologo -Zi -Od"
-		    CFLAGS_OPTIMIZE="-nologo -Ox"
-		    lversion=`echo ${CEVERSION} | sed -e 's/\(.\)\(..\)/\1\.\2/'`
-		    lflags="-MACHINE:${ARCH} -LIBPATH:\"${CELIBPATH}\" -subsystem:windowsce,${lversion} -nologo"
-		    LINKBIN="\"${CEBINROOT}/link.exe\""
-
-		else
-		    RC="rc"
-		    lflags="-nologo"
-    		    LINKBIN="link"
-		    CFLAGS_DEBUG="-nologo -Z7 -Od -W3 -WX ${runtime}d"
-		    CFLAGS_OPTIMIZE="-nologo -O2 -W2 ${runtime}"
-		fi
-	    fi
-
-	    if test "$GCC" = "yes"; then
-		# mingw gcc mode
-		RC="windres"
-		CFLAGS_DEBUG="-g"
-		CFLAGS_OPTIMIZE="-O2 -fomit-frame-pointer"
-		SHLIB_LD="$CC -shared"
-		UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.a'
-		LDFLAGS_CONSOLE="-wl,--subsystem,console ${lflags}"
-		LDFLAGS_WINDOW="-wl,--subsystem,windows ${lflags}"
-	    else
-		SHLIB_LD="${LINKBIN} -dll ${lflags}"
-		# link -lib only works when -lib is the first arg
-		STLIB_LD="${LINKBIN} -lib ${lflags}"
-		UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.lib'
-		PATHTYPE=-w
-		# For information on what debugtype is most useful, see:
-		# http://msdn.microsoft.com/library/en-us/dnvc60/html/gendepdebug.asp
-		# This essentially turns it all on.
-		LDFLAGS_DEBUG="-debug:full -debugtype:both -warn:2"
-		LDFLAGS_OPTIMIZE="-release"
-		if test "$doWince" != "no" ; then
-		    LDFLAGS_CONSOLE="-link ${lflags}"
-		    LDFLAGS_WINDOW=${LDFLAGS_CONSOLE}
-		else
-		    LDFLAGS_CONSOLE="-link -subsystem:console ${lflags}"
-		    LDFLAGS_WINDOW="-link -subsystem:windows ${lflags}"
-		fi
-	    fi
-
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".dll"
-	    SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.dll'
-
-	    TCL_LIB_VERSIONS_OK=nodots
-	    # Bogus to avoid getting this turned off
-	    DL_OBJS="tclLoadNone.obj"
-    	    ;;
-	AIX-*)
-	    if test "${TCL_THREADS}" = "1" -a "$GCC" != "yes" ; then
-		# AIX requires the _r compiler when gcc isn't being used
-		case "${CC}" in
-		    *_r)
-			# ok ...
-			;;
-		    *)
-			CC=${CC}_r
-			;;
-		esac
-		{ echo "$as_me:$LINENO: result: Using $CC for compiling with threads" >&5
-echo "${ECHO_T}Using $CC for compiling with threads" >&6; }
-	    fi
-	    LIBS="$LIBS -lc"
-	    SHLIB_CFLAGS=""
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-
-	    DL_OBJS="tclLoadDl.o"
-	    LD_LIBRARY_PATH_VAR="LIBPATH"
-
-	    # Check to enable 64-bit flags for compiler/linker on AIX 4+
-	    if test "$do64bit" = "yes" -a "`uname -v`" -gt "3" ; then
-		if test "$GCC" = "yes" ; then
-		    { echo "$as_me:$LINENO: WARNING: 64bit mode not supported with GCC on $system" >&5
-echo "$as_me: WARNING: 64bit mode not supported with GCC on $system" >&2;}
-		else
-		    do64bit_ok=yes
-		    CFLAGS="$CFLAGS -q64"
-		    LDFLAGS_ARCH="-q64"
-		    RANLIB="${RANLIB} -X64"
-		    AR="${AR} -X64"
-		    SHLIB_LD_FLAGS="-b64"
-		fi
-	    fi
-
-	    if test "`uname -m`" = "ia64" ; then
-		# AIX-5 uses ELF style dynamic libraries on IA-64, but not PPC
-		SHLIB_LD="/usr/ccs/bin/ld -G -z text"
-		# AIX-5 has dl* in libc.so
-		DL_LIBS=""
-		if test "$GCC" = "yes" ; then
-		    CC_SEARCH_FLAGS='-Wl,-R,${LIB_RUNTIME_DIR}'
-		else
-		    CC_SEARCH_FLAGS='-R${LIB_RUNTIME_DIR}'
-		fi
-		LD_SEARCH_FLAGS='-R ${LIB_RUNTIME_DIR}'
-	    else
-		if test "$GCC" = "yes" ; then
-		    SHLIB_LD="gcc -shared"
-		else
-		    SHLIB_LD="/bin/ld -bhalt:4 -bM:SRE -bE:lib.exp -H512 -T512 -bnoentry"
-		fi
-		SHLIB_LD="${TCL_SRC_DIR}/unix/ldAix ${SHLIB_LD} ${SHLIB_LD_FLAGS}"
-		DL_LIBS="-ldl"
-		CC_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}'
-		LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
-		TCL_NEEDS_EXP_FILE=1
-		TCL_EXPORT_FILE_SUFFIX='${PACKAGE_VERSION}.exp'
-	    fi
-
-	    # AIX v<=4.1 has some different flags than 4.2+
-	    if test "$system" = "AIX-4.1" -o "`uname -v`" -lt "4" ; then
-		case " $LIBOBJS " in
-  *" tclLoadAix.$ac_objext "* ) ;;
-  *) LIBOBJS="$LIBOBJS tclLoadAix.$ac_objext"
- ;;
-esac
-
-		DL_LIBS="-lld"
-	    fi
-
-	    # On AIX <=v4 systems, libbsd.a has to be linked in to support
-	    # non-blocking file IO.  This library has to be linked in after
-	    # the MATH_LIBS or it breaks the pow() function.  The way to
-	    # insure proper sequencing, is to add it to the tail of MATH_LIBS.
-	    # This library also supplies gettimeofday.
-	    #
-	    # AIX does not have a timezone field in struct tm. When the AIX
-	    # bsd library is used, the timezone global and the gettimeofday
-	    # methods are to be avoided for timezone deduction instead, we
-	    # deduce the timezone by comparing the localtime result on a
-	    # known GMT value.
-
-	    { echo "$as_me:$LINENO: checking for gettimeofday in -lbsd" >&5
-echo $ECHO_N "checking for gettimeofday in -lbsd... $ECHO_C" >&6; }
-if test "${ac_cv_lib_bsd_gettimeofday+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-lbsd  $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-/* Override any GCC internal prototype to avoid an error.
-   Use char because int might match the return type of a GCC
-   builtin and then its argument prototype would still apply.  */
-#ifdef __cplusplus
-extern "C"
-#endif
-char gettimeofday ();
-int
-main ()
-{
-return gettimeofday ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_bsd_gettimeofday=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_lib_bsd_gettimeofday=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_bsd_gettimeofday" >&5
-echo "${ECHO_T}$ac_cv_lib_bsd_gettimeofday" >&6; }
-if test $ac_cv_lib_bsd_gettimeofday = yes; then
-  libbsd=yes
-else
-  libbsd=no
-fi
-
-	    if test $libbsd = yes; then
-	    	MATH_LIBS="$MATH_LIBS -lbsd"
-
-cat >>confdefs.h <<\_ACEOF
-#define USE_DELTA_FOR_TZ 1
-_ACEOF
-
-	    fi
-	    ;;
-	BeOS*)
-	    SHLIB_CFLAGS="-fPIC"
-	    SHLIB_LD="${CC} -nostart"
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS="-ldl"
-
-	    #-----------------------------------------------------------
-	    # Check for inet_ntoa in -lbind, for BeOS (which also needs
-	    # -lsocket, even if the network functions are in -lnet which
-	    # is always linked to, for compatibility.
-	    #-----------------------------------------------------------
-	    { echo "$as_me:$LINENO: checking for inet_ntoa in -lbind" >&5
-echo $ECHO_N "checking for inet_ntoa in -lbind... $ECHO_C" >&6; }
-if test "${ac_cv_lib_bind_inet_ntoa+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-lbind  $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-/* Override any GCC internal prototype to avoid an error.
-   Use char because int might match the return type of a GCC
-   builtin and then its argument prototype would still apply.  */
-#ifdef __cplusplus
-extern "C"
-#endif
-char inet_ntoa ();
-int
-main ()
-{
-return inet_ntoa ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_bind_inet_ntoa=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_lib_bind_inet_ntoa=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_bind_inet_ntoa" >&5
-echo "${ECHO_T}$ac_cv_lib_bind_inet_ntoa" >&6; }
-if test $ac_cv_lib_bind_inet_ntoa = yes; then
-  LIBS="$LIBS -lbind -lsocket"
-fi
-
-	    ;;
-	BSD/OS-2.1*|BSD/OS-3*)
-	    SHLIB_CFLAGS=""
-	    SHLIB_LD="shlicc -r"
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS="-ldl"
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    ;;
-	BSD/OS-4.*)
-	    SHLIB_CFLAGS="-export-dynamic -fPIC"
-	    SHLIB_LD="cc -shared"
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS="-ldl"
-	    LDFLAGS="$LDFLAGS -export-dynamic"
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    ;;
-	dgux*)
-	    SHLIB_CFLAGS="-K PIC"
-	    SHLIB_LD="cc -G"
-	    SHLIB_LD_LIBS=""
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS="-ldl"
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    ;;
-	HP-UX-*.11.*)
-	    # Use updated header definitions where possible
-
-cat >>confdefs.h <<\_ACEOF
-#define _XOPEN_SOURCE_EXTENDED 1
-_ACEOF
-
-	    # Needed by Tcl, but not most extensions
-	    #AC_DEFINE(_XOPEN_SOURCE, 1, [Do we want to use the XOPEN network library?])
-	    #LIBS="$LIBS -lxnet"               # Use the XOPEN network library
-
-	    if test "`uname -m`" = "ia64" ; then
-		SHLIB_SUFFIX=".so"
-	    else
-		SHLIB_SUFFIX=".sl"
-	    fi
-	    { echo "$as_me:$LINENO: checking for shl_load in -ldld" >&5
-echo $ECHO_N "checking for shl_load in -ldld... $ECHO_C" >&6; }
-if test "${ac_cv_lib_dld_shl_load+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-ldld  $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-/* Override any GCC internal prototype to avoid an error.
-   Use char because int might match the return type of a GCC
-   builtin and then its argument prototype would still apply.  */
-#ifdef __cplusplus
-extern "C"
-#endif
-char shl_load ();
-int
-main ()
-{
-return shl_load ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_dld_shl_load=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_lib_dld_shl_load=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_dld_shl_load" >&5
-echo "${ECHO_T}$ac_cv_lib_dld_shl_load" >&6; }
-if test $ac_cv_lib_dld_shl_load = yes; then
-  tcl_ok=yes
-else
-  tcl_ok=no
-fi
-
-	    if test "$tcl_ok" = yes; then
-		SHLIB_CFLAGS="+z"
-		SHLIB_LD="ld -b"
-		SHLIB_LD_LIBS='${LIBS}'
-		DL_OBJS="tclLoadShl.o"
-		DL_LIBS="-ldld"
-		LDFLAGS="$LDFLAGS -Wl,-E"
-		CC_SEARCH_FLAGS='-Wl,+s,+b,${LIB_RUNTIME_DIR}:.'
-		LD_SEARCH_FLAGS='+s +b ${LIB_RUNTIME_DIR}:.'
-		LD_LIBRARY_PATH_VAR="SHLIB_PATH"
-	    fi
-	    if test "$GCC" = "yes" ; then
-		SHLIB_LD="gcc -shared"
-		SHLIB_LD_LIBS='${LIBS}'
-		LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
-	    fi
-
-	    # Users may want PA-RISC 1.1/2.0 portable code - needs HP cc
-	    #CFLAGS="$CFLAGS +DAportable"
-
-	    # Check to enable 64-bit flags for compiler/linker
-	    if test "$do64bit" = "yes" ; then
-		if test "$GCC" = "yes" ; then
-		    hpux_arch=`${CC} -dumpmachine`
-		    case $hpux_arch in
-			hppa64*)
-			    # 64-bit gcc in use.  Fix flags for GNU ld.
-			    do64bit_ok=yes
-			    SHLIB_LD="${CC} -shared"
-			    SHLIB_LD_LIBS='${LIBS}'
-			    CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
-			    LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
-			    ;;
-			*)
-			    { echo "$as_me:$LINENO: WARNING: 64bit mode not supported with GCC on $system" >&5
-echo "$as_me: WARNING: 64bit mode not supported with GCC on $system" >&2;}
-			    ;;
-		    esac
-		else
-		    do64bit_ok=yes
-		    CFLAGS="$CFLAGS +DD64"
-		    LDFLAGS_ARCH="+DD64"
-		fi
-	    fi
-	    ;;
-	HP-UX-*.08.*|HP-UX-*.09.*|HP-UX-*.10.*)
-	    SHLIB_SUFFIX=".sl"
-	    { echo "$as_me:$LINENO: checking for shl_load in -ldld" >&5
-echo $ECHO_N "checking for shl_load in -ldld... $ECHO_C" >&6; }
-if test "${ac_cv_lib_dld_shl_load+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-ldld  $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-/* Override any GCC internal prototype to avoid an error.
-   Use char because int might match the return type of a GCC
-   builtin and then its argument prototype would still apply.  */
-#ifdef __cplusplus
-extern "C"
-#endif
-char shl_load ();
-int
-main ()
-{
-return shl_load ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_dld_shl_load=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	ac_cv_lib_dld_shl_load=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_dld_shl_load" >&5
-echo "${ECHO_T}$ac_cv_lib_dld_shl_load" >&6; }
-if test $ac_cv_lib_dld_shl_load = yes; then
-  tcl_ok=yes
-else
-  tcl_ok=no
-fi
-
-	    if test "$tcl_ok" = yes; then
-		SHLIB_CFLAGS="+z"
-		SHLIB_LD="ld -b"
-		SHLIB_LD_LIBS=""
-		DL_OBJS="tclLoadShl.o"
-		DL_LIBS="-ldld"
-		LDFLAGS="$LDFLAGS -Wl,-E"
-		CC_SEARCH_FLAGS='-Wl,+s,+b,${LIB_RUNTIME_DIR}:.'
-		LD_SEARCH_FLAGS='+s +b ${LIB_RUNTIME_DIR}:.'
-		LD_LIBRARY_PATH_VAR="SHLIB_PATH"
-	    fi
-	    ;;
-	IRIX-5.*)
-	    SHLIB_CFLAGS=""
-	    SHLIB_LD="ld -shared -rdata_shared"
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS=""
-	    CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
-	    LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}'
-	    ;;
-	IRIX-6.*)
-	    SHLIB_CFLAGS=""
-	    SHLIB_LD="ld -n32 -shared -rdata_shared"
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS=""
-	    CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
-	    LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}'
-	    if test "$GCC" = "yes" ; then
-		CFLAGS="$CFLAGS -mabi=n32"
-		LDFLAGS="$LDFLAGS -mabi=n32"
-	    else
-		case $system in
-		    IRIX-6.3)
-			# Use to build 6.2 compatible binaries on 6.3.
-			CFLAGS="$CFLAGS -n32 -D_OLD_TERMIOS"
-			;;
-		    *)
-			CFLAGS="$CFLAGS -n32"
-			;;
-		esac
-		LDFLAGS="$LDFLAGS -n32"
-	    fi
-	    ;;
-	IRIX64-6.*)
-	    SHLIB_CFLAGS=""
-	    SHLIB_LD="ld -n32 -shared -rdata_shared"
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS=""
-	    CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
-	    LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}'
-
-	    # Check to enable 64-bit flags for compiler/linker
-
-	    if test "$do64bit" = "yes" ; then
-	        if test "$GCC" = "yes" ; then
-	            { echo "$as_me:$LINENO: WARNING: 64bit mode not supported by gcc" >&5
-echo "$as_me: WARNING: 64bit mode not supported by gcc" >&2;}
-	        else
-	            do64bit_ok=yes
-	            SHLIB_LD="ld -64 -shared -rdata_shared"
-	            CFLAGS="$CFLAGS -64"
-	            LDFLAGS_ARCH="-64"
-	        fi
-	    fi
-	    ;;
-	Linux*)
-	    SHLIB_CFLAGS="-fPIC"
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-
-	    CFLAGS_OPTIMIZE="-O2 -fomit-frame-pointer"
-	    # egcs-2.91.66 on Redhat Linux 6.0 generates lots of warnings
-	    # when you inline the string and math operations.  Turn this off to
-	    # get rid of the warnings.
-	    #CFLAGS_OPTIMIZE="${CFLAGS_OPTIMIZE} -D__NO_STRING_INLINES -D__NO_MATH_INLINES"
-
-	    # TEA specific: use LDFLAGS_DEFAULT instead of LDFLAGS here:
-	    SHLIB_LD='${CC} -shared ${CFLAGS} ${LDFLAGS_DEFAULT}'
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS="-ldl"
-	    LDFLAGS="$LDFLAGS -Wl,--export-dynamic"
-	    CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
-	    LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
-	    if test "`uname -m`" = "alpha" ; then
-		CFLAGS="$CFLAGS -mieee"
-	    fi
-	    if test $do64bit = yes; then
-		{ echo "$as_me:$LINENO: checking if compiler accepts -m64 flag" >&5
-echo $ECHO_N "checking if compiler accepts -m64 flag... $ECHO_C" >&6; }
-if test "${tcl_cv_cc_m64+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-
-		    hold_cflags=$CFLAGS
-		    CFLAGS="$CFLAGS -m64"
-		    cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-int
-main ()
-{
-
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  tcl_cv_cc_m64=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	tcl_cv_cc_m64=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-		    CFLAGS=$hold_cflags
-fi
-{ echo "$as_me:$LINENO: result: $tcl_cv_cc_m64" >&5
-echo "${ECHO_T}$tcl_cv_cc_m64" >&6; }
-		if test $tcl_cv_cc_m64 = yes; then
-		    CFLAGS="$CFLAGS -m64"
-		    do64bit_ok=yes
-		fi
-	    fi
-
-	    # The combo of gcc + glibc has a bug related
-	    # to inlining of functions like strtod(). The
-	    # -fno-builtin flag should address this problem
-	    # but it does not work. The -fno-inline flag
-	    # is kind of overkill but it works.
-	    # Disable inlining only when one of the
-	    # files in compat/*.c is being linked in.
-	    if test x"${USE_COMPAT}" != x ; then
-	        CFLAGS="$CFLAGS -fno-inline"
-	    fi
-
-	    ;;
-	GNU*)
-	    SHLIB_CFLAGS="-fPIC"
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-
-	    SHLIB_LD="${CC} -shared"
-	    DL_OBJS=""
-	    DL_LIBS="-ldl"
-	    LDFLAGS="$LDFLAGS -Wl,--export-dynamic"
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    if test "`uname -m`" = "alpha" ; then
-		CFLAGS="$CFLAGS -mieee"
-	    fi
-	    ;;
-	Lynx*)
-	    SHLIB_CFLAGS="-fPIC"
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-	    CFLAGS_OPTIMIZE=-02
-	    SHLIB_LD="${CC} -shared "
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS="-mshared -ldl"
-	    LD_FLAGS="-Wl,--export-dynamic"
-	    CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
-	    LD_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
-	    ;;
-	MP-RAS-02*)
-	    SHLIB_CFLAGS="-K PIC"
-	    SHLIB_LD="cc -G"
-	    SHLIB_LD_LIBS=""
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS="-ldl"
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    ;;
-	MP-RAS-*)
-	    SHLIB_CFLAGS="-K PIC"
-	    SHLIB_LD="cc -G"
-	    SHLIB_LD_LIBS=""
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS="-ldl"
-	    LDFLAGS="$LDFLAGS -Wl,-Bexport"
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    ;;
-	NetBSD-*|FreeBSD-[1-2].*)
-	    # NetBSD/SPARC needs -fPIC, -fpic will not do.
-	    SHLIB_CFLAGS="-fPIC"
-	    SHLIB_LD="ld -Bshareable -x"
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS=""
-	    CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
-	    LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}'
-	    { echo "$as_me:$LINENO: checking for ELF" >&5
-echo $ECHO_N "checking for ELF... $ECHO_C" >&6; }
-if test "${tcl_cv_ld_elf+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-
-		cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-#ifdef __ELF__
-	yes
-#endif
-
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-  $EGREP "yes" >/dev/null 2>&1; then
-  tcl_cv_ld_elf=yes
-else
-  tcl_cv_ld_elf=no
-fi
-rm -f conftest*
-
-fi
-{ echo "$as_me:$LINENO: result: $tcl_cv_ld_elf" >&5
-echo "${ECHO_T}$tcl_cv_ld_elf" >&6; }
-	    if test $tcl_cv_ld_elf = yes; then
-		SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.so'
-	    else
-		SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.so.1.0'
-	    fi
-
-	    # Ancient FreeBSD doesn't handle version numbers with dots.
-
-	    UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.a'
-	    TCL_LIB_VERSIONS_OK=nodots
-	    ;;
-	OpenBSD-*)
-	    # OpenBSD/SPARC[64] needs -fPIC, -fpic will not do.
-	    case `machine` in
-	    sparc|sparc64)
-		SHLIB_CFLAGS="-fPIC";;
-	    *)
-		SHLIB_CFLAGS="-fpic";;
-	    esac
-	    SHLIB_LD="${CC} -shared ${SHLIB_CFLAGS}"
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS=""
-	    CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
-	    LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
-	    SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.so.1.0'
-	    { echo "$as_me:$LINENO: checking for ELF" >&5
-echo $ECHO_N "checking for ELF... $ECHO_C" >&6; }
-if test "${tcl_cv_ld_elf+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-
-		cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-#ifdef __ELF__
-	yes
-#endif
-
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-  $EGREP "yes" >/dev/null 2>&1; then
-  tcl_cv_ld_elf=yes
-else
-  tcl_cv_ld_elf=no
-fi
-rm -f conftest*
-
-fi
-{ echo "$as_me:$LINENO: result: $tcl_cv_ld_elf" >&5
-echo "${ECHO_T}$tcl_cv_ld_elf" >&6; }
-	    if test $tcl_cv_ld_elf = yes; then
-		LDFLAGS=-Wl,-export-dynamic
-	    else
-		LDFLAGS=""
-	    fi
-
-	    # OpenBSD doesn't do version numbers with dots.
-	    UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.a'
-	    TCL_LIB_VERSIONS_OK=nodots
-	    ;;
-	FreeBSD-*)
-	    # FreeBSD 3.* and greater have ELF.
-	    SHLIB_CFLAGS="-fPIC"
-	    SHLIB_LD="ld -Bshareable -x"
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS=""
-	    LDFLAGS="$LDFLAGS -export-dynamic"
-	    CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
-	    LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}'
-	    if test "${TCL_THREADS}" = "1" ; then
-		# The -pthread needs to go in the CFLAGS, not LIBS
-		LIBS=`echo $LIBS | sed s/-pthread//`
-		CFLAGS="$CFLAGS -pthread"
-	    	LDFLAGS="$LDFLAGS -pthread"
-	    fi
-	    case $system in
-	    FreeBSD-3.*)
-	    	# FreeBSD-3 doesn't handle version numbers with dots.
-	    	UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.a'
-	    	SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.so'
-	    	TCL_LIB_VERSIONS_OK=nodots
-		;;
-	    esac
-	    ;;
-	Darwin-*)
-	    CFLAGS_OPTIMIZE="-Os"
-	    SHLIB_CFLAGS="-fno-common"
-	    # To avoid discrepancies between what headers configure sees during
-	    # preprocessing tests and compiling tests, move any -isysroot and
-	    # -mmacosx-version-min flags from CFLAGS to CPPFLAGS:
-	    CPPFLAGS="${CPPFLAGS} `echo " ${CFLAGS}" | \
-		awk 'BEGIN {FS=" +-";ORS=" "}; {for (i=2;i<=NF;i++) \
-		if ($i~/^(isysroot|mmacosx-version-min)/) print "-"$i}'`"
-	    CFLAGS="`echo " ${CFLAGS}" | \
-		awk 'BEGIN {FS=" +-";ORS=" "}; {for (i=2;i<=NF;i++) \
-		if (!($i~/^(isysroot|mmacosx-version-min)/)) print "-"$i}'`"
-	    if test $do64bit = yes; then
-		case `arch` in
-		    ppc)
-			{ echo "$as_me:$LINENO: checking if compiler accepts -arch ppc64 flag" >&5
-echo $ECHO_N "checking if compiler accepts -arch ppc64 flag... $ECHO_C" >&6; }
-if test "${tcl_cv_cc_arch_ppc64+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-
-			    hold_cflags=$CFLAGS
-			    CFLAGS="$CFLAGS -arch ppc64 -mpowerpc64 -mcpu=G5"
-			    cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-int
-main ()
-{
-
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  tcl_cv_cc_arch_ppc64=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	tcl_cv_cc_arch_ppc64=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-			    CFLAGS=$hold_cflags
-fi
-{ echo "$as_me:$LINENO: result: $tcl_cv_cc_arch_ppc64" >&5
-echo "${ECHO_T}$tcl_cv_cc_arch_ppc64" >&6; }
-			if test $tcl_cv_cc_arch_ppc64 = yes; then
-			    CFLAGS="$CFLAGS -arch ppc64 -mpowerpc64 -mcpu=G5"
-			    do64bit_ok=yes
-			fi;;
-		    i386)
-			{ echo "$as_me:$LINENO: checking if compiler accepts -arch x86_64 flag" >&5
-echo $ECHO_N "checking if compiler accepts -arch x86_64 flag... $ECHO_C" >&6; }
-if test "${tcl_cv_cc_arch_x86_64+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-
-			    hold_cflags=$CFLAGS
-			    CFLAGS="$CFLAGS -arch x86_64"
-			    cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-int
-main ()
-{
-
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  tcl_cv_cc_arch_x86_64=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	tcl_cv_cc_arch_x86_64=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-			    CFLAGS=$hold_cflags
-fi
-{ echo "$as_me:$LINENO: result: $tcl_cv_cc_arch_x86_64" >&5
-echo "${ECHO_T}$tcl_cv_cc_arch_x86_64" >&6; }
-			if test $tcl_cv_cc_arch_x86_64 = yes; then
-			    CFLAGS="$CFLAGS -arch x86_64"
-			    do64bit_ok=yes
-			fi;;
-		    *)
-			{ echo "$as_me:$LINENO: WARNING: Don't know how enable 64-bit on architecture \`arch\`" >&5
-echo "$as_me: WARNING: Don't know how enable 64-bit on architecture \`arch\`" >&2;};;
-		esac
-	    else
-		# Check for combined 32-bit and 64-bit fat build
-		echo "$CFLAGS " | grep -E -q -- '-arch (ppc64|x86_64) ' && \
-		    echo "$CFLAGS " | grep -E -q -- '-arch (ppc|i386) ' && \
-		    fat_32_64=yes
-	    fi
-	    # TEA specific: use LDFLAGS_DEFAULT instead of LDFLAGS here:
-	    SHLIB_LD='${CC} -dynamiclib ${CFLAGS} ${LDFLAGS_DEFAULT}'
-	    { echo "$as_me:$LINENO: checking if ld accepts -single_module flag" >&5
-echo $ECHO_N "checking if ld accepts -single_module flag... $ECHO_C" >&6; }
-if test "${tcl_cv_ld_single_module+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-
-		hold_ldflags=$LDFLAGS
-		LDFLAGS="$LDFLAGS -dynamiclib -Wl,-single_module"
-		cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-int
-main ()
-{
-int i;
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  tcl_cv_ld_single_module=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	tcl_cv_ld_single_module=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-		LDFLAGS=$hold_ldflags
-fi
-{ echo "$as_me:$LINENO: result: $tcl_cv_ld_single_module" >&5
-echo "${ECHO_T}$tcl_cv_ld_single_module" >&6; }
-	    if test $tcl_cv_ld_single_module = yes; then
-		SHLIB_LD="${SHLIB_LD} -Wl,-single_module"
-	    fi
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".dylib"
-	    DL_OBJS="tclLoadDyld.o"
-	    DL_LIBS=""
-	    # Don't use -prebind when building for Mac OS X 10.4 or later only:
-	    test "`echo "${MACOSX_DEPLOYMENT_TARGET}" | awk -F '10\\.' '{print int($2)}'`" -lt 4 -a \
-		"`echo "${CPPFLAGS}" | awk -F '-mmacosx-version-min=10\\.' '{print int($2)}'`" -lt 4 && \
-		LDFLAGS="$LDFLAGS -prebind"
-	    LDFLAGS="$LDFLAGS -headerpad_max_install_names"
-	    { echo "$as_me:$LINENO: checking if ld accepts -search_paths_first flag" >&5
-echo $ECHO_N "checking if ld accepts -search_paths_first flag... $ECHO_C" >&6; }
-if test "${tcl_cv_ld_search_paths_first+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-
-		hold_ldflags=$LDFLAGS
-		LDFLAGS="$LDFLAGS -Wl,-search_paths_first"
-		cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-int
-main ()
-{
-int i;
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  tcl_cv_ld_search_paths_first=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	tcl_cv_ld_search_paths_first=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-		LDFLAGS=$hold_ldflags
-fi
-{ echo "$as_me:$LINENO: result: $tcl_cv_ld_search_paths_first" >&5
-echo "${ECHO_T}$tcl_cv_ld_search_paths_first" >&6; }
-	    if test $tcl_cv_ld_search_paths_first = yes; then
-		LDFLAGS="$LDFLAGS -Wl,-search_paths_first"
-	    fi
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    LD_LIBRARY_PATH_VAR="DYLD_LIBRARY_PATH"
-
-	    # TEA specific: for Tk extensions, remove 64-bit arch flags from
-	    # CFLAGS et al. for combined 32 & 64 bit fat builds as neither
-	    # TkAqua nor TkX11 can be built for 64-bit at present.
-	    test "$fat_32_64" = yes && test -n "${TK_BIN_DIR}" && for v in CFLAGS CPPFLAGS LDFLAGS; do
-		eval $v'="`echo "$'$v' "|sed -e "s/-arch ppc64 / /g" -e "s/-arch x86_64 / /g"`"'; done
-	    ;;
-	NEXTSTEP-*)
-	    SHLIB_CFLAGS=""
-	    SHLIB_LD="cc -nostdlib -r"
-	    SHLIB_LD_LIBS=""
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadNext.o"
-	    DL_LIBS=""
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    ;;
-	OS/390-*)
-	    CFLAGS_OPTIMIZE=""		# Optimizer is buggy
-
-cat >>confdefs.h <<\_ACEOF
-#define _OE_SOCKETS 1
-_ACEOF
-
-	    ;;
-	OSF1-1.0|OSF1-1.1|OSF1-1.2)
-	    # OSF/1 1.[012] from OSF, and derivatives, including Paragon OSF/1
-	    SHLIB_CFLAGS=""
-	    # Hack: make package name same as library name
-	    SHLIB_LD='ld -R -export :'
-	    SHLIB_LD_LIBS=""
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadOSF.o"
-	    DL_LIBS=""
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    ;;
-	OSF1-1.*)
-	    # OSF/1 1.3 from OSF using ELF, and derivatives, including AD2
-	    SHLIB_CFLAGS="-fPIC"
-	    if test "$SHARED_BUILD" = "1" ; then
-	        SHLIB_LD="ld -shared"
-	    else
-	        SHLIB_LD="ld -non_shared"
-	    fi
-	    SHLIB_LD_LIBS=""
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS=""
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    ;;
-	OSF1-V*)
-	    # Digital OSF/1
-	    SHLIB_CFLAGS=""
-	    if test "$SHARED_BUILD" = "1" ; then
-	        SHLIB_LD='ld -shared -expect_unresolved "*"'
-	    else
-	        SHLIB_LD='ld -non_shared -expect_unresolved "*"'
-	    fi
-	    SHLIB_LD_LIBS=""
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS=""
-	    CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
-	    LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}'
-	    if test "$GCC" = "yes" ; then
-		CFLAGS="$CFLAGS -mieee"
-            else
-		CFLAGS="$CFLAGS -DHAVE_TZSET -std1 -ieee"
-	    fi
-	    # see pthread_intro(3) for pthread support on osf1, k.furukawa
-	    if test "${TCL_THREADS}" = "1" ; then
-		CFLAGS="$CFLAGS -DHAVE_PTHREAD_ATTR_SETSTACKSIZE"
-		CFLAGS="$CFLAGS -DTCL_THREAD_STACK_MIN=PTHREAD_STACK_MIN*64"
-		LIBS=`echo $LIBS | sed s/-lpthreads//`
-		if test "$GCC" = "yes" ; then
-		    LIBS="$LIBS -lpthread -lmach -lexc"
-		else
-		    CFLAGS="$CFLAGS -pthread"
-		    LDFLAGS="$LDFLAGS -pthread"
-		fi
-	    fi
-
-	    ;;
-	QNX-6*)
-	    # QNX RTP
-	    # This may work for all QNX, but it was only reported for v6.
-	    SHLIB_CFLAGS="-fPIC"
-	    SHLIB_LD="ld -Bshareable -x"
-	    SHLIB_LD_LIBS=""
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    # dlopen is in -lc on QNX
-	    DL_LIBS=""
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    ;;
-	SCO_SV-3.2*)
-	    # Note, dlopen is available only on SCO 3.2.5 and greater. However,
-	    # this test works, since "uname -s" was non-standard in 3.2.4 and
-	    # below.
-	    if test "$GCC" = "yes" ; then
-	    	SHLIB_CFLAGS="-fPIC -melf"
-	    	LDFLAGS="$LDFLAGS -melf -Wl,-Bexport"
-	    else
-	    	SHLIB_CFLAGS="-Kpic -belf"
-	    	LDFLAGS="$LDFLAGS -belf -Wl,-Bexport"
-	    fi
-	    SHLIB_LD="ld -G"
-	    SHLIB_LD_LIBS=""
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS=""
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    ;;
-	SINIX*5.4*)
-	    SHLIB_CFLAGS="-K PIC"
-	    SHLIB_LD="cc -G"
-	    SHLIB_LD_LIBS=""
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS="-ldl"
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    ;;
-	SunOS-4*)
-	    SHLIB_CFLAGS="-PIC"
-	    SHLIB_LD="ld"
-	    SHLIB_LD_LIBS=""
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS="-ldl"
-	    CC_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}'
-	    LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
-
-	    # SunOS can't handle version numbers with dots in them in library
-	    # specs, like -ltcl7.5, so use -ltcl75 instead.  Also, it
-	    # requires an extra version number at the end of .so file names.
-	    # So, the library has to have a name like libtcl75.so.1.0
-
-	    SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.so.1.0'
-	    UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.a'
-	    TCL_LIB_VERSIONS_OK=nodots
-	    ;;
-	SunOS-5.[0-6])
-	    # Careful to not let 5.10+ fall into this case
-
-	    # Note: If _REENTRANT isn't defined, then Solaris
-	    # won't define thread-safe library routines.
-
-
-cat >>confdefs.h <<\_ACEOF
-#define _REENTRANT 1
-_ACEOF
-
-
-cat >>confdefs.h <<\_ACEOF
-#define _POSIX_PTHREAD_SEMANTICS 1
-_ACEOF
-
-
-	    SHLIB_CFLAGS="-KPIC"
-
-	    # Note: need the LIBS below, otherwise Tk won't find Tcl's
-	    # symbols when dynamically loaded into tclsh.
-
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS="-ldl"
-	    if test "$GCC" = "yes" ; then
-		SHLIB_LD="$CC -shared"
-		CC_SEARCH_FLAGS='-Wl,-R,${LIB_RUNTIME_DIR}'
-		LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
-	    else
-		SHLIB_LD="/usr/ccs/bin/ld -G -z text"
-		CC_SEARCH_FLAGS='-R ${LIB_RUNTIME_DIR}'
-		LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
-	    fi
-	    ;;
-	SunOS-5*)
-	    # Note: If _REENTRANT isn't defined, then Solaris
-	    # won't define thread-safe library routines.
-
-
-cat >>confdefs.h <<\_ACEOF
-#define _REENTRANT 1
-_ACEOF
-
-
-cat >>confdefs.h <<\_ACEOF
-#define _POSIX_PTHREAD_SEMANTICS 1
-_ACEOF
-
-
-	    SHLIB_CFLAGS="-KPIC"
-
-	    # Check to enable 64-bit flags for compiler/linker
-	    if test "$do64bit" = "yes" ; then
-		arch=`isainfo`
-		if test "$arch" = "sparcv9 sparc" ; then
-			if test "$GCC" = "yes" ; then
-			    if test "`gcc -dumpversion | awk -F. '{print $1}'`" -lt "3" ; then
-				{ echo "$as_me:$LINENO: WARNING: 64bit mode not supported with GCC < 3.2 on $system" >&5
-echo "$as_me: WARNING: 64bit mode not supported with GCC < 3.2 on $system" >&2;}
-			    else
-				do64bit_ok=yes
-				CFLAGS="$CFLAGS -m64 -mcpu=v9"
-				LDFLAGS="$LDFLAGS -m64 -mcpu=v9"
-				SHLIB_CFLAGS="-fPIC"
-			    fi
-			else
-			    do64bit_ok=yes
-			    if test "$do64bitVIS" = "yes" ; then
-				CFLAGS="$CFLAGS -xarch=v9a"
-			    	LDFLAGS_ARCH="-xarch=v9a"
-			    else
-				CFLAGS="$CFLAGS -xarch=v9"
-			    	LDFLAGS_ARCH="-xarch=v9"
-			    fi
-			    # Solaris 64 uses this as well
-			    #LD_LIBRARY_PATH_VAR="LD_LIBRARY_PATH_64"
-			fi
-		elif test "$arch" = "amd64 i386" ; then
-		    if test "$GCC" = "yes" ; then
-			{ echo "$as_me:$LINENO: WARNING: 64bit mode not supported with GCC on $system" >&5
-echo "$as_me: WARNING: 64bit mode not supported with GCC on $system" >&2;}
-		    else
-			do64bit_ok=yes
-			CFLAGS="$CFLAGS -xarch=amd64"
-			LDFLAGS="$LDFLAGS -xarch=amd64"
-		    fi
-		else
-		    { echo "$as_me:$LINENO: WARNING: 64bit mode not supported for $arch" >&5
-echo "$as_me: WARNING: 64bit mode not supported for $arch" >&2;}
-		fi
-	    fi
-
-	    # Note: need the LIBS below, otherwise Tk won't find Tcl's
-	    # symbols when dynamically loaded into tclsh.
-
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS="-ldl"
-	    if test "$GCC" = "yes" ; then
-		SHLIB_LD="$CC -shared"
-		CC_SEARCH_FLAGS='-Wl,-R,${LIB_RUNTIME_DIR}'
-		LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
-		if test "$do64bit_ok" = "yes" ; then
-		    # We need to specify -static-libgcc or we need to
-		    # add the path to the sparv9 libgcc.
-		    # JH: static-libgcc is necessary for core Tcl, but may
-		    # not be necessary for extensions.
-		    SHLIB_LD="$SHLIB_LD -m64 -mcpu=v9 -static-libgcc"
-		    # for finding sparcv9 libgcc, get the regular libgcc
-		    # path, remove so name and append 'sparcv9'
-		    #v9gcclibdir="`gcc -print-file-name=libgcc_s.so` | ..."
-		    #CC_SEARCH_FLAGS="${CC_SEARCH_FLAGS},-R,$v9gcclibdir"
-		fi
-	    else
-		SHLIB_LD="/usr/ccs/bin/ld -G -z text"
-		CC_SEARCH_FLAGS='-Wl,-R,${LIB_RUNTIME_DIR}'
-		LD_SEARCH_FLAGS='-R ${LIB_RUNTIME_DIR}'
-	    fi
-	    ;;
-	UNIX_SV* | UnixWare-5*)
-	    SHLIB_CFLAGS="-KPIC"
-	    SHLIB_LD="cc -G"
-	    SHLIB_LD_LIBS=""
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS="-ldl"
-	    # Some UNIX_SV* systems (unixware 1.1.2 for example) have linkers
-	    # that don't grok the -Bexport option.  Test that it does.
-	    { echo "$as_me:$LINENO: checking for ld accepts -Bexport flag" >&5
-echo $ECHO_N "checking for ld accepts -Bexport flag... $ECHO_C" >&6; }
-if test "${tcl_cv_ld_Bexport+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-
-		hold_ldflags=$LDFLAGS
-		LDFLAGS="$LDFLAGS -Wl,-Bexport"
-		cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-int
-main ()
-{
-int i;
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  tcl_cv_ld_Bexport=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	tcl_cv_ld_Bexport=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-	        LDFLAGS=$hold_ldflags
-fi
-{ echo "$as_me:$LINENO: result: $tcl_cv_ld_Bexport" >&5
-echo "${ECHO_T}$tcl_cv_ld_Bexport" >&6; }
-	    if test $tcl_cv_ld_Bexport = yes; then
-		LDFLAGS="$LDFLAGS -Wl,-Bexport"
-	    fi
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    ;;
-    esac
-
-    if test "$do64bit" = "yes" -a "$do64bit_ok" = "no" ; then
-	{ echo "$as_me:$LINENO: WARNING: 64bit support being disabled -- don't know magic for this platform" >&5
-echo "$as_me: WARNING: 64bit support being disabled -- don't know magic for this platform" >&2;}
-    fi
-
-
-
-    # Step 4: disable dynamic loading if requested via a command-line switch.
-
-    # Check whether --enable-load was given.
-if test "${enable_load+set}" = set; then
-  enableval=$enable_load; tcl_ok=$enableval
-else
-  tcl_ok=yes
-fi
-
-    if test "$tcl_ok" = "no"; then
-	DL_OBJS=""
-    fi
-
-    if test "x$DL_OBJS" != "x" ; then
-	BUILD_DLTEST="\$(DLTEST_TARGETS)"
-    else
-	echo "Can't figure out how to do dynamic loading or shared libraries"
-	echo "on this system."
-	SHLIB_CFLAGS=""
-	SHLIB_LD=""
-	SHLIB_SUFFIX=""
-	DL_OBJS="tclLoadNone.o"
-	DL_LIBS=""
-	LDFLAGS="$LDFLAGS_ORIG"
-	CC_SEARCH_FLAGS=""
-	LD_SEARCH_FLAGS=""
-	BUILD_DLTEST=""
-    fi
-    LDFLAGS="$LDFLAGS $LDFLAGS_ARCH"
-
-    # If we're running gcc, then change the C flags for compiling shared
-    # libraries to the right flags for gcc, instead of those for the
-    # standard manufacturer compiler.
-
-    if test "$DL_OBJS" != "tclLoadNone.o" ; then
-	if test "$GCC" = "yes" ; then
-	    case $system in
-		AIX-*)
-		    ;;
-		BSD/OS*)
-		    ;;
-		IRIX*)
-		    ;;
-		NetBSD-*|FreeBSD-*)
-		    ;;
-		Darwin-*)
-		    ;;
-		SCO_SV-3.2*)
-		    ;;
-		windows)
-		    ;;
-		*)
-		    SHLIB_CFLAGS="-fPIC"
-		    ;;
-	    esac
-	fi
-    fi
-
-    if test "$SHARED_LIB_SUFFIX" = "" ; then
-	SHARED_LIB_SUFFIX='${PACKAGE_VERSION}${SHLIB_SUFFIX}'
-    fi
-    if test "$UNSHARED_LIB_SUFFIX" = "" ; then
-	UNSHARED_LIB_SUFFIX='${PACKAGE_VERSION}.a'
-    fi
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-    # These must be called after we do the basic CFLAGS checks and
-    # verify any possible 64-bit or similar switches are necessary
-
-    { echo "$as_me:$LINENO: checking for required early compiler flags" >&5
-echo $ECHO_N "checking for required early compiler flags... $ECHO_C" >&6; }
-    tcl_flags=""
-
-    if test "${tcl_cv_flag__isoc99_source+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <stdlib.h>
-int
-main ()
-{
-char *p = (char *)strtoll; char *q = (char *)strtoull;
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  tcl_cv_flag__isoc99_source=no
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#define _ISOC99_SOURCE 1
-#include <stdlib.h>
-int
-main ()
-{
-char *p = (char *)strtoll; char *q = (char *)strtoull;
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  tcl_cv_flag__isoc99_source=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	tcl_cv_flag__isoc99_source=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
-    if test "x${tcl_cv_flag__isoc99_source}" = "xyes" ; then
-
-cat >>confdefs.h <<\_ACEOF
-#define _ISOC99_SOURCE 1
-_ACEOF
-
-	tcl_flags="$tcl_flags _ISOC99_SOURCE"
-    fi
-
-
-    if test "${tcl_cv_flag__largefile64_source+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <sys/stat.h>
-int
-main ()
-{
-struct stat64 buf; int i = stat64("/", &buf);
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  tcl_cv_flag__largefile64_source=no
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#define _LARGEFILE64_SOURCE 1
-#include <sys/stat.h>
-int
-main ()
-{
-struct stat64 buf; int i = stat64("/", &buf);
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  tcl_cv_flag__largefile64_source=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	tcl_cv_flag__largefile64_source=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
-    if test "x${tcl_cv_flag__largefile64_source}" = "xyes" ; then
-
-cat >>confdefs.h <<\_ACEOF
-#define _LARGEFILE64_SOURCE 1
-_ACEOF
-
-	tcl_flags="$tcl_flags _LARGEFILE64_SOURCE"
-    fi
-
-
-    if test "${tcl_cv_flag__largefile_source64+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <sys/stat.h>
-int
-main ()
-{
-char *p = (char *)open64;
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  tcl_cv_flag__largefile_source64=no
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#define _LARGEFILE_SOURCE64 1
-#include <sys/stat.h>
-int
-main ()
-{
-char *p = (char *)open64;
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  tcl_cv_flag__largefile_source64=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	tcl_cv_flag__largefile_source64=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
-    if test "x${tcl_cv_flag__largefile_source64}" = "xyes" ; then
-
-cat >>confdefs.h <<\_ACEOF
-#define _LARGEFILE_SOURCE64 1
-_ACEOF
-
-	tcl_flags="$tcl_flags _LARGEFILE_SOURCE64"
-    fi
-
-    if test "x${tcl_flags}" = "x" ; then
-	{ echo "$as_me:$LINENO: result: none" >&5
-echo "${ECHO_T}none" >&6; }
-    else
-	{ echo "$as_me:$LINENO: result: ${tcl_flags}" >&5
-echo "${ECHO_T}${tcl_flags}" >&6; }
-    fi
-
-
-    { echo "$as_me:$LINENO: checking for 64-bit integer type" >&5
-echo $ECHO_N "checking for 64-bit integer type... $ECHO_C" >&6; }
-    if test "${tcl_cv_type_64bit+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-
-	tcl_cv_type_64bit=none
-	# See if the compiler knows natively about __int64
-	cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-int
-main ()
-{
-__int64 value = (__int64) 0;
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  tcl_type_64bit=__int64
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	tcl_type_64bit="long long"
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-	# See if we should use long anyway  Note that we substitute in the
-	# type that is our current guess for a 64-bit type inside this check
-	# program, so it should be modified only carefully...
-        cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-int
-main ()
-{
-switch (0) {
-            case 1: case (sizeof(${tcl_type_64bit})==sizeof(long)): ;
-        }
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  tcl_cv_type_64bit=${tcl_type_64bit}
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
-    if test "${tcl_cv_type_64bit}" = none ; then
-
-cat >>confdefs.h <<\_ACEOF
-#define TCL_WIDE_INT_IS_LONG 1
-_ACEOF
-
-	{ echo "$as_me:$LINENO: result: using long" >&5
-echo "${ECHO_T}using long" >&6; }
-    elif test "${tcl_cv_type_64bit}" = "__int64" \
-		-a "${TEA_PLATFORM}" = "windows" ; then
-	# We actually want to use the default tcl.h checks in this
-	# case to handle both TCL_WIDE_INT_TYPE and TCL_LL_MODIFIER*
-	{ echo "$as_me:$LINENO: result: using Tcl header defaults" >&5
-echo "${ECHO_T}using Tcl header defaults" >&6; }
-    else
-
-cat >>confdefs.h <<_ACEOF
-#define TCL_WIDE_INT_TYPE ${tcl_cv_type_64bit}
-_ACEOF
-
-	{ echo "$as_me:$LINENO: result: ${tcl_cv_type_64bit}" >&5
-echo "${ECHO_T}${tcl_cv_type_64bit}" >&6; }
-
-	# Now check for auxiliary declarations
-	{ echo "$as_me:$LINENO: checking for struct dirent64" >&5
-echo $ECHO_N "checking for struct dirent64... $ECHO_C" >&6; }
-if test "${tcl_cv_struct_dirent64+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-
-	    cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <sys/types.h>
-#include <sys/dirent.h>
-int
-main ()
-{
-struct dirent64 p;
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  tcl_cv_struct_dirent64=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	tcl_cv_struct_dirent64=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-{ echo "$as_me:$LINENO: result: $tcl_cv_struct_dirent64" >&5
-echo "${ECHO_T}$tcl_cv_struct_dirent64" >&6; }
-	if test "x${tcl_cv_struct_dirent64}" = "xyes" ; then
-
-cat >>confdefs.h <<\_ACEOF
-#define HAVE_STRUCT_DIRENT64 1
-_ACEOF
-
-	fi
-
-	{ echo "$as_me:$LINENO: checking for struct stat64" >&5
-echo $ECHO_N "checking for struct stat64... $ECHO_C" >&6; }
-if test "${tcl_cv_struct_stat64+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-
-	    cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <sys/stat.h>
-int
-main ()
-{
-struct stat64 p;
-
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  tcl_cv_struct_stat64=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	tcl_cv_struct_stat64=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-{ echo "$as_me:$LINENO: result: $tcl_cv_struct_stat64" >&5
-echo "${ECHO_T}$tcl_cv_struct_stat64" >&6; }
-	if test "x${tcl_cv_struct_stat64}" = "xyes" ; then
-
-cat >>confdefs.h <<\_ACEOF
-#define HAVE_STRUCT_STAT64 1
-_ACEOF
-
-	fi
-
-
-
-for ac_func in open64 lseek64
-do
-as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
-{ echo "$as_me:$LINENO: checking for $ac_func" >&5
-echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
-if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
-   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
-#define $ac_func innocuous_$ac_func
-
-/* System header to define __stub macros and hopefully few prototypes,
-    which can conflict with char $ac_func (); below.
-    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
-    <limits.h> exists even on freestanding compilers.  */
-
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
-
-#undef $ac_func
-
-/* Override any GCC internal prototype to avoid an error.
-   Use char because int might match the return type of a GCC
-   builtin and then its argument prototype would still apply.  */
-#ifdef __cplusplus
-extern "C"
-#endif
-char $ac_func ();
-/* The GNU C library defines this for functions which it implements
-    to always fail with ENOSYS.  Some functions are actually named
-    something starting with __ and the normal name is an alias.  */
-#if defined __stub_$ac_func || defined __stub___$ac_func
-choke me
-#endif
-
-int
-main ()
-{
-return $ac_func ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  eval "$as_ac_var=yes"
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	eval "$as_ac_var=no"
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-fi
-ac_res=`eval echo '${'$as_ac_var'}'`
-	       { echo "$as_me:$LINENO: result: $ac_res" >&5
-echo "${ECHO_T}$ac_res" >&6; }
-if test `eval echo '${'$as_ac_var'}'` = yes; then
-  cat >>confdefs.h <<_ACEOF
-#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
-_ACEOF
-
-fi
-done
-
-	{ echo "$as_me:$LINENO: checking for off64_t" >&5
-echo $ECHO_N "checking for off64_t... $ECHO_C" >&6; }
-	if test "${tcl_cv_type_off64_t+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-
-	    cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <sys/types.h>
-int
-main ()
-{
-off64_t offset;
-
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-	 test -z "$ac_c_werror_flag" ||
-	 test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  tcl_cv_type_off64_t=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-	tcl_cv_type_off64_t=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
-			if test "x${tcl_cv_type_off64_t}" = "xyes" && \
-	        test "x${ac_cv_func_lseek64}" = "xyes" && \
-	        test "x${ac_cv_func_open64}" = "xyes" ; then
-
-cat >>confdefs.h <<\_ACEOF
-#define HAVE_TYPE_OFF64_T 1
-_ACEOF
-
-	    { echo "$as_me:$LINENO: result: yes" >&5
-echo "${ECHO_T}yes" >&6; }
-	else
-	    { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-	fi
-    fi
-
-
-
-#--------------------------------------------------------------------
-# Set the default compiler switches based on the --enable-symbols option.
-#--------------------------------------------------------------------
-
-
-
-    { echo "$as_me:$LINENO: checking for build with symbols" >&5
-echo $ECHO_N "checking for build with symbols... $ECHO_C" >&6; }
-    # Check whether --enable-symbols was given.
-if test "${enable_symbols+set}" = set; then
-  enableval=$enable_symbols; tcl_ok=$enableval
-else
-  tcl_ok=no
-fi
-
-    DBGX=""
-    if test "$tcl_ok" = "no"; then
-	CFLAGS_DEFAULT="${CFLAGS_OPTIMIZE}"
-	LDFLAGS_DEFAULT="${LDFLAGS_OPTIMIZE}"
-	{ echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-    else
-	CFLAGS_DEFAULT="${CFLAGS_DEBUG}"
-	LDFLAGS_DEFAULT="${LDFLAGS_DEBUG}"
-	if test "$tcl_ok" = "yes"; then
-	    { echo "$as_me:$LINENO: result: yes (standard debugging)" >&5
-echo "${ECHO_T}yes (standard debugging)" >&6; }
-	fi
-    fi
-    if test "${TEA_PLATFORM}" != "windows" ; then
-	LDFLAGS_DEFAULT="${LDFLAGS}"
-    fi
-
-
-
-
-
-    if test "$tcl_ok" = "mem" -o "$tcl_ok" = "all"; then
-
-cat >>confdefs.h <<\_ACEOF
-#define TCL_MEM_DEBUG 1
-_ACEOF
-
-    fi
-
-    if test "$tcl_ok" != "yes" -a "$tcl_ok" != "no"; then
-	if test "$tcl_ok" = "all"; then
-	    { echo "$as_me:$LINENO: result: enabled symbols mem debugging" >&5
-echo "${ECHO_T}enabled symbols mem debugging" >&6; }
-	else
-	    { echo "$as_me:$LINENO: result: enabled $tcl_ok debugging" >&5
-echo "${ECHO_T}enabled $tcl_ok debugging" >&6; }
-	fi
-    fi
-
-
-#--------------------------------------------------------------------
-# Everyone should be linking against the Tcl stub library.  If you
-# can't for some reason, remove this definition.  If you aren't using
-# stubs, you also need to modify the SHLIB_LD_LIBS setting below to
-# link against the non-stubbed Tcl library.
-#--------------------------------------------------------------------
-
-
-cat >>confdefs.h <<\_ACEOF
-#define USE_TCL_STUBS 1
-_ACEOF
-
-
-#--------------------------------------------------------------------
-# This macro generates a line to use when building a library.  It
-# depends on values set by the TEA_ENABLE_SHARED, TEA_ENABLE_SYMBOLS,
-# and TEA_LOAD_TCLCONFIG macros above.
-#--------------------------------------------------------------------
-
-
-    if test "${TEA_PLATFORM}" = "windows" -a "$GCC" != "yes"; then
-	MAKE_STATIC_LIB="\${STLIB_LD} -out:\$@ \$(PKG_OBJECTS)"
-	MAKE_SHARED_LIB="\${SHLIB_LD} \${SHLIB_LD_LIBS} \${LDFLAGS_DEFAULT} -out:\$@ \$(PKG_OBJECTS)"
-	MAKE_STUB_LIB="\${STLIB_LD} -out:\$@ \$(PKG_STUB_OBJECTS)"
-    else
-	MAKE_STATIC_LIB="\${STLIB_LD} \$@ \$(PKG_OBJECTS)"
-	MAKE_SHARED_LIB="\${SHLIB_LD} -o \$@ \$(PKG_OBJECTS) \${SHLIB_LD_LIBS}"
-	MAKE_STUB_LIB="\${STLIB_LD} \$@ \$(PKG_STUB_OBJECTS)"
-    fi
-
-    if test "${SHARED_BUILD}" = "1" ; then
-	MAKE_LIB="${MAKE_SHARED_LIB} "
-    else
-	MAKE_LIB="${MAKE_STATIC_LIB} "
-    fi
-
-    #--------------------------------------------------------------------
-    # Shared libraries and static libraries have different names.
-    # Use the double eval to make sure any variables in the suffix is
-    # substituted. (@@@ Might not be necessary anymore)
-    #--------------------------------------------------------------------
-
-    if test "${TEA_PLATFORM}" = "windows" ; then
-	if test "${SHARED_BUILD}" = "1" ; then
-	    # We force the unresolved linking of symbols that are really in
-	    # the private libraries of Tcl and Tk.
-	    SHLIB_LD_LIBS="${SHLIB_LD_LIBS} \"`${CYGPATH} ${TCL_BIN_DIR}/${TCL_STUB_LIB_FILE}`\""
-	    if test x"${TK_BIN_DIR}" != x ; then
-		SHLIB_LD_LIBS="${SHLIB_LD_LIBS} \"`${CYGPATH} ${TK_BIN_DIR}/${TK_STUB_LIB_FILE}`\""
-	    fi
-	    eval eval "PKG_LIB_FILE=${PACKAGE_NAME}${SHARED_LIB_SUFFIX}"
-	else
-	    eval eval "PKG_LIB_FILE=${PACKAGE_NAME}${UNSHARED_LIB_SUFFIX}"
-	fi
-	# Some packages build their own stubs libraries
-	eval eval "PKG_STUB_LIB_FILE=${PACKAGE_NAME}stub${UNSHARED_LIB_SUFFIX}"
-	if test "$GCC" = "yes"; then
-	    PKG_STUB_LIB_FILE=lib${PKG_STUB_LIB_FILE}
-	fi
-	# These aren't needed on Windows (either MSVC or gcc)
-	RANLIB=:
-	RANLIB_STUB=:
-    else
-	RANLIB_STUB="${RANLIB}"
-	if test "${SHARED_BUILD}" = "1" ; then
-	    SHLIB_LD_LIBS="${SHLIB_LD_LIBS} ${TCL_STUB_LIB_SPEC}"
-	    if test x"${TK_BIN_DIR}" != x ; then
-		SHLIB_LD_LIBS="${SHLIB_LD_LIBS} ${TK_STUB_LIB_SPEC}"
-	    fi
-	    eval eval "PKG_LIB_FILE=lib${PACKAGE_NAME}${SHARED_LIB_SUFFIX}"
-	    RANLIB=:
-	else
-	    eval eval "PKG_LIB_FILE=lib${PACKAGE_NAME}${UNSHARED_LIB_SUFFIX}"
-	fi
-	# Some packages build their own stubs libraries
-	eval eval "PKG_STUB_LIB_FILE=lib${PACKAGE_NAME}stub${UNSHARED_LIB_SUFFIX}"
-    fi
-
-    # These are escaped so that only CFLAGS is picked up at configure time.
-    # The other values will be substituted at make time.
-    CFLAGS="${CFLAGS} \${CFLAGS_DEFAULT} \${CFLAGS_WARNING}"
-    if test "${SHARED_BUILD}" = "1" ; then
-	CFLAGS="${CFLAGS} \${SHLIB_CFLAGS}"
-    fi
-
-
-
-
-
-
-
-
-#--------------------------------------------------------------------
-# On Mac OS X we may want to build as a framework.
-# This affects the location and naming of headers and libaries.
-#--------------------------------------------------------------------
-
-# Check whether --enable-framework was given.
-if test "${enable_framework+set}" = set; then
-  enableval=$enable_framework; tcl_ok=$enableval
-else
-  tcl_ok=$1
-fi
-
-
-#--------------------------------------------------------------------
-# Load libxml2 configuration
-#--------------------------------------------------------------------
-
-{ echo "$as_me:$LINENO: checking for xml2-config script" >&5
-echo $ECHO_N "checking for xml2-config script... $ECHO_C" >&6; }
-
-
-# Check whether --with-xml2-config was given.
-if test "${with_xml2_config+set}" = set; then
-  withval=$with_xml2_config; with_xml2_config=${withval}
-fi
-
-
-LIBXML2_CONFIG=
-if test "x${with_xml2_config}" = "x" ; then
-    for c in \
-	/Library/Frameworks/libxml.framework/Resources/Scripts/xml2-config \
-	${prefix}/bin/xml2-config \
-	/usr/bin/xml2-config \
-	/usr/local/bin/xml2-config
-    do
-	if test -x "$c" ; then
-	    LIBXML2_CONFIG="$c"
-	    break
-	fi
-    done
-else
-    LIBXML2_CONFIG="${with_xml2_config}"
-fi
-if test "x$LIBXML2_CONFIG" = "x" ; then
-    { { echo "$as_me:$LINENO: error: unable to find xml2-config" >&5
-echo "$as_me: error: unable to find xml2-config" >&2;}
-   { (exit 1); exit 1; }; }
-else
-    { echo "$as_me:$LINENO: result: ${LIBXML2_CONFIG}" >&5
-echo "${ECHO_T}${LIBXML2_CONFIG}" >&6; }
-    XML2_VERSION=`${LIBXML2_CONFIG} --version`
-    XML2_PREFIX=`${LIBXML2_CONFIG} --prefix`
-    XML2_LIBS="`${LIBXML2_CONFIG} --libs`"
-    XML2_CFLAGS=`${LIBXML2_CONFIG} --cflags`
-fi
-
-
-
-
-
-#--------------------------------------------------------------------
-# Load libxslt configuration
-#--------------------------------------------------------------------
-
-{ echo "$as_me:$LINENO: checking for xslt-config script" >&5
-echo $ECHO_N "checking for xslt-config script... $ECHO_C" >&6; }
-
-
-# Check whether --with-xslt-config was given.
-if test "${with_xslt_config+set}" = set; then
-  withval=$with_xslt_config; with_xslt_config=${withval}
-fi
-
-
-LIBXSLT_CONFIG=
-if test "x${with_xslt_config}" = "x" ; then
-    if test "x${with_xml2_config}" = "x" ; then
-	:
-    else
-	if test -x "`dirname ${with_xml2_config}`/xslt-config" ; then
-	    LIBXSLT_CONFIG="`dirname ${with_xml2_config}`/xslt-config"
-	fi
-    fi
-else
-    LIBXSLT_CONFIG="${with_xslt_config}"
-fi
-if test "x${LIBXSLT_CONFIG}" = "x" ; then
-    for c in \
-	/Library/Frameworks/libxslt.framework/Resources/Scripts/xslt-config \
-	${prefix}/bin/xslt-config \
-	/usr/bin/xslt-config \
-	/usr/local/bin/xslt-config
-    do
-	if test -x "$c" ; then
-	    LIBXSLT_CONFIG="$c"
-	    break
-	fi
-    done
-fi
-if test "x$LIBXSLT_CONFIG" = "x" ; then
-    { { echo "$as_me:$LINENO: error: unable to find xslt-config script" >&5
-echo "$as_me: error: unable to find xslt-config script" >&2;}
-   { (exit 1); exit 1; }; }
-else
-    { echo "$as_me:$LINENO: result: ${LIBXSLT_CONFIG}" >&5
-echo "${ECHO_T}${LIBXSLT_CONFIG}" >&6; }
-    XSLT_VERSION=`${LIBXSLT_CONFIG} --version`
-    XSLT_PREFIX=`${LIBXSLT_CONFIG} --prefix`
-    XSLT_CFLAGS=`${LIBXSLT_CONFIG} --cflags`
-    XSLT_LIBS="`${LIBXSLT_CONFIG} --libs` -lexslt"
-fi
-
-
-
-
-
-#--------------------------------------------------------------------
-# See if we want to statically link the libxml2 and libxslt
-# libraries. This is desirable for Tclkit.
-#--------------------------------------------------------------------
-
-{ echo "$as_me:$LINENO: checking for static linking of XML/XSLT libraries" >&5
-echo $ECHO_N "checking for static linking of XML/XSLT libraries... $ECHO_C" >&6; }
-
-
-# Check whether --with-xml-static was given.
-if test "${with_xml_static+set}" = set; then
-  withval=$with_xml_static; with_xml_static=${withval}
-fi
-
-
-XML_STATIC="0"
-if test "${with_xml_static}" = "1" ; then
-    XML_STATIC="1"
-    { echo "$as_me:$LINENO: result: use static linking" >&5
-echo "${ECHO_T}use static linking" >&6; }
-else
-    { echo "$as_me:$LINENO: result: use dynamic linking" >&5
-echo "${ECHO_T}use dynamic linking" >&6; }
-fi
-
-
-
-#--------------------------------------------------------------------
-# __CHANGE__
-# Add platform libs to LIBS or SHLIB_LD_LIBS as necessary.
-#--------------------------------------------------------------------
-
-FIX_LIB=":"
-if test "${TEA_PLATFORM}" = "windows" -a "$GCC" != "yes" ; then
-    SHLIB_LD_LIBS="${SHLIB_LD_LIBS} \"`${CYGPATH} ${LIBXSLT_LIBDIR}/libxslt.lib`\""
-    SHLIB_LD_LIBS="${SHLIB_LD_LIBS} \"`${CYGPATH} ${LIBXSLT_LIBDIR}/libexslt.lib`\""
-    SHLIB_LD_LIBS="${SHLIB_LD_LIBS} \"`${CYGPATH} ${LIBXML2_LIBDIR}/libxml2.lib`\""
-else
-if test "${XML_STATIC}" = "0" ; then
-    echo "setting up dynamic linking"
-    SHLIB_LD_LIBS="${SHLIB_LD_LIBS} \${XSLT_LIBS}"
-else
-    SHLIB_LD_LIBS="${SHLIB_LD_LIBS} ${XSLT_PREFIX}/lib/libexslt.a"
-    SHLIB_LD_LIBS="${SHLIB_LD_LIBS} ${XSLT_PREFIX}/lib/libxslt.a"
-    SHLIB_LD_LIBS="${SHLIB_LD_LIBS} ${XML2_PREFIX}/lib/libxml2.a"
-    SHLIB_LD_LIBS="${SHLIB_LD_LIBS} -L/usr/lib -lgcrypt -lgpg-error -lz -lm"
-    XML2_LIBS=
-    XSLT_LIBS=
-#    FIX_LIB="chcon -t texrel_shlib_t"
-fi
-fi
-
-# Enabling static linking modifies the setting of the libraries,
-# so delay substitution until this point.
-
-
-
-
-#--------------------------------------------------------------------
-# Find tclsh so that we can run pkg_mkIndex to generate the pkgIndex.tcl
-# file during the install process.  Don't run the TCLSH_PROG through
-# ${CYGPATH} because it's being used directly by make.
-# Require that we use a tclsh shell version 8.2 or later since earlier
-# versions have bugs in the pkg_mkIndex routine.
-# Add WISH as well if this is a Tk extension.
-#--------------------------------------------------------------------
-
-
-    { echo "$as_me:$LINENO: checking for tclsh" >&5
-echo $ECHO_N "checking for tclsh... $ECHO_C" >&6; }
-    if test -f "${TCL_BIN_DIR}/Makefile" ; then
-        # tclConfig.sh is in Tcl build directory
-        if test "${TEA_PLATFORM}" = "windows"; then
-            TCLSH_PROG="${TCL_BIN_DIR}/tclsh${TCL_MAJOR_VERSION}${TCL_MINOR_VERSION}${TCL_DBGX}${EXEEXT}"
-        else
-            TCLSH_PROG="${TCL_BIN_DIR}/tclsh"
-        fi
-    else
-        # tclConfig.sh is in install location
-        if test "${TEA_PLATFORM}" = "windows"; then
-            TCLSH_PROG="tclsh${TCL_MAJOR_VERSION}${TCL_MINOR_VERSION}${TCL_DBGX}${EXEEXT}"
-        else
-            TCLSH_PROG="tclsh${TCL_MAJOR_VERSION}.${TCL_MINOR_VERSION}${TCL_DBGX}"
-        fi
-        list="`ls -d ${TCL_BIN_DIR}/../bin 2>/dev/null` \
-              `ls -d ${TCL_BIN_DIR}/..     2>/dev/null` \
-              `ls -d ${TCL_PREFIX}/bin     2>/dev/null`"
-        for i in $list ; do
-            if test -f "$i/${TCLSH_PROG}" ; then
-                REAL_TCL_BIN_DIR="`cd "$i"; pwd`/"
-                break
-            fi
-        done
-        TCLSH_PROG="${REAL_TCL_BIN_DIR}${TCLSH_PROG}"
-    fi
-    { echo "$as_me:$LINENO: result: ${TCLSH_PROG}" >&5
-echo "${ECHO_T}${TCLSH_PROG}" >&6; }
-
-
-
-#--------------------------------------------------------------------
-# These are for tclxmlConfig.sh
-#--------------------------------------------------------------------
-
-# pkglibdir must be a fully qualified path and (not ${exec_prefix}/lib)
-eval pkglibdir="${libdir}/${PACKAGE_NAME}${PACKAGE_VERSION}"
-if test "${TCL_LIB_VERSIONS_OK}" = "ok"; then
-    eval Tclxml_LIB_FLAG="-l${PACKAGE_NAME}${PACKAGE_VERSION}${DBGX}"
-else
-    eval Tclxml_LIB_FLAG="-l${PACKAGE_NAME}`echo ${PACKAGE_VERSION} | tr -d .`${DBGX}"
-fi
-Tclxml_BUILD_LIB_SPEC="-L`pwd` ${Tclxml_LIB_FLAG}"
-Tclxml_LIB_SPEC="-L${pkglibdir} ${Tclxml_LIB_FLAG}"
-
-if test "${TCL_LIB_VERSIONS_OK}" = "ok"; then
-    eval Tclxml_STUB_LIB_FLAG="-l${PACKAGE_NAME}stub${PACKAGE_VERSION}${DBGX}"
-else
-    eval Tclxml_STUB_LIB_FLAG="-l${PACKAGE_NAME}stub`echo ${PACKAGE_VERSION} | tr -d .`${DBGX}"
-fi
-Tclxml_BUILD_STUB_LIB_SPEC="-L`pwd` ${Tclxml_STUB_LIB_FLAG}"
-Tclxml_STUB_LIB_SPEC="-L${pkglibdir} ${Tclxml_STUB_LIB_FLAG}"
-Tclxml_BUILD_STUB_LIB_PATH="`pwd`/${Tclxmlstub_LIB_FILE}"
-Tclxml_STUB_LIB_PATH="${pkglibdir}/${Tclxmlstub_LIB_FILE}"
-eval pkgincludedir="${includedir}"
-Tclxml_INCLUDE_SPEC="-I${pkgincludedir}"
-
-
-
-
-
-
-
-
-
-#--------------------------------------------------------------------
-# TODO: search for an appropriate xsltproc to use
-#--------------------------------------------------------------------
-
-XSLTPROC=xsltproc
-
-
-#--------------------------------------------------------------------
-# Finally, substitute all of the various values into the Makefile.
-# You may alternatively have a special pkgIndex.tcl.in or other files
-# which require substituting th AC variables in.  Include these here.
-#--------------------------------------------------------------------
-
-ac_config_files="$ac_config_files Makefile Makefile.macosx pkgIndex.tcl TclxmlConfig.sh include/tclxml/tclxml.h doc/tclxml.xml doc/tcldom.xml doc/tclxslt.xml doc/README.xml"
-
-cat >confcache <<\_ACEOF
-# This file is a shell script that caches the results of configure
-# tests run on this system so they can be shared between configure
-# scripts and configure runs, see configure's option --config-cache.
-# It is not useful on other systems.  If it contains results you don't
-# want to keep, you may remove or edit it.
-#
-# config.status only pays attention to the cache file if you give it
-# the --recheck option to rerun configure.
-#
-# `ac_cv_env_foo' variables (set or unset) will be overridden when
-# loading this file, other *unset* `ac_cv_foo' will be assigned the
-# following values.
-
-_ACEOF
-
-# The following way of writing the cache mishandles newlines in values,
-# but we know of no workaround that is simple, portable, and efficient.
-# So, we kill variables containing newlines.
-# Ultrix sh set writes to stderr and can't be redirected directly,
-# and sets the high bit in the cache file unless we assign to the vars.
-(
-  for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
-    eval ac_val=\$$ac_var
-    case $ac_val in #(
-    *${as_nl}*)
-      case $ac_var in #(
-      *_cv_*) { echo "$as_me:$LINENO: WARNING: Cache variable $ac_var contains a newline." >&5
-echo "$as_me: WARNING: Cache variable $ac_var contains a newline." >&2;} ;;
-      esac
-      case $ac_var in #(
-      _ | IFS | as_nl) ;; #(
-      *) $as_unset $ac_var ;;
-      esac ;;
-    esac
-  done
-
-  (set) 2>&1 |
-    case $as_nl`(ac_space=' '; set) 2>&1` in #(
-    *${as_nl}ac_space=\ *)
-      # `set' does not quote correctly, so add quotes (double-quote
-      # substitution turns \\\\ into \\, and sed turns \\ into \).
-      sed -n \
-	"s/'/'\\\\''/g;
-	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
-      ;; #(
-    *)
-      # `set' quotes correctly as required by POSIX, so do not add quotes.
-      sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
-      ;;
-    esac |
-    sort
-) |
-  sed '
-     /^ac_cv_env_/b end
-     t clear
-     :clear
-     s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
-     t end
-     s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
-     :end' >>confcache
-if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
-  if test -w "$cache_file"; then
-    test "x$cache_file" != "x/dev/null" &&
-      { echo "$as_me:$LINENO: updating cache $cache_file" >&5
-echo "$as_me: updating cache $cache_file" >&6;}
-    cat confcache >$cache_file
-  else
-    { echo "$as_me:$LINENO: not updating unwritable cache $cache_file" >&5
-echo "$as_me: not updating unwritable cache $cache_file" >&6;}
-  fi
-fi
-rm -f confcache
-
-test "x$prefix" = xNONE && prefix=$ac_default_prefix
-# Let make expand exec_prefix.
-test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
-
-# Transform confdefs.h into DEFS.
-# Protect against shell expansion while executing Makefile rules.
-# Protect against Makefile macro expansion.
-#
-# If the first sed substitution is executed (which looks for macros that
-# take arguments), then branch to the quote section.  Otherwise,
-# look for a macro that doesn't take arguments.
-ac_script='
-t clear
-:clear
-s/^[	 ]*#[	 ]*define[	 ][	 ]*\([^	 (][^	 (]*([^)]*)\)[	 ]*\(.*\)/-D\1=\2/g
-t quote
-s/^[	 ]*#[	 ]*define[	 ][	 ]*\([^	 ][^	 ]*\)[	 ]*\(.*\)/-D\1=\2/g
-t quote
-b any
-:quote
-s/[	 `~#$^&*(){}\\|;'\''"<>?]/\\&/g
-s/\[/\\&/g
-s/\]/\\&/g
-s/\$/$$/g
-H
-:any
-${
-	g
-	s/^\n//
-	s/\n/ /g
-	p
-}
-'
-DEFS=`sed -n "$ac_script" confdefs.h`
-
-
-ac_libobjs=
-ac_ltlibobjs=
-for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
-  # 1. Remove the extension, and $U if already installed.
-  ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
-  ac_i=`echo "$ac_i" | sed "$ac_script"`
-  # 2. Prepend LIBOBJDIR.  When used with automake>=1.10 LIBOBJDIR
-  #    will be set to the directory where LIBOBJS objects are built.
-  ac_libobjs="$ac_libobjs \${LIBOBJDIR}$ac_i\$U.$ac_objext"
-  ac_ltlibobjs="$ac_ltlibobjs \${LIBOBJDIR}$ac_i"'$U.lo'
-done
-LIBOBJS=$ac_libobjs
-
-LTLIBOBJS=$ac_ltlibobjs
-
-
-CFLAGS="${CFLAGS} ${CPPFLAGS}"; CPPFLAGS=""
-
-: ${CONFIG_STATUS=./config.status}
-ac_clean_files_save=$ac_clean_files
-ac_clean_files="$ac_clean_files $CONFIG_STATUS"
-{ echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
-echo "$as_me: creating $CONFIG_STATUS" >&6;}
-cat >$CONFIG_STATUS <<_ACEOF
-#! $SHELL
-# Generated by $as_me.
-# Run this file to recreate the current configuration.
-# Compiler output produced by configure, useful for debugging
-# configure, is in config.log if it exists.
-
-debug=false
-ac_cs_recheck=false
-ac_cs_silent=false
-SHELL=\${CONFIG_SHELL-$SHELL}
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF
-## --------------------- ##
-## M4sh Initialization.  ##
-## --------------------- ##
-
-# Be more Bourne compatible
-DUALCASE=1; export DUALCASE # for MKS sh
-if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
-  emulate sh
-  NULLCMD=:
-  # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
-  # is contrary to our usage.  Disable this feature.
-  alias -g '${1+"$@"}'='"$@"'
-  setopt NO_GLOB_SUBST
-else
-  case `(set -o) 2>/dev/null` in
-  *posix*) set -o posix ;;
-esac
-
-fi
-
-
-
-
-# PATH needs CR
-# Avoid depending upon Character Ranges.
-as_cr_letters='abcdefghijklmnopqrstuvwxyz'
-as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
-as_cr_Letters=$as_cr_letters$as_cr_LETTERS
-as_cr_digits='0123456789'
-as_cr_alnum=$as_cr_Letters$as_cr_digits
-
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
-  echo "#! /bin/sh" >conf$$.sh
-  echo  "exit 0"   >>conf$$.sh
-  chmod +x conf$$.sh
-  if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
-    PATH_SEPARATOR=';'
-  else
-    PATH_SEPARATOR=:
-  fi
-  rm -f conf$$.sh
-fi
-
-# Support unset when possible.
-if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
-  as_unset=unset
-else
-  as_unset=false
-fi
-
-
-# IFS
-# We need space, tab and new line, in precisely that order.  Quoting is
-# there to prevent editors from complaining about space-tab.
-# (If _AS_PATH_WALK were called with IFS unset, it would disable word
-# splitting by setting IFS to empty value.)
-as_nl='
-'
-IFS=" ""	$as_nl"
-
-# Find who we are.  Look in the path if we contain no directory separator.
-case $0 in
-  *[\\/]* ) as_myself=$0 ;;
-  *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
-done
-IFS=$as_save_IFS
-
-     ;;
-esac
-# We did not find ourselves, most probably we were run as `sh COMMAND'
-# in which case we are not to be found in the path.
-if test "x$as_myself" = x; then
-  as_myself=$0
-fi
-if test ! -f "$as_myself"; then
-  echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
-  { (exit 1); exit 1; }
-fi
-
-# Work around bugs in pre-3.0 UWIN ksh.
-for as_var in ENV MAIL MAILPATH
-do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
-done
-PS1='$ '
-PS2='> '
-PS4='+ '
-
-# NLS nuisances.
-for as_var in \
-  LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
-  LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
-  LC_TELEPHONE LC_TIME
-do
-  if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
-    eval $as_var=C; export $as_var
-  else
-    ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
-  fi
-done
-
-# Required to use basename.
-if expr a : '\(a\)' >/dev/null 2>&1 &&
-   test "X`expr 00001 : '.*\(...\)'`" = X001; then
-  as_expr=expr
-else
-  as_expr=false
-fi
-
-if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
-  as_basename=basename
-else
-  as_basename=false
-fi
-
-
-# Name of the executable.
-as_me=`$as_basename -- "$0" ||
-$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
-	 X"$0" : 'X\(//\)$' \| \
-	 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
-echo X/"$0" |
-    sed '/^.*\/\([^/][^/]*\)\/*$/{
-	    s//\1/
-	    q
-	  }
-	  /^X\/\(\/\/\)$/{
-	    s//\1/
-	    q
-	  }
-	  /^X\/\(\/\).*/{
-	    s//\1/
-	    q
-	  }
-	  s/.*/./; q'`
-
-# CDPATH.
-$as_unset CDPATH
-
-
-
-  as_lineno_1=$LINENO
-  as_lineno_2=$LINENO
-  test "x$as_lineno_1" != "x$as_lineno_2" &&
-  test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || {
-
-  # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
-  # uniformly replaced by the line number.  The first 'sed' inserts a
-  # line-number line after each line using $LINENO; the second 'sed'
-  # does the real work.  The second script uses 'N' to pair each
-  # line-number line with the line containing $LINENO, and appends
-  # trailing '-' during substitution so that $LINENO is not a special
-  # case at line end.
-  # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
-  # scripts with optimization help from Paolo Bonzini.  Blame Lee
-  # E. McMahon (1931-1989) for sed's syntax.  :-)
-  sed -n '
-    p
-    /[$]LINENO/=
-  ' <$as_myself |
-    sed '
-      s/[$]LINENO.*/&-/
-      t lineno
-      b
-      :lineno
-      N
-      :loop
-      s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
-      t loop
-      s/-\n.*//
-    ' >$as_me.lineno &&
-  chmod +x "$as_me.lineno" ||
-    { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
-   { (exit 1); exit 1; }; }
-
-  # Don't try to exec as it changes $[0], causing all sort of problems
-  # (the dirname of $[0] is not the place where we might find the
-  # original and so on.  Autoconf is especially sensitive to this).
-  . "./$as_me.lineno"
-  # Exit status is that of the last command.
-  exit
-}
-
-
-if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
-  as_dirname=dirname
-else
-  as_dirname=false
-fi
-
-ECHO_C= ECHO_N= ECHO_T=
-case `echo -n x` in
--n*)
-  case `echo 'x\c'` in
-  *c*) ECHO_T='	';;	# ECHO_T is single tab character.
-  *)   ECHO_C='\c';;
-  esac;;
-*)
-  ECHO_N='-n';;
-esac
-
-if expr a : '\(a\)' >/dev/null 2>&1 &&
-   test "X`expr 00001 : '.*\(...\)'`" = X001; then
-  as_expr=expr
-else
-  as_expr=false
-fi
-
-rm -f conf$$ conf$$.exe conf$$.file
-if test -d conf$$.dir; then
-  rm -f conf$$.dir/conf$$.file
-else
-  rm -f conf$$.dir
-  mkdir conf$$.dir
-fi
-echo >conf$$.file
-if ln -s conf$$.file conf$$ 2>/dev/null; then
-  as_ln_s='ln -s'
-  # ... but there are two gotchas:
-  # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
-  # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
-  # In both cases, we have to default to `cp -p'.
-  ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
-    as_ln_s='cp -p'
-elif ln conf$$.file conf$$ 2>/dev/null; then
-  as_ln_s=ln
-else
-  as_ln_s='cp -p'
-fi
-rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
-rmdir conf$$.dir 2>/dev/null
-
-if mkdir -p . 2>/dev/null; then
-  as_mkdir_p=:
-else
-  test -d ./-p && rmdir ./-p
-  as_mkdir_p=false
-fi
-
-if test -x / >/dev/null 2>&1; then
-  as_test_x='test -x'
-else
-  if ls -dL / >/dev/null 2>&1; then
-    as_ls_L_option=L
-  else
-    as_ls_L_option=
-  fi
-  as_test_x='
-    eval sh -c '\''
-      if test -d "$1"; then
-        test -d "$1/.";
-      else
-	case $1 in
-        -*)set "./$1";;
-	esac;
-	case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in
-	???[sx]*):;;*)false;;esac;fi
-    '\'' sh
-  '
-fi
-as_executable_p=$as_test_x
-
-# Sed expression to map a string onto a valid CPP name.
-as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
-
-# Sed expression to map a string onto a valid variable name.
-as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
-
-
-exec 6>&1
-
-# Save the log message, to keep $[0] and so on meaningful, and to
-# report actual input values of CONFIG_FILES etc. instead of their
-# values after options handling.
-ac_log="
-This file was extended by Tclxml $as_me 3.2, which was
-generated by GNU Autoconf 2.61.  Invocation command line was
-
-  CONFIG_FILES    = $CONFIG_FILES
-  CONFIG_HEADERS  = $CONFIG_HEADERS
-  CONFIG_LINKS    = $CONFIG_LINKS
-  CONFIG_COMMANDS = $CONFIG_COMMANDS
-  $ $0 $@
-
-on `(hostname || uname -n) 2>/dev/null | sed 1q`
-"
-
-_ACEOF
-
-cat >>$CONFIG_STATUS <<_ACEOF
-# Files that config.status was made for.
-config_files="$ac_config_files"
-
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF
-ac_cs_usage="\
-\`$as_me' instantiates files from templates according to the
-current configuration.
-
-Usage: $0 [OPTIONS] [FILE]...
-
-  -h, --help       print this help, then exit
-  -V, --version    print version number and configuration settings, then exit
-  -q, --quiet      do not print progress messages
-  -d, --debug      don't remove temporary files
-      --recheck    update $as_me by reconfiguring in the same conditions
-  --file=FILE[:TEMPLATE]
-		   instantiate the configuration file FILE
-
-Configuration files:
-$config_files
-
-Report bugs to <bug-autoconf at gnu.org>."
-
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF
-ac_cs_version="\\
-Tclxml config.status 3.2
-configured by $0, generated by GNU Autoconf 2.61,
-  with options \\"`echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
-
-Copyright (C) 2006 Free Software Foundation, Inc.
-This config.status script is free software; the Free Software Foundation
-gives unlimited permission to copy, distribute and modify it."
-
-ac_pwd='$ac_pwd'
-srcdir='$srcdir'
-INSTALL='$INSTALL'
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF
-# If no file are specified by the user, then we need to provide default
-# value.  By we need to know if files were specified by the user.
-ac_need_defaults=:
-while test $# != 0
-do
-  case $1 in
-  --*=*)
-    ac_option=`expr "X$1" : 'X\([^=]*\)='`
-    ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
-    ac_shift=:
-    ;;
-  *)
-    ac_option=$1
-    ac_optarg=$2
-    ac_shift=shift
-    ;;
-  esac
-
-  case $ac_option in
-  # Handling of the options.
-  -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
-    ac_cs_recheck=: ;;
-  --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
-    echo "$ac_cs_version"; exit ;;
-  --debug | --debu | --deb | --de | --d | -d )
-    debug=: ;;
-  --file | --fil | --fi | --f )
-    $ac_shift
-    CONFIG_FILES="$CONFIG_FILES $ac_optarg"
-    ac_need_defaults=false;;
-  --he | --h |  --help | --hel | -h )
-    echo "$ac_cs_usage"; exit ;;
-  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
-  | -silent | --silent | --silen | --sile | --sil | --si | --s)
-    ac_cs_silent=: ;;
-
-  # This is an error.
-  -*) { echo "$as_me: error: unrecognized option: $1
-Try \`$0 --help' for more information." >&2
-   { (exit 1); exit 1; }; } ;;
-
-  *) ac_config_targets="$ac_config_targets $1"
-     ac_need_defaults=false ;;
-
-  esac
-  shift
-done
-
-ac_configure_extra_args=
-
-if $ac_cs_silent; then
-  exec 6>/dev/null
-  ac_configure_extra_args="$ac_configure_extra_args --silent"
-fi
-
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF
-if \$ac_cs_recheck; then
-  echo "running CONFIG_SHELL=$SHELL $SHELL $0 "$ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6
-  CONFIG_SHELL=$SHELL
-  export CONFIG_SHELL
-  exec $SHELL "$0"$ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
-fi
-
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF
-exec 5>>config.log
-{
-  echo
-  sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
-## Running $as_me. ##
-_ASBOX
-  echo "$ac_log"
-} >&5
-
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF
-
-# Handling of arguments.
-for ac_config_target in $ac_config_targets
-do
-  case $ac_config_target in
-    "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
-    "Makefile.macosx") CONFIG_FILES="$CONFIG_FILES Makefile.macosx" ;;
-    "pkgIndex.tcl") CONFIG_FILES="$CONFIG_FILES pkgIndex.tcl" ;;
-    "TclxmlConfig.sh") CONFIG_FILES="$CONFIG_FILES TclxmlConfig.sh" ;;
-    "include/tclxml/tclxml.h") CONFIG_FILES="$CONFIG_FILES include/tclxml/tclxml.h" ;;
-    "doc/tclxml.xml") CONFIG_FILES="$CONFIG_FILES doc/tclxml.xml" ;;
-    "doc/tcldom.xml") CONFIG_FILES="$CONFIG_FILES doc/tcldom.xml" ;;
-    "doc/tclxslt.xml") CONFIG_FILES="$CONFIG_FILES doc/tclxslt.xml" ;;
-    "doc/README.xml") CONFIG_FILES="$CONFIG_FILES doc/README.xml" ;;
-
-  *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
-echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
-   { (exit 1); exit 1; }; };;
-  esac
-done
-
-
-# If the user did not use the arguments to specify the items to instantiate,
-# then the envvar interface is used.  Set only those that are not.
-# We use the long form for the default assignment because of an extremely
-# bizarre bug on SunOS 4.1.3.
-if $ac_need_defaults; then
-  test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
-fi
-
-# Have a temporary directory for convenience.  Make it in the build tree
-# simply because there is no reason against having it here, and in addition,
-# creating and moving files from /tmp can sometimes cause problems.
-# Hook for its removal unless debugging.
-# Note that there is a small window in which the directory will not be cleaned:
-# after its creation but before its name has been assigned to `$tmp'.
-$debug ||
-{
-  tmp=
-  trap 'exit_status=$?
-  { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
-' 0
-  trap '{ (exit 1); exit 1; }' 1 2 13 15
-}
-# Create a (secure) tmp directory for tmp files.
-
-{
-  tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
-  test -n "$tmp" && test -d "$tmp"
-}  ||
-{
-  tmp=./conf$$-$RANDOM
-  (umask 077 && mkdir "$tmp")
-} ||
-{
-   echo "$me: cannot create a temporary directory in ." >&2
-   { (exit 1); exit 1; }
-}
-
-#
-# Set up the sed scripts for CONFIG_FILES section.
-#
-
-# No need to generate the scripts if there are no CONFIG_FILES.
-# This happens for instance when ./config.status config.h
-if test -n "$CONFIG_FILES"; then
-
-_ACEOF
-
-
-
-ac_delim='%!_!# '
-for ac_last_try in false false false false false :; do
-  cat >conf$$subs.sed <<_ACEOF
-SHELL!$SHELL$ac_delim
-PATH_SEPARATOR!$PATH_SEPARATOR$ac_delim
-PACKAGE_NAME!$PACKAGE_NAME$ac_delim
-PACKAGE_TARNAME!$PACKAGE_TARNAME$ac_delim
-PACKAGE_VERSION!$PACKAGE_VERSION$ac_delim
-PACKAGE_STRING!$PACKAGE_STRING$ac_delim
-PACKAGE_BUGREPORT!$PACKAGE_BUGREPORT$ac_delim
-exec_prefix!$exec_prefix$ac_delim
-prefix!$prefix$ac_delim
-program_transform_name!$program_transform_name$ac_delim
-bindir!$bindir$ac_delim
-sbindir!$sbindir$ac_delim
-libexecdir!$libexecdir$ac_delim
-datarootdir!$datarootdir$ac_delim
-datadir!$datadir$ac_delim
-sysconfdir!$sysconfdir$ac_delim
-sharedstatedir!$sharedstatedir$ac_delim
-localstatedir!$localstatedir$ac_delim
-includedir!$includedir$ac_delim
-oldincludedir!$oldincludedir$ac_delim
-docdir!$docdir$ac_delim
-infodir!$infodir$ac_delim
-htmldir!$htmldir$ac_delim
-dvidir!$dvidir$ac_delim
-pdfdir!$pdfdir$ac_delim
-psdir!$psdir$ac_delim
-libdir!$libdir$ac_delim
-localedir!$localedir$ac_delim
-mandir!$mandir$ac_delim
-DEFS!$DEFS$ac_delim
-ECHO_C!$ECHO_C$ac_delim
-ECHO_N!$ECHO_N$ac_delim
-ECHO_T!$ECHO_T$ac_delim
-LIBS!$LIBS$ac_delim
-build_alias!$build_alias$ac_delim
-host_alias!$host_alias$ac_delim
-target_alias!$target_alias$ac_delim
-CYGPATH!$CYGPATH$ac_delim
-EXEEXT!$EXEEXT$ac_delim
-PKG_LIB_FILE!$PKG_LIB_FILE$ac_delim
-PKG_STUB_LIB_FILE!$PKG_STUB_LIB_FILE$ac_delim
-PKG_STUB_SOURCES!$PKG_STUB_SOURCES$ac_delim
-PKG_STUB_OBJECTS!$PKG_STUB_OBJECTS$ac_delim
-PKG_TCL_SOURCES!$PKG_TCL_SOURCES$ac_delim
-PKG_HEADERS!$PKG_HEADERS$ac_delim
-PKG_INCLUDES!$PKG_INCLUDES$ac_delim
-PKG_LIBS!$PKG_LIBS$ac_delim
-PKG_CFLAGS!$PKG_CFLAGS$ac_delim
-TCL_VERSION!$TCL_VERSION$ac_delim
-TCL_BIN_DIR!$TCL_BIN_DIR$ac_delim
-TCL_SRC_DIR!$TCL_SRC_DIR$ac_delim
-TCL_LIB_FILE!$TCL_LIB_FILE$ac_delim
-TCL_LIB_FLAG!$TCL_LIB_FLAG$ac_delim
-TCL_LIB_SPEC!$TCL_LIB_SPEC$ac_delim
-TCL_STUB_LIB_FILE!$TCL_STUB_LIB_FILE$ac_delim
-TCL_STUB_LIB_FLAG!$TCL_STUB_LIB_FLAG$ac_delim
-TCL_STUB_LIB_SPEC!$TCL_STUB_LIB_SPEC$ac_delim
-TCL_LIBS!$TCL_LIBS$ac_delim
-TCL_DEFS!$TCL_DEFS$ac_delim
-TCL_EXTRA_CFLAGS!$TCL_EXTRA_CFLAGS$ac_delim
-TCL_LD_FLAGS!$TCL_LD_FLAGS$ac_delim
-TCL_SHLIB_LD_LIBS!$TCL_SHLIB_LD_LIBS$ac_delim
-CC!$CC$ac_delim
-CFLAGS!$CFLAGS$ac_delim
-LDFLAGS!$LDFLAGS$ac_delim
-CPPFLAGS!$CPPFLAGS$ac_delim
-ac_ct_CC!$ac_ct_CC$ac_delim
-OBJEXT!$OBJEXT$ac_delim
-CPP!$CPP$ac_delim
-INSTALL_PROGRAM!$INSTALL_PROGRAM$ac_delim
-INSTALL_SCRIPT!$INSTALL_SCRIPT$ac_delim
-INSTALL_DATA!$INSTALL_DATA$ac_delim
-SET_MAKE!$SET_MAKE$ac_delim
-RANLIB!$RANLIB$ac_delim
-GREP!$GREP$ac_delim
-EGREP!$EGREP$ac_delim
-MATH_LIBS!$MATH_LIBS$ac_delim
-PKG_SOURCES!$PKG_SOURCES$ac_delim
-PKG_OBJECTS!$PKG_OBJECTS$ac_delim
-CLEANFILES!$CLEANFILES$ac_delim
-TCL_INCLUDES!$TCL_INCLUDES$ac_delim
-TCL_THREADS!$TCL_THREADS$ac_delim
-SHARED_BUILD!$SHARED_BUILD$ac_delim
-AR!$AR$ac_delim
-CELIB_DIR!$CELIB_DIR$ac_delim
-LIBOBJS!$LIBOBJS$ac_delim
-DL_LIBS!$DL_LIBS$ac_delim
-CFLAGS_DEBUG!$CFLAGS_DEBUG$ac_delim
-CFLAGS_OPTIMIZE!$CFLAGS_OPTIMIZE$ac_delim
-CFLAGS_WARNING!$CFLAGS_WARNING$ac_delim
-STLIB_LD!$STLIB_LD$ac_delim
-SHLIB_LD!$SHLIB_LD$ac_delim
-SHLIB_LD_LIBS!$SHLIB_LD_LIBS$ac_delim
-SHLIB_CFLAGS!$SHLIB_CFLAGS$ac_delim
-LD_LIBRARY_PATH_VAR!$LD_LIBRARY_PATH_VAR$ac_delim
-TCL_DBGX!$TCL_DBGX$ac_delim
-CFLAGS_DEFAULT!$CFLAGS_DEFAULT$ac_delim
-_ACEOF
-
-  if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 97; then
-    break
-  elif $ac_last_try; then
-    { { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
-echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
-   { (exit 1); exit 1; }; }
-  else
-    ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
-  fi
-done
-
-ac_eof=`sed -n '/^CEOF[0-9]*$/s/CEOF/0/p' conf$$subs.sed`
-if test -n "$ac_eof"; then
-  ac_eof=`echo "$ac_eof" | sort -nru | sed 1q`
-  ac_eof=`expr $ac_eof + 1`
-fi
-
-cat >>$CONFIG_STATUS <<_ACEOF
-cat >"\$tmp/subs-1.sed" <<\CEOF$ac_eof
-/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
-_ACEOF
-sed '
-s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g
-s/^/s,@/; s/!/@,|#_!!_#|/
-:n
-t n
-s/'"$ac_delim"'$/,g/; t
-s/$/\\/; p
-N; s/^.*\n//; s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g; b n
-' >>$CONFIG_STATUS <conf$$subs.sed
-rm -f conf$$subs.sed
-cat >>$CONFIG_STATUS <<_ACEOF
-CEOF$ac_eof
-_ACEOF
-
-
-ac_delim='%!_!# '
-for ac_last_try in false false false false false :; do
-  cat >conf$$subs.sed <<_ACEOF
-LDFLAGS_DEFAULT!$LDFLAGS_DEFAULT$ac_delim
-MAKE_LIB!$MAKE_LIB$ac_delim
-MAKE_SHARED_LIB!$MAKE_SHARED_LIB$ac_delim
-MAKE_STATIC_LIB!$MAKE_STATIC_LIB$ac_delim
-MAKE_STUB_LIB!$MAKE_STUB_LIB$ac_delim
-RANLIB_STUB!$RANLIB_STUB$ac_delim
-XML2_PREFIX!$XML2_PREFIX$ac_delim
-XML2_CFLAGS!$XML2_CFLAGS$ac_delim
-XML2_VERSION!$XML2_VERSION$ac_delim
-XSLT_VERSION!$XSLT_VERSION$ac_delim
-XSLT_PREFIX!$XSLT_PREFIX$ac_delim
-XSLT_CFLAGS!$XSLT_CFLAGS$ac_delim
-XML_STATIC!$XML_STATIC$ac_delim
-XML2_LIBS!$XML2_LIBS$ac_delim
-XSLT_LIBS!$XSLT_LIBS$ac_delim
-FIX_LIB!$FIX_LIB$ac_delim
-TCLSH_PROG!$TCLSH_PROG$ac_delim
-Tclxml_BUILD_LIB_SPEC!$Tclxml_BUILD_LIB_SPEC$ac_delim
-Tclxml_LIB_SPEC!$Tclxml_LIB_SPEC$ac_delim
-Tclxml_BUILD_STUB_LIB_SPEC!$Tclxml_BUILD_STUB_LIB_SPEC$ac_delim
-Tclxml_STUB_LIB_SPEC!$Tclxml_STUB_LIB_SPEC$ac_delim
-Tclxml_BUILD_STUB_LIB_PATH!$Tclxml_BUILD_STUB_LIB_PATH$ac_delim
-Tclxml_STUB_LIB_PATH!$Tclxml_STUB_LIB_PATH$ac_delim
-Tclxml_INCLUDE_SPEC!$Tclxml_INCLUDE_SPEC$ac_delim
-XSLTPROC!$XSLTPROC$ac_delim
-LTLIBOBJS!$LTLIBOBJS$ac_delim
-_ACEOF
-
-  if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 26; then
-    break
-  elif $ac_last_try; then
-    { { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
-echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
-   { (exit 1); exit 1; }; }
-  else
-    ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
-  fi
-done
-
-ac_eof=`sed -n '/^CEOF[0-9]*$/s/CEOF/0/p' conf$$subs.sed`
-if test -n "$ac_eof"; then
-  ac_eof=`echo "$ac_eof" | sort -nru | sed 1q`
-  ac_eof=`expr $ac_eof + 1`
-fi
-
-cat >>$CONFIG_STATUS <<_ACEOF
-cat >"\$tmp/subs-2.sed" <<\CEOF$ac_eof
-/@[a-zA-Z_][a-zA-Z_0-9]*@/!b end
-_ACEOF
-sed '
-s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g
-s/^/s,@/; s/!/@,|#_!!_#|/
-:n
-t n
-s/'"$ac_delim"'$/,g/; t
-s/$/\\/; p
-N; s/^.*\n//; s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g; b n
-' >>$CONFIG_STATUS <conf$$subs.sed
-rm -f conf$$subs.sed
-cat >>$CONFIG_STATUS <<_ACEOF
-:end
-s/|#_!!_#|//g
-CEOF$ac_eof
-_ACEOF
-
-
-# VPATH may cause trouble with some makes, so we remove $(srcdir),
-# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
-# trailing colons and then remove the whole line if VPATH becomes empty
-# (actually we leave an empty line to preserve line numbers).
-if test "x$srcdir" = x.; then
-  ac_vpsub='/^[	 ]*VPATH[	 ]*=/{
-s/:*\$(srcdir):*/:/
-s/:*\${srcdir}:*/:/
-s/:*@srcdir@:*/:/
-s/^\([^=]*=[	 ]*\):*/\1/
-s/:*$//
-s/^[^=]*=[	 ]*$//
-}'
-fi
-
-cat >>$CONFIG_STATUS <<\_ACEOF
-fi # test -n "$CONFIG_FILES"
-
-
-for ac_tag in  :F $CONFIG_FILES
-do
-  case $ac_tag in
-  :[FHLC]) ac_mode=$ac_tag; continue;;
-  esac
-  case $ac_mode$ac_tag in
-  :[FHL]*:*);;
-  :L* | :C*:*) { { echo "$as_me:$LINENO: error: Invalid tag $ac_tag." >&5
-echo "$as_me: error: Invalid tag $ac_tag." >&2;}
-   { (exit 1); exit 1; }; };;
-  :[FH]-) ac_tag=-:-;;
-  :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
-  esac
-  ac_save_IFS=$IFS
-  IFS=:
-  set x $ac_tag
-  IFS=$ac_save_IFS
-  shift
-  ac_file=$1
-  shift
-
-  case $ac_mode in
-  :L) ac_source=$1;;
-  :[FH])
-    ac_file_inputs=
-    for ac_f
-    do
-      case $ac_f in
-      -) ac_f="$tmp/stdin";;
-      *) # Look for the file first in the build tree, then in the source tree
-	 # (if the path is not absolute).  The absolute path cannot be DOS-style,
-	 # because $ac_f cannot contain `:'.
-	 test -f "$ac_f" ||
-	   case $ac_f in
-	   [\\/$]*) false;;
-	   *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
-	   esac ||
-	   { { echo "$as_me:$LINENO: error: cannot find input file: $ac_f" >&5
-echo "$as_me: error: cannot find input file: $ac_f" >&2;}
-   { (exit 1); exit 1; }; };;
-      esac
-      ac_file_inputs="$ac_file_inputs $ac_f"
-    done
-
-    # Let's still pretend it is `configure' which instantiates (i.e., don't
-    # use $as_me), people would be surprised to read:
-    #    /* config.h.  Generated by config.status.  */
-    configure_input="Generated from "`IFS=:
-	  echo $* | sed 's|^[^:]*/||;s|:[^:]*/|, |g'`" by configure."
-    if test x"$ac_file" != x-; then
-      configure_input="$ac_file.  $configure_input"
-      { echo "$as_me:$LINENO: creating $ac_file" >&5
-echo "$as_me: creating $ac_file" >&6;}
-    fi
-
-    case $ac_tag in
-    *:-:* | *:-) cat >"$tmp/stdin";;
-    esac
-    ;;
-  esac
-
-  ac_dir=`$as_dirname -- "$ac_file" ||
-$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
-	 X"$ac_file" : 'X\(//\)[^/]' \| \
-	 X"$ac_file" : 'X\(//\)$' \| \
-	 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
-echo X"$ac_file" |
-    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
-	    s//\1/
-	    q
-	  }
-	  /^X\(\/\/\)[^/].*/{
-	    s//\1/
-	    q
-	  }
-	  /^X\(\/\/\)$/{
-	    s//\1/
-	    q
-	  }
-	  /^X\(\/\).*/{
-	    s//\1/
-	    q
-	  }
-	  s/.*/./; q'`
-  { as_dir="$ac_dir"
-  case $as_dir in #(
-  -*) as_dir=./$as_dir;;
-  esac
-  test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || {
-    as_dirs=
-    while :; do
-      case $as_dir in #(
-      *\'*) as_qdir=`echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #(
-      *) as_qdir=$as_dir;;
-      esac
-      as_dirs="'$as_qdir' $as_dirs"
-      as_dir=`$as_dirname -- "$as_dir" ||
-$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
-	 X"$as_dir" : 'X\(//\)[^/]' \| \
-	 X"$as_dir" : 'X\(//\)$' \| \
-	 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
-echo X"$as_dir" |
-    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
-	    s//\1/
-	    q
-	  }
-	  /^X\(\/\/\)[^/].*/{
-	    s//\1/
-	    q
-	  }
-	  /^X\(\/\/\)$/{
-	    s//\1/
-	    q
-	  }
-	  /^X\(\/\).*/{
-	    s//\1/
-	    q
-	  }
-	  s/.*/./; q'`
-      test -d "$as_dir" && break
-    done
-    test -z "$as_dirs" || eval "mkdir $as_dirs"
-  } || test -d "$as_dir" || { { echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5
-echo "$as_me: error: cannot create directory $as_dir" >&2;}
-   { (exit 1); exit 1; }; }; }
-  ac_builddir=.
-
-case "$ac_dir" in
-.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
-*)
-  ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
-  # A ".." for each directory in $ac_dir_suffix.
-  ac_top_builddir_sub=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,/..,g;s,/,,'`
-  case $ac_top_builddir_sub in
-  "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
-  *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
-  esac ;;
-esac
-ac_abs_top_builddir=$ac_pwd
-ac_abs_builddir=$ac_pwd$ac_dir_suffix
-# for backward compatibility:
-ac_top_builddir=$ac_top_build_prefix
-
-case $srcdir in
-  .)  # We are building in place.
-    ac_srcdir=.
-    ac_top_srcdir=$ac_top_builddir_sub
-    ac_abs_top_srcdir=$ac_pwd ;;
-  [\\/]* | ?:[\\/]* )  # Absolute name.
-    ac_srcdir=$srcdir$ac_dir_suffix;
-    ac_top_srcdir=$srcdir
-    ac_abs_top_srcdir=$srcdir ;;
-  *) # Relative name.
-    ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
-    ac_top_srcdir=$ac_top_build_prefix$srcdir
-    ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
-esac
-ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
-
-
-  case $ac_mode in
-  :F)
-  #
-  # CONFIG_FILE
-  #
-
-  case $INSTALL in
-  [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
-  *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
-  esac
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF
-# If the template does not know about datarootdir, expand it.
-# FIXME: This hack should be removed a few years after 2.60.
-ac_datarootdir_hack=; ac_datarootdir_seen=
-
-case `sed -n '/datarootdir/ {
-  p
-  q
-}
-/@datadir@/p
-/@docdir@/p
-/@infodir@/p
-/@localedir@/p
-/@mandir@/p
-' $ac_file_inputs` in
-*datarootdir*) ac_datarootdir_seen=yes;;
-*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
-  { echo "$as_me:$LINENO: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
-echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF
-  ac_datarootdir_hack='
-  s&@datadir@&$datadir&g
-  s&@docdir@&$docdir&g
-  s&@infodir@&$infodir&g
-  s&@localedir@&$localedir&g
-  s&@mandir@&$mandir&g
-    s&\\\${datarootdir}&$datarootdir&g' ;;
-esac
-_ACEOF
-
-# Neutralize VPATH when `$srcdir' = `.'.
-# Shell code in configure.ac might set extrasub.
-# FIXME: do we really want to maintain this feature?
-cat >>$CONFIG_STATUS <<_ACEOF
-  sed "$ac_vpsub
-$extrasub
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF
-:t
-/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
-s&@configure_input@&$configure_input&;t t
-s&@top_builddir@&$ac_top_builddir_sub&;t t
-s&@srcdir@&$ac_srcdir&;t t
-s&@abs_srcdir@&$ac_abs_srcdir&;t t
-s&@top_srcdir@&$ac_top_srcdir&;t t
-s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
-s&@builddir@&$ac_builddir&;t t
-s&@abs_builddir@&$ac_abs_builddir&;t t
-s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
-s&@INSTALL@&$ac_INSTALL&;t t
-$ac_datarootdir_hack
-" $ac_file_inputs | sed -f "$tmp/subs-1.sed" | sed -f "$tmp/subs-2.sed" >$tmp/out
-
-test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
-  { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
-  { ac_out=`sed -n '/^[	 ]*datarootdir[	 ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
-  { echo "$as_me:$LINENO: WARNING: $ac_file contains a reference to the variable \`datarootdir'
-which seems to be undefined.  Please make sure it is defined." >&5
-echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
-which seems to be undefined.  Please make sure it is defined." >&2;}
-
-  rm -f "$tmp/stdin"
-  case $ac_file in
-  -) cat "$tmp/out"; rm -f "$tmp/out";;
-  *) rm -f "$ac_file"; mv "$tmp/out" $ac_file;;
-  esac
- ;;
-
-
-
-  esac
-
-done # for ac_tag
-
-
-{ (exit 0); exit 0; }
-_ACEOF
-chmod +x $CONFIG_STATUS
-ac_clean_files=$ac_clean_files_save
-
-
-# configure is writing to config.log, and then calls config.status.
-# config.status does its own redirection, appending to config.log.
-# Unfortunately, on DOS this fails, as config.log is still kept open
-# by configure, so config.status won't be able to write to it; its
-# output is simply discarded.  So we exec the FD to /dev/null,
-# effectively closing config.log, so it can be properly (re)opened and
-# appended to by config.status.  When coming back to configure, we
-# need to make the FD available again.
-if test "$no_create" != yes; then
-  ac_cs_success=:
-  ac_config_status_args=
-  test "$silent" = yes &&
-    ac_config_status_args="$ac_config_status_args --quiet"
-  exec 5>/dev/null
-  $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
-  exec 5>>config.log
-  # Use ||, not &&, to avoid exiting from the if with $? = 1, which
-  # would make configure fail if this is the last instruction.
-  $ac_cs_success || { (exit 1); exit 1; }
-fi
-
-
-#--------------------------------------------------------------------
diff --git a/tclxml-3.2/configure.in b/tclxml-3.2/configure.in
deleted file mode 100755
index 3fde650..0000000
--- a/tclxml-3.2/configure.in
+++ /dev/null
@@ -1,331 +0,0 @@
-#!/bin/bash -norc
-dnl	This file is an input file used by the GNU "autoconf" program to
-dnl     generate the file "configure", which is run during Tcl installation
-dnl     to configure the system for the local environment.
-#
-# Copyright (c) 2007-2008 Explain/Packaged Press.
-#
-# $Id: configure.in,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-#--------------------------------------------------------------------
-# Configure script for package 'TclXML',
-# TEA compliant.
-#--------------------------------------------------------------------
-
-#--------------------------------------------------------------------
-# This very first macro is used to verify that the configure script can 
-# find the sources.  The argument to AC_INIT is a unique filename for
-# this package.
-#--------------------------------------------------------------------
-
-AC_INIT([Tclxml], [3.2])
-PACKAGE_NAME=Tclxml
-PACKAGE_VERSION=3.2
-
-TEA_INIT([3.6])
-AC_CONFIG_AUX_DIR(tclconfig)
-
-TEA_PATH_TCLCONFIG
-TEA_LOAD_TCLCONFIG
-
-TEA_PREFIX
-
-TEA_SETUP_COMPILER
-
-#-----------------------------------------------------------------------
-# Specify the C source files to compile in TEA_ADD_SOURCES,
-# public headers that need to be installed in TEA_ADD_HEADERS,
-# stub library C source files to compile in TEA_ADD_STUB_SOURCES,
-# and runtime Tcl library files in TEA_ADD_TCL_SOURCES.
-# This defines PKG(_STUB)_SOURCES, PKG(_STUB)_OBJECTS, PKG_HEADERS
-# and PKG_TCL_SOURCES.
-#-----------------------------------------------------------------------
-
-TEA_ADD_SOURCES([tclxml.c docObj.c tclxml-libxml2.c nodeObj.c tcldom-libxml2.c tclxslt-libxslt.c])
-TEA_ADD_HEADERS([include/tclxml-libxml2/docObj.h include/tclxml-libxml2/tclxml-libxml2.h include/tcldom/tcldom.h include/tcldom-libxml2/tcldom-libxml2.h include/tclxslt/tclxslt.h])
-TEA_ADD_INCLUDES([-Iinclude])
-#TEA_ADD_LIBS([-lexslt])
-TEA_ADD_LIBS([])
-TEA_ADD_CFLAGS([])
-TEA_ADD_STUB_SOURCES([tclxmlStubInit.c tclxmlStubLib.c])
-TEA_ADD_TCL_SOURCES([tclxml-tcl/xml__tcl.tcl tclxml-tcl/sgml-8.0.tcl tclxml-tcl/sgml-8.1.tcl tclxml-tcl/xml-8.0.tcl tclxml-tcl/xml-8.1.tcl tclxml-tcl/sgmlparser.tcl tclxml-tcl/tclparser-8.0.tcl tclxml-tcl/tclparser-8.1.tcl tclxml-tcl/xmldep.tcl tclxml-tcl/xpath.tcl tcldom-libxml2.tcl tcldom-tcl/xmlswitch.tcl tclxslt/process.tcl tclxslt/resources.tcl tclxslt/utilities.tcl tclxslt/xsltcache.tcl tclxslt-libxslt.tcl])
-
-#--------------------------------------------------------------------
-# A few miscellaneous platform-specific items:
-#
-# We have to define a special symbol for Windows (BUILD_Tclxml in this
-# case) so that we create the export library with the dll.
-#
-# Windows creates a few extra files that need to be cleaned up.
-# We can add more files to clean if our extension creates any extra
-# files in the future.
-#
-# TEA_ADD_* any platform specific compiler/build info here.
-#--------------------------------------------------------------------
-
-CLEANFILES=pkgIndex.tcl
-if test "${TEA_PLATFORM}" = "windows" ; then
-    AC_DEFINE(BUILD_Tclxml, 1, [Build windows export dll])
-    CLEANFILES="$CLEANFILES *.lib *.dll *.exp *.ilk *.pdb vc*.pch"
-else
-    :
-fi
-AC_SUBST(CLEANFILES)
-
-TEA_PUBLIC_TCL_HEADERS
-
-#--------------------------------------------------------------------
-# Check whether --enable-threads or --disable-threads was given.
-# So far only Tcl responds to this one.
-#--------------------------------------------------------------------
-
-TEA_ENABLE_THREADS
-
-#--------------------------------------------------------------------
-# The statement below defines a collection of symbols related to
-# building as a shared library instead of a static library.
-#--------------------------------------------------------------------
-
-TEA_ENABLE_SHARED
-
-#--------------------------------------------------------------------
-# This macro figures out what flags to use with the compiler/linker
-# when building shared/static debug/optimized objects.  This information
-# can be taken from the tclConfig.sh file, but this figures it all out.
-#--------------------------------------------------------------------
-
-TEA_CONFIG_CFLAGS
-
-#--------------------------------------------------------------------
-# Set the default compiler switches based on the --enable-symbols option.
-#--------------------------------------------------------------------
-
-TEA_ENABLE_SYMBOLS
-
-#--------------------------------------------------------------------
-# Everyone should be linking against the Tcl stub library.  If you
-# can't for some reason, remove this definition.  If you aren't using
-# stubs, you also need to modify the SHLIB_LD_LIBS setting below to
-# link against the non-stubbed Tcl library.
-#--------------------------------------------------------------------
-
-AC_DEFINE(USE_TCL_STUBS, 1, [Use Tcl stubs])
-
-#--------------------------------------------------------------------
-# This macro generates a line to use when building a library.  It
-# depends on values set by the TEA_ENABLE_SHARED, TEA_ENABLE_SYMBOLS,
-# and TEA_LOAD_TCLCONFIG macros above.
-#--------------------------------------------------------------------
-
-TEA_MAKE_LIB
-
-#--------------------------------------------------------------------
-# On Mac OS X we may want to build as a framework.
-# This affects the location and naming of headers and libaries.
-#--------------------------------------------------------------------
-
-AC_ARG_ENABLE(framework, [  --enable-framework      build as a Mac OS X framework],
-        [tcl_ok=$enableval], [tcl_ok=$1])
-
-#--------------------------------------------------------------------
-# Load libxml2 configuration
-#--------------------------------------------------------------------
-
-AC_MSG_CHECKING([for xml2-config script])
-
-AC_ARG_WITH(xml2-config,
-    [  --with-xml2-config      the xml2-config configuration script],
-    with_xml2_config=${withval})
-
-LIBXML2_CONFIG=
-if test "x${with_xml2_config}" = "x" ; then
-    for c in \
-	/Library/Frameworks/libxml.framework/Resources/Scripts/xml2-config \
-	${prefix}/bin/xml2-config \
-	/usr/bin/xml2-config \
-	/usr/local/bin/xml2-config
-    do
-	if test -x "$c" ; then
-	    LIBXML2_CONFIG="$c"
-	    break
-	fi
-    done
-else
-    LIBXML2_CONFIG="${with_xml2_config}"
-fi
-if test "x$LIBXML2_CONFIG" = "x" ; then
-    AC_MSG_ERROR([unable to find xml2-config])
-else
-    AC_MSG_RESULT([${LIBXML2_CONFIG}])
-    XML2_VERSION=`${LIBXML2_CONFIG} --version`
-    XML2_PREFIX=`${LIBXML2_CONFIG} --prefix`
-    XML2_LIBS="`${LIBXML2_CONFIG} --libs`"
-    XML2_CFLAGS=`${LIBXML2_CONFIG} --cflags`
-fi
-
-AC_SUBST(XML2_PREFIX)
-AC_SUBST(XML2_CFLAGS)
-AC_SUBST(XML2_VERSION)
-
-#--------------------------------------------------------------------
-# Load libxslt configuration
-#--------------------------------------------------------------------
-
-AC_MSG_CHECKING([for xslt-config script])
-
-AC_ARG_WITH(xslt-config,
-    [  --with-xslt-config      the xslt-config configuration script],
-    with_xslt_config=${withval})
-
-LIBXSLT_CONFIG=
-if test "x${with_xslt_config}" = "x" ; then
-    if test "x${with_xml2_config}" = "x" ; then
-	:
-    else
-	if test -x "`dirname ${with_xml2_config}`/xslt-config" ; then
-	    LIBXSLT_CONFIG="`dirname ${with_xml2_config}`/xslt-config"
-	fi
-    fi
-else
-    LIBXSLT_CONFIG="${with_xslt_config}"
-fi
-if test "x${LIBXSLT_CONFIG}" = "x" ; then
-    for c in \
-	/Library/Frameworks/libxslt.framework/Resources/Scripts/xslt-config \
-	${prefix}/bin/xslt-config \
-	/usr/bin/xslt-config \
-	/usr/local/bin/xslt-config
-    do
-	if test -x "$c" ; then
-	    LIBXSLT_CONFIG="$c"
-	    break
-	fi
-    done
-fi
-if test "x$LIBXSLT_CONFIG" = "x" ; then
-    AC_MSG_ERROR([unable to find xslt-config script])
-else
-    AC_MSG_RESULT([${LIBXSLT_CONFIG}])
-    XSLT_VERSION=`${LIBXSLT_CONFIG} --version`
-    XSLT_PREFIX=`${LIBXSLT_CONFIG} --prefix`
-    XSLT_CFLAGS=`${LIBXSLT_CONFIG} --cflags`
-    XSLT_LIBS="`${LIBXSLT_CONFIG} --libs` -lexslt"
-fi
-
-AC_SUBST(XSLT_VERSION)
-AC_SUBST(XSLT_PREFIX)
-AC_SUBST(XSLT_CFLAGS)
-
-#--------------------------------------------------------------------
-# See if we want to statically link the libxml2 and libxslt
-# libraries. This is desirable for Tclkit.
-#--------------------------------------------------------------------
-
-AC_MSG_CHECKING([for static linking of XML/XSLT libraries])
-
-AC_ARG_WITH(xml-static,
-    [  --with-xml-static      statically link the XML libraries],
-    with_xml_static=${withval})
-
-XML_STATIC="0"
-if test "${with_xml_static}" = "1" ; then
-    XML_STATIC="1"
-    AC_MSG_RESULT([use static linking])
-else
-    AC_MSG_RESULT([use dynamic linking])
-fi
-
-AC_SUBST(XML_STATIC)
-
-#--------------------------------------------------------------------
-# __CHANGE__
-# Add platform libs to LIBS or SHLIB_LD_LIBS as necessary.
-#--------------------------------------------------------------------
-
-FIX_LIB=":"
-if test "${TEA_PLATFORM}" = "windows" -a "$GCC" != "yes" ; then
-    SHLIB_LD_LIBS="${SHLIB_LD_LIBS} \"`${CYGPATH} ${LIBXSLT_LIBDIR}/libxslt.lib`\""
-    SHLIB_LD_LIBS="${SHLIB_LD_LIBS} \"`${CYGPATH} ${LIBXSLT_LIBDIR}/libexslt.lib`\""
-    SHLIB_LD_LIBS="${SHLIB_LD_LIBS} \"`${CYGPATH} ${LIBXML2_LIBDIR}/libxml2.lib`\""
-else
-if test "${XML_STATIC}" = "0" ; then
-    echo "setting up dynamic linking"
-    SHLIB_LD_LIBS="${SHLIB_LD_LIBS} \${XSLT_LIBS}"
-else
-    SHLIB_LD_LIBS="${SHLIB_LD_LIBS} ${XSLT_PREFIX}/lib/libexslt.a"
-    SHLIB_LD_LIBS="${SHLIB_LD_LIBS} ${XSLT_PREFIX}/lib/libxslt.a"
-    SHLIB_LD_LIBS="${SHLIB_LD_LIBS} ${XML2_PREFIX}/lib/libxml2.a"
-    SHLIB_LD_LIBS="${SHLIB_LD_LIBS} -L/usr/lib -lgcrypt -lgpg-error -lz -lm"
-    XML2_LIBS=
-    XSLT_LIBS=
-    FIX_LIB="chcon -t texrel_shlib_t"
-fi
-fi
-
-# Enabling static linking modifies the setting of the libraries,
-# so delay substitution until this point.
-AC_SUBST(XML2_LIBS)
-AC_SUBST(XSLT_LIBS)
-AC_SUBST(FIX_LIB)
-
-#--------------------------------------------------------------------
-# Find tclsh so that we can run pkg_mkIndex to generate the pkgIndex.tcl
-# file during the install process.  Don't run the TCLSH_PROG through
-# ${CYGPATH} because it's being used directly by make.
-# Require that we use a tclsh shell version 8.2 or later since earlier
-# versions have bugs in the pkg_mkIndex routine.
-# Add WISH as well if this is a Tk extension.
-#--------------------------------------------------------------------
-
-TEA_PROG_TCLSH
-
-#--------------------------------------------------------------------
-# These are for tclxmlConfig.sh
-#--------------------------------------------------------------------
-
-# pkglibdir must be a fully qualified path and (not ${exec_prefix}/lib)
-eval pkglibdir="${libdir}/${PACKAGE_NAME}${PACKAGE_VERSION}"
-if test "${TCL_LIB_VERSIONS_OK}" = "ok"; then
-    eval Tclxml_LIB_FLAG="-l${PACKAGE_NAME}${PACKAGE_VERSION}${DBGX}"
-else
-    eval Tclxml_LIB_FLAG="-l${PACKAGE_NAME}`echo ${PACKAGE_VERSION} | tr -d .`${DBGX}"
-fi
-Tclxml_BUILD_LIB_SPEC="-L`pwd` ${Tclxml_LIB_FLAG}"
-Tclxml_LIB_SPEC="-L${pkglibdir} ${Tclxml_LIB_FLAG}"
-
-if test "${TCL_LIB_VERSIONS_OK}" = "ok"; then
-    eval Tclxml_STUB_LIB_FLAG="-l${PACKAGE_NAME}stub${PACKAGE_VERSION}${DBGX}"
-else
-    eval Tclxml_STUB_LIB_FLAG="-l${PACKAGE_NAME}stub`echo ${PACKAGE_VERSION} | tr -d .`${DBGX}"
-fi
-Tclxml_BUILD_STUB_LIB_SPEC="-L`pwd` ${Tclxml_STUB_LIB_FLAG}"
-Tclxml_STUB_LIB_SPEC="-L${pkglibdir} ${Tclxml_STUB_LIB_FLAG}"
-Tclxml_BUILD_STUB_LIB_PATH="`pwd`/${Tclxmlstub_LIB_FILE}"
-Tclxml_STUB_LIB_PATH="${pkglibdir}/${Tclxmlstub_LIB_FILE}"
-eval pkgincludedir="${includedir}"
-Tclxml_INCLUDE_SPEC="-I${pkgincludedir}"
-
-AC_SUBST(Tclxml_BUILD_LIB_SPEC)
-AC_SUBST(Tclxml_LIB_SPEC)
-AC_SUBST(Tclxml_BUILD_STUB_LIB_SPEC)
-AC_SUBST(Tclxml_STUB_LIB_SPEC)
-AC_SUBST(Tclxml_BUILD_STUB_LIB_PATH)
-AC_SUBST(Tclxml_STUB_LIB_PATH)
-AC_SUBST(Tclxml_INCLUDE_SPEC)
-
-#--------------------------------------------------------------------
-# TODO: search for an appropriate xsltproc to use
-#--------------------------------------------------------------------
-
-XSLTPROC=xsltproc
-AC_SUBST(XSLTPROC)
-
-#--------------------------------------------------------------------
-# Finally, substitute all of the various values into the Makefile.
-# You may alternatively have a special pkgIndex.tcl.in or other files
-# which require substituting th AC variables in.  Include these here.
-#--------------------------------------------------------------------
-
-AC_OUTPUT([Makefile Makefile.macosx pkgIndex.tcl TclxmlConfig.sh include/tclxml/tclxml.h doc/tclxml.xml doc/tcldom.xml doc/tclxslt.xml doc/README.xml])
-
-#--------------------------------------------------------------------
diff --git a/tclxml-3.2/doc/README.xml.in b/tclxml-3.2/doc/README.xml.in
deleted file mode 100644
index 06eac14..0000000
--- a/tclxml-3.2/doc/README.xml.in
+++ /dev/null
@@ -1,405 +0,0 @@
-<!DOCTYPE article [
-  <!ENTITY version "@PACKAGE_VERSION@">
-]>
-<d:article xmlns:d='http://docbook.org/ns/docbook'
-	   xmlns:tcl='http://tclxml.sourceforge.net/doc'
-	   xmlns:xlink='http://www.w3.org/1999/xlink'>
-  <d:info>
-    <d:title>XML Support For Tcl</d:title>
-    <d:subtitle>TclXML, TclDOM and TclXSLT</d:subtitle>
-
-    <d:releaseinfo>$Id: README.xml.in,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $</d:releaseinfo>
-
-    <d:revhistory>
-      <d:revision>
-	<d:revnumber>&version;</d:revnumber>
-      </d:revision>
-    </d:revhistory>
-
-    <d:author>
-      <d:firstname>Steve</d:firstname>
-      <d:surname>Ball</d:surname>
-      <d:affiliation>
-	<d:orgname>Explain</d:orgname>
-	<d:address>
-	  <d:otheraddr>
-	    <d:link xlink:href='http://www.explain.com.au/'>www.explain.com.au</d:link>
-	  </d:otheraddr>
-	</d:address>
-      </d:affiliation>
-    </d:author>
-  </d:info>
-
-  <d:para>This package provides XML parsers, DOM scripting and XSL Transformations for <d:link xlink:href='http://www.tcl.tk'>Tcl</d:link>. In previous distributions, these features were supplied as separate packages. Now they have been combined into a single package to make installation easier.</d:para>
-
-  <d:para>Contact <d:link xlink:href='mailto:Steve.Ball at explain.com.au'>Steve Ball</d:link> for information about this release.</d:para>
-
-  <d:section>
-    <d:info>
-      <d:title>TclXML</d:title>
-    </d:info>
-
-    <d:para>TclXML provides a streaming parser for XML documents. This is the lowest-level interface for processing XML documents in Tcl. The package has a generic front-end interface with plugin parser implementations.  A number of parser implementations or wrappers are provided:</d:para>
-
-    <d:itemizedlist>
-      <d:listitem>
-	<d:para>Gnome libxml2 library.  This package is known as TclXML/libxml2.</d:para>
-      </d:listitem>
-      <d:listitem>
-	<d:para>A generic Tcl implementation (which does not require compilation).  This package is known as TclXML/tcl.</d:para>
-      </d:listitem>
-    </d:itemizedlist>
-
-    <d:para>Both of these implementations may be installed at the same time. See <d:link xlink:href='doc/tclxml.html'>the manual page</d:link> for more information.</d:para>
-  </d:section>
-
-  <d:section>
-    <d:info>
-      <d:title>TclDOM</d:title>
-    </d:info>
-
-    <d:para>TclDOM provides a tree view for XML documents. This is usually the best interface for scripting XML documents using Tcl. The package has two implementations:</d:para>
-
-    <d:itemizedlist>
-      <d:listitem>
-	<d:para>Gnome libxml2 library.  This package is known as TclDOM/libxml2.</d:para>
-      </d:listitem>
-      <d:listitem>
-	<d:para>A generic Tcl implementation (which does not require compilation).  This package is known as TclDOM/tcl.</d:para>
-      </d:listitem>
-    </d:itemizedlist>
-
-    <d:para>Only one of these will be installed.</d:para>
-
-    <d:para>See <d:link xlink:href='doc/tcldom.html'>the manual page</d:link> for more information.</d:para>
-  </d:section>
-
-  <d:section>
-    <d:info>
-      <d:title>TclXSLT</d:title>
-    </d:info>
-
-    <d:para>TclXSLT provides a method to invoke XSL Transformations upon XML documents. This package is a wrapper for the libxslt library.</d:para>
-
-    <d:para>See <d:link xlink:href='doc/tclxslt.html'>the manual page</d:link> for more information.</d:para>
-  </d:section>
-
-  <d:section xml:id='installation'>
-    <d:info>
-      <d:title>Installation</d:title>
-    </d:info>
-
-    <d:section>
-      <d:info>
-	<d:title>Dependencies</d:title>
-      </d:info>
-
-      <d:variablelist>
-	<d:varlistentry>
-	  <d:term>Tcllib</d:term>
-	  <d:listitem>
-	    <d:para><d:link xlink:href='http://www.tcl.tk/software/tcllib/'>http://www.tcl.tk/software/tcllib/</d:link></d:para>
-
-	    <d:para>In order for the Tcl-only parser to resolve external entities, the tcllib package must be installed.</d:para>
-
-	    <d:para>Be sure to get a version which includes the <tcl:package>uri</tcl:package> package.  Version 1.11 or better is recommended.</d:para>
-	    <d:itemizedlist>
-	      <d:listitem>
-		<d:para><d:link xlink:href='ftp://prdownloads.sf.net/tcllib/tcllib-1.11.tar.gz'>GZip'd tarball</d:link></d:para>
-	      </d:listitem>
-	      <d:listitem>
-		<d:para><d:link xlink:href='ftp://prdownloads.sf.net/tcllib/tcllib-1.11.zip'>ZIP file</d:link></d:para>
-	      </d:listitem>
-	    </d:itemizedlist>
-	    <d:para>The latest CVS snapshot may be found at <d:link xlink:href='http://sourceforge.net/projects/tcllib'>the SourceForge project page</d:link>.</d:para>
-	  </d:listitem>
-	</d:varlistentry>
-	<d:varlistentry>
-	  <d:term>libxml2</d:term>
-	  <d:listitem>
-	    <d:para>libxml2 is required for the compiled version of the TclXML/libxml2 package.  libiconv may also be required.</d:para>
-
-	    <d:para>The source code for libxml2 and libiconv is <d:emphasis>not</d:emphasis> supplied with this package.  Download libxml2 from <d:link xlink:href='http://xmlsoft.org/'>xmlsoft.org</d:link> separately. libiconv may also be required; download from a GNU mirror site.</d:para>
-
-	    <d:para>Version 2.7.2 (or better) is recommended.</d:para>
-	  </d:listitem>
-	</d:varlistentry>
-      </d:variablelist>
-    </d:section>
-
-    <d:section>
-      <d:info>
-	<d:title>Pure-Tcl Installation</d:title>
-	<d:subtitle>no compilation required</d:subtitle>
-      </d:info>
-
-      <d:para>Run the configure script and invoke the command:</d:para>
-      <d:informalexample>
-	<d:command>make install</d:command>
-      </d:informalexample>
-
-      <d:para>If the pure-Tcl parser is good enough for you, then read no further.</d:para>
-    </d:section>
-
-    <d:section>
-      <d:info>
-	<d:title>Compiled Installation</d:title>
-      </d:info>
-
-      <d:section>
-	<d:info>
-	  <d:title>Unix/Linux</d:title>
-	</d:info>
-
-	<d:para>You must have Tcl/Tk version 8.2 or better installed on your system.  Tcl/Tk 8.3 or better is recommended.</d:para>
-
-	<d:orderedlist>
-	  <d:listitem>
-	    <d:para>Make sure you have Tcllib 1.11 (or better) installed.  Tcllib is still required, even for the compiled parser.</d:para>
-	  </d:listitem>
-	  <d:listitem>
-	    <d:para>If you wish to use TclXML/libxml2, make sure libxml2-2.7.2 (or better) is installed.</d:para>
-	  </d:listitem>
-	  <d:listitem>
-	    <d:para>Unpack the TclXML distribution and <d:command>cd</d:command> into the <d:filename>tclxml-&version;</d:filename> directory.</d:para>
-	  </d:listitem>
-	  <d:listitem>
-	    <d:para>Run the <d:filename>configure</d:filename> script, with the <d:arg>--prefix</d:arg> and <d:arg>--enable-threads</d:arg> switches (the latter only if Tcl has been built with threads enabled). Use the <d:arg>--with-xml2-config</d:arg> switch to specify the location of the libxml2 configuration script, <d:filename>xml2Conf.sh</d:filename>. Similarly, use the <d:arg>--with-xslt-config</d:arg> if necessary.</d:para>
-	    <d:para>TclXML/libxml2 may be configured to statically link the libxml2 and libxslt libraries to the libtclxml.so shared library. This is advantageous when using TclXML/libxml2 in a StarKit. To statically link the libraries use the <d:arg>--with-xml-static</d:arg> switch.</d:para>
-	    <d:para>For example, on my system I have Tcl 8.5 installed in <d:filename>/usr/local/tcl8.5</d:filename> and libxm2 installed in <d:filename>/usr/local/gnome</d:filename>. I also need to statically link the libraries. Therefore I would use the command:</d:para>
-
-	    <d:programlisting>./configure --prefix=/usr/local/tcl8.5 --enable-threads --with-xml2-config=/usr/local/gnome/bin/xml2Conf.sh --with-xml-static=1</d:programlisting>
-	  </d:listitem>
-	  <d:listitem>
-	    <d:programlisting>make</d:programlisting>
-	  </d:listitem>
-	  <d:listitem>
-	    <d:note>Don't test the package using <d:literal>make test</d:literal> until all of the packages are installed (it is a current deficiency of the build system that the package cannot be tested before installation - we hope to fix this soon!).</d:note>
-	  </d:listitem>
-	  <d:listitem>
-	    <d:programlisting>make install</d:programlisting>
-
-	    <d:para>You may need to do this as root, depending on your installation.</d:para>
-	  </d:listitem>
-	  <d:listitem>
-	    <d:programlisting>make test</d:programlisting>
-	  </d:listitem>
-	  <d:listitem>
-	    <d:programlisting>make doc</d:programlisting>
-	  </d:listitem>
-	  <d:listitem>
-	    <d:programlisting>make install-doc</d:programlisting>
-	  </d:listitem>
-	</d:orderedlist>
-      </d:section>
-
-      <d:section>
-	<d:info>
-	  <d:title>Windows (MSYS/MINGW)</d:title>
-	</d:info>
-
-	<d:note>[Advice:  ActiveTcl includes binaries for TclXML.]</d:note>
-
-	<d:para>You must have Tcl/Tk version 8.2 or better installed on your system.  Tcl/Tk 8.5.5 or better is recommended.</d:para>
-
-	<d:para>Before starting, download the binaries for libxml2 (or build them from source).  <d:link xlink:href='http://xmlsoft.org/'>xmlsoft</d:link> has a link to the MS Windows binary distribution.</d:para>
-
-	<d:para>If you have a TEA build environment setup, just use the normal <d:literal>configure/make/make install</d:literal> pattern.</d:para>
-      </d:section>
-
-      <d:section>
-	<d:info>
-	  <d:title>Windows (NMAKE/VC++ 6.0)</d:title>
-	</d:info>
-
-	<d:note>TclXML/libxml2 is built with MSYS/MINGW, see above, so this build system is untested.</d:note>
-
-	<d:para>Alternatively, the <d:filename>win</d:filename> subdirectory contains a <d:filename>makefile.vc</d:filename> file for Visual Studio C++ v6.0.  In a Command Prompt window set up your environment so that <d:application>nmake</d:application> is on the path (by running <d:filename>VCVARS32.BAT</d:filename>), then type the following:</d:para>
-
-	<d:informalexample>
-	  <d:programlisting>nmake -f makefile.vc TCLDIR=<d:replaceable>C:\Path\To\Tcl</d:replaceable> INSTALLDIR=<d:replaceable>C:\Path\To\Tcl</d:replaceable> LIBZDIR=<d:replaceable>C:\Path\To\libz</d:replaceable> LIBICONVDIR=<d:replaceable>C:\Path\To\libiconv</d:replaceable> LIBXML2DIR=<d:replaceable>C:\Path\To\libxml2</d:replaceable> LIBXSLTDIR=<d:replaceable>C:\Path\To\libxslt</d:replaceable></d:programlisting>
-	</d:informalexample>
-
-	<d:para>As an example, on my system I have Tcl installed in <d:filename>C:\Tcl</d:filename> and the libxml2 and libxslt binaries unpacked in the directory <d:filename>C:\gnome</d:filename>.  Accordingly, I would use the following command line:</d:para>
-	<d:informalexample>
-	  <d:programlisting>nmake -f makefile.vc TCLDIR=C:\Tcl INSTALLDIR=C:\Tcl LIBZDIR=C:\gnome\zlib-1.1.4.win32 LIBICONVDIR=C:\gnome\libiconv-1.9.1.win32 LIBXML2DIR=C:\gnome\libxml2-2.7.2.win32 LIBXSLTDIR=C:\gnome\libxslt-1.1.24.win32</d:programlisting>
-	</d:informalexample>
-
-	<d:para>Install the package by appending 'install' to the command line used above, for example:</d:para>
-
-	<d:informalexample>
-	  <d:programlisting>nmake -f makefile.vc TCLDIR=<d:replaceable>C:\Path\To\Tcl</d:replaceable> INSTALLDIR=<d:replaceable>C:\Path\To\Tcl</d:replaceable> LIBZDIR=<d:replaceable>C:\Path\To\libz</d:replaceable> LIBICONVDIR=<d:replaceable>C:\Path\To\libiconv</d:replaceable> LIBXML2DIR=<d:replaceable>C:\Path\To\libxml2</d:replaceable> LIBXSLTDIR=<d:replaceable>C:\Path\To\libxslt</d:replaceable> install</d:programlisting>
-	</d:informalexample>
-      </d:section>
-
-      <d:section>
-	<d:info>
-	  <d:title>Macintosh OS X</d:title>
-	</d:info>
-
-	<d:note>Binary distributions of libxml2, libxslt and TclXML as frameworks are provided by <d:link xlink:href='http://www.explain.com.au/oss/'>Explain</d:link>.</d:note>
-
-	<d:para>There are two ways to build TclXML under Mac OS X:</d:para>
-	<d:orderedlist>
-	  <d:listitem>
-	    <d:para>The usual Unix way, see above.</d:para>
-	  </d:listitem>
-	  <d:listitem>
-	    <d:para>As an embedded Framework using Xcode.</d:para>
-	  </d:listitem>
-	</d:orderedlist>
-
-	<d:para>The <d:filename>macosx</d:filename> directory contains the Xcode files for building under OS X (Leopard/Panther).  TclXML/libxml2 has been tested on OS X 10.5 (or is that X.5?).</d:para>
-
-	<d:para>Start-up the project.  Make sure that the references to the libxml2 and Tcl external frameworks are correct.  Select the 'Make' target and build.  This builds everything.  The result is two Mac OS X Frameworks; a "normal" and an "embedded".  The embedded framework will be in the <d:filename>embedded</d:filename> subdirectory of the Build Products directory.  Copy <d:filename>tclxml.framework</d:filename> to any of the usual places for frameworks (<d:filename>~/Library/Frameworks</d:filename>, <d:filename>/Library/Frameworks</d:filename>, etc).</d:para>
-
-	<d:para>For earlier version of OS X using Project Builder, you will have to retrieve a previous version of the Project Builder files from the CVS repository.</d:para>
-      </d:section>
-
-    </d:section>
-  </d:section>
-
-  <d:section>
-    <d:info>
-      <d:title>Usage</d:title>
-    </d:info>
-
-    <d:para>See <d:link xlink:href='http://tclxml.sourceforge.net/'>the website</d:link> for links to tutorials and the reference manual.</d:para>
-
-    <d:para>In the meantime, here's a quick tutorial:</d:para>
-
-    <d:section>
-      <d:info>
-	<d:title>Parsing XML, Streaming</d:title>
-      </d:info>
-
-      <d:para>This is the lowest-level access to an XML document; use SAX-like events to stream through the document. The simple program below counts the number of characters in the content of an XML document.</d:para>
-
-      <d:programlisting>
-package require xml &version;
-
-set parser [xml::parser]
-$parser configure -elementstartcommand EStart \
-    -characterdatacommand PCData
-
-proc EStart {tag attlist args} {
-    array set attr $attlist
-    puts "Element \"$tag\" started with [array size attr] attributes"
-}
-
-proc PCData text {
-    incr ::count [string length $text]
-}
-
-set count 0
-$parser parse [read stdin]
-
-puts "The document contains $count characters"
-exit 0
-</d:programlisting>
-    </d:section>
-
-    <d:section>
-      <d:info>
-	<d:title>Parsing XML with DOM</d:title>
-      </d:info>
-
-      <d:para>This is the next level up in accessing an XML document; use the Document Object Model (DOM) to view the XML document as a tree. The simple program below counts the number of characters in the content of an XML document.</d:para>
-
-      <d:programlisting>
-package require xml &version;
-
-set doc [dom::parse [read stdin]]
-set count 0
-foreach textNode [dom::selectNode $doc //text()] {
-    incr count [string length [$textNode cget -nodeValue]]
-}
-
-puts "The document contains $count characters"
-      </d:programlisting>
-    </d:section>
-
-    <d:section>
-      <d:info>
-	<d:title>Transforming XML with XSLT</d:title>
-      </d:info>
-
-      <d:para>This is the highest level in processing an XML document; use a XSL stylesheet to transform a XML document. The simple program below reads two XML documents, compiles one into a XSL stylesheet and performs the transformation.</d:para>
-
-      <d:programlisting>
-package require xml &version;
-
-set chan [open "count.xsl"]
-set styleDoc [dom::parse [read $chan]]
-close $chan
-set sourceDoc [dom::parse [read stdin]]
-
-set style [xslt::compile $styleDoc]
-set resultDoc [$style transform $sourceDoc]
-
-puts [dom::serialize $resultDoc]
-      </d:programlisting>
-
-      <d:para>The XSL stylesheet <d:filename>count.xsl</d:filename>, which counts the number of characters in the source document, looks like this:</d:para>
-
-      <d:programlisting><![CDATA[
-<xsl:stylesheet version='1.0'
-  xmlns:xsl='http://www.w3.org/1999/XSL/Transform'>
-
-  <xsl:template match='/'>
-    <xsl:text>The document contains </xsl:text>
-    <xsl:call-template name='add'>
-      <xsl:with-param name='nodes' select='//text()'/>
-    </xsl:call-template>
-    <xsl:text> characters.
-</xsl:text>
-  </xsl:template>
-
-  <xsl:template name='add'>
-    <xsl:param name='sum' select='0'/>
-    <xsl:param name='nodes' select='/..'/>
-
-    <xsl:choose>
-      <xsl:when test='not($nodes)'>
-        <xsl:value-of select='$sum'/>
-      </xsl:when>
-      <xsl:otherwise>
-        <xsl:call-template name='add'>
-          <xsl:with-param name='sum'
-            select='$sum + string-length($nodes[1])'/>
-          <xsl:with-param name='nodes'
-            select='$nodes[position() != 1]'/>
-        </xsl:call-template>
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:template>
-</xsl:stylesheet>
-]]></d:programlisting>
-    </d:section>
-  </d:section>
-
-  <d:section>
-    <d:info>
-      <d:title>XPath</d:title>
-    </d:info>
-
-    <d:para>In addition to XML parsing packages, TclXML also provides a package for parsing XPath location paths.  The XPath package only parsing the path's syntax, it does interpret the path.  See <d:link xlink:href='http://tclxml.sourceforge.net/tcldom.html'>TclDOM</d:link> for a package that will interpret XPath location paths.</d:para>
-
-    <d:note>This package is in its infancy, and does not support the full range of XPath features.  Only a very limited subset of location paths are supported, of the form "/simple/example[2]".  Paths within predicates will definitely fail.</d:note>
-
-    <d:para>To use the XPath package:</d:para>
-
-    <d:programlisting>
-package require xpath
-</d:programlisting>
-
-    <d:para>To parse a location path:</d:para>
-
-    <d:programlisting>
-xpath::split {/simple/example}
-</d:programlisting>
-
-    <d:para>This returns a Tcl list, each element of which is a three element sublist: {axis node-test {?predicate ...?}}.</d:para>
-  </d:section>
-</d:article>
-
diff --git a/tclxml-3.2/doc/html.xsl b/tclxml-3.2/doc/html.xsl
deleted file mode 100644
index 1877ffb..0000000
--- a/tclxml-3.2/doc/html.xsl
+++ /dev/null
@@ -1,597 +0,0 @@
-<xsl:stylesheet version='1.0'
-		xmlns:xsl='http://www.w3.org/1999/XSL/Transform'
-		xmlns:d='http://docbook.org/ns/docbook'
-		xmlns:xlink='http://www.w3.org/1999/xlink'
-		xmlns:tcl='http://tclxml.sourceforge.net/doc'
-		exclude-result-prefixes='d xlink tcl'>
-
-  <!--
-     - html.xsl -
-     -
-     - Copyright (c) 2008 Explain
-     - http://www.explain.com.au/
-     - Copyright (c) 2000 Zveno Pty Ltd
-     -
-     -	XSLT stylesheet to convert TclXML docs to HTML.
-     -
-     - $Id: html.xsl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-  -->
-
-  <xsl:output method='html'/>
-  <xsl:strip-space elements='*'/>
-  <xsl:preserve-space elements='d:literallayout d:programlisting'/>
-
-  <xsl:template match='d:article'>
-    <html>
-      <head>
-        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
-        <title>
-          <xsl:apply-templates select="d:info/d:title"
-            mode='html-title'/>
-        </title>
-        <link rel='stylesheet' href='tclxml.css'/>
-      </head>
-      <body>
-        <div class="{local-name(.)}">
-          <h1 class="title">
-            <a>
-              <xsl:attribute name="name">
-                <xsl:call-template name="object.id"/>
-              </xsl:attribute>
-              <xsl:apply-templates select="d:info/d:title/node()"/>
-            </a>
-          </h1>
-          <xsl:apply-templates select='d:info/d:subtitle'/>
-          <h2>Contents</h2>
-          <ul>
-            <xsl:if test="d:refsynopsisdiv">
-              <li><a href="#synopsis">Synopsis</a></li>
-            </xsl:if>
-            <xsl:for-each select="d:sect1|d:section">
-              <li>
-                <a href="#{generate-id()}">
-                  <xsl:apply-templates select="d:info/d:title" mode='toc'/>
-                </a>
-                <xsl:if test="d:sect2|d:section">
-                  <ul>
-                    <xsl:for-each select="d:sect2|d:section">
-                      <li>
-                        <a href="#{generate-id()}">
-                          <xsl:apply-templates select="d:info/d:title" mode='toc'/>
-                        </a>
-                        <xsl:if test="d:sect3|d:section">
-                          <ul>
-                            <xsl:for-each select="d:sect3|d:section">
-                              <li>
-                                <a href="#{generate-id()}">
-                                  <xsl:apply-templates select="d:info/d:title"
-                                    mode='toc'/>
-                                </a>
-                              </li>
-                            </xsl:for-each>
-                          </ul>
-                        </xsl:if>
-                      </li>
-                    </xsl:for-each>
-                  </ul>
-                </xsl:if>
-              </li>
-            </xsl:for-each>
-          </ul>
-
-          <xsl:apply-templates/>
-
-          <xsl:variable name='footnotes' select='//d:footnote'/>
-          <xsl:if test='$footnotes'>
-            <div id='footnotes'>
-              <h2>Footnotes</h2>
-              <xsl:apply-templates select='$footnotes' mode='footnote'/>
-            </div>
-          </xsl:if>
-        </div>
-      </body>
-    </html>
-  </xsl:template>
-
-  <xsl:template match="d:refentry">
-    <xsl:variable name="refmeta" select=".//d:refmeta"/>
-    <xsl:variable name="refentrytitle" select="$refmeta//d:refentrytitle"/>
-    <xsl:variable name="refnamediv" select=".//d:refnamediv"/>
-    <xsl:variable name="refname" select="$refnamediv//d:refname"/>
-    <xsl:variable name="title">
-      <xsl:choose>
-	<xsl:when test="$refentrytitle">
-	  <xsl:apply-templates select="$refentrytitle[1]" mode="title"/>
-	</xsl:when>
-	<xsl:when test="$refname">
-	  <xsl:apply-templates select="$refname[1]" mode="title"/>
-	</xsl:when>
-      </xsl:choose>
-    </xsl:variable>
-
-    <html>
-      <head>
-        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
-        <title>
-          <xsl:copy-of select="$title"/>
-        </title>
-        <link rel='stylesheet' href='tclxml.css'/>
-      </head>
-      <body>
-        <div class="{local-name(.)}">
-          <h1 class="title">
-            <a>
-              <xsl:attribute name="name">
-                <xsl:call-template name="object.id"/>
-              </xsl:attribute>
-              <xsl:copy-of select="$title"/>
-            </a>
-          </h1>
-          <h2>Contents</h2>
-          <ul>
-            <xsl:if test="d:refsynopsisdiv">
-              <li><a href="#synopsis">Synopsis</a></li>
-            </xsl:if>
-            <xsl:for-each select="d:refsect1">
-              <li>
-                <a href="#{generate-id()}">
-                  <xsl:apply-templates select="d:info/d:title" mode='toc'/>
-                </a>
-                <xsl:if test="d:refsect2">
-                  <ul>
-                    <xsl:for-each select="d:refsect2">
-                      <li>
-                        <a href="#{generate-id()}">
-                          <xsl:apply-templates select="d:info/d:title" mode='toc'/>
-                        </a>
-                        <xsl:if test="d:refsect3">
-                          <ul>
-                            <xsl:for-each select="d:refsect3">
-                              <li>
-                                <a href="#{generate-id()}">
-                                  <xsl:apply-templates select="d:info/d:title"
-                                    mode='toc'/>
-                                </a>
-                              </li>
-                            </xsl:for-each>
-                          </ul>
-                        </xsl:if>
-                      </li>
-                    </xsl:for-each>
-                  </ul>
-                </xsl:if>
-              </li>
-            </xsl:for-each>
-          </ul>
-
-          <xsl:apply-templates/>
-
-          <xsl:variable name='footnotes' select='//d:footnote'/>
-          <xsl:if test='$footnotes'>
-            <div id='footnotes'>
-              <h2>Footnotes</h2>
-              <xsl:apply-templates select='$footnotes' mode='footnote'/>
-            </div>
-          </xsl:if>
-        </div>
-      </body>
-    </html>
-  </xsl:template>
-
-  <xsl:template match='d:article/d:info/d:title'/>
-
-  <xsl:template match='d:subtitle'>
-    <h3>
-      <xsl:apply-templates/>
-    </h3>
-  </xsl:template>
-
-  <xsl:template match='d:footnote' mode='footnote'>
-    <div class='footnote'>
-      <a name='fn_{generate-id()}'/>
-      <div>
-        <span class='footnote_label'>
-          <xsl:number level='any'/>
-        </span>
-        <xsl:apply-templates select='*[self::d:para][1]/node()'/>
-      </div>
-      <xsl:apply-templates select='*[position() != 1]'/>
-    </div>
-  </xsl:template>
-
-  <xsl:template match='d:footnote'>
-    <span class='footnoteref'>
-      <a href='fn_{generate-id()}'>
-        <xsl:number level='any'/>
-      </a>
-    </span>
-  </xsl:template>
-
-  <xsl:template match='d:refmeta'/>
-
-  <xsl:template match='d:keywordset'>
-    <div class='keywordset'>
-      <xsl:apply-templates/>
-    </div>
-  </xsl:template>
-  <xsl:template match='d:keyword'>
-    <xsl:if test='preceding-sibling::d:keyword'>, </xsl:if>
-    <xsl:apply-templates/>
-  </xsl:template>
-
-  <xsl:template match='d:section |
-                       d:refsect1 |
-                       d:refsect2 |
-                       d:refsect3 |
-                       d:refnamediv'>
-    <div class='{local-name()}'>
-      <xsl:apply-templates/>
-    </div>
-  </xsl:template>
-  <xsl:template match='d:refname'>
-    <xsl:if test='preceding-sibling::d:refname'>, </xsl:if>
-    <span class='{local-name()}'>
-      <xsl:apply-templates/>
-    </span>
-  </xsl:template>
-  <xsl:template match='d:refpurpose'>
-    <xsl:text> &#x2014; </xsl:text>
-    <span class='{local-name()}'>
-      <xsl:apply-templates/>
-    </span>
-  </xsl:template>
-
-  <xsl:template match="d:refsynopsisdiv">
-    <div class="{local-name(.)}">
-      <a name="synopsis"/>
-      <h2>Synopsis</h2>
-      <xsl:apply-templates select="*[not(self::tcl:namespacesynopsis)]"/>
-      <xsl:apply-templates select="tcl:namespacesynopsis"/>
-    </div>
-  </xsl:template>
-
-  <xsl:template match="tcl:cmdsynopsis">
-    <xsl:variable name="id"><xsl:call-template name="object.id"/></xsl:variable>
-
-    <div class="{local-name()}" id="{$id}">
-      <a name="{$id}"/>
-      <xsl:apply-templates/>
-    </div>
-  </xsl:template>
-  <xsl:template match="tcl:cmdsynopsis/d:command">
-    <br/>
-    <xsl:call-template name="inline.monoseq"/>
-    <xsl:text> </xsl:text>
-  </xsl:template>
-  <xsl:template match="tcl:cmdsynopsis/d:command[1]">
-    <xsl:call-template name="inline.monoseq"/>
-    <xsl:text> </xsl:text>
-  </xsl:template>
-
-  <xsl:template match="d:refsynopsisdiv/tcl:cmdsynopsis/d:command">
-    <xsl:variable name="id"><xsl:call-template name="object.id"/></xsl:variable>
-
-    <br/>
-    <span class="{local-name(.)}" id="{$id}">
-      <a name="{translate(.,': ','__')}"/>
-      <xsl:call-template name="inline.monoseq"/>
-      <xsl:text> </xsl:text>
-    </span>
-  </xsl:template>
-  <xsl:template match="d:refsynopsisdiv/tcl:cmdsynopsis/d:command[1]">
-    <xsl:variable name="id"><xsl:call-template name="object.id"/></xsl:variable>
-
-    <span class="{local-name(.)}" id="{$id}">
-      <a name="{translate(.,': ','__')}"/>
-      <xsl:call-template name="inline.monoseq"/>
-      <xsl:text> </xsl:text>
-    </span>
-  </xsl:template>
-  <xsl:template match="d:option">
-    <xsl:text> </xsl:text>
-    <em><xsl:apply-templates/></em>
-  </xsl:template>
-  <xsl:template match="d:group">
-    <xsl:text> </xsl:text>
-    <xsl:if test="@choice='opt'">
-      <xsl:text>?</xsl:text>
-    </xsl:if>
-    <xsl:if test="not(@choice) and count(d:arg) > 1">
-      <xsl:text>"</xsl:text>
-    </xsl:if>
-
-    <xsl:apply-templates/>
-
-    <xsl:if test="@rep='repeat'">
-      <xsl:text>...</xsl:text>
-    </xsl:if>
-    <xsl:if test="not(@choice) and count(d:arg) > 1">
-      <xsl:text>"</xsl:text>
-    </xsl:if>
-    <xsl:if test="@choice='opt'">
-      <xsl:text>?</xsl:text>
-    </xsl:if>
-  </xsl:template>
-  <xsl:template match="tcl:cmdsynopsis//d:arg[1]">
-    <xsl:apply-templates/>
-  </xsl:template>
-  <xsl:template match="tcl:cmdsynopsis//d:arg[position() > 1]">
-    <xsl:text> </xsl:text>
-    <xsl:apply-templates/>
-  </xsl:template>
-
-  <xsl:template match="tcl:command|d:command">
-    <xsl:call-template name="inline.boldseq"/>
-  </xsl:template>
-
-  <xsl:template match='tcl:package|tcl:namespace|tcl:method|d:classname|d:application|d:tag|d:filename'>
-    <xsl:call-template name='inline.monoseq'/>
-  </xsl:template>
-
-  <xsl:template match="tcl:pkgsynopsis">
-    <br/>
-    <span class="{name(.)}">
-      <pre>package require <xsl:value-of select="d:package"/> ?<xsl:value-of select="d:version"/>?</pre>
-    </span>
-  </xsl:template>
-
-  <xsl:template match="tcl:namespacesynopsis">
-    <h3>Tcl Namespace Usage</h3>
-    <xsl:apply-templates/>
-    <p/>
-  </xsl:template>
-
-  <xsl:template match="tcl:namespacesynopsis/tcl:namespace[1]">
-    <xsl:call-template name="inline.monoseq"/>
-  </xsl:template>
-
-  <xsl:template match="tcl:namespacesynopsis/tcl:namespace">
-    <br/>
-    <xsl:call-template name="inline.monoseq"/>
-  </xsl:template>
-
-  <xsl:template match="d:refsect1[d:info/d:title = 'Commands'][d:refsect2/d:info/d:title]//tcl:cmdsynopsis/*[position() = 1 and local-name() = 'option']">
-    <tt>
-      <xsl:choose>
-	<xsl:when test="ancestor::d:refsect3//*[@role='subject']">
-	  <i><xsl:value-of select="ancestor::d:refsect3//*[@role='subject']"/></i>
-	</xsl:when>
-        <xsl:when test="ancestor::d:refsect2/d:info/d:title">
-          <xsl:value-of select="ancestor::d:refsect2/d:info/d:title"/>
-	</xsl:when>
-      </xsl:choose>
-    </tt>
-    <xsl:text> </xsl:text>
-    <u><xsl:apply-templates/></u>
-  </xsl:template>
-
-  <xsl:template match="tcl:optionsynopsis">
-    <p>
-      <xsl:apply-templates/>
-    </p>
-  </xsl:template>
-
-  <xsl:template match="tcl:optionsynopsis/d:option">
-    <xsl:call-template name="inline.monoseq"/>
-  </xsl:template>
-
-  <xsl:template match="tcl:optionsynopsis/d:arg">
-    <xsl:text> </xsl:text>
-    <u>
-      <xsl:apply-templates/>
-    </u>
-  </xsl:template>
-
-  <!-- Do a segmentedlist as a table, instead of the poxy way DocBook does them -->
-
-  <xsl:template match="d:segmentedlist">
-    <table border="0">
-      <xsl:apply-templates/>
-    </table>
-  </xsl:template>
-
-  <xsl:template match="d:seglistitem">
-    <tr>
-      <xsl:apply-templates/>
-    </tr>
-  </xsl:template>
-
-  <xsl:template match="d:seg">
-    <td valign="top">
-      <xsl:apply-templates/>
-    </td>
-  </xsl:template>
-
-  <xsl:template match="d:seg/d:arg">
-    <xsl:text> </xsl:text>
-    <xsl:call-template name="inline.monoseq"/>
-  </xsl:template>
-
-  <xsl:template match='d:replaceable'>
-    <em>
-      <xsl:apply-templates/>
-    </em>
-  </xsl:template>
-
-  <xsl:template match='d:info'>
-    <xsl:apply-templates select='d:title | d:subtitle'/>
-  </xsl:template>
-  <xsl:template match='d:refsect1/d:info/d:title'>
-    <h2>
-      <a name='{generate-id(../..)}'/>
-      <xsl:apply-templates/>
-    </h2>
-  </xsl:template>
-  <xsl:template match='d:refsect2/d:info/d:title'>
-    <h3>
-      <a name='{generate-id(../..)}'/>
-      <xsl:apply-templates/>
-    </h3>
-  </xsl:template>
-  <xsl:template match='d:refsect3/d:info/d:title'>
-    <h4>
-      <a name='{generate-id(../..)}'/>
-      <xsl:apply-templates/>
-    </h4>
-  </xsl:template>
-  <xsl:template match='d:section/d:info/d:title'>
-    <xsl:element name='h{count(ancestor::d:section) + 2}'>
-      <a name='{generate-id(../..)}'/>
-      <xsl:apply-templates/>
-    </xsl:element>
-  </xsl:template>
-
-  <xsl:template match='d:para'>
-    <p>
-      <xsl:apply-templates/>
-    </p>
-  </xsl:template>
-
-  <xsl:template match='d:note'>
-    <div class='note'>
-      <xsl:apply-templates/>
-    </div>
-  </xsl:template>
-
-  <xsl:template match='d:informalexample|d:programlisting|d:computeroutput'>
-    <div class='{local-name()}'>
-      <pre>
-        <xsl:apply-templates/>
-      </pre>
-    </div>
-  </xsl:template>
-  <xsl:template match='d:example'>
-    <h4>
-      <xsl:apply-templates select='d:info/d:title/node() |
-                                   d:title/node()'/>
-    </h4>
-    <div class='{local-name()}'>
-      <pre>
-        <xsl:apply-templates select='*[not(self::d:title|self::d:info)]'/>
-      </pre>
-    </div>
-  </xsl:template>
-
-  <xsl:template match='d:variablelist'>
-    <dl>
-      <xsl:apply-templates/>
-    </dl>
-  </xsl:template>
-  <xsl:template match='d:varlistentry'>
-    <xsl:apply-templates/>
-  </xsl:template>
-  <xsl:template match='d:term'>
-    <dt>
-      <xsl:apply-templates/>
-    </dt>
-  </xsl:template>
-  <xsl:template match='d:varlistentry/d:listitem'>
-    <dd>
-      <xsl:apply-templates/>
-    </dd>
-  </xsl:template>
-
-  <xsl:template match='d:itemizedlist'>
-    <ul>
-      <xsl:apply-templates/>
-    </ul>
-  </xsl:template>
-  <xsl:template match='d:orderedlist'>
-    <ol>
-      <xsl:apply-templates/>
-    </ol>
-  </xsl:template>
-  <xsl:template match='d:itemizedlist/d:listitem |
-                       d:orderedlist/d:listitem'>
-    <li>
-      <xsl:apply-templates/>
-    </li>
-  </xsl:template>
-
-  <xsl:template match='d:arg'>
-    <xsl:choose>
-      <xsl:when test='parent::d:group and preceding-sibling::d:arg'>
-        <xsl:text> | </xsl:text>
-        <span class='arg'>
-          <xsl:apply-templates/>
-        </span>
-      </xsl:when>
-      <xsl:when test='preceding-sibling::d:arg'>
-        <xsl:text> </xsl:text>
-        <span class='arg'>
-          <xsl:apply-templates/>
-        </span>
-      </xsl:when>
-      <xsl:otherwise>
-        <span class='arg'>
-          <xsl:apply-templates/>
-        </span>
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:template>
-
-  <xsl:template match='d:literal|d:term|d:methodname'>
-    <span class='{local-name()}'>
-      <xsl:apply-templates/>
-    </span>
-  </xsl:template>
-
-  <xsl:template match='d:acronym'>
-    <xsl:choose>
-      <xsl:when test='@xlink:href'>
-        <a href='{@xlink:href}'>
-          <xsl:apply-templates/>
-        </a>
-      </xsl:when>
-      <xsl:otherwise>
-        <em>
-          <xsl:apply-templates/>
-        </em>
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:template>
-  <xsl:template match='d:link'>
-    <a href='{@xlink:href}'>
-      <xsl:apply-templates/>
-    </a>
-  </xsl:template>
-
-  <xsl:template match='d:emphasis'>
-    <em>
-      <xsl:apply-templates/>
-    </em>
-  </xsl:template>
-
-  <xsl:template name='inline.boldseq'>
-    <strong>
-      <xsl:apply-templates/>
-    </strong>
-  </xsl:template>
-
-  <xsl:template name='inline.monoseq'>
-    <tt>
-      <xsl:apply-templates/>
-    </tt>
-  </xsl:template>
-
-  <!-- Borrowed from DocBook XSL stylesheets: common/common.xsl -->
-  <xsl:template name="object.id">
-    <xsl:param name="object" select="."/>
-    <xsl:choose>
-      <xsl:when test="$object/@id">
-        <xsl:value-of select="$object/@id"/>
-      </xsl:when>
-      <xsl:when test="$object/@xml:id">
-        <xsl:value-of select="$object/@xml:id"/>
-      </xsl:when>
-      <xsl:otherwise>
-        <xsl:value-of select="generate-id($object)"/>
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:template>
-
-  <xsl:template match='*'>
-    <xsl:message>unmatched element "<xsl:value-of select='name()'/>" in "<xsl:value-of select='name(../..)'/>/<xsl:value-of select='name(..)'/>"</xsl:message>
-  </xsl:template>
-
-</xsl:stylesheet>
diff --git a/tclxml-3.2/doc/man.macros b/tclxml-3.2/doc/man.macros
deleted file mode 100644
index b50d170..0000000
--- a/tclxml-3.2/doc/man.macros
+++ /dev/null
@@ -1,236 +0,0 @@
-'\" The definitions below are for supplemental macros used in Tcl/Tk
-'\" manual entries.
-'\"
-'\" .AP type name in/out ?indent?
-'\"	Start paragraph describing an argument to a library procedure.
-'\"	type is type of argument (int, etc.), in/out is either "in", "out",
-'\"	or "in/out" to describe whether procedure reads or modifies arg,
-'\"	and indent is equivalent to second arg of .IP (shouldn't ever be
-'\"	needed;  use .AS below instead)
-'\"
-'\" .AS ?type? ?name?
-'\"	Give maximum sizes of arguments for setting tab stops.  Type and
-'\"	name are examples of largest possible arguments that will be passed
-'\"	to .AP later.  If args are omitted, default tab stops are used.
-'\"
-'\" .BS
-'\"	Start box enclosure.  From here until next .BE, everything will be
-'\"	enclosed in one large box.
-'\"
-'\" .BE
-'\"	End of box enclosure.
-'\"
-'\" .CS
-'\"	Begin code excerpt.
-'\"
-'\" .CE
-'\"	End code excerpt.
-'\"
-'\" .VS ?version? ?br?
-'\"	Begin vertical sidebar, for use in marking newly-changed parts
-'\"	of man pages.  The first argument is ignored and used for recording
-'\"	the version when the .VS was added, so that the sidebars can be
-'\"	found and removed when they reach a certain age.  If another argument
-'\"	is present, then a line break is forced before starting the sidebar.
-'\"
-'\" .VE
-'\"	End of vertical sidebar.
-'\"
-'\" .DS
-'\"	Begin an indented unfilled display.
-'\"
-'\" .DE
-'\"	End of indented unfilled display.
-'\"
-'\" .SO
-'\"	Start of list of standard options for a Tk widget.  The
-'\"	options follow on successive lines, in four columns separated
-'\"	by tabs.
-'\"
-'\" .SE
-'\"	End of list of standard options for a Tk widget.
-'\"
-'\" .OP cmdName dbName dbClass
-'\"	Start of description of a specific option.  cmdName gives the
-'\"	option's name as specified in the class command, dbName gives
-'\"	the option's name in the option database, and dbClass gives
-'\"	the option's class in the option database.
-'\"
-'\" .UL arg1 arg2
-'\"	Print arg1 underlined, then print arg2 normally.
-'\"
-'\" RCS: @(#) $Id: man.macros,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-'\"
-'\"	# Set up traps and other miscellaneous stuff for Tcl/Tk man pages.
-.if t .wh -1.3i ^B
-.nr ^l \n(.l
-.ad b
-'\"	# Start an argument description
-.de AP
-.ie !"\\$4"" .TP \\$4
-.el \{\
-.   ie !"\\$2"" .TP \\n()Cu
-.   el          .TP 15
-.\}
-.ta \\n()Au \\n()Bu
-.ie !"\\$3"" \{\
-\&\\$1	\\fI\\$2\\fP	(\\$3)
-.\".b
-.\}
-.el \{\
-.br
-.ie !"\\$2"" \{\
-\&\\$1	\\fI\\$2\\fP
-.\}
-.el \{\
-\&\\fI\\$1\\fP
-.\}
-.\}
-..
-'\"	# define tabbing values for .AP
-.de AS
-.nr )A 10n
-.if !"\\$1"" .nr )A \\w'\\$1'u+3n
-.nr )B \\n()Au+15n
-.\"
-.if !"\\$2"" .nr )B \\w'\\$2'u+\\n()Au+3n
-.nr )C \\n()Bu+\\w'(in/out)'u+2n
-..
-.AS Tcl_Interp Tcl_CreateInterp in/out
-'\"	# BS - start boxed text
-'\"	# ^y = starting y location
-'\"	# ^b = 1
-.de BS
-.br
-.mk ^y
-.nr ^b 1u
-.if n .nf
-.if n .ti 0
-.if n \l'\\n(.lu\(ul'
-.if n .fi
-..
-'\"	# BE - end boxed text (draw box now)
-.de BE
-.nf
-.ti 0
-.mk ^t
-.ie n \l'\\n(^lu\(ul'
-.el \{\
-.\"	Draw four-sided box normally, but don't draw top of
-.\"	box if the box started on an earlier page.
-.ie !\\n(^b-1 \{\
-\h'-1.5n'\L'|\\n(^yu-1v'\l'\\n(^lu+3n\(ul'\L'\\n(^tu+1v-\\n(^yu'\l'|0u-1.5n\(ul'
-.\}
-.el \}\
-\h'-1.5n'\L'|\\n(^yu-1v'\h'\\n(^lu+3n'\L'\\n(^tu+1v-\\n(^yu'\l'|0u-1.5n\(ul'
-.\}
-.\}
-.fi
-.br
-.nr ^b 0
-..
-'\"	# VS - start vertical sidebar
-'\"	# ^Y = starting y location
-'\"	# ^v = 1 (for troff;  for nroff this doesn't matter)
-.de VS
-.if !"\\$2"" .br
-.mk ^Y
-.ie n 'mc \s12\(br\s0
-.el .nr ^v 1u
-..
-'\"	# VE - end of vertical sidebar
-.de VE
-.ie n 'mc
-.el \{\
-.ev 2
-.nf
-.ti 0
-.mk ^t
-\h'|\\n(^lu+3n'\L'|\\n(^Yu-1v\(bv'\v'\\n(^tu+1v-\\n(^Yu'\h'-|\\n(^lu+3n'
-.sp -1
-.fi
-.ev
-.\}
-.nr ^v 0
-..
-'\"	# Special macro to handle page bottom:  finish off current
-'\"	# box/sidebar if in box/sidebar mode, then invoked standard
-'\"	# page bottom macro.
-.de ^B
-.ev 2
-'ti 0
-'nf
-.mk ^t
-.if \\n(^b \{\
-.\"	Draw three-sided box if this is the box's first page,
-.\"	draw two sides but no top otherwise.
-.ie !\\n(^b-1 \h'-1.5n'\L'|\\n(^yu-1v'\l'\\n(^lu+3n\(ul'\L'\\n(^tu+1v-\\n(^yu'\h'|0u'\c
-.el \h'-1.5n'\L'|\\n(^yu-1v'\h'\\n(^lu+3n'\L'\\n(^tu+1v-\\n(^yu'\h'|0u'\c
-.\}
-.if \\n(^v \{\
-.nr ^x \\n(^tu+1v-\\n(^Yu
-\kx\h'-\\nxu'\h'|\\n(^lu+3n'\ky\L'-\\n(^xu'\v'\\n(^xu'\h'|0u'\c
-.\}
-.bp
-'fi
-.ev
-.if \\n(^b \{\
-.mk ^y
-.nr ^b 2
-.\}
-.if \\n(^v \{\
-.mk ^Y
-.\}
-..
-'\"	# DS - begin display
-.de DS
-.RS
-.nf
-.sp
-..
-'\"	# DE - end display
-.de DE
-.fi
-.RE
-.sp
-..
-'\"	# SO - start of list of standard options
-.de SO
-.SH "STANDARD OPTIONS"
-.LP
-.nf
-.ta 5.5c 11c
-.ft B
-..
-'\"	# SE - end of list of standard options
-.de SE
-.fi
-.ft R
-.LP
-See the \\fBoptions\\fR manual entry for details on the standard options.
-..
-'\"	# OP - start of full description for a single option
-.de OP
-.LP
-.nf
-.ta 4c
-Command-Line Name:	\\fB\\$1\\fR
-Database Name:	\\fB\\$2\\fR
-Database Class:	\\fB\\$3\\fR
-.fi
-.IP
-..
-'\"	# CS - begin code excerpt
-.de CS
-.RS
-.nf
-.ta .25i .5i .75i 1i
-..
-'\"	# CE - end code excerpt
-.de CE
-.fi
-.RE
-..
-.de UL
-\\$1\l'|0\(ul'\\$2
-..
diff --git a/tclxml-3.2/doc/nroff.xsl b/tclxml-3.2/doc/nroff.xsl
deleted file mode 100644
index 6c0b648..0000000
--- a/tclxml-3.2/doc/nroff.xsl
+++ /dev/null
@@ -1,315 +0,0 @@
-<xsl:stylesheet version='1.0'
-  xmlns:xsl='http://www.w3.org/1999/XSL/Transform'
-  xmlns:d='http://docbook.org/ns/docbook'
-  xmlns:xlink='http://www.w3.org/1999/xlink'
-  xmlns:tcl='http://tclxml.sourceforge.net/doc'
-  xmlns:str='http://xsltsl.org/string'
-  extension-element-prefixes='str'
-  exclude-result-prefixes='d xlink tcl'>
-
-  <!--
-     - nroff.xsl -
-     -
-     - Copyright (c) 2005-2008 Explain
-     - http://www.explain.com.au/
-     -
-     - Copyright (c) 2000-2003 Zveno Pty Ltd
-     -
-     - See the file "LICENSE" for information on usage and
-     - redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
-     -
-     -	XSLT stylesheet to convert DocBook+Tcl mods to nroff.
-     -	NB. Tcl man macros are used.
-     -
-     - $Id: nroff.xsl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-  -->
-
-  <xsl:import href='xsltsl/stdlib.xsl'/>
-
-  <xsl:output method="text"/>
-
-  <xsl:template match="d:refentry">
-    <xsl:text>'\"
-</xsl:text>
-    <xsl:apply-templates select='d:info/d:copyright'/>
-    <xsl:apply-templates select='d:info/d:legalnotice'/>
-    <xsl:text>'\"
-'\" RCS: @(#) $Id: nroff.xsl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-'\" 
-.so man.macros
-</xsl:text>
-    <xsl:apply-templates select="*[not(self::d:info)]"/>
-</xsl:template>
-
-  <xsl:template match="d:info/d:legalnotice">
-    <xsl:apply-templates select='d:para' mode='comment'/>
-  </xsl:template>
-
-  <xsl:template match="d:info/d:copyright">
-    <xsl:text>'\" Copyright (c) </xsl:text>
-    <xsl:value-of select="d:year[1]"/>
-    <xsl:text> </xsl:text>
-    <xsl:value-of select="d:holder"/>
-    <xsl:text>
-</xsl:text>
-    <xsl:if test='d:holder/@xlink:href'>
-      <xsl:text>'\" </xsl:text>
-      <xsl:value-of select='d:holder/@xlink:href'/>
-      <xsl:text>
-</xsl:text>
-    </xsl:if>
-    <xsl:text>'\"
-</xsl:text>
-  </xsl:template>
-
-  <xsl:template match="d:info/d:legalnotice/d:para" mode='comment'>
-    <xsl:call-template name="str:justify">
-      <xsl:with-param name="text" select="."/>
-      <xsl:with-param name="prefix">'\" </xsl:with-param>
-      <xsl:with-param name='max' select='"75"'/>
-    </xsl:call-template>
-    <xsl:text>
-'\"
-</xsl:text>
-  </xsl:template>
-
-  <xsl:template match="d:refmeta">
-    <xsl:text>.TH </xsl:text>
-    <xsl:value-of select="d:refentrytitle"/>
-    <xsl:text> </xsl:text>
-    <xsl:value-of select="d:manvolnum"/>
-    <xsl:text> </xsl:text>
-    <xsl:value-of select="/d:refentry/d:info/d:revhistory/d:revision[1]/d:revnumber"/>
-    <xsl:text> TclXML "TclXML Package Commands"
-</xsl:text>
-  </xsl:template>
-  <xsl:template match='d:refentrytitle'>
-    <xsl:apply-templates/>
-  </xsl:template>
-
-  <xsl:template match="d:refnamediv">
-    <xsl:text>.BS
-'\" Note:  do not modify the .SH NAME line immediately below!
-.SH NAME
-</xsl:text>
-    <xsl:for-each select="d:refname">
-      <xsl:apply-templates/>
-      <xsl:text> </xsl:text>
-    </xsl:for-each>
-    <xsl:text>\- </xsl:text>
-    <xsl:value-of select="d:refpurpose"/>
-    <xsl:text>
-.BE
-
-</xsl:text>
-  </xsl:template>
-
-  <xsl:template match="d:refsynopsisdiv">
-    <xsl:text>.SH SYNOPSIS
-</xsl:text>
-    <xsl:apply-templates/>
-    <xsl:text>
-.BE
-</xsl:text>
-  </xsl:template>
-
-  <xsl:template match='tcl:pkgsynopsis|tcl:namespacesynopsis|d:keywordset'/>
-
-  <xsl:template match="tcl:cmdsynopsis|tcl:optionsynopsis">
-    <xsl:apply-templates/>
-    <xsl:choose>
-      <xsl:when test="d:command/node()[position() = last() and self::*]">
-        <!-- last element would have reset font -->
-      </xsl:when>
-      <xsl:otherwise>
-        <xsl:text>\fP</xsl:text>
-      </xsl:otherwise>
-    </xsl:choose>
-    <xsl:text>
-.sp
-</xsl:text>
-  </xsl:template>
-  <xsl:template match="tcl:cmdsynopsis[position() = last()]|tcl:optionsynopsis[position() = last()]">
-    <xsl:apply-templates/>
-    <xsl:choose>
-      <xsl:when test="d:command/node()[position() = last() and self::*]">
-        <!-- last element would have reset font -->
-      </xsl:when>
-      <xsl:otherwise>
-        <xsl:text>\fP</xsl:text>
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:template>
-
-  <xsl:template match="tcl:cmdsynopsis/d:command">
-    <xsl:text>\fB</xsl:text>
-    <xsl:apply-templates/>
-  </xsl:template>
-
-  <xsl:template match="d:option">
-    <xsl:text>\fI </xsl:text>
-    <xsl:apply-templates/>
-    <xsl:text>\fR</xsl:text>
-  </xsl:template>
-
-  <xsl:template match="d:group">
-    <xsl:apply-templates/>
-  </xsl:template>
-  <xsl:template match="d:group[@choice='opt']">
-    <xsl:text> ?</xsl:text>
-    <xsl:apply-templates/>
-    <xsl:text>?</xsl:text>
-  </xsl:template>
-  <xsl:template match="d:group[@choice='opt' and @rep='repeat']">
-    <xsl:text> ?</xsl:text>
-    <xsl:apply-templates/>
-    <xsl:text> ... ?</xsl:text>
-  </xsl:template>
-
-  <xsl:template match="d:arg">
-    <xsl:text>\fI </xsl:text>
-    <xsl:apply-templates/>
-  </xsl:template>
-
-  <xsl:template match="d:replaceable|d:emphasis">
-    <xsl:text>\fI</xsl:text>
-    <xsl:apply-templates/>
-    <xsl:text>\fR</xsl:text>
-  </xsl:template>
-
-  <xsl:template match="tcl:command|tcl:namespace|tcl:method|tcl:package">
-    <xsl:call-template name='inline.bold'/>
-  </xsl:template>
-  <xsl:template name='inline.bold'>
-    <xsl:text>\fB</xsl:text>
-    <xsl:apply-templates/>
-    <xsl:text>\fR</xsl:text>
-  </xsl:template>
-
-  <xsl:template match="d:refsect1">
-    <xsl:text>
-.SH </xsl:text>
-    <xsl:value-of select="translate(d:info/d:title,'abcdefghijklmnopqrstuvwxyz','ABCDEFGHIJKLMNOPQRSTUVWXYZ')"/>
-    <xsl:text>
-</xsl:text>
-    <xsl:apply-templates select='*[not(self::d:info)]'/>
-  </xsl:template>
-
-  <xsl:template match="d:para|d:note">
-    <xsl:text>
-.PP
-</xsl:text>
-    <xsl:if test='parent::d:listitem/parent::d:itemizedlist and
-                  not(preceding-sibling::d:para)'>
-      <xsl:text>*  </xsl:text>
-    </xsl:if>
-    <xsl:apply-templates/>
-    <xsl:text>
-</xsl:text>
-  </xsl:template>
-
-  <xsl:template match="d:para/text()">
-    <xsl:value-of select="."/>
-  </xsl:template>
-
-  <xsl:template match="d:refsect2|d:refsect3">
-    <xsl:apply-templates/>
-  </xsl:template>
-  <xsl:template match="d:refsect2/d:info|d:refsect3/d:info">
-    <xsl:apply-templates select='d:title'/>
-  </xsl:template>
-
-  <xsl:template match="d:acronym|d:link">
-    <xsl:apply-templates/>
-  </xsl:template>
-
-  <xsl:template match="d:refsect2/d:info/d:title|d:refsect3/d:info/d:title">
-    <xsl:text>.SS </xsl:text>
-    <xsl:apply-templates/>
-    <xsl:text>
-</xsl:text>
-  </xsl:template>
-
-  <xsl:template match="d:segmentedlist|d:variablelist|d:itemizedlist|d:orderedlist">
-    <xsl:text>
-.RS
-</xsl:text>
-    <xsl:apply-templates/>
-    <xsl:text>.RE
-</xsl:text>
-  </xsl:template>
-
-  <xsl:template match="d:seglistitem">
-    <xsl:text>.TP
-\fI</xsl:text>
-    <xsl:value-of select="d:seg[1]"/>
-    <xsl:text>\fP </xsl:text>
-    <xsl:value-of select="d:seg[2]"/>
-    <xsl:text>
-</xsl:text>
-  </xsl:template>
-
-  <xsl:template match="d:varlistentry">
-    <xsl:text>.TP
-\fI</xsl:text>
-    <xsl:apply-templates select="d:term"/>
-    <xsl:text>\fP 
-</xsl:text>
-    <xsl:apply-templates select="d:listitem"/>
-    <xsl:text>
-</xsl:text>
-  </xsl:template>
-  <xsl:template match='d:term|d:classname|d:tag|d:application'>
-    <xsl:call-template name='inline.bold'/>
-  </xsl:template>
-  <xsl:template match='d:listitem'>
-    <xsl:apply-templates/>
-  </xsl:template>
-
-  <xsl:template match='d:methodname|d:version|d:package|d:literal'>
-    <xsl:call-template name='inline.bold'/>
-  </xsl:template>
-
-  <xsl:template match="d:informalexample">
-    <xsl:text>.PP
-</xsl:text>
-    <xsl:apply-templates/>
-  </xsl:template>
-  <xsl:template match="d:example">
-    <xsl:text>.PP
-</xsl:text>
-<xsl:apply-templates select='d:title/node()|d:info/d:title/node()'/>
-    <xsl:text>.PP
-</xsl:text>
-    <xsl:apply-templates select='*[not(self::d:title|self::d:info)]'/>
-  </xsl:template>
-
-  <xsl:template match="d:programlisting|d:literallayout|d:computeroutput">
-    <xsl:text>.CS
-</xsl:text>
-    <xsl:apply-templates/>
-    <xsl:text>
-.CE
-</xsl:text>
-  </xsl:template>
-
-  <xsl:template match='d:author'>
-    <xsl:apply-templates select='d:firstname'/>
-    <xsl:text> </xsl:text>
-    <xsl:apply-templates select='d:surname'/>
-  </xsl:template>
-
-  <xsl:template match='d:firstname|d:surname'>
-    <xsl:apply-templates/>
-  </xsl:template>
-
-  <!-- Override built-in rules to omit unwanted content -->
-
-  <xsl:template match="*">
-    <xsl:message>No template matching <xsl:value-of select="name()"/> (parent <xsl:value-of select="name(..)"/>)</xsl:message>
-  </xsl:template>
-  <xsl:template match="text()[string-length(normalize-space()) = 0]|@*">
-    <!-- Don't emit white space -->
-  </xsl:template>
-
-</xsl:stylesheet>
diff --git a/tclxml-3.2/doc/tcldoc-1.0.dtd b/tclxml-3.2/doc/tcldoc-1.0.dtd
deleted file mode 100644
index c8e5def..0000000
--- a/tclxml-3.2/doc/tcldoc-1.0.dtd
+++ /dev/null
@@ -1,108 +0,0 @@
-<!-- tcldoc-1.0.dtd -
-   -
-   -	Customisation of DocBook for Tcl documentation.
-   -
-   - Copyright (c) 2000 Zveno Pty Ltd
-   -
-   - $Id: tcldoc-1.0.dtd,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
- -->
-
-<!-- Define overriding entities here -->
-
-<!ENTITY % common.attrib "">
-
-<!ENTITY % local.para.mix "|tclpackage|tclnamespace">
-<!ENTITY % local.refcomponent.mix "|tclcmdsynopsis|tclpkgsynopsis|tclnamespacesynopsis">
-<!ENTITY % local.synop.class "|tclcmdsynopsis">
-
-<!ENTITY % local.tech.char.class "|tclcommand">
-
-<!-- Import the DocBook DTD -->
-
-<!ENTITY % DocBook 
-	PUBLIC "-//Norman Walsh//DTD DocBk XML V4.1.2//EN" 
-	       "file:///usr/local/share/xml/docbook/dtd/docbookx.dtd">
-%DocBook;
-
-<!--
-   - Tcl documentation is written as a DocBook RefEntry.
-   - RefEntry includes a number of elements to represent
-   - commands, functions, options, etc.  For system-related
-   - concepts, these are used as-is.  However, the elements 
-   - below are used to distinguish Tcl-related concepts.
-   -
-   - In addition, XLink may be used for hyperlinking.
- -->
-
-<!-- tclcmdsynopsis -
-   -
-   -	Information about a Tcl command.
-   -	Content is taken to be Tcl commands, options, etc.
-   -
-  -->
-
-<!ELEMENT tclcmdsynopsis ((command | arg | group | sbr)+, synopfragment*)>
-<!ATTLIST tclcmdsynopsis
-	%cmdsynopsis.role.attrib;
-	%common.attrib;>
-
-<!-- tclpkgsynopsis -
-   -
-   -	Tcl Package usage synopsis.
-   -
-  -->
-
-<!ELEMENT tclpkgsynopsis ((package | version)+, synopfragment*)>
-<!ATTLIST tclpkgsynopsis
-	%cmdsynopsis.role.attrib;
-	%common.attrib;>
-
-<!ELEMENT package (#PCDATA)>
-<!ATTLIST package
-	%common.attrib;>
-
-<!ELEMENT version (#PCDATA)>
-<!ATTLIST version
-	%common.attrib;>
-
-<!ELEMENT tclpackage (#PCDATA)>
-<!ATTLIST tclpackage
-	%common.attrib;>
-
-<!-- tclnamespacesynopsis -
-   -
-   -	Tcl namespace usage synopsis.
-   -
-  -->
-
-<!ELEMENT tclnamespacesynopsis (tclnamespace+, synopfragment*)>
-<!ATTLIST tclnamespacesynopsis
-	%cmdsynopsis.role.attrib;
-	%common.attrib;>
-
-<!ELEMENT tclnamespace (#PCDATA)>
-<!ATTLIST tclnamespace
-	%common.attrib;>
-
-<!-- tcloptionsynopsis -
-   -
-   -	Tcl command configuration option synopsis.
-   -
-  -->
-
-<!ELEMENT tcloptionsynopsis ((option | arg | group | sbr)+, synopfragment*)>
-<!ATTLIST tcloptionsynopsis
-	%cmdsynopsis.role.attrib;
-	%common.attrib;>
-
-<!-- tclcommand -
-   -
-   -	A Tcl command, derived from DocBook's command.
-   -
-  -->
-
-<!ELEMENT tclcommand (%cptr.char.mix;)*>
-<!ATTLIST tclcommand
-	%moreinfo.attrib;
-	%command.role.attrib;
-	%common.attrib;>
diff --git a/tclxml-3.2/doc/tcldom.html b/tclxml-3.2/doc/tcldom.html
deleted file mode 100644
index 999578e..0000000
--- a/tclxml-3.2/doc/tcldom.html
+++ /dev/null
@@ -1,893 +0,0 @@
-<html>
-<head>
-<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
-<title>TclDOM</title>
-<link rel="stylesheet" href="tclxml.css">
-</head>
-<body><div class="refentry">
-<h1 class="title"><a name="id18406">TclDOM</a></h1>
-<h2>Contents</h2>
-<ul>
-<li><a href="#synopsis">Synopsis</a></li>
-<li><a href="#id19031">Description</a></li>
-<li><a href="#id19081">Packages and Namespaces</a></li>
-<li><a href="#id19172">Tokens</a></li>
-<li><a href="#id19233">Document and Node Commands</a></li>
-<li><a href="#id19265">DOM Interfaces</a></li>
-<li><a href="#id19314">Convenience Commands and Methods</a></li>
-<li>
-<a href="#id19362">Commands</a><ul>
-<li>
-<a href="#id19375">::dom::DOMImplementation</a><ul><li><a href="#id19408">Command Options</a></li></ul>
-</li>
-<li><a href="#id20417">::dom::document</a></li>
-<li><a href="#id21537">dom::node</a></li>
-<li><a href="#id22955">dom::element</a></li>
-<li><a href="#id23702">dom::processinginstruction</a></li>
-<li><a href="#id23883">dom::event</a></li>
-</ul>
-</li>
-<li><a href="#id25649">Errors</a></li>
-<li>
-<a href="#id25681">Implementations</a><ul>
-<li>
-<a href="#id25698">Tcl Implementation</a><ul><li><a href="#id25719">Limitations</a></li></ul>
-</li>
-<li>
-<a href="#id25760">libxml2 Implementation</a><ul><li><a href="#id25793">Limitations</a></li></ul>
-</li>
-</ul>
-</li>
-</ul>
-<div class="refnamediv">
-<span class="refname">::dom::DOMImplementation</span>, <span class="refname">::dom::hasfeature</span>, <span class="refname">::dom::create</span>, <span class="refname">::dom::destroy</span>, <span class="refname">::dom::parse</span>, <span class="refname">::dom::serialize</span>, <span class="refname">::dom::document</span>, <span class="refname">::dom::documenttype</span>, <span class="refname">::dom::node</span>, <span class="refname">::dom::element</span>, <span class="refname">::dom::event</span>, <span class="refname">::dom::selectNode</span>, <span class="refname">::dom::isNode</span>, <span class="refname">::dom::xinclude</span>, <span class="refname">::dom::prefix2namespaceURI</span>, <span class="refname">::dom::trim</span> — <span class="refpurpose">Tcl language binding for the W3C Document Object Model</span>
-</div>
-<div class="refsynopsisdiv">
-<a name="synopsis"></a><h2>Synopsis</h2>
-<div class="cmdsynopsis" id="id18562">
-<a name="id18562"></a><span class="command" id="id18567"><a name="package_require_dom"></a><tt>package require dom</tt> </span>
-</div>
-<br><span class="pkgsynopsis"><pre>package require dom ?3.2?</pre></span><div class="cmdsynopsis" id="id18602">
-<a name="id18602"></a><span class="command" id="id18606"><a name="__dom__DOMImplementation"></a><tt>::dom::DOMImplementation</tt> </span><em>method</em> ?args...?</div>
-<div class="cmdsynopsis" id="id18632">
-<a name="id18632"></a><span class="command" id="id18635"><a name="__dom__hasfeature"></a><tt>::dom::hasfeature</tt> </span><em>feature</em> <em>version</em>
-</div>
-<div class="cmdsynopsis" id="id18657">
-<a name="id18657"></a><span class="command" id="id18660"><a name="__dom__create"></a><tt>::dom::create</tt> </span>
-</div>
-<div class="cmdsynopsis" id="id18665">
-<a name="id18665"></a><span class="command" id="id18669"><a name="__dom__destroy"></a><tt>::dom::destroy</tt> </span><em>token</em>
-</div>
-<div class="cmdsynopsis" id="id18682">
-<a name="id18682"></a><span class="command" id="id18685"><a name="__dom__parse"></a><tt>::dom::parse</tt> </span><em>xml</em> ?option value...?</div>
-<div class="cmdsynopsis" id="id18713">
-<a name="id18713"></a><span class="command" id="id18716"><a name="__dom__serialize"></a><tt>::dom::serialize</tt> </span><em>token</em> ?option value...?</div>
-<div class="cmdsynopsis" id="id18744">
-<a name="id18744"></a><span class="command" id="id18747"><a name="__dom__document"></a><tt>::dom::document</tt> </span><em>method</em> <em>token</em> ?args...?</div>
-<div class="cmdsynopsis" id="id18780">
-<a name="id18780"></a><span class="command" id="id18782"><a name="__dom__documenttype"></a><tt>::dom::documenttype</tt> </span><em>method</em> <em>token</em> ?args...?</div>
-<div class="cmdsynopsis" id="id18815">
-<a name="id18815"></a><span class="command" id="id18818"><a name="__dom__node"></a><tt>::dom::node</tt> </span><em>method</em> <em>token</em> ?args...?</div>
-<div class="cmdsynopsis" id="id18850">
-<a name="id18850"></a><span class="command" id="id18853"><a name="__dom__element"></a><tt>::dom::element</tt> </span><em>method</em> <em>token</em> ?args...?</div>
-<div class="cmdsynopsis" id="id18885">
-<a name="id18885"></a><span class="command" id="id18888"><a name="__dom__event"></a><tt>::dom::event</tt> </span><em>method</em> <em>token</em> ?args...?</div>
-<div class="cmdsynopsis" id="id18921">
-<a name="id18921"></a><span class="command" id="id18924"><a name="__dom__selectNode"></a><tt>::dom::selectNode</tt> </span><em>token</em> <em>xpath</em> ?option value...?</div>
-<div class="cmdsynopsis" id="id18956">
-<a name="id18956"></a><span class="command" id="id18959"><a name="__dom__isNode"></a><tt>::dom::isNode</tt> </span><em>token</em>
-</div>
-<div class="cmdsynopsis" id="id18973">
-<a name="id18973"></a><span class="command" id="id18976"><a name="__dom__xinclude"></a><tt>::dom::xinclude</tt> </span><em>doc</em>
-</div>
-<div class="cmdsynopsis" id="id18989">
-<a name="id18989"></a><span class="command" id="id18992"><a name="__dom__prefix2namespaceURI"></a><tt>::dom::prefix2namespaceURI</tt> </span><em>node</em> <em>prefix</em>
-</div>
-<div class="cmdsynopsis" id="id19014">
-<a name="id19014"></a><span class="command" id="id19017"><a name="__dom__trim"></a><tt>::dom::trim</tt> </span><em>doc</em>
-</div>
-<h3>Tcl Namespace Usage</h3>
-<br><tt>::dom</tt><br><tt>::dom::tcl</tt><br><tt>::dom::libxml2</tt><p></p>
-</div>
-<div class="refsect1">
-<h2>
-<a name="id19031"></a>Description</h2>
-<p>TclDOM is a Tcl language binding for the <a href="http://www.w3c.org/DOM/">W3C Document Object Model</a> (DOM).  DOM provides a view of a XML (or HTML) document as a tree structure.  Currently, TclDOM only supports XML documents.</p>
-<p>The package implements most of the DOM Level 1 interfaces and also some Level 2 and Level 3 interfaces.  There are also a number of non-standard commands and methods provided for the convenience of application developers (these are documented).</p>
-<p>The DOM specification should be read in conjunction with this reference manual, as it explains the meaning and purpose of the various interfaces.  This manual is not a tutorial on how to use the DOM.</p>
-<p>TclDOM also provides two implementations of the API:  a pure-Tcl implementation and a C implementation based on the Gnome libxml2 library.</p>
-</div>
-<div class="refsect1">
-<h2>
-<a name="id19081"></a>Packages and Namespaces</h2>
-<p>TclDOM defines the <tt>dom</tt> package and also a Tcl namespace using that same name.</p>
-<p>Implementations define their own package name and Tcl namespace within the <tt>::dom</tt> Tcl namespace:</p>
-<dl>
-<span class="term">Tcl implementation</span><dd><p>Package <tt>dom::tcl</tt>, Tcl namespace <tt>::dom::tcl</tt>.</p></dd>
-<span class="term">libxml2</span><dd><p>Package <tt>dom::libxml2</tt>, Tcl namespace <tt>::dom::libxml2</tt>.</p></dd>
-</dl>
-<p>Each DOM Document is allocated a Tcl namespace within the <tt>::dom</tt> Tcl namespace.  All storage for the document and commands are defined within that Tcl namespace.</p>
-</div>
-<div class="refsect1">
-<h2>
-<a name="id19172"></a>Tokens</h2>
-<p>The TclDOM API uses <em>tokens</em> as identifiers for nodes within the document tree.  This technique has been used to allow alternate implementations of TclDOM to be efficient, while retaining compatibility with the pure-Tcl implementation.</p>
-<p>The format of the token itself as well as the data structure referred to by the token are <em>not</em> public and an application should not rely on these.  Instead, an application should use the accessor methods provided by the API.</p>
-<p>There is no requirement to always use the same token for a node.  In fact, an important performance optimisation for some implementations is to create a new token when a node is accessed, regardless of whether a token has already been issued for that node.  This implies that in order to test whether two tokens refer to the same node it is not sufficient to test the string values of the tokens; the <tt>isSameNode</tt> method must be used for this purpose.  For example,</p>
-<div class="informalexample"><pre><div class="programlisting"><pre>
-proc NodeCompare1 {A B} {
-    return [string equal $A $B]
-}
-proc NodeCompare2 {A B} {
-    return [$A isSameNode $B]
-}
-</pre></div></pre></div>
-<p>In the above example, <span class="literal">NodeCompare2</span> correctly determines whether its two arguments refer to the same node.</p>
-</div>
-<div class="refsect1">
-<h2>
-<a name="id19233"></a>Document and Node Commands</h2>
-<p>Each Document and Node has a Tcl command defined that may be used to control the object.  This command may be used to invoke the methods by the <strong>::dom::document</strong> command (for Documents) or the <strong>::dom::node</strong> command (for all other Nodes).  If a Document' or Node's Tcl command is destroyed then the Document or Node is also destroyed.</p>
-</div>
-<div class="refsect1">
-<h2>
-<a name="id19265"></a>DOM Interfaces</h2>
-<p>Each <em>Interface</em> in the DOM specification is implemented with a Tcl command in the <tt>dom</tt> namespace.  A few interfaces have not been mapped to Tcl commands because Tcl already provides the required functionality, for example the <tt>CharacterData</tt> interface.</p>
-<p><em>method</em>s for interfaces are methods (subcommands) of the corresponding Tcl command.</p>
-<p>Each <em>attribute</em> of an interface is a configuration option for an object in the document tree.</p>
-</div>
-<div class="refsect1">
-<h2>
-<a name="id19314"></a>Convenience Commands and Methods</h2>
-<p>DOM doesn't always provide an interface, method or attribute for every function required.  For example, until DOM Level 3 for was no standard for creating, parsing and serializing a document.  Sometimes using the standard DOM interface is awkward.  TclDOM provides a number of non-standard features to overcome these problems.</p>
-<p>A major convenience is that each method of the <tt>DOMImplementation</tt> interface is also defined as a command.  For example, rather than using <strong>dom::DOMImplementation create</strong> to create a new document, the shorter command <strong>dom::create</strong> may be used.</p>
-<p>Implementations may also provide direct access to specific features.  Refer to the documentation for a DOM implementation.</p>
-</div>
-<div class="refsect1">
-<h2>
-<a name="id19362"></a>Commands</h2>
-<div class="refsect2">
-<h3>
-<a name="id19375"></a><strong>::dom::DOMImplementation</strong>
-</h3>
-<p>The <strong>::dom::DOMImplementation</strong> command implements the <tt>DOMImplementation</tt> DOM interface.  It is used to provide implementation-specific features not explicitly defined in the DOM specification.</p>
-<div class="refsect3">
-<h4>
-<a name="id19408"></a>Command Options</h4>
-<p>The following command options may be used.  These are also available as commands.</p>
-<dl>
-<span class="term"><span class="methodname">hasFeature</span></span><dd>
-<div class="cmdsynopsis" id="id19440">
-<a name="id19440"></a>hasFeature <em>feature</em>
-</div>
-<p>Provides a test for existence of a feature.  Returns <span class="literal">1</span> if a feature is implemented, <span class="literal">0</span> otherwise.</p>
-</dd>
-<span class="term"><span class="methodname">create</span></span><dd>
-<div class="cmdsynopsis" id="id19483">
-<a name="id19483"></a>create <em>type</em>
-</div>
-<p>Creates the root node of a new DOM document.  The document element type may be specified as an argument, in which case that element is created.  The return value is a token referring to the root node of the newly created document.  A Tcl command is also created with the same name as the document's token.  This command is a shortcut for the <strong>::dom::document</strong> command.</p>
-<div class="note"><p>Non-standard method.  DOM Level 2 introduced the <span class="methodname">createDocument</span> method.</p></div>
-</dd>
-<span class="term"><span class="methodname">createDocument</span></span><dd>
-<div class="cmdsynopsis" id="id19537">
-<a name="id19537"></a>createDocument <em>nsURI</em> <em>type</em> <em>doctype</em>
-</div>
-<p>Creates the root node of a new DOM document.  The document element namespace URI and local-name (element type) may be specified as an argument, in which case that element is created.  If the document type is given then the newly created document is configured to use that document type.  The return value is a token referring to the root node of the newly created document.  A Tcl command is also created with the same name as the document's token.  This command is a shortcut for the <strong>::dom::document</strong> command.</p>
-</dd>
-<span class="term"><span class="methodname">createDocumentType</span></span><dd>
-<div class="cmdsynopsis" id="id19595">
-<a name="id19595"></a>createDocumentType <em>name</em> <em>publicid</em> <em>systemid</em> <em>internaldtd</em>
-</div>
-<p>Creates a Document Type Declaration.  The return value is a token for the newly created document type declaration.  A Tcl command is also created with the same name as the document type's token.  This command is a shortcut for the <strong>::dom::documenttype</strong> command.</p>
-</dd>
-<span class="term"><span class="methodname">createNode</span></span><dd>
-<div class="cmdsynopsis" id="id19661">
-<a name="id19661"></a>createNode <em>token</em> <em>xpath</em>
-</div>
-<p>May create a node in the document.   <em><em>token</em></em> specifies a context for the XPath expression given by  <em><em>xpath</em></em>.  The expression must resolve to a node.  If the node exists then no further action is taken.  Otherwise the node is created.  The token of the matched or newly created node is returned.</p>
-<div class="note"><p>Non-standard method.</p></div>
-</dd>
-<span class="term"><span class="methodname">destroy</span></span><dd>
-<div class="cmdsynopsis" id="id19722">
-<a name="id19722"></a>destroy <em>token</em>
-</div>
-<p>This method frees all data structures associated with a DOM document or node.  The  <em><em>token</em></em> argument must refer to a valid token for any document or any node in the tree of a document.</p>
-<p>When the given token refers to a DOM document then the entire document is destroyed; the Tcl namespace for the document is deleted and all document and node commands are deleted.  All tokens for the document or nodes in the document become invalid.</p>
-<p>When the token refers to a node the node is removed from the tree before it is destroyed.  If the node has children or attributes, they will also be destroyed.  The Tcl command for the node is deleted.</p>
-</dd>
-<span class="term"><span class="methodname">isNode</span></span><dd>
-<div class="cmdsynopsis" id="id19781">
-<a name="id19781"></a>isNode <em>token</em>
-</div>
-<p>Tests whether the given token is a valid token for some DOM node.</p>
-<div class="note"><p>Non-standard method.</p></div>
-</dd>
-<span class="term"><span class="methodname">parse</span></span><dd>
-<div class="cmdsynopsis" id="id19821">
-<a name="id19821"></a>parse <em>xml</em> "<em>option</em> <em>value</em>"</div>
-<p>This method parses XML formatted text given by the  <em><em>xml</em></em> argument and constructs a DOM tree for the document.  The return result is the token of the root node of the newly created document.  The document will also have a Tcl command associated with it, see the <tt>createDocument</tt> method.</p>
-<p>This method uses the <a href="http://tclxml.sourceforge.net/">TclXML</a> package to perform the parsing operation.  The <tt>dom</tt> package itself does not include an XML parser.  TclXML supports the use of multiple parser implementations.  The  <em>-parser</em> may be used to specify which XML parser class to use.</p>
-<p>All options not listed below are passed to the TclXML parser.</p>
-<p>Valid configuration options are:</p>
-<dl>
-<span class="term"><span class="arg">-parser</span> <span class="arg"> "<span class="arg">{}</span> | <span class="arg">libxml2</span> | <span class="arg">tcl</span>"</span></span><dd><p>This option specifies the name of a TclXML parser class to use to parse the XML data.  The given parser class must be registered with the TclXML package.  If an empty string is given then the default parser class is used.  If an explicit value is given and that parser class is not registered then the command will fail, despite the fact that another parser may be available.</p></dd>
-<span class="term"><span class="arg">-progresscommand</span> <span class="arg"><em>script</em></span></span><dd><p>This option specifies a Tcl command to be invoked from time to time while the DOM tree is being constructed.  The script will be invoked after a certain number of element start tags have been processed, given by the  <em>-chunksize</em> option.</p></dd>
-<span class="term"><span class="arg">-chunksize</span> <span class="arg"><em>integer</em></span></span><dd><p>This option specifies how many element start tags to process before invoking the script given by the  <em>-progresscommand</em> option.</p></dd>
-</dl>
-</dd>
-<span class="term"><span class="methodname">selectNode</span></span><dd>
-<div class="cmdsynopsis" id="id20023">
-<a name="id20023"></a>selectNode <em>token</em> <em>xpath</em> ?option value...?</div>
-<p>Resolves the XPath location path given by  <em><em>xpath</em></em>.   <em><em>token</em></em> is the initial context for the location path.  Returns the resulting nodeset as a (static) Tcl list.</p>
-<p>The following options may be specified:</p>
-<dl>
-<span class="term"> <em>-namespaces</em></span><dd>
-<p>The value for this option is a list of prefix-URI pairs.  Each of these pairs defines an XML Namespace and its prefix for the purposes of evaluating the XPath expression.  The document itself may use a different prefix for the same XML Namespace.</p>
-<p>This option may be repeated, in which case the lists of namespace pairs are merged and all of the XML Namespaces registered.</p>
-</dd>
-</dl>
-<div class="note"><p>Non-standard method.</p></div>
-</dd>
-<span class="term"><span class="methodname">serialize</span></span><dd>
-<div class="cmdsynopsis" id="id20126">
-<a name="id20126"></a>serialize <em>token</em> "<em>option</em> <em>value</em>"</div>
-<p>This method returns the XML formatted text corresponding to the node given by  <em>token</em>.  The text is guaranteed to be a well-formed XML document, unless the  <em>-method</em> option specifies a non-XML output method.</p>
-<p>Valid configuration options are:</p>
-<dl>
-<span class="term"><span class="arg">-method</span> <span class="arg">xml|html|text</span></span><dd><p>Specifies how the document tree is to be serialized as text.  The allowed values correspond to the output methods defined by the XSLT v1.0 W3C Recommendation.  The <span class="literal">xml</span> method produces output that conforms to the XML syntax.  The <span class="literal">html</span> method produces output that conforms to HTML syntax.  The <span class="literal">text</span> method serializes only the text nodes of the document and disables all output escaping.</p></dd>
-<span class="term"><span class="arg">-indent</span> <span class="arg"><em>boolean</em></span></span><dd><p>Specifies that the output is to be "pretty-printed", ie. element content is indented to provide a visual indication of nesting levels.</p></dd>
-<span class="term"><span class="arg">-encoding</span> <span class="arg"><em>encoding</em></span></span><dd><p>Specifies that the output is to be encoded using the given character encoding.  If the encoding is <span class="literal">utf-8</span> (the default) then the output is treated as a string within Tcl.  If any other encoding is specified then the output is treated as a ByteArray object (ie. as binary).</p></dd>
-<span class="term"><span class="arg">-newline</span> <span class="arg"><em>elementlist</em></span></span><dd>
-<p>This option specifies a list of element types for which newline characters will be added before and after the start and end tags for those elements upon serialization.  This option is deprecated: the <span class="arg">-indent</span> option should be used instead.</p>
-<p>White space is significant in XML, so the <tt>dom</tt> package never adds extra white space for purposes of "pretty-printing" the XML source document.  On some platforms, such as VMS, this can actually cause serious problems due to line length limitations.  This option provides the convenience of adding newlines to certain nominated element types for formatting the source into lines.</p>
-<p>Examples:</p>
-<p>Suppose the following DOM document is constructed:</p>
-<div class="informalexample"><pre><div class="programlisting"><pre>
-set doc [::dom::DOMImplementation create]
-set top [::dom::document createElement $doc Root]
-set node [::dom::document createElement $top First]
-::dom::document createElement $node Second
-::dom::document createElement $top First
-</pre></div></pre></div>
-<p>Without the  <em>-newline</em> option the serialized document would be:</p>
-<div class="informalexample"><pre><div class="programlisting"><pre>
-::dom::DOMImplementation serialize $doc
-<div class="computeroutput"><pre>
-<?xml version="1.0"?>
-<!DOCTYPE Root>
-<Root><First><Second/></First><First/></Root>
-
-</pre></div>
-</pre></div></pre></div>
-<p>With the  <em>-newline</em> option the serialized document would be:</p>
-<div class="informalexample"><pre><div class="programlisting"><pre>
-::dom::DOMImplementation serialize $doc -newline First
-<div class="computeroutput"><pre>
-<?xml version="1.0"?>
-<!DOCTYPE Root>
-<Root>
-<First>
-<Second/>
-</First>
-<First/>
-</Root>
-
-</pre></div>
-</pre></div></pre></div>
-</dd>
-</dl>
-</dd>
-<span class="term"><span class="methodname">trim</span></span><dd>
-<div class="cmdsynopsis" id="id20386">
-<a name="id20386"></a>trim <em>token</em>
-</div>
-<p>This method removes any node containing only white space from the document tree of the node given by  <em><em>token</em></em>.</p>
-</dd>
-</dl>
-</div>
-</div>
-<div class="refsect2">
-<h3>
-<a name="id20417"></a><strong>::dom::document</strong>
-</h3>
-<p>This command implements the Document interface in the DOM specification.  The most important aspect of this command are its factory methods for creating nodes.</p>
-<p>The methods accepted by this command are as follows:</p>
-<dl>
-<span class="term"><span class="methodname">cget</span></span><dd>
-<div class="cmdsynopsis" id="id20458">
-<a name="id20458"></a><span class="methodname">cget</span><em>token</em> -option</div>
-<p>This method returns the value of the given configuration option.</p>
-</dd>
-<span class="term"><span class="methodname">configure</span></span><dd>
-<div class="cmdsynopsis" id="id20496">
-<a name="id20496"></a><span class="methodname">configure</span><em>token</em> "<em>option</em> <em>value</em>..."</div>
-<p>This method sets the value of the given configuration options.</p>
-<p>Valid configuration options are:</p>
-<dl>
-<span class="term"><span class="arg">-doctype</span></span><dd>
-<p>Specifies the token of the Document Type Declaration node.</p>
-<p>This is a read-only option.  Use the factory method to create a Document Type Declaration node.</p>
-</dd>
-<span class="term"><span class="arg">-implementation</span></span><dd>
-<p>Specifies the token of the document's implementation.</p>
-<p>This is a read-only option.</p>
-</dd>
-<span class="term"><span class="arg">-documentElement</span></span><dd>
-<p>Specifies the token of the document's document element node.  A document node may only have one document element, but may have other types of children (such as comments).</p>
-<p>This is a read-only option.  Use the factory method to create the document element node.</p>
-</dd>
-</dl>
-</dd>
-<span class="term"><span class="methodname">createElement</span></span><dd>
-<div class="cmdsynopsis" id="id20622">
-<a name="id20622"></a><span class="methodname">createElement</span><em>token</em> <em>type</em>
-</div>
-<p>This method creates an element node as a child of the given node specified by  <em><em>token</em></em> and returns the new node's token as its result.   <em><em>token</em></em> must be a node of type element, document or documentFragment.  The new, child element is added as the last child of  <em><em>token</em></em>'s list of children.  The new element's type is given by the  <em><em>type</em></em> argument.  The new element is created with an empty attribute list.</p>
-<p>A Tcl command is created with the same name as the new node's token.  This command is a shortcut for the <strong>::dom::node</strong> command.</p>
-</dd>
-<span class="term"><span class="methodname">createElementNS</span></span><dd>
-<div class="cmdsynopsis" id="id20697">
-<a name="id20697"></a><span class="methodname">createElementNS</span><em>token</em> <em>nsuri</em> <em>qualname</em>
-</div>
-<p>This method creates an element node in an XML Namespace as a child of the given node specified by  <em><em>token</em></em> and returns the new node's token as its result.   <em><em>token</em></em> must be a node of type element, document or documentFragment.  The new, child element is added as the last child of  <em><em>token</em></em>'s list of children.  The new element is created in the XML Namespace given by the namespace URI  <em><em>nsuri</em></em>.  The new element's qualifed name (QName) is given by the  <em><em>qualname</em></em> argument.  Qualified names have the form <span class="literal">prefix:local-part</span>.  The new element is created with an empty attribute list.</p>
-<p>A Tcl command is created with the same name as the new node's token.  This command is a shortcut for the <strong>::dom::node</strong> command.</p>
-</dd>
-<span class="term"><span class="methodname">createDocumentFragment</span></span><dd>
-<div class="cmdsynopsis" id="id20790">
-<a name="id20790"></a><span class="methodname">createDocumentFragment</span><em>token</em>
-</div>
-<p>This method creates a documentFragment node as a child of the given node specified by  <em><em>token</em></em> and returns the new node's token as its result.   <em><em>token</em></em> must be a node of type element, document or documentFragment.</p>
-<p>A Tcl command is created with the same name as the new node's token.  This command is a shortcut for the <strong>::dom::node</strong> command.</p>
-</dd>
-<span class="term"><span class="methodname">createTextNode</span></span><dd>
-<div class="cmdsynopsis" id="id20846">
-<a name="id20846"></a><span class="methodname">createTextNode</span><em>token</em> <em>text</em>
-</div>
-<p>This method creates a textNode node as a child of the given node specified by  <em><em>token</em></em> and returns the new node's token as its result.   <em><em>token</em></em> must be a node of type element, document or documentFragment.  The new, child textNode is added as the last child of  <em><em>token</em></em>'s list of children.  The new textNode is created with its value set to  <em><em>text</em></em>.</p>
-<p>A Tcl command is created with the same name as the new node's token.  This command is a shortcut for the <strong>::dom::node</strong> command.</p>
-</dd>
-<span class="term"><span class="methodname">createComment</span></span><dd>
-<div class="cmdsynopsis" id="id20919">
-<a name="id20919"></a><span class="methodname">createComment</span><em>token</em> <em>data</em>
-</div>
-<p>This method creates a comment node as a child of the given node specified by  <em><em>token</em></em> and returns the new node's token as its result.   <em><em>token</em></em> must be a node of type element, document or documentFragment.  The new, child comment is added as the last child of  <em><em>token</em></em>'s list of children.  The new comment is created with its value set to  <em><em>data</em></em>.</p>
-<p>A Tcl command is created with the same name as the new node's token.  This command is a shortcut for the <strong>::dom::node</strong> command.</p>
-</dd>
-<span class="term"><span class="methodname">createCDATASection</span></span><dd>
-<div class="cmdsynopsis" id="id20993">
-<a name="id20993"></a><span class="methodname">createCDATASection</span><em>token</em> <em>text</em>
-</div>
-<p>TclDOM does not distinguish between textNodes and CDATASection nodes.  Accordingly, this method creates a textNode node as a child of the given node specified by  <em><em>token</em></em> and returns the new node's token as its result.   <em><em>token</em></em> must be a node of type element, document or documentFragment.  The new, child textNode is added as the last child of  <em><em>token</em></em>'s list of children.  The new node is created with its value set to  <em><em>text</em></em> and has the attribute  <em>-cdatasection</em> set to the value <span class="literal">1</span>.</p>
-<p>A Tcl command is created with the same name as the new node's token.  This command is a shortcut for the <strong>::dom::node</strong> command.</p>
-</dd>
-<span class="term"><span class="methodname">createProcessingInstruction</span></span><dd>
-<div class="cmdsynopsis" id="id21076">
-<a name="id21076"></a><span class="methodname">createProcessingInstruction</span><em>token</em> <em>target</em> <em>data</em>
-</div>
-<p>This method creates a processingInstruction node as a child of the given node specified by  <em><em>token</em></em> and returns the new node's token as its result.   <em><em>token</em></em> must be a node of type element, document or documentFragment.  The new, child processingInstruction is added as the last child of  <em><em>token</em></em>'s list of children.  The new node is created with its name set to  <em><em>target</em></em> and its value set to  <em><em>data</em></em>.</p>
-<p>A Tcl command is created with the same name as the new node's token.  This command is a shortcut for the <strong>::dom::node</strong> command.</p>
-</dd>
-<span class="term"><span class="methodname">createAttribute</span></span><dd>
-<div class="cmdsynopsis" id="id21162">
-<a name="id21162"></a><span class="methodname">createAttribute</span><em>token</em> <em>name</em>
-</div>
-<p>This method creates an attribute node for the given element specified by  <em><em>token</em></em> and returns the new node's token as its result.   <em><em>token</em></em> must be a node of type element.  The new attribute is created with its name set to  <em><em>name</em></em> and an empty value.</p>
-<p>A Tcl command is created with the same name as the new node's token.  This command is a shortcut for the <strong>::dom::node</strong> command.</p>
-<div class="note"><p>This method is included for completeness with respect to the DOM specification.  The preferred method for setting element attributes is to use the <strong>::dom::element</strong> command.</p></div>
-</dd>
-<span class="term"><span class="methodname">createEntity</span></span><dd>
-<div class="cmdsynopsis" id="id21244">
-<a name="id21244"></a><span class="methodname">createEntity</span><em>token</em>
-</div>
-<p>Not currently implemented.</p>
-</dd>
-<span class="term"><span class="methodname">createEntityReference</span></span><dd>
-<div class="cmdsynopsis" id="id21279">
-<a name="id21279"></a><span class="methodname">createEntityReference</span><em>token</em> <em>name</em>
-</div>
-<p>Not currently implemented.</p>
-</dd>
-<span class="term"><span class="methodname">createEvent</span></span><dd>
-<div class="cmdsynopsis" id="id21320">
-<a name="id21320"></a><span class="methodname">createEvent</span><em>token</em> <em>name</em>
-</div>
-<p>This method creates an event node in the document specified by  <em><em>token</em></em> and returns the new node's token as its result.   <em><em>token</em></em> must be a node of type document.  The event type is specified by  <em><em>name</em></em>.</p>
-<p>A Tcl command is created with the same name as the new node's token.  This command is a shortcut for the <strong>::dom::event</strong> command.</p>
-</dd>
-<span class="term"><span class="methodname">getElementsByTagName</span></span><dd>
-<div class="cmdsynopsis" id="id21387">
-<a name="id21387"></a><span class="methodname">getElementsByTagName</span><em>token</em> <em>name</em>
-</div>
-<p>This method searches the node given by the argument  <em><em>token</em></em> for child elements with a type matching the argument  <em><em>name</em></em>.  The name <span class="literal">*</span> matches all elements.  All descendants of  <em><em>token</em></em> are searched.  This method returns a "live-list"; the return result of this method is the name of a Tcl variable, the content of which is a Tcl list containing tokens for all elements that match.</p>
-</dd>
-<span class="term"><span class="methodname">dtd</span></span><dd>
-<div class="cmdsynopsis" id="id21450">
-<a name="id21450"></a><span class="methodname">dtd</span>validate</div>
-<p>This method performs DTD validation upon the document.  If the method returns successfully, then the document is valid.  Otherwise the document is invalid and the error returned contains the reason.</p>
-</dd>
-<span class="term"><span class="methodname">schema</span></span><dd>
-<div class="cmdsynopsis" id="id21483">
-<a name="id21483"></a><span class="methodname"><em>submethod</em></span> ?<em>args</em>...?</div>
-<p>This method performs XML Schema validation upon the document.  Schema validation is performed in two steps.  First the document is compiled into a schema document.  Second, the schema document is used to schema-validate an instance document.</p>
-<p>Example:</p>
-<div class="informalexample"><pre><div class="programlisting"><pre>
-set schema [dom::parse $XML]
-$schema schema compile
-set instance [dom::parse $XML2]
-$schema schema validate $instance
-</pre></div></pre></div>
-<p>If the document is changed after compiling, then schema document must be recompiled.</p>
-</dd>
-</dl>
-</div>
-<div class="refsect2">
-<h3>
-<a name="id21537"></a><strong>dom::node</strong>
-</h3>
-<p>This command implements generic functions for DOM nodes.</p>
-<p>The methods accepted by this command are as follows:</p>
-<dl>
-<span class="term"><span class="methodname">cget</span></span><dd>
-<div class="cmdsynopsis" id="id21577">
-<a name="id21577"></a><span class="methodname">cget</span><em>token</em> option</div>
-<p>This method returns the value of the given configuration option for the node given by  <em><em>token</em></em>.</p>
-</dd>
-<span class="term"><span class="methodname">configure</span></span><dd>
-<div class="cmdsynopsis" id="id21620">
-<a name="id21620"></a><span class="methodname">configure</span><em>token</em> "<em>option</em> <em>value</em>..."</div>
-<p>This method sets the value of the given configuration option for the node given by  <em><em>token</em></em>.</p>
-<p>Valid configuration options are as follows:</p>
-<dl>
-<span class="term"><span class="arg">-nodeName</span></span><dd>
-<p>Returns the node name.  This is a read-only option.</p>
-<p>The DOM specification gives the meaning of names for different types of nodes.  For example, the  <em>-nodeName</em> option of an element node is the element type.</p>
-</dd>
-<span class="term"><span class="arg">-nodeType</span></span><dd><p>Returns the type of the node given by  <em><em>token</em></em>.  This is a read-only option.</p></dd>
-<span class="term"> <em>-parentNode</em></span><dd><p>Returns the parent node of the node given by  <em><em>token</em></em>.  This is a read-only option.</p></dd>
-<span class="term"> <em>-childNodes</em></span><dd><p>Returns the name of a Tcl variable which contains a list of the children of the node given by  <em><em>token</em></em>.  The variable contains the "live" list of children.  This is a read-only option.</p></dd>
-<span class="term"> <em>-firstChild</em></span><dd><p>Returns the first child node of the node given by  <em><em>token</em></em>.  This is a read-only option.</p></dd>
-<span class="term"> <em>-lastChild</em></span><dd><p>Returns the last child node of the node given by  <em><em>token</em></em>.  This is a read-only option.</p></dd>
-<span class="term"> <em>-previousSibling</em></span><dd><p>Returns the parent's child node which appears before this node.  If this child is the first child of its parent then returns an empty string.  This is a read-only option.</p></dd>
-<span class="term"> <em>-nextSibling</em></span><dd><p>Returns the parent's child node which appears after this node.  If this child is the last child of its parent then returns an empty string.  This is a read-only option.</p></dd>
-<span class="term"> <em>-attributes</em></span><dd><p>Returns the name of a Tcl array variable which contains the attribute list for an element node.  If the node is not an element type node then returns an empty string.  The indices of the array are attribute names, and the values of the array elements are their corresponding attribute values.  This is a read-only option.</p></dd>
-<span class="term"> <em>-nodeValue</em><span class="arg"><em>data</em></span></span><dd><p>Specifies the value of a node.  The DOM specification gives the meaning of values for different types of nodes.  For example, the  <em>-nodeValue</em> option of a textNode node is the node's text.</p></dd>
-</dl>
-</dd>
-<span class="term"><span class="methodname">insertBefore</span></span><dd>
-<div class="cmdsynopsis" id="id21912">
-<a name="id21912"></a><span class="methodname">insertBefore</span><em>token</em> <em>newchild</em> <em>refchild</em>
-</div>
-<p>This method removes the node given by  <em><em>newchild</em></em> from its parent.  If no  <em><em>refchild</em></em> argument is given then  <em><em>newchild</em></em> is appended to  <em><em>token</em></em>'s list of children.  If the  <em><em>refchild</em></em> argument is given then this method adds  <em><em>newchild</em></em> as a child of  <em><em>token</em></em>.  The new child node is positioned before the node  <em><em>refchild</em></em> in  <em><em>token</em></em>'s list of children.  Returns an empty string.</p>
-</dd>
-<span class="term"><span class="methodname">replaceChild</span></span><dd>
-<div class="cmdsynopsis" id="id22008">
-<a name="id22008"></a><span class="methodname">replaceChild</span><em>token</em> <em>newchild</em> <em>oldchild</em>
-</div>
-<p>This method removes the node given by  <em><em>newchild</em></em> from its parent.  It then also removes the node given by  <em><em>oldchild</em></em> from  <em><em>token</em></em>.   <em><em>newchild</em></em> is then added as a child of  <em><em>token</em></em> in  <em><em>oldchild</em></em>'s original position in the list of children.  The method returns the token  <em><em>oldchild</em></em>, which will now have no parent.</p>
-</dd>
-<span class="term"><span class="methodname">removeChild</span></span><dd>
-<div class="cmdsynopsis" id="id22092">
-<a name="id22092"></a><span class="methodname">removeChild</span><em>token</em> <em>oldchild</em>
-</div>
-<p>This method removes the node given by  <em><em>oldchild</em></em> from its parent,  <em><em>token</em></em>.  The method returns the token  <em><em>oldchild</em></em>, which will now have no parent.</p>
-</dd>
-<span class="term"><span class="methodname">appendChild</span></span><dd>
-<div class="cmdsynopsis" id="id22148">
-<a name="id22148"></a><span class="methodname">appendChild</span><em>token</em> <em>newchild</em>
-</div>
-<p>This method removes the node given by  <em><em>newchild</em></em> from its parent.   <em><em>newchild</em></em> is then appended to the end of the list of children for node  <em><em>token</em></em>.  The method returns the token  <em><em>newchild</em></em>.</p>
-</dd>
-<span class="term"><span class="methodname">hasChildNodes</span></span><dd>
-<div class="cmdsynopsis" id="id22210">
-<a name="id22210"></a><span class="methodname">hasChildNodes</span><em>token</em>
-</div>
-<p>Returns <span class="literal">1</span> if the given node has any child nodes, <span class="literal">0</span> otherwise.</p>
-</dd>
-<span class="term"><span class="methodname">isSameNode</span></span><dd>
-<div class="cmdsynopsis" id="id22250">
-<a name="id22250"></a><span class="methodname">isSameNode</span><em>token</em> <em>ref</em>
-</div>
-<p>Returns <span class="literal">1</span> if the given node is the same node as the node given by the <span class="arg"><span class="literal">ref</span></span> token, <span class="literal">0</span> otherwise.</p>
-</dd>
-<span class="term"><span class="methodname">cloneNode</span></span><dd>
-<div class="cmdsynopsis" id="id22303">
-<a name="id22303"></a><span class="methodname">cloneNode</span><em>token</em> <em>deep</em>
-</div>
-<p>This method makes a copy the node given by  <em><em>token</em></em>.  If the argument  <em><em>deep</em></em> is not specified or has the value <span class="literal">0</span> then only the node itself is copied, not its children.  If the argument  <em><em>deep</em></em> has the value <span class="literal">1</span> then  <em><em>token</em></em>'s children are also copied recursively.  This method returns the token of the newly created node.  This new node will have no parent.</p>
-</dd>
-<span class="term"><span class="methodname">children</span></span><dd>
-<div class="cmdsynopsis" id="id22375">
-<a name="id22375"></a><span class="methodname">children</span><em>token</em>
-</div>
-<p>This is a convenience method which returns the list of child nodes for the given node as a (static) Tcl list.</p>
-<p>This is not a standard DOM method for this interface.</p>
-</dd>
-<span class="term"><span class="methodname">parent</span></span><dd>
-<div class="cmdsynopsis" id="id22415">
-<a name="id22415"></a><span class="methodname">parent</span><em>token</em>
-</div>
-<p>This is a convenience method which returns the parent node for the given node.</p>
-<p>This is not a standard DOM method for this interface.</p>
-</dd>
-<span class="term"><span class="methodname">path</span></span><dd>
-<div class="cmdsynopsis" id="id22453">
-<a name="id22453"></a><span class="methodname">path</span><em>token</em>
-</div>
-<p>Returns a Tcl list of the ancestor nodes of the given node, starting with the root node.</p>
-<p>This is not a standard DOM method for this interface.</p>
-</dd>
-<span class="term"><span class="methodname">createNode</span></span><dd>
-<div class="cmdsynopsis" id="id22491">
-<a name="id22491"></a><span class="methodname">createNode</span><em>token</em> <em>xpath</em>
-</div>
-<p>May create nodes in order to satisfy the given XPath location path.  The initial context for the location path is the node <span class="arg"><em>token</em></span>.  For more detail, see the <strong>::dom::createNode</strong> command.</p>
-<p>This is not a standard DOM method for this interface.</p>
-</dd>
-<span class="term"><span class="methodname">selectNode</span></span><dd>
-<div class="cmdsynopsis" id="id22548">
-<a name="id22548"></a><span class="methodname">selectNode</span><em>token</em> <em>xpath</em>
-</div>
-<p>Returns a (static) Tcl list of nodes selected by the XPath location path <span class="arg"><em>xpath</em></span>.  The initial context for the location path is the node  <span class="arg"><em>token</em></span>.  For more detail, see the <strong>::dom::selectNode</strong> command.</p>
-<p>This is not a standard DOM method for this interface.</p>
-</dd>
-<span class="term"><span class="methodname">stringValue</span></span><dd>
-<div class="cmdsynopsis" id="id22609">
-<a name="id22609"></a><span class="methodname">stringValue</span><em>token</em>
-</div>
-<p>Returns the string value of the node given by <span class="arg"><em>token</em></span>.  The string value of a node is defined by the XPath specification: for element nodes it is the concatenation of the string values of all descendant text nodes, for text nodes it is the node's character data value, for attribute nodes it is the attribute value, for comment nodes it is the comment data and for processing instruction nodes it is the PI data.</p>
-<p>This is not a standard DOM method for this interface.</p>
-</dd>
-<span class="term"><span class="methodname">addEventListener</span></span><dd>
-<div class="cmdsynopsis" id="id22658">
-<a name="id22658"></a><span class="methodname">addEventListener</span><em>token</em> <em>type</em> <em>listener</em> ?option value...?</div>
-<p>Register an event listener for the node given by <span class="arg"><em>token</em></span> listening for events of type  <span class="arg"><em>type</em></span>.  The event mechanism functions as described in the W3C DOM Level 2 Event module.</p>
-<p>When an event of type <span class="arg"><em>type</em></span> occurs the script  <span class="arg"><em>listener</em></span> is evaluated, in the global context.  The token of the event node is appended to the script.</p>
-<p>If the <span class="arg"><em>listener</em></span> argument is omitted then the listener for the given event type is returned.</p>
-<p>Valid options are:</p>
-<dl>
-<span class="term"><span class="arg">-usecapture</span> <span class="arg"><em>boolean</em></span></span><dd><p>If true the listener is triggered in the event capturing phase.  If false the listener is triggered in the event bubbling phase.</p></dd>
-</dl>
-</dd>
-<span class="term"><span class="methodname">removeEventListener</span></span><dd>
-<div class="cmdsynopsis" id="id22789">
-<a name="id22789"></a><span class="methodname">removeEventListener</span><em>token</em> <em>type</em> <em>listener</em> ?option value...?</div>
-<p>Removes an event listener previously registered for the node given by <span class="arg"><em>token</em></span> listening for events of type  <span class="arg"><em>type</em></span>.</p>
-<p>Valid options are:</p>
-<dl>
-<span class="term"><span class="arg">-usecapture</span> <span class="arg"><em>boolean</em></span></span><dd><p>If true the capturing listener is removed.  If false the bubbling listener is removed.</p></dd>
-</dl>
-</dd>
-<span class="term"><span class="methodname">dispatchEvent</span></span><dd>
-<div class="cmdsynopsis" id="id22893">
-<a name="id22893"></a><span class="methodname">dispatchEvent</span><em>token</em> <em>event</em>
-</div>
-<p>Dispatches the event given by <span class="arg"><em>event</em></span> with target node  <span class="arg"><em>token</em></span>.  The event mechanism functions as described in the W3C DOM Level 2 Event module.  The event enters the capturing phase first, followed by the bubbling phase.  During each phase any event listeners registered for the same event type as the event  <span class="arg"><em>event</em></span> are triggered; their script is evaluated.  Unless the script invokes the <tt>stopPropagation</tt> method of the <strong>dom::event</strong> command, all registered event listeners will be triggered.  The order in which listeners registered at a particular node for a particular phase are triggered is undefined.</p>
-</dd>
-</dl>
-</div>
-<div class="refsect2">
-<h3>
-<a name="id22955"></a><strong>dom::element</strong>
-</h3>
-<p>This command provides functions for element type nodes.</p>
-<p>Valid methods for this command are as follows:</p>
-<dl>
-<span class="term"><span class="methodname">cget</span></span><dd>
-<div class="cmdsynopsis" id="id22995">
-<a name="id22995"></a><span class="methodname">cget</span><em>token</em> <em>option</em>
-</div>
-<p>This method returns the current setting of configuration options for an element.  See the <span class="methodname">configure</span> method for the list of valid configuration options.</p>
-</dd>
-<span class="term"><span class="methodname">configure</span></span><dd>
-<div class="cmdsynopsis" id="id23041">
-<a name="id23041"></a><span class="methodname">configure</span><em>token</em> "<em>option</em> <em>value</em>..."</div>
-<p>This method sets configuration options for an element.  Note that element type nodes only have read-only options.</p>
-<p>Valid configuration options are as follows:</p>
-<dl>
-<span class="term"> <em>-tagName</em><span class="arg"><em>name</em></span></span><dd>The tag name, or element type, of this element.</dd>
-<span class="term"> <em>-empty</em><span class="arg"><em>boolean</em></span></span><dd>
-<p>Sets whether this element was specified as an empty element when the document was parsed.  That is, XML empty element syntax such as <span class="literal"><Empty/></span> was used.</p>
-<p>This option has no effect upon output (serialization) of the XML document.  Empty element syntax is automatically used where appropriate.</p>
-</dd>
-</dl>
-</dd>
-<span class="term"><span class="methodname">getAttribute</span></span><dd>
-<div class="cmdsynopsis" id="id23156">
-<a name="id23156"></a><span class="methodname">getAttribute</span><em>token</em> <em>name</em>
-</div>
-<p>This method returns the attribute value of the attribute given by  <em><em>name</em></em>.  If the attribute does not exist, then an empty string is returned.</p>
-</dd>
-<span class="term"><span class="methodname">setAttribute</span></span><dd>
-<div class="cmdsynopsis" id="id23203">
-<a name="id23203"></a><span class="methodname">setAttribute</span><em>token</em> <em>name</em> <em>value</em>
-</div>
-<p>This method sets the attribute value of the attribute given by  <em><em>name</em></em>.  If the attribute already exists then its value is replaced, otherwise the attribute is created.</p>
-</dd>
-<span class="term"><span class="methodname">removeAttribute</span></span><dd>
-<div class="cmdsynopsis" id="id23258">
-<a name="id23258"></a><span class="methodname">removeAttribute</span><em>token</em> <em>name</em>
-</div>
-<p>This method deletes the attribute given by  <em><em>name</em></em>.  If the attribute does not exist then the method has no effect.</p>
-</dd>
-<span class="term"><span class="methodname">getAttributeNode</span></span><dd>
-<div class="cmdsynopsis" id="id23306">
-<a name="id23306"></a><span class="methodname">getAttributeNode</span><em>token</em> <em>name</em>
-</div>
-<p>Not implemented.</p>
-</dd>
-<span class="term"><span class="methodname">setAttributeNode</span></span><dd>
-<div class="cmdsynopsis" id="id23348">
-<a name="id23348"></a><span class="methodname">setAttributeNode</span><em>token</em> <em>name</em>
-</div>
-<p>Not implemented.</p>
-</dd>
-<span class="term"><span class="methodname">removeAttributeNode</span></span><dd>
-<div class="cmdsynopsis" id="id23389">
-<a name="id23389"></a><span class="methodname">removeAttributeNode</span><em>token</em> <em>name</em>
-</div>
-<p>Not implemented.</p>
-</dd>
-<span class="term"><span class="methodname">getAttributeNS</span></span><dd>
-<div class="cmdsynopsis" id="id23430">
-<a name="id23430"></a><span class="methodname">getAttributeNS</span><em>token</em> <em>ns</em> <em>name</em>
-</div>
-<p>This method returns the attribute value of the attribute given by  <em><em>name</em></em> in the XML namespace <span class="arg"><em>ns</em></span>.  If the attribute does not exist, then an empty string is returned.</p>
-</dd>
-<span class="term"><span class="methodname">setAttributeNS</span></span><dd>
-<div class="cmdsynopsis" id="id23489">
-<a name="id23489"></a><span class="methodname">setAttributeNS</span><em>token</em> <em>ns</em> <em>name</em> <em>value</em>
-</div>
-<p>This method sets the attribute value of the attribute given by  <em><em>name</em></em> in the XML namespace <span class="arg"><em>ns</em></span>.  If the attribute already exists then its value is replaced, otherwise the attribute is created.</p>
-</dd>
-<span class="term"><span class="methodname">removeAttributeNS</span></span><dd>
-<div class="cmdsynopsis" id="id23557">
-<a name="id23557"></a><span class="methodname">removeAttributeNS</span><em>token</em> <em>ns</em> <em>name</em>
-</div>
-<p>This method deletes the attribute given by  <em><em>name</em></em> in the XML namespace <span class="arg"><em>ns</em></span>.  If the attribute does not exist then the method has no effect.</p>
-</dd>
-<span class="term"><span class="methodname">getElementsByTagName</span></span><dd>
-<div class="cmdsynopsis" id="id23616">
-<a name="id23616"></a><span class="methodname">getElementsByTagName</span><em>token</em> <em>name</em>
-</div>
-<p>This method searches the node given by the argument  <em><em>token</em></em> for descendant child elements with a type matching the argument  <em><em>name</em></em>.  The wildcard character <span class="literal">*</span> matches any element type.  The return result is a "live-list" which is represented by a Tcl variable.  This method returns the name of the Tcl variable that contains the list of tokens that match.</p>
-</dd>
-<span class="term"><span class="methodname">normalize</span></span><dd>
-<div class="cmdsynopsis" id="id23675">
-<a name="id23675"></a><span class="methodname">normalize</span><em>token</em>
-</div>
-<p>This method recursively coalesces textNodes within the children of the given node.  textNodes which are adjacent in the DOM tree cannot be distinguished in the serialized XML document.</p>
-</dd>
-</dl>
-</div>
-<div class="refsect2">
-<h3>
-<a name="id23702"></a><strong>dom::processinginstruction</strong>
-</h3>
-<p>This command provides functions for processingInstruction type nodes.</p>
-<p>Valid methods for this command are as follows:</p>
-<dl>
-<span class="term"><span class="methodname">cget</span></span><dd>
-<div class="cmdsynopsis" id="id23741">
-<a name="id23741"></a><span class="methodname">cget</span><em>token</em> <em>option</em>
-</div>
-<p>This method returns the current setting of configuration options for an element.  See the <span class="methodname">configure</span> method for the list of valid configuration options.</p>
-</dd>
-<span class="term"><span class="methodname">configure</span></span><dd>
-<div class="cmdsynopsis" id="id23787">
-<a name="id23787"></a><span class="methodname">configure</span><em>token</em> "<em>option</em> <em>value</em>..."</div>
-<p>This method sets configuration options for a processing instruction.</p>
-<p>Valid configuration options are as follows:</p>
-<dl>
-<span class="term"> <em>-target</em><span class="arg"><em>name</em></span></span><dd>This option sets the target of the processing instruction.  This is a read-only configuration option.</dd>
-<span class="term"> <em>-data</em><span class="arg"><em>data</em></span></span><dd><p>This option sets the data of the processing instruction.</p></dd>
-</dl>
-</dd>
-</dl>
-</div>
-<div class="refsect2">
-<h3>
-<a name="id23883"></a><strong>dom::event</strong>
-</h3>
-<p>This command provides functions for event type nodes.</p>
-<p>Valid methods for this command are as follows:</p>
-<dl>
-<span class="term"><span class="methodname">cget</span></span><dd>
-<div class="cmdsynopsis" id="id23922">
-<a name="id23922"></a><span class="methodname">cget</span><em>token</em>
-</div>
-<p>This method retrieves configuration options for an event.</p>
-<p>Valid configuration options are as follows:</p>
-<dl>
-<span class="term"> <em>-altKey</em></span><dd>This option determines whether the ALT modifier key has been specified for this event.</dd>
-<span class="term"> <em>-attrName</em></span><dd>This option gives the name of the attribute associated with this event.</dd>
-<span class="term"> <em>-bubbles</em></span><dd>This option determines whether the event uses the bubbling phase.</dd>
-<span class="term"> <em>-button</em></span><dd>This option gives the button pressed for this event.</dd>
-<span class="term"> <em>-cancelable</em></span><dd>This option determines whether the event may be cancelled.</dd>
-<span class="term"> <em>-clientX</em></span><dd>This option gives the window X coordinate for this event.</dd>
-<span class="term"> <em>-clientY</em></span><dd>This option gives the window Y coordinate for this event.</dd>
-<span class="term"> <em>-ctrlKey</em></span><dd>This option determines whether the control modifier key has been specified for this event.</dd>
-<span class="term"> <em>-currentNode</em></span><dd>The current node of the capturing or bubbling phase.</dd>
-<span class="term"> <em>-detail</em></span><dd>This option gives an additional information item for the event, for example the key that was pressed or the button number.</dd>
-<span class="term"> <em>-eventPhase</em></span><dd>The current phase of the event.</dd>
-<span class="term"> <em>-metaKey</em></span><dd>This option determines whether the META modifier key has been specified for this event.</dd>
-<span class="term"> <em>-newValue</em></span><dd>This option gives the new value of a node.</dd>
-<span class="term"> <em>-prevValue</em></span><dd>This option gives the previous value of a node.</dd>
-<span class="term"> <em>-relatedNode</em></span><dd>This option gives a related node for this event.  See the W3C DOM Level 2 Event module specification for further details.</dd>
-<span class="term"> <em>-screenX</em></span><dd>This option gives the screen X coordinate for this event.</dd>
-<span class="term"> <em>-screenY</em></span><dd>This option gives the screen Y coordinate for this event.</dd>
-<span class="term"> <em>-shiftKey</em></span><dd>This option determines whether the shift modifier key has been specified for this event.</dd>
-<span class="term"> <em>-target</em></span><dd>The node that is the target of this event.</dd>
-<span class="term"> <em>-timeStamp</em></span><dd>
-<p>This option gives the time at which the event was posted.  The value is the number of milliseconds since the epoch, which is compatible with the Tcl <strong>clock</strong> command.  </p>
-<div class="note">The implementation of this method depends on the <span class="methodname">Tcl_GetTime</span> function.This function only became publically available in Tcl 8.4.  If a version of Tcl prior to 8.4 is being used, then this option will have the value <span class="literal">0</span>.</div>
-</dd>
-<span class="term"> <em>-type</em></span><dd>The type of this event.</dd>
-<span class="term"> <em>-view</em></span><dd>This option gives whether the view of the event.</dd>
-</dl>
-</dd>
-<span class="term"><span class="methodname">configure</span></span><dd>
-<div class="cmdsynopsis" id="id24296">
-<a name="id24296"></a><span class="methodname">configure</span><em>token</em> "<em>option</em> <em>value</em>..."</div>
-<p>This method sets the configuration options for an event.  However, all event options are read-only.  See the <span class="methodname">cget</span> method for the list of valid configuration options.</p>
-</dd>
-<span class="term"><span class="methodname">stopPropagation</span></span><dd>
-<div class="cmdsynopsis" id="id24354">
-<a name="id24354"></a><span class="methodname">stopPropagation</span><em>token</em>
-</div>
-<p>This method cancels further propagation of the event.</p>
-<div class="note">Invoking this method does not prevent event listeners at the current node from being triggered.</div>
-</dd>
-<span class="term"><span class="methodname">preventDefault</span></span><dd>
-<div class="cmdsynopsis" id="id24392">
-<a name="id24392"></a><span class="methodname">preventDefault</span><em>token</em>
-</div>
-<p>This method stops the default action for this event from occurring.</p>
-</dd>
-<span class="term"><span class="methodname">initEvent</span></span><dd>
-<div class="cmdsynopsis" id="id24426">
-<a name="id24426"></a><span class="methodname">initEvent</span><em>token</em> <em>type</em> <em>bubbles</em> <em>cancelable</em>
-</div>
-<p>Initialise the event.</p>
-<p><span class="arg"><em>type</em></span> gives the type of the event.  Any of the event types defined by the W3C DOM Level 2 Event module may be specified, or a user-defined event type may be used instead.</p>
-<p><span class="arg"><em>bubbles</em></span> indicates whether the event will enter the bubbling phase after the capturing phase.   <span class="arg"><em>cancelable</em></span> indicates whether the event may be cancelled.</p>
-</dd>
-<span class="term"><span class="methodname">initUIEvent</span></span><dd>
-<div class="cmdsynopsis" id="id24505">
-<a name="id24505"></a><span class="methodname">initUIEvent</span><em>token</em> <em>type</em> <em>bubbles</em> <em>cancelable</em> <em>view</em> <em>detail</em>
-</div>
-<p>Initialise a user interface event.  See <tt>initEvent</tt> for further information.</p>
-<p><span class="arg"><em>view</em></span> gives the view for the event (not supported by TclDOM).   <span class="arg"><em>detail</em></span> provides extra data for the event.</p>
-</dd>
-<span class="term"><span class="methodname">initMouseEvent</span></span><dd>
-<div class="cmdsynopsis" id="id24593">
-<a name="id24593"></a><span class="methodname">initMouseEvent</span><em>token</em> <em>type</em> <em>bubbles</em> <em>cancelable</em> <em>view</em> <em>detail</em> <em>screenX</em> <em>screenY</em> <em>clientX</em> <em>clientY</em> <em>ctrlKey</em> <em>altKey</em> <em>shiftKey</em> <em>metaKey</em> <em>button</em> <em>relatedNode</em>
-</div>
-<p>Initialise a mouse event.  See <tt>initUIEvent</tt> for further information.</p>
-<p><span class="arg"><em>screenX</em></span> and  <span class="arg"><em>screenY</em></span> give the coordinates at which the event occurred relative to the screen.   <span class="arg"><em>screenX</em></span> and  <span class="arg"><em>screenY</em></span> give the coordinates at which the event occurred relative to the window.</p>
-<p><span class="arg"><em>ctrlKey</em></span>,  <span class="arg"><em>altKey</em></span>,  <span class="arg"><em>shiftKey</em></span>,  <span class="arg"><em>metaKey</em></span> indicate whether the respective modifier key was pressed when the event occurred.</p>
-<p><span class="arg"><em>button</em></span> indicates which button, if any, was pressed when the event occurred.</p>
-<p><span class="arg"><em>relatedNode</em></span> specifies that a DOM node is associated with the event.</p>
-</dd>
-<span class="term"><span class="methodname">initMutationEvent</span></span><dd>
-<div class="cmdsynopsis" id="id24802">
-<a name="id24802"></a><span class="methodname">initMutationEvent</span><em>token</em> <em>type</em> <em>bubbles</em> <em>cancelable</em> <em>relatedNode</em> <em>prevValue</em> <em>newValue</em> <em>attrName</em>
-</div>
-<p>Initialise a tree mutation event event.  See <tt>initEvent</tt> for further information.</p>
-<p><span class="arg"><em>relatedNode</em></span> specifies a DOM node to associate with the event.   <span class="arg"><em>prevValue</em></span> gives the previous value of the node.   <span class="arg"><em>newValue</em></span> gives the new value of the node.   <span class="arg"><em>attrName</em></span> gives the name of the attribute where the event is modifying an attribute value.</p>
-</dd>
-<span class="term"><span class="methodname">postUIEvent</span></span><dd>
-<div class="cmdsynopsis" id="id24918">
-<a name="id24918"></a><span class="methodname">postUIEvent</span><em>token</em> <em>type</em> ?option <em>value</em>...?</div>
-<p>Non-standard convenience method that handles posting an user interface event with <span class="arg"><em>token</em></span> as the target node.  This method performs the following functions:</p>
-<ol>
-<li><p>Create an event node,</p></li>
-<li><p>Initialise the event node (using default values where required),</p></li>
-<li><p>Dispatch the event,</p></li>
-<li><p>Destroy the event node.</p></li>
-</ol>
-<p><span class="arg"><em>type</em></span> gives the event type.</p>
-<p>The following options are valid:</p>
-<dl>
-<span class="term"> <em>-bubbles</em></span><dd><p>Indicates whether the event bubbles.</p></dd>
-<span class="term"> <em>-cancelable</em></span><dd><p>Indicates whether the event can be cancelled.</p></dd>
-<span class="term"> <em>-view</em></span><dd><p>The view.</p></dd>
-<span class="term"> <em>-detail</em></span><dd><p>Extra data for the event.</p></dd>
-</dl>
-</dd>
-<span class="term"><span class="methodname">postMouseEvent</span></span><dd>
-<div class="cmdsynopsis" id="id25096">
-<a name="id25096"></a><span class="methodname">postMouseEvent</span><em>token</em> <em>type</em> ?option <em>value</em>...?</div>
-<p>Non-standard convenience method that handles posting a mouse event with <span class="arg"><em>token</em></span> as the target node.  This method performs the following functions:</p>
-<ol>
-<li><p>Create an event node,</p></li>
-<li><p>Initialise the event node (using default values where required),</p></li>
-<li><p>Dispatch the event,</p></li>
-<li><p>Destroy the event node.</p></li>
-</ol>
-<p><span class="arg"><em>type</em></span> gives the event type.</p>
-<p>The following options are valid:</p>
-<dl>
-<span class="term"> <em>-bubbles</em></span><dd><p>Indicates whether the event bubbles.</p></dd>
-<span class="term"> <em>-cancelable</em></span><dd><p>Indicates whether the event can be cancelled.</p></dd>
-<span class="term"> <em>-view</em></span><dd><p>The view.</p></dd>
-<span class="term"> <em>-detail</em></span><dd><p>Extra data for the event.</p></dd>
-<span class="term"> <em>-screenX</em></span><dd><p>Gives the screen X coordinate.</p></dd>
-<span class="term"> <em>-screenY</em></span><dd><p>Gives the screen Y coordinate.</p></dd>
-<span class="term"> <em>-clientX</em></span><dd><p>Gives the window X coordinate.</p></dd>
-<span class="term"> <em>-clientY</em></span><dd><p>Gives the window Y coordinate.</p></dd>
-<span class="term"> <em>-ctrlKey</em></span><dd><p>Indicates whether the control modifier key was pressed.</p></dd>
-<span class="term"> <em>-altKey</em></span><dd><p>Indicates whether the ALT modifier key was pressed.</p></dd>
-<span class="term"> <em>-shiftKey</em></span><dd><p>Indicates whether the shift modifier key was pressed.</p></dd>
-<span class="term"> <em>-metaKey</em></span><dd><p>Indicates whether the meta modifier key was pressed.</p></dd>
-<span class="term"> <em>-button</em></span><dd><p>Gives the button pressed.</p></dd>
-<span class="term"> <em>-relatedNode</em></span><dd><p>Gives a node to associate with the event.</p></dd>
-</dl>
-</dd>
-<span class="term"><span class="methodname">postMutationEvent</span></span><dd>
-<div class="cmdsynopsis" id="id25444">
-<a name="id25444"></a><span class="methodname">postMutationEvent</span><em>token</em> <em>type</em> ?option <em>value</em>...?</div>
-<p>Non-standard convenience method that handles posting a mutation event with <span class="arg"><em>token</em></span> as the target node.  This method performs the following functions:</p>
-<ol>
-<li><p>Create an event node,</p></li>
-<li><p>Initialise the event node (using default values where required),</p></li>
-<li><p>Dispatch the event,</p></li>
-<li><p>Destroy the event node.</p></li>
-</ol>
-<p><span class="arg"><em>type</em></span> gives the event type.</p>
-<p>The following options are valid:</p>
-<dl>
-<span class="term"> <em>-bubbles</em></span><dd><p>Indicates whether the event bubbles.</p></dd>
-<span class="term"> <em>-cancelable</em></span><dd><p>Indicates whether the event can be cancelled.</p></dd>
-<span class="term"> <em>-relatedNode</em></span><dd><p>Gives a node to associate with the event.</p></dd>
-<span class="term"> <em>-prevValue</em></span><dd><p>Gives the previous value of the target node.</p></dd>
-<span class="term"> <em>-newValue</em></span><dd><p>Gives the new value of the target node.</p></dd>
-<span class="term"> <em>-attrName</em></span><dd><p>Gives the name of the attribute modified.</p></dd>
-</dl>
-</dd>
-</dl>
-</div>
-</div>
-<div class="refsect1">
-<h2>
-<a name="id25649"></a>Errors</h2>
-<p>If an operation results in an error condition, an error message is returned as a structured Tcl list.  The list has members as follows:</p>
-<div class="informalexample"><pre><div class="programlisting"><pre>{domain level code node line message int1 int2 string1 string2 string3}</pre></div></pre></div>
-<p>The format of the list is described in the TclXML manual page.</p>
-</div>
-<div class="refsect1">
-<h2>
-<a name="id25681"></a>Implementations</h2>
-<p>This section documents the various implmentations of the TclDOM API.</p>
-<div class="refsect2">
-<h3>
-<a name="id25698"></a>Tcl Implementation</h3>
-<p>The Tcl implementation is provided by the <tt>dom::tcl</tt> package.</p>
-<div class="refsect3">
-<h4>
-<a name="id25719"></a>Limitations</h4>
-<p>This implementation is not able to preform the following functions:</p>
-<ul>
-<li><p>Validation: DTD, XML Schema or RelaxNG validation are not supported.</p></li>
-<li><p>Character encodings: The TclDOM/tcl implementation itself does not handle character encodings other than utf-8.  Character encodings are handled by Tcl itself.</p></li>
-</ul>
-</div>
-</div>
-<div class="refsect2">
-<h3>
-<a name="id25760"></a>libxml2 Implementation</h3>
-<p>The TclDOM/libxml2 implementation is a wrapper for the <a href="http://xmlsoft.org/">Gnome libxml2 library</a>.  It is provided by the <tt>dom::libxml2</tt> package.  It is a high-performance library, making use of Tcl objects for fast access to tree nodes.</p>
-<div class="refsect3">
-<h4>
-<a name="id25793"></a>Limitations</h4>
-<ul>
-<li><p>The TclXML/libxml2 parser must be used to parse an XML document.  It is not possible to use any other parser class.</p></li>
-<li><p>RELAX-NG validation is not yet supported.</p></li>
-<li><p>The importNode method has not been implemented.</p></li>
-</ul>
-</div>
-</div>
-</div>
-</div></body>
-</html>
-
diff --git a/tclxml-3.2/doc/tcldom.xml.in b/tclxml-3.2/doc/tcldom.xml.in
deleted file mode 100644
index 1f699a2..0000000
--- a/tclxml-3.2/doc/tcldom.xml.in
+++ /dev/null
@@ -1,2519 +0,0 @@
-<!DOCTYPE refentry [
-  <!ENTITY version "@PACKAGE_VERSION@">
-]>
-<refentry xmlns="http://docbook.org/ns/docbook"
-	  xmlns:tcl='http://tclxml.sourceforge.net/doc'>
-  <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
-    <author xmlns:xlink="http://www.w3.org/XLink" xlink:href="http://www.explain.com.au/staff/Steve.Ball/">
-      <firstname>Steve</firstname>
-      <surname>Ball</surname>
-    </author>
-    <copyright>
-      <year>2008</year>
-      <year>2007</year>
-      <holder xmlns:xlink="http://www.w3.org/XLink" xlink:href="http://www.explain.com.au/">Explain</holder>
-    </copyright>
-    <copyright>
-      <year>2004</year>
-      <year>2003</year>
-      <year>2002</year>
-      <holder xmlns:xlink="http://www.w3.org/XLink" xlink:href="http://www.zveno.com/">Zveno Pty Ltd</holder>
-    </copyright>
-    <legalnotice>
-      <para>See the file "LICENSE" for information on usage and redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.</para>
-    </legalnotice>
-  </d:info>
-  <refmeta>
-    <refentrytitle>TclDOM</refentrytitle>
-    <manvolnum>n</manvolnum>
-  </refmeta>
-  <refnamediv>
-    <refname>::dom::DOMImplementation</refname>
-    <refname>::dom::hasfeature</refname>
-    <refname>::dom::create</refname>
-    <refname>::dom::destroy</refname>
-    <refname>::dom::parse</refname>
-    <refname>::dom::serialize</refname>
-    <refname>::dom::document</refname>
-    <refname>::dom::documenttype</refname>
-    <refname>::dom::node</refname>
-    <refname>::dom::element</refname>
-    <refname>::dom::event</refname>
-    <refname>::dom::selectNode</refname>
-    <refname>::dom::isNode</refname>
-    <refname>::dom::xinclude</refname>
-    <refname>::dom::prefix2namespaceURI</refname>
-    <refname>::dom::trim</refname>
-    <refpurpose>Tcl language binding for the W3C Document Object Model</refpurpose>
-  </refnamediv>
-  <refsynopsisdiv>
-    <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-      <command xmlns="http://docbook.org/ns/docbook">package require dom</command>
-    </cmdsynopsis>
-    <pkgsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-      <package xmlns="http://docbook.org/ns/docbook">dom</package>
-      <version xmlns="http://docbook.org/ns/docbook">&version;</version>
-    </pkgsynopsis>
-    <namespacesynopsis xmlns="http://tclxml.sourceforge.net/doc">
-      <namespace>::dom</namespace>
-      <namespace>::dom::tcl</namespace>
-      <namespace>::dom::libxml2</namespace>
-    </namespacesynopsis>
-    <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-      <command xmlns="http://docbook.org/ns/docbook">::dom::DOMImplementation</command>
-      <arg xmlns="http://docbook.org/ns/docbook">
-        <replaceable>method</replaceable>
-      </arg>
-      <group xmlns="http://docbook.org/ns/docbook" choice="opt" rep="repeat">
-        <arg>args</arg>
-      </group>
-    </cmdsynopsis>
-    <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-      <command xmlns="http://docbook.org/ns/docbook">::dom::hasfeature</command>
-      <arg xmlns="http://docbook.org/ns/docbook">
-        <replaceable>feature</replaceable>
-      </arg>
-      <arg xmlns="http://docbook.org/ns/docbook">
-        <replaceable>version</replaceable>
-      </arg>
-    </cmdsynopsis>
-    <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-      <command xmlns="http://docbook.org/ns/docbook">::dom::create</command>
-    </cmdsynopsis>
-    <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-      <command xmlns="http://docbook.org/ns/docbook">::dom::destroy</command>
-      <arg xmlns="http://docbook.org/ns/docbook">
-        <replaceable>token</replaceable>
-      </arg>
-    </cmdsynopsis>
-    <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-      <command xmlns="http://docbook.org/ns/docbook">::dom::parse</command>
-      <arg xmlns="http://docbook.org/ns/docbook">
-        <replaceable>xml</replaceable>
-      </arg>
-      <group xmlns="http://docbook.org/ns/docbook" choice="opt" rep="repeat">
-        <arg>option</arg>
-        <arg>value</arg>
-      </group>
-    </cmdsynopsis>
-    <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-      <command xmlns="http://docbook.org/ns/docbook">::dom::serialize</command>
-      <arg xmlns="http://docbook.org/ns/docbook">
-        <replaceable>token</replaceable>
-      </arg>
-      <group xmlns="http://docbook.org/ns/docbook" choice="opt" rep="repeat">
-        <arg>option</arg>
-        <arg>value</arg>
-      </group>
-    </cmdsynopsis>
-    <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-      <command xmlns="http://docbook.org/ns/docbook">::dom::document</command>
-      <arg xmlns="http://docbook.org/ns/docbook">
-        <replaceable>method</replaceable>
-      </arg>
-      <arg xmlns="http://docbook.org/ns/docbook">
-        <replaceable>token</replaceable>
-      </arg>
-      <group xmlns="http://docbook.org/ns/docbook" choice="opt" rep="repeat">
-        <arg>args</arg>
-      </group>
-    </cmdsynopsis>
-    <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-      <command xmlns="http://docbook.org/ns/docbook">::dom::documenttype</command>
-      <arg xmlns="http://docbook.org/ns/docbook">
-        <replaceable>method</replaceable>
-      </arg>
-      <arg xmlns="http://docbook.org/ns/docbook">
-        <replaceable>token</replaceable>
-      </arg>
-      <group xmlns="http://docbook.org/ns/docbook" choice="opt" rep="repeat">
-        <arg>args</arg>
-      </group>
-    </cmdsynopsis>
-    <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-      <command xmlns="http://docbook.org/ns/docbook">::dom::node</command>
-      <arg xmlns="http://docbook.org/ns/docbook">
-        <replaceable>method</replaceable>
-      </arg>
-      <arg xmlns="http://docbook.org/ns/docbook">
-        <replaceable>token</replaceable>
-      </arg>
-      <group xmlns="http://docbook.org/ns/docbook" choice="opt" rep="repeat">
-        <arg>args</arg>
-      </group>
-    </cmdsynopsis>
-    <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-      <command xmlns="http://docbook.org/ns/docbook">::dom::element</command>
-      <arg xmlns="http://docbook.org/ns/docbook">
-        <replaceable>method</replaceable>
-      </arg>
-      <arg xmlns="http://docbook.org/ns/docbook">
-        <replaceable>token</replaceable>
-      </arg>
-      <group xmlns="http://docbook.org/ns/docbook" choice="opt" rep="repeat">
-        <arg>args</arg>
-      </group>
-    </cmdsynopsis>
-    <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-      <command xmlns="http://docbook.org/ns/docbook">::dom::event</command>
-      <arg xmlns="http://docbook.org/ns/docbook">
-        <replaceable>method</replaceable>
-      </arg>
-      <arg xmlns="http://docbook.org/ns/docbook">
-        <replaceable>token</replaceable>
-      </arg>
-      <group xmlns="http://docbook.org/ns/docbook" choice="opt" rep="repeat">
-        <arg>args</arg>
-      </group>
-    </cmdsynopsis>
-    <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-      <command xmlns="http://docbook.org/ns/docbook">::dom::selectNode</command>
-      <arg xmlns="http://docbook.org/ns/docbook">
-        <replaceable>token</replaceable>
-      </arg>
-      <arg xmlns="http://docbook.org/ns/docbook">
-        <replaceable>xpath</replaceable>
-      </arg>
-      <group xmlns="http://docbook.org/ns/docbook" choice="opt" rep="repeat">
-        <arg>option value</arg>
-      </group>
-    </cmdsynopsis>
-    <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-      <command xmlns="http://docbook.org/ns/docbook">::dom::isNode</command>
-      <arg xmlns="http://docbook.org/ns/docbook">
-        <replaceable>token</replaceable>
-      </arg>
-    </cmdsynopsis>
-    <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-      <command xmlns="http://docbook.org/ns/docbook">::dom::xinclude</command>
-      <arg xmlns="http://docbook.org/ns/docbook">
-        <replaceable>doc</replaceable>
-      </arg>
-    </cmdsynopsis>
-    <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-      <command xmlns="http://docbook.org/ns/docbook">::dom::prefix2namespaceURI</command>
-      <arg xmlns="http://docbook.org/ns/docbook">
-        <replaceable>node</replaceable>
-      </arg>
-      <arg xmlns="http://docbook.org/ns/docbook">
-        <replaceable>prefix</replaceable>
-      </arg>
-    </cmdsynopsis>
-    <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-      <command xmlns="http://docbook.org/ns/docbook">::dom::trim</command>
-      <arg xmlns="http://docbook.org/ns/docbook">
-        <replaceable>doc</replaceable>
-      </arg>
-    </cmdsynopsis>
-  </refsynopsisdiv>
-  <refsect1>
-    <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
-      <d:title>Description</d:title>
-    </d:info>
-    <para>TclDOM is a Tcl language binding for the <d:link xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc" xlink:href="http://www.w3c.org/DOM/">W3C Document Object Model</d:link> (DOM).  DOM provides a view of a XML (or HTML) document as a tree structure.  Currently, TclDOM only supports XML documents.</para>
-    <para>The package implements most of the DOM Level 1 interfaces and also some Level 2 and Level 3 interfaces.  There are also a number of non-standard commands and methods provided for the convenience of application developers (these are documented).</para>
-    <para>The DOM specification should be read in conjunction with this reference manual, as it explains the meaning and purpose of the various interfaces.  This manual is not a tutorial on how to use the DOM.</para>
-    <para>TclDOM also provides two implementations of the API:  a pure-Tcl implementation and a C implementation based on the Gnome libxml2 library.</para>
-  </refsect1>
-  <refsect1>
-    <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
-      <d:title>Packages and Namespaces</d:title>
-    </d:info>
-    <para>TclDOM defines the <tcl:package>dom</tcl:package> package and also a Tcl namespace using that same name.</para>
-    <para>Implementations define their own package name and Tcl namespace within the <namespace xmlns="http://tclxml.sourceforge.net/doc">::dom</namespace> Tcl namespace:</para>
-    <variablelist>
-      <varlistentry>
-        <term>Tcl implementation</term>
-        <listitem>
-          <para>Package <tcl:package>dom::tcl</tcl:package>, Tcl namespace <namespace xmlns="http://tclxml.sourceforge.net/doc">::dom::tcl</namespace>.</para>
-        </listitem>
-      </varlistentry>
-      <varlistentry>
-        <term>libxml2</term>
-        <listitem>
-          <para>Package <tcl:package>dom::libxml2</tcl:package>, Tcl namespace <namespace xmlns="http://tclxml.sourceforge.net/doc">::dom::libxml2</namespace>.</para>
-        </listitem>
-      </varlistentry>
-    </variablelist>
-    <para>Each DOM Document is allocated a Tcl namespace within the <namespace xmlns="http://tclxml.sourceforge.net/doc">::dom</namespace> Tcl namespace.  All storage for the document and commands are defined within that Tcl namespace.</para>
-  </refsect1>
-  <refsect1>
-    <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
-      <d:title>Tokens</d:title>
-    </d:info>
-    <para>The TclDOM API uses <emphasis>tokens</emphasis> as identifiers for nodes within the document tree.  This technique has been used to allow alternate implementations of TclDOM to be efficient, while retaining compatibility with the pure-Tcl implementation.</para>
-    <para>The format of the token itself as well as the data structure referred to by the token are <emphasis>not</emphasis> public and an application should not rely on these.  Instead, an application should use the accessor methods provided by the API.</para>
-    <para>There is no requirement to always use the same token for a node.  In fact, an important performance optimisation for some implementations is to create a new token when a node is accessed, regardless of whether a token has already been issued for that node.  This implies that in order to test whether two tokens refer to the same node it is not sufficient to test the string values of the tokens; the <tcl:method>isSameNode</tcl:method> method must be used for this purpose.  For example,</para>
-    <informalexample>
-      <programlisting>
-proc NodeCompare1 {A B} {
-    return [string equal $A $B]
-}
-proc NodeCompare2 {A B} {
-    return [$A isSameNode $B]
-}
-</programlisting>
-    </informalexample>
-    <para>In the above example, <literal>NodeCompare2</literal> correctly determines whether its two arguments refer to the same node.</para>
-  </refsect1>
-  <refsect1>
-    <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
-      <d:title>Document and Node Commands</d:title>
-    </d:info>
-    <para>Each Document and Node has a Tcl command defined that may be used to control the object.  This command may be used to invoke the methods by the <command xmlns="http://tclxml.sourceforge.net/doc">::dom::document</command> command (for Documents) or the <command xmlns="http://tclxml.sourceforge.net/doc">::dom::node</command> command (for all other Nodes).  If a Document' or Node's Tcl command is destroyed then the Document or Node is also destroyed.</para>
-  </refsect1>
-  <refsect1>
-    <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
-      <d:title>DOM Interfaces</d:title>
-    </d:info>
-    <para>Each <emphasis>Interface</emphasis> in the DOM specification is implemented with a Tcl command in the <namespace xmlns="http://tclxml.sourceforge.net/doc">dom</namespace> namespace.  A few interfaces have not been mapped to Tcl commands because Tcl already provides the required functionality, for example the <classname>CharacterData</classname> interface.</para>
-    <para><emphasis>method</emphasis>s for interfaces are methods (subcommands) of the corresponding Tcl command.</para>
-    <para>Each <emphasis>attribute</emphasis> of an interface is a configuration option for an object in the document tree.</para>
-  </refsect1>
-  <refsect1>
-    <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
-      <d:title>Convenience Commands and Methods</d:title>
-    </d:info>
-    <para>DOM doesn't always provide an interface, method or attribute for every function required.  For example, until DOM Level 3 for was no standard for creating, parsing and serializing a document.  Sometimes using the standard DOM interface is awkward.  TclDOM provides a number of non-standard features to overcome these problems.</para>
-    <para>A major convenience is that each method of the <classname>DOMImplementation</classname> interface is also defined as a command.  For example, rather than using <command xmlns="http://tclxml.sourceforge.net/doc">dom::DOMImplementation create</command> to create a new document, the shorter command <command xmlns="http://tclxml.sourceforge.net/doc">dom::create</command> may be used.</para>
-    <para>Implementations may also provide direct access to specific features.  Refer to the documentation for a DOM implementation.</para>
-  </refsect1>
-  <refsect1>
-    <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
-      <d:title>Commands</d:title>
-    </d:info>
-    <refsect2>
-      <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
-        <d:title>
-          <command xmlns="http://tclxml.sourceforge.net/doc">::dom::DOMImplementation</command>
-        </d:title>
-      </d:info>
-      <para>The <command xmlns="http://tclxml.sourceforge.net/doc">::dom::DOMImplementation</command> command implements the <classname>DOMImplementation</classname> DOM interface.  It is used to provide implementation-specific features not explicitly defined in the DOM specification.</para>
-      <refsect3>
-        <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
-          <d:title>Command Options</d:title>
-        </d:info>
-        <para>The following command options may be used.  These are also available as commands.</para>
-        <variablelist>
-          <varlistentry>
-            <term>
-              <methodname>hasFeature</methodname>
-            </term>
-            <listitem>
-              <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <arg xmlns="http://docbook.org/ns/docbook">hasFeature</arg>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable class="parameter">feature</replaceable>
-                </arg>
-              </cmdsynopsis>
-              <para>Provides a test for existence of a feature.  Returns <literal>1</literal> if a feature is implemented, <literal>0</literal> otherwise.</para>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <methodname>create</methodname>
-            </term>
-            <listitem>
-              <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <arg xmlns="http://docbook.org/ns/docbook">create</arg>
-                <arg xmlns="http://docbook.org/ns/docbook" choice="opt">
-                  <replaceable class="parameter">type</replaceable>
-                </arg>
-              </cmdsynopsis>
-              <para>Creates the root node of a new DOM document.  The document element type may be specified as an argument, in which case that element is created.  The return value is a token referring to the root node of the newly created document.  A Tcl command is also created with the same name as the document's token.  This command is a shortcut for the <command xmlns="http://tclxml.sourceforge.net/doc">::dom::document</command> command.</para>
-              <note>
-                <para>Non-standard method.  DOM Level 2 introduced the <methodname>createDocument</methodname> method.</para>
-              </note>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <methodname>createDocument</methodname>
-            </term>
-            <listitem>
-              <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <arg xmlns="http://docbook.org/ns/docbook">createDocument</arg>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>nsURI</replaceable>
-                </arg>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>type</replaceable>
-                </arg>
-                <arg xmlns="http://docbook.org/ns/docbook" choice="opt">
-                  <replaceable>doctype</replaceable>
-                </arg>
-              </cmdsynopsis>
-              <para>Creates the root node of a new DOM document.  The document element namespace URI and local-name (element type) may be specified as an argument, in which case that element is created.  If the document type is given then the newly created document is configured to use that document type.  The return value is a token referring to the root node of the newly created document.  A Tcl command is also created with the same name as the document's token.  This command is a shortcut for the <command xmlns="http://tclxml.sourceforge.net/doc">::dom::document</command> command.</para>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <methodname>createDocumentType</methodname>
-            </term>
-            <listitem>
-              <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <arg xmlns="http://docbook.org/ns/docbook">createDocumentType</arg>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>name</replaceable>
-                </arg>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>publicid</replaceable>
-                </arg>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>systemid</replaceable>
-                </arg>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>internaldtd</replaceable>
-                </arg>
-              </cmdsynopsis>
-              <para>Creates a Document Type Declaration.  The return value is a token for the newly created document type declaration.  A Tcl command is also created with the same name as the document type's token.  This command is a shortcut for the <command xmlns="http://tclxml.sourceforge.net/doc">::dom::documenttype</command> command.</para>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <methodname>createNode</methodname>
-            </term>
-            <listitem>
-              <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <arg xmlns="http://docbook.org/ns/docbook">createNode</arg>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>token</replaceable>
-                </arg>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>xpath</replaceable>
-                </arg>
-              </cmdsynopsis>
-              <para>May create a node in the document.  <option><replaceable>token</replaceable></option> specifies a context for the XPath expression given by <option><replaceable>xpath</replaceable></option>.  The expression must resolve to a node.  If the node exists then no further action is taken.  Otherwise the node is created.  The token of the matched or newly created node is returned.</para>
-              <note>
-                <para>Non-standard method.</para>
-              </note>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <methodname>destroy</methodname>
-            </term>
-            <listitem>
-              <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <arg xmlns="http://docbook.org/ns/docbook">destroy</arg>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable class="parameter">token</replaceable>
-                </arg>
-              </cmdsynopsis>
-              <para>This method frees all data structures associated with a DOM document or node.  The <option><replaceable class="parameter">token</replaceable></option> argument must refer to a valid token for any document or any node in the tree of a document.</para>
-              <para>When the given token refers to a DOM document then the entire document is destroyed; the Tcl namespace for the document is deleted and all document and node commands are deleted.  All tokens for the document or nodes in the document become invalid.</para>
-              <para>When the token refers to a node the node is removed from the tree before it is destroyed.  If the node has children or attributes, they will also be destroyed.  The Tcl command for the node is deleted.</para>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <methodname>isNode</methodname>
-            </term>
-            <listitem>
-              <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <arg xmlns="http://docbook.org/ns/docbook">isNode</arg>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>token</replaceable>
-                </arg>
-              </cmdsynopsis>
-              <para>Tests whether the given token is a valid token for some DOM node.</para>
-              <note>
-                <para>Non-standard method.</para>
-              </note>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <methodname>parse</methodname>
-            </term>
-            <listitem>
-              <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <arg xmlns="http://docbook.org/ns/docbook">parse</arg>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable class="parameter">xml</replaceable>
-                </arg>
-                <group xmlns="http://docbook.org/ns/docbook">
-                  <arg>
-                    <replaceable>option</replaceable>
-                  </arg>
-                  <arg>
-                    <replaceable>value</replaceable>
-                  </arg>
-                </group>
-              </cmdsynopsis>
-              <para>This method parses XML formatted text given by the <option><replaceable class="parameter">xml</replaceable></option> argument and constructs a DOM tree for the document.  The return result is the token of the root node of the newly created document.  The document will also have a Tcl command associated with it, see the <tcl:method>createDocument</tcl:method> method.</para>
-              <para>This method uses the <d:link xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc" xlink:href="http://tclxml.sourceforge.net/">TclXML</d:link> package to perform the parsing operation.  The <tcl:package>dom</tcl:package> package itself does not include an XML parser.  TclXML supports the use of multiple parser implementations.  The <option>-parser</option> may be used to specify which XML parser class to use.</para>
-              <para>All options not listed below are passed to the TclXML parser.</para>
-              <para>Valid configuration options are:</para>
-              <variablelist>
-                <varlistentry>
-                  <term>
-                    <arg>-parser</arg>
-                    <arg>
-                      <group>
-                        <arg>{}</arg>
-                        <arg>libxml2</arg>
-                        <arg>tcl</arg>
-                      </group>
-                    </arg>
-                  </term>
-                  <listitem>
-                    <para>This option specifies the name of a TclXML parser class to use to parse the XML data.  The given parser class must be registered with the TclXML package.  If an empty string is given then the default parser class is used.  If an explicit value is given and that parser class is not registered then the command will fail, despite the fact that another parser may be available.</para>
-                  </listitem>
-                </varlistentry>
-                <varlistentry>
-                  <term>
-                    <arg>-progresscommand</arg>
-                    <arg>
-                      <replaceable>script</replaceable>
-                    </arg>
-                  </term>
-                  <listitem>
-                    <para>This option specifies a Tcl command to be invoked from time to time while the DOM tree is being constructed.  The script will be invoked after a certain number of element start tags have been processed, given by the <option>-chunksize</option> option.</para>
-                  </listitem>
-                </varlistentry>
-                <varlistentry>
-                  <term>
-                    <arg>-chunksize</arg>
-                    <arg>
-                      <replaceable>integer</replaceable>
-                    </arg>
-                  </term>
-                  <listitem>
-                    <para>This option specifies how many element start tags to process before invoking the script given by the <option>-progresscommand</option> option.</para>
-                  </listitem>
-                </varlistentry>
-              </variablelist>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <methodname>selectNode</methodname>
-            </term>
-            <listitem>
-              <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <arg xmlns="http://docbook.org/ns/docbook">selectNode</arg>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>token</replaceable>
-                </arg>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>xpath</replaceable>
-                </arg>
-                <group xmlns="http://docbook.org/ns/docbook" choice="opt" rep="repeat">
-                  <arg>option value</arg>
-                </group>
-              </cmdsynopsis>
-              <para>Resolves the XPath location path given by <option><replaceable>xpath</replaceable></option>.  <option><replaceable>token</replaceable></option> is the initial context for the location path.  Returns the resulting nodeset as a (static) Tcl list.</para>
-              <para>The following options may be specified:</para>
-              <variablelist>
-                <varlistentry>
-                  <term>
-                    <option>-namespaces</option>
-                  </term>
-                  <listitem>
-                    <para>The value for this option is a list of prefix-URI pairs.  Each of these pairs defines an XML Namespace and its prefix for the purposes of evaluating the XPath expression.  The document itself may use a different prefix for the same XML Namespace.</para>
-                    <para>This option may be repeated, in which case the lists of namespace pairs are merged and all of the XML Namespaces registered.</para>
-                  </listitem>
-                </varlistentry>
-              </variablelist>
-              <note>
-                <para>Non-standard method.</para>
-              </note>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <methodname>serialize</methodname>
-            </term>
-            <listitem>
-              <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <arg xmlns="http://docbook.org/ns/docbook">serialize</arg>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>token</replaceable>
-                </arg>
-                <group xmlns="http://docbook.org/ns/docbook">
-                  <arg>
-                    <replaceable>option</replaceable>
-                  </arg>
-                  <arg>
-                    <replaceable>value</replaceable>
-                  </arg>
-                </group>
-              </cmdsynopsis>
-              <para>This method returns the XML formatted text corresponding to the node given by <option>token</option>.  The text is guaranteed to be a well-formed XML document, unless the <option>-method</option> option specifies a non-XML output method.</para>
-              <para>Valid configuration options are:</para>
-              <variablelist>
-                <varlistentry>
-                  <term>
-                    <arg>-method</arg>
-                    <arg>xml|html|text</arg>
-                  </term>
-                  <listitem>
-                    <para>Specifies how the document tree is to be serialized as text.  The allowed values correspond to the output methods defined by the XSLT v1.0 W3C Recommendation.  The <literal>xml</literal> method produces output that conforms to the XML syntax.  The <literal>html</literal> method produces output that conforms to HTML syntax.  The <literal>text</literal> method serializes only the text nodes of the document and disables all output escaping.</para>
-                  </listitem>
-                </varlistentry>
-                <varlistentry>
-                  <term>
-                    <arg>-indent</arg>
-                    <arg>
-                      <replaceable>boolean</replaceable>
-                    </arg>
-                  </term>
-                  <listitem>
-                    <para>Specifies that the output is to be "pretty-printed", ie. element content is indented to provide a visual indication of nesting levels.</para>
-                  </listitem>
-                </varlistentry>
-                <varlistentry>
-                  <term>
-                    <arg>-encoding</arg>
-                    <arg>
-                      <replaceable>encoding</replaceable>
-                    </arg>
-                  </term>
-                  <listitem>
-                    <para>Specifies that the output is to be encoded using the given character encoding.  If the encoding is <literal>utf-8</literal> (the default) then the output is treated as a string within Tcl.  If any other encoding is specified then the output is treated as a ByteArray object (ie. as binary).</para>
-                  </listitem>
-                </varlistentry>
-                <varlistentry>
-                  <term>
-                    <arg>-newline</arg>
-                    <arg>
-                      <replaceable>elementlist</replaceable>
-                    </arg>
-                  </term>
-                  <listitem>
-                    <para>This option specifies a list of element types for which newline characters will be added before and after the start and end tags for those elements upon serialization.  This option is deprecated: the <arg>-indent</arg> option should be used instead.</para>
-                    <para>White space is significant in XML, so the <tcl:package>dom</tcl:package> package never adds extra white space for purposes of "pretty-printing" the XML source document.  On some platforms, such as VMS, this can actually cause serious problems due to line length limitations.  This option provides the convenience of adding newlines to certain nominated element types for formatting the source into lines.</para>
-                    <para>Examples:</para>
-                    <para>Suppose the following DOM document is constructed:</para>
-                    <informalexample>
-                      <programlisting>
-set doc [::dom::DOMImplementation create]
-set top [::dom::document createElement $doc Root]
-set node [::dom::document createElement $top First]
-::dom::document createElement $node Second
-::dom::document createElement $top First
-</programlisting>
-                    </informalexample>
-                    <para>Without the <option>-newline</option> option the serialized document would be:</para>
-                    <informalexample>
-                      <programlisting>
-::dom::DOMImplementation serialize $doc
-<computeroutput>
-<?xml version="1.0"?>
-<!DOCTYPE Root>
-<Root><First><Second/></First><First/></Root>
-
-</computeroutput>
-</programlisting>
-                    </informalexample>
-                    <para>With the <option>-newline</option> option the serialized document would be:</para>
-                    <informalexample>
-                      <programlisting>
-::dom::DOMImplementation serialize $doc -newline First
-<computeroutput>
-<?xml version="1.0"?>
-<!DOCTYPE Root>
-<Root>
-<First>
-<Second/>
-</First>
-<First/>
-</Root>
-
-</computeroutput>
-</programlisting>
-                    </informalexample>
-                  </listitem>
-                </varlistentry>
-              </variablelist>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <methodname>trim</methodname>
-            </term>
-            <listitem>
-              <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <arg xmlns="http://docbook.org/ns/docbook">trim</arg>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>token</replaceable>
-                </arg>
-              </cmdsynopsis>
-              <para>This method removes any node containing only white space from the document tree of the node given by <option><replaceable>token</replaceable></option>.</para>
-            </listitem>
-          </varlistentry>
-        </variablelist>
-      </refsect3>
-    </refsect2>
-    <refsect2>
-      <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
-        <d:title>
-          <command xmlns="http://tclxml.sourceforge.net/doc">::dom::document</command>
-        </d:title>
-      </d:info>
-      <para>This command implements the Document interface in the DOM specification.  The most important aspect of this command are its factory methods for creating nodes.</para>
-      <para>The methods accepted by this command are as follows:</para>
-      <variablelist>
-        <varlistentry>
-          <term>
-            <methodname>cget</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">cget</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">-option</arg>
-            </cmdsynopsis>
-            <para>This method returns the value of the given configuration option.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>configure</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">configure</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <group xmlns="http://docbook.org/ns/docbook" rep="repeat">
-                <arg>
-                  <replaceable>option</replaceable>
-                </arg>
-                <arg>
-                  <replaceable>value</replaceable>
-                </arg>
-              </group>
-            </cmdsynopsis>
-            <para>This method sets the value of the given configuration options.</para>
-            <para>Valid configuration options are:</para>
-            <variablelist>
-              <varlistentry>
-                <term>
-                  <arg>-doctype</arg>
-                </term>
-                <listitem>
-                  <para>Specifies the token of the Document Type Declaration node.</para>
-                  <para>This is a read-only option.  Use the factory method to create a Document Type Declaration node.</para>
-                </listitem>
-              </varlistentry>
-              <varlistentry>
-                <term>
-                  <arg>-implementation</arg>
-                </term>
-                <listitem>
-                  <para>Specifies the token of the document's implementation.</para>
-                  <para>This is a read-only option.</para>
-                </listitem>
-              </varlistentry>
-              <varlistentry>
-                <term>
-                  <arg>-documentElement</arg>
-                </term>
-                <listitem>
-                  <para>Specifies the token of the document's document element node.  A document node may only have one document element, but may have other types of children (such as comments).</para>
-                  <para>This is a read-only option.  Use the factory method to create the document element node.</para>
-                </listitem>
-              </varlistentry>
-            </variablelist>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>createElement</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">createElement</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>type</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>This method creates an element node as a child of the given node specified by <option><replaceable>token</replaceable></option> and returns the new node's token as its result.  <option><replaceable>token</replaceable></option> must be a node of type element, document or documentFragment.  The new, child element is added as the last child of <option><replaceable>token</replaceable></option>'s list of children.  The new element's type is given by the <option><replaceable>type</replaceable></option> argument.  The new element is created with an empty attribute list.</para>
-            <para>A Tcl command is created with the same name as the new node's token.  This command is a shortcut for the <command xmlns="http://tclxml.sourceforge.net/doc">::dom::node</command> command.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>createElementNS</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">createElementNS</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>nsuri</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>qualname</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>This method creates an element node in an XML Namespace as a child of the given node specified by <option><replaceable>token</replaceable></option> and returns the new node's token as its result.  <option><replaceable>token</replaceable></option> must be a node of type element, document or documentFragment.  The new, child element is added as the last child of <option><replaceable>token</replaceable></option>'s list of children.  The new element is created in the XML Namespace given by the namespace URI <option><replaceable>nsuri</replaceable></option>.  The new element's qualifed name (QName) is given by the <option><replaceable>qualname</replaceable></option> argument.  Qualified names have the form <literal>prefix:local-part</literal>.  The new element is created with an empty attribute list.</para>
-            <para>A Tcl command is created with the same name as the new node's token.  This command is a shortcut for the <command xmlns="http://tclxml.sourceforge.net/doc">::dom::node</command> command.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>createDocumentFragment</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">createDocumentFragment</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>This method creates a documentFragment node as a child of the given node specified by <option><replaceable>token</replaceable></option> and returns the new node's token as its result.  <option><replaceable>token</replaceable></option> must be a node of type element, document or documentFragment.</para>
-            <para>A Tcl command is created with the same name as the new node's token.  This command is a shortcut for the <command xmlns="http://tclxml.sourceforge.net/doc">::dom::node</command> command.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>createTextNode</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">createTextNode</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>text</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>This method creates a textNode node as a child of the given node specified by <option><replaceable>token</replaceable></option> and returns the new node's token as its result.  <option><replaceable>token</replaceable></option> must be a node of type element, document or documentFragment.  The new, child textNode is added as the last child of <option><replaceable>token</replaceable></option>'s list of children.  The new textNode is created with its value set to <option><replaceable>text</replaceable></option>.</para>
-            <para>A Tcl command is created with the same name as the new node's token.  This command is a shortcut for the <command xmlns="http://tclxml.sourceforge.net/doc">::dom::node</command> command.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>createComment</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">createComment</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>data</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>This method creates a comment node as a child of the given node specified by <option><replaceable>token</replaceable></option> and returns the new node's token as its result.  <option><replaceable>token</replaceable></option> must be a node of type element, document or documentFragment.  The new, child comment is added as the last child of <option><replaceable>token</replaceable></option>'s list of children.  The new comment is created with its value set to <option><replaceable>data</replaceable></option>.</para>
-            <para>A Tcl command is created with the same name as the new node's token.  This command is a shortcut for the <command xmlns="http://tclxml.sourceforge.net/doc">::dom::node</command> command.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>createCDATASection</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">createCDATASection</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>text</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>TclDOM does not distinguish between textNodes and CDATASection nodes.  Accordingly, this method creates a textNode node as a child of the given node specified by <option><replaceable>token</replaceable></option> and returns the new node's token as its result.  <option><replaceable>token</replaceable></option> must be a node of type element, document or documentFragment.  The new, child textNode is added as the last child of <option><replaceable>token</replaceable></option>'s list of children.  The new node is created with its value set to <option><replaceable>text</replaceable></option> and has the attribute <option>-cdatasection</option> set to the value <literal>1</literal>.</para>
-            <para>A Tcl command is created with the same name as the new node's token.  This command is a shortcut for the <command xmlns="http://tclxml.sourceforge.net/doc">::dom::node</command> command.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>createProcessingInstruction</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">createProcessingInstruction</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>target</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>data</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>This method creates a processingInstruction node as a child of the given node specified by <option><replaceable>token</replaceable></option> and returns the new node's token as its result.  <option><replaceable>token</replaceable></option> must be a node of type element, document or documentFragment.  The new, child processingInstruction is added as the last child of <option><replaceable>token</replaceable></option>'s list of children.  The new node is created with its name set to <option><replaceable>target</replaceable></option> and its value set to <option><replaceable>data</replaceable></option>.</para>
-            <para>A Tcl command is created with the same name as the new node's token.  This command is a shortcut for the <command xmlns="http://tclxml.sourceforge.net/doc">::dom::node</command> command.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>createAttribute</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">createAttribute</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>name</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>This method creates an attribute node for the given element specified by <option><replaceable>token</replaceable></option> and returns the new node's token as its result.  <option><replaceable>token</replaceable></option> must be a node of type element.  The new attribute is created with its name set to <option><replaceable>name</replaceable></option> and an empty value.</para>
-            <para>A Tcl command is created with the same name as the new node's token.  This command is a shortcut for the <command xmlns="http://tclxml.sourceforge.net/doc">::dom::node</command> command.</para>
-            <note>
-              <para>This method is included for completeness with respect to the DOM specification.  The preferred method for setting element attributes is to use the <command xmlns="http://tclxml.sourceforge.net/doc">::dom::element</command> command.</para>
-            </note>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>createEntity</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">createEntity</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>Not currently implemented.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>createEntityReference</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">createEntityReference</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>name</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>Not currently implemented.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>createEvent</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">createEvent</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>name</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>This method creates an event node in the document specified by <option><replaceable>token</replaceable></option> and returns the new node's token as its result.  <option><replaceable>token</replaceable></option> must be a node of type document.  The event type is specified by <option><replaceable>name</replaceable></option>.</para>
-            <para>A Tcl command is created with the same name as the new node's token.  This command is a shortcut for the <command xmlns="http://tclxml.sourceforge.net/doc">::dom::event</command> command.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>getElementsByTagName</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">getElementsByTagName</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>name</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>This method searches the node given by the argument <option><replaceable>token</replaceable></option> for child elements with a type matching the argument <option><replaceable>name</replaceable></option>.  The name <literal>*</literal> matches all elements.  All descendants of <option><replaceable>token</replaceable></option> are searched.  This method returns a "live-list"; the return result of this method is the name of a Tcl variable, the content of which is a Tcl list containing tokens for all elements that match.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>dtd</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">dtd</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">validate</arg>
-            </cmdsynopsis>
-            <para>This method performs DTD validation upon the document.  If the method returns successfully, then the document is valid.  Otherwise the document is invalid and the error returned contains the reason.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>schema</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">
-                <replaceable>submethod</replaceable>
-              </methodname>
-              <group xmlns="http://docbook.org/ns/docbook" choice="opt" rep="repeat">
-                <arg>
-                  <replaceable>args</replaceable>
-                </arg>
-              </group>
-            </cmdsynopsis>
-            <para>This method performs XML Schema validation upon the document.  Schema validation is performed in two steps.  First the document is compiled into a schema document.  Second, the schema document is used to schema-validate an instance document.</para>
-            <para>Example:</para>
-            <informalexample>
-              <programlisting>
-set schema [dom::parse $XML]
-$schema schema compile
-set instance [dom::parse $XML2]
-$schema schema validate $instance
-</programlisting>
-            </informalexample>
-            <para>If the document is changed after compiling, then schema document must be recompiled.</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refsect2>
-    <refsect2>
-      <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
-        <d:title>
-          <command xmlns="http://tclxml.sourceforge.net/doc">dom::node</command>
-        </d:title>
-      </d:info>
-      <para>This command implements generic functions for DOM nodes.</para>
-      <para>The methods accepted by this command are as follows:</para>
-      <variablelist>
-        <varlistentry>
-          <term>
-            <methodname>cget</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">cget</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">option</arg>
-            </cmdsynopsis>
-            <para>This method returns the value of the given configuration option for the node given by <option><replaceable>token</replaceable></option>.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>configure</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">configure</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <group xmlns="http://docbook.org/ns/docbook" rep="repeat">
-                <arg>
-                  <replaceable>option</replaceable>
-                </arg>
-                <arg>
-                  <replaceable>value</replaceable>
-                </arg>
-              </group>
-            </cmdsynopsis>
-            <para>This method sets the value of the given configuration option for the node given by <option><replaceable>token</replaceable></option>.</para>
-            <para>Valid configuration options are as follows:</para>
-            <variablelist>
-              <varlistentry>
-                <term>
-                  <arg>-nodeName</arg>
-                </term>
-                <listitem>
-                  <para>Returns the node name.  This is a read-only option.</para>
-                  <para>The DOM specification gives the meaning of names for different types of nodes.  For example, the <option>-nodeName</option> option of an element node is the element type.</para>
-                </listitem>
-              </varlistentry>
-              <varlistentry>
-                <term>
-                  <arg>-nodeType</arg>
-                </term>
-                <listitem>
-                  <para>Returns the type of the node given by <option><replaceable>token</replaceable></option>.  This is a read-only option.</para>
-                </listitem>
-              </varlistentry>
-              <varlistentry>
-                <term>
-                  <option>-parentNode</option>
-                </term>
-                <listitem>
-                  <para>Returns the parent node of the node given by <option><replaceable>token</replaceable></option>.  This is a read-only option.</para>
-                </listitem>
-              </varlistentry>
-              <varlistentry>
-                <term>
-                  <option>-childNodes</option>
-                </term>
-                <listitem>
-                  <para>Returns the name of a Tcl variable which contains a list of the children of the node given by <option><replaceable>token</replaceable></option>.  The variable contains the "live" list of children.  This is a read-only option.</para>
-                </listitem>
-              </varlistentry>
-              <varlistentry>
-                <term>
-                  <option>-firstChild</option>
-                </term>
-                <listitem>
-                  <para>Returns the first child node of the node given by <option><replaceable>token</replaceable></option>.  This is a read-only option.</para>
-                </listitem>
-              </varlistentry>
-              <varlistentry>
-                <term>
-                  <option>-lastChild</option>
-                </term>
-                <listitem>
-                  <para>Returns the last child node of the node given by <option><replaceable>token</replaceable></option>.  This is a read-only option.</para>
-                </listitem>
-              </varlistentry>
-              <varlistentry>
-                <term>
-                  <option>-previousSibling</option>
-                </term>
-                <listitem>
-                  <para>Returns the parent's child node which appears before this node.  If this child is the first child of its parent then returns an empty string.  This is a read-only option.</para>
-                </listitem>
-              </varlistentry>
-              <varlistentry>
-                <term>
-                  <option>-nextSibling</option>
-                </term>
-                <listitem>
-                  <para>Returns the parent's child node which appears after this node.  If this child is the last child of its parent then returns an empty string.  This is a read-only option.</para>
-                </listitem>
-              </varlistentry>
-              <varlistentry>
-                <term>
-                  <option>-attributes</option>
-                </term>
-                <listitem>
-                  <para>Returns the name of a Tcl array variable which contains the attribute list for an element node.  If the node is not an element type node then returns an empty string.  The indices of the array are attribute names, and the values of the array elements are their corresponding attribute values.  This is a read-only option.</para>
-                </listitem>
-              </varlistentry>
-              <varlistentry>
-                <term>
-                  <option>-nodeValue</option>
-                  <arg>
-                    <replaceable>data</replaceable>
-                  </arg>
-                </term>
-                <listitem>
-                  <para>Specifies the value of a node.  The DOM specification gives the meaning of values for different types of nodes.  For example, the <option>-nodeValue</option> option of a textNode node is the node's text.</para>
-                </listitem>
-              </varlistentry>
-            </variablelist>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>insertBefore</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">insertBefore</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>newchild</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook" choice="opt">
-                <replaceable>refchild</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>This method removes the node given by <option><replaceable>newchild</replaceable></option> from its parent.  If no <option><replaceable>refchild</replaceable></option> argument is given then <option><replaceable>newchild</replaceable></option> is appended to <option><replaceable>token</replaceable></option>'s list of children.  If the <option><replaceable>refchild</replaceable></option> argument is given then this method adds <option><replaceable>newchild</replaceable></option> as a child of <option><replaceable>token</replaceable></option>.  The new child node is positioned before the node <option><replaceable>refchild</replaceable></option> in <option><replaceable>token</replaceable></option>'s list of children.  Returns an empty string.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>replaceChild</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">replaceChild</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>newchild</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>oldchild</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>This method removes the node given by <option><replaceable>newchild</replaceable></option> from its parent.  It then also removes the node given by <option><replaceable>oldchild</replaceable></option> from <option><replaceable>token</replaceable></option>.  <option><replaceable>newchild</replaceable></option> is then added as a child of <option><replaceable>token</replaceable></option> in <option><replaceable>oldchild</replaceable></option>'s original position in the list of children.  The method returns the token <option><replaceable>oldchild</replaceable></option>, which will now have no parent.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>removeChild</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">removeChild</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>oldchild</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>This method removes the node given by <option><replaceable>oldchild</replaceable></option> from its parent, <option><replaceable>token</replaceable></option>.  The method returns the token <option><replaceable>oldchild</replaceable></option>, which will now have no parent.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>appendChild</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">appendChild</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>newchild</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>This method removes the node given by <option><replaceable>newchild</replaceable></option> from its parent.  <option><replaceable>newchild</replaceable></option> is then appended to the end of the list of children for node <option><replaceable>token</replaceable></option>.  The method returns the token <option><replaceable>newchild</replaceable></option>.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>hasChildNodes</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">hasChildNodes</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>Returns <literal>1</literal> if the given node has any child nodes, <literal>0</literal> otherwise.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>isSameNode</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">isSameNode</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>ref</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>Returns <literal>1</literal> if the given node is the same node as the node given by the <arg><literal>ref</literal></arg> token, <literal>0</literal> otherwise.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>cloneNode</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">cloneNode</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook" choice="opt">
-                <replaceable>deep</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>This method makes a copy the node given by <option><replaceable>token</replaceable></option>.  If the argument <option><replaceable>deep</replaceable></option> is not specified or has the value <literal>0</literal> then only the node itself is copied, not its children.  If the argument <option><replaceable>deep</replaceable></option> has the value <literal>1</literal> then <option><replaceable>token</replaceable></option>'s children are also copied recursively.  This method returns the token of the newly created node.  This new node will have no parent.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>children</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">children</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>This is a convenience method which returns the list of child nodes for the given node as a (static) Tcl list.</para>
-            <para>This is not a standard DOM method for this interface.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>parent</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">parent</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>This is a convenience method which returns the parent node for the given node.</para>
-            <para>This is not a standard DOM method for this interface.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>path</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">path</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>Returns a Tcl list of the ancestor nodes of the given node, starting with the root node.</para>
-            <para>This is not a standard DOM method for this interface.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>createNode</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">createNode</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>xpath</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>May create nodes in order to satisfy the given XPath location path.  The initial context for the location path is the node <arg><replaceable>token</replaceable></arg>.  For more detail, see the <command xmlns="http://tclxml.sourceforge.net/doc">::dom::createNode</command> command.</para>
-            <para>This is not a standard DOM method for this interface.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>selectNode</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">selectNode</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>xpath</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>Returns a (static) Tcl list of nodes selected by the XPath location path <arg><replaceable>xpath</replaceable></arg>.  The initial context for the location path is the node <arg><replaceable>token</replaceable></arg>.  For more detail, see the <command xmlns="http://tclxml.sourceforge.net/doc">::dom::selectNode</command> command.</para>
-            <para>This is not a standard DOM method for this interface.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>stringValue</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">stringValue</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>Returns the string value of the node given by <arg><replaceable>token</replaceable></arg>.  The string value of a node is defined by the XPath specification: for element nodes it is the concatenation of the string values of all descendant text nodes, for text nodes it is the node's character data value, for attribute nodes it is the attribute value, for comment nodes it is the comment data and for processing instruction nodes it is the PI data.</para>
-            <para>This is not a standard DOM method for this interface.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>addEventListener</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">addEventListener</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>type</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook" choice="opt">
-                <replaceable>listener</replaceable>
-              </arg>
-              <group xmlns="http://docbook.org/ns/docbook" choice="opt" rep="repeat">
-                <arg>option</arg>
-                <arg>value</arg>
-              </group>
-            </cmdsynopsis>
-            <para>Register an event listener for the node given by <arg><replaceable>token</replaceable></arg> listening for events of type <arg><replaceable>type</replaceable></arg>.  The event mechanism functions as described in the W3C DOM Level 2 Event module.</para>
-            <para>When an event of type <arg><replaceable>type</replaceable></arg> occurs the script <arg><replaceable>listener</replaceable></arg> is evaluated, in the global context.  The token of the event node is appended to the script.</para>
-            <para>If the <arg><replaceable>listener</replaceable></arg> argument is omitted then the listener for the given event type is returned.</para>
-            <para>Valid options are:</para>
-            <variablelist>
-              <varlistentry>
-                <term>
-                  <arg>-usecapture</arg>
-                  <arg>
-                    <replaceable>boolean</replaceable>
-                  </arg>
-                </term>
-                <listitem>
-                  <para>If true the listener is triggered in the event capturing phase.  If false the listener is triggered in the event bubbling phase.</para>
-                </listitem>
-              </varlistentry>
-            </variablelist>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>removeEventListener</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">removeEventListener</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>type</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>listener</replaceable>
-              </arg>
-              <group xmlns="http://docbook.org/ns/docbook" choice="opt" rep="repeat">
-                <arg>option</arg>
-                <arg>value</arg>
-              </group>
-            </cmdsynopsis>
-            <para>Removes an event listener previously registered for the node given by <arg><replaceable>token</replaceable></arg> listening for events of type <arg><replaceable>type</replaceable></arg>.</para>
-            <para>Valid options are:</para>
-            <variablelist>
-              <varlistentry>
-                <term>
-                  <arg>-usecapture</arg>
-                  <arg>
-                    <replaceable>boolean</replaceable>
-                  </arg>
-                </term>
-                <listitem>
-                  <para>If true the capturing listener is removed.  If false the bubbling listener is removed.</para>
-                </listitem>
-              </varlistentry>
-            </variablelist>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>dispatchEvent</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">dispatchEvent</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>event</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>Dispatches the event given by <arg><replaceable>event</replaceable></arg> with target node <arg><replaceable>token</replaceable></arg>.  The event mechanism functions as described in the W3C DOM Level 2 Event module.  The event enters the capturing phase first, followed by the bubbling phase.  During each phase any event listeners registered for the same event type as the event <arg><replaceable>event</replaceable></arg> are triggered; their script is evaluated.  Unless the script invokes the <tcl:method>stopPropagation</tcl:method> method of the <command xmlns="http://tclxml.sourceforge.net/doc">dom::event</command> command, all registered event listeners will be triggered.  The order in which listeners registered at a particular node for a particular phase are triggered is undefined.</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refsect2>
-    <refsect2>
-      <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
-        <d:title>
-          <command xmlns="http://tclxml.sourceforge.net/doc">dom::element</command>
-        </d:title>
-      </d:info>
-      <para>This command provides functions for element type nodes.</para>
-      <para>Valid methods for this command are as follows:</para>
-      <variablelist>
-        <varlistentry>
-          <term>
-            <methodname>cget</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">cget</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>option</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>This method returns the current setting of configuration options for an element.  See the <methodname>configure</methodname> method for the list of valid configuration options.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>configure</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">configure</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <group xmlns="http://docbook.org/ns/docbook" rep="repeat">
-                <arg>
-                  <replaceable>option</replaceable>
-                </arg>
-                <arg>
-                  <replaceable>value</replaceable>
-                </arg>
-              </group>
-            </cmdsynopsis>
-            <para>This method sets configuration options for an element.  Note that element type nodes only have read-only options.</para>
-            <para>Valid configuration options are as follows:</para>
-            <variablelist>
-              <varlistentry>
-                <term>
-                  <option>-tagName</option>
-                  <arg>
-                    <replaceable>name</replaceable>
-                  </arg>
-                </term>
-                <listitem>The tag name, or element type, of this element.</listitem>
-              </varlistentry>
-              <varlistentry>
-                <term>
-                  <option>-empty</option>
-                  <arg>
-                    <replaceable>boolean</replaceable>
-                  </arg>
-                </term>
-                <listitem>
-                  <para>Sets whether this element was specified as an empty element when the document was parsed.  That is, XML empty element syntax such as <literal><Empty/></literal> was used.</para>
-                  <para>This option has no effect upon output (serialization) of the XML document.  Empty element syntax is automatically used where appropriate.</para>
-                </listitem>
-              </varlistentry>
-            </variablelist>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>getAttribute</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">getAttribute</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>name</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>This method returns the attribute value of the attribute given by <option><replaceable>name</replaceable></option>.  If the attribute does not exist, then an empty string is returned.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>setAttribute</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">setAttribute</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>name</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>value</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>This method sets the attribute value of the attribute given by <option><replaceable>name</replaceable></option>.  If the attribute already exists then its value is replaced, otherwise the attribute is created.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>removeAttribute</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">removeAttribute</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>name</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>This method deletes the attribute given by <option><replaceable>name</replaceable></option>.  If the attribute does not exist then the method has no effect.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>getAttributeNode</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">getAttributeNode</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>name</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>Not implemented.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>setAttributeNode</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">setAttributeNode</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>name</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>Not implemented.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>removeAttributeNode</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">removeAttributeNode</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>name</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>Not implemented.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>getAttributeNS</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">getAttributeNS</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>ns</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>name</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>This method returns the attribute value of the attribute given by <option><replaceable>name</replaceable></option> in the XML namespace <arg><replaceable>ns</replaceable></arg>.  If the attribute does not exist, then an empty string is returned.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>setAttributeNS</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">setAttributeNS</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>ns</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>name</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>value</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>This method sets the attribute value of the attribute given by <option><replaceable>name</replaceable></option> in the XML namespace <arg><replaceable>ns</replaceable></arg>.  If the attribute already exists then its value is replaced, otherwise the attribute is created.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>removeAttributeNS</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">removeAttributeNS</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>ns</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>name</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>This method deletes the attribute given by <option><replaceable>name</replaceable></option> in the XML namespace <arg><replaceable>ns</replaceable></arg>.  If the attribute does not exist then the method has no effect.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>getElementsByTagName</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">getElementsByTagName</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>name</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>This method searches the node given by the argument <option><replaceable>token</replaceable></option> for descendant child elements with a type matching the argument <option><replaceable>name</replaceable></option>.  The wildcard character <literal>*</literal> matches any element type.  The return result is a "live-list" which is represented by a Tcl variable.  This method returns the name of the Tcl variable that contains the list of tokens that match.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>normalize</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">normalize</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>This method recursively coalesces textNodes within the children of the given node.  textNodes which are adjacent in the DOM tree cannot be distinguished in the serialized XML document.</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refsect2>
-    <refsect2>
-      <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
-        <d:title>
-          <command xmlns="http://tclxml.sourceforge.net/doc">dom::processinginstruction</command>
-        </d:title>
-      </d:info>
-      <para>This command provides functions for processingInstruction type nodes.</para>
-      <para>Valid methods for this command are as follows:</para>
-      <variablelist>
-        <varlistentry>
-          <term>
-            <methodname>cget</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">cget</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>option</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>This method returns the current setting of configuration options for an element.  See the <methodname>configure</methodname> method for the list of valid configuration options.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>configure</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">configure</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <group xmlns="http://docbook.org/ns/docbook" rep="repeat">
-                <arg>
-                  <replaceable>option</replaceable>
-                </arg>
-                <arg>
-                  <replaceable>value</replaceable>
-                </arg>
-              </group>
-            </cmdsynopsis>
-            <para>This method sets configuration options for a processing instruction.</para>
-            <para>Valid configuration options are as follows:</para>
-            <variablelist>
-              <varlistentry>
-                <term>
-                  <option>-target</option>
-                  <arg>
-                    <replaceable>name</replaceable>
-                  </arg>
-                </term>
-                <listitem>This option sets the target of the processing instruction.  This is a read-only configuration option.</listitem>
-              </varlistentry>
-              <varlistentry>
-                <term>
-                  <option>-data</option>
-                  <arg>
-                    <replaceable>data</replaceable>
-                  </arg>
-                </term>
-                <listitem>
-                  <para>This option sets the data of the processing instruction.</para>
-                </listitem>
-              </varlistentry>
-            </variablelist>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refsect2>
-    <refsect2>
-      <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
-        <d:title>
-          <command xmlns="http://tclxml.sourceforge.net/doc">dom::event</command>
-        </d:title>
-      </d:info>
-      <para>This command provides functions for event type nodes.</para>
-      <para>Valid methods for this command are as follows:</para>
-      <variablelist>
-        <varlistentry>
-          <term>
-            <methodname>cget</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">cget</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>This method retrieves configuration options for an event.</para>
-            <para>Valid configuration options are as follows:</para>
-            <variablelist>
-              <varlistentry>
-                <term>
-                  <option>-altKey</option>
-                </term>
-                <listitem>This option determines whether the ALT modifier key has been specified for this event.</listitem>
-              </varlistentry>
-              <varlistentry>
-                <term>
-                  <option>-attrName</option>
-                </term>
-                <listitem>This option gives the name of the attribute associated with this event.</listitem>
-                <varlistentry>
-                  <varlistentry>
-                    <term>
-                      <option>-bubbles</option>
-                    </term>
-                    <listitem>This option determines whether the event uses the bubbling phase.</listitem>
-                  </varlistentry>
-                  <varlistentry>
-                    <term>
-                      <option>-button</option>
-                    </term>
-                    <listitem>This option gives the button pressed for this event.</listitem>
-                  </varlistentry>
-                  <varlistentry>
-                    <term>
-                      <option>-cancelable</option>
-                    </term>
-                    <listitem>This option determines whether the event may be cancelled.</listitem>
-                  </varlistentry>
-                  <varlistentry>
-                    <term>
-                      <option>-clientX</option>
-                    </term>
-                    <listitem>This option gives the window X coordinate for this event.</listitem>
-                  </varlistentry>
-                  <varlistentry>
-                    <term>
-                      <option>-clientY</option>
-                    </term>
-                    <listitem>This option gives the window Y coordinate for this event.</listitem>
-                  </varlistentry>
-                  <varlistentry>
-                    <term>
-                      <option>-ctrlKey</option>
-                    </term>
-                    <listitem>This option determines whether the control modifier key has been specified for this event.</listitem>
-                  </varlistentry>
-                  <varlistentry>
-                    <term>
-                      <option>-currentNode</option>
-                    </term>
-                    <listitem>The current node of the capturing or bubbling phase.</listitem>
-                  </varlistentry>
-                  <varlistentry>
-                    <term>
-                      <option>-detail</option>
-                    </term>
-                    <listitem>This option gives an additional information item for the event, for example the key that was pressed or the button number.</listitem>
-                  </varlistentry>
-                  <varlistentry>
-                    <term>
-                      <option>-eventPhase</option>
-                    </term>
-                    <listitem>The current phase of the event.</listitem>
-                  </varlistentry>
-                  <varlistentry>
-                    <term>
-                      <option>-metaKey</option>
-                    </term>
-                    <listitem>This option determines whether the META modifier key has been specified for this event.</listitem>
-                  </varlistentry>
-                  <varlistentry>
-                    <term>
-                      <option>-newValue</option>
-                    </term>
-                    <listitem>This option gives the new value of a node.</listitem>
-                  </varlistentry>
-                  <varlistentry>
-                    <term>
-                      <option>-prevValue</option>
-                    </term>
-                    <listitem>This option gives the previous value of a node.</listitem>
-                  </varlistentry>
-                  <varlistentry>
-                    <term>
-                      <option>-relatedNode</option>
-                    </term>
-                    <listitem>This option gives a related node for this event.  See the W3C DOM Level 2 Event module specification for further details.</listitem>
-                  </varlistentry>
-                  <varlistentry>
-                    <term>
-                      <option>-screenX</option>
-                    </term>
-                    <listitem>This option gives the screen X coordinate for this event.</listitem>
-                  </varlistentry>
-                  <varlistentry>
-                    <term>
-                      <option>-screenY</option>
-                    </term>
-                    <listitem>This option gives the screen Y coordinate for this event.</listitem>
-                  </varlistentry>
-                  <varlistentry>
-                    <term>
-                      <option>-shiftKey</option>
-                    </term>
-                    <listitem>This option determines whether the shift modifier key has been specified for this event.</listitem>
-                  </varlistentry>
-                  <varlistentry>
-                    <term>
-                      <option>-target</option>
-                    </term>
-                    <listitem>The node that is the target of this event.</listitem>
-                  </varlistentry>
-                </varlistentry>
-                <term>
-                  <option>-timeStamp</option>
-                </term>
-                <listitem>
-                  <para>This option gives the time at which the event was posted.  The value is the number of milliseconds since the epoch, which is compatible with the Tcl <tcl:command>clock</tcl:command> command.  </para>
-                  <note>The implementation of this method depends on the <methodname>Tcl_GetTime</methodname> function.This function only became publically available in Tcl 8.4.  If a version of Tcl prior to 8.4 is being used, then this option will have the value <literal>0</literal>.</note>
-                </listitem>
-              </varlistentry>
-              <varlistentry>
-                <term>
-                  <option>-type</option>
-                </term>
-                <listitem>The type of this event.</listitem>
-              </varlistentry>
-              <varlistentry>
-                <term>
-                  <option>-view</option>
-                </term>
-                <listitem>This option gives whether the view of the event.</listitem>
-              </varlistentry>
-            </variablelist>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>configure</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">configure</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <group xmlns="http://docbook.org/ns/docbook" rep="repeat">
-                <arg>
-                  <replaceable>option</replaceable>
-                </arg>
-                <arg>
-                  <replaceable>value</replaceable>
-                </arg>
-              </group>
-            </cmdsynopsis>
-            <para>This method sets the configuration options for an event.  However, all event options are read-only.  See the <methodname>cget</methodname> method for the list of valid configuration options.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>stopPropagation</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">stopPropagation</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>This method cancels further propagation of the event.</para>
-            <note>Invoking this method does not prevent event listeners at the current node from being triggered.</note>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>preventDefault</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">preventDefault</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>This method stops the default action for this event from occurring.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>initEvent</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">initEvent</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>type</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>bubbles</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>cancelable</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>Initialise the event.</para>
-            <para><arg><replaceable>type</replaceable></arg> gives the type of the event.  Any of the event types defined by the W3C DOM Level 2 Event module may be specified, or a user-defined event type may be used instead.</para>
-            <para><arg><replaceable>bubbles</replaceable></arg> indicates whether the event will enter the bubbling phase after the capturing phase.  <arg><replaceable>cancelable</replaceable></arg> indicates whether the event may be cancelled.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>initUIEvent</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">initUIEvent</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>type</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>bubbles</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>cancelable</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>view</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>detail</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>Initialise a user interface event.  See <tcl:method>initEvent</tcl:method> for further information.</para>
-            <para><arg><replaceable>view</replaceable></arg> gives the view for the event (not supported by TclDOM).  <arg><replaceable>detail</replaceable></arg> provides extra data for the event.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>initMouseEvent</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">initMouseEvent</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>type</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>bubbles</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>cancelable</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>view</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>detail</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>screenX</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>screenY</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>clientX</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>clientY</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>ctrlKey</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>altKey</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>shiftKey</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>metaKey</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>button</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>relatedNode</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>Initialise a mouse event.  See <tcl:method>initUIEvent</tcl:method> for further information.</para>
-            <para><arg><replaceable>screenX</replaceable></arg> and <arg><replaceable>screenY</replaceable></arg> give the coordinates at which the event occurred relative to the screen.  <arg><replaceable>screenX</replaceable></arg> and <arg><replaceable>screenY</replaceable></arg> give the coordinates at which the event occurred relative to the window.</para>
-            <para><arg><replaceable>ctrlKey</replaceable></arg>, <arg><replaceable>altKey</replaceable></arg>, <arg><replaceable>shiftKey</replaceable></arg>, <arg><replaceable>metaKey</replaceable></arg> indicate whether the respective modifier key was pressed when the event occurred.</para>
-            <para><arg><replaceable>button</replaceable></arg> indicates which button, if any, was pressed when the event occurred.</para>
-            <para><arg><replaceable>relatedNode</replaceable></arg> specifies that a DOM node is associated with the event.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>initMutationEvent</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">initMutationEvent</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>type</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>bubbles</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>cancelable</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>relatedNode</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>prevValue</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>newValue</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>attrName</replaceable>
-              </arg>
-            </cmdsynopsis>
-            <para>Initialise a tree mutation event event.  See <tcl:method>initEvent</tcl:method> for further information.</para>
-            <para><arg><replaceable>relatedNode</replaceable></arg> specifies a DOM node to associate with the event.  <arg><replaceable>prevValue</replaceable></arg> gives the previous value of the node.  <arg><replaceable>newValue</replaceable></arg> gives the new value of the node.  <arg><replaceable>attrName</replaceable></arg> gives the name of the attribute where the event is modifying an attribute value.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>postUIEvent</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">postUIEvent</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>type</replaceable>
-              </arg>
-              <group xmlns="http://docbook.org/ns/docbook" choice="opt" rep="repeat">
-                <arg>option</arg>
-                <arg>
-                  <replaceable>value</replaceable>
-                </arg>
-              </group>
-            </cmdsynopsis>
-            <para>Non-standard convenience method that handles posting an user interface event with <arg><replaceable>token</replaceable></arg> as the target node.  This method performs the following functions:</para>
-            <orderedlist>
-              <listitem>
-                <para>Create an event node,</para>
-              </listitem>
-              <listitem>
-                <para>Initialise the event node (using default values where required),</para>
-              </listitem>
-              <listitem>
-                <para>Dispatch the event,</para>
-              </listitem>
-              <listitem>
-                <para>Destroy the event node.</para>
-              </listitem>
-            </orderedlist>
-            <para><arg><replaceable>type</replaceable></arg> gives the event type.</para>
-            <para>The following options are valid:</para>
-            <variablelist>
-              <varlistentry>
-                <term>
-                  <option>-bubbles</option>
-                </term>
-                <listitem>
-                  <para>Indicates whether the event bubbles.</para>
-                </listitem>
-              </varlistentry>
-              <varlistentry>
-                <term>
-                  <option>-cancelable</option>
-                </term>
-                <listitem>
-                  <para>Indicates whether the event can be cancelled.</para>
-                </listitem>
-              </varlistentry>
-              <varlistentry>
-                <term>
-                  <option>-view</option>
-                </term>
-                <listitem>
-                  <para>The view.</para>
-                </listitem>
-              </varlistentry>
-              <varlistentry>
-                <term>
-                  <option>-detail</option>
-                </term>
-                <listitem>
-                  <para>Extra data for the event.</para>
-                </listitem>
-              </varlistentry>
-            </variablelist>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>postMouseEvent</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">postMouseEvent</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>type</replaceable>
-              </arg>
-              <group xmlns="http://docbook.org/ns/docbook" choice="opt" rep="repeat">
-                <arg>option</arg>
-                <arg>
-                  <replaceable>value</replaceable>
-                </arg>
-              </group>
-            </cmdsynopsis>
-            <para>Non-standard convenience method that handles posting a mouse event with <arg><replaceable>token</replaceable></arg> as the target node.  This method performs the following functions:</para>
-            <orderedlist>
-              <listitem>
-                <para>Create an event node,</para>
-              </listitem>
-              <listitem>
-                <para>Initialise the event node (using default values where required),</para>
-              </listitem>
-              <listitem>
-                <para>Dispatch the event,</para>
-              </listitem>
-              <listitem>
-                <para>Destroy the event node.</para>
-              </listitem>
-            </orderedlist>
-            <para><arg><replaceable>type</replaceable></arg> gives the event type.</para>
-            <para>The following options are valid:</para>
-            <variablelist>
-              <varlistentry>
-                <term>
-                  <option>-bubbles</option>
-                </term>
-                <listitem>
-                  <para>Indicates whether the event bubbles.</para>
-                </listitem>
-              </varlistentry>
-              <varlistentry>
-                <term>
-                  <option>-cancelable</option>
-                </term>
-                <listitem>
-                  <para>Indicates whether the event can be cancelled.</para>
-                </listitem>
-              </varlistentry>
-              <varlistentry>
-                <term>
-                  <option>-view</option>
-                </term>
-                <listitem>
-                  <para>The view.</para>
-                </listitem>
-              </varlistentry>
-              <varlistentry>
-                <term>
-                  <option>-detail</option>
-                </term>
-                <listitem>
-                  <para>Extra data for the event.</para>
-                </listitem>
-              </varlistentry>
-              <varlistentry>
-                <term>
-                  <option>-screenX</option>
-                </term>
-                <listitem>
-                  <para>Gives the screen X coordinate.</para>
-                </listitem>
-              </varlistentry>
-              <varlistentry>
-                <term>
-                  <option>-screenY</option>
-                </term>
-                <listitem>
-                  <para>Gives the screen Y coordinate.</para>
-                </listitem>
-              </varlistentry>
-              <varlistentry>
-                <term>
-                  <option>-clientX</option>
-                </term>
-                <listitem>
-                  <para>Gives the window X coordinate.</para>
-                </listitem>
-              </varlistentry>
-              <varlistentry>
-                <term>
-                  <option>-clientY</option>
-                </term>
-                <listitem>
-                  <para>Gives the window Y coordinate.</para>
-                </listitem>
-              </varlistentry>
-              <varlistentry>
-                <term>
-                  <option>-ctrlKey</option>
-                </term>
-                <listitem>
-                  <para>Indicates whether the control modifier key was pressed.</para>
-                </listitem>
-              </varlistentry>
-              <varlistentry>
-                <term>
-                  <option>-altKey</option>
-                </term>
-                <listitem>
-                  <para>Indicates whether the ALT modifier key was pressed.</para>
-                </listitem>
-              </varlistentry>
-              <varlistentry>
-                <term>
-                  <option>-shiftKey</option>
-                </term>
-                <listitem>
-                  <para>Indicates whether the shift modifier key was pressed.</para>
-                </listitem>
-              </varlistentry>
-              <varlistentry>
-                <term>
-                  <option>-metaKey</option>
-                </term>
-                <listitem>
-                  <para>Indicates whether the meta modifier key was pressed.</para>
-                </listitem>
-              </varlistentry>
-              <varlistentry>
-                <term>
-                  <option>-button</option>
-                </term>
-                <listitem>
-                  <para>Gives the button pressed.</para>
-                </listitem>
-              </varlistentry>
-              <varlistentry>
-                <term>
-                  <option>-relatedNode</option>
-                </term>
-                <listitem>
-                  <para>Gives a node to associate with the event.</para>
-                </listitem>
-              </varlistentry>
-            </variablelist>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>
-            <methodname>postMutationEvent</methodname>
-          </term>
-          <listitem>
-            <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-              <methodname xmlns="http://docbook.org/ns/docbook">postMutationEvent</methodname>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>token</replaceable>
-              </arg>
-              <arg xmlns="http://docbook.org/ns/docbook">
-                <replaceable>type</replaceable>
-              </arg>
-              <group xmlns="http://docbook.org/ns/docbook" choice="opt" rep="repeat">
-                <arg>option</arg>
-                <arg>
-                  <replaceable>value</replaceable>
-                </arg>
-              </group>
-            </cmdsynopsis>
-            <para>Non-standard convenience method that handles posting a mutation event with <arg><replaceable>token</replaceable></arg> as the target node.  This method performs the following functions:</para>
-            <orderedlist>
-              <listitem>
-                <para>Create an event node,</para>
-              </listitem>
-              <listitem>
-                <para>Initialise the event node (using default values where required),</para>
-              </listitem>
-              <listitem>
-                <para>Dispatch the event,</para>
-              </listitem>
-              <listitem>
-                <para>Destroy the event node.</para>
-              </listitem>
-            </orderedlist>
-            <para><arg><replaceable>type</replaceable></arg> gives the event type.</para>
-            <para>The following options are valid:</para>
-            <variablelist>
-              <varlistentry>
-                <term>
-                  <option>-bubbles</option>
-                </term>
-                <listitem>
-                  <para>Indicates whether the event bubbles.</para>
-                </listitem>
-              </varlistentry>
-              <varlistentry>
-                <term>
-                  <option>-cancelable</option>
-                </term>
-                <listitem>
-                  <para>Indicates whether the event can be cancelled.</para>
-                </listitem>
-              </varlistentry>
-              <varlistentry>
-                <term>
-                  <option>-relatedNode</option>
-                </term>
-                <listitem>
-                  <para>Gives a node to associate with the event.</para>
-                </listitem>
-              </varlistentry>
-              <varlistentry>
-                <term>
-                  <option>-prevValue</option>
-                </term>
-                <listitem>
-                  <para>Gives the previous value of the target node.</para>
-                </listitem>
-              </varlistentry>
-              <varlistentry>
-                <term>
-                  <option>-newValue</option>
-                </term>
-                <listitem>
-                  <para>Gives the new value of the target node.</para>
-                </listitem>
-              </varlistentry>
-              <varlistentry>
-                <term>
-                  <option>-attrName</option>
-                </term>
-                <listitem>
-                  <para>Gives the name of the attribute modified.</para>
-                </listitem>
-              </varlistentry>
-            </variablelist>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refsect2>
-  </refsect1>
-  <refsect1>
-    <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
-      <d:title>Errors</d:title>
-    </d:info>
-    <para>If an operation results in an error condition, an error message is returned as a structured Tcl list.  The list has members as follows:</para>
-    <informalexample>
-      <programlisting>{domain level code node line message int1 int2 string1 string2 string3}</programlisting>
-    </informalexample>
-    <para>The format of the list is described in the TclXML manual page.</para>
-  </refsect1>
-  <refsect1>
-    <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
-      <d:title>Implementations</d:title>
-    </d:info>
-    <para>This section documents the various implmentations of the TclDOM API.</para>
-    <refsect2>
-      <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
-        <d:title>Tcl Implementation</d:title>
-      </d:info>
-      <para>The Tcl implementation is provided by the <tcl:package>dom::tcl</tcl:package> package.</para>
-      <refsect3>
-        <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
-          <d:title>Limitations</d:title>
-        </d:info>
-        <para>This implementation is not able to preform the following functions:</para>
-        <itemizedlist>
-          <listitem>
-            <para>Validation: DTD, XML Schema or RelaxNG validation are not supported.</para>
-          </listitem>
-          <listitem>
-            <para>Character encodings: The TclDOM/tcl implementation itself does not handle character encodings other than utf-8.  Character encodings are handled by Tcl itself.</para>
-          </listitem>
-        </itemizedlist>
-      </refsect3>
-    </refsect2>
-    <refsect2>
-      <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
-        <d:title>libxml2 Implementation</d:title>
-      </d:info>
-      <para>The TclDOM/libxml2 implementation is a wrapper for the <d:link xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc" xlink:href="http://xmlsoft.org/">Gnome libxml2 library</d:link>.  It is provided by the <tcl:package>dom::libxml2</tcl:package> package.  It is a high-performance library, making use of Tcl objects for fast access to tree nodes.</para>
-      <refsect3>
-        <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
-          <d:title>Limitations</d:title>
-        </d:info>
-        <itemizedlist>
-          <listitem>
-            <para>The TclXML/libxml2 parser must be used to parse an XML document.  It is not possible to use any other parser class.</para>
-          </listitem>
-          <listitem>
-            <para>RELAX-NG validation is not yet supported.</para>
-          </listitem>
-          <listitem>
-            <para>The importNode method has not been implemented.</para>
-          </listitem>
-        </itemizedlist>
-      </refsect3>
-    </refsect2>
-  </refsect1>
-</refentry>
diff --git a/tclxml-3.2/doc/tclxml.css b/tclxml-3.2/doc/tclxml.css
deleted file mode 100644
index 81c01c3..0000000
--- a/tclxml-3.2/doc/tclxml.css
+++ /dev/null
@@ -1,13 +0,0 @@
-body
-{
-    bgcolor: white;
-    color: black;
-    font-family: sans-serif;
-}
-
-div.note
-{
-    margin-left: 15px;
-    margin-right: 15px;
-}
-
diff --git a/tclxml-3.2/doc/tclxml.html b/tclxml-3.2/doc/tclxml.html
deleted file mode 100644
index 37f4a02..0000000
--- a/tclxml-3.2/doc/tclxml.html
+++ /dev/null
@@ -1,849 +0,0 @@
-<html>
-<head>
-<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
-<title>TclXML</title>
-<link rel="stylesheet" href="tclxml.css">
-</head>
-<body><div class="refentry">
-<h1 class="title"><a name="id18405">TclXML</a></h1>
-<h2>Contents</h2>
-<ul>
-<li><a href="#synopsis">Synopsis</a></li>
-<li><a href="#id18713">Description</a></li>
-<li>
-<a href="#id18784">Commands</a><ul>
-<li>
-<a href="#id18796">::xml::parserclass</a><ul><li><a href="#id18823">Command Options</a></li></ul>
-</li>
-<li>
-<a href="#id19046">::xml::parser</a><ul>
-<li><a href="#id19102">Configuration Options</a></li>
-<li><a href="#id22051">Parser Command</a></li>
-</ul>
-</li>
-</ul>
-</li>
-<li><a href="#id22422">Callback Return Codes</a></li>
-<li><a href="#id22510">Error Messages</a></li>
-<li><a href="#id22728">Application Examples</a></li>
-<li><a href="#id22772">Safe XML</a></li>
-<li>
-<a href="#id22797">Parser Classes</a><ul>
-<li><a href="#id22814">Tcl Parser Class</a></li>
-<li>
-<a href="#id22857">libxml2 Parser Class</a><ul>
-<li><a href="#id22898">get Method</a></li>
-<li><a href="#id22948">Additional Options</a></li>
-<li><a href="#id23083">Limitations</a></li>
-</ul>
-</li>
-</ul>
-</li>
-<li><a href="#id23155">Keywords</a></li>
-</ul>
-<div class="refnamediv">
-<span class="refname">TclXML</span> — <span class="refpurpose">XML parser support for Tcl</span>
-</div>
-<div class="refsynopsisdiv">
-<a name="synopsis"></a><h2>Synopsis</h2>
-<div class="cmdsynopsis" id="id18559">
-<a name="id18559"></a><span class="command" id="id18562"><a name="package_require_xml"></a><tt>package require xml</tt> </span>
-</div>
-<div class="cmdsynopsis" id="id18568">
-<a name="id18568"></a><span class="command" id="id18571"><a name="package_require_parserclass"></a><tt>package require <em>parserclass</em></tt> </span>
-</div>
-<br><span class="pkgsynopsis"><pre>package require xml ?3.2?</pre></span><div class="cmdsynopsis" id="id18613">
-<a name="id18613"></a><span class="command" id="id18617"><a name="__xml__parserclass"></a><tt>::xml::parserclass</tt> </span> <em>option</em> ?arg arg...?</div>
-<div class="cmdsynopsis" id="id18643">
-<a name="id18643"></a><span class="command" id="id18646"><a name="__xml__parser"></a><tt>::xml::parser</tt> </span> ?<em>name</em>? ? <em>-option</em><em>value</em>...?</div>
-<div class="cmdsynopsis" id="id18682">
-<a name="id18682"></a><span class="command" id="id18685"><a name="parser"></a><tt><em>parser</em></tt> </span><em>option</em> <em>arg</em>
-</div>
-<h3>Tcl Namespace Usage</h3>
-<br><tt>::xml</tt><br><tt>::sgml</tt><br><tt>::xml::tclparser</tt><br><tt>::xml::libxml2</tt><p></p>
-</div>
-<div class="refsect1">
-<h2>
-<a name="id18713"></a>Description</h2>
-<p>TclXML provides event-based parsing of <a href="http://www.w3.org/XML/">XML</a> documents.  The application may register callback scripts for certain document features, and when the parser encounters those features while parsing the document the callback is evaluated.</p>
-<p>The parser may also perform other functions, such as normalisation, validation and/or entity expansion.  Generally, these functions are under the control of configuration options.  Whether these functions can be performed at all depends on the parser implementation.</p>
-<p>The TclXML package provides a generic interface for use by a Tcl application, along with a low-level interface for use by a parser implementation.  Each implementation provides a class of XML parser, and these register themselves using the <strong>::xml::parserclass create</strong> command.  One of the registered parser classes will be the default parser class.</p>
-<p>Loading the package with the generic <strong>package require xml</strong> command allows the package to automatically determine the default parser class.  In order to select a particular parser class as the default, that class' package may be loaded directly, eg. <strong>package require xml::libxml2</strong>.  In all cases, all available parser classes are registered with the TclXML package, the difference is simply in which one becomes the default.</p>
-</div>
-<div class="refsect1">
-<h2>
-<a name="id18784"></a>Commands</h2>
-<div class="refsect2">
-<h3>
-<a name="id18796"></a><strong>::xml::parserclass</strong>
-</h3>
-<p>The <strong>::xml::parserclass</strong> command is used to manage XML parser classes.</p>
-<div class="refsect3">
-<h4>
-<a name="id18823"></a>Command Options</h4>
-<p>The following command options may be used:</p>
-<dl>
-<span class="term"><span class="methodname">create</span></span><dd>
-<div class="cmdsynopsis" id="id18856">
-<a name="id18856"></a>create <em>name</em> ? <em>-createcommand</em><em>script</em>? ? <em>-createentityparsercommand</em><em>script</em>? ? <em>-parsecommand</em><em>script</em>? ? <em>-configurecommand</em><em>script</em>? ? <em>-getcommand</em><em>script</em>? ? <em>-deletecommand</em><em>script</em>?</div>
-<p>Creates an XML parser class with the given name.</p>
-</dd>
-<span class="term"><span class="methodname">destroy</span></span><dd>
-<div class="cmdsynopsis" id="id18984">
-<a name="id18984"></a>destroy <em>name</em>
-</div>
-<p>Destroys an XML parser class.</p>
-</dd>
-<span class="term"><span class="methodname">info</span></span><dd>
-<div class="cmdsynopsis" id="id19016">
-<a name="id19016"></a><tt>::xml::parserclass</tt> <u>info</u> names default</div>
-<p>Returns information about registered XML parser classes.</p>
-</dd>
-</dl>
-</div>
-</div>
-<div class="refsect2">
-<h3>
-<a name="id19046"></a><strong>::xml::parser</strong>
-</h3>
-<p>The <strong>::xml::parser</strong> command creates an <em>XML</em> parser object.  The return value of the command is the name of the newly created parser.</p>
-<p>The parser scans an XML document's syntactical structure, evaluating callback scripts for each feature found.  At the very least the parser will normalise the document and check the document for well-formedness.  If the document is not well-formed then the  <em>-errorcommand</em> option will be evaluated.  Some parser classes may perform additional functions, such as validation.  Additional features provided by the various parser classes are described in the section Parser Classes</p>
-<p>Parsing is performed synchronously.  The command blocks until the entire document has been parsed.  Parsing may be terminated by an application callback, see the section Callback Return Codes.  Incremental parsing is also supported by using the  <em>-final</em> configuration option.</p>
-<div class="refsect3">
-<h4>
-<a name="id19102"></a>Configuration Options</h4>
-<p>The <strong>::xml::parser</strong> command accepts the following configuration options:</p>
-<dl>
-<span class="term"> <em>-attlistdeclcommand</em></span><dd>
-<p><tt>-attlistdeclcommand</tt> <u><em>script</em></u></p>
-<p>Specifies the prefix of a Tcl command to be evaluated whenever an attribute list declaration is encountered in the DTD subset of an XML document.  The command evaluated is:</p>
-<div class="cmdsynopsis" id="id19162">
-<a name="id19162"></a><tt><em>script</em></tt> <em>name</em> <em>attrname</em> <em>type</em> <em>default</em> <em>value</em>
-</div>
-<p>where:</p>
-<table border="0">
-<tr>
-<td valign="top"> <tt><em>name</em></tt>
-</td>
-<td valign="top">Element type name</td>
-</tr>
-<tr>
-<td valign="top"> <tt><em>attrname</em></tt>
-</td>
-<td valign="top">Attribute name being declared</td>
-</tr>
-<tr>
-<td valign="top"> <tt><em>type</em></tt>
-</td>
-<td valign="top">Attribute type</td>
-</tr>
-<tr>
-<td valign="top"> <tt><em>default</em></tt>
-</td>
-<td valign="top">Attribute default, such as #IMPLIED</td>
-</tr>
-<tr>
-<td valign="top"> <tt><em>value</em></tt>
-</td>
-<td valign="top">Default attribute value.  Empty string if none given.</td>
-</tr>
-</table>
-</dd>
-<span class="term"> <em>-baseuri</em></span><span class="term"> <em>-baseurl</em></span><dd>
-<p><tt>-baseuri</tt> <u><em>URI</em></u></p>
-<p><tt>-baseurl</tt> <u><em>URI</em></u></p>
-<p>Specifies the base URI for resolving relative URIs that may be used in the XML document to refer to external entities.</p>
-<p> <em>-baseurl</em> is deprecated in favour of  <em>-baseuri</em>.</p>
-</dd>
-<span class="term"> <em>-characterdatacommand</em></span><dd>
-<p><tt>-characterdatacommand</tt> <u><em>script</em></u></p>
-<p>Specifies the prefix of a Tcl command to be evaluated whenever character data is encountered in the XML document being parsed.  The command evaluated is:</p>
-<div class="cmdsynopsis" id="id19406">
-<a name="id19406"></a><tt><em>script</em></tt> <em>data</em>
-</div>
-<p>where:</p>
-<table border="0"><tr>
-<td valign="top"> <tt><em>data</em></tt>
-</td>
-<td valign="top">Character data in the document</td>
-</tr></table>
-</dd>
-<span class="term"> <em>-commentcommand</em></span><dd>
-<p><tt>-commentcommand</tt> <u><em>script</em></u></p>
-<p>Specifies the prefix of a Tcl command to be evaluated whenever a comment is encountered in the XML document being parsed.  The command evaluated is:</p>
-<div class="cmdsynopsis" id="id19484">
-<a name="id19484"></a><tt><em>script</em></tt> <em>data</em>
-</div>
-<p>where:</p>
-<table border="0"><tr>
-<td valign="top"> <tt><em>data</em></tt>
-</td>
-<td valign="top">Comment data</td>
-</tr></table>
-</dd>
-<span class="term"> <em>-defaultcommand</em></span><dd>
-<p><tt>-defaultcommand</tt> <u><em>script</em></u></p>
-<p>Specifies the prefix of a Tcl command to be evaluated when no other callback has been defined for a document feature which has been encountered.  The command evaluated is:</p>
-<div class="cmdsynopsis" id="id19561">
-<a name="id19561"></a><tt><em>script</em></tt> <em>data</em>
-</div>
-<p>where:</p>
-<table border="0"><tr>
-<td valign="top"> <tt><em>data</em></tt>
-</td>
-<td valign="top">Document data</td>
-</tr></table>
-</dd>
-<span class="term"> <em>-defaultexpandinternalentities</em></span><dd>
-<p><tt>-defaultexpandinternalentities</tt> <u><em>boolean</em></u></p>
-<p>Specifies whether entities declared in the internal DTD subset are expanded with their replacement text.  If entities are not expanded then the entity references will be reported with no expansion.</p>
-</dd>
-<span class="term"> <em>-doctypecommand</em></span><dd>
-<p><tt>-doctypecommand</tt> <u><em>script</em></u></p>
-<p>Specifies the prefix of a Tcl command to be evaluated when the document type declaration is encountered.  The command evaluated is:</p>
-<div class="cmdsynopsis" id="id19676">
-<a name="id19676"></a><tt><em>script</em></tt> <em>name</em> <em>public</em> <em>system</em> <em>dtd</em>
-</div>
-<p>where:</p>
-<table border="0">
-<tr>
-<td valign="top"> <tt><em>name</em></tt>
-</td>
-<td valign="top">The name of the document element</td>
-</tr>
-<tr>
-<td valign="top"> <tt><em>public</em></tt>
-</td>
-<td valign="top">Public identifier for the external DTD subset</td>
-</tr>
-<tr>
-<td valign="top"> <tt><em>system</em></tt>
-</td>
-<td valign="top">System identifier for the external DTD subset.  Usually a URI.</td>
-</tr>
-<tr>
-<td valign="top"> <tt><em>dtd</em></tt>
-</td>
-<td valign="top">The internal DTD subset</td>
-</tr>
-</table>
-<p>See also  <em>-startdoctypedeclcommand</em> and  <em>-enddoctypedeclcommand</em>.</p>
-</dd>
-<span class="term"> <em>-elementdeclcommand</em></span><dd>
-<p><tt>-elementdeclcommand</tt> <u><em>script</em></u></p>
-<p>Specifies the prefix of a Tcl command to be evaluated when an element markup declaration is encountered.  The command evaluated is:</p>
-<div class="cmdsynopsis" id="id19838">
-<a name="id19838"></a><tt><em>script</em></tt> <em>name</em> <em>model</em>
-</div>
-<p>where:</p>
-<table border="0">
-<tr>
-<td valign="top"> <tt><em>name</em></tt>
-</td>
-<td valign="top">The element type name</td>
-</tr>
-<tr>
-<td valign="top"> <tt><em>model</em></tt>
-</td>
-<td valign="top">Content model specification</td>
-</tr>
-</table>
-</dd>
-<span class="term"> <em>-elementendcommand</em></span><dd>
-<p><tt>-elementendcommand</tt> <u><em>script</em></u></p>
-<p>Specifies the prefix of a Tcl command to be evaluated when an element end tag is encountered.  The command evaluated is:</p>
-<div class="cmdsynopsis" id="id19940">
-<a name="id19940"></a><tt><em>script</em></tt> <em>name</em> <em>args</em>
-</div>
-<p>where:</p>
-<table border="0">
-<tr>
-<td valign="top"> <tt><em>name</em></tt>
-</td>
-<td valign="top">The element type name that has ended</td>
-</tr>
-<tr>
-<td valign="top"> <tt><em>args</em></tt>
-</td>
-<td valign="top">Additional information about this element</td>
-</tr>
-</table>
-<p>Additional information about the element takes the form of configuration options.  Possible options are:</p>
-<table border="0">
-<tr>
-<td valign="top"> <em>-empty</em> <tt><em>boolean</em></tt>
-</td>
-<td valign="top">The empty element syntax was used for this element</td>
-</tr>
-<tr>
-<td valign="top"> <em>-namespace</em> <tt><em>uri</em></tt>
-</td>
-<td valign="top">The element is in the XML namespace associated with the given URI</td>
-</tr>
-</table>
-</dd>
-<span class="term"> <em>-elementstartcommand</em></span><dd>
-<p><tt>-elementstartcommand</tt> <u><em>script</em></u></p>
-<p>Specifies the prefix of a Tcl command to be evaluated when an element start tag is encountered.  The command evaluated is:</p>
-<div class="cmdsynopsis" id="id20093">
-<a name="id20093"></a><tt><em>script</em></tt> <em>name</em> <em>attlist</em> <em>args</em>
-</div>
-<p>where:</p>
-<table border="0">
-<tr>
-<td valign="top"> <tt><em>name</em></tt>
-</td>
-<td valign="top">The element type name that has started</td>
-</tr>
-<tr>
-<td valign="top"> <tt><em>attlist</em></tt>
-</td>
-<td valign="top">A Tcl list containing the attributes for this element.  The list of attributes is formatted as pairs of attribute names and their values.  </td>
-</tr>
-<tr>
-<td valign="top"> <tt><em>args</em></tt>
-</td>
-<td valign="top">Additional information about this element</td>
-</tr>
-</table>
-<p>Additional information about the element takes the form of configuration options.  Possible options are:</p>
-<table border="0">
-<tr>
-<td valign="top"> <em>-empty</em> <tt><em>boolean</em></tt>
-</td>
-<td valign="top">The empty element syntax was used for this element</td>
-</tr>
-<tr>
-<td valign="top"> <em>-namespace</em> <tt><em>uri</em></tt>
-</td>
-<td valign="top">The element is in the XML namespace associated with the given URI</td>
-</tr>
-<tr>
-<td valign="top"> <em>-namespacedecls</em> <tt><em>list</em></tt>
-</td>
-<td valign="top">The start tag included one or more XML Namespace declarations.   <tt><em>list</em></tt> is a Tcl list giving the namespaces declared.  The list is formatted as pairs of values, the first value is the namespace URI and the second value is the prefix used for the namespace in this document.  A default XML namespace declaration will have an empty string for the prefix.</td>
-</tr>
-</table>
-</dd>
-<span class="term"> <em>-encoding</em></span><dd>
-<p><tt>-encoding</tt> <u><em>value</em></u></p>
-<p>Gives the character encoding of the document.  This option only has an effect before a document is parsed.  The default character encoding is <span class="literal">utf-8</span>.  If the value <span class="literal">unknown</span> is given, or any value other than <span class="literal">utf-8</span>, then the document text is treated as binary data.  If the value is given as <span class="literal">unknown</span> then the parser will attempt to automatically determine the character encoding of the document (using byte-order-marks, etc).  If any value other than <span class="literal">utf-8</span> or <span class="literal">unknown</span> is given then the parser will read the document text using that character encoding.</p>
-</dd>
-<span class="term"> <em>-endcdatasectioncommand</em></span><dd>
-<p><tt>-endcdatasectioncommand</tt> <u><em>script</em></u></p>
-<p>Specifies the prefix of a Tcl command to be evaluated when end of a CDATA section is encountered.  The command is evaluated with no further arguments.</p>
-</dd>
-<span class="term"> <em>-enddoctypedeclcommand</em></span><dd>
-<p><tt>-enddoctypedeclcommand</tt> <u><em>script</em></u></p>
-<p>Specifies the prefix of a Tcl command to be evaluated when end of the document type declaration is encountered.  The command is evaluated with no further arguments.</p>
-</dd>
-<span class="term"> <em>-entitydeclcommand</em></span><dd>
-<p><tt>-entitydeclcommand</tt> <u><em>script</em></u></p>
-<p>Specifies the prefix of a Tcl command to be evaluated when an entity declaration is encountered.  The command evaluated is:</p>
-<div class="cmdsynopsis" id="id20436">
-<a name="id20436"></a><tt><em>script</em></tt> <em>name</em> <em>args</em>
-</div>
-<p>where:</p>
-<table border="0">
-<tr>
-<td valign="top"> <tt><em>name</em></tt>
-</td>
-<td valign="top">The name of the entity being declared</td>
-</tr>
-<tr>
-<td valign="top"> <tt><em>args</em></tt>
-</td>
-<td valign="top">Additional information about the entity declaration.  An internal entity shall have a single argument, the replacement text.  An external parsed entity shall have two additional arguments, the public and system indentifiers of the external resource.  An external unparsed entity shall have three additional arguments, the public and system identifiers followed by the notation name.</td>
-</tr>
-</table>
-</dd>
-<span class="term"> <em>-entityreferencecommand</em></span><dd>
-<p><tt>-entityreferencecommand</tt> <u><em>script</em></u></p>
-<p>Specifies the prefix of a Tcl command to be evaluated when an entity reference is encountered.  The command evaluated is:</p>
-<div class="cmdsynopsis" id="id20548">
-<a name="id20548"></a><tt><em>script</em></tt> <em>name</em>
-</div>
-<p>where:</p>
-<table border="0"><tr>
-<td valign="top"> <tt><em>name</em></tt>
-</td>
-<td valign="top">The name of the entity being referenced</td>
-</tr></table>
-</dd>
-<span class="term"> <em>-errorcommand</em></span><dd>
-<p><tt>-errorcommand</tt> <u><em>script</em></u></p>
-<p>Specifies the prefix of a Tcl command to be evaluated when a fatal error is detected.  The error may be due to the XML document not being well-formed.  In the case of a validating parser class, the error may also be due to the XML document not obeying validity constraints.  By default, a callback script is provided which causes an error return code, but an application may supply a script which attempts to continue parsing.  The command evaluated is:</p>
-<div class="cmdsynopsis" id="id20631">
-<a name="id20631"></a><tt><em>script</em></tt> <em>errorcode</em> <em>errormsg</em>
-</div>
-<p>where:</p>
-<table border="0">
-<tr>
-<td valign="top"> <tt><em>errorcode</em></tt>
-</td>
-<td valign="top">A single word description of the error, intended for use by an application</td>
-</tr>
-<tr>
-<td valign="top"> <tt><em>errormsg</em></tt>
-</td>
-<td valign="top">A human-readable description of the error</td>
-</tr>
-</table>
-</dd>
-<span class="term"> <em>-externalentitycommand</em></span><dd>
-<p><tt>-externalentitycommand</tt> <u><em>script</em></u></p>
-<p>Specifies the prefix of a Tcl command to be evaluated to resolve an external entity reference.  If the parser has been configured to validate the XML document, a default script is supplied that resolves the URI given as the system identifier of the external entity and recursively parses the entity's data.  If the parser has been configured as a non-validating parser, then by default external entities are not resolved.  This option can be used to override the default behaviour.  The command evaluated is:</p>
-<div class="cmdsynopsis" id="id20732">
-<a name="id20732"></a><tt><em>script</em></tt> <em>name</em> <em>baseuri</em> <em>uri</em> <em>id</em>
-</div>
-<p>where:</p>
-<table border="0">
-<tr>
-<td valign="top"> <tt><em>name</em></tt>
-</td>
-<td valign="top">The Tcl command name of the current parser</td>
-</tr>
-<tr>
-<td valign="top"> <tt><em>baseuri</em></tt>
-</td>
-<td valign="top">An absolute URI for the current entity which is to be used to resolve relative URIs</td>
-</tr>
-<tr>
-<td valign="top"> <tt><em>uri</em></tt>
-</td>
-<td valign="top">The system identifier of the external entity, usually a URI</td>
-</tr>
-<tr>
-<td valign="top"> <tt><em>id</em></tt>
-</td>
-<td valign="top">The public identifier of the external entity.  If no public identifier was given in the entity declaration then  <tt><em>id</em></tt> will be an empty string.</td>
-</tr>
-</table>
-<p>The return result of the callback script determines the action of the parser.  Note that these codes are interpreted in a different manner to other callbacks.</p>
-<dl>
-<span class="term"><span class="literal">TCL_OK</span></span><dd>
-<p>The return result of the callback script is used as the external entity's data.  The URI passed to the callback script is used as the entity's base URI.</p>
-<p>This is useful to either override the normal loading of an entity's data, or to implement new or alternative URI schemes.  As an example, the script below sets an external entity handler that intercepts "tcl:" URIs and evaluates them as inline Tcl scripts:</p>
-<div class="informalexample"><pre><div class="programlisting"><pre>
-package require xml
-
-proc External {name baseuri uri id} {
-    switch -glob -- $uri {
-	tcl:* {
-	    regexp {^tcl:(.*)$} $uri discard script
-	    return [uplevel #0 $script]
-	}
-	default {
-	    return -code continue {}
-	}
-    }
-}
-
-set parser [xml::parser -externalentitycommand External]
-$parser parse {<!DOCTYPE example [
-  <!ENTITY example SYSTEM "tcl:set%20example%20HelloWorld">
-]>
-<example>
-  &example;
-</example>
-}
-
-puts $example
-</pre></div></pre></div>
-<p>This script will print "HelloWorld" to stdout.</p>
-</dd>
-<span class="term"><span class="literal">TCL_CONTINUE</span></span><dd>
-<p>In a normal (non-safe) interpreter, the default external entity handler is used to load the external entity data as per normal operation of the parser.  If the parser is executing in a Safe Tcl interpreter then the entity is not loaded at all.</p>
-<p>This is useful to interpose on the loading of external entities without interfering with the loading of entities.</p>
-</dd>
-<span class="term"><span class="literal">TCL_BREAK</span></span><dd><p>No data is returned for this entity, ie. the entity is ignored.  No error is propagated.</p></dd>
-<span class="term"><span class="literal">TCL_ERROR</span></span><dd><p>No data is returned for this entity, ie. the entity is ignored.  A background error is registered, using the result of the callback script.</p></dd>
-</dl>
-</dd>
-<span class="term"> <em>-final</em></span><dd>
-<p><tt>-final</tt> <u><em>boolean</em></u></p>
-<p>Specifies whether the XML document being parsed is complete.  If the document is to be incrementally parsed then this option will be set to false, and when the last fragment of document is parsed it is set to true.  For example,</p>
-<div class="informalexample"><pre><div class="programlisting"><pre>
-set parser [::xml::parser -final 0]
-$parser parse $data1
-.
-.
-.
-$parser parse $data2
-.
-.
-.
-$parser configure -final 1
-$parser parse $finaldata
-		</pre></div></pre></div>
-</dd>
-<span class="term"> <em>-ignorewhitespace</em></span><dd>
-<p><tt>-ignorewhitespace</tt> <u><em>boolean</em></u></p>
-<p>If this option is set to true then spans of character data in the XML document which are composed only of white-space (CR, LF, space, tab) will not be reported to the application.  In other words, the data passed to every invocation of the  <em>-characterdatacommand</em> script will contain at least one non-white-space character.</p>
-</dd>
-<span class="term"> <em>-notationdeclcommand</em></span><dd>
-<p><tt>-notationdeclcommand</tt> <u><em>script</em></u></p>
-<p>Specifies the prefix of a Tcl command to be evaluated when a notation declaration is encountered.  The command evaluated is:</p>
-<div class="cmdsynopsis" id="id21088">
-<a name="id21088"></a><tt><em>script</em></tt> <em>name</em> <em>uri</em>
-</div>
-<p>where:</p>
-<table border="0">
-<tr>
-<td valign="top"> <tt><em>name</em></tt>
-</td>
-<td valign="top">The name of the notation</td>
-</tr>
-<tr>
-<td valign="top"> <tt><em>uri</em></tt>
-</td>
-<td valign="top">An external identifier for the notation, usually a URI.</td>
-</tr>
-</table>
-</dd>
-<span class="term"> <em>-notstandalonecommand</em></span><dd>
-<p><tt>-notstandalonecommand</tt> <u><em>script</em></u></p>
-<p>Specifies the prefix of a Tcl command to be evaluated when the parser determines that the XML document being parsed is not a standalone document.</p>
-</dd>
-<span class="term"> <em>-paramentityparsing</em></span><dd>
-<p><tt>-paramentityparsing</tt> <u><em>boolean</em></u></p>
-<p>Controls whether external parameter entities are parsed.</p>
-</dd>
-<span class="term"> <em>-parameterentitydeclcommand</em></span><dd>
-<p><tt>-parameterentitydeclcommand</tt> <u><em>script</em></u></p>
-<p>Specifies the prefix of a Tcl command to be evaluated when a parameter entity declaration is encountered.  The command evaluated is:</p>
-<div class="cmdsynopsis" id="id21261">
-<a name="id21261"></a><tt><em>script</em></tt> <em>name</em> <em>args</em>
-</div>
-<p>where:</p>
-<table border="0">
-<tr>
-<td valign="top"> <tt><em>name</em></tt>
-</td>
-<td valign="top">The name of the parameter entity</td>
-</tr>
-<tr>
-<td valign="top"> <tt><em>args</em></tt>
-</td>
-<td valign="top">For an internal parameter entity there is only one additional argument, the replacement text.  For external parameter entities there are two additional arguments, the system and public identifiers respectively.</td>
-</tr>
-</table>
-</dd>
-<span class="term"> <em>-parser</em></span><dd>
-<p><tt>-parser</tt> <u><em>name</em></u></p>
-<p>The name of the parser class to instantiate for this parser object.  This option may only be specified when the parser instance is created.</p>
-</dd>
-<span class="term"> <em>-processinginstructioncommand</em></span><dd>
-<p><tt>-processinginstructioncommand</tt> <u><em>script</em></u></p>
-<p>Specifies the prefix of a Tcl command to be evaluated when a processing instruction is encountered.  The command evaluated is:</p>
-<div class="cmdsynopsis" id="id21404">
-<a name="id21404"></a><tt><em>script</em></tt> <em>target</em> <em>data</em>
-</div>
-<p>where:</p>
-<table border="0">
-<tr>
-<td valign="top"> <tt><em>target</em></tt>
-</td>
-<td valign="top">The name of the processing instruction target</td>
-</tr>
-<tr>
-<td valign="top"> <tt><em>data</em></tt>
-</td>
-<td valign="top">Remaining data from the processing instruction</td>
-</tr>
-</table>
-</dd>
-<span class="term"> <em>-reportempty</em></span><dd>
-<p><tt>-reportempty</tt> <u><em>boolean</em></u></p>
-<p>If this option is enabled then when an element is encountered that uses the special empty element syntax, additional arguments are appended to the  <em>-elementstartcommand</em> and  <em>-elementendcommand</em> callbacks.  The arguments <span class="arg">-empty 1</span> are appended.  For example:</p>
-<div class="cmdsynopsis" id="id21518">
-<a name="id21518"></a><tt><em>script</em></tt>  <em>-empty</em>1</div>
-</dd>
-<span class="term"> <em>-startcdatasectioncommand</em></span><dd>
-<p><tt>-startcdatasectioncommand</tt> <u><em>script</em></u></p>
-<p>Specifies the prefix of a Tcl command to be evaluated when the start of a CDATA section section is encountered.  No arguments are appended to the script.</p>
-</dd>
-<span class="term"> <em>-startdoctypedeclcommand</em></span><dd>
-<p><tt>-startdoctypedeclcommand</tt> <u><em>script</em></u></p>
-<p>Specifies the prefix of a Tcl command to be evaluated at the start of a document type declaration.  No arguments are appended to the script.</p>
-</dd>
-<span class="term"> <em>-unknownencodingcommand</em></span><dd>
-<p><tt>-unknownencodingcommand</tt> <u><em>script</em></u></p>
-<p>Specifies the prefix of a Tcl command to be evaluated when a character is encountered with an unknown encoding.  This option has not been implemented.</p>
-</dd>
-<span class="term"> <em>-unparsedentitydeclcommand</em></span><dd>
-<p><tt>-unparsedentitydeclcommand</tt> <u><em>script</em></u></p>
-<p>Specifies the prefix of a Tcl command to be evaluated when a declaration is encountered for an unparsed entity.  The command evaluated is:</p>
-<div class="cmdsynopsis" id="id21683">
-<a name="id21683"></a><tt><em>script</em></tt> <em>system</em> <em>public</em> <em>notation</em>
-</div>
-<p>where:</p>
-<table border="0">
-<tr>
-<td valign="top"> <tt><em>system</em></tt>
-</td>
-<td valign="top">The system identifier of the external entity, usually a URI</td>
-</tr>
-<tr>
-<td valign="top"> <tt><em>public</em></tt>
-</td>
-<td valign="top">The public identifier of the external entity</td>
-</tr>
-<tr>
-<td valign="top"> <tt><em>notation</em></tt>
-</td>
-<td valign="top">The name of the notation for the external entity</td>
-</tr>
-</table>
-</dd>
-<span class="term"> <em>-validate</em></span><dd>
-<p><tt>-validate</tt> <u><em>boolean</em></u></p>
-<p>Enables validation of the XML document to be parsed.  Any changes to this option are ignored after an XML document has started to be parsed, but the option may be changed after a reset.</p>
-</dd>
-<span class="term"> <em>-warningcommand</em></span><dd>
-<p><tt>-warningcommand</tt> <u><em>script</em></u></p>
-<p>Specifies the prefix of a Tcl command to be evaluated when a warning condition is detected.  A warning condition is where the XML document has not been authored correctly, but is still well-formed and may be valid.  For example, the special empty element syntax may be used for an element which has not been declared to have empty content.  By default, a callback script is provided which silently ignores the warning.  The command evaluated is:</p>
-<div class="cmdsynopsis" id="id21851">
-<a name="id21851"></a><tt><em>script</em></tt> <em>warningcode</em> <em>warningmsg</em>
-</div>
-<p>where:</p>
-<table border="0">
-<tr>
-<td valign="top"> <tt><em>warningcode</em></tt>
-</td>
-<td valign="top">A single word description of the warning, intended for use by an application</td>
-</tr>
-<tr>
-<td valign="top"> <tt><em>wanringmsg</em></tt>
-</td>
-<td valign="top">A human-readable description of the warning</td>
-</tr>
-</table>
-</dd>
-<span class="term"> <em>-xmldeclcommand</em></span><dd>
-<p><tt>-xmldeclcommand</tt> <u><em>script</em></u></p>
-<p>Specifies the prefix of a Tcl command to be evaluated when the XML declaration is encountered.  The command evaluated is:</p>
-<div class="cmdsynopsis" id="id21954">
-<a name="id21954"></a><tt><em>script</em></tt> <em>version</em> <em>encoding</em> <em>standalone</em>
-</div>
-<p>where:</p>
-<table border="0">
-<tr>
-<td valign="top"> <tt><em>version</em></tt>
-</td>
-<td valign="top">The version number of the XML specification to which this document purports to conform</td>
-</tr>
-<tr>
-<td valign="top"> <tt><em>encoding</em></tt>
-</td>
-<td valign="top">The character encoding of the document</td>
-</tr>
-<tr>
-<td valign="top"> <tt><em>standalone</em></tt>
-</td>
-<td valign="top">A boolean declaring whether the document is standalone</td>
-</tr>
-</table>
-</dd>
-</dl>
-</div>
-<div class="refsect3">
-<h4>
-<a name="id22051"></a>Parser Command</h4>
-<p>The <strong>::xml::parser</strong> command creates a new Tcl command with the same name as the parser.  This command may be used to invoke various operations on the parser object.  It has the following general form:</p>
-<div class="cmdsynopsis" id="id22075">
-<a name="id22075"></a><tt><em>name</em></tt>  <em><em>option</em></em><em>arg</em>
-</div>
-<p> <em><em>option</em></em> and the <span class="arg"><em>arg</em></span> determine the exact behaviour of the command.  The following commands are possible for parser objects:</p>
-<dl>
-<span class="term"> <em>cget</em></span><dd>
-<div class="cmdsynopsis" id="id22133">
-<a name="id22133"></a><tt><i>name</i></tt> <u>cget</u><em>-option</em>
-</div>
-<p>Returns the current value of the configuration option given by  <em><em>option</em></em>.   <em><em>Option</em></em> may have any of the values accepted by the parser object.</p>
-</dd>
-<span class="term"> <em>configure</em></span><dd>
-<div class="cmdsynopsis" id="id22177">
-<a name="id22177"></a><tt><i>name</i></tt> <u>configure</u> "<em>-option</em> <em>value</em>..."</div>
-<p>Modify the configuration options of the parser object.   <em><em>Option</em></em> may have any of the values accepted by the parser object.</p>
-</dd>
-<span class="term"> <em>entityparser</em></span><dd>
-<div class="cmdsynopsis" id="id22227">
-<a name="id22227"></a><tt><i>name</i></tt> <u>entityparser</u> "<em>option</em> <em>value</em>..."</div>
-<p>Creates a new parser object.  The new object inherits the same configuration options as the parent parser object, but is able to parse XML data in a parsed entity.  The option  <em>-dtdsubset</em> allows markup declarations to be treated as being in the internal or external DTD subset.</p>
-</dd>
-<span class="term"> <em>free</em></span><dd>
-<div class="cmdsynopsis" id="id22280">
-<a name="id22280"></a><tt><i>name</i></tt> <u>free</u><em>name</em>
-</div>
-<p>Frees all resources associated with the parser object.  The object is not usable after this command has been invoked.</p>
-</dd>
-<span class="term"> <em>get</em></span><dd>
-<div class="cmdsynopsis" id="id22315">
-<a name="id22315"></a><tt><i>name</i></tt> <u>get</u><em>name</em> args</div>
-<p>Returns information about the XML document being parsed.  Each parser class provides different information, see the documentation for the parser class.</p>
-</dd>
-<span class="term"> <em>parse</em></span><dd>
-<div class="cmdsynopsis" id="id22358">
-<a name="id22358"></a><tt><i>name</i></tt> <u>parse</u><em>xml</em> args</div>
-<p>Parses the XML document.  The usual desired effect is for various application callbacks to be evaluated.  Other functions will also be performed by the parser class, at the very least this includes checking the XML document for well-formedness.</p>
-</dd>
-<span class="term"> <em>reset</em></span><dd>
-<div class="cmdsynopsis" id="id22403">
-<a name="id22403"></a><tt><i>name</i></tt> <u>reset</u>
-</div>
-<p>Initialises the parser object in preparation for parsing a new XML document.</p>
-</dd>
-</dl>
-</div>
-</div>
-</div>
-<div class="refsect1">
-<h2>
-<a name="id22422"></a>Callback Return Codes</h2>
-<p>Every callback script evaluated by a parser may return a return code other than <span class="arg">TCL_OK</span>.  Return codes are interpreted as follows:</p>
-<table border="0">
-<tr>
-<td valign="top">break</td>
-<td valign="top">Suppresses invocation of all further callback scripts.  The  <em>parse</em> method returns the  <tt>TCL_OK</tt> return code.</td>
-</tr>
-<tr>
-<td valign="top">continue</td>
-<td valign="top">Suppresses invocation of further callback scripts until the current element has finished.</td>
-</tr>
-<tr>
-<td valign="top">error</td>
-<td valign="top">Suppresses invocation of all further callback scripts.  The  <em>parse</em> method also returns the  <tt>TCL_ERROR</tt> return code.</td>
-</tr>
-<tr>
-<td valign="top">default</td>
-<td valign="top">Any other return code suppresses invocation of all further callback scripts.  The  <em>parse</em> method returns the same return code.</td>
-</tr>
-</table>
-</div>
-<div class="refsect1">
-<h2>
-<a name="id22510"></a>Error Messages</h2>
-<p>If an error or warning condition is detected then an error message is returned.  These messages are structured as a Tcl list, as described below:</p>
-<div class="informalexample"><pre><div class="programlisting"><pre>{domain level code node line message int1 int2 string1 string2 string3}</pre></div></pre></div>
-<dl>
-<span class="term"><span class="literal">domain</span></span><dd><p>A code for the subsystem that detected the error.</p></dd>
-<span class="term"><span class="literal">level</span></span><dd><p>Severity level of the problem.</p></dd>
-<span class="term"><span class="literal">code</span></span><dd><p>A one word string describing the error.</p></dd>
-<span class="term"><span class="literal">node</span></span><dd><p>If available, the token of the DOM node associated with the problem.</p></dd>
-<span class="term"><span class="literal">line</span></span><dd><p>If known, the line number in the source XML document where the problem was detected.</p></dd>
-<span class="term"><span class="literal">message</span></span><dd><p>A human-readable description of the problem.</p></dd>
-<span class="term"><span class="literal">int1</span></span><dd><p>Additional integer data.  For the parser domain, this is usually the column number where the problem was detected.</p></dd>
-<span class="term"><span class="literal">int2</span></span><dd><p>Additional integer data.</p></dd>
-<span class="term"><span class="literal">string1</span></span><dd><p>Additional string data.</p></dd>
-<span class="term"><span class="literal">string2</span></span><dd><p>Additional string data.</p></dd>
-<span class="term"><span class="literal">string3</span></span><dd><p>Additional string data.</p></dd>
-</dl>
-</div>
-<div class="refsect1">
-<h2>
-<a name="id22728"></a>Application Examples</h2>
-<p>This script outputs the character data of an XML document read from stdin.</p>
-<div class="informalexample"><pre><div class="programlisting"><pre>
-package require xml
-
-proc cdata {data args} {
-    puts -nonewline $data
-}
-
-set parser [::xml::parser -characterdatacommand cdata]
-$parser parse [read stdin]
-      </pre></div></pre></div>
-<p>This script counts the number of elements in an XML document read from stdin.</p>
-<div class="informalexample"><pre><div class="programlisting"><pre>
-package require xml
-
-proc EStart {varName name attlist args} {
-    upvar #0 $varName var
-    incr var
-}
-
-set count 0
-set parser [::xml::parser -elementstartcommand [list EStart count]]
-$parser parse [read stdin]
-puts "The XML document contains $count elements"
-      </pre></div></pre></div>
-</div>
-<div class="refsect1">
-<h2>
-<a name="id22772"></a>Safe XML</h2>
-<p>TclXML/Tcl and TclXML/libxml2 may be used in a Safe Tcl interpreter.  When a document is parsed in a Safe Tcl interpreter, any attempt by the XML document to load an external entity is handled by the -externalentitycommand callback.  This callback is evaluated in the context of the safe interpreter and therefore is subject to the security policy in force for that interpreter.  The default entity loader will not be invoked, even if the callback script returns a <span class="literal">TCL_CONTINUE</span> code.</p>
-<p>See the description of the -externalentitycommand for further details.</p>
-</div>
-<div class="refsect1">
-<h2>
-<a name="id22797"></a>Parser Classes</h2>
-<p>This section will discuss how a parser class is implemented.</p>
-<div class="refsect2">
-<h3>
-<a name="id22814"></a>Tcl Parser Class</h3>
-<p>The pure-Tcl parser class requires no compilation - it is a collection of Tcl scripts.  This parser implementation is non-validating, ie. it can only check well-formedness in a document.  However, by enabling the  <em>-validate</em> option it will read the document's DTD and resolve external entities.  This parser class is referred to as TclXML/tcl.</p>
-<p>This parser implementation aims to implement XML v1.0 and supports XML Namespaces.</p>
-<p>Generally the parser produces XML Infoset information items.  That is, it gives the application a slightly higher-level view than the raw XML syntax.  For example, it does not report CDATA Sections.</p>
-<p>TclXML/tcl is not able to handle character encodings other than UTF-8.</p>
-</div>
-<div class="refsect2">
-<h3>
-<a name="id22857"></a>libxml2 Parser Class</h3>
-<p>The libxml2 parser class provides a Tcl interface to the libxml2 XML parser library.  This parser class is referred to as TclXML/libxml2.</p>
-<p>When the package is loaded the variable <span class="literal">::xml::libxml2::libxml2version</span> is set to the version number of the libxml2 library being used.</p>
-<p>On MS Windows, it is necessary to load the generic XML package first, and then the TclXML/libxml2 package.  For example,</p>
-<div class="informalexample"><pre><div class="programlisting"><pre>
-package require xml
-package require xml::libxml2
-</pre></div></pre></div>
-<div class="refsect3">
-<h4>
-<a name="id22898"></a>get Method</h4>
-<p>TclXML/libxml2 provides the following arguments to the get method:</p>
-<dl>
-<span class="term"><span class="arg">document</span></span><dd>
-<p>Returns the parsed document object.  libxml2 builds an in-memory data structure of the XML document it parses (a DOM tree).  This method returns a handle (or token) for that structure.</p>
-<p>TclXML/libxml2 manages the document object as a Tcl object.  See the  <em>-keep</em> for further information.</p>
-</dd>
-</dl>
-</div>
-<div class="refsect3">
-<h4>
-<a name="id22948"></a>Additional Options</h4>
-<dl>
-<span class="term"> <em>-keep</em></span><dd>
-<p><tt>-keep</tt> <u>normal | implicit</u></p>
-<p>Controls how the TclXML/libxml2 packages manages the document object.  The default value is <span class="literal">implicit</span>; the document is destroyed when the Tcl Object's internal representation is freed.  If the option is given the value <span class="literal">normal</span> then the document must be explicit destroyed.  The only way to explicitly destroy the document is by using the C API.</p>
-</dd>
-<span class="term"> <em>-retainpath</em></span><dd>
-<p><tt>-retainpath</tt> <u><em>xpath</em></u></p>
-<p>The given XPath location path specifies which part of the document is to be kept after the parsing operation has completed.  By default, all document data is discard after it has been parsed.</p>
-</dd>
-<span class="term"> <em>-retainpathns</em></span><dd>
-<p><tt>-retainpathns</tt> <u><em>prefix ns ...</em></u></p>
-<p>The value of this option is a list of pairs of XML Namespace prefixes and their corresponding namespace URIs.  These are used by the XPath location path given in the <span class="arg">-retainpath</span> option.</p>
-</dd>
-</dl>
-</div>
-<div class="refsect3">
-<h4>
-<a name="id23083"></a>Limitations</h4>
-<p>The libxml2 parser classes has the following limitations:</p>
-<ul>
-<li><p> <em>-reportempty</em> has no effect.  libxml2 does not report empty element syntax.</p></li>
-<li><p>Incremental (push) parsing, ie. <span class="arg"> <em>-final</em> <span class="literal">0</span></span> is not supported.</p></li>
-<li><p>TclXML/libxml2 does not provide (DTD) validation, (WXS) schema validation or Relax NG validation, although the libxml2 library does provide those functions.  These functions are provided by the TclDOM/libxml2 package, but only in a "posteriori" fashion (ie. only after the document has been parsed).</p></li>
-<li><p>libxml2 supports XML Namespaces.  The use of XML Namespaces can be queried, but the <em>declaration</em> of a XML Namespace is not reported.</p></li>
-</ul>
-</div>
-</div>
-</div>
-<div class="refsect1">
-<h2>
-<a name="id23155"></a>Keywords</h2>
-<div class="keywordset">XML, parse</div>
-</div>
-</div></body>
-</html>
-
diff --git a/tclxml-3.2/doc/tclxml.xml.in b/tclxml-3.2/doc/tclxml.xml.in
deleted file mode 100644
index 30ff877..0000000
--- a/tclxml-3.2/doc/tclxml.xml.in
+++ /dev/null
@@ -1,1862 +0,0 @@
-<!DOCTYPE refentry [
-  <!ENTITY version "@PACKAGE_VERSION@">
-]>
-<refentry xmlns="http://docbook.org/ns/docbook">
-  <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
-    <author xlink:href="http://www.explain.com.au/staff/Steve.Ball/">
-      <firstname>Steve</firstname>
-      <surname>Ball</surname>
-    </author>
-    <copyright>
-      <year>2007</year>
-      <year>2005</year>
-      <holder xlink:href="http://www.explain.com.au/">Explain</holder>
-    </copyright>
-    <copyright>
-      <year>2004</year>
-      <year>2003</year>
-      <year>2000</year>
-      <holder xlink:href="http://www.zveno.com/">Zveno Pty Ltd</holder>
-    </copyright>
-    <legalnotice>
-      <para>See the file "LICENSE" for information on usage and redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.</para>
-    </legalnotice>
-    <revhistory>
-      <revision>
-        <revnumber>3.2</revnumber>
-        <date>2007-12-11</date>
-        <authorinitials>SRB</authorinitials>
-        <revremark>Updated author details and legal notice.</revremark>
-      </revision>
-      <revision>
-        <revnumber>3.1</revnumber>
-        <date>2005-03-02</date>
-        <authorinitials>SRB</authorinitials>
-        <revremark>Updated details on -externalentitycommand callback.  Fixed minor typo.</revremark>
-      </revision>
-      <revision>
-        <revnumber>3.0</revnumber>
-        <date>2003-08-22</date>
-        <authorinitials>SRB</authorinitials>
-        <revremark>Added libxml2 parser class.</revremark>
-      </revision>
-    </revhistory>
-  </d:info>
-  <refmeta>
-    <refentrytitle>TclXML</refentrytitle>
-    <manvolnum>n</manvolnum>
-  </refmeta>
-  <refnamediv>
-    <refname>TclXML</refname>
-    <refpurpose>XML parser support for Tcl</refpurpose>
-  </refnamediv>
-  <refsynopsisdiv>
-    <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-      <command xmlns="http://docbook.org/ns/docbook">package require xml</command>
-    </cmdsynopsis>
-    <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-      <command xmlns="http://docbook.org/ns/docbook">package require <replaceable>parserclass</replaceable></command>
-    </cmdsynopsis>
-    <pkgsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-      <package xmlns="http://docbook.org/ns/docbook">xml</package>
-      <version xmlns="http://docbook.org/ns/docbook">&version;</version>
-    </pkgsynopsis>
-    <namespacesynopsis xmlns="http://tclxml.sourceforge.net/doc">
-      <namespace>::xml</namespace>
-      <namespace>::sgml</namespace>
-      <namespace>::xml::tclparser</namespace>
-      <namespace>::xml::libxml2</namespace>
-    </namespacesynopsis>
-    <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-      <command xmlns="http://docbook.org/ns/docbook">::xml::parserclass</command>
-      <option xmlns="http://docbook.org/ns/docbook">option</option>
-      <group xmlns="http://docbook.org/ns/docbook" choice="opt" rep="repeat">
-        <arg>arg</arg>
-        <arg>arg</arg>
-      </group>
-    </cmdsynopsis>
-    <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-      <command xmlns="http://docbook.org/ns/docbook">::xml::parser</command>
-      <group xmlns="http://docbook.org/ns/docbook" choice="opt">
-        <arg>
-          <replaceable>name</replaceable>
-        </arg>
-      </group>
-      <group xmlns="http://docbook.org/ns/docbook" choice="opt" rep="repeat">
-        <option>-option</option>
-        <arg>
-          <replaceable>value</replaceable>
-        </arg>
-      </group>
-    </cmdsynopsis>
-    <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-      <command xmlns="http://docbook.org/ns/docbook">
-        <replaceable>parser</replaceable>
-      </command>
-      <arg xmlns="http://docbook.org/ns/docbook">
-        <replaceable>option</replaceable>
-      </arg>
-      <arg xmlns="http://docbook.org/ns/docbook" rep="repeat" choice="opt">
-        <replaceable>arg</replaceable>
-      </arg>
-    </cmdsynopsis>
-  </refsynopsisdiv>
-  <refsect1>
-    <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
-      <d:title>Description</d:title>
-    </d:info>
-    <para>TclXML provides event-based parsing of <acronym xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="http://www.w3.org/XML/">XML</acronym> documents.  The application may register callback scripts for certain document features, and when the parser encounters those features while parsing the document the callback is evaluated.</para>
-    <para>The parser may also perform other functions, such as normalisation, validation and/or entity expansion.  Generally, these functions are under the control of configuration options.  Whether these functions can be performed at all depends on the parser implementation.</para>
-    <para>The TclXML package provides a generic interface for use by a Tcl application, along with a low-level interface for use by a parser implementation.  Each implementation provides a class of XML parser, and these register themselves using the <command xmlns="http://tclxml.sourceforge.net/doc">::xml::parserclass create</command> command.  One of the registered parser classes will be the default parser class.</para>
-    <para>Loading the package with the generic <command xmlns="http://tclxml.sourceforge.net/doc">package require xml</command> command allows the package to automatically determine the default parser class.  In order to select a particular parser class as the default, that class' package may be loaded directly, eg. <command xmlns="http://tclxml.sourceforge.net/doc">package require xml::libxml2</command>.  In all cases, all available parser classes are registered with the TclXML package, the difference is simply in which one becomes the default.</para>
-  </refsect1>
-  <refsect1>
-    <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
-      <d:title>Commands</d:title>
-    </d:info>
-    <refsect2>
-      <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
-        <d:title>
-          <command xmlns="http://tclxml.sourceforge.net/doc">::xml::parserclass</command>
-        </d:title>
-      </d:info>
-      <para>The <command xmlns="http://tclxml.sourceforge.net/doc">::xml::parserclass</command> command is used to manage XML parser classes.</para>
-      <refsect3>
-        <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
-          <d:title>Command Options</d:title>
-        </d:info>
-        <para>The following command options may be used:</para>
-        <variablelist>
-          <varlistentry>
-            <term>
-              <methodname>create</methodname>
-            </term>
-            <listitem>
-              <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <arg xmlns="http://docbook.org/ns/docbook">create</arg>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable class="parameter">name</replaceable>
-                </arg>
-                <group xmlns="http://docbook.org/ns/docbook" choice="opt">
-                  <option>-createcommand</option>
-                  <arg>
-                    <replaceable>script</replaceable>
-                  </arg>
-                </group>
-                <group xmlns="http://docbook.org/ns/docbook" choice="opt">
-                  <option>-createentityparsercommand</option>
-                  <arg>
-                    <replaceable>script</replaceable>
-                  </arg>
-                </group>
-                <group xmlns="http://docbook.org/ns/docbook" choice="opt">
-                  <option>-parsecommand</option>
-                  <arg>
-                    <replaceable>script</replaceable>
-                  </arg>
-                </group>
-                <group xmlns="http://docbook.org/ns/docbook" choice="opt">
-                  <option>-configurecommand</option>
-                  <arg>
-                    <replaceable>script</replaceable>
-                  </arg>
-                </group>
-                <group xmlns="http://docbook.org/ns/docbook" choice="opt">
-                  <option>-getcommand</option>
-                  <arg>
-                    <replaceable>script</replaceable>
-                  </arg>
-                </group>
-                <group xmlns="http://docbook.org/ns/docbook" choice="opt">
-                  <option>-deletecommand</option>
-                  <arg>
-                    <replaceable>script</replaceable>
-                  </arg>
-                </group>
-              </cmdsynopsis>
-              <para>Creates an XML parser class with the given name.</para>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <methodname>destroy</methodname>
-            </term>
-            <listitem>
-              <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <arg xmlns="http://docbook.org/ns/docbook">destroy</arg>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>name</replaceable>
-                </arg>
-              </cmdsynopsis>
-              <para>Destroys an XML parser class.</para>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <methodname>info</methodname>
-            </term>
-            <listitem>
-              <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">info</option>
-                <group xmlns="http://docbook.org/ns/docbook" choice="req">
-                  <arg>names</arg>
-                  <arg>default</arg>
-                </group>
-              </cmdsynopsis>
-              <para>Returns information about registered XML parser classes.</para>
-            </listitem>
-          </varlistentry>
-        </variablelist>
-      </refsect3>
-    </refsect2>
-    <refsect2>
-      <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
-        <d:title>
-          <command xmlns="http://tclxml.sourceforge.net/doc">::xml::parser</command>
-        </d:title>
-      </d:info>
-      <para>The <command xmlns="http://tclxml.sourceforge.net/doc">::xml::parser</command> command creates an <acronym>XML</acronym> parser object.  The return value of the command is the name of the newly created parser.</para>
-      <para>The parser scans an XML document's syntactical structure, evaluating callback scripts for each feature found.  At the very least the parser will normalise the document and check the document for well-formedness.  If the document is not well-formed then the <option>-errorcommand</option> option will be evaluated.  Some parser classes may perform additional functions, such as validation.  Additional features provided by the various parser classes are described in the section Parser Classes</para>
-      <para>Parsing is performed synchronously.  The command blocks until the entire document has been parsed.  Parsing may be terminated by an application callback, see the section Callback Return Codes.  Incremental parsing is also supported by using the <option>-final</option> configuration option.</para>
-      <refsect3>
-        <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
-          <d:title>Configuration Options</d:title>
-        </d:info>
-        <para>The <command xmlns="http://tclxml.sourceforge.net/doc">::xml::parser</command> command accepts the following configuration options:</para>
-        <variablelist>
-          <varlistentry>
-            <term>
-              <option>-attlistdeclcommand</option>
-            </term>
-            <listitem>
-              <optionsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">-attlistdeclcommand</option>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </arg>
-              </optionsynopsis>
-              <para>Specifies the prefix of a Tcl command to be evaluated whenever an attribute list declaration is encountered in the DTD subset of an XML document.  The command evaluated is:</para>
-              <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <command xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </command>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>name</replaceable>
-                </arg>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>attrname</replaceable>
-                </arg>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>type</replaceable>
-                </arg>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>default</replaceable>
-                </arg>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>value</replaceable>
-                </arg>
-              </cmdsynopsis>
-              <para>where:</para>
-              <segmentedlist>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>name</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>Element type name</seg>
-                </seglistitem>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>attrname</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>Attribute name being declared</seg>
-                </seglistitem>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>type</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>Attribute type</seg>
-                </seglistitem>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>default</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>Attribute default, such as #IMPLIED</seg>
-                </seglistitem>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>value</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>Default attribute value.  Empty string if none given.</seg>
-                </seglistitem>
-              </segmentedlist>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <option>-baseuri</option>
-            </term>
-            <term>
-              <option>-baseurl</option>
-            </term>
-            <listitem>
-              <optionsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">-baseuri</option>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>URI</replaceable>
-                </arg>
-              </optionsynopsis>
-              <optionsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">-baseurl</option>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>URI</replaceable>
-                </arg>
-              </optionsynopsis>
-              <para>Specifies the base URI for resolving relative URIs that may be used in the XML document to refer to external entities.</para>
-              <para><option>-baseurl</option> is deprecated in favour of <option>-baseuri</option>.</para>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <option>-characterdatacommand</option>
-            </term>
-            <listitem>
-              <optionsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">-characterdatacommand</option>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </arg>
-              </optionsynopsis>
-              <para>Specifies the prefix of a Tcl command to be evaluated whenever character data is encountered in the XML document being parsed.  The command evaluated is:</para>
-              <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <command xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </command>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>data</replaceable>
-                </arg>
-              </cmdsynopsis>
-              <para>where:</para>
-              <segmentedlist>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>data</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>Character data in the document</seg>
-                </seglistitem>
-              </segmentedlist>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <option>-commentcommand</option>
-            </term>
-            <listitem>
-              <optionsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">-commentcommand</option>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </arg>
-              </optionsynopsis>
-              <para>Specifies the prefix of a Tcl command to be evaluated whenever a comment is encountered in the XML document being parsed.  The command evaluated is:</para>
-              <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <command xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </command>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>data</replaceable>
-                </arg>
-              </cmdsynopsis>
-              <para>where:</para>
-              <segmentedlist>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>data</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>Comment data</seg>
-                </seglistitem>
-              </segmentedlist>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <option>-defaultcommand</option>
-            </term>
-            <listitem>
-              <optionsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">-defaultcommand</option>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </arg>
-              </optionsynopsis>
-              <para>Specifies the prefix of a Tcl command to be evaluated when no other callback has been defined for a document feature which has been encountered.  The command evaluated is:</para>
-              <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <command xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </command>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>data</replaceable>
-                </arg>
-              </cmdsynopsis>
-              <para>where:</para>
-              <segmentedlist>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>data</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>Document data</seg>
-                </seglistitem>
-              </segmentedlist>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <option>-defaultexpandinternalentities</option>
-            </term>
-            <listitem>
-              <optionsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">-defaultexpandinternalentities</option>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>boolean</replaceable>
-                </arg>
-              </optionsynopsis>
-              <para>Specifies whether entities declared in the internal DTD subset are expanded with their replacement text.  If entities are not expanded then the entity references will be reported with no expansion.</para>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <option>-doctypecommand</option>
-            </term>
-            <listitem>
-              <optionsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">-doctypecommand</option>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </arg>
-              </optionsynopsis>
-              <para>Specifies the prefix of a Tcl command to be evaluated when the document type declaration is encountered.  The command evaluated is:</para>
-              <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <command xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </command>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>name</replaceable>
-                </arg>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>public</replaceable>
-                </arg>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>system</replaceable>
-                </arg>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>dtd</replaceable>
-                </arg>
-              </cmdsynopsis>
-              <para>where:</para>
-              <segmentedlist>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>name</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>The name of the document element</seg>
-                </seglistitem>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>public</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>Public identifier for the external DTD subset</seg>
-                </seglistitem>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>system</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>System identifier for the external DTD subset.  Usually a URI.</seg>
-                </seglistitem>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>dtd</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>The internal DTD subset</seg>
-                </seglistitem>
-              </segmentedlist>
-              <para>See also <option>-startdoctypedeclcommand</option> and <option>-enddoctypedeclcommand</option>.</para>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <option>-elementdeclcommand</option>
-            </term>
-            <listitem>
-              <optionsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">-elementdeclcommand</option>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </arg>
-              </optionsynopsis>
-              <para>Specifies the prefix of a Tcl command to be evaluated when an element markup declaration is encountered.  The command evaluated is:</para>
-              <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <command xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </command>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>name</replaceable>
-                </arg>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>model</replaceable>
-                </arg>
-              </cmdsynopsis>
-              <para>where:</para>
-              <segmentedlist>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>name</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>The element type name</seg>
-                </seglistitem>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>model</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>Content model specification</seg>
-                </seglistitem>
-              </segmentedlist>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <option>-elementendcommand</option>
-            </term>
-            <listitem>
-              <optionsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">-elementendcommand</option>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </arg>
-              </optionsynopsis>
-              <para>Specifies the prefix of a Tcl command to be evaluated when an element end tag is encountered.  The command evaluated is:</para>
-              <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <command xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </command>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>name</replaceable>
-                </arg>
-                <arg xmlns="http://docbook.org/ns/docbook" choice="opt">
-                  <replaceable>args</replaceable>
-                </arg>
-              </cmdsynopsis>
-              <para>where:</para>
-              <segmentedlist>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>name</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>The element type name that has ended</seg>
-                </seglistitem>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>args</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>Additional information about this element</seg>
-                </seglistitem>
-              </segmentedlist>
-              <para>Additional information about the element takes the form of configuration options.  Possible options are:</para>
-              <segmentedlist>
-                <seglistitem>
-                  <seg>
-                    <option>-empty</option>
-                    <arg>
-                      <replaceable>boolean</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>The empty element syntax was used for this element</seg>
-                </seglistitem>
-                <seglistitem>
-                  <seg>
-                    <option>-namespace</option>
-                    <arg>
-                      <replaceable>uri</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>The element is in the XML namespace associated with the given URI</seg>
-                </seglistitem>
-              </segmentedlist>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <option>-elementstartcommand</option>
-            </term>
-            <listitem>
-              <optionsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">-elementstartcommand</option>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </arg>
-              </optionsynopsis>
-              <para>Specifies the prefix of a Tcl command to be evaluated when an element start tag is encountered.  The command evaluated is:</para>
-              <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <command xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </command>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>name</replaceable>
-                </arg>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>attlist</replaceable>
-                </arg>
-                <arg xmlns="http://docbook.org/ns/docbook" choice="opt">
-                  <replaceable>args</replaceable>
-                </arg>
-              </cmdsynopsis>
-              <para>where:</para>
-              <segmentedlist>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>name</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>The element type name that has started</seg>
-                </seglistitem>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>attlist</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>A Tcl list containing the attributes for this element.  The list of attributes is formatted as pairs of attribute names and their values.  </seg>
-                </seglistitem>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>args</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>Additional information about this element</seg>
-                </seglistitem>
-              </segmentedlist>
-              <para>Additional information about the element takes the form of configuration options.  Possible options are:</para>
-              <segmentedlist>
-                <seglistitem>
-                  <seg>
-                    <option>-empty</option>
-                    <arg>
-                      <replaceable>boolean</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>The empty element syntax was used for this element</seg>
-                </seglistitem>
-                <seglistitem>
-                  <seg>
-                    <option>-namespace</option>
-                    <arg>
-                      <replaceable>uri</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>The element is in the XML namespace associated with the given URI</seg>
-                </seglistitem>
-                <seglistitem>
-                  <seg>
-                    <option>-namespacedecls</option>
-                    <arg>
-                      <replaceable>list</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>The start tag included one or more XML Namespace declarations.  <arg><replaceable>list</replaceable></arg> is a Tcl list giving the namespaces declared.  The list is formatted as pairs of values, the first value is the namespace URI and the second value is the prefix used for the namespace in this document.  A default XML namespace declaration will have an empty string for the prefix.</seg>
-                </seglistitem>
-              </segmentedlist>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <option>-encoding</option>
-            </term>
-            <listitem>
-              <optionsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">-encoding</option>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>value</replaceable>
-                </arg>
-              </optionsynopsis>
-              <para>Gives the character encoding of the document.  This option only has an effect before a document is parsed.  The default character encoding is <literal>utf-8</literal>.  If the value <literal>unknown</literal> is given, or any value other than <literal>utf-8</literal>, then the document text is treated as binary data.  If the value is given as <literal>unknown</literal> then the parser will attempt to automatically determine the character encoding of the document (using byte-order-marks, etc).  If any value other than <literal>utf-8</literal> or <literal>unknown</literal> is given then the parser will read the document text using that character encoding.</para>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <option>-endcdatasectioncommand</option>
-            </term>
-            <listitem>
-              <optionsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">-endcdatasectioncommand</option>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </arg>
-              </optionsynopsis>
-              <para>Specifies the prefix of a Tcl command to be evaluated when end of a CDATA section is encountered.  The command is evaluated with no further arguments.</para>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <option>-enddoctypedeclcommand</option>
-            </term>
-            <listitem>
-              <optionsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">-enddoctypedeclcommand</option>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </arg>
-              </optionsynopsis>
-              <para>Specifies the prefix of a Tcl command to be evaluated when end of the document type declaration is encountered.  The command is evaluated with no further arguments.</para>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <option>-entitydeclcommand</option>
-            </term>
-            <listitem>
-              <optionsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">-entitydeclcommand</option>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </arg>
-              </optionsynopsis>
-              <para>Specifies the prefix of a Tcl command to be evaluated when an entity declaration is encountered.  The command evaluated is:</para>
-              <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <command xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </command>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>name</replaceable>
-                </arg>
-                <arg xmlns="http://docbook.org/ns/docbook" choice="opt" repeat="rep">
-                  <replaceable>args</replaceable>
-                </arg>
-              </cmdsynopsis>
-              <para>where:</para>
-              <segmentedlist>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>name</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>The name of the entity being declared</seg>
-                </seglistitem>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>args</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>Additional information about the entity declaration.  An internal entity shall have a single argument, the replacement text.  An external parsed entity shall have two additional arguments, the public and system indentifiers of the external resource.  An external unparsed entity shall have three additional arguments, the public and system identifiers followed by the notation name.</seg>
-                </seglistitem>
-              </segmentedlist>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <option>-entityreferencecommand</option>
-            </term>
-            <listitem>
-              <optionsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">-entityreferencecommand</option>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </arg>
-              </optionsynopsis>
-              <para>Specifies the prefix of a Tcl command to be evaluated when an entity reference is encountered.  The command evaluated is:</para>
-              <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <command xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </command>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>name</replaceable>
-                </arg>
-              </cmdsynopsis>
-              <para>where:</para>
-              <segmentedlist>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>name</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>The name of the entity being referenced</seg>
-                </seglistitem>
-              </segmentedlist>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <option>-errorcommand</option>
-            </term>
-            <listitem>
-              <optionsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">-errorcommand</option>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </arg>
-              </optionsynopsis>
-              <para>Specifies the prefix of a Tcl command to be evaluated when a fatal error is detected.  The error may be due to the XML document not being well-formed.  In the case of a validating parser class, the error may also be due to the XML document not obeying validity constraints.  By default, a callback script is provided which causes an error return code, but an application may supply a script which attempts to continue parsing.  The command evaluated is:</para>
-              <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <command xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </command>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>errorcode</replaceable>
-                </arg>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>errormsg</replaceable>
-                </arg>
-              </cmdsynopsis>
-              <para>where:</para>
-              <segmentedlist>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>errorcode</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>A single word description of the error, intended for use by an application</seg>
-                </seglistitem>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>errormsg</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>A human-readable description of the error</seg>
-                </seglistitem>
-              </segmentedlist>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <option>-externalentitycommand</option>
-            </term>
-            <listitem>
-              <optionsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">-externalentitycommand</option>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </arg>
-              </optionsynopsis>
-              <para>Specifies the prefix of a Tcl command to be evaluated to resolve an external entity reference.  If the parser has been configured to validate the XML document, a default script is supplied that resolves the URI given as the system identifier of the external entity and recursively parses the entity's data.  If the parser has been configured as a non-validating parser, then by default external entities are not resolved.  This option can be used to override the default behaviour.  The command evaluated is:</para>
-              <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <command xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </command>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>name</replaceable>
-                </arg>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>baseuri</replaceable>
-                </arg>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>uri</replaceable>
-                </arg>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>id</replaceable>
-                </arg>
-              </cmdsynopsis>
-              <para>where:</para>
-              <segmentedlist>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>name</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>The Tcl command name of the current parser</seg>
-                </seglistitem>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>baseuri</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>An absolute URI for the current entity which is to be used to resolve relative URIs</seg>
-                </seglistitem>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>uri</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>The system identifier of the external entity, usually a URI</seg>
-                </seglistitem>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>id</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>The public identifier of the external entity.  If no public identifier was given in the entity declaration then <arg><replaceable>id</replaceable></arg> will be an empty string.</seg>
-                </seglistitem>
-              </segmentedlist>
-              <para>The return result of the callback script determines the action of the parser.  Note that these codes are interpreted in a different manner to other callbacks.</para>
-              <variablelist>
-                <varlistentry>
-                  <term>
-                    <literal>TCL_OK</literal>
-                  </term>
-                  <listitem>
-                    <para>The return result of the callback script is used as the external entity's data.  The URI passed to the callback script is used as the entity's base URI.</para>
-                    <para>This is useful to either override the normal loading of an entity's data, or to implement new or alternative URI schemes.  As an example, the script below sets an external entity handler that intercepts "tcl:" URIs and evaluates them as inline Tcl scripts:</para>
-                    <informalexample>
-                      <programlisting>
-package require xml
-
-proc External {name baseuri uri id} {
-    switch -glob -- $uri {
-	tcl:* {
-	    regexp {^tcl:(.*)$} $uri discard script
-	    return [uplevel #0 $script]
-	}
-	default {
-	    return -code continue {}
-	}
-    }
-}
-
-set parser [xml::parser -externalentitycommand External]
-$parser parse {<!DOCTYPE example [
-  <!ENTITY example SYSTEM "tcl:set%20example%20HelloWorld">
-]>
-<example>
-  &example;
-</example>
-}
-
-puts $example
-</programlisting>
-                    </informalexample>
-                    <para>This script will print "HelloWorld" to stdout.</para>
-                  </listitem>
-                </varlistentry>
-                <varlistentry>
-                  <term>
-                    <literal>TCL_CONTINUE</literal>
-                  </term>
-                  <listitem>
-                    <para>In a normal (non-safe) interpreter, the default external entity handler is used to load the external entity data as per normal operation of the parser.  If the parser is executing in a Safe Tcl interpreter then the entity is not loaded at all.</para>
-                    <para>This is useful to interpose on the loading of external entities without interfering with the loading of entities.</para>
-                  </listitem>
-                </varlistentry>
-                <varlistentry>
-                  <term>
-                    <literal>TCL_BREAK</literal>
-                  </term>
-                  <listitem>
-                    <para>No data is returned for this entity, ie. the entity is ignored.  No error is propagated.</para>
-                  </listitem>
-                </varlistentry>
-                <varlistentry>
-                  <term>
-                    <literal>TCL_ERROR</literal>
-                  </term>
-                  <listitem>
-                    <para>No data is returned for this entity, ie. the entity is ignored.  A background error is registered, using the result of the callback script.</para>
-                  </listitem>
-                </varlistentry>
-              </variablelist>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <option>-final</option>
-            </term>
-            <listitem>
-              <optionsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">-final</option>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>boolean</replaceable>
-                </arg>
-              </optionsynopsis>
-              <para>Specifies whether the XML document being parsed is complete.  If the document is to be incrementally parsed then this option will be set to false, and when the last fragment of document is parsed it is set to true.  For example,</para>
-              <informalexample>
-                <programlisting>
-set parser [::xml::parser -final 0]
-$parser parse $data1
-.
-.
-.
-$parser parse $data2
-.
-.
-.
-$parser configure -final 1
-$parser parse $finaldata
-		</programlisting>
-              </informalexample>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <option>-ignorewhitespace</option>
-            </term>
-            <listitem>
-              <optionsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">-ignorewhitespace</option>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>boolean</replaceable>
-                </arg>
-              </optionsynopsis>
-              <para>If this option is set to true then spans of character data in the XML document which are composed only of white-space (CR, LF, space, tab) will not be reported to the application.  In other words, the data passed to every invocation of the <option>-characterdatacommand</option> script will contain at least one non-white-space character.</para>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <option>-notationdeclcommand</option>
-            </term>
-            <listitem>
-              <optionsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">-notationdeclcommand</option>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </arg>
-              </optionsynopsis>
-              <para>Specifies the prefix of a Tcl command to be evaluated when a notation declaration is encountered.  The command evaluated is:</para>
-              <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <command xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </command>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>name</replaceable>
-                </arg>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>uri</replaceable>
-                </arg>
-              </cmdsynopsis>
-              <para>where:</para>
-              <segmentedlist>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>name</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>The name of the notation</seg>
-                </seglistitem>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>uri</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>An external identifier for the notation, usually a URI.</seg>
-                </seglistitem>
-              </segmentedlist>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <option>-notstandalonecommand</option>
-            </term>
-            <listitem>
-              <optionsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">-notstandalonecommand</option>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </arg>
-              </optionsynopsis>
-              <para>Specifies the prefix of a Tcl command to be evaluated when the parser determines that the XML document being parsed is not a standalone document.</para>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <option>-paramentityparsing</option>
-            </term>
-            <listitem>
-              <optionsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">-paramentityparsing</option>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>boolean</replaceable>
-                </arg>
-              </optionsynopsis>
-              <para>Controls whether external parameter entities are parsed.</para>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <option>-parameterentitydeclcommand</option>
-            </term>
-            <listitem>
-              <optionsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">-parameterentitydeclcommand</option>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </arg>
-              </optionsynopsis>
-              <para>Specifies the prefix of a Tcl command to be evaluated when a parameter entity declaration is encountered.  The command evaluated is:</para>
-              <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <command xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </command>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>name</replaceable>
-                </arg>
-                <arg xmlns="http://docbook.org/ns/docbook" choice="opt">
-                  <replaceable>args</replaceable>
-                </arg>
-              </cmdsynopsis>
-              <para>where:</para>
-              <segmentedlist>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>name</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>The name of the parameter entity</seg>
-                </seglistitem>
-                <seglistitem>
-                  <seg>
-                    <arg choice="opt">
-                      <replaceable>args</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>For an internal parameter entity there is only one additional argument, the replacement text.  For external parameter entities there are two additional arguments, the system and public identifiers respectively.</seg>
-                </seglistitem>
-              </segmentedlist>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <option>-parser</option>
-            </term>
-            <listitem>
-              <optionsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">-parser</option>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>name</replaceable>
-                </arg>
-              </optionsynopsis>
-              <para>The name of the parser class to instantiate for this parser object.  This option may only be specified when the parser instance is created.</para>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <option>-processinginstructioncommand</option>
-            </term>
-            <listitem>
-              <optionsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">-processinginstructioncommand</option>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </arg>
-              </optionsynopsis>
-              <para>Specifies the prefix of a Tcl command to be evaluated when a processing instruction is encountered.  The command evaluated is:</para>
-              <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <command xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </command>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>target</replaceable>
-                </arg>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>data</replaceable>
-                </arg>
-              </cmdsynopsis>
-              <para>where:</para>
-              <segmentedlist>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>target</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>The name of the processing instruction target</seg>
-                </seglistitem>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>data</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>Remaining data from the processing instruction</seg>
-                </seglistitem>
-              </segmentedlist>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <option>-reportempty</option>
-            </term>
-            <listitem>
-              <optionsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">-reportempty</option>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>boolean</replaceable>
-                </arg>
-              </optionsynopsis>
-              <para>If this option is enabled then when an element is encountered that uses the special empty element syntax, additional arguments are appended to the <option>-elementstartcommand</option> and <option>-elementendcommand</option> callbacks.  The arguments <arg>-empty 1</arg> are appended.  For example:</para>
-              <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <command xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </command>
-                <option xmlns="http://docbook.org/ns/docbook">-empty</option>
-                <arg xmlns="http://docbook.org/ns/docbook">1</arg>
-              </cmdsynopsis>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <option>-startcdatasectioncommand</option>
-            </term>
-            <listitem>
-              <optionsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">-startcdatasectioncommand</option>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </arg>
-              </optionsynopsis>
-              <para>Specifies the prefix of a Tcl command to be evaluated when the start of a CDATA section section is encountered.  No arguments are appended to the script.</para>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <option>-startdoctypedeclcommand</option>
-            </term>
-            <listitem>
-              <optionsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">-startdoctypedeclcommand</option>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </arg>
-              </optionsynopsis>
-              <para>Specifies the prefix of a Tcl command to be evaluated at the start of a document type declaration.  No arguments are appended to the script.</para>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <option>-unknownencodingcommand</option>
-            </term>
-            <listitem>
-              <optionsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">-unknownencodingcommand</option>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </arg>
-              </optionsynopsis>
-              <para>Specifies the prefix of a Tcl command to be evaluated when a character is encountered with an unknown encoding.  This option has not been implemented.</para>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <option>-unparsedentitydeclcommand</option>
-            </term>
-            <listitem>
-              <optionsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">-unparsedentitydeclcommand</option>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </arg>
-              </optionsynopsis>
-              <para>Specifies the prefix of a Tcl command to be evaluated when a declaration is encountered for an unparsed entity.  The command evaluated is:</para>
-              <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <command xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </command>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>system</replaceable>
-                </arg>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>public</replaceable>
-                </arg>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>notation</replaceable>
-                </arg>
-              </cmdsynopsis>
-              <para>where:</para>
-              <segmentedlist>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>system</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>The system identifier of the external entity, usually a URI</seg>
-                </seglistitem>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>public</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>The public identifier of the external entity</seg>
-                </seglistitem>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>notation</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>The name of the notation for the external entity</seg>
-                </seglistitem>
-              </segmentedlist>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <option>-validate</option>
-            </term>
-            <listitem>
-              <optionsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">-validate</option>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>boolean</replaceable>
-                </arg>
-              </optionsynopsis>
-              <para>Enables validation of the XML document to be parsed.  Any changes to this option are ignored after an XML document has started to be parsed, but the option may be changed after a reset.</para>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <option>-warningcommand</option>
-            </term>
-            <listitem>
-              <optionsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">-warningcommand</option>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </arg>
-              </optionsynopsis>
-              <para>Specifies the prefix of a Tcl command to be evaluated when a warning condition is detected.  A warning condition is where the XML document has not been authored correctly, but is still well-formed and may be valid.  For example, the special empty element syntax may be used for an element which has not been declared to have empty content.  By default, a callback script is provided which silently ignores the warning.  The command evaluated is:</para>
-              <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <command xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </command>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>warningcode</replaceable>
-                </arg>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>warningmsg</replaceable>
-                </arg>
-              </cmdsynopsis>
-              <para>where:</para>
-              <segmentedlist>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>warningcode</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>A single word description of the warning, intended for use by an application</seg>
-                </seglistitem>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>wanringmsg</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>A human-readable description of the warning</seg>
-                </seglistitem>
-              </segmentedlist>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <option>-xmldeclcommand</option>
-            </term>
-            <listitem>
-              <optionsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">-xmldeclcommand</option>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </arg>
-              </optionsynopsis>
-              <para>Specifies the prefix of a Tcl command to be evaluated when the XML declaration is encountered.  The command evaluated is:</para>
-              <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <command xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>script</replaceable>
-                </command>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>version</replaceable>
-                </arg>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>encoding</replaceable>
-                </arg>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>standalone</replaceable>
-                </arg>
-              </cmdsynopsis>
-              <para>where:</para>
-              <segmentedlist>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>version</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>The version number of the XML specification to which this document purports to conform</seg>
-                </seglistitem>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>encoding</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>The character encoding of the document</seg>
-                </seglistitem>
-                <seglistitem>
-                  <seg>
-                    <arg>
-                      <replaceable>standalone</replaceable>
-                    </arg>
-                  </seg>
-                  <seg>A boolean declaring whether the document is standalone</seg>
-                </seglistitem>
-              </segmentedlist>
-            </listitem>
-          </varlistentry>
-        </variablelist>
-      </refsect3>
-      <refsect3>
-        <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
-          <d:title>Parser Command</d:title>
-        </d:info>
-        <para>The <command xmlns="http://tclxml.sourceforge.net/doc">::xml::parser</command> command creates a new Tcl command with the same name as the parser.  This command may be used to invoke various operations on the parser object.  It has the following general form:</para>
-        <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-          <command xmlns="http://docbook.org/ns/docbook" role="subject">
-            <replaceable>name</replaceable>
-          </command>
-          <option xmlns="http://docbook.org/ns/docbook">
-            <replaceable>option</replaceable>
-          </option>
-          <arg xmlns="http://docbook.org/ns/docbook" rep="repeat">
-            <replaceable>arg</replaceable>
-          </arg>
-        </cmdsynopsis>
-        <para><option><replaceable>option</replaceable></option> and the <arg rep="repeat"><replaceable>arg</replaceable></arg> determine the exact behaviour of the command.  The following commands are possible for parser objects:</para>
-        <variablelist>
-          <varlistentry>
-            <term>
-              <option>cget</option>
-            </term>
-            <listitem>
-              <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">cget</option>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>-option</replaceable>
-                </arg>
-              </cmdsynopsis>
-              <para>Returns the current value of the configuration option given by <option><replaceable>option</replaceable></option>.  <option><replaceable>Option</replaceable></option> may have any of the values accepted by the parser object.</para>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <option>configure</option>
-            </term>
-            <listitem>
-              <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">configure</option>
-                <group xmlns="http://docbook.org/ns/docbook" rep="repeat">
-                  <arg>
-                    <replaceable>-option</replaceable>
-                  </arg>
-                  <arg>
-                    <replaceable>value</replaceable>
-                  </arg>
-                </group>
-              </cmdsynopsis>
-              <para>Modify the configuration options of the parser object.  <option><replaceable>Option</replaceable></option> may have any of the values accepted by the parser object.</para>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <option>entityparser</option>
-            </term>
-            <listitem>
-              <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">entityparser</option>
-                <group xmlns="http://docbook.org/ns/docbook" rep="repeat">
-                  <arg>
-                    <replaceable>option</replaceable>
-                  </arg>
-                  <arg>
-                    <replaceable>value</replaceable>
-                  </arg>
-                </group>
-              </cmdsynopsis>
-              <para>Creates a new parser object.  The new object inherits the same configuration options as the parent parser object, but is able to parse XML data in a parsed entity.  The option <option>-dtdsubset</option> allows markup declarations to be treated as being in the internal or external DTD subset.</para>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <option>free</option>
-            </term>
-            <listitem>
-              <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">free</option>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>name</replaceable>
-                </arg>
-              </cmdsynopsis>
-              <para>Frees all resources associated with the parser object.  The object is not usable after this command has been invoked.</para>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <option>get</option>
-            </term>
-            <listitem>
-              <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">get</option>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>name</replaceable>
-                </arg>
-                <arg xmlns="http://docbook.org/ns/docbook" rep="repeat" choice="opt">args</arg>
-              </cmdsynopsis>
-              <para>Returns information about the XML document being parsed.  Each parser class provides different information, see the documentation for the parser class.</para>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <option>parse</option>
-            </term>
-            <listitem>
-              <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">parse</option>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>xml</replaceable>
-                </arg>
-                <arg xmlns="http://docbook.org/ns/docbook" rep="repeat" choice="opt">args</arg>
-              </cmdsynopsis>
-              <para>Parses the XML document.  The usual desired effect is for various application callbacks to be evaluated.  Other functions will also be performed by the parser class, at the very least this includes checking the XML document for well-formedness.</para>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <option>reset</option>
-            </term>
-            <listitem>
-              <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">reset</option>
-              </cmdsynopsis>
-              <para>Initialises the parser object in preparation for parsing a new XML document.</para>
-            </listitem>
-          </varlistentry>
-        </variablelist>
-      </refsect3>
-    </refsect2>
-  </refsect1>
-  <refsect1>
-    <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
-      <d:title>Callback Return Codes</d:title>
-    </d:info>
-    <para>Every callback script evaluated by a parser may return a return code other than <arg>TCL_OK</arg>.  Return codes are interpreted as follows:</para>
-    <segmentedlist>
-      <seglistitem>
-        <seg>break</seg>
-        <seg>Suppresses invocation of all further callback scripts.  The <option>parse</option> method returns the <arg>TCL_OK</arg> return code.</seg>
-      </seglistitem>
-      <seglistitem>
-        <seg>continue</seg>
-        <seg>Suppresses invocation of further callback scripts until the current element has finished.</seg>
-      </seglistitem>
-      <seglistitem>
-        <seg>error</seg>
-        <seg>Suppresses invocation of all further callback scripts.  The <option>parse</option> method also returns the <arg>TCL_ERROR</arg> return code.</seg>
-      </seglistitem>
-      <seglistitem>
-        <seg>default</seg>
-        <seg>Any other return code suppresses invocation of all further callback scripts.  The <option>parse</option> method returns the same return code.</seg>
-      </seglistitem>
-    </segmentedlist>
-  </refsect1>
-  <refsect1>
-    <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
-      <d:title>Error Messages</d:title>
-    </d:info>
-    <para>If an error or warning condition is detected then an error message is returned.  These messages are structured as a Tcl list, as described below:</para>
-    <informalexample>
-      <programlisting>{domain level code node line message int1 int2 string1 string2 string3}</programlisting>
-    </informalexample>
-    <variablelist>
-      <varlistentry>
-        <term>
-          <literal>domain</literal>
-        </term>
-        <listitem>
-          <para>A code for the subsystem that detected the error.</para>
-        </listitem>
-      </varlistentry>
-      <varlistentry>
-        <term>
-          <literal>level</literal>
-        </term>
-        <listitem>
-          <para>Severity level of the problem.</para>
-        </listitem>
-      </varlistentry>
-      <varlistentry>
-        <term>
-          <literal>code</literal>
-        </term>
-        <listitem>
-          <para>A one word string describing the error.</para>
-        </listitem>
-      </varlistentry>
-      <varlistentry>
-        <term>
-          <literal>node</literal>
-        </term>
-        <listitem>
-          <para>If available, the token of the DOM node associated with the problem.</para>
-        </listitem>
-      </varlistentry>
-      <varlistentry>
-        <term>
-          <literal>line</literal>
-        </term>
-        <listitem>
-          <para>If known, the line number in the source XML document where the problem was detected.</para>
-        </listitem>
-      </varlistentry>
-      <varlistentry>
-        <term>
-          <literal>message</literal>
-        </term>
-        <listitem>
-          <para>A human-readable description of the problem.</para>
-        </listitem>
-      </varlistentry>
-      <varlistentry>
-        <term>
-          <literal>int1</literal>
-        </term>
-        <listitem>
-          <para>Additional integer data.  For the parser domain, this is usually the column number where the problem was detected.</para>
-        </listitem>
-      </varlistentry>
-      <varlistentry>
-        <term>
-          <literal>int2</literal>
-        </term>
-        <listitem>
-          <para>Additional integer data.</para>
-        </listitem>
-      </varlistentry>
-      <varlistentry>
-        <term>
-          <literal>string1</literal>
-        </term>
-        <listitem>
-          <para>Additional string data.</para>
-        </listitem>
-      </varlistentry>
-      <varlistentry>
-        <term>
-          <literal>string2</literal>
-        </term>
-        <listitem>
-          <para>Additional string data.</para>
-        </listitem>
-      </varlistentry>
-      <varlistentry>
-        <term>
-          <literal>string3</literal>
-        </term>
-        <listitem>
-          <para>Additional string data.</para>
-        </listitem>
-      </varlistentry>
-    </variablelist>
-  </refsect1>
-  <refsect1>
-    <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
-      <d:title>Application Examples</d:title>
-    </d:info>
-    <para>This script outputs the character data of an XML document read from stdin.</para>
-    <informalexample>
-      <programlisting>
-package require xml
-
-proc cdata {data args} {
-    puts -nonewline $data
-}
-
-set parser [::xml::parser -characterdatacommand cdata]
-$parser parse [read stdin]
-      </programlisting>
-    </informalexample>
-    <para>This script counts the number of elements in an XML document read from stdin.</para>
-    <informalexample>
-      <programlisting>
-package require xml
-
-proc EStart {varName name attlist args} {
-    upvar #0 $varName var
-    incr var
-}
-
-set count 0
-set parser [::xml::parser -elementstartcommand [list EStart count]]
-$parser parse [read stdin]
-puts "The XML document contains $count elements"
-      </programlisting>
-    </informalexample>
-  </refsect1>
-  <refsect1>
-    <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
-      <d:title>Safe XML</d:title>
-    </d:info>
-    <para>TclXML/Tcl and TclXML/libxml2 may be used in a Safe Tcl interpreter.  When a document is parsed in a Safe Tcl interpreter, any attempt by the XML document to load an external entity is handled by the -externalentitycommand callback.  This callback is evaluated in the context of the safe interpreter and therefore is subject to the security policy in force for that interpreter.  The default entity loader will not be invoked, even if the callback script returns a <literal>TCL_CONTINUE</literal> code.</para>
-    <para>See the description of the -externalentitycommand for further details.</para>
-  </refsect1>
-  <refsect1>
-    <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
-      <d:title>Parser Classes</d:title>
-    </d:info>
-    <para>This section will discuss how a parser class is implemented.</para>
-    <refsect2>
-      <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
-        <d:title>Tcl Parser Class</d:title>
-      </d:info>
-      <para>The pure-Tcl parser class requires no compilation - it is a collection of Tcl scripts.  This parser implementation is non-validating, ie. it can only check well-formedness in a document.  However, by enabling the <option>-validate</option> option it will read the document's DTD and resolve external entities.  This parser class is referred to as TclXML/tcl.</para>
-      <para>This parser implementation aims to implement XML v1.0 and supports XML Namespaces.</para>
-      <para>Generally the parser produces XML Infoset information items.  That is, it gives the application a slightly higher-level view than the raw XML syntax.  For example, it does not report CDATA Sections.</para>
-      <para>TclXML/tcl is not able to handle character encodings other than UTF-8.</para>
-    </refsect2>
-    <refsect2>
-      <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
-        <d:title>libxml2 Parser Class</d:title>
-      </d:info>
-      <para>The libxml2 parser class provides a Tcl interface to the libxml2 XML parser library.  This parser class is referred to as TclXML/libxml2.</para>
-      <para>When the package is loaded the variable <literal>::xml::libxml2::libxml2version</literal> is set to the version number of the libxml2 library being used.</para>
-      <para>On MS Windows, it is necessary to load the generic XML package first, and then the TclXML/libxml2 package.  For example,</para>
-      <informalexample>
-        <programlisting>
-package require xml
-package require xml::libxml2
-</programlisting>
-      </informalexample>
-      <refsect3>
-        <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
-          <d:title>get Method</d:title>
-        </d:info>
-        <para>TclXML/libxml2 provides the following arguments to the get method:</para>
-        <variablelist>
-          <varlistentry>
-            <term>
-              <arg>document</arg>
-            </term>
-            <listitem>
-              <para>Returns the parsed document object.  libxml2 builds an in-memory data structure of the XML document it parses (a DOM tree).  This method returns a handle (or token) for that structure.</para>
-              <para>TclXML/libxml2 manages the document object as a Tcl object.  See the <option>-keep</option> for further information.</para>
-            </listitem>
-          </varlistentry>
-        </variablelist>
-      </refsect3>
-      <refsect3>
-        <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
-          <d:title>Additional Options</d:title>
-        </d:info>
-        <variablelist>
-          <varlistentry>
-            <term>
-              <option>-keep</option>
-            </term>
-            <listitem>
-              <optionsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">-keep</option>
-                <arg xmlns="http://docbook.org/ns/docbook">normal | implicit</arg>
-              </optionsynopsis>
-              <para>Controls how the TclXML/libxml2 packages manages the document object.  The default value is <literal>implicit</literal>; the document is destroyed when the Tcl Object's internal representation is freed.  If the option is given the value <literal>normal</literal> then the document must be explicit destroyed.  The only way to explicitly destroy the document is by using the C API.</para>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <option>-retainpath</option>
-            </term>
-            <listitem>
-              <optionsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">-retainpath</option>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>xpath</replaceable>
-                </arg>
-              </optionsynopsis>
-              <para>The given XPath location path specifies which part of the document is to be kept after the parsing operation has completed.  By default, all document data is discard after it has been parsed.</para>
-            </listitem>
-          </varlistentry>
-          <varlistentry>
-            <term>
-              <option>-retainpathns</option>
-            </term>
-            <listitem>
-              <optionsynopsis xmlns="http://tclxml.sourceforge.net/doc">
-                <option xmlns="http://docbook.org/ns/docbook">-retainpathns</option>
-                <arg xmlns="http://docbook.org/ns/docbook">
-                  <replaceable>prefix ns ...</replaceable>
-                </arg>
-              </optionsynopsis>
-              <para>The value of this option is a list of pairs of XML Namespace prefixes and their corresponding namespace URIs.  These are used by the XPath location path given in the <arg>-retainpath</arg> option.</para>
-            </listitem>
-          </varlistentry>
-        </variablelist>
-      </refsect3>
-      <refsect3>
-        <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
-          <d:title>Limitations</d:title>
-        </d:info>
-        <para>The libxml2 parser classes has the following limitations:</para>
-        <itemizedlist>
-          <listitem>
-            <para><option>-reportempty</option> has no effect.  libxml2 does not report empty element syntax.</para>
-          </listitem>
-          <listitem>
-            <para>Incremental (push) parsing, ie. <arg><option>-final</option>&#xa0;<literal>0</literal></arg> is not supported.</para>
-          </listitem>
-          <listitem>
-            <para>TclXML/libxml2 does not provide (DTD) validation, (WXS) schema validation or Relax NG validation, although the libxml2 library does provide those functions.  These functions are provided by the TclDOM/libxml2 package, but only in a "posteriori" fashion (ie. only after the document has been parsed).</para>
-          </listitem>
-          <listitem>
-            <para>libxml2 supports XML Namespaces.  The use of XML Namespaces can be queried, but the <emphasis>declaration</emphasis> of a XML Namespace is not reported.</para>
-          </listitem>
-        </itemizedlist>
-      </refsect3>
-    </refsect2>
-  </refsect1>
-  <refsect1>
-    <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
-      <d:title>Keywords</d:title>
-    </d:info>
-    <keywordset>
-      <keyword>XML</keyword>
-      <keyword>parse</keyword>
-    </keywordset>
-  </refsect1>
-</refentry>
diff --git a/tclxml-3.2/doc/tclxslt.html b/tclxml-3.2/doc/tclxslt.html
deleted file mode 100644
index cc68619..0000000
--- a/tclxml-3.2/doc/tclxslt.html
+++ /dev/null
@@ -1,257 +0,0 @@
-<html>
-<head>
-<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
-<title>TclXSLT</title>
-<link rel="stylesheet" href="tclxml.css">
-</head>
-<body><div class="refentry">
-<h1 class="title"><a name="id18406">TclXSLT</a></h1>
-<h2>Contents</h2>
-<ul>
-<li><a href="#synopsis">Synopsis</a></li>
-<li><a href="#id18664">Description</a></li>
-<li><a href="#id18710">Packages and Namespaces</a></li>
-<li>
-<a href="#id18731">Commands</a><ul>
-<li><a href="#id18745">::xslt::compile</a></li>
-<li>
-<a href="#id18805">Stylesheet Command</a><ul>
-<li><a href="#id18828">Command Methods</a></li>
-<li><a href="#id19210">Stylesheet Parameters</a></li>
-</ul>
-</li>
-<li><a href="#id19288">::xslt::extension</a></li>
-<li><a href="#id19330">::xslt::security</a></li>
-</ul>
-</li>
-<li>
-<a href="#id19511">Extensions</a><ul>
-<li>
-<a href="#id19535">Implementing An Extension</a><ul>
-<li><a href="#id19594">Extension Functions</a></li>
-<li><a href="#id19619">Extension Elements</a></li>
-</ul>
-</li>
-<li><a href="#id19638">Using An Extension</a></li>
-</ul>
-</li>
-</ul>
-<div class="refnamediv">
-<span class="refname">::xslt::compile</span>, <span class="refname">::xslt::extension</span>, <span class="refname">::xslt::security</span>
-</div>
-<div class="refsynopsisdiv">
-<a name="synopsis"></a><h2>Synopsis</h2>
-<div class="cmdsynopsis" id="id18514">
-<a name="id18514"></a><span class="command" id="id18518"><a name="package_require_xslt"></a><tt>package require xslt</tt> </span>
-</div>
-<br><span class="pkgsynopsis"><pre>package require xslt ?3.2?</pre></span><div class="cmdsynopsis" id="id18540">
-<a name="id18540"></a><span class="command" id="id18544"><a name="__xslt__compile"></a><tt>::xslt::compile</tt> </span><em>doc</em>
-</div>
-<div class="cmdsynopsis" id="id18564">
-<a name="id18564"></a><span class="command" id="id18568"><a name="ssheet"></a><tt><em>ssheet</em></tt> </span><em>method</em> ?option value...? ?args...?</div>
-<div class="cmdsynopsis" id="id18610">
-<a name="id18610"></a><span class="command" id="id18613"><a name="__xslt__extension"></a><tt>::xslt::extension</tt> </span><span class="methodname">add</span><em>nsuri</em> <em>tcl-namespace</em>
-</div>
-<div class="cmdsynopsis" id="id18639">
-<a name="id18639"></a><span class="command" id="id18642"><a name="__xslt__security"></a><tt>::xslt::security</tt> </span><span class="methodname"><em>request</em></span><em>detail</em>
-</div>
-<h3>Tcl Namespace Usage</h3>
-<br><tt>::xslt</tt><p></p>
-</div>
-<div class="refsect1">
-<h2>
-<a name="id18664"></a>Description</h2>
-<p>TclXSLT is a wrapper for the <a href="http://xmlsoft.org/">Gnome libxslt library</a> that allows an application to perform XSL transformations (XSLT).  The package also provides a binding to the XSLT extension mechanism so that XSLT extension may be implemented using Tcl scripts.</p>
-<p>Transformation only works with documents created by TclDOM/libxml2.</p>
-<p>The TclXSLT package makes extensive use of Tcl objects.  Compiled XSL stylesheets are stored as the internal representation of a Tcl object.  Source and result documents are accessed via TclDOM's C interface as Tcl objects.  This allows the application to cache parsed XML documents and compiled XSL stylesheets for better runtime performance.</p>
-</div>
-<div class="refsect1">
-<h2>
-<a name="id18710"></a>Packages and Namespaces</h2>
-<p>The TclXSLT package defines the <tt>xslt</tt> package and also a Tcl namespace using that name.</p>
-</div>
-<div class="refsect1">
-<h2>
-<a name="id18731"></a>Commands</h2>
-<div class="refsect2">
-<h3>
-<a name="id18745"></a><strong>::xslt::compile</strong>
-</h3>
-<p>The <strong>::xslt::compile</strong> command compiles a stylesheet document.  It returns a compiled stylesheet object and also defines a Tcl command to access the stylesheet.  This Tcl command may be used to transform XML documents.</p>
-<h4>Example</h4>
-<div class="example"><pre><div class="programlisting"><pre>
-set source_doc [::dom::libxml2::parse $XML]
-set ssheet_doc [::dom::libxml2::parse $XSLstylesheet]
-set ssheet [::xslt::compile $ssheet_doc]
-set result [$ssheet transform $source_doc]
-</pre></div></pre></div>
-<p>NB.  It is advisable to use the  <em>-baseuri</em> option when parsing the source and stylesheet documents to allow external resources to be resolved.</p>
-</div>
-<div class="refsect2">
-<h3>
-<a name="id18805"></a>Stylesheet Command</h3>
-<p>The stylesheet command created by <strong>::xslt::compile</strong> command accesses a compiled stylesheet.</p>
-<div class="refsect3">
-<h4>
-<a name="id18828"></a>Command Methods</h4>
-<p>The following command methods may be used:</p>
-<dl>
-<span class="term"><span class="arg">cget</span> <span class="arg"><em>option</em></span></span><dd><p>Returns the value of an option.  See below for the list of valid options.</p></dd>
-<span class="term"><span class="arg">configure</span> <span class="arg"><em>option</em><em>value</em></span></span><dd>
-<p>Sets the value of an option.  Available options are as follows:</p>
-<dl>
-<span class="term"> <em>-indent</em></span><dd>
-<p>Specifies whether the output being produced by the stylesheet should be idented (or "pretty-printed").  This is usually set by the styesheet's <tt>xsl:output</tt> element.  The result is a boolean value.</p>
-<p>This is a read-only option.</p>
-</dd>
-<span class="term"> <em>-messagecommand</em><span class="arg"><em>script</em></span></span><dd>
-<p>This option specifies a Tcl command to be evaluated when a message is produced by the stylesheet.  Messages may be produced when the stylesheet detects an error during processing, or when the stylesheet uses the <tt>xsl:message</tt> element.</p>
-<p>It is currently not possible to distinguish between an error message and a message produced using <tt>xsl:message</tt>.</p>
-</dd>
-<span class="term"> <em>-method</em></span><dd>
-<p>Specifies the output being produced by the stylesheet.  This is usually set by the styesheet's <tt>xsl:output</tt> element.  May have the value <span class="literal">xml</span>, <span class="literal">html</span>, <span class="literal">xhtml</span>, <span class="literal">text</span> or an empty string.</p>
-<p>If the result is an empty string, then the output method used depends on the type of the result document.  If the result document is of type "HTML" (ie. if [dom::node cget $resultdoc -nodeType] returns <span class="literal">HTMLdocument</span>), then the <span class="literal">html</span> output method should be used.  Otherwise the output method to use is <span class="literal">xml</span>.</p>
-<p>This is a read-only option.</p>
-</dd>
-<span class="term"> <em>-profilechannel</em></span><dd><p>Specifies the name of a channel into which profiling information is written.  The channel must have been opened for writing, or an error will be returned when attempting a transformation.  Only file channels may be used and only on Unix systems.</p></dd>
-<span class="term"> <em>-resulturi</em></span><dd>
-<p>Specifies the target URI for the transformation, ie. where the result will be written to.  The result document is <em>not</em> written to this URI automatically; the application should write the result document to this URI itself.</p>
-<p>Some transformation constructs resolve relative URIs against this URI.  For example, a subsidiary result document produced using the <tt>document</tt> element.</p>
-</dd>
-</dl>
-</dd>
-<span class="term"><span class="arg">get</span> <span class="arg"><em>what</em></span></span><dd>
-<p>Returns information from the stylesheet.  The following values may be used for <span class="arg"><em>what</em></span>:</p>
-<dl>
-<span class="term"><span class="arg">parameters</span></span><dd>
-<p>Returns a Tcl list describing the parameters that the stylesheet accepts.  Each member of the list is itself a Tcl list with three members: <span class="literal">{name ns select}</span>.  <span class="literal">name</span> is the name of the parameter, <span class="literal">ns</span> is the XML namespace for the parameter and <span class="literal">select</span> is the value of the <tt>select</tt> attribute of the <tt>param</tt> element, if any (ie. the default value of the parameter).  This implementation is not able to return a default value set using the content of the <tt>param</tt> element.</p>
-<p>All stylesheet parameters are returned by this method, including those in included/imported stylesheets.  Where more than one parameter is defined with the same name, only the parameter with the highest import precedence is included in the returned list.</p>
-</dd>
-</dl>
-</dd>
-<span class="term"><span class="arg">transform</span> <span class="arg"><em>source</em></span> "<span class="arg"><em>name</em></span> | <span class="arg"><em>value</em></span>"</span><dd><p>Performs an XSL transformation on the given source document.  Stylesheet parameters may be specified as name-value pairs.  The return result is the DOM token for the result document.</p></dd>
-</dl>
-</div>
-<div class="refsect3">
-<h4>
-<a name="id19210"></a>Stylesheet Parameters</h4>
-<p>Any number of name-value pairs may be specified as arguments to the <strong><em>stylesheet</em> transform</strong> method.  These are passed as values for parameters in the stylesheet.  <tt>libxslt</tt> interprets the values as XPath expressions, where the context node is the root node for the source document.  To pass a value as a string it must be XPath-quoted, for example</p>
-<div class="informalexample"><pre><div class="programlisting"><pre>
-set library "Gnome libxslt"
-$ssheet transform $source_doc \
-	library '$library' \
-	author "'Daniel Veillard'" \
-	node {/*/Element[3]}
-</pre></div></pre></div>
-</div>
-<p>Following is an example of how to use the <strong><em>stylesheet</em> transform</strong> method.</p>
-<h4>Example</h4>
-<div class="example"><pre><div class="programlisting"><pre>
-set source_doc [::dom::libxml2::parse $XML]
-set ssheet_doc [::dom::libxml2::parse $XSLstylesheet]
-set ssheet [::xslt::compile $ssheet_doc]
-set result_doc [$ssheet transform $source_doc]
-set result_xml [::dom::libxml2::serialize $result_doc \
-    -method [$ssheet cget -method]]
-</pre></div></pre></div>
-</div>
-<div class="refsect2">
-<h3>
-<a name="id19288"></a><strong>::xslt::extension</strong>
-</h3>
-<p>The <strong>::xslt::extension</strong> command is used to manage extensions of the <tt>libxslt</tt> library.  The <span class="methodname">add</span> is used to register an extension.  The <span class="methodname">remove</span> is used to unregister an extension.  See <a href="">EXTENSIONS</a> for more detail.</p>
-</div>
-<div class="refsect2">
-<h3>
-<a name="id19330"></a><strong>::xslt::security</strong>
-</h3>
-<p>The <strong>::xslt::security</strong> command is a "call-in" used to manage the security of a stylesheet performing a transformation.  The TclXSLT package does not create this command.  A stylesheet may need to perform an operation on an external resource, such as reading or writing a file, or opening a network connection.  Before performing such an operation, TclXSLT will invoke the <strong>::xslt::security</strong> command.  It interprets the result of the command as a boolean value, and only if the "true" value is returned will it instruct the <tt>libxslt</tt> library to continue.</p>
-<p>TclXSLT will invoke the <strong>::xslt::security</strong> command in a different fashion depending on whether the current interpreter is safe or unsafe.</p>
-<ul>
-<li><p>If the current interpeter is unsafe (ie. it is a trusted interpreter) then the command is invoked in the usual manner (see below for arguments).  If the command does not exist then the value "true" is the default, ie. the operation will be permitted.</p></li>
-<li><p>If the current interpreter is safe then the command is invoked as a hidden command.  This is to ensure that the untrusted script cannot intercept the invocation of the command.  If the hidden command does not exist then the value "false" is the default, ie. the operation will not be permitted.</p></li>
-</ul>
-<p>When the <strong>::xslt::security</strong> command is invoked two arguments are appended:</p>
-<div class="cmdsynopsis" id="id19414">
-<a name="id19414"></a><tt>::xslt::security</tt> <span class="methodname"><em>request</em></span><em>detail</em>
-</div>
-<dl>
-<span class="term"><span class="methodname"><em>request</em></span></span><dd>
-<p>This indicates the operation being requested and may have one of the following values:</p>
-<ul>
-<li><p><span class="literal">readfile</span></p></li>
-<li><p><span class="literal"></span></p></li>
-<li><p><span class="literal"></span></p></li>
-<li><p><span class="literal"></span></p></li>
-<li><p><span class="literal"></span></p></li>
-</ul>
-</dd>
-</dl>
-</div>
-</div>
-<div class="refsect1">
-<h2>
-<a name="id19511"></a>Extensions</h2>
-<p>The TclXSLT package allows an application to bind Tcl scripts to the extension mechanism of <tt>libxslt</tt>.  This means that Tcl scripts may provide the implementation of an XSLT extension element or function.  The binding is achieved to associating a Tcl namespace with an XML namespace.</p>
-<div class="refsect2">
-<h3>
-<a name="id19535"></a>Implementing An Extension</h3>
-<p>The Tcl application uses the <strong>::xslt::extension add</strong> command to register an extension.  An XML Namespace for the extension is specified as an argument, along with a Tcl namespace that will provide implementations of extension elements and functions.  For example,</p>
-<div class="informalexample"><pre><div class="programlisting"><pre>
-::xslt::extension add http://tclxml.sourceforge.net/Example ::example
-</pre></div></pre></div>
-<p>Everytime the <strong>::xslt::transform</strong> command is executed, a newly-created XSLT engine is initialized.  For each registered extension, every procedure in the associated Tcl namespace is defined in the XSLT engine as either an extension element or an extension function.  The procedure is defined as an extension function if it has a variable argument list, otherwise it is defined as an extension element.  The procedure name is used as the local part of the extension name.  For example,</p>
-<div class="informalexample"><pre><div class="programlisting"><pre>
-namespace eval example {
-    namespace export myfunc myelement
-}
-
-proc example::myfunc {name args} {
-    global app
-    return $app($name)
-}
-proc example::myelement {node} {
-    global app
-    return $app([dom::libxml2::node cget $node -nodeName])
-}
-</pre></div></pre></div>
-<p>"myfunc" is defined as an extension function and "myelement" is defined as an extension element.</p>
-<div class="refsect3">
-<h4>
-<a name="id19594"></a>Extension Functions</h4>
-<p>The arguments to an extension function are converted to a string value and then passed as parameters to the Tcl procedure.</p>
-<p>The return result of the Tcl procedure becomes the return value of the extension function.  The type of the result is preserved where possible, otherwise it is converted to a string value.</p>
-</div>
-<div class="refsect3">
-<h4>
-<a name="id19619"></a>Extension Elements</h4>
-<p>Extension elements have not been implemented in TclXSLT v3.2.</p>
-</div>
-</div>
-<div class="refsect2">
-<h3>
-<a name="id19638"></a>Using An Extension</h3>
-<p>To invoke an extension in an XSL stylesheet, use the normal XSLT extension mechanism.  The XML Namespace matches the extension to the registered Tcl namespace (NB. the stylesheet author is free to choose any prefix for the extension namespace).  For example,</p>
-<div class="informalexample"><pre><div class="programlisting"><pre>
-<xsl:stylesheet version='1.0'
-	xmlns:xsl='http://www.w3.org/1999/XSL/Transform'
-	xmlns:eg='http://tclxml.sourceforge.net/Example'>
-
-  <xsl:template match='/'>
-    <xsl:text>Result of calling extension is "</xsl:text>
-    <xsl:value-of select='eg:myfunc("foo")'/>
-    <xsl:text>".
-</xsl:text>
-  </xsl:template>
-
-</xsl:stylesheet>
-</pre></div></pre></div>
-<p>This stylesheet would result in the following Tcl script being evaluated:</p>
-<div class="informalexample"><pre><div class="programlisting"><pre>
-::example::myfunc foo
-</pre></div></pre></div>
-</div>
-</div>
-</div></body>
-</html>
-
diff --git a/tclxml-3.2/doc/tclxslt.xml.in b/tclxml-3.2/doc/tclxslt.xml.in
deleted file mode 100644
index 0f00963..0000000
--- a/tclxml-3.2/doc/tclxslt.xml.in
+++ /dev/null
@@ -1 +0,0 @@
-<!DOCTYPE refentry [
  <!ENTITY version "@PACKAGE_VERSION@">
]>
<refentry xmlns="http://docbook.org/ns/docbook"
	  xmlns:tcl='http://tclxml.sourceforge.net/doc'>
  <info>
    <author xmlns:xlink="http://www.w3.org/XLink" xlink:href="http://www.explain.com.au/staff/Steve.Ball/">
      <firstname>Steve</firstname>
      <surname>Ball</surname>
    </author>
    <copyright>
      <year>2008</year>
      <year>2007</year>
      <year>2005</year>
      <holder xmlns:xlink="http://www.w3.org/XLink" xlink:href="http://www.explain.com.au/">Explain</holder>
    </copyright>
    <copyright>
      <year>2004</year>
      <year>2003</year>
      <year>2002</year>
      <holder xmlns:xlink="http://www.w3.org/XLink" xlink:href="http://www.zveno.com/">Zveno Pty Ltd</holder>
      <legalnotice>
        <para>See the file <filename>LICENSE</filename> for information on usage and redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.</para>
      </legalnotice>
    </copyright>
  </info>
  <refmeta>
    <refentrytitle>TclXSLT</refentrytitle>
    <manvolnum>n</manvolnum>
  </refmeta>
  <refnamediv>
    <refname>::xslt::compile</refname>
    <refname>::xslt::extension</refname>
    <refname>::xslt::security</refname>
  </refnamediv>
  <refsynopsisdiv>
    <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
      <command xmlns="http://docbook.org/ns/docbook">package require xslt</command>
    </cmdsynopsis>
    <pkgsynopsis xmlns="http://tclxml.sourceforge.net/doc">
      <package xmlns="http://docbook.org/ns/docbook">xslt</package>
      <version xmlns="http://docbook.org/ns/docbook">&version;</version>
    </pkgsynopsis>
    <namespacesynopsis xmlns="http://tclxml.sourceforge.net/doc">
      <namespace>::xslt</namespace>
    </namespacesynopsis>
    <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
      <command xmlns="http://docbook.org/ns/docbook">::xslt::compile</command>
      <arg xmlns="http://docbook.org/ns/docbook">
        <replaceable>doc</replaceable>
      </arg>
    </cmdsynopsis>
    <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
      <command xmlns="http://docbook.org/ns/docbook">
        <replaceable>ssheet</replaceable>
      </command>
      <arg xmlns="http://docbook.org/ns/docbook">
        <replaceable>method</replaceable>
      </arg>
      <group xmlns="http://docbook.org/ns/docbook" choice="opt" rep="repeat">
        <arg>option</arg>
        <arg>value</arg>
      </group>
      <group xmlns="http://docbook.org/ns/docbook" choice="opt" rep="repeat">
        <arg>args</arg>
      </group>
    </cmdsynopsis>
    <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
      <command xmlns="http://docbook.org/ns/docbook">::xslt::extension</command>
      <methodname xmlns="http://docbook.org/ns/docbook">add</methodname>
      <arg xmlns="http://docbook.org/ns/docbook">
        <replaceable>nsuri</replaceable>
      </arg>
      <arg xmlns="http://docbook.org/ns/docbook">
        <replaceable>tcl-namespace</replaceable>
      </arg>
    </cmdsynopsis>
    <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
      <command xmlns="http://docbook.org/ns/docbook">::xslt::security</command>
      <methodname xmlns="http://docbook.org/ns/docbook">
        <replaceable>request</replaceable>
      </methodname>
      <arg xmlns="http://docbook.org/ns/docbook">
        <replaceable>detail</replaceable>
      </arg>
    </cmdsynopsis>
  </refsynopsisdiv>
  <refsect1>
    <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
      <d:title>Description</d:title>
    </d:info>
    <para>TclXSLT is a wrapper for the <d:link xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc" xlink:href="http://xmlsoft.org/">Gnome libxslt library</d:link> that allows an application to perform XSL transformations (XSLT).  The package also provides a binding to the XSLT extension mechanism so that XSLT extension may be implemented using Tcl scripts.</para>
    <para>Transformation only works with documents created by TclDOM/libxml2.</para>
    <para>The TclXSLT package makes extensive use of Tcl objects.  Compiled XSL stylesheets are stored as the internal representation of a Tcl object.  Source and result documents are accessed via TclDOM's C interface as Tcl objects.  This allows the application to cache parsed XML documents and compiled XSL stylesheets for better runtime performance.</para>
  </refsect1>
  <refsect1>
    <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
      <d:title>Packages and Namespaces</d:title>
    </d:info>
    <para>The TclXSLT package defines the <tcl:package>xslt</tcl:package> package and also a Tcl namespace using that name.</para>
  </refsect1>
  <refsect1>
    <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
      <d:title>Commands</d:title>
    </d:info>
    <refsect2>
      <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
        <d:title>
          <command xmlns="http://tclxml.sourceforge.net/doc">::xslt::compile</command>
        </d:title>
      </d:info>
      <para>The <command xmlns="http://tclxml.sourceforge.net/doc">::xslt::compile</command> command compiles a stylesheet document.  It returns a compiled stylesheet object and also defines a Tcl command to access the stylesheet.  This Tcl command may be used to transform XML documents.</para>
      <example>
        <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
          <d:title>Example</d:title>
        </d:info>
        <programlisting>
set source_doc [::dom::libxml2::parse $XML]
set ssheet_doc [::dom::libxml2::parse $XSLstylesheet]
set ssheet [::xslt::compile $ssheet_doc]
set result [$ssheet transform $source_doc]
</programlisting>
      </example>
      <para>NB.  It is advisable to use the <option>-baseuri</option> option when parsing the source and stylesheet documents to allow external resources to be resolved.</para>
    </refsect2>
    <refsect2>
      <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
        <d:title>Stylesheet Command</d:title>
      </d:info>
      <para>The stylesheet command created by <command xmlns="http://tclxml.sourceforge.net/doc">::xslt::compile</command> command accesses a compiled stylesheet.</para>
      <refsect3>
        <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
          <d:title>Command Methods</d:title>
        </d:info>
        <para>The following command methods may be used:</para>
        <variablelist>
          <varlistentry>
            <term>
              <arg>cget</arg>
              <arg>
                <replaceable>option</replaceable>
              </arg>
            </term>
            <listitem>
              <para>Returns the value of an option.  See below for the list of valid options.</para>
            </listitem>
          </varlistentry>
          <varlistentry>
            <term>
              <arg>configure</arg>
              <arg>
                <replaceable>option</replaceable>
                <replaceable>value</replaceable>
              </arg>
            </term>
            <listitem>
              <para>Sets the value of an option.  Available options are as follows:</para>
              <variablelist>
                <varlistentry>
                  <term>
                    <option>-indent</option>
                  </term>
                  <listitem>
                    <para>Specifies whether the output being produced by the stylesheet should be idented (or "pretty-printed").  This is usually set by the styesheet's <tag>xsl:output</tag> element.  The result is a boolean value.</para>
                    <para>This is a read-only option.</para>
                  </listitem>
                </varlistentry>
                <varlistentry>
                  <term>
                    <option>-messagecommand</option>
                    <arg>
                      <replaceable>script</replaceable>
                    </arg>
                  </term>
                  <listitem>
                    <para>This option specifies a Tcl command to be evaluated when a message is produced by the stylesheet.  Messages may be produced when the stylesheet detects an error during processing, or when the stylesheet uses the <tag>xsl:message</tag> element.</para>
                    <para>It is currently not possible to distinguish between an error message and a message produced using <tag>xsl:message</tag>.</para>
                  </listitem>
                </varlistentry>
                <varlistentry>
                  <term>
                    <option>-method</option>
                  </term>
                  <listitem>
                    <para>Specifies the output being produced by the stylesheet.  This is usually set by the styesheet's <tag>xsl:output</tag> element.  May have the value <literal>xml</literal>, <literal>html</literal>, <literal>xhtml</literal>, <literal>text</literal> or an empty string.</para>
                    <para>If the result is an empty string, then the output method used depends on the type of the result document.  If the result document is of type "HTML" (ie. if [dom::node cget $resultdoc -nodeType] returns <literal>HTMLdocument</literal>), then the <literal>html</literal> output method should be used.  Otherwise the output method to use is <literal>xml</literal>.</para>
                    <para>This is a read-only option.</para>
                  </listitem>
                </varlistentry>
                <varlistentry>
                  <term>
                    <option>-profilechannel</option>
                  </term>
                  <listitem>
                    <para>Specifies the name of a channel into which profiling information is written.  The channel must have been opened for writing, or an error will be returned when attempting a transformation.  Only file channels may be used and only on Unix systems.</para>
                  </listitem>
                </varlistentry>
                <varlistentry>
                  <term>
                    <option>-resulturi</option>
                  </term>
                  <listitem>
                    <para>Specifies the target URI for the transformation, ie. where the result will be written to.  The result document is <emphasis>not</emphasis> written to this URI automatically; the application should write the result document to this URI itself.</para>
                    <para>Some transformation constructs resolve relative URIs against this URI.  For example, a subsidiary result document produced using the <tag>document</tag> element.</para>
                  </listitem>
                </varlistentry>
              </variablelist>
            </listitem>
          </varlistentry>
          <varlistentry>
            <term>
              <arg>get</arg>
              <arg>
                <replaceable>what</replaceable>
              </arg>
            </term>
            <listitem>
              <para>Returns information from the stylesheet.  The following values may be used for <arg><replaceable>what</replaceable></arg>:</para>
              <variablelist>
                <varlistentry>
                  <term>
                    <arg>parameters</arg>
                  </term>
                  <listitem>
                    <para>Returns a Tcl list describing the parameters that the stylesheet accepts.  Each member of the list is itself a Tcl list with three members: <literal>{name ns select}</literal>.  <literal>name</literal> is the name of the parameter, <literal>ns</literal> is the XML namespace for the parameter and <literal>select</literal> is the value of the <tag role='attribute'>select</tag> attribute of the <tag>param</tag> element, if any (ie. the default value of the parameter).  This implementation is not able to return a default value set using the content of the <tag>param</tag> element.</para>
                    <para>All stylesheet parameters are returned by this method, including those in included/imported stylesheets.  Where more than one parameter is defined with the same name, only the parameter with the highest import precedence is included in the returned list.</para>
                  </listitem>
                </varlistentry>
              </variablelist>
            </listitem>
          </varlistentry>
          <varlistentry>
            <term>
              <arg>transform</arg>
              <arg>
                <replaceable>source</replaceable>
              </arg>
              <group opt="repeat">
                <arg>
                  <replaceable>name</replaceable>
                </arg>
                <arg>
                  <replaceable>value</replaceable>
                </arg>
              </group>
            </term>
            <listitem>
              <para>Performs an XSL transformation on the given source document.  Stylesheet parameters may be specified as name-value pairs.  The return result is the DOM token for the result document.</para>
            </listitem>
          </varlistentry>
        </variablelist>
      </refsect3>
      <refsect3>
        <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
          <d:title>Stylesheet Parameters</d:title>
        </d:info>
        <para>Any number of name-value pairs may be specified as arguments to the <command xmlns="http://tclxml.sourceforge.net/doc"><replaceable xmlns="http://docbook.org/ns/docbook">stylesheet</replaceable> transform</command> method.  These are passed as values for parameters in the stylesheet.  <application>libxslt</application> interprets the values as XPath expressions, where the context node is the root node for the source document.  To pass a value as a string it must be XPath-quoted, for example</para>
        <informalexample>
          <programlisting>
set library "Gnome libxslt"
$ssheet transform $source_doc \
	library '$library' \
	author "'Daniel Veillard'" \
	node {/*/Element[3]}
</programlisting>
        </informalexample>
      </refsect3>
      <para>Following is an example of how to use the <command xmlns="http://tclxml.sourceforge.net/doc"><replaceable xmlns="http://docbook.org/ns/docbook">stylesheet</replaceable> transform</command> method.</para>
      <example>
        <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
          <d:title>Example</d:title>
        </d:info>
        <programlisting>
set source_doc [::dom::libxml2::parse $XML]
set ssheet_doc [::dom::libxml2::parse $XSLstylesheet]
set ssheet [::xslt::compile $ssheet_doc]
set result_doc [$ssheet transform $source_doc]
set result_xml [::dom::libxml2::serialize $result_doc \
    -method [$ssheet cget -method]]
</programlisting>
      </example>
    </refsect2>
    <refsect2>
      <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
        <d:title>
          <command xmlns="http://tclxml.sourceforge.net/doc">::xslt::extension</command>
        </d:title>
      </d:info>
      <para>The <command xmlns="http://tclxml.sourceforge.net/doc">::xslt::extension</command> command is used to manage extensions of the <application>libxslt</application> library.  The <methodname>add</methodname> is used to register an extension.  The <methodname>remove</methodname> is used to unregister an extension.  See <link>EXTENSIONS</link> for more detail.</para>
    </refsect2>
    <refsect2>
      <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
        <d:title>
          <command xmlns="http://tclxml.sourceforge.net/doc">::xslt::security</command>
        </d:title>
      </d:info>
      <para>The <command xmlns="http://tclxml.sourceforge.net/doc">::xslt::security</command> command is a "call-in" used to manage the security of a stylesheet performing a transformation.  The TclXSLT package does not create this command.  A stylesheet may need to perform an operation on an external resource, such as reading or writing a file, or opening a network connection.  Before performing such an operation, TclXSLT will invoke the <command xmlns="http://tclxml.sourceforge.net/doc">::xslt::security</command> command.  It interprets the result of the command as a boolean value, and only if the "true" value is returned will it instruct the <application>libxslt</application> library to continue.</para>
      <para>TclXSLT will invoke the <command xmlns="http://tclxml.sourceforge.net/doc">::xslt::security</command> command in a different fashion depending on whether the current interpreter is safe or unsafe.</para>
      <itemizedlist>
        <listitem>
          <para>If the current interpeter is unsafe (ie. it is a trusted interpreter) then the command is invoked in the usual manner (see below for arguments).  If the command does not exist then the value "true" is the default, ie. the operation will be permitted.</para>
        </listitem>
        <listitem>
          <para>If the current interpreter is safe then the command is invoked as a hidden command.  This is to ensure that the untrusted script cannot intercept the invocation of the command.  If the hidden command does not exist then the value "false" is the default, ie. the operation will not be permitted.</para>
        </listitem>
      </itemizedlist>
      <para>When the <command xmlns="http://tclxml.sourceforge.net/doc">::xslt::security</command> command is invoked two arguments are appended:</para>
      <cmdsynopsis xmlns="http://tclxml.sourceforge.net/doc">
        <command xmlns="http://docbook.org/ns/docbook">::xslt::security</command>
        <methodname xmlns="http://docbook.org/ns/docbook">
          <replaceable>request</replaceable>
        </methodname>
        <arg xmlns="http://docbook.org/ns/docbook">
          <replaceable>detail</replaceable>
        </arg>
      </cmdsynopsis>
      <variablelist>
        <varlistentry>
          <term>
            <methodname>
              <replaceable>request</replaceable>
            </methodname>
          </term>
          <listitem>
            <para>This indicates the operation being requested and may have one of the following values:</para>
            <itemizedlist>
              <listitem>
                <para>
                  <literal>readfile</literal>
                </para>
              </listitem>
              <listitem>
                <para>
                  <literal/>
                </para>
              </listitem>
              <listitem>
                <para>
                  <literal/>
                </para>
              </listitem>
              <listitem>
                <para>
                  <literal/>
                </para>
              </listitem>
              <listitem>
                <para>
                  <literal/>
                </para>
              </listitem>
            </itemizedlist>
          </listitem>
        </varlistentry>
      </variablelist>
    </refsect2>
  </refsect1>
  <refsect1>
    <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
      <d:title>Extensions</d:title>
    </d:info>
    <para>The TclXSLT package allows an application to bind Tcl scripts to the extension mechanism of <application>libxslt</application>.  This means that Tcl scripts may provide the implementation of an XSLT extension element or function.  The binding is achieved to associating a Tcl namespace with an XML namespace.</para>
    <refsect2>
      <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
        <d:title>Implementing An Extension</d:title>
      </d:info>
      <para>The Tcl application uses the <command xmlns="http://tclxml.sourceforge.net/doc">::xslt::extension add</command> command to register an extension.  An XML Namespace for the extension is specified as an argument, along with a Tcl namespace that will provide implementations of extension elements and functions.  For example,</para>
      <informalexample>
        <programlisting>
::xslt::extension add http://tclxml.sourceforge.net/Example ::example
</programlisting>
      </informalexample>
      <para>Everytime the <command xmlns="http://tclxml.sourceforge.net/doc">::xslt::transform</command> command is executed, a newly-created XSLT engine is initialized.  For each registered extension, every procedure in the associated Tcl namespace is defined in the XSLT engine as either an extension element or an extension function.  The procedure is defined as an extension function if it has a variable argument list, otherwise it is defined as an extension element.  The procedure name is used as the local part of the extension name.  For example,</para>
      <informalexample>
        <programlisting>
namespace eval example {
    namespace export myfunc myelement
}

proc example::myfunc {name args} {
    global app
    return $app($name)
}
proc example::myelement {node} {
    global app
    return $app([dom::libxml2::node cget $node -nodeName])
}
</programlisting>
      </informalexample>
      <para>"myfunc" is defined as an extension function and "myelement" is defined as an extension element.</para>
      <refsect3>
        <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
          <d:title>Extension Functions</d:title>
        </d:info>
        <para>The arguments to an extension function are converted to a string value and then passed as parameters to the Tcl procedure.</para>
        <para>The return result of the Tcl procedure becomes the return value of the extension function.  The type of the result is preserved where possible, otherwise it is converted to a string value.</para>
      </refsect3>
      <refsect3>
        <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
          <d:title>Extension Elements</d:title>
        </d:info>
        <para>Extension elements have not been implemented in TclXSLT v&version;.</para>
      </refsect3>
    </refsect2>
    <refsect2>
      <d:info xmlns:d="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:tcl="http://tclxml.sourceforge.net/doc">
        <d:title>Using An Extension</d:title>
      </d:info>
      <para>To invoke an extension in an XSL stylesheet, use the normal XSLT extension mechanism.  The XML Namespace matches the extension to the registered Tcl namespace (NB. the stylesheet author is free to choose any prefix for the extension namespace).  For example,</para>
      <informalexample>
        <programlisting>
<xsl:stylesheet version='1.0'
	xmlns:xsl='http://www.w3.org/1999/XSL/Transform'
	xmlns:eg='http://tclxml.sourceforge.net/Example'>

  <xsl:template match='/'>
    <xsl:text>Result of calling extension is "</xsl:text>
    <xsl:value-of select='eg:myfunc("foo")'/>
    <xsl:text>".
</xsl:text>
  </xsl:template>

</xsl:stylesheet>
</programlisting>
      </informalexample>
      <para>This stylesheet would result in the following Tcl script being evaluated:</para>
      <informalexample>
        <programlisting>
::example::myfunc foo
</programlisting>
      </informalexample>
    </refsect2>
  </refsect1>
</refentry>
\ No newline at end of file
diff --git a/tclxml-3.2/doc/transform.tcl b/tclxml-3.2/doc/transform.tcl
deleted file mode 100644
index 7c63e5c..0000000
--- a/tclxml-3.2/doc/transform.tcl
+++ /dev/null
@@ -1,77 +0,0 @@
-#!/bin/sh
-# -*- tcl -*- \
-exec tclsh "$0" "$@"
-
-# transform.tcl --
-#
-#	Transform a source document with a XSL stylesheet.
-#
-# Arguments:
-#	source-doc	Source XML document
-#	style-doc	XSL Stylesheet
-#	result-doc	Result HTML document
-#
-# Copyright (c) 2008 Explain
-# http://www.explain.com.au/
-#
-# $Id: transform.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require xml 3.2
-package require xslt 3.2
-
-set srcFname {}
-set styleFname {}
-set resultFname {}
-
-foreach {srcFname styleFname resultFname} $argv break
-
-if {$srcFname == "" || $styleFname == "" || $resultFname == ""} {
-    puts stderr "Usage: $argv0 source-doc style-doc result-doc"
-    exit 1
-}
-
-proc ReadXML fname {
-    if {[catch {open $fname} ch]} {
-	puts stderr "unable to open \"$fname\" due to \"$ch\""
-	exit 2
-    }
-    set xml [read $ch]
-    close $ch
-
-    if {[catch {dom::parse $xml -baseuri file://[file normalize [file join [pwd] $fname]]} doc]} {
-	puts stderr "unable to read XML document due to \"$doc\""
-	exit 3
-    }
-
-    return $doc
-}
-
-proc Message args {
-    if {[string length [string trim {*}$args]]} {
-	puts {*}$args
-    }
-}
-
-set srcdoc [ReadXML $srcFname]
-set styledoc [ReadXML $styleFname]
-if {[catch {xslt::compile $styledoc} style]} {
-    puts stderr "unable to compile XSL stylesheet due to \"$style\""
-    exit 4
-}
-
-$style configure -messagecommand Message
-
-if {[catch {$style transform $srcdoc} resultdoc]} {
-    puts stderr "error while performing transformation: \"$resultdoc\""
-    exit 5
-}
-
-if {[catch {open $resultFname w} ch]} {
-    puts stderr "unable to open file \"$resultFname\" for writing due to \"$ch\""
-    exit 6
-}
-puts $ch [dom::serialize $resultdoc -method [$style cget -method]]
-close $ch
-
-exit 0
-
diff --git a/tclxml-3.2/doc/txt.xsl b/tclxml-3.2/doc/txt.xsl
deleted file mode 100644
index 1cf99c3..0000000
--- a/tclxml-3.2/doc/txt.xsl
+++ /dev/null
@@ -1,234 +0,0 @@
-<xsl:stylesheet version='1.0'
-  xmlns:xsl='http://www.w3.org/1999/XSL/Transform'
-  xmlns:d='http://docbook.org/ns/docbook'
-  xmlns:xlink='http://www.w3.org/1999/xlink'
-  xmlns:tcl='http://tclxml.sourceforge.net/doc'
-  xmlns:str='http://xsltsl.org/string'
-  extension-element-prefixes='str'
-  exclude-result-prefixes="d xlink tcl">
-
-  <xsl:import href='xsltsl/stdlib.xsl'/>
-
-  <d:article>
-    <d:info>
-      <d:title>Text Stylesheet</d:title>
-      <d:copyright>
-        <d:year>2008</d:year>
-        <d:holder>Explain</d:holder>
-      </d:copyright>
-    </d:info>
-
-    <d:para>This stylesheet produces a text rendition of a DocBook document.</d:para>
-  </d:article>
-
-  <xsl:output method='text'/>
-
-  <xsl:strip-space elements='*'/>
-  <xsl:preserve-space elements='d:programlisting d:literallayout d:command'/>
-
-  <xsl:template match='d:article'>
-    <xsl:choose>
-      <xsl:when test='d:title'>
-        <xsl:apply-templates select='d:title'/>
-      </xsl:when>
-      <xsl:when test='d:info/d:title'>
-        <xsl:apply-templates select='d:info/d:title'/>
-      </xsl:when>
-    </xsl:choose>
-
-    <xsl:apply-templates select='d:info/d:author'/>
-    <xsl:text>
-
-</xsl:text>
-
-    <xsl:apply-templates select='*[not(self::d:info|self::d:title)]'/>
-  </xsl:template>
-
-  <xsl:template match='d:article/d:title|d:article/d:info/d:title'>
-    <xsl:text>
-	</xsl:text>
-    <xsl:apply-templates/>
-    <xsl:text>
-
-</xsl:text>
-
-    <xsl:if test='following-sibling::d:subtitle'>
-      <xsl:text>	</xsl:text>
-      <xsl:apply-templates select='following-sibling::d:subtitle'/>
-      <xsl:if test='following-sibling::d:revhistory'>
-        <xsl:text> Version </xsl:text>
-        <xsl:apply-templates select='following-sibling::d:revhistory/d:revision[1]/d:revnumber'/>
-      </xsl:if>
-    </xsl:if>
-    <xsl:text>
-
-</xsl:text>
-  </xsl:template>
-
-  <xsl:template match='d:author'>
-    <xsl:apply-templates select='d:firstname'/>
-    <xsl:text> </xsl:text>
-    <xsl:apply-templates select='d:surname'/>
-    <xsl:if test='d:affiliation'>
-      <xsl:text>, </xsl:text>
-      <xsl:apply-templates select='d:affiliation/d:orgname'/>
-    </xsl:if>
-  </xsl:template>
-
-  <xsl:template match='d:para'>
-    <xsl:param name='indent' select='0'/>
-    <xsl:param name='linelen' select='80'/>
-
-    <xsl:call-template name='str:justify'>
-      <xsl:with-param name='text'>
-        <xsl:apply-templates/>
-      </xsl:with-param>
-      <xsl:with-param name='indent' select='$indent'/>
-      <xsl:with-param name='max' select='$linelen'/>
-    </xsl:call-template>
-    <xsl:text>
-
-</xsl:text>
-  </xsl:template>
-
-  <xsl:template match='d:note'>
-    <xsl:call-template name='str:justify'>
-      <xsl:with-param name='text'>
-        <xsl:apply-templates/>
-      </xsl:with-param>
-      <xsl:with-param name='indent' select='4'/>
-    </xsl:call-template>
-    <xsl:text>
-
-</xsl:text>
-  </xsl:template>
-
-  <xsl:template match='d:section'>
-    <xsl:text>
-
-</xsl:text>
-    <xsl:apply-templates select='d:info/d:title'/>
-    <xsl:if test='d:info/d:subtitle'>
-      <xsl:text> (</xsl:text>
-      <xsl:apply-templates select='d:info/d:subtitle'/>
-      <xsl:text>)</xsl:text>
-    </xsl:if>
-    <xsl:text>
-</xsl:text>
-    <xsl:variable name='titlelen'>
-      <xsl:choose>
-        <xsl:when test='d:subtitle'>
-          <xsl:value-of select='string-length(d:info/d:title) + 3 + string-length(d:info/d:subtitle)'/>
-        </xsl:when>
-        <xsl:otherwise>
-          <xsl:value-of select='string-length(d:info/d:title)'/>
-        </xsl:otherwise>
-      </xsl:choose>
-    </xsl:variable>
-    <xsl:call-template name='str:generate-string'>
-      <xsl:with-param name='count' select='$titlelen'/>
-      <xsl:with-param name='text'>
-        <xsl:choose>
-          <xsl:when test='parent::d:section'>-</xsl:when>
-          <xsl:otherwise>=</xsl:otherwise>
-        </xsl:choose>
-      </xsl:with-param>
-    </xsl:call-template>
-    <xsl:text>
-
-</xsl:text>
-
-    <xsl:apply-templates select='*[not(self::d:info)]'/>
-  </xsl:template>
-
-  <xsl:template match='d:itemizedlist'>
-    <xsl:apply-templates select='d:listitem'/>
-    <xsl:text>
-</xsl:text>
-  </xsl:template>
-  <xsl:template match='d:itemizedlist/d:listitem'>
-    <xsl:call-template name='str:generate-string'>
-      <xsl:with-param name='text' select='" "'/>
-      <xsl:with-param name='count' select='count(ancestor::d:itemizedlist|ancestor::d:variablelist) * 4'/>
-    </xsl:call-template>
-
-    <xsl:text>* </xsl:text>
-    <xsl:apply-templates select='*'>
-      <xsl:with-param name='indent' select='count(ancestor::d:itemizedlist|ancestor::d:variablelist) * 4'/>
-      <xsl:with-param name='linelen' select='80 - count(ancestor::d:itemizedlist|ancestor::d:variablelist) * 4'/>
-    </xsl:apply-templates>
-  </xsl:template>
-
-  <xsl:template match='d:variablelist'>
-    <xsl:apply-templates select='d:varlistentry'/>
-  </xsl:template>
-  <xsl:template match='d:varlistentry'>
-    <xsl:call-template name='str:generate-string'>
-      <xsl:with-param name='text' select='" "'/>
-      <xsl:with-param name='count' select='(count(ancestor::d:variablelist|ancestor::d:itemizedlist) - 1) * 4'/>
-    </xsl:call-template>
-
-    <xsl:apply-templates select='d:term'/>
-    <xsl:apply-templates select='d:listitem'/>
-    <xsl:text>
-
-</xsl:text>
-  </xsl:template>
-  <xsl:template match='d:varlistentry/d:term'>
-    <xsl:apply-templates/>
-    <xsl:text>
-</xsl:text>
-  </xsl:template>
-  <xsl:template match='d:varlistentry/d:listitem'>
-    <xsl:apply-templates select='*'>
-      <xsl:with-param name='indent' select='count(ancestor::d:variablelist|ancestor::d:itemizedlist) * 4'/>
-    </xsl:apply-templates>
-  </xsl:template>
-
-  <xsl:template match='d:programlisting|d:literallayout'>
-    <xsl:call-template name='indent'>
-      <xsl:with-param name='text' select='.'/>
-      <xsl:with-param name='indent' select='(count(ancestor::d:itemizedlist|ancestor::d:variablelist) + 1) * 4'/>
-    </xsl:call-template>
-    <xsl:text>
-
-</xsl:text>
-  </xsl:template>
-
-  <xsl:template name='indent'>
-    <xsl:param name='text'/>
-    <xsl:param name='indent' select='4'/>
-
-    <xsl:choose>
-      <xsl:when test='not($text)'/>
-      <xsl:when test='contains($text, "&#xa;")'>
-        <xsl:call-template name='str:generate-string'>
-          <xsl:with-param name='text' select='" "'/>
-          <xsl:with-param name='count' select='$indent'/>
-        </xsl:call-template>
-        <xsl:value-of select='substring-before($text, "&#xa;")'/>
-        <xsl:text>
-</xsl:text>
-        <xsl:call-template name='indent'>
-          <xsl:with-param name='text' select='substring-after($text, "&#xa;")'/>
-          <xsl:with-param name='indent' select='$indent'/>
-        </xsl:call-template>
-      </xsl:when>
-      <xsl:otherwise>
-        <xsl:call-template name='str:generate-string'>
-          <xsl:with-param name='text' select='" "'/>
-          <xsl:with-param name='count' select='$indent'/>
-        </xsl:call-template>
-        <xsl:value-of select='$text'/>
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:template>
-
-  <xsl:template match='d:link'>
-    <xsl:apply-templates/>
-    <xsl:text> [</xsl:text>
-    <xsl:value-of select='@xlink:href'/>
-    <xsl:text>]</xsl:text>
-  </xsl:template>
-
-</xsl:stylesheet>
diff --git a/tclxml-3.2/doc/xsltsl/cmp.xsl b/tclxml-3.2/doc/xsltsl/cmp.xsl
deleted file mode 100755
index 977c5c6..0000000
--- a/tclxml-3.2/doc/xsltsl/cmp.xsl
+++ /dev/null
@@ -1,351 +0,0 @@
-<?xml version="1.0"?>
-
-<xsl:stylesheet
-  version="1.0"
-  extension-element-prefixes="doc"
-  xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
-  xmlns:doc="http://xsltsl.org/xsl/documentation/1.0"
-  xmlns:str="http://xsltsl.org/string"
-  xmlns:cmp="http://xsltsl.org/cmp"
-  exclude-result-prefixes="cmp str doc"
->
-
-  <doc:reference xmlns="">
-    <referenceinfo>
-      <releaseinfo role="meta">
-        $Id: cmp.xsl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-      </releaseinfo>
-      <author>
-        <surname>Hummel</surname>
-        <firstname>Mark</firstname>
-      </author>
-      <copyright>
-        <year>2003</year>
-        <holder>Mark Hummel</holder>
-      </copyright>
-    </referenceinfo>
-
-    <title>XML Compare</title>
-
-    <partintro>
-      <section>
-        <title>Introduction</title>
-
-        <para>This module provides a template for comparing two xml documents. </para>
-
-      </section>
-    </partintro>
-
-  </doc:reference>
-
-
-  <doc:template name="cmp:diff">
-    <refpurpose>Find differences</refpurpose>
-
-    <refdescription>
-      <para>Compare two xml documents and display differences. Two xml documents are defined to be the same if: They have the matching elements and attributes, and that the data in the elements also match. The comparison is order sensitive. </para>
-
-      <para>The element names from the documents at the current depth are compared, followed by their values, then any attribute names and values are compared. The process is applied then to the subtrees of the documents.</para>
-
-      <para>Notes: If there are leaf nodes in one nodeset which don't exist in the other, the value of those 'extra' elements won't appear as a difference.
-      </para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>ns1</term>
-          <term>ns2</term>
-          <listitem>
-            <para>The two nodesets which are to be compared. </para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns the difference between the documents. </para>
-
-      <para>The format of the output is an xml document. A node is added to the result tree for every difference. The node contains the type of difference (e.g element name difference, attribute value difference, etc), the value in the first nodeset and the value in the second nodeset, and the parent node. The indentation level is the depth at which the difference was found relative to the first document. </para>
-
-    </refreturn>
-  </doc:template>
-
-  <!-- pass in a nodeset and compare. Is order sensitive. Output attribute, element and textual differences. -->
-
-  <xsl:template name="cmp:diff">
-    <xsl:param name="ns1"/>
-    <xsl:param name="ns2"/>
-
-    <!-- attribute compare -->
-	<!-- Optimisation attempt 
-
-	Can probaby change this into one loop ie -
-	<xsl:for-each 
-	  i = position
-	 if node1[i] = node2[i]...
-
-	  -->
-
-	<!-- Need to check if there are two sets of attributes -->
-	<xsl:choose>
-	  <xsl:when test='count($ns1/attribute::*) = count($ns2/attribute::*)'>
-	    <xsl:for-each select="$ns1/attribute::*">
-	      <xsl:variable name="name1" select="name()"/>
-	      <xsl:variable name="value1" select="."/>
-	      <xsl:variable name="i" select="position()"/>
-	      
-	      <xsl:for-each select="$ns2/attribute::*">
-		
-		<xsl:variable name="j" select="position()"/>
-		<xsl:variable name="name2" select="name()"/>
-		<xsl:variable name="value2" select="."/>
-		
-		<xsl:if test="$i = $j">
-		  <xsl:if test="$name1 != $name2">
-		    <attributeNameDifference>
-	              <parentElement><xsl:value-of select="name(..)"/></parentElement>
-                      <before><xsl:value-of select="$name1"/></before>
-	              <after><xsl:value-of select="$name2"/></after>
-		    </attributeNameDifference>
-		  </xsl:if>
-		  
-		  <xsl:if test="$name1 = $name2 and $value1 != $value2">
-		    <attributeValueDifference>
-		      <parentElement><xsl:value-of select="name(..)"/></parentElement>
-		      <before><xsl:value-of select="$value1"/></before>
-		      <after><xsl:value-of select="$value2"/></after>
-		    </attributeValueDifference>
-		  </xsl:if>
-	      
-		</xsl:if>
-	      </xsl:for-each>
-	    </xsl:for-each>
-	    </xsl:when>
-	  <xsl:otherwise>
-	    <attributeNameDifference>
-	      <parentElement>
-		<xsl:value-of select="name(..)"/>
-	      </parentElement>
-	      <before><xsl:value-of select='$ns1/attribute::*'/></before>
-	      <after><xsl:value-of select='$ns2/attribute::*'/></after>
-	    </attributeNameDifference>
-	  </xsl:otherwise>
-	</xsl:choose>
-	
-
-  <!-- Find element differences by comparing the element names from the same position in both documents. Iterate over all the nodes in the nodeset with the largest number of elements, so the extra elements will appear as differences. -->
-
-    <xsl:choose>
-      <!-- Define loop direction based on which tree has more nodes
-	   FIXME: Replacing this with one for-each and a test for the case 
-	          of the second tree having more nodes would be more elegant 
-
-	   Solution: Add variable for direction and assign the 'larger' nodeset to that
-	             variable. Then do one for-each. 
-	   
-	   FIXME: The solution is a bit too iterative. Make it more functional
-
-      -->
-     <xsl:when test="count($ns1) > count($ns2)">
-       <xsl:for-each select="$ns1">
-          <xsl:variable name="i" select="position()"/> 
-	  
-	  <xsl:message>node[<xsl:value-of select='$i'/>]:
-	    <xsl:value-of select='$ns1[$i]'/>
-	  </xsl:message>
-
-	<!-- Element name compare -->
-	  <xsl:if test="name($ns1[$i]) != name($ns2[$i])">
-        	<elementNameDifference>
-		  <parentElement><xsl:value-of select="name(..)"/></parentElement>
-		  <before><xsl:value-of select="name($ns1[$i])"/></before>
-		  <after><xsl:value-of select="name($ns2[$i])"/></after>
-  	        </elementNameDifference>
-	  </xsl:if>
-	
-	  <!-- Element Value compare -->
-	  <!-- Check if there are descendants so that reported differences
-	    don't cascade. -->
-	  <xsl:if test="count($ns1[$i]/*) = 0">
-            <xsl:if test="$ns1[$i] != $ns2[$i]">
-	         <elementValueDifference>
-	           <parentElement><xsl:value-of select="name(..)"/></parentElement>
-		   <before><xsl:value-of select="$ns1[$i]"/></before>
- 		   <after><xsl:value-of select="$ns2[$i]"/></after>
-	         </elementValueDifference>
-	    </xsl:if>
-	 </xsl:if>
-	
-       </xsl:for-each>
-      </xsl:when>
-      <xsl:otherwise>
-        <xsl:for-each select="$ns2">
-          <xsl:variable name="i" select="position()"/> 
-
-	  <!-- Element Name compare -->
-	
-	  <xsl:if test="name($ns1[$i]) != name($ns2[$i])">
-	       <elementNameDifference>
-		  <parentElement><xsl:value-of select="name(..)"/></parentElement>
-		  <before><xsl:value-of select="name($ns1[$i])"/></before>
-		  <after><xsl:value-of select="name($ns2[$i])"/></after>
-	       </elementNameDifference>
-
-	  </xsl:if>
-	
-	  <!-- value compare -->
-	  <!-- Check if there are descendants so that reported differences
-	       don't cascade. -->
-	
-	  <xsl:if test="count($ns2[$i]/*) = 0">
-	     <xsl:if test="$ns2[$i] != $ns1[$i]">
-		 <elementValueDifference>
-		   <parentElement><xsl:value-of select="name(..)"/></parentElement>
-		   <after><xsl:value-of select="$ns2[$i]"/></after>
-                   <before><xsl:value-of select="$ns1[$i]"/></before>
-		 </elementValueDifference>
-	     </xsl:if>
-	  </xsl:if>
-	
-        </xsl:for-each>
-      </xsl:otherwise>
-    </xsl:choose>
-	
-  <!-- stop processing when leaf node is reached. -->
-
-    <xsl:if test="count($ns1/*) > 0 and count($ns2/*) > 0">
-      <xsl:call-template name="cmp:diff">
-            <xsl:with-param name="ns1" select="$ns1/*"/>
-            <xsl:with-param name="ns2" select="$ns2/*"/>
-        </xsl:call-template>
-    </xsl:if>
-
-  </xsl:template>
-
-  <!-- Return false if the two nodesets are not identical
-  -->
-
-  <doc:template name="cmp:cmp">
-    <refpurpose>Compare</refpurpose>
-
-    <refdescription>
-      <para>Recursively compare two xml nodesets, stop when a difference is found and return false. Otherwise return true if the document is identical. </para>
-
-      <para>The element names from the documents at the current depth are compared, followed by their values, then any attribute names and values are compared. The process is applied then to the subtrees of the documents.</para>
-
-      <para>Notes: If there are leaf nodes in one nodeset which don't exist in the other, the value of those 'extra' elements won't appear as a difference.
-      </para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>ns1</term>
-          <term>ns2</term>
-          <listitem>
-            <para>The two nodesets which are to be compared. </para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>False when the nodesets are not identical, empty otherwise. </para>
-
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name="cmp:cmp">
-   <xsl:param name="ns1"/>     	
-   <xsl:param name="ns2"/>     	
-   <xsl:param name="depth"/>
-
-   <xsl:choose>
-     <xsl:when test='count($ns1) != count($ns2)'>
-       <xsl:value-of select='"countDiff"'/>
-     </xsl:when>
-     <xsl:when test='count($ns1/attribute::*) != count($ns2/attribute::*)'>
-       <xsl:value-of select='"countDiff"'/>
-     </xsl:when>
-     <xsl:when test='$ns1 and $ns2'>
-
-       <xsl:variable name='result'>
-	<xsl:call-template name='cmp:cmp'>
-	  <xsl:with-param name='ns1' select='$ns1/*'/>
-	  <xsl:with-param name='ns2' select='$ns2/*'/>
-	  <xsl:with-param name='depth' select='$depth+1'/>
-	</xsl:call-template>
-	</xsl:variable>	
-
-       <xsl:choose>
-	  <xsl:when test='$result = "countDiff"'>
-	    <xsl:value-of select='$result'/>
-	  </xsl:when>
-	  <xsl:when test='$result = "textDiff"'>
-	    <xsl:value-of select='$result'/>
-	  </xsl:when>	  
-	  <xsl:when test='$result = ""'>
-
-	    <xsl:variable name='keyText1' select='name($ns1)'/>
-	    <xsl:variable name='keyText2' select='name($ns2)'/>
-	    	    
-	    <xsl:choose>
-	      <!-- Check if the text of the nodesets are the same and the attributes-->
-	      <xsl:when test='$ns1 = $ns2 and $keyText1 = $keyText2'>
-
-		<!-- Check the attribute names are the same -->
-		<!-- Number of attributes being different is caught higher up -->
-		<xsl:if test='count($ns1/attribute::*)'>
-		  <xsl:for-each select='$ns1/attribute::*'>
-		    <xsl:variable name='i' select='position()'/>
-		    <xsl:variable name='name1' select='name(.)'/>
-                    <xsl:variable name='value1' select='.'/>
-		    
-		    <xsl:for-each select='$ns2/attribute::*'>
-		      <xsl:variable name='j' select='position()'/>
-		      <xsl:variable name='name2' select='name(.)'/>
-                      <xsl:variable name='value2' select='.'/>
-
-                      <xsl:if test='$i = $j and ($name1 != $name2 or 
-                                    $value1 != $value2)'>
-			<xsl:value-of select='"textDiff"'/>
-		      </xsl:if>
-		      
-		    </xsl:for-each>
-		  </xsl:for-each>
-		</xsl:if>
-		<!--
-		<xsl:variable name='diffResult'>
-		  <xsl:call-template name='cmp:diff'>
-		    <xsl:with-param name='ns1' select='$ns1'/>
-		    <xsl:with-param name='ns2' select='$ns2'/>
-		  </xsl:call-template>
-		</xsl:variable>
-		
-		<xsl:if test='not($diffResult = "")'>
-		  <xsl:value-of select='"textDiff"'/>
-		</xsl:if>
-		-->
-
-	      </xsl:when>
-	      <xsl:otherwise>
-		<xsl:value-of select='"textDiff"'/>
-	      </xsl:otherwise>
-	    </xsl:choose>
-	  </xsl:when>
-	</xsl:choose>
-	  
-     </xsl:when>
-     <xsl:when test='$ns1 and not($ns2)'>
-       <xsl:value-of select='"structDiff"'/>
-     </xsl:when>
-     <xsl:when test='$ns2 and not($ns1)'>
-       <xsl:value-of select='"structDiff"'/>
-     </xsl:when>
-   </xsl:choose>
-
-  </xsl:template>
-
-</xsl:stylesheet>
-
diff --git a/tclxml-3.2/doc/xsltsl/date-time.xsl b/tclxml-3.2/doc/xsltsl/date-time.xsl
deleted file mode 100644
index b605efb..0000000
--- a/tclxml-3.2/doc/xsltsl/date-time.xsl
+++ /dev/null
@@ -1,2092 +0,0 @@
-<xsl:stylesheet version="1.0"
-  xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
-  xmlns:doc="http://xsltsl.org/xsl/documentation/1.0"
-  xmlns:dt="http://xsltsl.org/date-time"
-  xmlns:str="http://xsltsl.org/string"
-  extension-element-prefixes="doc str">
-
-  <doc:reference xmlns="">
-    <referenceinfo>
-      <releaseinfo role="meta">
-        $Id: date-time.xsl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-      </releaseinfo>
-      <author>
-        <surname>Diamond</surname>
-        <firstname>Jason</firstname>
-      </author>
-      <copyright>
-        <year>2004</year>
-        <holder>Steve Ball</holder>
-      </copyright>
-      <copyright>
-        <year>2001</year>
-        <holder>Jason Diamond</holder>
-      </copyright>
-    </referenceinfo>
-
-    <title>Date/Time Processing</title>
-
-    <partintro>
-      <section>
-        <title>Introduction</title>
-
-        <para>This module provides templates for formatting and parsing date/time strings.</para>
-
-        <para>See <ulink url="http://www.tondering.dk/claus/calendar.html">http://www.tondering.dk/claus/calendar.html</ulink> for more information on calendars and the calculations this library performs.</para>
-
-      </section>
-    </partintro>
-
-  </doc:reference>
-
-  <doc:template name="dt:format-date-time" xmlns="">
-    <refpurpose>Returns a string with a formatted date/time.</refpurpose>
-
-    <refdescription>
-      <para>The formatted date/time is determined by the format parameter. The default format is %Y-%m-%dT%H:%M:%S%z, the W3C format.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-
-        <varlistentry>
-          <term>xsd-date-time</term>
-          <listitem>
-            <para>The date-time value in XML Schemas (WXS) format.</para>
-            <para>If this value is specified, it takes priority over other parameters.</para>
-          </listitem>
-        </varlistentry>
-
-        <varlistentry>
-          <term>year</term>
-          <listitem>
-            <para>Year, in either 2 or 4+ digit format..</para>
-            <para>If the year is given as a two digit value, it will be converted to a four digit value using the fixed window method.  Values between 00 and 49 will be prepended by "20".  Values between 50 and 99 will be prepended by "19".</para>
-          </listitem>
-        </varlistentry>
-
-        <varlistentry>
-          <term>month</term>
-          <listitem>
-            <para>Month (1 - 12; January = 1)</para>
-          </listitem>
-        </varlistentry>
-
-        <varlistentry>
-          <term>day</term>
-          <listitem>
-            <para>Day of month (1 - 31)</para>
-          </listitem>
-        </varlistentry>
-
-        <varlistentry>
-          <term>hour</term>
-          <listitem>
-            <para>Hours since midnight (0 - 23)</para>
-          </listitem>
-        </varlistentry>
-
-        <varlistentry>
-          <term>minute</term>
-          <listitem>
-            <para>Minutes after hour (0 - 59)</para>
-          </listitem>
-        </varlistentry>
-
-        <varlistentry>
-          <term>second</term>
-          <listitem>
-            <para>Seconds after minute (0 - 59)</para>
-          </listitem>
-        </varlistentry>
-
-        <varlistentry>
-          <term>time-zone</term>
-          <listitem>
-            <para>Time zone string (e.g., 'Z' or '-08:00')</para>
-          </listitem>
-        </varlistentry>
-
-        <varlistentry>
-          <term>format</term>
-          <listitem>
-            <para>The format specification.</para>
-            <variablelist>
-
-              <varlistentry>
-                <term>%a</term>
-                <listitem>
-                  <para>Abbreviated weekday name</para>
-                </listitem>
-              </varlistentry>
-
-              <varlistentry>
-                <term>%A</term>
-                <listitem>
-                  <para>Full weekday name</para>
-                </listitem>
-              </varlistentry>
-
-              <varlistentry>
-                <term>%b</term>
-                <listitem>
-                  <para>Abbreviated month name</para>
-                </listitem>
-              </varlistentry>
-
-              <varlistentry>
-                <term>%B</term>
-                <listitem>
-                  <para>Full month name</para>
-                </listitem>
-              </varlistentry>
-
-              <varlistentry>
-                <term>%c</term>
-                <listitem>
-                  <para>Date and time representation appropriate for locale</para>
-                </listitem>
-              </varlistentry>
-
-              <varlistentry>
-                <term>%d</term>
-                <listitem>
-                  <para>Day of month as decimal number (01 - 31)</para>
-                </listitem>
-              </varlistentry>
-
-              <varlistentry>
-                <term>%e</term>
-                <listitem>
-                  <para>Day of month as decimal number (1 - 31)</para>
-                </listitem>
-              </varlistentry>
-
-              <varlistentry>
-                <term>%H</term>
-                <listitem>
-                  <para>Hour in 24-hour format (00 - 23)</para>
-                </listitem>
-              </varlistentry>
-
-              <varlistentry>
-                <term>%I</term>
-                <listitem>
-                  <para>Hour in 12-hour format (01 - 12)</para>
-                </listitem>
-              </varlistentry>
-
-              <varlistentry>
-                <term>%i</term>
-                <listitem>
-                  <para>Hour in 12-hour format (1 - 12)</para>
-                </listitem>
-              </varlistentry>
-
-              <varlistentry>
-                <term>%j</term>
-                <listitem>
-                  <para>Day of year as decimal number (001 - 366)</para>
-                </listitem>
-              </varlistentry>
-
-              <varlistentry>
-                <term>%m</term>
-                <listitem>
-                  <para>Month as decimal number (01 - 12)</para>
-                </listitem>
-              </varlistentry>
-
-              <varlistentry>
-                <term>%n</term>
-                <listitem>
-                  <para>Month as decimal number (1 - 12)</para>
-                </listitem>
-              </varlistentry>
-
-              <varlistentry>
-                <term>%M</term>
-                <listitem>
-                  <para>Minute as decimal number (00 - 59)</para>
-                </listitem>
-              </varlistentry>
-
-              <varlistentry>
-                <term>%P</term>
-                <listitem>
-                  <para>Current locale's A.M./P.M. indicator for 12-hour clock, uppercase</para>
-                </listitem>
-              </varlistentry>
-
-              <varlistentry>
-                <term>%Q</term>
-                <listitem>
-                  <para>Current locale's A.M./P.M. indicator for 12-hour clock, uppercase with periods</para>
-                </listitem>
-              </varlistentry>
-
-              <varlistentry>
-                <term>%p</term>
-                <listitem>
-                  <para>Current locale's A.M./P.M. indicator for 12-hour clock, lowercase</para>
-                </listitem>
-              </varlistentry>
-
-              <varlistentry>
-                <term>%q</term>
-                <listitem>
-                  <para>Current locale's A.M./P.M. indicator for 12-hour clock, lowercase with periods</para>
-                </listitem>
-              </varlistentry>
-
-              <varlistentry>
-                <term>%S</term>
-                <listitem>
-                  <para>Second as decimal number (00 - 59)</para>
-                </listitem>
-              </varlistentry>
-
-              <varlistentry>
-                <term>%U</term>
-                <listitem>
-                  <para>Week of year as decimal number, with Sunday as first day of week (00 - 53)</para>
-                </listitem>
-              </varlistentry>
-
-              <varlistentry>
-                <term>%w</term>
-                <listitem>
-                  <para>Weekday as decimal number (0 - 6; Sunday is 0)</para>
-                </listitem>
-              </varlistentry>
-
-              <varlistentry>
-                <term>%W</term>
-                <listitem>
-                  <para>Week of year as decimal number, with Monday as first day of week (00 - 53)</para>
-                </listitem>
-              </varlistentry>
-
-              <varlistentry>
-                <term>%x</term>
-                <listitem>
-                  <para>Date representation for current locale </para>
-                </listitem>
-              </varlistentry>
-
-              <varlistentry>
-                <term>%X</term>
-                <listitem>
-                  <para>Time representation for current locale</para>
-                </listitem>
-              </varlistentry>
-
-              <varlistentry>
-                <term>%y</term>
-                <listitem>
-                  <para>Year without century, as decimal number (00 - 99)</para>
-                </listitem>
-              </varlistentry>
-
-              <varlistentry>
-                <term>%Y</term>
-                <listitem>
-                  <para>Year with century, as decimal number</para>
-                </listitem>
-              </varlistentry>
-
-              <varlistentry>
-                <term>%z</term>
-                <listitem>
-                  <para>Time-zone name or abbreviation; no characters if time zone is unknown</para>
-                </listitem>
-              </varlistentry>
-
-              <varlistentry>
-                <term>%%</term>
-                <listitem>
-                  <para>Percent sign</para>
-                </listitem>
-              </varlistentry>
-
-            </variablelist>
-          </listitem>
-        </varlistentry>
-
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns a formatted date/time string.</para>
-    </refreturn>
-
-  </doc:template>
-
-  <xsl:template name="dt:format-date-time">
-    <xsl:param name='xsd-date-time'/>
-    <xsl:param name="year"/>
-    <xsl:param name="month"/>
-    <xsl:param name="day"/>
-    <xsl:param name="hour"/>
-    <xsl:param name="minute"/>
-    <xsl:param name="second"/>
-    <xsl:param name="time-zone"/>
-    <xsl:param name="format" select="'%Y-%m-%dT%H:%M:%S%z'"/>
-
-    <xsl:value-of select="substring-before($format, '%')"/>
-
-    <xsl:variable name="code" select="substring(substring-after($format, '%'), 1, 1)"/>
-
-    <xsl:choose>
-
-      <xsl:when test='$xsd-date-time'>
-        <xsl:call-template name='dt:format-date-time'>
-          <xsl:with-param name='year'>
-            <xsl:call-template name='dt:get-xsd-datetime-year'>
-              <xsl:with-param name='xsd-date-time' select='$xsd-date-time'/>
-            </xsl:call-template>
-          </xsl:with-param>
-          <xsl:with-param name='month'>
-            <xsl:call-template name='dt:get-xsd-datetime-month'>
-              <xsl:with-param name='xsd-date-time' select='$xsd-date-time'/>
-            </xsl:call-template>
-          </xsl:with-param>
-          <xsl:with-param name='day'>
-            <xsl:call-template name='dt:get-xsd-datetime-day'>
-              <xsl:with-param name='xsd-date-time' select='$xsd-date-time'/>
-            </xsl:call-template>
-          </xsl:with-param>
-          <xsl:with-param name='hour'>
-            <xsl:call-template name='dt:get-xsd-datetime-hour'>
-              <xsl:with-param name='xsd-date-time' select='$xsd-date-time'/>
-            </xsl:call-template>
-          </xsl:with-param>
-          <xsl:with-param name='minute'>
-            <xsl:call-template name='dt:get-xsd-datetime-minute'>
-              <xsl:with-param name='xsd-date-time' select='$xsd-date-time'/>
-            </xsl:call-template>
-          </xsl:with-param>
-          <xsl:with-param name='second'>
-            <xsl:call-template name='dt:get-xsd-datetime-second'>
-              <xsl:with-param name='xsd-date-time' select='$xsd-date-time'/>
-            </xsl:call-template>
-          </xsl:with-param>
-          <xsl:with-param name='time-zone'>
-            <xsl:call-template name='dt:get-xsd-datetime-timezone'>
-              <xsl:with-param name='xsd-date-time' select='$xsd-date-time'/>
-            </xsl:call-template>
-          </xsl:with-param>
-          <xsl:with-param name='format'>
-            <xsl:choose>
-              <xsl:when test='contains($format, "%")'>
-                <xsl:text>%</xsl:text>
-                <xsl:value-of select='substring-after($format, "%")'/>
-              </xsl:when>
-              <xsl:otherwise>
-                <xsl:value-of select='$format'/>
-              </xsl:otherwise>
-            </xsl:choose>
-          </xsl:with-param>
-        </xsl:call-template>
-      </xsl:when>
-
-      <!-- Abbreviated weekday name -->
-      <xsl:when test="$code='a'">
-        <xsl:variable name="day-of-the-week">
-          <xsl:call-template name="dt:calculate-day-of-the-week">
-            <xsl:with-param name="year" select="$year"/>
-            <xsl:with-param name="month" select="$month"/>
-            <xsl:with-param name="day" select="$day"/>
-          </xsl:call-template>
-        </xsl:variable>
-        <xsl:call-template name="dt:get-day-of-the-week-abbreviation">
-          <xsl:with-param name="day-of-the-week" select="$day-of-the-week"/>
-        </xsl:call-template>
-      </xsl:when>
-
-      <!-- Full weekday name -->
-      <xsl:when test="$code='A'">
-        <xsl:variable name="day-of-the-week">
-          <xsl:call-template name="dt:calculate-day-of-the-week">
-            <xsl:with-param name="year" select="$year"/>
-            <xsl:with-param name="month" select="$month"/>
-            <xsl:with-param name="day" select="$day"/>
-          </xsl:call-template>
-        </xsl:variable>
-        <xsl:call-template name="dt:get-day-of-the-week-name">
-          <xsl:with-param name="day-of-the-week" select="$day-of-the-week"/>
-        </xsl:call-template>
-      </xsl:when>
-
-      <!-- Abbreviated month name -->
-      <xsl:when test="$code='b'">
-        <xsl:call-template name="dt:get-month-abbreviation">
-          <xsl:with-param name="month" select="$month"/>
-        </xsl:call-template>
-      </xsl:when>
-
-      <!-- Full month name -->
-      <xsl:when test="$code='B'">
-        <xsl:call-template name="dt:get-month-name">
-          <xsl:with-param name="month" select="$month"/>
-        </xsl:call-template>
-      </xsl:when>
-
-      <!-- Date and time representation appropriate for locale -->
-      <xsl:when test="$code='c'">
-        <xsl:text>[not implemented]</xsl:text>
-      </xsl:when>
-
-      <!-- Day of month as decimal number (01 - 31) -->
-      <xsl:when test="$code='d'">
-        <xsl:if test="$day < 10">0</xsl:if>
-        <xsl:value-of select="number($day)"/>
-      </xsl:when>
-      <!-- Day of month as decimal number (1 - 31) -->
-      <xsl:when test="$code='e'">
-        <xsl:value-of select="number($day)"/>
-      </xsl:when>
-
-      <!-- Hour in 24-hour format (00 - 23) -->
-      <xsl:when test="$code='H'">
-        <xsl:if test="$hour < 10">0</xsl:if>
-        <xsl:value-of select="number($hour)"/>
-      </xsl:when>
-
-      <!-- Hour in 12-hour format (01 - 12) -->
-      <xsl:when test="$code='I'">
-        <xsl:choose>
-          <xsl:when test="$hour = 0">12</xsl:when>
-          <xsl:when test="$hour < 10">0<xsl:value-of select="$hour - 0"/></xsl:when>
-          <xsl:when test="$hour < 13"><xsl:value-of select="$hour - 0"/></xsl:when>
-          <xsl:when test="$hour < 22">0<xsl:value-of select="$hour - 12"/></xsl:when>
-          <xsl:otherwise><xsl:value-of select="$hour - 12"/></xsl:otherwise>
-        </xsl:choose>
-      </xsl:when>
-      <!-- Hour in 12-hour format (1 - 12) -->
-      <xsl:when test="$code='i'">
-        <xsl:choose>
-          <xsl:when test="$hour = 0">12</xsl:when>
-          <xsl:when test="$hour < 10"><xsl:value-of select="$hour - 0"/></xsl:when>
-          <xsl:when test="$hour < 13"><xsl:value-of select="$hour - 0"/></xsl:when>
-          <xsl:when test="$hour < 22"><xsl:value-of select="$hour - 12"/></xsl:when>
-          <xsl:otherwise><xsl:value-of select="$hour - 12"/></xsl:otherwise>
-        </xsl:choose>
-      </xsl:when>
-
-      <!-- Day of year as decimal number (001 - 366) -->
-      <xsl:when test="$code='j'">
-        <xsl:text>[not implemented]</xsl:text>
-      </xsl:when>
-
-      <!-- Month as decimal number (01 - 12) -->
-      <xsl:when test="$code='m'">
-        <xsl:if test="$month < 10">0</xsl:if>
-        <xsl:value-of select="number($month)"/>
-      </xsl:when>
-      <!-- Month as decimal number (1 - 12) -->
-      <xsl:when test="$code='n'">
-        <xsl:value-of select="number($month)"/>
-      </xsl:when>
-
-      <!-- Minute as decimal number (00 - 59) -->
-      <xsl:when test="$code='M'">
-        <xsl:if test="$minute < 10">0</xsl:if>
-        <xsl:value-of select="number($minute)"/>
-      </xsl:when>
-
-      <!-- Current locale's A.M./P.M. indicator for 12-hour clock -->
-      <xsl:when test="$code='p'">
-        <xsl:choose>
-          <xsl:when test="$hour < 12">am</xsl:when>
-          <xsl:otherwise>pm</xsl:otherwise>
-        </xsl:choose>
-      </xsl:when>
-      <!-- Current locale's A.M./P.M. indicator for 12-hour clock with periods -->
-      <xsl:when test="$code='q'">
-        <xsl:choose>
-          <xsl:when test="$hour < 12">am</xsl:when>
-          <xsl:otherwise>p.m.</xsl:otherwise>
-        </xsl:choose>
-      </xsl:when>
-      <!-- Current locale's A.M./P.M. indicator for 12-hour clock -->
-      <xsl:when test="$code='P'">
-        <xsl:choose>
-          <xsl:when test="$hour < 12">AM</xsl:when>
-          <xsl:otherwise>PM</xsl:otherwise>
-        </xsl:choose>
-      </xsl:when>
-      <!-- Current locale's A.M./P.M. indicator for 12-hour clock with periods -->
-      <xsl:when test="$code='Q'">
-        <xsl:choose>
-          <xsl:when test="$hour < 12">AM</xsl:when>
-          <xsl:otherwise>P.M.</xsl:otherwise>
-        </xsl:choose>
-      </xsl:when>
-
-      <!-- Second as decimal number (00 - 59) -->
-      <xsl:when test="$code='S'">
-        <xsl:if test="$second < 10">0</xsl:if>
-        <xsl:value-of select="number($second)"/>
-      </xsl:when>
-
-      <!-- Week of year as decimal number, with Sunday as first day of week (00 - 53) -->
-      <xsl:when test="$code='U'">
-        <!-- add 1 to day -->
-        <xsl:call-template name="dt:calculate-week-number">
-          <xsl:with-param name="year" select="$year"/>
-          <xsl:with-param name="month" select="$month"/>
-          <xsl:with-param name="day" select="$day + 1"/>
-        </xsl:call-template>
-      </xsl:when>
-
-      <!-- Weekday as decimal number (0 - 6; Sunday is 0) -->
-      <xsl:when test="$code='w'">
-        <xsl:call-template name="dt:calculate-day-of-the-week">
-          <xsl:with-param name="year" select="$year"/>
-          <xsl:with-param name="month" select="$month"/>
-          <xsl:with-param name="day" select="$day"/>
-        </xsl:call-template>
-      </xsl:when>
-
-      <!-- Week of year as decimal number, with Monday as first day of week (00 - 53) -->
-      <xsl:when test="$code='W'">
-        <xsl:call-template name="dt:calculate-week-number">
-          <xsl:with-param name="year" select="$year"/>
-          <xsl:with-param name="month" select="$month"/>
-          <xsl:with-param name="day" select="$day"/>
-        </xsl:call-template>
-      </xsl:when>
-
-      <!-- Date representation for current locale -->
-      <xsl:when test="$code='x'">
-        <xsl:text>[not implemented]</xsl:text>
-      </xsl:when>
-
-      <!-- Time representation for current locale -->
-      <xsl:when test="$code='X'">
-        <xsl:text>[not implemented]</xsl:text>
-      </xsl:when>
-
-      <!-- Year without century, as decimal number (00 - 99) -->
-      <xsl:when test="$code='y'">
-        <xsl:choose>
-          <xsl:when test='not(number($year))'>invalid year value</xsl:when>
-
-          <!-- workaround MSXML bug -->
-          <xsl:when test='number($year) mod 100 = 0'>00</xsl:when>
-
-          <xsl:otherwise>
-            <xsl:number format='01' value='number($year) mod 100'/>
-          </xsl:otherwise>
-        </xsl:choose>
-      </xsl:when>
-
-      <!-- Year with century, as decimal number -->
-      <xsl:when test="$code='Y'">
-        <xsl:choose>
-          <xsl:when test='not(number($year))'>invalid year value</xsl:when>
-          <xsl:when test='string-length($year) = 2'>
-            <xsl:call-template name='dt:format-two-digit-year'>
-              <xsl:with-param name='year' select='$year'/>
-            </xsl:call-template>
-          </xsl:when>
-          <xsl:when test='string-length($year) >= 4'>
-            <xsl:value-of select='$year'/>
-          </xsl:when>
-          <xsl:otherwise>invalid year value</xsl:otherwise>
-        </xsl:choose>
-      </xsl:when>
-
-      <!-- Time-zone name or abbreviation; no characters if time zone is unknown -->
-      <xsl:when test="$code='z'">
-        <xsl:value-of select="$time-zone"/>
-      </xsl:when>
-
-      <!-- Percent sign -->
-      <xsl:when test="$code='%'">
-        <xsl:text>%</xsl:text>
-      </xsl:when>
-
-    </xsl:choose>
-
-    <xsl:variable name="remainder" select="substring(substring-after($format, '%'), 2)"/>
-
-    <xsl:if test="not($xsd-date-time) and $remainder">
-      <xsl:call-template name="dt:format-date-time">
-        <xsl:with-param name="year" select="$year"/>
-        <xsl:with-param name="month" select="$month"/>
-        <xsl:with-param name="day" select="$day"/>
-        <xsl:with-param name="hour" select="$hour"/>
-        <xsl:with-param name="minute" select="$minute"/>
-        <xsl:with-param name="second" select="$second"/>
-        <xsl:with-param name="time-zone" select="$time-zone"/>
-        <xsl:with-param name="format" select="$remainder"/>
-      </xsl:call-template>
-    </xsl:if>
-
-  </xsl:template>
-
-  <doc:template name="dt:calculate-day-of-the-week" xmlns="">
-    <refpurpose>Calculates the day of the week.</refpurpose>
-
-    <refdescription>
-      <para>Given any Gregorian date, this calculates the day of the week.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>year</term>
-          <listitem>
-            <para>Year</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>month</term>
-          <listitem>
-            <para>Month (1 - 12; January = 1)</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>day</term>
-          <listitem>
-            <para>Day of month (1 - 31)</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns the day of the week (0 - 6; Sunday = 0).</para>
-    </refreturn>
-
-  </doc:template>
-
-  <xsl:template name="dt:calculate-day-of-the-week">
-    <xsl:param name="year"/>
-    <xsl:param name="month"/>
-    <xsl:param name="day"/>
-
-    <xsl:variable name="a" select="floor((14 - $month) div 12)"/>
-    <xsl:variable name="y" select="$year - $a"/>
-    <xsl:variable name="m" select="$month + 12 * $a - 2"/>
-
-    <xsl:value-of select="($day + $y + floor($y div 4) - floor($y div 100) + floor($y div 400) + floor((31 * $m) div 12)) mod 7"/>
-
-  </xsl:template>
-
-  <doc:template name="dt:calculate-last-day-of-month" xmlns="">
-    <refpurpose>Calculates the number of days for a specified month.</refpurpose>
-
-    <refdescription>
-      <para>Given any Gregorian month, this calculates the last day of the month.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>year</term>
-          <listitem>
-            <para>Year</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>month</term>
-          <listitem>
-            <para>Month (1 - 12; January = 1)</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns the number of days in given month as a decimal number.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name="dt:calculate-last-day-of-month">
-    <xsl:param name="year"/>
-    <xsl:param name="month"/>
-
-    <xsl:choose>
-      <xsl:when test="$month = 2">
-        <xsl:choose> 
-          <xsl:when test="($year mod 4) = 0 and (($year mod 400) = 0
-                          or ($year mod 100) != 0)">29</xsl:when>
-          <xsl:otherwise>28</xsl:otherwise>
-        </xsl:choose>
-      </xsl:when>
-      <xsl:when test="$month < 8">
-        <xsl:choose>
-          <xsl:when test="$month mod 2 = 0">30</xsl:when>
-          <xsl:otherwise>31</xsl:otherwise>
-        </xsl:choose>
-      </xsl:when>
-      <xsl:otherwise>
-        <xsl:choose>
-          <xsl:when test="$month mod 2 = 1">30</xsl:when>
-          <xsl:otherwise>31</xsl:otherwise>
-        </xsl:choose>
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:template>
-
-  <doc:template name="dt:get-day-of-the-week-name" xmlns="">
-    <refpurpose>Gets the day of the week's full name.</refpurpose>
-
-    <refdescription>
-      <para>Converts a numeric day of the week value into a string representing the day's full name.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>day-of-the-week</term>
-          <listitem>
-            <para>Day of the week (0 - 6; Sunday = 0)</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns a string.</para>
-    </refreturn>
-
-  </doc:template>
-
-  <xsl:template name="dt:get-day-of-the-week-name">
-    <xsl:param name="day-of-the-week"/>
-
-    <xsl:choose>
-      <xsl:when test="$day-of-the-week = 0">Sunday</xsl:when>
-      <xsl:when test="$day-of-the-week = 1">Monday</xsl:when>
-      <xsl:when test="$day-of-the-week = 2">Tuesday</xsl:when>
-      <xsl:when test="$day-of-the-week = 3">Wednesday</xsl:when>
-      <xsl:when test="$day-of-the-week = 4">Thursday</xsl:when>
-      <xsl:when test="$day-of-the-week = 5">Friday</xsl:when>
-      <xsl:when test="$day-of-the-week = 6">Saturday</xsl:when>
-      <xsl:otherwise>error: <xsl:value-of select="$day-of-the-week"/></xsl:otherwise>
-    </xsl:choose>
-
-  </xsl:template>
-
-  <doc:template name="dt:get-day-of-the-week-abbreviation" xmlns="">
-    <refpurpose>Gets the day of the week's abbreviation.</refpurpose>
-
-    <refdescription>
-      <para>Converts a numeric day of the week value into a string representing the day's abbreviation.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>day-of-the-week</term>
-          <listitem>
-            <para>Day of the week (0 - 6; Sunday = 0)</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns a string.</para>
-    </refreturn>
-
-  </doc:template>
-
-  <xsl:template name="dt:get-day-of-the-week-abbreviation">
-    <xsl:param name="day-of-the-week"/>
-
-    <xsl:choose>
-      <xsl:when test="$day-of-the-week = 0">Sun</xsl:when>
-      <xsl:when test="$day-of-the-week = 1">Mon</xsl:when>
-      <xsl:when test="$day-of-the-week = 2">Tue</xsl:when>
-      <xsl:when test="$day-of-the-week = 3">Wed</xsl:when>
-      <xsl:when test="$day-of-the-week = 4">Thu</xsl:when>
-      <xsl:when test="$day-of-the-week = 5">Fri</xsl:when>
-      <xsl:when test="$day-of-the-week = 6">Sat</xsl:when>
-      <xsl:otherwise>error: <xsl:value-of select="$day-of-the-week"/></xsl:otherwise>
-    </xsl:choose>
-
-  </xsl:template>
-
-  <doc:template name="dt:get-month-name" xmlns="">
-    <refpurpose>Gets the month's full name.</refpurpose>
-
-    <refdescription>
-      <para>Converts a numeric month value into a string representing the month's full name.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>month</term>
-          <listitem>
-            <para>Month (1 - 12; Januaray = 1)</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns a string.</para>
-    </refreturn>
-
-  </doc:template>
-
-  <xsl:template name="dt:get-month-name">
-    <xsl:param name="month"/>
-
-    <xsl:choose>
-      <xsl:when test="$month = 1">January</xsl:when>
-      <xsl:when test="$month = 2">February</xsl:when>
-      <xsl:when test="$month = 3">March</xsl:when>
-      <xsl:when test="$month = 4">April</xsl:when>
-      <xsl:when test="$month = 5">May</xsl:when>
-      <xsl:when test="$month = 6">June</xsl:when>
-      <xsl:when test="$month = 7">July</xsl:when>
-      <xsl:when test="$month = 8">August</xsl:when>
-      <xsl:when test="$month = 9">September</xsl:when>
-      <xsl:when test="$month = 10">October</xsl:when>
-      <xsl:when test="$month = 11">November</xsl:when>
-      <xsl:when test="$month = 12">December</xsl:when>
-      <xsl:otherwise>error: <xsl:value-of select="$month"/></xsl:otherwise>
-    </xsl:choose>
-
-  </xsl:template>
-
-  <doc:template name="dt:get-month-abbreviation" xmlns="">
-    <refpurpose>Gets the month's abbreviation.</refpurpose>
-
-    <refdescription>
-      <para>Converts a numeric month value into a string representing the month's abbreviation.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>month</term>
-          <listitem>
-            <para>Month (1 - 12; Januaray = 1)</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns a string.</para>
-    </refreturn>
-
-  </doc:template>
-
-  <xsl:template name="dt:get-month-abbreviation">
-    <xsl:param name="month"/>
-
-    <xsl:choose>
-      <xsl:when test="$month = 1">Jan</xsl:when>
-      <xsl:when test="$month = 2">Feb</xsl:when>
-      <xsl:when test="$month = 3">Mar</xsl:when>
-      <xsl:when test="$month = 4">Apr</xsl:when>
-      <xsl:when test="$month = 5">May</xsl:when>
-      <xsl:when test="$month = 6">Jun</xsl:when>
-      <xsl:when test="$month = 7">Jul</xsl:when>
-      <xsl:when test="$month = 8">Aug</xsl:when>
-      <xsl:when test="$month = 9">Sep</xsl:when>
-      <xsl:when test="$month = 10">Oct</xsl:when>
-      <xsl:when test="$month = 11">Nov</xsl:when>
-      <xsl:when test="$month = 12">Dec</xsl:when>
-      <xsl:otherwise>error: <xsl:value-of select="$month"/></xsl:otherwise>
-    </xsl:choose>
-
-  </xsl:template>
-
-  <doc:template name="dt:calculate-julian-day" xmlns="">
-    <refpurpose>Calculates the Julian Day for a specified date.</refpurpose>
-
-    <refdescription>
-      <para>Given any Gregorian date, this calculates the Julian Day.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>year</term>
-          <listitem>
-            <para>Year</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>month</term>
-          <listitem>
-            <para>Month (1 - 12; January = 1)</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>day</term>
-          <listitem>
-            <para>Day of month (1 - 31)</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns the Julian Day as a decimal number.</para>
-    </refreturn>
-
-  </doc:template>
-
-  <xsl:template name="dt:calculate-julian-day">
-    <xsl:param name="year"/>
-    <xsl:param name="month"/>
-    <xsl:param name="day"/>
-
-    <xsl:variable name="a" select="floor((14 - $month) div 12)"/>
-    <xsl:variable name="y" select="$year + 4800 - $a"/>
-    <xsl:variable name="m" select="$month + 12 * $a - 3"/>
-
-    <xsl:value-of select="$day + floor((153 * $m + 2) div 5) + $y * 365 + floor($y div 4) - floor($y div 100) + floor($y div 400) - 32045"/>
-
-  </xsl:template>
-
-  <doc:template name="dt:format-julian-day" xmlns="">
-    <refpurpose>Returns a string with a formatted date for a specified Julian Day.</refpurpose>
-
-    <refdescription>
-      <para>Given any Julian Day, this returns a string according to the format specification.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>julian-day</term>
-          <listitem>
-            <para>A Julian Day</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>format</term>
-          <listitem>
-            <para>The format specification. See dt:format-date-time for more details.</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>A string.</para>
-    </refreturn>
-
-  </doc:template>
-
-  <xsl:template name="dt:format-julian-day">
-    <xsl:param name="julian-day"/>
-    <xsl:param name="format" select="'%Y-%m-%d'"/>
-
-    <xsl:variable name="a" select="$julian-day + 32044"/>
-    <xsl:variable name="b" select="floor((4 * $a + 3) div 146097)"/>
-    <xsl:variable name="c" select="$a - floor(($b * 146097) div 4)"/>
-
-    <xsl:variable name="d" select="floor((4 * $c + 3) div 1461)"/>
-    <xsl:variable name="e" select="$c - floor((1461 * $d) div 4)"/>
-    <xsl:variable name="m" select="floor((5 * $e + 2) div 153)"/>
-
-    <xsl:variable name="day" select="$e - floor((153 * $m + 2) div 5) + 1"/>
-    <xsl:variable name="month" select="$m + 3 - 12 * floor($m div 10)"/>
-    <xsl:variable name="year" select="$b * 100 + $d - 4800 + floor($m div 10)"/>
-
-    <xsl:call-template name="dt:format-date-time">
-      <xsl:with-param name="year" select="$year"/>
-      <xsl:with-param name="month" select="$month"/>
-      <xsl:with-param name="day" select="$day"/>
-      <xsl:with-param name="format" select="$format"/>
-    </xsl:call-template>
-
-  </xsl:template>
-
-  <doc:template name="dt:calculate-week-number" xmlns="">
-    <refpurpose>Calculates the week number for a specified date.</refpurpose>
-
-    <refdescription>
-      <para>Assumes Monday is the first day of the week.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>year</term>
-          <listitem>
-            <para>Year</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>month</term>
-          <listitem>
-            <para>Month (1 - 12; January = 1)</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>day</term>
-          <listitem>
-            <para>Day of month (1 - 31)</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns the week number as a decimal number.</para>
-    </refreturn>
-
-  </doc:template>
-
-  <xsl:template name="dt:calculate-week-number">
-    <xsl:param name="year"/>
-    <xsl:param name="month"/>
-    <xsl:param name="day"/>
-
-    <xsl:variable name="J">
-      <xsl:call-template name="dt:calculate-julian-day">
-        <xsl:with-param name="year" select="$year"/>
-        <xsl:with-param name="month" select="$month"/>
-        <xsl:with-param name="day" select="$day"/>
-      </xsl:call-template>
-    </xsl:variable>
-
-    <xsl:variable name="d4" select="($J + 31741 - ($J mod 7)) mod 146097 mod 36524 mod 1461"/>
-    <xsl:variable name="L" select="floor($d4 div 1460)"/>
-    <xsl:variable name="d1" select="(($d4 - $L) mod 365) + $L"/>
-
-    <xsl:value-of select="floor($d1 div 7) + 1"/>
-
-  </xsl:template>
-
-  <doc:template name="dt:get-month-number" xmlns="">
-    <refpurpose>Take a month by name and return a number which can be used as input to the templates. </refpurpose>
-
-    <refdescription>
-      <para>Input</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>month</term>
-          <listitem>
-            <para>Month as described either by full name or abbreviation.</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Return a month as a decimal number. (Jan = 1)</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name='dt:get-month-number'>
-    <xsl:param name='month'/>
-
-    <xsl:variable name='monToUpper'>
-      <xsl:call-template name='str:to-upper'>
-        <xsl:with-param name='text' select='$month'/>
-      </xsl:call-template>
-    </xsl:variable>
-
-    <xsl:choose>
-      <xsl:when test='starts-with($monToUpper,"JAN")'>
-        <xsl:value-of select='"1"'/>
-      </xsl:when>
-      <xsl:when test='starts-with($monToUpper,"FEB")'>
-        <xsl:value-of select='2'/>
-      </xsl:when>
-      <xsl:when test='starts-with($monToUpper,"MAR")'>
-        <xsl:value-of select='3'/>
-      </xsl:when>
-      <xsl:when test='starts-with($monToUpper,"APR")'>
-	<xsl:value-of select='4'/>
-      </xsl:when>      
-      <xsl:when test='starts-with($monToUpper,"MAY")'>
-	<xsl:value-of select='5'/>
-      </xsl:when>
-      <xsl:when test='starts-with($monToUpper,"JUN")'>
-	<xsl:value-of select='6'/>
-      </xsl:when>
-      <xsl:when test='starts-with($monToUpper,"JUL")'>
-	<xsl:value-of select='7'/>
-      </xsl:when>
-      <xsl:when test='starts-with($monToUpper,"AUG")'>
-	<xsl:value-of select='8'/>
-      </xsl:when>
-      <xsl:when test='starts-with($monToUpper,"SEP")'>
-	<xsl:value-of select='9'/>
-      </xsl:when>
-      <xsl:when test='starts-with($monToUpper,"OCT")'>
-	<xsl:value-of select='10'/>
-      </xsl:when>
-      <xsl:when test='starts-with($monToUpper,"NOV")'>
-	<xsl:value-of select='11'/>
-      </xsl:when>
-      <xsl:when test='starts-with($monToUpper,"DEC")'>
-	<xsl:value-of select='"12"'/>
-      </xsl:when>
-    </xsl:choose>
-  </xsl:template>
-
-  <doc:template name="dt:get-xsd-datetime-year" xmlns="">
-    <refpurpose>Return year component of XSD DateTime value.</refpurpose>
-
-    <refdescription>
-      <para>Extract component of XML Schemas DateTime value.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>xsd-date-time</term>
-          <listitem>
-            <para>A value in XSD DateTime format.</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns year component.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name='dt:get-xsd-datetime-year'>
-    <xsl:param name='xsd-date-time'/>
-
-    <xsl:choose>
-      <xsl:when test='contains($xsd-date-time, "T")'>
-        <xsl:call-template name='dt:get-xsd-datetime-year'>
-          <xsl:with-param name='xsd-date-time' select='substring-before($xsd-date-time, "T")'/>
-        </xsl:call-template>
-      </xsl:when>
-
-      <!-- Check for time -->
-      <xsl:when test='substring($xsd-date-time, 3, 1) = ":"'/>
-
-      <xsl:otherwise>
-        <!-- This is a date -->
-        <xsl:value-of select='substring-before($xsd-date-time, "-")'/>
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:template>
-
-  <doc:template name="dt:get-xsd-datetime-month" xmlns="">
-    <refpurpose>Return month component of XSD DateTime value.</refpurpose>
-
-    <refdescription>
-      <para>Extract component of XML Schemas DateTime value.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>xsd-date-time</term>
-          <listitem>
-            <para>A value in XSD DateTime format.</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns month component.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name='dt:get-xsd-datetime-month'>
-    <xsl:param name='xsd-date-time'/>
-
-    <xsl:choose>
-      <xsl:when test='contains($xsd-date-time, "T")'>
-        <xsl:call-template name='dt:get-xsd-datetime-month'>
-          <xsl:with-param name='xsd-date-time' select='substring-before($xsd-date-time, "T")'/>
-        </xsl:call-template>
-      </xsl:when>
-
-      <!-- Check for time -->
-      <xsl:when test='substring($xsd-date-time, 3, 1) = ":"'/>
-
-      <xsl:otherwise>
-        <!-- This is a date -->
-        <xsl:value-of select='substring(substring-after($xsd-date-time, "-"), 1, 2)'/>
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:template>
-
-  <doc:template name="dt:get-xsd-datetime-day" xmlns="">
-    <refpurpose>Return day component of XSD DateTime value.</refpurpose>
-
-    <refdescription>
-      <para>Extract component of XML Schemas DateTime value.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>xsd-date-time</term>
-          <listitem>
-            <para>A value in XSD DateTime format.</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns day component.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name='dt:get-xsd-datetime-day'>
-    <xsl:param name='xsd-date-time'/>
-
-    <xsl:choose>
-      <xsl:when test='contains($xsd-date-time, "T")'>
-        <xsl:call-template name='dt:get-xsd-datetime-day'>
-          <xsl:with-param name='xsd-date-time' select='substring-before($xsd-date-time, "T")'/>
-        </xsl:call-template>
-      </xsl:when>
-
-      <!-- Check for time -->
-      <xsl:when test='substring($xsd-date-time, 3, 1) = ":"'/>
-
-      <xsl:otherwise>
-        <!-- This is a date -->
-        <xsl:value-of select='substring(substring-after($xsd-date-time, "-"), 4, 2)'/>
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:template>
-
-  <doc:template name="dt:get-xsd-datetime-hour" xmlns="">
-    <refpurpose>Return hour component of XSD DateTime value.</refpurpose>
-
-    <refdescription>
-      <para>Extract component of XML Schemas DateTime value.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>xsd-date-time</term>
-          <listitem>
-            <para>A value in XSD DateTime format.</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns hour component.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name='dt:get-xsd-datetime-hour'>
-    <xsl:param name='xsd-date-time'/>
-
-    <xsl:choose>
-      <xsl:when test='contains($xsd-date-time, "T")'>
-        <xsl:call-template name='dt:get-xsd-datetime-hour'>
-          <xsl:with-param name='xsd-date-time' select='substring-after($xsd-date-time, "T")'/>
-        </xsl:call-template>
-      </xsl:when>
-
-      <!-- Check for time -->
-      <xsl:when test='substring($xsd-date-time, 3, 1) = ":"'>
-        <xsl:value-of select='substring($xsd-date-time, 1, 2)'/>
-      </xsl:when>
-
-      <xsl:otherwise>
-        <!-- This is a date -->
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:template>
-
-  <doc:template name="dt:get-xsd-datetime-minute" xmlns="">
-    <refpurpose>Return minute component of XSD DateTime value.</refpurpose>
-
-    <refdescription>
-      <para>Extract component of XML Schemas DateTime value.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>xsd-date-time</term>
-          <listitem>
-            <para>A value in XSD DateTime format.</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns minute component.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name='dt:get-xsd-datetime-minute'>
-    <xsl:param name='xsd-date-time'/>
-
-    <xsl:choose>
-      <xsl:when test='contains($xsd-date-time, "T")'>
-        <xsl:call-template name='dt:get-xsd-datetime-minute'>
-          <xsl:with-param name='xsd-date-time' select='substring-after($xsd-date-time, "T")'/>
-        </xsl:call-template>
-      </xsl:when>
-
-      <!-- Check for time -->
-      <xsl:when test='substring($xsd-date-time, 3, 1) = ":"'>
-        <xsl:value-of select='substring($xsd-date-time, 4, 2)'/>
-      </xsl:when>
-
-      <xsl:otherwise>
-        <!-- This is a date -->
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:template>
-
-  <doc:template name="dt:get-xsd-datetime-second" xmlns="">
-    <refpurpose>Return second component of XSD DateTime value.</refpurpose>
-
-    <refdescription>
-      <para>Extract component of XML Schemas DateTime value.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>xsd-date-time</term>
-          <listitem>
-            <para>A value in XSD DateTime format.</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns second component.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name='dt:get-xsd-datetime-second'>
-    <xsl:param name='xsd-date-time'/>
-
-    <xsl:choose>
-      <xsl:when test='contains($xsd-date-time, "T")'>
-        <xsl:call-template name='dt:get-xsd-datetime-second'>
-          <xsl:with-param name='xsd-date-time' select='substring-after($xsd-date-time, "T")'/>
-        </xsl:call-template>
-      </xsl:when>
-
-      <!-- Check for time -->
-      <xsl:when test='substring($xsd-date-time, 3, 1) = ":"'>
-        <xsl:variable name='part' select='substring($xsd-date-time, 7)'/>
-        <xsl:choose>
-          <xsl:when test='contains($part, "Z")'>
-            <xsl:value-of select='substring-before($part, "Z")'/>
-          </xsl:when>
-          <xsl:when test='contains($part, "+")'>
-            <xsl:value-of select='substring-before($part, "+")'/>
-          </xsl:when>
-          <xsl:when test='contains($part, "-")'>
-            <xsl:value-of select='substring-before($part, "-")'/>
-          </xsl:when>
-          <xsl:otherwise>
-            <xsl:value-of select='$part'/>
-          </xsl:otherwise>
-        </xsl:choose>
-      </xsl:when>
-
-      <xsl:otherwise>
-        <!-- This is a date -->
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:template>
-
-  <doc:template name="dt:get-xsd-datetime-timezone" xmlns="">
-    <refpurpose>Return timezone component of XSD DateTime value.</refpurpose>
-
-    <refdescription>
-      <para>Extract component of XML Schemas DateTime value.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>xsd-date-time</term>
-          <listitem>
-            <para>A value in XSD DateTime format.</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns timezone component.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name='dt:get-xsd-datetime-timezone'>
-    <xsl:param name='xsd-date-time'/>
-
-    <xsl:choose>
-      <xsl:when test='contains($xsd-date-time, "Z")'>Z</xsl:when>
-      <xsl:when test='contains($xsd-date-time, "T")'>
-        <xsl:call-template name='dt:get-xsd-datetime-timezone'>
-          <xsl:with-param name='xsd-date-time' select='substring-after($xsd-date-time, "T")'/>
-        </xsl:call-template>
-      </xsl:when>
-
-      <xsl:when test='substring($xsd-date-time, 3, 1) = ":"'>
-        <!-- This is a time -->
-        <xsl:choose>
-          <xsl:when test='contains($xsd-date-time, "+")'>
-            <xsl:text>+</xsl:text>
-            <xsl:value-of select='substring-after($xsd-date-time, "+")'/>
-          </xsl:when>
-          <xsl:when test='contains($xsd-date-time, "-")'>
-            <xsl:text>-</xsl:text>
-            <xsl:value-of select='substring-after($xsd-date-time, "-")'/>
-          </xsl:when>
-        </xsl:choose>
-      </xsl:when>
-      <xsl:otherwise>
-        <!-- This is a date -->
-        <xsl:value-of select='substring(substring-after($xsd-date-time, "-"), 6)'/>
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:template>
-
-  <doc:template name="dt:format-two-digit-year" xmlns="">
-    <refpurpose>Return two digit year as four digit year value.</refpurpose>
-
-    <refdescription>
-      <para>Prepend century to two digit year value.</para>
-      <para>Century value is calculated according to suggested solutions in RFC2626 (section 5).</para>
-      <para>Fixed window solution: 20 is prepended to year if the year is less than 50, otherwise 19 is prepended to year.</para>
-      <para>Sliding window solution: The year is considered in the future if the year is less than the current 2 digit year plus 'n' years (where 'n' is a param), otherwise it is considered in the past.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>year</term>
-          <listitem>
-            <para>A year value in 2 digit format.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>method</term>
-          <listitem>
-            <para>RFC2626 suggested solution ('fixed' or 'sliding').  Default is 'fixed'.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>n</term>
-          <listitem>
-            <para>No. of years. Used in sliding windows solution.</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns four digit year value.</para>
-    </refreturn>
-  </doc:template>
-  
-  <xsl:template name="dt:format-two-digit-year">
-    <xsl:param name="year" />
-    <xsl:param name="method" select="'fixed'"/>
-
-    <xsl:choose>
-      <xsl:when test="string-length($year) != 2">invalid year value</xsl:when>
-      <xsl:when test="$method = 'fixed'">
-        <xsl:choose>
-          <xsl:when test="$year < 50">20</xsl:when>
-          <xsl:otherwise>19</xsl:otherwise>
-        </xsl:choose>
-        <xsl:value-of select="$year" />
-      </xsl:when>
-      <xsl:when test="$method = 'window'">not yet implemented</xsl:when>
-      <xsl:otherwise>invalid method</xsl:otherwise>
-    </xsl:choose>
-  </xsl:template>
-
-  <doc:template name="dt:years-from-duration" xmlns="">
-    <refpurpose>Return number of years.</refpurpose>
-
-    <refdescription>
-      <para>Extract year value from a Duration value.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>duration</term>
-          <listitem>
-            <para>A XSD Duration format value.</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns year value. If the duration is not formatted correctly, returns empty string.</para>
-    </refreturn>
-  </doc:template>
-  
-  <xsl:template name="dt:years-from-duration">
-    <xsl:param name="duration" />
-
-    <xsl:call-template name='dt:component-from-duration'>
-      <xsl:with-param name='duration' select='$duration'/>
-      <xsl:with-param name='component' select='"year"'/>
-    </xsl:call-template>
-  </xsl:template>
-
-  <doc:template name="dt:months-from-duration" xmlns="">
-    <refpurpose>Return number of months.</refpurpose>
-
-    <refdescription>
-      <para>Extract month value from a Duration value.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>duration</term>
-          <listitem>
-            <para>A XSD Duration format value.</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns month value. If the duration is not formatted correctly, returns empty string.</para>
-    </refreturn>
-  </doc:template>
-  
-  <xsl:template name="dt:months-from-duration">
-    <xsl:param name="duration" />
-
-    <xsl:call-template name='dt:component-from-duration'>
-      <xsl:with-param name='duration' select='$duration'/>
-      <xsl:with-param name='component' select='"month"'/>
-    </xsl:call-template>
-  </xsl:template>
-
-  <doc:template name="dt:days-from-duration" xmlns="">
-    <refpurpose>Return number of days.</refpurpose>
-
-    <refdescription>
-      <para>Extract day value from a Duration value.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>duration</term>
-          <listitem>
-            <para>A XSD Duration format value.</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns day value. If the duration is not formatted correctly, returns empty string.</para>
-    </refreturn>
-  </doc:template>
-  
-  <xsl:template name="dt:days-from-duration">
-    <xsl:param name="duration" />
-
-    <xsl:call-template name='dt:component-from-duration'>
-      <xsl:with-param name='duration' select='$duration'/>
-      <xsl:with-param name='component' select='"day"'/>
-    </xsl:call-template>
-  </xsl:template>
-
-  <doc:template name="dt:hours-from-duration" xmlns="">
-    <refpurpose>Return number of hours.</refpurpose>
-
-    <refdescription>
-      <para>Extract hour value from a Duration value.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>duration</term>
-          <listitem>
-            <para>A XSD Duration format value.</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns hour value. If the duration is not formatted correctly, returns empty string.</para>
-    </refreturn>
-  </doc:template>
-  
-  <xsl:template name="dt:hours-from-duration">
-    <xsl:param name="duration" />
-
-    <xsl:call-template name='dt:component-from-duration'>
-      <xsl:with-param name='duration' select='$duration'/>
-      <xsl:with-param name='component' select='"hour"'/>
-    </xsl:call-template>
-  </xsl:template>
-
-  <doc:template name="dt:minutes-from-duration" xmlns="">
-    <refpurpose>Return number of minutes.</refpurpose>
-
-    <refdescription>
-      <para>Extract minute value from a Duration value.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>duration</term>
-          <listitem>
-            <para>A XSD Duration format value.</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns minute value. If the duration is not formatted correctly, returns empty string.</para>
-    </refreturn>
-  </doc:template>
-  
-  <xsl:template name="dt:minutes-from-duration">
-    <xsl:param name="duration" />
-
-    <xsl:call-template name='dt:component-from-duration'>
-      <xsl:with-param name='duration' select='$duration'/>
-      <xsl:with-param name='component' select='"minute"'/>
-    </xsl:call-template>
-  </xsl:template>
-
-  <doc:template name="dt:seconds-from-duration" xmlns="">
-    <refpurpose>Return number of seconds.</refpurpose>
-
-    <refdescription>
-      <para>Extract second value from a Duration value.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>duration</term>
-          <listitem>
-            <para>A XSD Duration format value.</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns second value. If the duration is not formatted correctly, returns empty string.</para>
-    </refreturn>
-  </doc:template>
-  
-  <xsl:template name="dt:seconds-from-duration">
-    <xsl:param name="duration" />
-
-    <xsl:call-template name='dt:component-from-duration'>
-      <xsl:with-param name='duration' select='$duration'/>
-      <xsl:with-param name='component' select='"second"'/>
-    </xsl:call-template>
-  </xsl:template>
-
-  <!-- Internal function: this does the real work -->
-  <xsl:template name="dt:component-from-duration">
-    <xsl:param name="duration"/>
-    <xsl:param name='component' select='"year"'/>
-    <xsl:param name='stage' select='"sign"'/>
-
-    <xsl:choose>
-      <xsl:when test='$stage = "sign" and
-                      substring($duration, 1, 1) = "-"'>
-        <xsl:text>-</xsl:text>
-        <xsl:call-template name='dt:component-from-duration'>
-          <xsl:with-param name='duration' select='substring($duration, 2)'/>
-          <xsl:with-param name='stage' select='"p"'/>
-          <xsl:with-param name='component' select='$component'/>
-        </xsl:call-template>
-      </xsl:when>
-      <xsl:when test='$stage = "sign"'>
-        <xsl:call-template name='dt:component-from-duration'>
-          <xsl:with-param name='duration' select='$duration'/>
-          <xsl:with-param name='stage' select='"p"'/>
-          <xsl:with-param name='component' select='$component'/>
-        </xsl:call-template>
-      </xsl:when>
-
-      <xsl:when test="$stage = 'p' and
-                      substring($duration, 1, 1) != 'P'"/>
-      <xsl:when test='$stage = "p"'>
-        <xsl:call-template name='dt:component-from-duration'>
-          <xsl:with-param name='duration' select='substring($duration, 2)'/>
-          <xsl:with-param name='stage' select='"year"'/>
-          <xsl:with-param name='component' select='$component'/>
-        </xsl:call-template>
-      </xsl:when>
-
-      <xsl:when test="$stage = 't' and
-                      $duration = ''">0</xsl:when>
-      <xsl:when test="$stage = 't' and
-                      substring($duration, 1, 1) != 'T'"/>
-      <xsl:when test='$stage = "t"'>
-        <xsl:call-template name='dt:component-from-duration'>
-          <xsl:with-param name='duration' select='substring($duration, 2)'/>
-          <xsl:with-param name='stage' select='"hour"'/>
-          <xsl:with-param name='component' select='$component'/>
-        </xsl:call-template>
-      </xsl:when>
-
-      <xsl:when test='$stage = "year"'>
-        <xsl:variable name='value'>
-          <xsl:call-template name='dt:get-number-value'>
-            <xsl:with-param name='text' select='$duration'/>
-          </xsl:call-template>
-        </xsl:variable>
-        <xsl:variable name='code' select='substring($duration, string-length($value) + 1, 1)'/>
-
-        <xsl:choose>
-          <xsl:when test='$duration = ""'>0</xsl:when>
-          <xsl:when test='$component = "year" and
-                          $code = "Y" and
-                          $value != ""'>
-            <xsl:value-of select='$value'/>
-          </xsl:when>
-          <xsl:when test='$code = "Y" and
-                          $value = ""'/>
-          <xsl:when test='$value = "" and
-                          not($code = "M" or $code = "D" or $code = "T")'/>
-          <xsl:when test='$component = "year"'>0</xsl:when>
-          <xsl:when test='$code = "Y"'>
-            <xsl:call-template name='dt:component-from-duration'>
-              <xsl:with-param name='duration' select='substring($duration, string-length($value) + 2)'/>
-              <xsl:with-param name='stage' select='"month"'/>
-              <xsl:with-param name='component' select='$component'/>
-            </xsl:call-template>
-          </xsl:when>
-          <xsl:otherwise>
-            <xsl:call-template name='dt:component-from-duration'>
-              <xsl:with-param name='duration' select='$duration'/>
-              <xsl:with-param name='stage' select='"month"'/>
-              <xsl:with-param name='component' select='$component'/>
-            </xsl:call-template>
-          </xsl:otherwise>
-        </xsl:choose>
-      </xsl:when>
-
-      <xsl:when test='$stage = "month"'>
-        <xsl:variable name='value'>
-          <xsl:call-template name='dt:get-number-value'>
-            <xsl:with-param name='text' select='$duration'/>
-          </xsl:call-template>
-        </xsl:variable>
-        <xsl:variable name='code' select='substring($duration, string-length($value) + 1, 1)'/>
-
-        <xsl:choose>
-          <xsl:when test='$duration = ""'>0</xsl:when>
-          <xsl:when test='$component = "month" and
-                          $code = "M" and
-                          $value != ""'>
-            <xsl:value-of select='$value'/>
-          </xsl:when>
-          <xsl:when test='$code = "M" and
-                          $value = ""'/>
-          <xsl:when test='$component = "month" and
-                          $value != "" and
-                          not($code = "D" or $code = "T")'/>
-          <xsl:when test='$component = "month"'>0</xsl:when>
-          <xsl:when test='$code = "M"'>
-            <xsl:call-template name='dt:component-from-duration'>
-              <xsl:with-param name='duration' select='substring($duration, string-length($value) + 2)'/>
-              <xsl:with-param name='stage' select='"day"'/>
-              <xsl:with-param name='component' select='$component'/>
-            </xsl:call-template>
-          </xsl:when>
-          <xsl:otherwise>
-            <xsl:call-template name='dt:component-from-duration'>
-              <xsl:with-param name='duration' select='$duration'/>
-              <xsl:with-param name='stage' select='"day"'/>
-              <xsl:with-param name='component' select='$component'/>
-            </xsl:call-template>
-          </xsl:otherwise>
-        </xsl:choose>
-      </xsl:when>
-
-      <xsl:when test='$stage = "day"'>
-        <xsl:variable name='value'>
-          <xsl:call-template name='dt:get-number-value'>
-            <xsl:with-param name='text' select='$duration'/>
-          </xsl:call-template>
-        </xsl:variable>
-        <xsl:variable name='code' select='substring($duration, string-length($value) + 1, 1)'/>
-
-        <xsl:choose>
-          <xsl:when test='$duration = ""'>0</xsl:when>
-          <xsl:when test='$component = "day" and
-                          $code = "D" and
-                          $value != ""'>
-            <xsl:value-of select='$value'/>
-          </xsl:when>
-          <xsl:when test='$code = "D" and
-                          $value = ""'/>
-          <xsl:when test='$component = "day" and
-                          $value != "" and
-                          $code != "D"'/>
-          <xsl:when test='$value = "" and
-                          $code != "T"'/>
-          <xsl:when test='$component = "day"'>0</xsl:when>
-          <xsl:when test='$code = "D"'>
-            <xsl:call-template name='dt:component-from-duration'>
-              <xsl:with-param name='duration' select='substring($duration, string-length($value) + 2)'/>
-              <xsl:with-param name='stage' select='"t"'/>
-              <xsl:with-param name='component' select='$component'/>
-            </xsl:call-template>
-          </xsl:when>
-          <xsl:otherwise>
-            <xsl:call-template name='dt:component-from-duration'>
-              <xsl:with-param name='duration' select='$duration'/>
-              <xsl:with-param name='stage' select='"t"'/>
-              <xsl:with-param name='component' select='$component'/>
-            </xsl:call-template>
-          </xsl:otherwise>
-        </xsl:choose>
-      </xsl:when>
-
-      <xsl:when test='$stage = "hour"'>
-        <xsl:variable name='value'>
-          <xsl:call-template name='dt:get-number-value'>
-            <xsl:with-param name='text' select='$duration'/>
-          </xsl:call-template>
-        </xsl:variable>
-        <xsl:variable name='code' select='substring($duration, string-length($value) + 1, 1)'/>
-
-        <xsl:choose>
-          <xsl:when test='$duration = ""'>0</xsl:when>
-          <xsl:when test='$component = "hour" and
-                          $code = "H" and
-                          $value != ""'>
-            <xsl:value-of select='$value'/>
-          </xsl:when>
-          <xsl:when test='$code = "H" and
-                          $value = ""'/>
-          <xsl:when test='$component = "hour" and
-                          $value != "" and
-                          not($code = "." or $code = "M" or $code = "S")'/>
-          <xsl:when test='$value = "" and
-                          not($code = "M" or $code = "S")'/>
-          <xsl:when test='$component = "hour"'>0</xsl:when>
-          <xsl:when test='$code = "H"'>
-            <xsl:call-template name='dt:component-from-duration'>
-              <xsl:with-param name='duration' select='substring($duration, string-length($value) + 2)'/>
-              <xsl:with-param name='stage' select='"minute"'/>
-              <xsl:with-param name='component' select='$component'/>
-            </xsl:call-template>
-          </xsl:when>
-          <xsl:otherwise>
-            <xsl:call-template name='dt:component-from-duration'>
-              <xsl:with-param name='duration' select='$duration'/>
-              <xsl:with-param name='stage' select='"minute"'/>
-              <xsl:with-param name='component' select='$component'/>
-            </xsl:call-template>
-          </xsl:otherwise>
-        </xsl:choose>
-      </xsl:when>
-
-      <xsl:when test='$stage = "minute"'>
-        <xsl:variable name='value'>
-          <xsl:call-template name='dt:get-number-value'>
-            <xsl:with-param name='text' select='$duration'/>
-          </xsl:call-template>
-        </xsl:variable>
-        <xsl:variable name='code' select='substring($duration, string-length($value) + 1, 1)'/>
-
-        <xsl:choose>
-          <xsl:when test='$duration = ""'>0</xsl:when>
-          <xsl:when test='$component = "minute" and
-                          $code = "M" and
-                          $value != ""'>
-            <xsl:value-of select='$value'/>
-          </xsl:when>
-          <xsl:when test='$component = "minute" and
-                          $code = "M" and
-                          $value != ""'>
-            <xsl:value-of select='$value'/>
-          </xsl:when>
-          <xsl:when test='$code = "M" and
-                          $value = ""'/>
-          <xsl:when test='$component = "minute" and
-                          $value != "" and
-                          not($code = "." or $code = "S")'/>
-          <xsl:when test='$component = "minute"'>0</xsl:when>
-          <xsl:when test='$code = "M"'>
-            <xsl:call-template name='dt:component-from-duration'>
-              <xsl:with-param name='duration' select='substring($duration, string-length($value) + 2)'/>
-              <xsl:with-param name='stage' select='"second"'/>
-              <xsl:with-param name='component' select='$component'/>
-            </xsl:call-template>
-          </xsl:when>
-          <xsl:otherwise>
-            <xsl:call-template name='dt:component-from-duration'>
-              <xsl:with-param name='duration' select='$duration'/>
-              <xsl:with-param name='stage' select='"second"'/>
-              <xsl:with-param name='component' select='$component'/>
-            </xsl:call-template>
-          </xsl:otherwise>
-        </xsl:choose>
-      </xsl:when>
-
-      <xsl:when test='$stage = "second"'>
-        <xsl:variable name='value'>
-          <xsl:call-template name='dt:get-decimal-value'>
-            <xsl:with-param name='text' select='$duration'/>
-          </xsl:call-template>
-        </xsl:variable>
-        <xsl:variable name='code' select='substring($duration, string-length($value) + 1, 1)'/>
-
-        <xsl:choose>
-          <xsl:when test='$duration = ""'>0</xsl:when>
-          <xsl:when test='$component = "second" and
-                          $code = "S" and
-                          $value != "" and
-                          substring($duration, string-length($value) + 2) != ""'/>
-          <xsl:when test='$component = "second" and
-                          $code = "S" and
-                          $value != ""'>
-            <xsl:value-of select='$value'/>
-          </xsl:when>
-          <!-- otherwise: invalid format -->
-        </xsl:choose>
-      </xsl:when>
-    </xsl:choose>
-  </xsl:template>
-
-  <!-- Internal utility functions to scan text for an integer or decimal value -->
-  <xsl:template name='dt:get-number-value'>
-    <xsl:param name='text'/>
-
-    <!-- TODO: improve handling of minus sign -->
-
-    <xsl:choose>
-      <xsl:when test='not($text)'/>
-      <xsl:when test='translate(substring($text, 1, 1), "-0123456789", "") = ""'>
-        <xsl:value-of select='substring($text, 1, 1)'/>
-        <xsl:call-template name='dt:get-number-value'>
-          <xsl:with-param name='text' select='substring($text, 2)'/>
-        </xsl:call-template>
-      </xsl:when>
-    </xsl:choose>
-  </xsl:template>
-  <xsl:template name='dt:get-decimal-value'>
-    <xsl:param name='text'/>
-
-    <xsl:choose>
-      <xsl:when test='not($text)'/>
-      <xsl:when test='substring($text, 1, 1) = "."'>
-        <xsl:text>.</xsl:text>
-        <xsl:call-template name='dt:get-number-value'>
-          <xsl:with-param name='text' select='substring($text, 2)'/>
-        </xsl:call-template>
-      </xsl:when>
-      <xsl:when test='translate(substring($text, 1, 1), "-0123456789", "") = ""'>
-        <xsl:value-of select='substring($text, 1, 1)'/>
-        <xsl:call-template name='dt:get-decimal-value'>
-          <xsl:with-param name='text' select='substring($text, 2)'/>
-        </xsl:call-template>
-      </xsl:when>
-    </xsl:choose>
-  </xsl:template>
-
-  <doc:template name="dt:seconds" xmlns="">
-    <refpurpose>Return number of seconds in a duration.</refpurpose>
-
-    <refdescription>
-      <para>Converts a Duration value to seconds. This function will be unreliable for values greater than one month: months are assumed to have thirty days, and does not take into account leap days or seconds.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>duration</term>
-          <listitem>
-            <para>A XSD Duration format value.</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns an integer value. If the duration is not formatted correctly, returns empty string.</para>
-    </refreturn>
-  </doc:template>
-  
-  <xsl:template name="dt:seconds">
-    <xsl:param name="duration" />
-
-    <xsl:variable name='years'>
-      <xsl:call-template name='dt:years-from-duration'>
-        <xsl:with-param name='duration' select='$duration'/>
-      </xsl:call-template>
-    </xsl:variable>
-    <xsl:variable name='months'>
-      <xsl:call-template name='dt:months-from-duration'>
-        <xsl:with-param name='duration' select='$duration'/>
-      </xsl:call-template>
-    </xsl:variable>
-    <xsl:variable name='days'>
-      <xsl:call-template name='dt:days-from-duration'>
-        <xsl:with-param name='duration' select='$duration'/>
-      </xsl:call-template>
-    </xsl:variable>
-    <xsl:variable name='hours'>
-      <xsl:call-template name='dt:hours-from-duration'>
-        <xsl:with-param name='duration' select='$duration'/>
-      </xsl:call-template>
-    </xsl:variable>
-    <xsl:variable name='minutes'>
-      <xsl:call-template name='dt:minutes-from-duration'>
-        <xsl:with-param name='duration' select='$duration'/>
-      </xsl:call-template>
-    </xsl:variable>
-    <xsl:variable name='seconds'>
-      <xsl:call-template name='dt:seconds-from-duration'>
-        <xsl:with-param name='duration' select='$duration'/>
-      </xsl:call-template>
-    </xsl:variable>
-
-    <xsl:if test='not($years = "" or
-                      $months = "" or
-                      $days = "" or
-                      $hours = "" or
-                      $minutes = "" or
-                      $seconds = "")'>
-      <xsl:value-of select='$years * 365 * 24 * 60 * 60 +
-                            $months * 30 * 24 * 60 * 60 +
-                            $days * 24 * 60 * 60 +
-                            $hours * 60 * 60 +
-                            $minutes * 60 +
-                            $seconds'/>
-    </xsl:if>
-  </xsl:template>
-
- </xsl:stylesheet>
diff --git a/tclxml-3.2/doc/xsltsl/example.xsl b/tclxml-3.2/doc/xsltsl/example.xsl
deleted file mode 100644
index c4f8b25..0000000
--- a/tclxml-3.2/doc/xsltsl/example.xsl
+++ /dev/null
@@ -1,90 +0,0 @@
-<?xml version="1.0"?>
-
-<xsl:stylesheet
-  version="1.0"
-  extension-element-prefixes="doc"
-  xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
-  xmlns:doc="http://xsltsl.org/xsl/documentation/1.0"
-  xmlns:eg="http://xsltsl.org/example"
->
-
-  <doc:reference xmlns="">
-    <referenceinfo>
-      <releaseinfo role="meta">
-        $Id: example.xsl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-      </releaseinfo>
-      <author>
-        <surname>Ball</surname>
-        <firstname>Steve</firstname>
-      </author>
-      <copyright>
-        <year>2001</year>
-        <holder>Steve Ball</holder>
-      </copyright>
-    </referenceinfo>
-
-    <title>Example Stylesheet</title>
-
-    <partintro>
-      <section>
-        <title>Introduction</title>
-
-        <para>This module provides a template for adding stylesheet modules to the XSLT Standard Library.</para>
-        <para>To add a new module to the library, follow these easy steps:</para>
-        <orderedlist>
-          <listitem>
-            <para>Copy this file and replace its contents with the new module templates and documentation.</para>
-          </listitem>
-          <listitem>
-            <para>Copy the corresponding test file in the <filename>test</filename> directory.  Replace its contents with tests for the new module.</para>
-          </listitem>
-          <listitem>
-            <para>Add an include element in the <filename>stdlib.xsl</filename> stylesheet.</para>
-          </listitem>
-          <listitem>
-            <para>Add an entry in the <filename>test/test.xml</filename> file.</para>
-          </listitem>
-          <listitem>
-            <para>Add entries in the <filename>test/test.xsl</filename> stylesheet.</para>
-          </listitem>
-          <listitem>
-            <para>Add an entry in the <filename>doc/build.xml</filename> file.</para>
-          </listitem>
-        </orderedlist>
-
-        <para>The <filename>example.xsl</filename> stylesheet provides a more extensive example.</para>
-
-      </section>
-    </partintro>
-
-  </doc:reference>
-
-  <doc:template name="eg:example" xmlns="">
-    <refpurpose>Template Example</refpurpose>
-
-    <refdescription>
-      <para>Provides a template for writing templates.  Replace this paragraph with a description of your template</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>text</term>
-          <listitem>
-            <para>The example string</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns nothing.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name="eg:example">
-    <xsl:param name="text"/>
-  </xsl:template>
-
-</xsl:stylesheet>
-
diff --git a/tclxml-3.2/doc/xsltsl/markup.xsl b/tclxml-3.2/doc/xsltsl/markup.xsl
deleted file mode 100644
index 7f3ab75..0000000
--- a/tclxml-3.2/doc/xsltsl/markup.xsl
+++ /dev/null
@@ -1,789 +0,0 @@
-<xsl:stylesheet version='1.0'
-  xmlns:xsl='http://www.w3.org/1999/XSL/Transform'
-  xmlns:doc='http://xsltsl.org/xsl/documentation/1.0'
-  xmlns:markup='http://xsltsl.org/markup'
-  xmlns:str='http://xsltsl.org/string'
-  extension-element-prefixes='doc markup str'>
-
-  <doc:reference xmlns=''>
-    <referenceinfo>
-      <releaseinfo role="meta">
-	$Id: markup.xsl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-      </releaseinfo>
-      <author>
-	<surname>Ball</surname>
-	<firstname>Steve</firstname>
-      </author>
-      <copyright>
-	<year>2003</year>
-	<year>2001</year>
-	<holder>Steve Ball</holder>
-      </copyright>
-    </referenceinfo>
-
-    <title>XML Markup Templates</title>
-
-    <partintro>
-      <section>
-	<title>Introduction</title>
-
-	<para>This stylesheet module provides functions for generating literal XML markup.</para>
-
-      </section>
-    </partintro>
-
-  </doc:reference>
-
-  <doc:template name="markup:xml-declaration" xmlns="">
-    <refpurpose>Create an XML Declaration</refpurpose>
-
-    <refdescription>
-      <para>This template returns an XML Declaration.  Although the XSLT standard provides control over the generation of the XML Declaration, this template may be useful in circumstances where the values must be computed at runtime.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-	<varlistentry>
-	  <term>version</term>
-	  <listitem>
-	    <para>Version number.</para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>standalone</term>
-	  <listitem>
-	    <para>Standalone indication.  Must be value "yes" or "no".</para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>encoding</term>
-	  <listitem>
-	    <para>Character encoding.</para>
-	  </listitem>
-	</varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns an XML Declaration as a string.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name='markup:xml-declaration'>
-    <xsl:param name='version' select="'1.0'"/>
-    <xsl:param name='standalone'/>
-    <xsl:param name='encoding'/>
-
-    <xsl:text disable-output-escaping='yes'><?xml version="</xsl:text>
-    <xsl:copy-of select="$version"/>
-    <xsl:text>"</xsl:text>
-
-    <xsl:choose>
-      <xsl:when test="string-length($standalone) = 0"/>
-      <xsl:when test='$standalone = "yes" or $standalone = "no"'>
-        <xsl:text> standalone="</xsl:text>
-        <xsl:copy-of select="$standalone"/>
-        <xsl:text>"</xsl:text>
-      </xsl:when>
-      <xsl:otherwise>
-        <xsl:message terminate="yes">invalid value "<xsl:value-of select="$standalone"/>" for standalone attribute</xsl:message>
-      </xsl:otherwise>
-    </xsl:choose>
-
-    <xsl:if test='string-length($encoding) > 0'>
-      <xsl:text> encoding="</xsl:text>
-      <xsl:copy-of select='$encoding'/>
-      <xsl:text>"</xsl:text>
-    </xsl:if>
-
-    <xsl:text disable-output-escaping='yes'>?>
-</xsl:text>
-  </xsl:template>
-
-  <doc:template name="markup:doctype-declaration" xmlns="">
-    <refpurpose>Create a Document Type Declaration</refpurpose>
-
-    <refdescription>
-      <para>This template returns a Document Type Declaration.  Although the XSLT standard provides control over the generation of a Document Type Declaration, this template may be useful in circumstances where the values for the identifiers or the internal subset must be computed at runtime.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-	<varlistentry>
-	  <term>docel</term>
-	  <listitem>
-	    <para>The name of the document element.</para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>publicid</term>
-	  <listitem>
-	    <para>The public identifier for the external DTD subset.</para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>systemid</term>
-	  <listitem>
-	    <para>The system identifier for the external DTD subset.</para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>internaldtd</term>
-	  <listitem>
-	    <para>The internal DTD subset.</para>
-	  </listitem>
-	</varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns a Document Type Declaration as a string.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name='markup:doctype-declaration'>
-    <xsl:param name='docel'/>
-    <xsl:param name='publicid'/>
-    <xsl:param name='systemid'/>
-    <xsl:param name='internaldtd'/>
-
-    <xsl:if test='string-length($docel) = 0'>
-      <xsl:message terminate='yes'>No document element specified</xsl:message>
-    </xsl:if>
-
-    <xsl:text disable-output-escaping='yes'><!DOCTYPE </xsl:text>
-    <xsl:copy-of select="$docel"/>
-
-    <xsl:call-template name='markup:external-identifier'>
-      <xsl:with-param name='publicid' select='$publicid'/>
-      <xsl:with-param name='systemid' select='$systemid'/>
-      <xsl:with-param name='leading-space' select='true()'/>
-    </xsl:call-template>
-
-    <xsl:if test='string-length($internaldtd) > 0'>
-      <xsl:text> [</xsl:text>
-      <xsl:copy-of select='$internaldtd'/>
-      <xsl:text>]</xsl:text>
-    </xsl:if>
-
-    <xsl:text disable-output-escaping='yes'>>
-</xsl:text>
-  </xsl:template>
-
-  <doc:template name="markup:element-declaration" xmlns="">
-    <refpurpose>Create an Element Declaration</refpurpose>
-
-    <refdescription>
-      <para>This template returns an element declaration..</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-	<varlistentry>
-	  <term>type</term>
-	  <listitem>
-	    <para>The element type.</para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>content-spec</term>
-	  <listitem>
-	    <para>The content specification.</para>
-	  </listitem>
-	</varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns an element declaration as a string.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name='markup:element-declaration'>
-    <xsl:param name='type'/>
-    <xsl:param name='content-spec' select="'ANY'"/>
-
-    <xsl:if test='string-length($type) = 0'>
-      <xsl:message terminate='yes'>element type must be specified</xsl:message>
-    </xsl:if>
-    <xsl:if test='string-length($content-spec) = 0'>
-      <xsl:message terminate='yes'>content specification must be specified</xsl:message>
-    </xsl:if>
-
-    <xsl:text disable-output-escaping='yes'><!ELEMENT </xsl:text>
-    <xsl:copy-of select='$type'/>
-    <xsl:text> </xsl:text>
-    <xsl:copy-of select='$content-spec'/>
-    <xsl:text disable-output-escaping='yes'>></xsl:text>
-  </xsl:template>
-
-  <doc:template name="markup:attlist-declaration" xmlns="">
-    <refpurpose>Create an Attribute List Declaration</refpurpose>
-
-    <refdescription>
-      <para>This template returns an attribute list declaration.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-	<varlistentry>
-	  <term>type</term>
-	  <listitem>
-	    <para>The element type.</para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>attr-defns</term>
-	  <listitem>
-	    <para>Attribute definitions.</para>
-	  </listitem>
-	</varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns an attribute list declaration as a string.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name='markup:attlist-declaration'>
-    <xsl:param name='type'/>
-    <xsl:param name='attr-defns'/>
-
-    <xsl:if test='string-length($type) = 0'>
-      <xsl:message terminate='yes'>element type must be specified</xsl:message>
-    </xsl:if>
-
-    <xsl:text disable-output-escaping='yes'><!ATTLIST </xsl:text>
-    <xsl:copy-of select='$type'/>
-    <xsl:text> </xsl:text>
-    <xsl:copy-of select='$attr-defns'/>
-    <xsl:text disable-output-escaping='yes'>></xsl:text>
-  </xsl:template>
-
-  <doc:template name="markup:attribute-definition" xmlns="">
-    <refpurpose>Create an Attribute Definition</refpurpose>
-
-    <refdescription>
-      <para>This template returns an attribute definition.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-	<varlistentry>
-	  <term>name</term>
-	  <listitem>
-	    <para>The attribute name.</para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>type</term>
-	  <listitem>
-	    <para>The attribute type.</para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>default</term>
-	  <listitem>
-	    <para>The attribute default.</para>
-	  </listitem>
-	</varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns an attribute definition as a string.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name='markup:attribute-definition'>
-    <xsl:param name='name'/>
-    <xsl:param name='type'/>
-    <xsl:param name='default'/>
-
-    <xsl:if test='string-length($name) = 0'>
-      <xsl:message terminate='yes'>attribute name must be specified</xsl:message>
-    </xsl:if>
-    <xsl:if test='string-length($type) = 0'>
-      <xsl:message terminate='yes'>attribute type must be specified</xsl:message>
-    </xsl:if>
-    <xsl:if test='string-length($default) = 0'>
-      <xsl:message terminate='yes'>attribute default must be specified</xsl:message>
-    </xsl:if>
-
-    <xsl:text> </xsl:text>
-    <xsl:copy-of select='$name'/>
-    <xsl:text> </xsl:text>
-    <xsl:copy-of select='$type'/>
-    <xsl:text> </xsl:text>
-    <xsl:copy-of select='$default'/>
-  </xsl:template>
-
-  <doc:template name="markup:entity-declaration" xmlns="">
-    <refpurpose>Create an Entity Declaration</refpurpose>
-
-    <refdescription>
-      <para>This template returns an entity declaration.</para>
-      <para>If the 'text' parameter is given a value, then an internal entity is created.  If either the 'publicid' or 'systemid' parameters are given a value then an external entity is created.  It is an error for the 'text' parameter to have value as well as the 'publicid', 'systemid' or 'notation' parameters.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-	<varlistentry>
-	  <term>name</term>
-	  <listitem>
-	    <para>The entity name.</para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>parameter</term>
-	  <listitem>
-	    <para>Boolean value to determine whether a parameter entity is created.  Default is 'false()'.</para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>text</term>
-	  <listitem>
-	    <para>The replacement text.  Must be a string.</para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>nodes</term>
-	  <listitem>
-	    <para>The replacement text as a nodeset.  The nodeset is formatted as XML using the as-xml template.  If both text and nodes are specified then nodes takes precedence.</para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>publicid</term>
-	  <listitem>
-	    <para>The public identifier for an external entity.</para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>systemid</term>
-	  <listitem>
-	    <para>The system identifier for an external entity.</para>
-	  </listitem>
-	</varlistentry>
- 	<varlistentry>
-	  <term>notation</term>
-	  <listitem>
-	    <para>The notation for an external entity.</para>
-	  </listitem>
-	</varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns an entity declaration as a string.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name='markup:entity-declaration'>
-    <xsl:param name='name'/>
-    <xsl:param name='parameter' select='false()'/>
-    <xsl:param name='text'/>
-    <xsl:param name='nodes'/>
-    <xsl:param name='publicid'/>
-    <xsl:param name='systemid'/>
-    <xsl:param name='notation'/>
-
-    <xsl:if test='string-length($name) = 0'>
-      <xsl:message terminate='yes'>entity name must be specified</xsl:message>
-    </xsl:if>
-    <xsl:if test='string-length($text) > 0 and 
-                  (string-length($publicid) > 0 or
-                   string-length($systemid) > 0 or
-                   string-length($notation) > 0)'>
-      <xsl:message terminate='yes'>both replacement text and external identifier specified</xsl:message>
-    </xsl:if>
-
-    <xsl:text disable-output-escaping='yes'><!ENTITY </xsl:text>
-    <xsl:copy-of select='$name'/>
-    <xsl:text> </xsl:text>
-    <xsl:if test="$parameter">
-      <xsl:text>% </xsl:text>
-    </xsl:if>
-
-    <xsl:choose>
-      <xsl:when test="$nodes">
-        <xsl:call-template name='markup:quote-value'>
-          <xsl:with-param name='value'>
-            <xsl:call-template name="markup:as-xml">
-              <xsl:with-param name="nodes" select="$nodes"/>
-            </xsl:call-template>
-          </xsl:with-param>
-        </xsl:call-template>
-      </xsl:when>
-      <xsl:when test='$text'>
-        <xsl:call-template name='markup:quote-value'>
-          <xsl:with-param name='value' select='$text'/>
-        </xsl:call-template>
-      </xsl:when>
-      <xsl:otherwise>
-        <xsl:call-template name='markup:external-identifier'>
-          <xsl:with-param name='publicid' select='$publicid'/>
-          <xsl:with-param name='systemid' select='$systemid'/>
-        </xsl:call-template>
-      </xsl:otherwise>
-    </xsl:choose>
-
-    <xsl:if test='$notation'>
-      <xsl:text> NDATA "</xsl:text>
-      <xsl:copy-of select='$notation'/>
-      <xsl:text>"</xsl:text>
-    </xsl:if>
-
-    <xsl:text disable-output-escaping='yes'>></xsl:text>
-  </xsl:template>
-
-  <doc:template name="markup:quote-value" xmlns="">
-    <refpurpose>Quote an Attribute Value</refpurpose>
-
-    <refdescription>
-      <para>This template returns a quoted value.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-	<varlistentry>
-	  <term>value</term>
-	  <listitem>
-	    <para>The value to quote.</para>
-	  </listitem>
-	</varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns a quote value as a string.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name='markup:quote-value'>
-    <xsl:param name='value'/>
-
-    <xsl:variable name="quoted">
-      <xsl:call-template name='markup:quote-value-aux'>
-        <xsl:with-param name='value' select='$value'/>
-      </xsl:call-template>
-    </xsl:variable>
-
-    <xsl:choose>
-      <xsl:when test="contains($value, '<')">
-        <xsl:call-template name='str:subst'>
-          <xsl:with-param name='text' select='$quoted'/>
-          <xsl:with-param name='replace'><</xsl:with-param>
-          <xsl:with-param name='with'>
-            <xsl:text disable-output-escaping='yes'>&lt;</xsl:text>
-          </xsl:with-param>
-        </xsl:call-template>
-      </xsl:when>
-      <xsl:otherwise>
-        <xsl:copy-of select='$quoted'/>
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:template>
-
-  <xsl:template name='markup:quote-value-aux'>
-    <xsl:param name='value'/>
-
-    <!-- Quoting hell! -->
-    <xsl:variable name="quot">"</xsl:variable>
-    <xsl:variable name="apos">'</xsl:variable>
-
-    <xsl:choose>
-      <xsl:when test='contains($value, $quot) and contains($value, $apos)'>
-        <xsl:text>"</xsl:text>
-        <xsl:call-template name='str:subst'>
-          <xsl:with-param name='text' select='$value'/>
-          <xsl:with-param name='replace'>"</xsl:with-param>
-          <xsl:with-param name='with'>
-            <xsl:text disable-output-escaping='yes'>&quot;</xsl:text>
-          </xsl:with-param>
-        </xsl:call-template>
-        <xsl:text>"</xsl:text>
-      </xsl:when>
-      <xsl:when test='contains($value, $quot)'>
-        <xsl:text>'</xsl:text>
-        <xsl:value-of select='$value'/>
-        <xsl:text>'</xsl:text>
-      </xsl:when>
-      <xsl:otherwise>
-        <xsl:text>"</xsl:text>
-        <xsl:value-of select='$value'/>
-        <xsl:text>"</xsl:text>
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:template>
-
-  <doc:template name="markup:external-identifier" xmlns="">
-    <refpurpose>Create an External Identifier</refpurpose>
-
-    <refdescription>
-      <para>This template returns an external identifier.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-	<varlistentry>
-	  <term>publicid</term>
-	  <listitem>
-	    <para>The public identifier.</para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>systemid</term>
-	  <listitem>
-	    <para>The system identifier.</para>
-	  </listitem>
-	</varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns an external identifier as a string.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name='markup:external-identifier'>
-    <xsl:param name='publicid'/>
-    <xsl:param name='systemid'/>
-    <xsl:param name='leading-space' select='false()'/>
-
-    <xsl:choose>
-      <xsl:when test='string-length($publicid) > 0'>
-        <xsl:if test='$leading-space'>
-          <xsl:text> </xsl:text>
-        </xsl:if>
-        <xsl:text disable-output-escaping='yes'>PUBLIC "</xsl:text>
-        <xsl:value-of select='$publicid' disable-output-escaping='yes'/>
-        <xsl:text disable-output-escaping='yes'>"</xsl:text>
-        <xsl:if test='string-length($systemid) > 0'>
-          <xsl:text disable-output-escaping='yes'> "</xsl:text>
-          <xsl:value-of select='$systemid' disable-output-escaping='yes'/>
-          <xsl:text disable-output-escaping='yes'>"</xsl:text>
-        </xsl:if>
-      </xsl:when>
-      <xsl:when test="string-length($systemid) > 0">
-        <xsl:if test='$leading-space'>
-          <xsl:text> </xsl:text>
-        </xsl:if>
-        <xsl:text disable-output-escaping='yes'>SYSTEM "</xsl:text>
-        <xsl:value-of select='$systemid' disable-output-escaping='yes'/>
-        <xsl:text disable-output-escaping='yes'>"</xsl:text>
-      </xsl:when>
-    </xsl:choose>
-  </xsl:template>
-
-  <doc:template name="markup:entity-reference" xmlns="">
-    <refpurpose>Create an Entity Reference</refpurpose>
-
-    <refdescription>
-      <para>This template returns an entity reference.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-	<varlistentry>
-	  <term>name</term>
-	  <listitem>
-	    <para>The name of the entity.</para>
-	  </listitem>
-	</varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns an entity reference as a string.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name='markup:entity-reference'>
-    <xsl:param name='name'/>
-
-    <xsl:text disable-output-escaping='yes'>&</xsl:text>
-    <xsl:value-of select='$name'/>
-    <xsl:text>;</xsl:text>
-
-  </xsl:template>
-
-  <doc:template name="markup:notation-declaration" xmlns="">
-    <refpurpose>Create a Notation Declaration</refpurpose>
-
-    <refdescription>
-      <para>This template returns a notation declaration.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-	<varlistentry>
-	  <term>name</term>
-	  <listitem>
-	    <para>The notation name.</para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>publicid</term>
-	  <listitem>
-	    <para>The public identifier for the notation.</para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>systemid</term>
-	  <listitem>
-	    <para>The system identifier for the notation.</para>
-	  </listitem>
-	</varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns a notation declaration as a string.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name='markup:notation-declaration'>
-    <xsl:param name='name'/>
-    <xsl:param name='publicid'/>
-    <xsl:param name='systemid'/>
-
-    <xsl:if test='string-length($name) = 0'>
-      <xsl:message terminate='yes'>notation name must be specified</xsl:message>
-    </xsl:if>
-    <xsl:if test='string-length($publicid) = 0 and string-length($systemid) = 0'>
-      <xsl:message terminate='yes'>external identifier must be specified</xsl:message>
-    </xsl:if>
-
-    <xsl:text disable-output-escaping='yes'><!NOTATION </xsl:text>
-    <xsl:copy-of select='$name'/>
-
-    <xsl:call-template name='markup:external-identifier'>
-      <xsl:with-param name='publicid' select='$publicid'/>
-      <xsl:with-param name='systemid' select='$systemid'/>
-      <xsl:with-param name='leading-space' select='true()'/>
-    </xsl:call-template>
-
-    <xsl:text disable-output-escaping='yes'>></xsl:text>
-  </xsl:template>
-
-  <doc:template name="markup:cdata-section" xmlns="">
-    <refpurpose>Create a CDATA Section</refpurpose>
-
-    <refdescription>
-      <para>This template returns a CDATA Section.  The XSLT specification provides a mechanism for instructing the XSL processor to output character data in a CDATA section for certain elements, but this template may be useful in those circumstances where not all instances of an element are to have their content placed in a CDATA section.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-	<varlistentry>
-	  <term>text</term>
-	  <listitem>
-	    <para>The content of the CDATA section.</para>
-	  </listitem>
-	</varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns a CDATA section as a string.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name='markup:cdata-section'>
-    <xsl:param name='text'/>
-
-    <xsl:if test="contains($text, ']]>')">
-      <xsl:message terminate="yes">CDATA section contains "]]>"</xsl:message>
-    </xsl:if>
-
-    <xsl:text disable-output-escaping='yes'><![CDATA[</xsl:text>
-    <xsl:copy-of select='$text'/>
-    <xsl:text disable-output-escaping='yes'>]]></xsl:text>
-  </xsl:template>
-
-  <doc:template name="markup:as-xml" xmlns="">
-    <refpurpose>Format Nodeset As XML Markup</refpurpose>
-
-    <refdescription>
-      <para>This template returns XML markup.  Each node in the given nodeset is converted to its equivalent XML markup.</para>
-
-      <para>BUG: This version may not adequately handle XML Namespaces.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-	<varlistentry>
-	  <term>nodes</term>
-	  <listitem>
-	    <para>Nodeset to format as XML.</para>
-	  </listitem>
-	</varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns XML markup.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name='markup:as-xml'>
-    <xsl:param name='nodes'/>
-
-    <xsl:if test="$nodes">
-      <xsl:choose>
-        <xsl:when test="$nodes[1]/self::*">
-          <xsl:text disable-output-escaping='yes'><</xsl:text>
-          <xsl:value-of select="name($nodes[1])"/>
-          <xsl:for-each select="$nodes[1]/@*">
-            <xsl:text> </xsl:text>
-            <xsl:value-of select="name()"/>
-            <xsl:text>=</xsl:text>
-            <xsl:call-template name='markup:quote-value'>
-              <xsl:with-param name='value' select='.'/>
-            </xsl:call-template>
-          </xsl:for-each>
-
-          <xsl:choose>
-            <xsl:when test='$nodes[1]/node()'>
-              <xsl:text disable-output-escaping='yes'>></xsl:text>
-              <xsl:call-template name='markup:as-xml'>
-                <xsl:with-param name='nodes' select='$nodes[1]/node()'/>
-              </xsl:call-template>
-              <xsl:text disable-output-escaping='yes'></</xsl:text>
-              <xsl:value-of select="name($nodes[1])"/>
-              <xsl:text disable-output-escaping='yes'>></xsl:text>
-            </xsl:when>
-            <xsl:otherwise>
-              <xsl:text disable-output-escaping='yes'>/></xsl:text>
-            </xsl:otherwise>
-          </xsl:choose>
-        </xsl:when>
-        <xsl:when test="$nodes[1]/self::text()">
-          <xsl:value-of select="$nodes[1]"/>
-        </xsl:when>
-        <xsl:when test="$nodes[1]/self::comment()">
-          <xsl:text disable-output-escaping='yes'><!--</xsl:text>
-          <xsl:value-of select="$nodes[1]"/>
-          <xsl:text disable-output-escaping='yes'>--></xsl:text>
-        </xsl:when>
-        <xsl:when test="$nodes[1]/self::processing-instruction()">
-          <xsl:text disable-output-escaping='yes'><?</xsl:text>
-          <xsl:value-of select="name($nodes[1])"/>
-          <xsl:text> </xsl:text>
-          <xsl:value-of select="$nodes[1]"/>
-          <xsl:text disable-output-escaping='yes'>?></xsl:text>
-        </xsl:when>
-
-        <xsl:when test="not($nodes[1]/parent::*)"/> <!-- root node -->
-        <xsl:when test="count($nodes[1] | $nodes[1]/../namespace::*) = count($nodes[1]/../namespace::*)"/> <!-- namespace node -->
-        <xsl:when test="count($nodes[1] | $nodes[1]/../@*) = count($nodes[1]/../@*)"/> <!-- attribute node -->
-      </xsl:choose>
-
-      <xsl:call-template name="markup:as-xml">
-        <xsl:with-param name="nodes" select="$nodes[position() > 1]"/>
-      </xsl:call-template>
-    </xsl:if>
-  </xsl:template>
-
-</xsl:stylesheet>
diff --git a/tclxml-3.2/doc/xsltsl/math.xsl b/tclxml-3.2/doc/xsltsl/math.xsl
deleted file mode 100644
index fb9f871..0000000
--- a/tclxml-3.2/doc/xsltsl/math.xsl
+++ /dev/null
@@ -1,704 +0,0 @@
-<?xml version="1.0"?>
-<xsl:stylesheet version="1.0"
-  xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
-  xmlns:doc="http://xsltsl.org/xsl/documentation/1.0"
-  xmlns:math="http://xsltsl.org/math"
-  exclude-result-prefixes="doc math">
-
-  <doc:reference xmlns="">
-    <referenceinfo>
-      <releaseinfo role="meta">
-        $Id: math.xsl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-      </releaseinfo>
-      <author>
-        <surname>Ball</surname>
-        <firstname>Steve</firstname>
-      </author>
-      <copyright>
-        <year>2004</year>
-        <year>2002</year>
-        <holder>Steve Ball</holder>
-      </copyright>
-    </referenceinfo>
-
-    <title>Math Module</title>
-
-    <partintro>
-      <section>
-        <title>Introduction</title>
-
-        <para>This module provides mathematical functions.</para>
-      </section>
-    </partintro>
-
-  </doc:reference>
-
-  <doc:template name="math:power" xmlns="">
-    <refpurpose>Power</refpurpose>
-
-    <refdescription>
-      <para>Raises a number to a power.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>base</term>
-          <listitem>
-            <para>The base number.  Must be a number.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>power</term>
-          <listitem>
-            <para>The power to raise the number to.  Must be an integer.</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns base multiplied by itself power times.  If the base or power are not numbers or if the power is fractional then an empty string is returned.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name="math:power">
-    <xsl:param name="base"/>
-    <xsl:param name="power"/>
-
-    <xsl:choose>
-      <xsl:when test='$power = "0" and $base = "0"'>
-        <xsl:text>1</xsl:text>
-      </xsl:when>
-      <xsl:when test='$power = "0" and number($base)'>
-        <xsl:text>1</xsl:text>
-      </xsl:when>
-      <xsl:when test='$power = "0" and not(number($base))'/>
-      <xsl:when test='$base = "0" and number($power)'>
-        <xsl:text>0</xsl:text>
-      </xsl:when>
-
-      <xsl:when test='not(number($base)) or not(number($power))'/>
-
-      <xsl:when test='floor(number($power)) != number($power)'/>
-
-      <xsl:when test='number($power) < 0'>
-        <xsl:variable name='x'>
-          <xsl:call-template name='math:power'>
-            <xsl:with-param name='base' select='$base'/>
-            <xsl:with-param name='power' select='-1 * $power'/>
-          </xsl:call-template>
-        </xsl:variable>
-        <xsl:value-of select='1 div $x'/>
-      </xsl:when>
-
-      <xsl:when test='number($power) = 1'>
-        <xsl:value-of select='$base'/>
-      </xsl:when>
-
-      <xsl:when test='number($power) > 0'>
-        <xsl:variable name='x'>
-          <xsl:call-template name='math:power'>
-            <xsl:with-param name='base' select='$base'/>
-            <xsl:with-param name='power' select='$power - 1'/>
-          </xsl:call-template>
-        </xsl:variable>
-        <xsl:value-of select='$base * $x'/>
-      </xsl:when>
-      <xsl:otherwise/>
-    </xsl:choose>
-  </xsl:template>
-
-  <doc:template name="math:abs" xmlns="">
-    <refpurpose>Absolute Value</refpurpose>
-
-    <refdescription>
-      <para>Absolute value of a number.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>number</term>
-          <listitem>
-            <para>The number.  Must be a number.</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns the absolute value of the number.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name="math:abs">
-    <xsl:param name="number"/>
-
-    <xsl:choose>
-      <xsl:when test='$number < 0'>
-        <xsl:value-of select='$number * -1'/>
-      </xsl:when>
-      <xsl:when test='$number >= 0'>
-        <xsl:value-of select='$number'/>
-      </xsl:when>
-    </xsl:choose>
-  </xsl:template>
-
-  <doc:template name="math:cvt-hex-decimal" xmlns="">
-    <refpurpose>Conversion</refpurpose>
-
-    <refdescription>
-      <para>Converts a hexidecimal value to a decimal value.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>value</term>
-          <listitem>
-            <para>The hexidecimal number.  Must be a number in hexidecimal format.</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns the value as a decimal string.  If the value is not a number then a NaN value is returned.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name="math:cvt-hex-decimal">
-    <xsl:param name="value"/>
-
-    <xsl:choose>
-      <xsl:when test='$value = ""'/>
-
-      <xsl:when test='string-length($value) = 1'>
-        <xsl:call-template name='math:cvt-hex-decimal-digit'>
-          <xsl:with-param name='digit' select='$value'/>
-        </xsl:call-template>
-      </xsl:when>
-      <xsl:otherwise>
-        <xsl:variable name='first-digit'>
-          <xsl:call-template name='math:cvt-hex-decimal-digit'>
-            <xsl:with-param name='digit' select='substring($value, 1, 1)'/>
-          </xsl:call-template>
-        </xsl:variable>
-        <xsl:variable name='remainder'>
-          <xsl:call-template name='math:cvt-hex-decimal'>
-            <xsl:with-param name='value' select='substring($value, 2)'/>
-          </xsl:call-template>
-        </xsl:variable>
-
-        <xsl:value-of select='$first-digit * 16 + $remainder'/>
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:template>
-
-  <xsl:template name='math:cvt-hex-decimal-digit'>
-    <xsl:param name='digit' select='0'/>
-    <xsl:choose>
-      <xsl:when test='$digit <= 9'>
-        <xsl:value-of select='$digit'/>
-      </xsl:when>
-      <xsl:when test='$digit = "a" or $digit = "A"'>10</xsl:when>
-      <xsl:when test='$digit = "b" or $digit = "B"'>11</xsl:when>
-      <xsl:when test='$digit = "c" or $digit = "C"'>12</xsl:when>
-      <xsl:when test='$digit = "d" or $digit = "D"'>13</xsl:when>
-      <xsl:when test='$digit = "e" or $digit = "E"'>14</xsl:when>
-      <xsl:when test='$digit = "f" or $digit = "F"'>15</xsl:when>
-    </xsl:choose>
-  </xsl:template>
-
-  <doc:template name="math:cvt-decimal-hex" xmlns="">
-    <refpurpose>Conversion</refpurpose>
-
-    <refdescription>
-      <para>Converts a decimal value to a hexidecimal value.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>value</term>
-          <listitem>
-            <para>The decimal number.</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns the value as a hexidecimal string (lowercase).  If the value is not a number then a NaN value is returned.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name="math:cvt-decimal-hex">
-    <xsl:param name="value"/>
-
-    <xsl:choose>
-      <xsl:when test='$value = "0"'>0</xsl:when>
-      <xsl:when test='not(number($value))'>NaN</xsl:when>
-
-      <xsl:when test='$value div 16 >= 1'>
-        <xsl:call-template name='math:cvt-decimal-hex'>
-          <xsl:with-param name='value' select='floor($value div 16)'/>
-        </xsl:call-template>
-        <xsl:call-template name='math:cvt-decimal-hex'>
-          <xsl:with-param name='value' select='$value mod 16'/>
-        </xsl:call-template>
-      </xsl:when>
-      <xsl:when test='$value = 10'>a</xsl:when>
-      <xsl:when test='$value = 11'>b</xsl:when>
-      <xsl:when test='$value = 12'>c</xsl:when>
-      <xsl:when test='$value = 13'>d</xsl:when>
-      <xsl:when test='$value = 14'>e</xsl:when>
-      <xsl:when test='$value = 15'>f</xsl:when>
-      <xsl:otherwise>
-        <xsl:value-of select='$value'/>
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:template>
-
-  <doc:template name="math:ordinal" xmlns="">
-    <refpurpose>Ordinal number</refpurpose>
-
-    <refdescription>
-      <para>Gives the ordinal number of a given counting number.  For example, 1 becomes "1st".</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>number</term>
-          <listitem>
-            <para>An integer number.</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns the number with an ordinal suffix.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name="math:ordinal">
-    <xsl:param name="number"/>
-
-    <xsl:choose>
-      <xsl:when test='$number < 0'/>
-      <xsl:otherwise>
-        <xsl:value-of select='$number'/>
-        <xsl:choose>
-          <xsl:when test='$number = 11 or $number = 12 or $number = 13'>th</xsl:when>
-          <xsl:when test='$number mod 10 = 1'>st</xsl:when>
-          <xsl:when test='$number mod 10 = 2'>nd</xsl:when>
-          <xsl:when test='$number mod 10 = 3'>rd</xsl:when>
-          <xsl:otherwise>th</xsl:otherwise>
-        </xsl:choose>
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:template>
-
-
-  <doc:template name="math:ordinal-as-word" xmlns="">
-    <refpurpose>Returns an ordinal number</refpurpose>
-
-    <refdescription>
-      <para>This template returns the ordinal number for a given counting number as a word.  For example "first" for 1.</para>
-      <para>Only handles numbers less than 10000000 (ten million).</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-	<varlistentry>
-	  <term>number</term>
-	  <listitem>
-	    <para>The counting number.</para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>conjunctive</term>
-	  <listitem>
-	    <para>Whether to add the word "and" to the result, for example "one hundred and first" rather than "one hundred first".  Default is "yes".</para>
-	  </listitem>
-	</varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns the ordinal number as a string.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name="math:ordinal-as-word">
-    <xsl:param name="number" select="0"/>
-    <xsl:param name='conjunctive' select='"yes"'/>
-    <xsl:param name='preceding' select='0'/>
-
-    <xsl:choose>
-      <xsl:when test='$preceding = 1 and $number = 0'/>
-      <xsl:when test='$number = 0'>zeroth</xsl:when>
-
-      <xsl:when test="$number < 1 or $number != floor($number)"/>
-
-      <xsl:when test='$number = 1'>
-        <xsl:if test='$preceding = 1'> and </xsl:if>
-        <xsl:text>first</xsl:text>
-      </xsl:when>
-      <xsl:when test='$number = 2'>
-        <xsl:if test='$preceding = 1'> and </xsl:if>
-        <xsl:text>second</xsl:text>
-      </xsl:when>
-      <xsl:when test='$number = 3'>
-        <xsl:if test='$preceding = 1'> and </xsl:if>
-        <xsl:text>third</xsl:text>
-      </xsl:when>
-      <xsl:when test='$number = 4'>
-        <xsl:if test='$preceding = 1'> and </xsl:if>
-        <xsl:text>fourth</xsl:text>
-      </xsl:when>
-      <xsl:when test='$number = 5'>
-        <xsl:if test='$preceding = 1'> and </xsl:if>
-        <xsl:text>fifth</xsl:text>
-      </xsl:when>
-      <xsl:when test='$number = 6'>
-        <xsl:if test='$preceding = 1'> and </xsl:if>
-        <xsl:text>sixth</xsl:text>
-      </xsl:when>
-      <xsl:when test='$number = 7'>
-        <xsl:if test='$preceding = 1'> and </xsl:if>
-        <xsl:text>seventh</xsl:text>
-      </xsl:when>
-      <xsl:when test='$number = 8'>
-        <xsl:if test='$preceding = 1'> and </xsl:if>
-        <xsl:text>eighth</xsl:text>
-      </xsl:when>
-      <xsl:when test='$number = 9'>
-        <xsl:if test='$preceding = 1'> and </xsl:if>
-        <xsl:text>ninth</xsl:text>
-      </xsl:when>
-      <xsl:when test='$number = 10'>
-        <xsl:if test='$preceding = 1'> and </xsl:if>
-        <xsl:text>tenth</xsl:text>
-      </xsl:when>
-      <xsl:when test='$number = 11'>
-        <xsl:if test='$preceding = 1'> and </xsl:if>
-        <xsl:text>eleventh</xsl:text>
-      </xsl:when>
-      <xsl:when test='$number = 12'>
-        <xsl:if test='$preceding = 1'> and </xsl:if>
-        <xsl:text>twelveth</xsl:text>
-      </xsl:when>
-      <xsl:when test='$number = 13'>
-        <xsl:if test='$preceding = 1'> and </xsl:if>
-        <xsl:text>thirteenth</xsl:text>
-      </xsl:when>
-      <xsl:when test='$number = 14'>
-        <xsl:if test='$preceding = 1'> and </xsl:if>
-        <xsl:text>fourteenth</xsl:text>
-      </xsl:when>
-      <xsl:when test='$number = 15'>
-        <xsl:if test='$preceding = 1'> and </xsl:if>
-        <xsl:text>fifteenth</xsl:text>
-      </xsl:when>
-      <xsl:when test='$number = 16'>
-        <xsl:if test='$preceding = 1'> and </xsl:if>
-        <xsl:text>sixteenth</xsl:text>
-      </xsl:when>
-      <xsl:when test='$number = 17'>
-        <xsl:if test='$preceding = 1'> and </xsl:if>
-        <xsl:text>seventeenth</xsl:text>
-      </xsl:when>
-      <xsl:when test='$number = 18'>
-        <xsl:if test='$preceding = 1'> and </xsl:if>
-        <xsl:text>eighteenth</xsl:text>
-      </xsl:when>
-      <xsl:when test='$number = 19'>
-        <xsl:if test='$preceding = 1'> and </xsl:if>
-        <xsl:text>nineteenth</xsl:text>
-      </xsl:when>
-      <xsl:when test='$number = 20'>
-        <xsl:if test='$preceding = 1'> and </xsl:if>
-        <xsl:text>twentieth</xsl:text>
-      </xsl:when>
-      <xsl:when test='$number = 30'>
-        <xsl:if test='$preceding = 1'> and </xsl:if>
-        <xsl:text>thirtieth</xsl:text>
-      </xsl:when>
-      <xsl:when test='$number = 40'>
-        <xsl:if test='$preceding = 1'> and </xsl:if>
-        <xsl:text>fortieth</xsl:text>
-      </xsl:when>
-      <xsl:when test='$number = 50'>
-        <xsl:if test='$preceding = 1'> and </xsl:if>
-        <xsl:text>fiftieth</xsl:text>
-      </xsl:when>
-      <xsl:when test='$number = 60'>
-        <xsl:if test='$preceding = 1'> and </xsl:if>
-        <xsl:text>sixtieth</xsl:text>
-      </xsl:when>
-      <xsl:when test='$number = 70'>
-        <xsl:if test='$preceding = 1'> and </xsl:if>
-        <xsl:text>seventieth</xsl:text>
-      </xsl:when>
-      <xsl:when test='$number = 80'>
-        <xsl:if test='$preceding = 1'> and </xsl:if>
-        <xsl:text>eightieth</xsl:text>
-      </xsl:when>
-      <xsl:when test='$number = 90'>
-        <xsl:if test='$preceding = 1'> and </xsl:if>
-        <xsl:text>ninetieth</xsl:text>
-      </xsl:when>
-
-      <xsl:when test='$number mod 1000000 = 0'>
-        <xsl:call-template name='math:number-as-word'>
-          <xsl:with-param name='number' select='floor($number div 1000000)'/>
-        </xsl:call-template>
-        <xsl:text> millionth</xsl:text>
-      </xsl:when>
-      <xsl:when test='$number < 1000000 and $number mod 1000 = 0'>
-        <xsl:if test='$preceding = 1 and $conjunctive'> and </xsl:if>
-        <xsl:call-template name='math:number-as-word'>
-          <xsl:with-param name='number' select='floor($number div 1000)'/>
-        </xsl:call-template>
-        <xsl:text> thousandth</xsl:text>
-      </xsl:when>
-      <xsl:when test='$number < 1000 and $number mod 100 = 0'>
-        <xsl:if test='$preceding = 1 and $conjunctive'> and </xsl:if>
-        <xsl:call-template name='math:number-as-word'>
-          <xsl:with-param name='number' select='floor($number div 100)'/>
-        </xsl:call-template>
-        <xsl:text> hundredth</xsl:text>
-      </xsl:when>
-
-      <xsl:when test='$number > 1000000'>
-        <xsl:if test='$preceding = 1'>
-          <xsl:text> </xsl:text>
-          <xsl:if test='$conjunctive'>and </xsl:if>
-        </xsl:if>
-        <xsl:call-template name='math:number-as-word'>
-          <xsl:with-param name='number' select='floor($number div 1000000) * 1000000'/>
-        </xsl:call-template>
-        <xsl:choose>
-          <xsl:when
-            test='(floor(floor(($number mod 1000000) + 0.1) div 100000) > 0 and $number mod 100000 > 0) or
-            (floor(floor(($number mod 100000) + 0.1) div 10000) > 0 and $number mod 10000 > 0) or
-            (floor(floor(($number mod 10000) + 0.1) div 1000) > 0 and $number mod 1000 > 0) or
-            (floor(floor(($number mod 1000) + 0.1) div 100) > 0 and $number mod 100 > 0) or
-            (floor(floor(($number mod 100) + 0.1) div 10) > 0 and $number mod 10 > 0 and $number mod 100 > 20)'>
-            <xsl:text> </xsl:text>
-            <xsl:call-template name='math:ordinal-as-word'>
-              <xsl:with-param name='number' select='floor(($number mod 1000000) + 0.1)'/>
-              <xsl:with-param name='conjunctive' select='$conjunctive'/>
-              <xsl:with-param name='preceding' select='0'/>
-            </xsl:call-template>
-          </xsl:when>
-          <xsl:otherwise>
-            <xsl:call-template name='math:ordinal-as-word'>
-              <xsl:with-param name='number' select='floor(($number mod 1000000) + 0.1)'/>
-              <xsl:with-param name='conjunctive' select='$conjunctive'/>
-              <xsl:with-param name='preceding' select='1'/>
-            </xsl:call-template>
-          </xsl:otherwise>
-        </xsl:choose>
-      </xsl:when>
-      <xsl:when test='$number > 1000'>
-        <xsl:if test='$preceding = 1'>
-          <xsl:text> </xsl:text>
-          <xsl:if test='$conjunctive'>and </xsl:if>
-        </xsl:if>
-        <xsl:call-template name='math:number-as-word'>
-          <xsl:with-param name='number' select='floor($number div 1000) * 1000'/>
-          <xsl:with-param name='conjunctive' select='$conjunctive'/>
-        </xsl:call-template>
-        <xsl:choose>
-          <xsl:when test='floor(floor(($number mod 1000) + 0.1) div 100) > 0'>
-            <xsl:text> </xsl:text>
-            <xsl:call-template name='math:ordinal-as-word'>
-              <xsl:with-param name='number' select='floor(($number mod 1000) + 0.1)'/>
-              <xsl:with-param name='conjunctive' select='$conjunctive'/>
-              <xsl:with-param name='preceding' select='0'/>
-            </xsl:call-template>
-          </xsl:when>
-          <xsl:otherwise>
-            <xsl:call-template name='math:ordinal-as-word'>
-              <xsl:with-param name='number' select='floor(($number mod 1000) + 0.1)'/>
-              <xsl:with-param name='conjunctive' select='$conjunctive'/>
-              <xsl:with-param name='preceding' select='1'/>
-            </xsl:call-template>
-          </xsl:otherwise>
-        </xsl:choose>
-      </xsl:when>
-      <xsl:when test='$number > 100'>
-        <xsl:if test='$preceding = 1'>
-          <xsl:text> </xsl:text>
-          <xsl:if test='$conjunctive'>and </xsl:if>
-        </xsl:if>
-        <xsl:call-template name='math:number-as-word'>
-          <xsl:with-param name='number' select='floor($number div 100) * 100'/>
-        </xsl:call-template>
-        <xsl:call-template name='math:ordinal-as-word'>
-          <xsl:with-param name='number' select='floor(($number mod 100) + 0.1)'/>
-          <xsl:with-param name='conjunctive' select='$conjunctive'/>
-          <xsl:with-param name='preceding' select='1'/>
-        </xsl:call-template>
-      </xsl:when>
-
-      <xsl:when test='$number > 20'>
-        <xsl:if test='$preceding = 1'>
-          <xsl:text> </xsl:text>
-          <xsl:if test='$conjunctive'>and </xsl:if>
-        </xsl:if>
-        <xsl:call-template name='math:number-as-word'>
-          <xsl:with-param name='number' select='floor($number div 10) * 10'/>
-        </xsl:call-template>
-        <xsl:text> </xsl:text>
-        <xsl:call-template name='math:ordinal-as-word'>
-          <xsl:with-param name='number' select='floor(($number mod 10) + 0.1)'/>
-          <xsl:with-param name='conjunctive' select='$conjunctive'/>
-        </xsl:call-template>
-      </xsl:when>
-
-      <xsl:otherwise/>
-    </xsl:choose>
-  </xsl:template>
-
-  <doc:template name="math:number-as-word" xmlns="">
-    <refpurpose>Returns a number as a word</refpurpose>
-
-    <refdescription>
-      <para>This template returns the word for a given integer number, for example "one" for 1.</para>
-      <para>Only handles numbers less than 10000000 (ten million).</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-	<varlistentry>
-	  <term>number</term>
-	  <listitem>
-	    <para>The counting number.</para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>conjunctive</term>
-	  <listitem>
-	    <para>Adds the word "and" where appropriate, for example.</para>
-	  </listitem>
-	</varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns the number as a string.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name="math:number-as-word">
-    <xsl:param name="number" select="0"/>
-    <xsl:param name='conjunctive' select='true()'/>
-
-    <xsl:choose>
-
-      <xsl:when test='$number = 0'>zero</xsl:when>
-
-      <xsl:when test='$number < 0'>
-        <xsl:text>minus </xsl:text>
-        <xsl:call-template name='math:number-as-word'>
-          <xsl:with-param name='number' select='-1 * $number'/>
-        </xsl:call-template>
-      </xsl:when>
-
-      <xsl:when test="$number != floor($number)"/>
-
-      <xsl:when test='$number mod 1000000 = 0'>
-        <xsl:call-template name='math:number-as-word'>
-          <xsl:with-param name='number' select='floor($number div 1000000)'/>
-        </xsl:call-template>
-        <xsl:text> million</xsl:text>
-      </xsl:when>
-      <xsl:when test='$number >= 1000000'>
-        <xsl:call-template name='math:number-as-word'>
-          <xsl:with-param name='number' select='floor($number div 1000000)'/>
-        </xsl:call-template>
-        <xsl:text> million </xsl:text>
-        <xsl:call-template name='math:number-as-word'>
-          <xsl:with-param name='number' select='floor(($number mod 1000000) + 0.1)'/>
-        </xsl:call-template>
-      </xsl:when>
-      <xsl:when test='$number mod 1000 = 0'>
-        <xsl:call-template name='math:number-as-word'>
-          <xsl:with-param name='number' select='floor($number div 1000)'/>
-        </xsl:call-template>
-        <xsl:text> thousand</xsl:text>
-      </xsl:when>
-      <xsl:when test='$number >= 1000'>
-        <xsl:call-template name='math:number-as-word'>
-          <xsl:with-param name='number' select='floor($number div 1000)'/>
-        </xsl:call-template>
-        <xsl:text> thousand </xsl:text>
-        <xsl:if test='$conjunctive and floor(floor(($number mod 1000) + 0.1) div 100) = 0'>and </xsl:if>
-        <xsl:call-template name='math:number-as-word'>
-          <xsl:with-param name='number' select='floor(($number mod 1000) + 0.1)'/>
-        </xsl:call-template>
-      </xsl:when>
-      <xsl:when test='$number mod 100 = 0'>
-        <xsl:call-template name='math:number-as-word'>
-          <xsl:with-param name='number' select='floor($number div 100)'/>
-        </xsl:call-template>
-        <xsl:text> hundred</xsl:text>
-      </xsl:when>
-      <xsl:when test='$number >= 100'>
-        <xsl:call-template name='math:number-as-word'>
-          <xsl:with-param name='number' select='floor($number div 100)'/>
-        </xsl:call-template>
-        <xsl:text> hundred </xsl:text>
-        <xsl:if test='$conjunctive'>and </xsl:if>
-        <xsl:call-template name='math:number-as-word'>
-          <xsl:with-param name='number' select='floor(($number mod 100) + 0.1)'/>
-        </xsl:call-template>
-      </xsl:when>
-
-      <xsl:when test='$number = 1'>one</xsl:when>
-      <xsl:when test='$number = 2'>two</xsl:when>
-      <xsl:when test='$number = 3'>three</xsl:when>
-      <xsl:when test='$number = 4'>four</xsl:when>
-      <xsl:when test='$number = 5'>five</xsl:when>
-      <xsl:when test='$number = 6'>six</xsl:when>
-      <xsl:when test='$number = 7'>seven</xsl:when>
-      <xsl:when test='$number = 8'>eight</xsl:when>
-      <xsl:when test='$number = 9'>nine</xsl:when>
-      <xsl:when test='$number = 10'>ten</xsl:when>
-      <xsl:when test='$number = 11'>eleven</xsl:when>
-      <xsl:when test='$number = 12'>twelve</xsl:when>
-      <xsl:when test='$number = 13'>thirteen</xsl:when>
-      <xsl:when test='$number = 14'>fourteen</xsl:when>
-      <xsl:when test='$number = 15'>fifteen</xsl:when>
-      <xsl:when test='$number = 16'>sixteen</xsl:when>
-      <xsl:when test='$number = 17'>seventeen</xsl:when>
-      <xsl:when test='$number = 18'>eighteen</xsl:when>
-      <xsl:when test='$number = 19'>nineteen</xsl:when>
-      <xsl:when test='$number = 20'>twenty</xsl:when>
-      <xsl:when test='$number = 30'>thirty</xsl:when>
-      <xsl:when test='$number = 40'>forty</xsl:when>
-      <xsl:when test='$number = 50'>fifty</xsl:when>
-      <xsl:when test='$number = 60'>sixty</xsl:when>
-      <xsl:when test='$number = 70'>seventy</xsl:when>
-      <xsl:when test='$number = 80'>eighty</xsl:when>
-      <xsl:when test='$number = 90'>ninety</xsl:when>
-
-      <xsl:when test='$number < 100'>
-        <xsl:call-template name='math:number-as-word'>
-          <xsl:with-param name='number' select='floor($number div 10) * 10'/>
-        </xsl:call-template>
-        <xsl:text> </xsl:text>
-        <xsl:call-template name='math:number-as-word'>
-          <xsl:with-param name='number' select='floor(($number mod 10) + 0.1)'/>
-        </xsl:call-template>
-      </xsl:when>
-    </xsl:choose>
-  </xsl:template>
-</xsl:stylesheet>
-
diff --git a/tclxml-3.2/doc/xsltsl/node.xsl b/tclxml-3.2/doc/xsltsl/node.xsl
deleted file mode 100644
index 2b1dfad..0000000
--- a/tclxml-3.2/doc/xsltsl/node.xsl
+++ /dev/null
@@ -1,229 +0,0 @@
-<?xml version="1.0"?>
-
-<xsl:stylesheet version="1.0"
-	xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
-	xmlns:doc="http://xsltsl.org/xsl/documentation/1.0"
-	xmlns:node="http://xsltsl.org/node"
-	extension-element-prefixes="doc node">
-
-  <doc:reference xmlns="">
-    <referenceinfo>
-      <releaseinfo role="meta">
-	$Id: node.xsl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-      </releaseinfo>
-      <author>
-	<surname>Ball</surname>
-	<firstname>Steve</firstname>
-      </author>
-      <copyright>
-	<year>2001</year>
-	<holder>Steve Ball</holder>
-      </copyright>
-    </referenceinfo>
-
-    <title>Node Templates</title>
-
-    <partintro>
-      <section>
-	<title>Introduction</title>
-
-	<para>This stylesheet module provides functions for reporting on or manipulating nodes and nodesets.</para>
-
-      </section>
-    </partintro>
-
-  </doc:reference>
-
-  <doc:template name="node:xpath" xmlns="">
-    <refpurpose>Returns an XPath location path</refpurpose>
-
-    <refdescription>
-      <para>This template returns an XPath location path that uniquely identifies the given node within the document.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-	<varlistentry>
-	  <term>node</term>
-	  <listitem>
-	    <para>The node to create an XPath for.  If this parameter is given as a nodeset, then the first node in the nodeset is used.</para>
-	  </listitem>
-	</varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns an XPath location path as a string.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name="node:xpath">
-    <xsl:param name="node" select="."/>
-
-    <xsl:choose>
-
-      <xsl:when test="$node">
-
-        <xsl:for-each select="$node[1]/ancestor-or-self::*">
-          <xsl:text/>/<xsl:value-of select="name()"/>
-          <xsl:text/>[<xsl:value-of select="count(preceding-sibling::*[name() = name(current())]) + 1"/>]<xsl:text/>
-        </xsl:for-each>
-
-        <xsl:choose>
-
-          <xsl:when test="$node[1]/self::comment()">
-            <xsl:text>/comment()</xsl:text>
-            <xsl:text/>[<xsl:value-of select="count($node[1]/preceding-sibling::comment()) + 1" />]<xsl:text/>
-          </xsl:when>
-
-          <xsl:when test="$node[1]/self::processing-instruction()">
-            <xsl:text>/processing-instruction()</xsl:text>
-            <xsl:text/>[<xsl:value-of select="count($node[1]/preceding-sibling::processing-instruction()) + 1" />]<xsl:text/>
-          </xsl:when>
-
-          <xsl:when test="$node[1]/self::text()">
-            <xsl:text>/text()</xsl:text>
-            <xsl:text/>[<xsl:value-of select="count($node[1]/preceding-sibling::text()) + 1" />]<xsl:text/>
-          </xsl:when>
-
-          <xsl:when test="not($node[1]/..)">
-            <xsl:text>/</xsl:text>
-          </xsl:when>
-
-          <xsl:when test="count($node[1]/../namespace::* | $node[1]) = count($node[1]/../namespace::*)">
-            <xsl:text/>/namespace::<xsl:value-of select="name($node[1])" />
-          </xsl:when>
-
-          <xsl:when test="count($node[1]/../@* | $node[1]) = count($node[1]/../@*)">
-            <xsl:text/>/@<xsl:value-of select="name($node[1])" />
-          </xsl:when>
-
-        </xsl:choose>      
-      </xsl:when>
-
-      <xsl:otherwise>
-        <xsl:text>/..</xsl:text>
-      </xsl:otherwise>
-
-    </xsl:choose>
-
-  </xsl:template>
-
-  <doc:template name="node:type" xmlns="">
-    <refpurpose>Return node type</refpurpose>
-
-    <refdescription>
-      <para>Returns the type of a node as a string.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-	<varlistentry>
-	  <term>node</term>
-	  <listitem>
-	    <para>The node to get the type for.  If this parameter is given as a nodeset, then the first node in the nodeset is used.</para>
-	  </listitem>
-	</varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns node type as a string.  Values returned are:</para>
-      <variablelist>
-	<varlistentry>
-	  <term>Element</term>
-	  <listitem>
-	    <para><literal>element</literal></para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>Text Node</term>
-	  <listitem>
-	    <para><literal>text</literal></para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>Comment</term>
-	  <listitem>
-	    <para><literal>comment</literal></para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>Processing Instruction</term>
-	  <listitem>
-	    <para><literal>processing instruction</literal></para>
-	  </listitem>
-	</varlistentry>
-      </variablelist>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name="node:type">
-    <xsl:param name="node" select="."/>
-
-    <xsl:choose>
-      <xsl:when test="not($node)"/>
-      <xsl:when test="$node[1]/self::*">
-	<xsl:text>element</xsl:text>
-      </xsl:when>
-      <xsl:when test="$node[1]/self::text()">
-	<xsl:text>text</xsl:text>
-      </xsl:when>
-      <xsl:when test="$node[1]/self::comment()">
-	<xsl:text>comment</xsl:text>
-      </xsl:when>
-      <xsl:when test="$node[1]/self::processing-instruction()">
-	<xsl:text>processing instruction</xsl:text>
-      </xsl:when>
-      <xsl:when test="not($node[1]/parent::*)">
-        <xsl:text>root</xsl:text>
-      </xsl:when>
-      <xsl:when test="count($node[1] | $node[1]/../namespace::*) = count($node[1]/../namespace::*)">
-        <xsl:text>namespace</xsl:text>
-      </xsl:when>
-      <xsl:when test="count($node[1] | $node[1]/../@*) = count($node[1]/../@*)">
-        <xsl:text>attribute</xsl:text>
-      </xsl:when>
-    </xsl:choose>
-  </xsl:template>
-
-  <doc:template name="node:copy" xmlns="">
-    <refpurpose>Copy Nodes</refpurpose>
-
-    <refdescription>
-      <para>Makes a copy of the given nodes, including attributes and descendants.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-	<varlistentry>
-	  <term>nodes</term>
-	  <listitem>
-	    <para>The nodes to copy.</para>
-	  </listitem>
-	</varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns the copied nodes as a result tree fragment.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name='node:copy'>
-    <xsl:param name='nodes' select='.'/>
-
-    <xsl:for-each select='$nodes'>
-      <xsl:copy>
-        <xsl:for-each select='@*'>
-          <xsl:copy/>
-        </xsl:for-each>
-
-        <xsl:for-each select='node()'>
-          <xsl:call-template name='node:copy'/>
-        </xsl:for-each>
-      </xsl:copy>
-    </xsl:for-each>
-  </xsl:template>
-</xsl:stylesheet>
-
diff --git a/tclxml-3.2/doc/xsltsl/stdlib.xsl b/tclxml-3.2/doc/xsltsl/stdlib.xsl
deleted file mode 100644
index 114a88c..0000000
--- a/tclxml-3.2/doc/xsltsl/stdlib.xsl
+++ /dev/null
@@ -1,340 +0,0 @@
-<?xml version="1.0"?>
-<!DOCTYPE xsl:stylesheet [
-  <!ENTITY version "1.2.1">
-]>
-
-<xsl:stylesheet
-  xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
-  xmlns:doc="http://xsltsl.org/xsl/documentation/1.0"
-  exclude-result-prefixes="doc"
-  version="1.0">
-
-  <xsl:import href="string.xsl"/>
-  <xsl:import href="date-time.xsl"/>
-  <xsl:import href="node.xsl"/>
-  <xsl:import href="uri.xsl"/>
-  <xsl:import href="markup.xsl"/>
-  <xsl:import href="math.xsl"/>
-  <xsl:import href="cmp.xsl"/>
-
-  <xsl:import href="svg.xsl"/>
-<!--
-  <xsl:import href="html/html.xsl"/>
-  <xsl:import href="fo/fo.xsl"/>
--->
-
-  <!-- For a new module, add an import element here -->
-  <xsl:import href="example.xsl"/>
-
-  <doc:book xmlns="">
-    <bookinfo>
-      <title>XSLT Standard Library</title>
-      <subtitle>Version &version;</subtitle>
-      <!-- $Id: stdlib.xsl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $ -->
-
-      <author>
-        <surname>Ball</surname>
-        <firstname>Steve</firstname>
-      </author>
-      <copyright>
-        <year>2004</year>
-        <year>2002</year>
-        <holder>Steve Ball</holder>
-      </copyright>
-    </bookinfo>
-
-    <preface>
-      <para>The <ulink url="http://www.w3.org/Style/XSL">XSLT</ulink> Standard Library, <acronym>xsltsl</acronym>, provides the XSLT developer with a set of XSLT templates for commonly used functions.  These are implemented purely in XSLT, that is they do not use any extensions.</para>
-      <para><acronym>xsltsl</acronym> is a <ulink url="http://sourceforge.net/projects/xsltsl/">SourceForge project</ulink>.</para>
-      <para><ulink url="http://sourceforge.net/"><inlinemediaobject>
-	  <imageobject>
-	    <imagedata fileref="sflogo.gif" width="88" height="31"/>
-	  </imageobject>
-	  <textobject>
-	    <phrase>SourceForge Logo</phrase>
-	  </textobject>
-	</inlinemediaobject></ulink></para>
-      <para>Goals of the <acronym>xsltsl</acronym> project include:</para>
-      <itemizedlist>
-        <listitem>
-          <para>Provision of a high-quality library of XSLT templates, suitable for inclusion by vendors in XSLT processor software products.</para>
-        </listitem>
-        <listitem>
-          <para>Demonstration of best practice in XSLT stylesheet development and documentation.</para>
-        </listitem>
-        <listitem>
-          <para>Provide examples of various techniques used to develop XSLT stylesheets (ie. a working FAQ).</para>
-        </listitem>
-      </itemizedlist>
-    </preface>
-
-    <chapter>
-      <title>Using The Library</title>
-
-      <para>There are two ways of using the library:</para>
-      <itemizedlist>
-	<listitem>
-	  <para>Use a local copy of the library.</para>
-	  <orderedlist>
-	    <listitem>
-	      <para>Download the distribution (see below).</para>
-	    </listitem>
-	    <listitem>
-	      <para>Unpack the distribution, using either gunzip/tar or unzip.</para>
-	    </listitem>
-	    <listitem>
-	      <para>In your stylesheet import or include either the main stylesheet, <filename>stdlib.xsl</filename>, or the stylesheet module you wish to use, such as <filename>string.xsl</filename>.  This example assumes that the distribution has been extracted into the same directory as your own stylesheet:</para>
-	      <informalexample>
-		<programlisting><![CDATA[
-<xsl:import href="stdlib.xsl"/>
-]]></programlisting>
-	      </informalexample>
-	    </listitem>
-	  </orderedlist>
-	</listitem>
-	<listitem>
-          <para>Import or include either the main stylesheet, or the stylesheet module you wish to use, directly from the library website; http://xsltsl.sourceforge.net/modules/.  The <filename>modules</filename> directory always contains the latest stable release.  For example:</para>
-	  <informalexample>
-	    <programlisting><![CDATA[
-<xsl:import href="http://xsltsl.sourceforge.net/modules/stdlib.xsl"/>
-]]></programlisting>
-	  </informalexample>
-          <para>Older versions of the library are available in subdirectories.  For example, to access version 1.1 of the library use:</para>
-	  <informalexample>
-	    <programlisting><![CDATA[
-<xsl:import href="http://xsltsl.sourceforge.net/modules/1.1/stdlib.xsl"/>
-]]></programlisting>
-	  </informalexample>
-	</listitem>
-      </itemizedlist>
-      <para>Next, add XML Namespace declarations for the modules you wish to use.  For example, to use templates from the string module, your stylesheet should have the following declaration:</para>
-      <informalexample>
-	<programlisting><![CDATA[
-<xsl:stylesheet version="1.0"
-	xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
-	xmlns:str="http://xsltsl.org/string">
-
-<xsl:import href="http://xsltsl.sourceforge.net/modules/stdlib.xsl"/>
-]]></programlisting>
-      </informalexample>
-      <para>Finally, use a template with the <sgmltag>call-template</sgmltag> element.  Most templates require parameters, which are passed using the <sgmltag>with-param</sgmltag> element.  For example:</para>
-      <informalexample>
-	<programlisting><![CDATA[
-<xsl:template match="foo">
-  <xsl:call-template name="str:subst">
-    <xsl:with-param name="text" select="."/>
-    <xsl:with-param name="replace">a word</xsl:with-param>
-    <xsl:with-param name="with">another word</xsl:with-param>
-  </xsl:call-template>
-</xsl:template>
-]]></programlisting>
-      </informalexample>
-    </chapter>
-
-    <chapter>
-      <title>Obtaining The Library</title>
-
-      <para>The XSLT Standard Library is available for download as either:</para>
-      <itemizedlist>
-	<listitem>
-	  <para>Gzip'd tarball: <ulink url="http://prdownloads.sourceforge.net/xsltsl/xsltsl-&version;.tar.gz">http://prdownloads.sourceforge.net/xsltsl/xsltsl-&version;.tar.gz</ulink></para>
-	</listitem>
-	<listitem>
-	  <para>Zip file: <ulink url="http://prdownloads.sourceforge.net/xsltsl/xsltsl-&version;.zip">http://prdownloads.sourceforge.net/xsltsl/xsltsl-&version;.zip</ulink></para>
-	</listitem>
-      </itemizedlist>
-    </chapter>
-
-    <chapter>
-      <title>Getting Involved</title>
-
-      <para>Contributions to the project are most welcome, and may be in the form of stylesheet modules, patches, bug reports or sample code.  Any contributed code must use the LGPL license to be accepted into the library.</para>
-
-      <para>See the SourceForge Project Page <ulink url="http://sourceforge.net/projects/xsltsl/">http://sourceforge.net/projects/xsltsl/</ulink> for information on the development of the project.  Bug reports may be submitted here.</para>
-
-      <para>See the project Web Page <ulink url="http://xsltsl.sourceforge.net/">http://xsltsl.sourceforge.net/</ulink> for documentation.</para>
-
-      <para>There are three mailing lists for the project:</para>
-      <variablelist>
-	<varlistentry>
-	  <term><email>xsltsl-users at lists.sourceforge.net</email></term>
-	  <listitem>
-	    <para>Discussion of the use of <acronym>xsltsl</acronym>.</para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term><email>xsltsl-devel at lists.sourceforge.net</email></term>
-	  <listitem>
-	    <para>Discussion of the development of <acronym>xsltsl</acronym>.</para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term><email>xsltsl-announce at lists.sourceforge.net</email></term>
-	  <listitem>
-	    <para>Project announcements.</para>
-	  </listitem>
-	</varlistentry>
-      </variablelist>
-    </chapter>
-
-    <chapter>
-      <title>XML Namespaces</title>
-
-      <para>Apart from the XSLT XML Namespace (http://www.w3.org/1999/XSL/Transform), <acronym>xsltsl</acronym> employs a number of XML Namespaces to allow inclusion of the library in developer stylesheets.  In addition, documentation is defined in a separate namespace.</para>
-      <para>Each module is allocated a namespace URI by appending the module name to the URI for the project, http://xsltsl.org/.  For example, the string module has the namespace URI http://xsltsl.org/string.</para>
-      <para>All documentation is written using an <ulink url="docbook-extensions.html">extension</ulink> of <ulink url="http://www.docbook.org/">DocBook</ulink> designed for <ulink url="docbook-extensions.html">embedding DocBook into XSLT stylesheets</ulink>.  The namespace URI for DocBook embedded in stylesheets is http://xsltsl.org/xsl/documentation/1.0</para>
-    </chapter>
-
-    <chapter>
-      <title>Engineering Standards</title>
-
-      <para>In order to maintain a high engineering standard, all modules and contributions to the <acronym>xsltsl</acronym> project must adhere to the following coding and documentation standards.  Submissions which do not meet (or exceed) this standard will not be accepted.</para>
-      <itemizedlist>
-        <listitem>
-          <para>All stylesheets must be indented, with each level indented by two spaces.  NB. a simple stylesheet could be used to enforce/fix this.</para>
-        </listitem>
-        <listitem>
-          <para>Templates are named using a qualified name (QName).  The namespace URI for the template's containing stylesheet is assigned as above.</para>
-        </listitem>
-        <listitem>
-          <para>Parameters for templates should use sensible names.  Where possible (or if in doubt), follow these conventions:</para>
-          <itemizedlist>
-            <listitem>
-              <para>A parameter containing a single node is named <parametername>node</parametername>.  Where more than one parameter contains a single node, the suffix <parametername>Node</parametername> is appended to the parameter name, eg. <parametername>referenceNode</parametername></para>
-            </listitem>
-            <listitem>
-              <para>A parameter which potentially contains multiple nodes is named <parametername>nodes</parametername>.  Where more than one parameter potentially contains multiple nodes, the suffix <parametername>Nodes</parametername> is appended to the parameter name, eg. <parametername>copyNodes</parametername></para>
-            </listitem>
-            <listitem>
-              <para>A parameter which contains a string value is named <parametername>text</parametername>.</para>
-            </listitem>
-          </itemizedlist>
-        </listitem>
-        <listitem>
-          <para>All templates in each stylesheet must be documented.  A template is documented as a <ulink url="http://www.docbook.org/">DocBook</ulink> RefEntry.</para>
-        </listitem>
-        <listitem>
-          <para>Every stylesheet must include a test suite.  The test system is in the <filename>test</filename> subdirectory.  See <ulink url="test/test.html">test/test.html</ulink> for further details.</para>
-        </listitem>
-      </itemizedlist>
-
-      <para>An <ulink url="example.xsl">example stylesheet</ulink> has been provided, which acts as a template for new stylesheet modules.</para>
-
-    </chapter>
-
-    <chapter>
-      <title>Related Work</title>
-
-      <para>The <ulink url="http://www.exslt.org/">EXSLT</ulink> project is creating a library to standardise extension functions.  The XSLT Standard Library is complementary to the EXSLT project.</para>
-
-    </chapter>
-
-    <chapter>
-      <title>Reference Documentation</title>
-
-      <para>Reference documentation is available for each module.</para>
-
-      <section>
-        <title>String Processing</title>
-
-        <itemizedlist>
-          <listitem>
-            <para><ulink url="string.html">string.xsl</ulink></para>
-          </listitem>
-        </itemizedlist>
-      </section>
-
-      <section>
-        <title>Nodes</title>
-
-        <itemizedlist>
-          <listitem>
-            <para><ulink url="node.html">node.xsl</ulink></para>
-          </listitem>
-        </itemizedlist>
-      </section>
-
-      <section>
-        <title>Date/Time Processing</title>
-
-        <itemizedlist>
-          <listitem>
-            <para><ulink url="date-time.html">date-time.xsl</ulink></para>
-          </listitem>
-        </itemizedlist>
-      </section>
-
-      <section>
-        <title>Mathematics</title>
-
-        <itemizedlist>
-          <listitem>
-            <para><ulink url="math.html">math.xsl</ulink></para>
-          </listitem>
-        </itemizedlist>
-      </section>
-
-      <section>
-        <title>URI (Uniform Resource Identifier) Processing</title>
-
-        <itemizedlist>
-          <listitem>
-            <para><ulink url="uri.html">uri.xsl</ulink></para>
-          </listitem>
-        </itemizedlist>
-      </section>
-
-      <section>
-        <title>Comparing Nodesets</title>
-
-        <itemizedlist>
-          <listitem>
-            <para><ulink url="cmp.html">cmp.xsl</ulink></para>
-          </listitem>
-        </itemizedlist>
-      </section>
-
-      <section>
-        <title>Generating XML Markup</title>
-
-        <itemizedlist>
-          <listitem>
-            <para><ulink url="markup.html">markup.xsl</ulink></para>
-          </listitem>
-        </itemizedlist>
-      </section>
-
-      <section>
-        <title>Presentation Media Support</title>
-
-        <itemizedlist>
-          <listitem>
-            <para>Scalable Vector Graphics: <ulink url="svg.html">svg.xsl</ulink></para>
-          </listitem>
-<!--
-          <listitem>
-            <para><ulink url="html/html.html">html/html.xsl</ulink></para>
-          </listitem>
-          <listitem>
-            <para><ulink url="fo/fo.html">fo/fo.xsl</ulink></para>
-          </listitem>
--->
-        </itemizedlist>
-      </section>
-
-      <section>
-        <title>Example</title>
-
-        <!-- Add a new module in a similar fashion -->
-
-        <itemizedlist>
-          <listitem>
-            <para><ulink url="example.html">example.xsl</ulink></para>
-          </listitem>
-        </itemizedlist>
-      </section>
-    </chapter>
-
-  </doc:book>
-
-</xsl:stylesheet>
diff --git a/tclxml-3.2/doc/xsltsl/string.xsl b/tclxml-3.2/doc/xsltsl/string.xsl
deleted file mode 100644
index c589122..0000000
--- a/tclxml-3.2/doc/xsltsl/string.xsl
+++ /dev/null
@@ -1,1304 +0,0 @@
-<?xml version="1.0"?>
-
-<xsl:stylesheet version="1.0"
-	xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
-	xmlns:doc="http://xsltsl.org/xsl/documentation/1.0"
-	xmlns:str="http://xsltsl.org/string"
-	extension-element-prefixes="doc str">
-
-  <doc:reference xmlns="">
-    <referenceinfo>
-      <releaseinfo role="meta">
-	$Id: string.xsl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-      </releaseinfo>
-      <author>
-	<surname>Ball</surname>
-	<firstname>Steve</firstname>
-      </author>
-      <copyright>
-	<year>2002</year>
-	<year>2001</year>
-	<holder>Steve Ball</holder>
-      </copyright>
-    </referenceinfo>
-
-    <title>String Processing</title>
-
-    <partintro>
-      <section>
-	<title>Introduction</title>
-
-	<para>This module provides templates for manipulating strings.</para>
-
-      </section>
-    </partintro>
-
-  </doc:reference>
-
-  <!-- Common string constants and datasets as XSL variables -->
-
-  <!-- str:lower and str:upper contain pairs of lower and upper case
-       characters. Below insanely long strings should contain the
-       official lower/uppercase pairs, making this stylesheet working
-       for every language on earth. Hopefully. -->
-  <!-- These values are not enough, however. There are some
-       exceptions, dealt with below. -->
-  <xsl:variable name="xsltsl-str-lower" select="'&#x0061;&#x0062;&#x0063;&#x0064;&#x0065;&#x0066;&#x0067;&#x0068;&#x0069;&#x006A;&#x006B;&#x006C;&#x006D;&#x006E;&#x006F;&#x0070;&#x0071;&#x0072;&#x0073;&#x0074;&#x0075;&#x0076;&#x0077;&#x0078;&#x0079;&#x007A;&#x00B5;&#x00E0;&#x00E1;&#x00E2;&#x00E3;&#x00E4;&#x00E5;&#x00E6;&#x00E7;&#x00E8;&#x00E9;&#x00EA;&#x00EB;&#x00EC;&#x00ED;&#x00EE;&#x00EF;&#x00F0;&#x00F1;&#x00F2;&#x00F3;&#x00F4;&#x00F5;&#x00F6;&#x00F8;&#x00F9;&#x00FA;&#x00FB;&#x00FC;&#x00FD;&#x00FE;&#x00FF;&#x0101;&#x0103;&#x0105;&#x0107;&#x0109;&#x010B;&#x010D;&#x010F;&#x0111;&#x0113;&#x0115;&#x0117;&#x0119;&#x011B;&#x011D;&#x011F;&#x0121;&#x0123;&#x0125;&#x0127;&#x0129;&#x012B;&#x012D;&#x012F;&#x0131;&#x0133;&#x0135;&#x0137;&#x013A;&#x013C;&#x013E;&#x0140;&#x0142;&#x0144;&#x0146;&#x0148;&#x014B;&#x014D;&#x014F;&#x0151;&#x0153;&#x0155;&#x0157;&#x0159;&#x015B;&#x015D;&#x015F;&#x0161;&#x0163;&#x0165;&#x0167;&#x0169;&#x016B;&#x016D;&#x016F;&#x0171;&#x0173;&#x0175;&#x0177;&#x017A;&#x017C;&#x017E;&#x017F;&#x0183;&#x0185;&#x0188;&#x018C;&#x0192;&#x0195;&#x0199;&#x01A1;&#x01A3;&#x01A5;&#x01A8;&#x01AD;&#x01B0;&#x01B4;&#x01B6;&#x01B9;&#x01BD;&#x01BF;&#x01C5;&#x01C6;&#x01C8;&#x01C9;&#x01CB;&#x01CC;&#x01CE;&#x01D0;&#x01D2;&#x01D4;&#x01D6;&#x01D8;&#x01DA;&#x01DC;&#x01DD;&#x01DF;&#x01E1;&#x01E3;&#x01E5;&#x01E7;&#x01E9;&#x01EB;&#x01ED;&#x01EF;&#x01F2;&#x01F3;&#x01F5;&#x01F9;&#x01FB;&#x01FD;&#x01FF;&#x0201;&#x0203;&#x0205;&#x0207;&#x0209;&#x020B;&#x020D;&#x020F;&#x0211;&#x0213;&#x0215;&#x0217;&#x0219;&#x021B;&#x021D;&#x021F;&#x0223;&#x0225;&#x0227;&#x0229;&#x022B;&#x022D;&#x022F;&#x0231;&#x0233;&#x0253;&#x0254;&#x0256;&#x0257;&#x0259;&#x025B;&#x0260;&#x0263;&#x0268;&#x0269;&#x026F;&#x0272;&#x0275;&#x0280;&#x0283;&#x0288;&#x028A;&#x028B;&#x0292;&#x0345;&#x03AC;&#x03AD;&#x03AE;&#x03AF;&#x03B1;&#x03B2;&#x03B3;&#x03B4;&#x03B5;&#x03B6;&#x03B7;&#x03B8;&#x03B9;&#x03BA;&#x03BB;&#x03BC;&#x03BD;&#x03BE;&#x03BF;&#x03C0;&#x03C1;&#x03C2;&#x03C3;&#x03C4;&#x03C5;&#x03C6;&#x03C7;&#x03C8;&#x03C9;&#x03CA;&#x03CB;&#x03CC;&#x03CD;&#x03CE;&#x03D0;&#x03D1;&#x03D5;&#x03D6;&#x03DB;&#x03DD;&#x03DF;&#x03E1;&#x03E3;&#x03E5;&#x03E7;&#x03E9;&#x03EB;&#x03ED;&#x03EF;&#x03F0;&#x03F1;&#x03F2;&#x03F5;&#x0430;&#x0431;&#x0432;&#x0433;&#x0434;&#x0435;&#x0436;&#x0437;&#x0438;&#x0439;&#x043A;&#x043B;&#x043C;&#x043D;&#x043E;&#x043F;&#x0440;&#x0441;&#x0442;&#x0443;&#x0444;&#x0445;&#x0446;&#x0447;&#x0448;&#x0449;&#x044A;&#x044B;&#x044C;&#x044D;&#x044E;&#x044F;&#x0450;&#x0451;&#x0452;&#x0453;&#x0454;&#x0455;&#x0456;&#x0457;&#x0458;&#x0459;&#x045A;&#x045B;&#x045C;&#x045D;&#x045E;&#x045F;&#x0461;&#x0463;&#x0465;&#x0467;&#x0469;&#x046B;&#x046D;&#x046F;&#x0471;&#x0473;&#x0475;&#x0477;&#x0479;&#x047B;&#x047D;&#x047F;&#x0481;&#x048D;&#x048F;&#x0491;&#x0493;&#x0495;&#x0497;&#x0499;&#x049B;&#x049D;&#x049F;&#x04A1;&#x04A3;&#x04A5;&#x04A7;&#x04A9;&#x04AB;&#x04AD;&#x04AF;&#x04B1;&#x04B3;&#x04B5;&#x04B7;&#x04B9;&#x04BB;&#x04BD;&#x04BF;&#x04C2;&#x04C4;&#x04C8;&#x04CC;&#x04D1;&#x04D3;&#x04D5;&#x04D7;&#x04D9;&#x04DB;&#x04DD;&#x04DF;&#x04E1;&#x04E3;&#x04E5;&#x04E7;&#x04E9;&#x04EB;&#x04ED;&#x04EF;&#x04F1;&#x04F3;&#x04F5;&#x04F9;&#x0561;&#x0562;&#x0563;&#x0564;&#x0565;&#x0566;&#x0567;&#x0568;&#x0569;&#x056A;&#x056B;&#x056C;&#x056D;&#x056E;&#x056F;&#x0570;&#x0571;&#x0572;&#x0573;&#x0574;&#x0575;&#x0576;&#x0577;&#x0578;&#x0579;&#x057A;&#x057B;&#x057C;&#x057D;&#x057E;&#x057F;&#x0580;&#x0581;&#x0582;&#x0583;&#x0584;&#x0585;&#x0586;&#x1E01;&#x1E03;&#x1E05;&#x1E07;&#x1E09;&#x1E0B;&#x1E0D;&#x1E0F;&#x1E11;&#x1E13;&#x1E15;&#x1E17;&#x1E19;&#x1E1B;&#x1E1D;&#x1E1F;&#x1E21;&#x1E23;&#x1E25;&#x1E27;&#x1E29;&#x1E2B;&#x1E2D;&#x1E2F;&#x1E31;&#x1E33;&#x1E35;&#x1E37;&#x1E39;&#x1E3B;&#x1E3D;&#x1E3F;&#x1E41;&#x1E43;&#x1E45;&#x1E47;&#x1E49;&#x1E4B;&#x1E4D;&#x1E4F;&#x1E51;&#x1E53;&#x1E55;&#x1E57;&#x1E59;&#x1E5B;&#x1E5D;&#x1E5F;&#x1E61;&#x1E63;&#x1E65;&#x1E67;&#x1E69;&#x1E6B;&#x1E6D;&#x1E6F;&#x1E71;&#x1E73;&#x1E75;&#x1E77;&#x1E79;&#x1E7B;&#x1E7D;&#x1E7F;&#x1E81;&#x1E83;&#x1E85;&#x1E87;&#x1E89;&#x1E8B;&#x1E8D;&#x1E8F;&#x1E91;&#x1E93;&#x1E95;&#x1E9B;&#x1EA1;&#x1EA3;&#x1EA5;&#x1EA7;&#x1EA9;&#x1EAB;&#x1EAD;&#x1EAF;&#x1EB1;&#x1EB3;&#x1EB5;&#x1EB7;&#x1EB9;&#x1EBB;&#x1EBD;&#x1EBF;&#x1EC1;&#x1EC3;&#x1EC5;&#x1EC7;&#x1EC9;&#x1ECB;&#x1ECD;&#x1ECF;&#x1ED1;&#x1ED3;&#x1ED5;&#x1ED7;&#x1ED9;&#x1EDB;&#x1EDD;&#x1EDF;&#x1EE1;&#x1EE3;&#x1EE5;&#x1EE7;&#x1EE9;&#x1EEB;&#x1EED;&#x1EEF;&#x1EF1;&#x1EF3;&#x1EF5;&#x1EF7;&#x1EF9;&#x1F00;&#x1F01;&#x1F02;&#x1F03;&#x1F04;&#x1F05;&#x1F06;&#x1F07;&#x1F10;&#x1F11;&#x1F12;&#x1F13;&#x1F14;&#x1F15;&#x1F20;&#x1F21;&#x1F22;&#x1F23;&#x1F24;&#x1F25;&#x1F26;&#x1F27;&#x1F30;&#x1F31;&#x1F32;&#x1F33;&#x1F34;&#x1F35;&#x1F36;&#x1F37;&#x1F40;&#x1F41;&#x1F42;&#x1F43;&#x1F44;&#x1F45;&#x1F51;&#x1F53;&#x1F55;&#x1F57;&#x1F60;&#x1F61;&#x1F62;&#x1F63;&#x1F64;&#x1F65;&#x1F66;&#x1F67;&#x1F70;&#x1F71;&#x1F72;&#x1F73;&#x1F74;&#x1F75;&#x1F76;&#x1F77;&#x1F78;&#x1F79;&#x1F7A;&#x1F7B;&#x1F7C;&#x1F7D;&#x1F80;&#x1F81;&#x1F82;&#x1F83;&#x1F84;&#x1F85;&#x1F86;&#x1F87;&#x1F90;&#x1F91;&#x1F92;&#x1F93;&#x1F94;&#x1F95;&#x1F96;&#x1F97;&#x1FA0;&#x1FA1;&#x1FA2;&#x1FA3;&#x1FA4;&#x1FA5;&#x1FA6;&#x1FA7;&#x1FB0;&#x1FB1;&#x1FB3;&#x1FBE;&#x1FC3;&#x1FD0;&#x1FD1;&#x1FE0;&#x1FE1;&#x1FE5;&#x1FF3;&#x2170;&#x2171;&#x2172;&#x2173;&#x2174;&#x2175;&#x2176;&#x2177;&#x2178;&#x2179;&#x217A;&#x217B;&#x217C;&#x217D;&#x217E;&#x217F;&#x24D0;&#x24D1;&#x24D2;&#x24D3;&#x24D4;&#x24D5;&#x24D6;&#x24D7;&#x24D8;&#x24D9;&#x24DA;&#x24DB;&#x24DC;&#x24DD;&#x24DE;&#x24DF;&#x24E0;&#x24E1;&#x24E2;&#x24E3;&#x24E4;&#x24E5;&#x24E6;&#x24E7;&#x24E8;&#x24E9;&#xFF41;&#xFF42;&#xFF43;&#xFF44;&#xFF45;&#xFF46;&#xFF47;&#xFF48;&#xFF49;&#xFF4A;&#xFF4B;&#xFF4C;&#xFF4D;&#xFF4E;&#xFF4F;&#xFF50;&#xFF51;&#xFF52;&#xFF53;&#xFF54;&#xFF55;&#xFF56;&#xFF57;&#xFF58;&#xFF59;&#xFF5A;&#x10428;&#x10429;&#x1042A;&#x1042B;&#x1042C;&#x1042D;&#x1042E;&#x1042F;&#x10430;&#x10431;&#x10432;&#x10433;&#x10434;&#x10435;&#x10436;&#x10437;&#x10438;&#x10439;&#x1043A;&#x1043B;&#x1043C;&#x1043D;&#x1043E;&#x1043F;&#x10440;&#x10441;&#x10442;&#x10443;&#x10444;&#x10445;&#x10446;&#x10447;&#x10448;&#x10449;&#x1044A;&#x1044B;&#x1044C;&#x1044D;'"/>
-  <xsl:variable name="xsltsl-str-upper" select="'&#x0041;&#x0042;&#x0043;&#x0044;&#x0045;&#x0046;&#x0047;&#x0048;&#x0049;&#x004A;&#x004B;&#x004C;&#x004D;&#x004E;&#x004F;&#x0050;&#x0051;&#x0052;&#x0053;&#x0054;&#x0055;&#x0056;&#x0057;&#x0058;&#x0059;&#x005A;&#x039C;&#x00C0;&#x00C1;&#x00C2;&#x00C3;&#x00C4;&#x00C5;&#x00C6;&#x00C7;&#x00C8;&#x00C9;&#x00CA;&#x00CB;&#x00CC;&#x00CD;&#x00CE;&#x00CF;&#x00D0;&#x00D1;&#x00D2;&#x00D3;&#x00D4;&#x00D5;&#x00D6;&#x00D8;&#x00D9;&#x00DA;&#x00DB;&#x00DC;&#x00DD;&#x00DE;&#x0178;&#x0100;&#x0102;&#x0104;&#x0106;&#x0108;&#x010A;&#x010C;&#x010E;&#x0110;&#x0112;&#x0114;&#x0116;&#x0118;&#x011A;&#x011C;&#x011E;&#x0120;&#x0122;&#x0124;&#x0126;&#x0128;&#x012A;&#x012C;&#x012E;&#x0049;&#x0132;&#x0134;&#x0136;&#x0139;&#x013B;&#x013D;&#x013F;&#x0141;&#x0143;&#x0145;&#x0147;&#x014A;&#x014C;&#x014E;&#x0150;&#x0152;&#x0154;&#x0156;&#x0158;&#x015A;&#x015C;&#x015E;&#x0160;&#x0162;&#x0164;&#x0166;&#x0168;&#x016A;&#x016C;&#x016E;&#x0170;&#x0172;&#x0174;&#x0176;&#x0179;&#x017B;&#x017D;&#x0053;&#x0182;&#x0184;&#x0187;&#x018B;&#x0191;&#x01F6;&#x0198;&#x01A0;&#x01A2;&#x01A4;&#x01A7;&#x01AC;&#x01AF;&#x01B3;&#x01B5;&#x01B8;&#x01BC;&#x01F7;&#x01C4;&#x01C4;&#x01C7;&#x01C7;&#x01CA;&#x01CA;&#x01CD;&#x01CF;&#x01D1;&#x01D3;&#x01D5;&#x01D7;&#x01D9;&#x01DB;&#x018E;&#x01DE;&#x01E0;&#x01E2;&#x01E4;&#x01E6;&#x01E8;&#x01EA;&#x01EC;&#x01EE;&#x01F1;&#x01F1;&#x01F4;&#x01F8;&#x01FA;&#x01FC;&#x01FE;&#x0200;&#x0202;&#x0204;&#x0206;&#x0208;&#x020A;&#x020C;&#x020E;&#x0210;&#x0212;&#x0214;&#x0216;&#x0218;&#x021A;&#x021C;&#x021E;&#x0222;&#x0224;&#x0226;&#x0228;&#x022A;&#x022C;&#x022E;&#x0230;&#x0232;&#x0181;&#x0186;&#x0189;&#x018A;&#x018F;&#x0190;&#x0193;&#x0194;&#x0197;&#x0196;&#x019C;&#x019D;&#x019F;&#x01A6;&#x01A9;&#x01AE;&#x01B1;&#x01B2;&#x01B7;&#x0399;&#x0386;&#x0388;&#x0389;&#x038A;&#x0391;&#x0392;&#x0393;&#x0394;&#x0395;&#x0396;&#x0397;&#x0398;&#x0399;&#x039A;&#x039B;&#x039C;&#x039D;&#x039E;&#x039F;&#x03A0;&#x03A1;&#x03A3;&#x03A3;&#x03A4;&#x03A5;&#x03A6;&#x03A7;&#x03A8;&#x03A9;&#x03AA;&#x03AB;&#x038C;&#x038E;&#x038F;&#x0392;&#x0398;&#x03A6;&#x03A0;&#x03DA;&#x03DC;&#x03DE;&#x03E0;&#x03E2;&#x03E4;&#x03E6;&#x03E8;&#x03EA;&#x03EC;&#x03EE;&#x039A;&#x03A1;&#x03A3;&#x0395;&#x0410;&#x0411;&#x0412;&#x0413;&#x0414;&#x0415;&#x0416;&#x0417;&#x0418;&#x0419;&#x041A;&#x041B;&#x041C;&#x041D;&#x041E;&#x041F;&#x0420;&#x0421;&#x0422;&#x0423;&#x0424;&#x0425;&#x0426;&#x0427;&#x0428;&#x0429;&#x042A;&#x042B;&#x042C;&#x042D;&#x042E;&#x042F;&#x0400;&#x0401;&#x0402;&#x0403;&#x0404;&#x0405;&#x0406;&#x0407;&#x0408;&#x0409;&#x040A;&#x040B;&#x040C;&#x040D;&#x040E;&#x040F;&#x0460;&#x0462;&#x0464;&#x0466;&#x0468;&#x046A;&#x046C;&#x046E;&#x0470;&#x0472;&#x0474;&#x0476;&#x0478;&#x047A;&#x047C;&#x047E;&#x0480;&#x048C;&#x048E;&#x0490;&#x0492;&#x0494;&#x0496;&#x0498;&#x049A;&#x049C;&#x049E;&#x04A0;&#x04A2;&#x04A4;&#x04A6;&#x04A8;&#x04AA;&#x04AC;&#x04AE;&#x04B0;&#x04B2;&#x04B4;&#x04B6;&#x04B8;&#x04BA;&#x04BC;&#x04BE;&#x04C1;&#x04C3;&#x04C7;&#x04CB;&#x04D0;&#x04D2;&#x04D4;&#x04D6;&#x04D8;&#x04DA;&#x04DC;&#x04DE;&#x04E0;&#x04E2;&#x04E4;&#x04E6;&#x04E8;&#x04EA;&#x04EC;&#x04EE;&#x04F0;&#x04F2;&#x04F4;&#x04F8;&#x0531;&#x0532;&#x0533;&#x0534;&#x0535;&#x0536;&#x0537;&#x0538;&#x0539;&#x053A;&#x053B;&#x053C;&#x053D;&#x053E;&#x053F;&#x0540;&#x0541;&#x0542;&#x0543;&#x0544;&#x0545;&#x0546;&#x0547;&#x0548;&#x0549;&#x054A;&#x054B;&#x054C;&#x054D;&#x054E;&#x054F;&#x0550;&#x0551;&#x0552;&#x0553;&#x0554;&#x0555;&#x0556;&#x1E00;&#x1E02;&#x1E04;&#x1E06;&#x1E08;&#x1E0A;&#x1E0C;&#x1E0E;&#x1E10;&#x1E12;&#x1E14;&#x1E16;&#x1E18;&#x1E1A;&#x1E1C;&#x1E1E;&#x1E20;&#x1E22;&#x1E24;&#x1E26;&#x1E28;&#x1E2A;&#x1E2C;&#x1E2E;&#x1E30;&#x1E32;&#x1E34;&#x1E36;&#x1E38;&#x1E3A;&#x1E3C;&#x1E3E;&#x1E40;&#x1E42;&#x1E44;&#x1E46;&#x1E48;&#x1E4A;&#x1E4C;&#x1E4E;&#x1E50;&#x1E52;&#x1E54;&#x1E56;&#x1E58;&#x1E5A;&#x1E5C;&#x1E5E;&#x1E60;&#x1E62;&#x1E64;&#x1E66;&#x1E68;&#x1E6A;&#x1E6C;&#x1E6E;&#x1E70;&#x1E72;&#x1E74;&#x1E76;&#x1E78;&#x1E7A;&#x1E7C;&#x1E7E;&#x1E80;&#x1E82;&#x1E84;&#x1E86;&#x1E88;&#x1E8A;&#x1E8C;&#x1E8E;&#x1E90;&#x1E92;&#x1E94;&#x1E60;&#x1EA0;&#x1EA2;&#x1EA4;&#x1EA6;&#x1EA8;&#x1EAA;&#x1EAC;&#x1EAE;&#x1EB0;&#x1EB2;&#x1EB4;&#x1EB6;&#x1EB8;&#x1EBA;&#x1EBC;&#x1EBE;&#x1EC0;&#x1EC2;&#x1EC4;&#x1EC6;&#x1EC8;&#x1ECA;&#x1ECC;&#x1ECE;&#x1ED0;&#x1ED2;&#x1ED4;&#x1ED6;&#x1ED8;&#x1EDA;&#x1EDC;&#x1EDE;&#x1EE0;&#x1EE2;&#x1EE4;&#x1EE6;&#x1EE8;&#x1EEA;&#x1EEC;&#x1EEE;&#x1EF0;&#x1EF2;&#x1EF4;&#x1EF6;&#x1EF8;&#x1F08;&#x1F09;&#x1F0A;&#x1F0B;&#x1F0C;&#x1F0D;&#x1F0E;&#x1F0F;&#x1F18;&#x1F19;&#x1F1A;&#x1F1B;&#x1F1C;&#x1F1D;&#x1F28;&#x1F29;&#x1F2A;&#x1F2B;&#x1F2C;&#x1F2D;&#x1F2E;&#x1F2F;&#x1F38;&#x1F39;&#x1F3A;&#x1F3B;&#x1F3C;&#x1F3D;&#x1F3E;&#x1F3F;&#x1F48;&#x1F49;&#x1F4A;&#x1F4B;&#x1F4C;&#x1F4D;&#x1F59;&#x1F5B;&#x1F5D;&#x1F5F;&#x1F68;&#x1F69;&#x1F6A;&#x1F6B;&#x1F6C;&#x1F6D;&#x1F6E;&#x1F6F;&#x1FBA;&#x1FBB;&#x1FC8;&#x1FC9;&#x1FCA;&#x1FCB;&#x1FDA;&#x1FDB;&#x1FF8;&#x1FF9;&#x1FEA;&#x1FEB;&#x1FFA;&#x1FFB;&#x1F88;&#x1F89;&#x1F8A;&#x1F8B;&#x1F8C;&#x1F8D;&#x1F8E;&#x1F8F;&#x1F98;&#x1F99;&#x1F9A;&#x1F9B;&#x1F9C;&#x1F9D;&#x1F9E;&#x1F9F;&#x1FA8;&#x1FA9;&#x1FAA;&#x1FAB;&#x1FAC;&#x1FAD;&#x1FAE;&#x1FAF;&#x1FB8;&#x1FB9;&#x1FBC;&#x0399;&#x1FCC;&#x1FD8;&#x1FD9;&#x1FE8;&#x1FE9;&#x1FEC;&#x1FFC;&#x2160;&#x2161;&#x2162;&#x2163;&#x2164;&#x2165;&#x2166;&#x2167;&#x2168;&#x2169;&#x216A;&#x216B;&#x216C;&#x216D;&#x216E;&#x216F;&#x24B6;&#x24B7;&#x24B8;&#x24B9;&#x24BA;&#x24BB;&#x24BC;&#x24BD;&#x24BE;&#x24BF;&#x24C0;&#x24C1;&#x24C2;&#x24C3;&#x24C4;&#x24C5;&#x24C6;&#x24C7;&#x24C8;&#x24C9;&#x24CA;&#x24CB;&#x24CC;&#x24CD;&#x24CE;&#x24CF;&#xFF21;&#xFF22;&#xFF23;&#xFF24;&#xFF25;&#xFF26;&#xFF27;&#xFF28;&#xFF29;&#xFF2A;&#xFF2B;&#xFF2C;&#xFF2D;&#xFF2E;&#xFF2F;&#xFF30;&#xFF31;&#xFF32;&#xFF33;&#xFF34;&#xFF35;&#xFF36;&#xFF37;&#xFF38;&#xFF39;&#xFF3A;&#x10400;&#x10401;&#x10402;&#x10403;&#x10404;&#x10405;&#x10406;&#x10407;&#x10408;&#x10409;&#x1040A;&#x1040B;&#x1040C;&#x1040D;&#x1040E;&#x1040F;&#x10410;&#x10411;&#x10412;&#x10413;&#x10414;&#x10415;&#x10416;&#x10417;&#x10418;&#x10419;&#x1041A;&#x1041B;&#x1041C;&#x1041D;&#x1041E;&#x1041F;&#x10420;&#x10421;&#x10422;&#x10423;&#x10424;&#x10425;'"/>
-  <xsl:variable name="xsltsl-str-digits" select="'0123456789'"/>
-  <!-- space (#x20) characters, carriage returns, line feeds, or tabs. -->
-  <xsl:variable name="xsltsl-str-ws" select="'&#x20;&#x9;&#xD;&#xA;'"/>
-
-  <doc:template name="str:to-upper" xmlns="">
-    <refpurpose>Make string uppercase</refpurpose>
-
-    <refdescription>
-      <para>Converts all lowercase letters to uppercase.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-	<varlistentry>
-	  <term>text</term>
-	  <listitem>
-	    <para>The string to be converted</para>
-	  </listitem>
-	</varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns string with all uppercase letters.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name="str:to-upper">
-    <xsl:param name="text"/>
-
-    <!-- Below exception is extracted from unicode's SpecialCasing.txt
-         file. It's the german lowercase "eszett" (the thing looking
-         like a greek beta) that's to become "SS" in uppercase (note:
-         that are *two* characters, that's why it doesn't fit in the
-         list of upper/lowercase characters). There are more
-         characters in that file (103, excluding the locale-specific
-         ones), but they seemed to be much less used to me and they
-         add up to a hellish long stylesheet.... - Reinout -->
-    <xsl:param name="modified-text">
-      <xsl:call-template name="str:subst">
-        <xsl:with-param name="text">
-          <xsl:value-of select="$text"/>
-        </xsl:with-param>
-        <xsl:with-param name="replace">
-          <xsl:text>&#x00DF;</xsl:text>
-        </xsl:with-param>
-        <xsl:with-param name="with">
-          <xsl:text>&#x0053;</xsl:text>
-          <xsl:text>&#x0053;</xsl:text>
-        </xsl:with-param>
-      </xsl:call-template>
-    </xsl:param>
-
-    <xsl:value-of select="translate($modified-text, $xsltsl-str-lower, $xsltsl-str-upper)"/>
-  </xsl:template>
-
-  <doc:template name="str:to-lower" xmlns="">
-    <refpurpose>Make string lowercase</refpurpose>
-
-    <refdescription>
-      <para>Converts all uppercase letters to lowercase.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-	<varlistentry>
-	  <term>text</term>
-	  <listitem>
-	    <para>The string to be converted</para>
-	  </listitem>
-	</varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns string with all lowercase letters.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name="str:to-lower">
-    <xsl:param name="text"/>
-
-    <xsl:value-of select="translate($text, $xsltsl-str-upper, $xsltsl-str-lower)"/>
-  </xsl:template>
-
-  <doc:template name="str:capitalise" xmlns="">
-    <refpurpose>Capitalise string</refpurpose>
-
-    <refdescription>
-      <para>Converts first character of string to an uppercase letter.  All remaining characters are converted to lowercase.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-	<varlistentry>
-	  <term>text</term>
-	  <listitem>
-	    <para>The string to be capitalised</para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>all</term>
-	  <listitem>
-	    <para>Boolean controlling whether all words in the string are capitalised.</para>
-	    <para>Default is true.</para>
-	  </listitem>
-	</varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns string with first character uppcase and all remaining characters lowercase.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name="str:capitalise">
-    <xsl:param name="text"/>
-    <xsl:param name="all" select="true()"/>
-
-    <xsl:choose>
-      <xsl:when test="$all and (contains($text, ' ') or contains($text, '	') or contains($text, '
'))">
-	<xsl:variable name="firstword">
-	  <xsl:call-template name="str:substring-before-first">
-	    <xsl:with-param name="text" select="$text"/>
-	    <xsl:with-param name="chars" select="$xsltsl-str-ws"/>
-	  </xsl:call-template>
-	</xsl:variable>
-	<xsl:call-template name="str:capitalise">
-	  <xsl:with-param name="text">
-	    <xsl:value-of select="$firstword"/>
-	  </xsl:with-param>
-	  <xsl:with-param name="all" select="false()"/>
-	</xsl:call-template>
-	<xsl:value-of select="substring($text, string-length($firstword) + 1, 1)"/>
-	<xsl:call-template name="str:capitalise">
-	  <xsl:with-param name="text">
-	    <xsl:value-of select="substring($text, string-length($firstword) + 2)"/>
-	  </xsl:with-param>
-	</xsl:call-template>
-      </xsl:when>
-
-      <xsl:otherwise>
-	<xsl:call-template name="str:to-upper">
-	  <xsl:with-param name="text" select="substring($text, 1, 1)"/>
-	</xsl:call-template>
-	<xsl:call-template name="str:to-lower">
-	  <xsl:with-param name="text" select="substring($text, 2)"/>
-	</xsl:call-template>
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:template>
-
-  <doc:template name="str:to-camelcase" xmlns="">
-    <refpurpose>Convert a string to one camelcase word</refpurpose>
-
-    <refdescription>
-      <para>Converts a string to one lowerCamelCase or UpperCamelCase
-      word, depending on the setting of the "upper"
-      parameter. UpperCamelCase is also called MixedCase while
-      lowerCamelCase is also called just camelCase. The template
-      removes any spaces, tabs and slashes, but doesn't deal with
-      other punctuation. It's purpose is to convert strings like
-      "hollow timber flush door" to a term suitable as identifier or
-      XML tag like "HollowTimberFlushDoor".
-      </para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-	<varlistentry>
-	  <term>text</term>
-	  <listitem>
-	    <para>The string to be capitalised</para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>upper</term>
-	  <listitem>
-	    <para>Boolean controlling whether the string becomes an
-            UpperCamelCase word or a lowerCamelCase word.</para>
-	    <para>Default is true.</para>
-	  </listitem>
-	</varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns string with first character uppcase and all remaining characters lowercase.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name="str:to-camelcase">
-    <xsl:param name="text"/>
-    <xsl:param name="upper" select="true()"/>
-    <!-- First change all 'strange' characters to spaces -->
-    <xsl:param name="string-with-only-spaces">
-      <xsl:value-of select="translate($text,concat($xsltsl-str-ws,'/'),'     ')"/>
-    </xsl:param>
-    <!-- Then process them -->
-    <xsl:param name="before-space-removal">
-      <xsl:variable name="firstword">
-        <xsl:call-template name="str:substring-before-first">
-          <xsl:with-param name="text" select="$string-with-only-spaces"/>
-          <xsl:with-param name="chars" select="$xsltsl-str-ws"/>
-        </xsl:call-template>
-      </xsl:variable>
-      <xsl:choose>
-        <xsl:when test="$upper">
-          <xsl:call-template name="str:to-upper">
-            <xsl:with-param name="text" select="substring($firstword, 1, 1)"/>
-          </xsl:call-template>
-          <xsl:call-template name="str:to-lower">
-            <xsl:with-param name="text" select="substring($firstword, 2)"/>
-          </xsl:call-template>
-        </xsl:when>
-        <xsl:otherwise>
-          <xsl:call-template name="str:to-lower">
-            <xsl:with-param name="text" select="$firstword"/>
-          </xsl:call-template>
-        </xsl:otherwise>
-      </xsl:choose>
-
-      <xsl:call-template name="str:capitalise">
-        <xsl:with-param name="text">
-          <xsl:value-of select="substring($string-with-only-spaces, string-length($firstword) + 2)"/>
-        </xsl:with-param>
-        <xsl:with-param name="all" select="true()"/>            
-      </xsl:call-template>
-    </xsl:param>
-    <xsl:value-of select="translate($before-space-removal,' ','')"/>
-  </xsl:template>
-
-  <doc:template name="str:substring-before-first" xmlns="">
-    <refpurpose>String extraction</refpurpose>
-
-    <refdescription>
-      <para>Extracts the portion of string 'text' which occurs before any of the characters in string 'chars'.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-	<varlistentry>
-	  <term>text</term>
-	  <listitem>
-	    <para>The string from which to extract a substring.</para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>chars</term>
-	  <listitem>
-	    <para>The string containing characters to find.</para>
-	  </listitem>
-	</varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns string.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name="str:substring-before-first">
-    <xsl:param name="text"/>
-    <xsl:param name="chars"/>
-
-    <xsl:choose>
-
-      <xsl:when test="string-length($text) = 0"/>
-
-      <xsl:when test="string-length($chars) = 0">
-	<xsl:value-of select="$text"/>
-      </xsl:when>
-
-      <xsl:when test="contains($text, substring($chars, 1, 1))">
-	<xsl:variable name="this" select="substring-before($text, substring($chars, 1, 1))"/>
-	<xsl:variable name="rest">
-	  <xsl:call-template name="str:substring-before-first">
-	    <xsl:with-param name="text" select="$text"/>
-	    <xsl:with-param name="chars" select="substring($chars, 2)"/>
-	  </xsl:call-template>
-	</xsl:variable>
-
-	<xsl:choose>
-	  <xsl:when test="string-length($this) < string-length($rest)">
-	    <xsl:value-of select="$this"/>
-	  </xsl:when>
-	  <xsl:otherwise>
-	    <xsl:value-of select="$rest"/>
-	  </xsl:otherwise>
-	</xsl:choose>
-      </xsl:when>
-
-      <xsl:otherwise>
-	<xsl:call-template name="str:substring-before-first">
-	  <xsl:with-param name="text" select="$text"/>
-	  <xsl:with-param name="chars" select="substring($chars, 2)"/>
-	</xsl:call-template>
-      </xsl:otherwise>
-
-    </xsl:choose>
-  </xsl:template>
-
-  <doc:template name="str:substring-after-last" xmlns="">
-    <refpurpose>String extraction</refpurpose>
-
-    <refdescription>
-      <para>Extracts the portion of string 'text' which occurs after the last of the character in string 'chars'.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-	<varlistentry>
-	  <term>text</term>
-	  <listitem>
-	    <para>The string from which to extract a substring.</para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>chars</term>
-	  <listitem>
-	    <para>The string containing characters to find.</para>
-	  </listitem>
-	</varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns string.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name="str:substring-after-last">
-    <xsl:param name="text"/>
-    <xsl:param name="chars"/>
-
-    <xsl:choose>
-      <xsl:when test='not($chars)'/>
-
-      <xsl:when test="contains($text, $chars)">
-        <xsl:variable name="last" select="substring-after($text, $chars)"/>
-
-	<xsl:choose>
-	  <xsl:when test="contains($last, $chars)">
-	    <xsl:call-template name="str:substring-after-last">
-	      <xsl:with-param name="text" select="$last"/>
-	      <xsl:with-param name="chars" select="$chars"/>
-	    </xsl:call-template>
-	  </xsl:when>
-	  <xsl:otherwise>
-	    <xsl:value-of select="$last"/>
-	  </xsl:otherwise>
-	</xsl:choose>
-      </xsl:when>
-
-      <xsl:otherwise>
-        <xsl:value-of select="$text"/>
-      </xsl:otherwise>
-
-    </xsl:choose>
-  </xsl:template>
-
-  <doc:template name="str:substring-after-last-character" xmlns="">
-    <refpurpose>String extraction</refpurpose>
-
-    <refdescription>
-      <para>Searches the string 'text' for the last occurrance of one of the characters listed in 'chars', then extracts the portion of string 'text' which follows that character's last occurrance.</para>
-
-      <para>Example: substring-after-last-character("abcdabcdabcd", "ac") returns "d".</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-	<varlistentry>
-	  <term>text</term>
-	  <listitem>
-	    <para>The string from which to extract a substring.</para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>chars</term>
-	  <listitem>
-	    <para>The characters to search for.</para>
-	  </listitem>
-	</varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns string.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name="str:substring-after-last-character">
-    <xsl:param name="text"/>
-    <xsl:param name="chars"/>
-    <xsl:param name='found' select='false()'/>
-
-    <xsl:choose>
-      <xsl:when test='not($chars) or not($text)'/>
-
-      <xsl:when test='string-length($chars) = 1 and
-                      contains($text, $chars)'>
-        <xsl:call-template name='str:substring-after-last'>
-          <xsl:with-param name='text' select='$text'/>
-          <xsl:with-param name='chars' select='$chars'/>
-        </xsl:call-template>
-      </xsl:when>
-      <xsl:when test='string-length($chars) = 1 and $found'>
-        <xsl:value-of select='$text'/>
-      </xsl:when>
-      <xsl:when test='string-length($chars) = 1'/>
-
-      <xsl:when test="contains($text, substring($chars, 1, 1))">
-        <xsl:call-template name='str:substring-after-last-character'>
-          <xsl:with-param name='text'
-            select='substring-after($text, substring($chars, 1, 1))'/>
-          <xsl:with-param name='chars' select='$chars'/>
-          <xsl:with-param name='found' select='true()'/>
-        </xsl:call-template>
-      </xsl:when>
-
-      <xsl:otherwise>
-        <xsl:call-template name='str:substring-after-last-character'>
-          <xsl:with-param name='text' select='$text'/>
-          <xsl:with-param name='chars' select='substring($chars, 2)'/>
-          <xsl:with-param name='found' select='$found'/>
-        </xsl:call-template>
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:template>
-
-  <doc:template name="str:substring-before-last" xmlns="">
-    <refpurpose>String extraction</refpurpose>
-
-    <refdescription>
-      <para>Extracts the portion of string 'text' which occurs before the first character of the last occurance of string 'chars'.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-	<varlistentry>
-	  <term>text</term>
-	  <listitem>
-	    <para>The string from which to extract a substring.</para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>chars</term>
-	  <listitem>
-	    <para>The string containing characters to find.</para>
-	  </listitem>
-	</varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns string.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name="str:substring-before-last">
-    <xsl:param name="text"/>
-    <xsl:param name="chars"/>
-
-    <xsl:choose>
-
-      <xsl:when test="string-length($text) = 0"/>
-
-      <xsl:when test="string-length($chars) = 0">
-	<xsl:value-of select="$text"/>
-      </xsl:when>
-
-      <xsl:when test="contains($text, $chars)">
-	<xsl:call-template name="str:substring-before-last-aux">
-	  <xsl:with-param name="text" select="$text"/>
-	  <xsl:with-param name="chars" select="$chars"/>
-	</xsl:call-template>
-      </xsl:when>
-
-      <xsl:otherwise>
-        <xsl:value-of select="$text"/>
-      </xsl:otherwise>
-
-    </xsl:choose>
-  </xsl:template>
-
-  <xsl:template name="str:substring-before-last-aux">
-    <xsl:param name="text"/>
-    <xsl:param name="chars"/>
-
-    <xsl:choose>
-      <xsl:when test="string-length($text) = 0"/>
-
-      <xsl:when test="contains($text, $chars)">
-	<xsl:variable name="after">
-	  <xsl:call-template name="str:substring-before-last-aux">
-	    <xsl:with-param name="text" select="substring-after($text, $chars)"/>
-	    <xsl:with-param name="chars" select="$chars"/>
-	  </xsl:call-template>
-	</xsl:variable>
-
-	<xsl:value-of select="substring-before($text, $chars)"/>
-	<xsl:if test="string-length($after) > 0">
-	  <xsl:value-of select="$chars"/>
-	  <xsl:copy-of select="$after"/>
-	</xsl:if>
-      </xsl:when>
-
-      <xsl:otherwise/>
-    </xsl:choose>
-  </xsl:template>
-
-  <doc:template name="str:subst" xmlns="">
-    <refpurpose>String substitution</refpurpose>
-
-    <refdescription>
-      <para>Substitute 'replace' for 'with' in string 'text'.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-	<varlistentry>
-	  <term>text</term>
-	  <listitem>
-	    <para>The string upon which to perform substitution.</para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>replace</term>
-	  <listitem>
-	    <para>The string to substitute.</para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>with</term>
-	  <listitem>
-	    <para>The string to be substituted.</para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>disable-output-escaping</term>
-	  <listitem>
-            <para>A value of <literal>yes</literal> indicates that the result should have output escaping disabled.  Any other value allows normal escaping of text values.  The default is to enable output escaping.</para>
-	  </listitem>
-	</varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns string.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name="str:subst">
-    <xsl:param name="text"/>
-    <xsl:param name="replace"/>
-    <xsl:param name="with"/>
-    <xsl:param name='disable-output-escaping'>no</xsl:param>
-
-    <xsl:choose>
-      <xsl:when test="string-length($replace) = 0 and $disable-output-escaping = 'yes'">
-        <xsl:value-of select="$text" disable-output-escaping='yes'/>
-      </xsl:when>
-      <xsl:when test="string-length($replace) = 0">
-        <xsl:value-of select="$text"/>
-      </xsl:when>
-      <xsl:when test="contains($text, $replace)">
-
-	<xsl:variable name="before" select="substring-before($text, $replace)"/>
-	<xsl:variable name="after" select="substring-after($text, $replace)"/>
-
-        <xsl:choose>
-          <xsl:when test='$disable-output-escaping = "yes"'>
-            <xsl:value-of select="$before" disable-output-escaping="yes"/>
-            <xsl:value-of select="$with" disable-output-escaping="yes"/>
-          </xsl:when>
-          <xsl:otherwise>
-            <xsl:value-of select="$before"/>
-            <xsl:value-of select="$with"/>
-          </xsl:otherwise>
-        </xsl:choose>
-        <xsl:call-template name="str:subst">
-	  <xsl:with-param name="text" select="$after"/>
-	  <xsl:with-param name="replace" select="$replace"/>
-	  <xsl:with-param name="with" select="$with"/>
-	  <xsl:with-param name="disable-output-escaping" select="$disable-output-escaping"/>
-	</xsl:call-template>
-      </xsl:when>
-      <xsl:when test='$disable-output-escaping = "yes"'>
-        <xsl:value-of select="$text" disable-output-escaping="yes"/>
-      </xsl:when>
-      <xsl:otherwise>
-        <xsl:value-of select="$text"/>
-      </xsl:otherwise>
-    </xsl:choose>            
-  </xsl:template>
-
-  <doc:template name="str:count-substring" xmlns="">
-    <refpurpose>Count Substrings</refpurpose>
-
-    <refdescription>
-      <para>Counts the number of times a substring occurs in a string.  This can also counts the number of times a character occurs in a string, since a character is simply a string of length 1.</para>
-    </refdescription>
-
-    <example>
-      <title>Counting Lines</title>
-      <programlisting><![CDATA[
-<xsl:call-template name="str:count-substring">
-  <xsl:with-param name="text" select="$mytext"/>
-  <xsl:with-param name="chars" select="'&#x0a;'"/>
-</xsl:call-template>
-]]></programlisting>
-    </example>
-
-    <refparameter>
-      <variablelist>
-	<varlistentry>
-	  <term>text</term>
-	  <listitem>
-	    <para>The source string.</para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>chars</term>
-	  <listitem>
-	    <para>The substring to count.</para>
-	  </listitem>
-	</varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns a non-negative integer value.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name="str:count-substring">
-    <xsl:param name="text"/>
-    <xsl:param name="chars"/>
-
-    <xsl:choose>
-      <xsl:when test="string-length($text) = 0 or string-length($chars) = 0">
-	<xsl:text>0</xsl:text>
-      </xsl:when>
-      <xsl:when test="contains($text, $chars)">
-	<xsl:variable name="remaining">
-	  <xsl:call-template name="str:count-substring">
-	    <xsl:with-param name="text" select="substring-after($text, $chars)"/>
-	    <xsl:with-param name="chars" select="$chars"/>
-	  </xsl:call-template>
-	</xsl:variable>
-	<xsl:value-of select="$remaining + 1"/>
-      </xsl:when>
-      <xsl:otherwise>
-	<xsl:text>0</xsl:text>
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:template>
-
-  <doc:template name="str:substring-after-at" xmlns="">
-    <refpurpose>String extraction</refpurpose>
-    <refdescription>
-      <para>Extracts the portion of a 'char' delimited 'text' string "array" at a given 'position'.</para>
-    </refdescription>
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>text</term>
-          <listitem>
-            <para>The string from which to extract a substring.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>chars</term>
-          <listitem>
-            <para>delimiters</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>position</term>
-          <listitem>
-            <para>position of the elements</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>all</term>
-          <listitem>
-            <para>If true all of the remaining string is returned, otherwise only the element at the given position is returned.  Default: false().</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-    <refreturn>
-      <para>Returns string.</para>
-    </refreturn>
-  </doc:template>
-
-
-  <xsl:template name="str:substring-after-at">
-    <xsl:param name="text"/>
-    <xsl:param name="chars"/>
-    <xsl:param name="position"/>
-    <xsl:param name="all" select='false()'/>
-
-    <xsl:choose>
-      <xsl:when test='number($position) = 0 and $all'>
-        <xsl:value-of select='$text'/>
-      </xsl:when>
-      <xsl:when test='number($position) = 0 and not($chars)'>
-        <xsl:value-of select='$text'/>
-      </xsl:when>
-      <xsl:when test='number($position) = 0 and not(contains($text, $chars))'>
-        <xsl:value-of select='$text'/>
-      </xsl:when>
-      <xsl:when test='not(contains($text, $chars))'>
-      </xsl:when>
-      <xsl:when test="number($position) = 0">
-        <xsl:value-of select="substring-before($text, $chars)"/>
-      </xsl:when>
-      <xsl:otherwise>
-        <xsl:call-template name="str:substring-after-at">
-          <xsl:with-param name="text" select="substring-after($text, $chars)"/>
-          <xsl:with-param name="chars" select="$chars"/>
-          <xsl:with-param name="all" select="$all"/>
-          <xsl:with-param name="position" select="$position - 1"/>
-        </xsl:call-template>
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:template>
-
-  <doc:template name="str:substring-before-at" xmlns="">
-    <refpurpose>String extraction</refpurpose>
-    <refdescription>
-      <para>Extracts the portion of a 'char' delimited 'text' string "array" at a given 'position' </para>
-    </refdescription>
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>text</term>
-          <listitem>
-            <para>The string from which to extract a substring.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>chars</term>
-          <listitem>
-          <para>delimiters</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>position</term>
-          <listitem>
-            <para>position of the elements</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-    <refreturn>
-      <para>Returns string.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name="str:substring-before-at">
-    <xsl:param name="text"/>
-    <xsl:param name="chars"/>
-    <xsl:param name="position"/>
-
-    <xsl:choose>
-      <xsl:when test="$position <= 0"/>
-      <xsl:when test="not(contains($text, $chars))"/>
-      <xsl:otherwise>
-        <xsl:value-of select='substring-before($text, $chars)'/>
-        <xsl:value-of select='$chars'/>
-
-        <xsl:call-template name="str:substring-before-at">
-          <xsl:with-param name="text" select="substring-after($text, $chars)"/>
-          <xsl:with-param name="position" select="$position - 1"/>
-          <xsl:with-param name="chars" select="$chars"/>
-        </xsl:call-template>
-        
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:template>
-
-  <doc:template name="str:insert-at" xmlns="">
-    <refpurpose>String insertion</refpurpose>
-    <refdescription>
-      <para>Insert 'chars' into "text' at any given "position'</para>
-    </refdescription>
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>text</term>
-          <listitem>
-            <para>The string upon which to perform insertion</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>position</term>
-          <listitem>
-            <para>the position where insertion will be performed</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>with</term>
-          <listitem>
-            <para>The string to be inserted</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-    <refreturn>
-      <para>Returns string.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name="str:insert-at">
-    <xsl:param name="text"/>
-    <xsl:param name="position"/>
-    <xsl:param name="chars"/>
-
-    <xsl:variable name="firstpart" select="substring($text, 0, $position)"/>
-    <xsl:variable name="secondpart" select="substring($text, $position, string-length($text))"/>
-
-    <xsl:value-of select="concat($firstpart, $chars, $secondpart)"/>
-  </xsl:template>
- 
-
-  <doc:template name="str:backward" xmlns="">
-    <refpurpose>String reversal</refpurpose>
-
-    <refdescription>
-      <para>Reverse the content of a given string</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>text</term>
-          <listitem>
-            <para>The string to be reversed</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns string.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name="str:backward">
-    <xsl:param name="text"/>
-    <xsl:variable name="mirror">
-      <xsl:call-template name="str:build-mirror">
-        <xsl:with-param name="text" select="$text"/>
-        <xsl:with-param name="position" select="string-length($text)"/>
-      </xsl:call-template>
-    </xsl:variable>
-    <xsl:value-of select="substring($mirror, string-length($text) + 1, string-length($text))"/>
-  </xsl:template>
-
-  <xsl:template name="str:build-mirror">
-    <xsl:param name="text"/>
-    <xsl:param name="position"/>
-
-    <xsl:choose>
-      <xsl:when test="$position > 0">
-        <xsl:call-template name="str:build-mirror">
-          <xsl:with-param name="text" select="concat($text, substring($text, $position, 1))"/>
-          <xsl:with-param name="position" select="$position - 1"/>
-        </xsl:call-template>
-      </xsl:when>
-      <xsl:otherwise>
-        <xsl:value-of select="$text"/>
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:template>
-
-  <doc:template name="str:justify" xmlns="">
-    <refpurpose>Format a string</refpurpose>
-
-    <refdescription>
-      <para>Inserts newlines and spaces into a string to format it as a block of text.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>text</term>
-          <listitem>
-            <para>String to be formatted.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>max</term>
-          <listitem>
-            <para>Maximum line length.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>indent</term>
-          <listitem>
-            <para>Number of spaces to insert at the beginning of each line.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>justify</term>
-          <listitem>
-            <para>Justify left, right or both.  Not currently implemented (fixed at "left").</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Formatted block of text.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name='str:justify'>
-    <xsl:param name='text'/>
-    <xsl:param name='max' select='"80"'/>
-    <xsl:param name='indent' select='"0"'/>
-    <xsl:param name='justify' select='"left"'/>
-
-    <xsl:choose>
-      <xsl:when test='string-length($text) = 0 or $max <= 0'/>
-
-      <xsl:when test='string-length($text) > $max and contains($text, " ") and string-length(substring-before($text, " ")) > $max'>
-        <xsl:call-template name='str:generate-string'>
-          <xsl:with-param name='text' select='" "'/>
-          <xsl:with-param name='count' select='$indent'/>
-        </xsl:call-template>
-        <xsl:value-of select='substring-before($text, " ")'/>
-        <xsl:text>
-</xsl:text>
-        <xsl:call-template name='str:justify'>
-          <xsl:with-param name='text' select='substring-after($text, " ")'/>
-          <xsl:with-param name='max' select='$max'/>
-          <xsl:with-param name='indent' select='$indent'/>
-          <xsl:with-param name='justify' select='$justify'/>
-        </xsl:call-template>
-      </xsl:when>
-
-      <xsl:when test='string-length($text) > $max and contains($text, " ")'>
-        <xsl:variable name='first'>
-          <xsl:call-template name='str:substring-before-last'>
-            <xsl:with-param name='text' select='substring($text, 1, $max)'/>
-            <xsl:with-param name='chars' select='" "'/>
-          </xsl:call-template>
-        </xsl:variable>
-
-        <xsl:call-template name='str:generate-string'>
-          <xsl:with-param name='text' select='" "'/>
-          <xsl:with-param name='count' select='$indent'/>
-        </xsl:call-template>
-        <xsl:value-of select='$first'/>
-        <xsl:text>
-</xsl:text>
-        <xsl:call-template name='str:justify'>
-          <xsl:with-param name='text' select='substring($text, string-length($first) + 2)'/>
-          <xsl:with-param name='max' select='$max'/>
-          <xsl:with-param name='indent' select='$indent'/>
-          <xsl:with-param name='justify' select='$justify'/>
-        </xsl:call-template>
-      </xsl:when>
-
-      <xsl:otherwise>
-        <xsl:call-template name='str:generate-string'>
-          <xsl:with-param name='text' select='" "'/>
-          <xsl:with-param name='count' select='$indent'/>
-        </xsl:call-template>
-        <xsl:value-of select='$text'/>
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:template>
-
-  <doc:template name="str:character-first" xmlns="">
-    <refpurpose>Find first occurring character in a string</refpurpose>
-
-    <refdescription>
-      <para>Finds which of the given characters occurs first in a string.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-	<varlistentry>
-	  <term>text</term>
-	  <listitem>
-	    <para>The source string.</para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>chars</term>
-	  <listitem>
-	    <para>The characters to search for.</para>
-	  </listitem>
-	</varlistentry>
-      </variablelist>
-    </refparameter>
-  </doc:template>
-
-  <xsl:template name="str:character-first">
-    <xsl:param name="text"/>
-    <xsl:param name="chars"/>
-
-    <xsl:choose>
-      <xsl:when test="string-length($text) = 0 or string-length($chars) = 0"/>
-
-      <xsl:when test="contains($text, substring($chars, 1, 1))">
-	<xsl:variable name="next-character">
-	  <xsl:call-template name="str:character-first">
-	    <xsl:with-param name="text" select="$text"/>
-	    <xsl:with-param name="chars" select="substring($chars, 2)"/>
-	  </xsl:call-template>
-	</xsl:variable>
-
-	<xsl:choose>
-	  <xsl:when test="string-length($next-character)">
-	    <xsl:variable name="first-character-position" select="string-length(substring-before($text, substring($chars, 1, 1)))"/>
-	    <xsl:variable name="next-character-position" select="string-length(substring-before($text, $next-character))"/>
-
-	    <xsl:choose>
-	      <xsl:when test="$first-character-position < $next-character-position">
-		<xsl:value-of select="substring($chars, 1, 1)"/>
-	      </xsl:when>
-	      <xsl:otherwise>
-		<xsl:value-of select="$next-character"/>
-	      </xsl:otherwise>
-	    </xsl:choose>
-	  </xsl:when>
-	  <xsl:otherwise>
-	    <xsl:value-of select="substring($chars, 1, 1)"/>
-	  </xsl:otherwise>
-	</xsl:choose>
-      </xsl:when>
-      <xsl:otherwise>
-	<xsl:call-template name="str:character-first">
-	  <xsl:with-param name="text" select="$text"/>
-	  <xsl:with-param name="chars" select="substring($chars, 2)"/>
-	</xsl:call-template>
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:template>
-
-  <doc:template name="str:string-match" xmlns="">
-    <refpurpose>Match A String To A Pattern</refpurpose>
-
-    <refdescription>
-      <para>Performs globbing-style pattern matching on a string.</para>
-    </refdescription>
-
-    <example>
-      <title>Match Pattern</title>
-      <programlisting><![CDATA[
-<xsl:call-template name="str:string-match">
-  <xsl:with-param name="text" select="$mytext"/>
-  <xsl:with-param name="pattern" select="'abc*def?g'"/>
-</xsl:call-template>
-]]></programlisting>
-    </example>
-
-    <refparameter>
-      <variablelist>
-	<varlistentry>
-	  <term>text</term>
-	  <listitem>
-	    <para>The source string.</para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>pattern</term>
-	  <listitem>
-	    <para>The pattern to match against.  Certain characters have special meaning:</para>
-	    <variablelist>
-	      <varlistentry>
-		<term>*</term>
-		<listitem>
-		  <para>Matches zero or more characters.</para>
-		</listitem>
-	      </varlistentry>
-	      <varlistentry>
-		<term>?</term>
-		<listitem>
-		  <para>Matches a single character.</para>
-		</listitem>
-	      </varlistentry>
-	      <varlistentry>
-		<term>\</term>
-		<listitem>
-		  <para>Character escape.  The next character is taken as a literal character.</para>
-		</listitem>
-	      </varlistentry>
-	    </variablelist>
-	  </listitem>
-	</varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns "1" if the string matches the pattern, "0" otherwise.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name="str:string-match">
-    <xsl:param name="text"/>
-    <xsl:param name="pattern"/>
-
-    <xsl:choose>
-      <xsl:when test="$pattern = '*'">
-	<!-- Special case: always matches -->
-	<xsl:text>1</xsl:text>
-      </xsl:when>
-      <xsl:when test="string-length($text) = 0 and string-length($pattern) = 0">
-	<xsl:text>1</xsl:text>
-      </xsl:when>
-      <xsl:when test="string-length($text) = 0 or string-length($pattern) = 0">
-	<xsl:text>0</xsl:text>
-      </xsl:when>
-      <xsl:otherwise>
-	<xsl:variable name='before-special'>
-	  <xsl:call-template name='str:substring-before-first'>
-	    <xsl:with-param name='text' select='$pattern'/>
-	    <xsl:with-param name='chars' select='"*?\"'/>
-	  </xsl:call-template>
-	</xsl:variable>
-	<xsl:variable name='special'>
-	  <xsl:call-template name='str:character-first'>
-	    <xsl:with-param name='text' select='$pattern'/>
-	    <xsl:with-param name='chars' select='"*?\"'/>
-	  </xsl:call-template>
-	</xsl:variable>
-
-	<xsl:variable name='new-text' select='substring($text, string-length($before-special) + 1)'/>
-	<xsl:variable name='new-pattern' select='substring($pattern, string-length($before-special) + 1)'/>
-
-	<xsl:choose>
-	  <xsl:when test="not(starts-with($text, $before-special))">
-	    <!-- Verbatim characters don't match -->
-	    <xsl:text>0</xsl:text>
-	  </xsl:when>
-
-	  <xsl:when test="$special = '*' and string-length($new-pattern) = 1">
-	    <xsl:text>1</xsl:text>
-	  </xsl:when>
-	  <xsl:when test="$special = '*'">
-	    <xsl:call-template name='str:match-postfix'>
-	      <xsl:with-param name='text' select='$new-text'/>
-	      <xsl:with-param name='pattern' select='substring($new-pattern, 2)'/>
-	    </xsl:call-template>
-	  </xsl:when>
-
-	  <xsl:when test="$special = '?'">
-	    <xsl:call-template name="str:string-match">
-	      <xsl:with-param name='text' select='substring($new-text, 2)'/>
-	      <xsl:with-param name='pattern' select='substring($new-pattern, 2)'/>
-	    </xsl:call-template>
-	  </xsl:when>
-
-	  <xsl:when test="$special = '\' and substring($new-text, 1, 1) = substring($new-pattern, 2, 1)">
-	    <xsl:call-template name="str:string-match">
-	      <xsl:with-param name='text' select='substring($new-text, 2)'/>
-	      <xsl:with-param name='pattern' select='substring($new-pattern, 3)'/>
-	    </xsl:call-template>
-	  </xsl:when>
-	  <xsl:when test="$special = '\' and substring($new-text, 1, 1) != substring($new-pattern, 2, 1)">
-	    <xsl:text>0</xsl:text>
-	  </xsl:when>
-
-	  <xsl:otherwise>
-	    <!-- There were no special characters in the pattern -->
-	    <xsl:choose>
-	      <xsl:when test='$text = $pattern'>
-		<xsl:text>1</xsl:text>
-	      </xsl:when>
-	      <xsl:otherwise>
-		<xsl:text>0</xsl:text>
-	      </xsl:otherwise>
-	    </xsl:choose>
-	  </xsl:otherwise>
-	</xsl:choose>
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:template>
-
-  <xsl:template name="str:match-postfix">
-    <xsl:param name="text"/>
-    <xsl:param name="pattern"/>
-
-    <xsl:variable name='result'>
-      <xsl:call-template name='str:string-match'>
-	<xsl:with-param name='text' select='$text'/>
-	<xsl:with-param name='pattern' select='$pattern'/>
-      </xsl:call-template>
-    </xsl:variable>
-
-    <xsl:choose>
-      <xsl:when test='$result = "1"'>
-	<xsl:value-of select='$result'/>
-      </xsl:when>
-      <xsl:when test='string-length($text) = 0'>
-	<xsl:text>0</xsl:text>
-      </xsl:when>
-      <xsl:otherwise>
-	<xsl:call-template name='str:match-postfix'>
-	  <xsl:with-param name='text' select='substring($text, 2)'/>
-	  <xsl:with-param name='pattern' select='$pattern'/>
-	</xsl:call-template>
-      </xsl:otherwise>
-    </xsl:choose>
-
-  </xsl:template>
-
-  <doc:template name="str:generate-string" xmlns="">
-    <refpurpose>Create A Repeating Sequence of Characters</refpurpose>
-
-    <refdescription>
-      <para>Repeats a string a given number of times.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-	<varlistentry>
-	  <term>text</term>
-	  <listitem>
-	    <para>The string to repeat.</para>
-	  </listitem>
-	</varlistentry>
-	<varlistentry>
-	  <term>count</term>
-	  <listitem>
-	    <para>The number of times to repeat the string.</para>
-	  </listitem>
-	</varlistentry>
-      </variablelist>
-    </refparameter>
-  </doc:template>
-
-  <xsl:template name="str:generate-string">
-    <xsl:param name="text"/>
-    <xsl:param name="count"/>
-
-    <xsl:choose>
-      <xsl:when test="string-length($text) = 0 or $count <= 0"/>
-      <xsl:otherwise>
-	<xsl:value-of select="$text"/>
-	<xsl:call-template name="str:generate-string">
-	  <xsl:with-param name="text" select="$text"/>
-	  <xsl:with-param name="count" select="$count - 1"/>
-	</xsl:call-template>
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:template>
-
-</xsl:stylesheet>
-
diff --git a/tclxml-3.2/doc/xsltsl/svg.xsl b/tclxml-3.2/doc/xsltsl/svg.xsl
deleted file mode 100644
index 324aa2a..0000000
--- a/tclxml-3.2/doc/xsltsl/svg.xsl
+++ /dev/null
@@ -1 +0,0 @@
-<xsl:stylesheet version='1.0'
  xmlns:xsl='http://www.w3.org/1999/XSL/Transform'
  xmlns:svg='http://xsltsl.org/svg'
  xmlns:doc="http://xsltsl.org/xsl/documentation/1.0"
  exclude-result-prefixes="doc">

  <xsl:variable name='svg-public-id' select='"-//W3C//DTD SVG 20010904//EN"'/>
  <xsl:variable name='svg-system-id' select='"http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd"'/>

  <doc:reference xmlns="">
    <referenceinfo>
      <releaseinfo role="meta">
        $Id: svg.xsl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
      </releaseinfo>
      <author>
        <surname>Ball</surname>
        <firstname>Steve</firstname>
      </author>
      <copyright>
        <year>2002</year>
        <holder>Steve Ball</holder>
      </copyright>
    </referenceinfo>

    <title>SVG Stylesheet</title>

    <partintro>
      <section>
        <title>Introduction</title>

        <para>This module provides templates for creating SVG images.</para>
      </section>
    </partintro>
  </doc:reference>

  <doc:template name="svg:aqua-button-defs" xmlns="">
    <refpurpose>Aqua-style Button</refpurpose>

    <refdescription>
      <para>Part of the mechanism to create an Aqua-style button.  Include a call to this template in your SVG document's <sgmltag>defs</sgmltag> element.  This template only needs to be included once.  Use this in conjunction with <sgmltag>svg:aqua-button</sgmltag>.</para>

      <para>The default values for color1, color2 and color3 result in a grey button.</para>
    </refdescription>

    <refparameter>
      <variablelist>
        <varlistentry>
          <term>prefix</term>
          <listitem>
            <para>A prefix to append to the identifiers used, so that they don't clash with other identifiers.  Default: "aqua-".</para>
          </listitem>
        </varlistentry>
        <varlistentry>
          <term>color1</term>
          <listitem>
            <para>The base colour of the button.  Default: "#d9d9d9".</para>
          </listitem>
        </varlistentry>
        <varlistentry>
          <term>color2</term>
          <listitem>
            <para>A "background" colour for the button.  Should be a darker colour than color1.  Default: "#a9a9a9".</para>
          </listitem>
        </varlistentry>
        <varlistentry>
          <term>color3</term>
          <listitem>
            <para>A highlight colour for the button.  Should be a lighter colour than color1.  Default: "#f9f9f9".</para>
          </listitem>
        </varlistentry>
      </variablelist>
    </refparameter>

    <refreturn>
      <para>Returns SVG result-tree-fragment.</para>
    </refreturn>
  </doc:template>

  <xsl:template name="svg:aqua-button-defs">
    <xsl:param name="prefix" select='"aqua-"'/>
    <xsl:param name="color1" select='"#d9d9d9"'/>
    <xsl:param name="color2" select='"#a9a9a9"'/>
    <xsl:param name="color3" select='"#f9f9f9"'/>

    <linearGradient id='{$prefix}gradient' x1='0%' y1='0%' x2='0%' y2='100%'>
      <stop offset='0%' stop-color='{$color2}'/>
      <stop offset='100%' stop-color='{$color1}'/>
    </linearGradient>
    <linearGradient id='{$prefix}highlight-gradient' x1='0%' y1='0%' x2='0%' y2='100%'>
      <stop offset='0%' stop-color='#ffffff'/>
      <stop offset='75%' stop-color='{$color3}' stop-opacity='0'/>
      <stop offset='100%' stop-color='{$color3}' stop-opacity='0'/>
    </linearGradient>
    <linearGradient id='{$prefix}revhighlight-gradient' x1='0%' y1='100%' x2='0%' y2='0%'>
      <stop offset='0%' stop-color='#ffffff'/>
      <stop offset='50%' stop-color='{$color3}' stop-opacity='0'/>
      <stop offset='100%' stop-color='{$color3}' stop-opacity='0'/>
    </linearGradient>
    <linearGradient id='{$prefix}corner-left-gradient' x1='0%' y1='0%' x2='100%' y2='100%'>
      <stop offset='0%' stop-color='#000000'/>
      <stop offset='100%' stop-color='{$color3}' stop-opacity='0'/>
    </linearGradient>
    <linearGradient id='{$prefix}corner-right-gradient' x1='100%' y1='0%' x2='0%' y2='100%'>
      <stop offset='0%' stop-color='#000000'/>
      <stop offset='100%' stop-color='{$color3}' stop-opacity='0'/>
    </linearGradient>

    <filter id='{$prefix}filter-blur' filterUnits='userSpaceOnUse' x='0' y='0' width='200' height='100'>
      <feGaussianBlur in='SourceGraphic' stdDeviation='2'/>
    </filter>
    <filter id='{$prefix}drop-shadow' y='-5' height='100'>
      <feColorMatrix type='matrix' in='SourceAlpha' result='inglow'
	values='.5 .5 .5 1 0
		.5 .5 .5 1 0
		.5 .5 .5 1 0
		0 0 0 1 0'/>
      <feBlend mode='multiply' in2='SourceGraphic' in='inglow' result='innerglow'/>

      <feGaussianBlur stdDeviation='4' in='SourceAlpha' result='shadow'/>
      <feColorMatrix type='matrix' in='shadow' result='lightshadow'
	values='.33 .33 .33 1 0
		.33 .33 .33 1 0
		.33 .33 .33 1 0
		0 0 0 1 0'/>
      <feOffset in='lightshadow' dx='0' dy='3' result='dropshadow'/>
      <feMerge>
	<feMergeNode in='dropshadow'/>
	<feMergeNode in='innerglow'/>
      </feMerge>
    </filter>

  </xsl:template>

  <doc:template name="svg:aqua-button" xmlns="">
    <refpurpose>Aqua-style Button</refpurpose>

    <refdescription>
      <para>Part of the mechanism to create an Aqua-style button.  Include a call to this template in your SVG document where you want a button to appear.  This template can be used many times in a single SVG document.  Use this in conjunction with <sgmltag>svg:aqua-button-defs</sgmltag>.</para>
    </refdescription>

    <refparameter>
      <variablelist>
        <varlistentry>
          <term>prefix</term>
          <listitem>
            <para>A prefix to append to the identifiers used, so that they don't clash with other identifiers.  Default: "aqua-".</para>
          </listitem>
        </varlistentry>
      </variablelist>
    </refparameter>

    <refreturn>
      <para>Returns SVG result-tree-fragment.</para>
    </refreturn>
  </doc:template>

  <xsl:template name='svg:aqua-button'>
    <xsl:param name="prefix" select='"aqua-"'/>

    <g filter='url(#{$prefix}drop-shadow)'>
      <clipPath id='{$prefix}main-shape'>
        <path clip-rule='evenodd'
                d="M50,90 C0,90 0,30 50,30 L150,30 C200,30 200,90 150,90 z" />
      </clipPath>
      <path fill="url(#{$prefix}gradient)" stroke="none"
                d="M50,90 C0,90 0,30 50,30 L150,30 C200,30 200,90 150,90 z" />
      <path clip-path='url(#{$prefix}main-shape)' fill='url(#{$prefix}corner-left-gradient)' stroke='none' filter='url(#{$prefix}filter-blur)'
                d="M50,57 L13,57 A35,35 -90 0,1 50,30 z" />
      <path clip-path='url(#{$prefix}main-shape)' fill='url(#{$prefix}corner-right-gradient)' stroke='none' filter='url(#{$prefix}filter-blur)'
                d="M150,30 A35,35 90 0,1 190,57 L150,57 z" />
      <path fill="url(#{$prefix}highlight-gradient)" stroke="none" stroke-width='1'
                d="M50,65 C20,65 20,35 50,35 L150,35 C180,35 180,65 150,65 z" />
      <path filter='url(#{$prefix}filter-blur)' fill="url(#{$prefix}revhighlight-gradient)" stroke="none"
                d="M50,85 C10,85 10,35 50,35 L150,35 C190,35 190,85 150,85 z" />
    </g>
  </xsl:template>
</xsl:stylesheet>
\ No newline at end of file
diff --git a/tclxml-3.2/doc/xsltsl/uri.xsl b/tclxml-3.2/doc/xsltsl/uri.xsl
deleted file mode 100644
index 1235957..0000000
--- a/tclxml-3.2/doc/xsltsl/uri.xsl
+++ /dev/null
@@ -1,755 +0,0 @@
-<?xml version="1.0"?>
-
-<xsl:stylesheet
-  version="1.0"
-  extension-element-prefixes="doc"
-  xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
-  xmlns:doc="http://xsltsl.org/xsl/documentation/1.0"
-  xmlns:uri="http://xsltsl.org/uri"
-  xmlns:str="http://xsltsl.org/string"
->
-
-  <doc:reference xmlns="">
-    <referenceinfo>
-      <releaseinfo role="meta">
-        $Id: uri.xsl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-      </releaseinfo>
-      <author>
-        <surname>Diamond</surname>
-        <firstname>Jason</firstname>
-      </author>
-      <copyright>
-        <year>2005</year>
-        <holder>Steve Ball</holder>
-      </copyright>
-      <copyright>
-        <year>2001</year>
-        <holder>Jason Diamond</holder>
-      </copyright>
-    </referenceinfo>
-
-    <title>URI (Uniform Resource Identifier) Processing</title>
-
-    <partintro>
-      <section>
-        <title>Introduction</title>
-        <para>This module provides templates for processing URIs (Uniform Resource Identifers).</para>
-      </section>
-    </partintro>
-
-  </doc:reference>
-
-  <doc:template name="uri:is-absolute-uri" xmlns="">
-    <refpurpose>Determines if a URI is absolute or relative.</refpurpose>
-
-    <refdescription>
-      <para>Absolute URIs start with a scheme (like "http:" or "mailto:").</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>uri</term>
-          <listitem>
-            <para>An absolute or relative URI.</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns 'true' if the URI is absolute or '' if it's not.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name="uri:is-absolute-uri">
-    <xsl:param name="uri"/>
-
-    <xsl:if test="contains($uri, ':')">
-      <xsl:value-of select="true()"/>
-    </xsl:if>
-
-  </xsl:template>
-
-  <doc:template name="uri:get-uri-scheme" xmlns="">
-    <refpurpose>Gets the scheme part of a URI.</refpurpose>
-
-    <refdescription>
-      <para>The ':' is not part of the scheme.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>uri</term>
-          <listitem>
-            <para>An absolute or relative URI.</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns the scheme (without the ':') or '' if the URI is relative.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name="uri:get-uri-scheme">
-    <xsl:param name="uri"/>
-    <xsl:if test="contains($uri, ':')">
-      <xsl:value-of select="substring-before($uri, ':')"/>
-    </xsl:if>
-  </xsl:template>
-
-  <doc:template name="uri:get-uri-authority" xmlns="">
-    <refpurpose>Gets the authority part of a URI.</refpurpose>
-
-    <refdescription>
-      <para>The authority usually specifies the host machine for a resource. It always follows '//' in a typical URI.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>uri</term>
-          <listitem>
-            <para>An absolute or relative URI.</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns the authority (without the '//') or '' if the URI has no authority.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name="uri:get-uri-authority">
-    <xsl:param name="uri"/>
-
-    <xsl:variable name="a">
-      <xsl:choose>
-        <xsl:when test="contains($uri, ':')">
-          <xsl:if test="substring(substring-after($uri, ':'), 1, 2) = '//'">
-              <xsl:value-of select="substring(substring-after($uri, ':'), 3)"/>
-          </xsl:if>
-        </xsl:when>
-        <xsl:otherwise>
-          <xsl:if test="substring($uri, 1, 2) = '//'">
-            <xsl:value-of select="substring($uri, 3)"/>
-          </xsl:if>
-        </xsl:otherwise>
-      </xsl:choose>
-    </xsl:variable>
-
-    <xsl:choose>
-      <xsl:when test="contains($a, '/')">
-        <xsl:value-of select="substring-before($a, '/')" />
-      </xsl:when>
-      <xsl:when test="contains($a, '?')">
-        <xsl:value-of select="substring-before($a, '?')" />
-      </xsl:when>
-      <xsl:when test="contains($a, '#')">
-        <xsl:value-of select="substring-before($a, '#')" />
-      </xsl:when>
-      <xsl:otherwise>
-        <xsl:value-of select="$a" />
-      </xsl:otherwise>
-    </xsl:choose>
-
-  </xsl:template>
-
-  <doc:template name="uri:get-uri-path" xmlns="">
-    <refpurpose>Gets the path part of a URI.</refpurpose>
-
-    <refdescription>
-      <para>The path usually comes after the '/' in a URI.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>uri</term>
-          <listitem>
-            <para>An absolute or relative URI.</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns the path (with any leading '/') or '' if the URI has no path.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name="uri:get-uri-path">
-    <xsl:param name="uri"/>
-
-    <xsl:variable name="p">
-      <xsl:choose>
-        <xsl:when test="contains($uri, '//')">
-          <xsl:if test="contains(substring-after($uri, '//'), '/')">
-            <xsl:value-of select="concat('/', substring-after(substring-after($uri, '//'), '/'))"/>
-          </xsl:if>
-        </xsl:when>
-        <xsl:otherwise>
-          <xsl:choose>
-            <xsl:when test="contains($uri, ':')">
-              <xsl:value-of select="substring-after($uri, ':')"/>
-            </xsl:when>
-            <xsl:otherwise>
-              <xsl:value-of select="$uri"/>
-            </xsl:otherwise>
-          </xsl:choose>
-        </xsl:otherwise>
-      </xsl:choose>
-    </xsl:variable>
-
-    <xsl:choose>
-      <xsl:when test="contains($p, '?')">
-        <xsl:value-of select="substring-before($p, '?')" />
-      </xsl:when>
-      <xsl:when test="contains($p, '#')">
-        <xsl:value-of select="substring-before($p, '#')" />
-      </xsl:when>
-      <xsl:otherwise>
-        <xsl:value-of select="$p" />
-      </xsl:otherwise>
-    </xsl:choose>
-
-  </xsl:template>
-
-  <doc:template name="uri:get-uri-query" xmlns="">
-    <refpurpose>Gets the query part of a URI.</refpurpose>
-
-    <refdescription>
-      <para>The query comes after the '?' in a URI.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>uri</term>
-          <listitem>
-            <para>An absolute or relative URI.</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns the query (without the '?') or '' if the URI has no query.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name="uri:get-uri-query">
-    <xsl:param name="uri"/>
-
-    <xsl:variable name="q" select="substring-after($uri, '?')"/>
-
-    <xsl:choose>
-      <xsl:when test="contains($q, '#')">
-        <xsl:value-of select="substring-before($q, '#')"/>
-      </xsl:when>
-      <xsl:otherwise><xsl:value-of select="$q"/></xsl:otherwise>
-    </xsl:choose>
-
-  </xsl:template>
-
-  <doc:template name="uri:get-uri-fragment" xmlns="">
-    <refpurpose>Gets the fragment part of a URI.</refpurpose>
-
-    <refdescription>
-      <para>The fragment comes after the '#' in a URI.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>uri</term>
-          <listitem>
-            <para>An absolute or relative URI.</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns the fragment (without the '#') or '' if the URI has no fragment.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name="uri:get-uri-fragment">
-    <xsl:param name="uri"/>
-
-    <xsl:value-of select="substring-after($uri, '#')"/>
-
-  </xsl:template>
-
-  <doc:template name="uri:resolve-uri" xmlns="">
-    <refpurpose>Resolves a URI reference against a base URI.</refpurpose>
-
-    <refdescription>
-      <para>This template follows the guidelines specified by <ulink url="ftp://ftp.isi.edu/in-notes/rfc2396.txt">RFC 2396</ulink>.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>reference</term>
-          <listitem>
-            <para>A (potentially relative) URI reference.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>base</term>
-          <listitem>
-            <para>The base URI.</para>
-          </listitem>
-        </varlistentry>
-        <varlistentry>
-          <term>document</term>
-          <listitem>
-            <para>The URI of the current document. This defaults to the value of the base URI if not specified.</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>The "combined" URI.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name="uri:resolve-uri">
-    <xsl:param name="reference"/>
-    <xsl:param name="base"/>
-    <xsl:param name="document" select="$base"/>
-
-    <xsl:variable name="reference-scheme">
-      <xsl:call-template name="uri:get-uri-scheme">
-        <xsl:with-param name="uri" select="$reference"/>
-      </xsl:call-template>
-    </xsl:variable>
-
-    <xsl:variable name="reference-authority">
-      <xsl:call-template name="uri:get-uri-authority">
-        <xsl:with-param name="uri" select="$reference"/>
-      </xsl:call-template>
-    </xsl:variable>
-
-    <xsl:variable name="reference-path">
-      <xsl:call-template name="uri:get-uri-path">
-        <xsl:with-param name="uri" select="$reference"/>
-      </xsl:call-template>
-    </xsl:variable>
-
-    <xsl:variable name="reference-query">
-      <xsl:call-template name="uri:get-uri-query">
-        <xsl:with-param name="uri" select="$reference"/>
-      </xsl:call-template>
-    </xsl:variable>
-
-    <xsl:variable name="reference-fragment">
-      <xsl:call-template name="uri:get-uri-fragment">
-        <xsl:with-param name="uri" select="$reference"/>
-      </xsl:call-template>
-    </xsl:variable>
-
-    <xsl:choose>
-
-      <xsl:when test="
-        not(string-length($reference-scheme)) and
-        not(string-length($reference-authority)) and
-        not(string-length($reference-path)) and
-        not(string-length($reference-query))"
-      >
-
-        <xsl:choose>
-          <xsl:when test="contains($document, '?')">
-            <xsl:value-of select="substring-before($document, '?')"/>
-          </xsl:when>
-          <xsl:when test="contains($document, '#')">
-            <xsl:value-of select="substring-before($document, '#')"/>
-          </xsl:when>
-          <xsl:otherwise>
-            <xsl:value-of select="$document"/>
-          </xsl:otherwise>
-        </xsl:choose>
-
-        <xsl:if test="string-length($reference-fragment)">
-          <xsl:value-of select="concat('#', $reference-fragment)"/>
-        </xsl:if>
-
-      </xsl:when>
-
-      <xsl:when test="string-length($reference-scheme)">
-
-        <xsl:value-of select="$reference"/>
-
-      </xsl:when>
-
-      <xsl:otherwise>
-
-        <xsl:variable name="base-scheme">
-          <xsl:call-template name="uri:get-uri-scheme">
-            <xsl:with-param name="uri" select="$base"/>
-          </xsl:call-template>
-        </xsl:variable>
-
-        <xsl:variable name="base-authority">
-          <xsl:call-template name="uri:get-uri-authority">
-            <xsl:with-param name="uri" select="$base"/>
-          </xsl:call-template>
-        </xsl:variable>
-
-        <xsl:variable name="base-path">
-          <xsl:call-template name="uri:get-uri-path">
-            <xsl:with-param name="uri" select="$base"/>
-          </xsl:call-template>
-        </xsl:variable>
-
-        <xsl:variable name="base-query">
-          <xsl:call-template name="uri:get-uri-query">
-            <xsl:with-param name="uri" select="$base"/>
-          </xsl:call-template>
-        </xsl:variable>
-
-        <xsl:variable name="base-fragment">
-          <xsl:call-template name="uri:get-uri-fragment">
-            <xsl:with-param name="uri" select="$base"/>
-          </xsl:call-template>
-        </xsl:variable>
-
-        <xsl:variable name="result-authority">
-          <xsl:choose>
-            <xsl:when test="string-length($reference-authority)">
-              <xsl:value-of select="$reference-authority"/>
-            </xsl:when>
-            <xsl:otherwise>
-              <xsl:value-of select="$base-authority"/>
-            </xsl:otherwise>
-          </xsl:choose>
-        </xsl:variable>
-
-        <xsl:variable name="result-path">
-          <xsl:choose>
-            <!-- don't normalize absolute paths -->
-            <xsl:when test="starts-with($reference-path, '/')">
-              <xsl:value-of select="$reference-path" />
-            </xsl:when>
-            <xsl:otherwise>
-              <xsl:call-template name="uri:normalize-path">
-                <xsl:with-param name="path">
-                  <xsl:if test="string-length($reference-authority) = 0 and substring($reference-path, 1, 1) != '/'">
-                    <xsl:call-template name="uri:get-path-without-file">
-                      <xsl:with-param name="path-with-file" select="$base-path"/>
-                    </xsl:call-template>
-                    <xsl:value-of select="'/'"/>
-                  </xsl:if>
-                  <xsl:value-of select="$reference-path"/>
-                </xsl:with-param>
-              </xsl:call-template>
-            </xsl:otherwise>
-          </xsl:choose>
-        </xsl:variable>
-
-        <xsl:value-of select="concat($base-scheme, '://', $result-authority, $result-path)"/>
-
-        <xsl:if test="string-length($reference-query)">
-          <xsl:value-of select="concat('?', $reference-query)"/>
-        </xsl:if>
-
-        <xsl:if test="string-length($reference-fragment)">
-          <xsl:value-of select="concat('#', $reference-fragment)"/>
-        </xsl:if>
-
-      </xsl:otherwise>
-    </xsl:choose>
-
-  </xsl:template>
-
-  <xsl:template name="uri:get-path-without-file">
-    <xsl:param name="path-with-file" />
-    <xsl:param name="path-without-file" />
-
-    <xsl:choose>
-      <xsl:when test="contains($path-with-file, '/')">
-        <xsl:call-template name="uri:get-path-without-file">
-          <xsl:with-param name="path-with-file" select="substring-after($path-with-file, '/')" />
-          <xsl:with-param name="path-without-file">
-            <xsl:choose>
-              <xsl:when test="$path-without-file">
-                <xsl:value-of select="concat($path-without-file, '/', substring-before($path-with-file, '/'))" />
-              </xsl:when>
-              <xsl:otherwise>
-                <xsl:value-of select="substring-before($path-with-file, '/')" />
-              </xsl:otherwise>
-            </xsl:choose>
-          </xsl:with-param>
-        </xsl:call-template>
-      </xsl:when>
-      <xsl:otherwise>
-        <xsl:value-of select="$path-without-file" />
-      </xsl:otherwise>
-    </xsl:choose>
-
-  </xsl:template>
-
-  <xsl:template name="uri:normalize-path">
-    <xsl:param name="path"/>
-    <xsl:param name="result" select="''"/>
-
-    <xsl:choose>
-      <xsl:when test="string-length($path)">
-        <xsl:choose>
-          <xsl:when test="$path = '/'">
-            <xsl:value-of select="concat($result, '/')"/>
-          </xsl:when>
-          <xsl:when test="$path = '.'">
-            <xsl:value-of select="concat($result, '/')"/>
-          </xsl:when>
-          <xsl:when test="$path = '..'">
-            <xsl:call-template name="uri:get-path-without-file">
-              <xsl:with-param name="path-with-file" select="$result"/>
-            </xsl:call-template>
-            <xsl:value-of select="'/'"/>
-          </xsl:when>
-          <xsl:when test="contains($path, '/')">
-            <!-- the current segment -->
-            <xsl:variable name="s" select="substring-before($path, '/')"/>
-            <!-- the remaining path -->
-            <xsl:variable name="p">
-              <xsl:choose>
-                <xsl:when test="substring-after($path, '/') = ''">
-                  <xsl:value-of select="'/'"/>
-                </xsl:when>
-                <xsl:otherwise>
-                  <xsl:value-of select="substring-after($path, '/')"/>
-                </xsl:otherwise>
-              </xsl:choose>
-            </xsl:variable>
-            <xsl:choose>
-              <xsl:when test="$s = ''">
-                <xsl:call-template name="uri:normalize-path">
-                  <xsl:with-param name="path" select="$p"/>
-                  <xsl:with-param name="result" select="$result"/>
-                </xsl:call-template>
-              </xsl:when>
-              <xsl:when test="$s = '.'">
-                <xsl:call-template name="uri:normalize-path">
-                  <xsl:with-param name="path" select="$p"/>
-                  <xsl:with-param name="result" select="$result"/>
-                </xsl:call-template>
-              </xsl:when>
-              <xsl:when test="$s = '..'">
-                <xsl:choose>
-                  <xsl:when test="string-length($result) and (substring($result, string-length($result) - 2) != '/..')">
-                    <xsl:call-template name="uri:normalize-path">
-                      <xsl:with-param name="path" select="$p"/>
-                      <xsl:with-param name="result">
-                        <xsl:call-template name="uri:get-path-without-file">
-                          <xsl:with-param name="path-with-file" select="$result"/>
-                        </xsl:call-template>
-                      </xsl:with-param>
-                    </xsl:call-template>
-                  </xsl:when>
-                  <xsl:otherwise>
-                    <xsl:call-template name="uri:normalize-path">
-                      <xsl:with-param name="path" select="$p"/>
-                      <xsl:with-param name="result" select="concat($result, '/..')"/>
-                    </xsl:call-template>
-                  </xsl:otherwise>
-                </xsl:choose>
-              </xsl:when>
-              <xsl:otherwise>
-                <xsl:call-template name="uri:normalize-path">
-                  <xsl:with-param name="path" select="$p"/>
-                  <xsl:with-param name="result" select="concat($result, '/', $s)"/>
-                </xsl:call-template>
-              </xsl:otherwise>
-            </xsl:choose>
-          </xsl:when>
-          <xsl:otherwise>
-            <xsl:value-of select="concat($result, '/', $path)"/>
-          </xsl:otherwise>
-        </xsl:choose>
-      </xsl:when>
-      <xsl:otherwise>
-        <xsl:value-of select="$result"/>
-      </xsl:otherwise>
-    </xsl:choose>
-
-  </xsl:template>
-
-  <doc:template name="uri:escape" xmlns="">
-    <refpurpose>Escape Characters</refpurpose>
-
-    <refdescription>
-      <para>Escape special characters in a URI.</para>
-    </refdescription>
-
-    <refparameter>
-      <variablelist>
-        <varlistentry>
-          <term>text</term>
-          <listitem>
-            <para>Text to escape.</para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-    </refparameter>
-
-    <refreturn>
-      <para>Returns string, possibly with escaped special characters.</para>
-    </refreturn>
-  </doc:template>
-
-  <xsl:template name='uri:escape'>
-    <xsl:param name='text'/>
-
-    <xsl:variable name='unsafe'>
-      <xsl:text> &#x9;'"[]<>`#%{}|/\^~&#xa;</xsl:text> <!-- " for emacs -->
-    </xsl:variable>
-
-    <xsl:choose>
-      <xsl:when test='string-length(translate($text, $unsafe, "")) != string-length($text)'>
-	<xsl:variable name='sub1'>
-	  <xsl:call-template name='str:subst'>
-	    <xsl:with-param name='text' select='$text'/>
-	    <xsl:with-param name='replace' select='"%"'/>
-	    <xsl:with-param name='with'    select='"%25"'/>
-	  </xsl:call-template>
-	</xsl:variable>
-	<xsl:variable name='sub2'>
-	  <xsl:call-template name='str:subst'>
-	    <xsl:with-param name='text' select='$sub1'/>
-	    <xsl:with-param name='replace' select='"&#x9;"'/>
-	    <xsl:with-param name='with'    select='"%09"'/>
-	  </xsl:call-template>
-	</xsl:variable>
-	<xsl:variable name='sub3'>
-	  <xsl:call-template name='str:subst'>
-	    <xsl:with-param name='text' select='$sub2'/>
-	    <xsl:with-param name='replace'>'</xsl:with-param>
-	    <xsl:with-param name='with' select='"%27"'/>
-	  </xsl:call-template>
-	</xsl:variable>
-	<xsl:variable name='sub4'>
-	  <xsl:call-template name='str:subst'>
-	    <xsl:with-param name='text' select='$sub3'/>
-	    <xsl:with-param name='replace'>"</xsl:with-param> <!-- " for emacs -->
-	    <xsl:with-param name='with'    select='"%22"'/>
-	  </xsl:call-template>
-	</xsl:variable>
-	<xsl:variable name='sub5'>
-	  <xsl:call-template name='str:subst'>
-	    <xsl:with-param name='text' select='$sub4'/>
-	    <xsl:with-param name='replace' select='"["'/>
-	    <xsl:with-param name='with'    select='"%5B"'/>
-	  </xsl:call-template>
-	</xsl:variable>
-	<xsl:variable name='sub6'>
-	  <xsl:call-template name='str:subst'>
-	    <xsl:with-param name='text' select='$sub5'/>
-	    <xsl:with-param name='replace' select='"]"'/>
-	    <xsl:with-param name='with'    select='"%5D"'/>
-	  </xsl:call-template>
-	</xsl:variable>
-	<xsl:variable name='sub7'>
-	  <xsl:call-template name='str:subst'>
-	    <xsl:with-param name='text' select='$sub6'/>
-	    <xsl:with-param name='replace' select='"<"'/>
-	    <xsl:with-param name='with'    select='"%3C"'/>
-	  </xsl:call-template>
-	</xsl:variable>
-	<xsl:variable name='sub8'>
-	  <xsl:call-template name='str:subst'>
-	    <xsl:with-param name='text' select='$sub7'/>
-	    <xsl:with-param name='replace' select='">"'/>
-	    <xsl:with-param name='with'    select='"%3E"'/>
-	  </xsl:call-template>
-	</xsl:variable>
-	<xsl:variable name='sub9'>
-	  <xsl:call-template name='str:subst'>
-	    <xsl:with-param name='text' select='$sub8'/>
-	    <xsl:with-param name='replace' select='"`"'/>
-	    <xsl:with-param name='with'    select='"%60"'/>
-	  </xsl:call-template>
-	</xsl:variable>
-	<xsl:variable name='sub10'>
-	  <xsl:call-template name='str:subst'>
-	    <xsl:with-param name='text' select='$sub9'/>
-	    <xsl:with-param name='replace' select='"#"'/>
-	    <xsl:with-param name='with'    select='"%23"'/>
-	  </xsl:call-template>
-	</xsl:variable>
-	<xsl:variable name='sub11'>
-	  <xsl:call-template name='str:subst'>
-	    <xsl:with-param name='text' select='$sub10'/>
-	    <xsl:with-param name='replace' select='" "'/>
-	    <xsl:with-param name='with'    select='"%20"'/>
-	  </xsl:call-template>
-	</xsl:variable>
-	<xsl:variable name='sub12'>
-	  <xsl:call-template name='str:subst'>
-	    <xsl:with-param name='text' select='$sub11'/>
-	    <xsl:with-param name='replace' select='"{"'/>
-	    <xsl:with-param name='with'    select='"%7B"'/>
-	  </xsl:call-template>
-	</xsl:variable>
-	<xsl:variable name='sub13'>
-	  <xsl:call-template name='str:subst'>
-	    <xsl:with-param name='text' select='$sub12'/>
-	    <xsl:with-param name='replace' select='"}"'/>
-	    <xsl:with-param name='with'    select='"%7D"'/>
-	  </xsl:call-template>
-	</xsl:variable>
-	<xsl:variable name='sub14'>
-	  <xsl:call-template name='str:subst'>
-	    <xsl:with-param name='text' select='$sub13'/>
-	    <xsl:with-param name='replace' select='"|"'/>
-	    <xsl:with-param name='with'    select='"%7C"'/>
-	  </xsl:call-template>
-	</xsl:variable>
-	<xsl:variable name='sub15'>
-	  <xsl:call-template name='str:subst'>
-	    <xsl:with-param name='text' select='$sub14'/>
-	    <xsl:with-param name='replace' select='"/"'/>
-	    <xsl:with-param name='with'    select='"%2F"'/>
-	  </xsl:call-template>
-	</xsl:variable>
-	<xsl:variable name='sub16'>
-	  <xsl:call-template name='str:subst'>
-	    <xsl:with-param name='text' select='$sub15'/>
-	    <xsl:with-param name='replace' select='"\"'/>
-	    <xsl:with-param name='with'    select='"%5C"'/>
-	  </xsl:call-template>
-	</xsl:variable>
-	<xsl:variable name='sub17'>
-	  <xsl:call-template name='str:subst'>
-	    <xsl:with-param name='text' select='$sub16'/>
-	    <xsl:with-param name='replace' select='"^"'/>
-	    <xsl:with-param name='with'    select='"%5E"'/>
-	  </xsl:call-template>
-	</xsl:variable>
-	<xsl:variable name='sub18'>
-	  <xsl:call-template name='str:subst'>
-	    <xsl:with-param name='text' select='$sub17'/>
-	    <xsl:with-param name='replace' select='"~"'/>
-	    <xsl:with-param name='with'    select='"%7E"'/>
-	  </xsl:call-template>
-	</xsl:variable>
-	<xsl:call-template name='str:subst'>
-	  <xsl:with-param name='text' select='$sub18'/>
-	  <xsl:with-param name='replace' select='"&#xa;"'/>
-	  <xsl:with-param name='with'    select='"%0A"'/>
-	</xsl:call-template>
-      </xsl:when>
-      <xsl:otherwise>
-	<xsl:value-of select='$text'/>
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:template>
-
-</xsl:stylesheet>
diff --git a/tclxml-3.2/docObj.c b/tclxml-3.2/docObj.c
deleted file mode 100644
index b91ab1f..0000000
--- a/tclxml-3.2/docObj.c
+++ /dev/null
@@ -1,1832 +0,0 @@
-/* docObj.c --
- *
- *	This module manages libxml2 xmlDocPtr Tcl objects.
- *
- * Copyright (c) 2005 by Explain.
- * http://www.explain.com.au/
- * Copyright (c) 2003-2004 Zveno Pty Ltd
- * http://www.zveno.com/
- *
- * See the file "LICENSE" for information on usage and
- * redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
- *
- * $Id: docObj.c,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
- */
-
-#include <tclxml-libxml2/tclxml-libxml2.h>
-#include <libxml/xmlerror.h>
-#include <string.h>
-
-#define TCL_DOES_STUBS \
-    (TCL_MAJOR_VERSION > 8 || TCL_MAJOR_VERSION == 8 && (TCL_MINOR_VERSION > 1 || \
-    (TCL_MINOR_VERSION == 1 && TCL_RELEASE_LEVEL == TCL_FINAL_RELEASE)))
-
-#undef TCL_STORAGE_CLASS
-#define TCL_STORAGE_CLASS DLLEXPORT
-
-/*
- * Basic list for tracking Tcl_Obj's for a document.
- */
-
-typedef struct ObjList {
-  Tcl_Obj *objPtr;
-  struct ObjList *next;
-} ObjList;
-
-/*
- * Prototypes for procedures defined later in this file:
- */
-
-static void DestroyTclDoc _ANSI_ARGS_((TclXML_libxml2_Document *tDocPtr));
-
-Tcl_FreeInternalRepProc	TclXMLlibxml2_DocFree;
-Tcl_DupInternalRepProc	TclXMLlibxml2_DocDup;
-Tcl_UpdateStringProc	TclXMLlibxml2_DocUpdate;
-Tcl_SetFromAnyProc	TclXMLlibxml2_DocSetFromAny;
-
-Tcl_ObjType TclXMLlibxml2_DocObjType = {
-  "libxml2-doc",
-  TclXMLlibxml2_DocFree,
-  TclXMLlibxml2_DocDup,
-  TclXMLlibxml2_DocUpdate,
-  TclXMLlibxml2_DocSetFromAny
-};
-
-typedef struct ThreadSpecificData {
-  int initialized;
-
-  /*
-   * Hash table for mapping string rep to doc structure.
-   */
-
-  Tcl_HashTable *documents;
-  int docCntr;
-
-  /*
-   * Hash table for tracking doc objects.
-   */
-
-  Tcl_HashTable *docByPtr;
-
-  /*
-   * Structured error handling
-   */
-
-  TclXML_ErrorInfo *errorInfoPtr;
-
-} ThreadSpecificData;
-static Tcl_ThreadDataKey dataKey;
-
-/*
- * libxml2 is mostly thread-safe, but just-in-case use a mutex to control access.
- */
-
-TCL_DECLARE_MUTEX(libxml2)
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXML_libxml2_InitDocObj --
- *
- *  Initialise this module.
- *
- * Results:
- *  Returns success code
- *
- * Side effects:
- *  Memory may be allocated
- *
- *----------------------------------------------------------------------------
- */
-
-int
-TclXML_libxml2_InitDocObj(interp)
-    Tcl_Interp *interp;
-{
-  ThreadSpecificData *tsdPtr = Tcl_GetThreadData(&dataKey, sizeof(ThreadSpecificData));
-
-  tsdPtr->initialized = 1;
-  tsdPtr->documents = (Tcl_HashTable *) Tcl_Alloc(sizeof(Tcl_HashTable));
-  Tcl_InitHashTable(tsdPtr->documents, TCL_STRING_KEYS);
-  tsdPtr->docByPtr = (Tcl_HashTable *) Tcl_Alloc(sizeof(Tcl_HashTable));
-  Tcl_InitHashTable(tsdPtr->docByPtr, TCL_ONE_WORD_KEYS);
-
-  tsdPtr->docCntr = 0;
-
-  /*
-   * Setup an error handler that stores structured error info
-   */
-
-  tsdPtr->errorInfoPtr = (TclXML_ErrorInfo *) Tcl_Alloc(sizeof(TclXML_ErrorInfo));
-  tsdPtr->errorInfoPtr->interp = interp;
-  tsdPtr->errorInfoPtr->listPtr = NULL;
-  tsdPtr->errorInfoPtr->nodeHandlerProc = NULL;
-  xmlSetStructuredErrorFunc((void *) tsdPtr->errorInfoPtr, TclXML_libxml2_ErrorHandler);
-
-  return TCL_OK;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXML_libxml2_NewDocObj --
- *
- *  Creates a new xmlDocPtr and wraps it in a Tcl_Obj.
- *
- * Results:
- *  Returns a *TclObj
- *
- * Side effects:
- *  Objects allocated.
- *
- *----------------------------------------------------------------------------
- */
-
-Tcl_Obj *
-TclXML_libxml2_NewDocObj(interp)
-     Tcl_Interp *interp;
-{
-  xmlDocPtr new;
-
-  Tcl_MutexLock(&libxml2);
-  new = xmlNewDoc((const xmlChar *) "1.0");
-  Tcl_MutexUnlock(&libxml2);
-  if (!new) {
-    Tcl_SetResult(interp, "unable to create document", NULL);
-    return NULL;
-  }
-
-  return TclXML_libxml2_CreateObjFromDoc(new);
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXML_libxml2_CreateObjFromDoc --
- *
- *  Create a Tcl_Obj to wrap a xmlDocPtr.
- *
- * Results:
- *  Returns Tcl_Obj*.
- *
- * Side effects:
- *  Allocates object.
- *
- *----------------------------------------------------------------------------
- */
-
-Tcl_Obj *
-TclXML_libxml2_CreateObjFromDoc (docPtr)
-  xmlDocPtr docPtr;
-{
-  ThreadSpecificData *tsdPtr = Tcl_GetThreadData(&dataKey, sizeof(ThreadSpecificData));
-  TclXML_libxml2_Document *tDocPtr;
-  Tcl_HashEntry *entryPtr;
-  Tcl_Obj *objPtr;
-  ObjList *listPtr;
-
-  /*
-   * This xmlDocPtr may already have been wrapped by a Tcl object.
-   * If so, return an already existing wrapper.
-   * If not, create a new wrapper.
-   */
-
-  entryPtr = Tcl_FindHashEntry(tsdPtr->docByPtr, (ClientData) docPtr);
-  if (entryPtr) {
-    tDocPtr = (TclXML_libxml2_Document *) Tcl_GetHashValue(entryPtr);
-
-    if (tDocPtr->objs) {
-      /* The first object is sufficient */
-      listPtr = (ObjList *) tDocPtr->objs;
-      objPtr = listPtr->objPtr;
-    } else {
-      /* Create a new Tcl_Obj to refer to existing structure */
-      objPtr = Tcl_NewObj();
-
-      listPtr = (ObjList *) Tcl_Alloc(sizeof(ObjList));
-      listPtr->objPtr = objPtr;
-      listPtr->next = NULL;
-      tDocPtr->objs = (void *) listPtr;
-
-      objPtr->length = strlen(tDocPtr->token);
-      objPtr->bytes = Tcl_Alloc(objPtr->length + 1);
-      strcpy(objPtr->bytes, tDocPtr->token);
-      objPtr->internalRep.twoPtrValue.ptr1 = (void *) tDocPtr;
-      objPtr->internalRep.twoPtrValue.ptr2 = NULL;
-      objPtr->typePtr = &TclXMLlibxml2_DocObjType;
-    }
-
-  } else {
-    int new;
-
-    objPtr = Tcl_NewObj();
-
-    tDocPtr = (TclXML_libxml2_Document *) Tcl_Alloc(sizeof(TclXML_libxml2_Document));
-    tDocPtr->docPtr = docPtr;
-    tDocPtr->token = Tcl_Alloc(20);
-    sprintf(tDocPtr->token, "doc%d", tsdPtr->docCntr++);
-    tDocPtr->keep = TCLXML_LIBXML2_DOCUMENT_IMPLICIT;
-    tDocPtr->dom = NULL;
-    tDocPtr->domfree = NULL;
-    tDocPtr->apphook = NULL;
-    tDocPtr->appfree = NULL;
-
-    listPtr = (ObjList *) Tcl_Alloc(sizeof(ObjList));
-    listPtr->objPtr = objPtr;
-    listPtr->next = NULL;
-    tDocPtr->objs = (void *) listPtr;
-
-    entryPtr = Tcl_CreateHashEntry(tsdPtr->documents, tDocPtr->token, &new);
-    Tcl_SetHashValue(entryPtr, (ClientData) tDocPtr);
-    entryPtr = Tcl_CreateHashEntry(tsdPtr->docByPtr, (ClientData) docPtr, &new);
-    Tcl_SetHashValue(entryPtr, (ClientData) tDocPtr);
-
-    objPtr->length = strlen(tDocPtr->token);
-    objPtr->bytes = Tcl_Alloc(objPtr->length + 1);
-    strcpy(objPtr->bytes, tDocPtr->token);
-    objPtr->internalRep.twoPtrValue.ptr1 = (void *) tDocPtr;
-    objPtr->internalRep.twoPtrValue.ptr2 = NULL;
-    objPtr->typePtr = &TclXMLlibxml2_DocObjType;
-  }
-
-  /* Bug fix #1032660.  David Welton. */
-  Tcl_IncrRefCount(objPtr);
-
-  return objPtr;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXML_libxml2_GetDocFromObj --
- *
- *  Retrieve the xmlDocPtr from a Tcl object.
- *
- * Results:
- *  Returns success code.
- *
- * Side effects:
- *  May set internal rep of object.
- *
- *----------------------------------------------------------------------------
- */
-
-int
-TclXML_libxml2_GetDocFromObj (interp, objPtr, docPtr)
-     Tcl_Interp *interp;
-     Tcl_Obj *objPtr;
-     xmlDocPtr *docPtr;
-{
-  TclXML_libxml2_Document *tDocPtr;
-
-  if (TclXML_libxml2_GetTclDocFromObj(interp, objPtr, &tDocPtr) != TCL_OK) {
-    return TCL_ERROR;
-  }
-
-  *docPtr = tDocPtr->docPtr;
-
-  return TCL_OK;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXML_libxml2_GetTclDocFromNode --
- *
- *  Retrieve a pointer to the TclXML Doc structure from a xmlNodePtr.
- *
- * Results:
- *  Returns success code.
- *
- * Side effects:
- *  Sets pointer
- *
- *----------------------------------------------------------------------------
- */
-
-int
-TclXML_libxml2_GetTclDocFromNode (interp, nodePtr, tDocPtrPtr)
-     Tcl_Interp *interp;
-     xmlNodePtr nodePtr;
-     TclXML_libxml2_Document **tDocPtrPtr;
-{
-  ThreadSpecificData *tsdPtr = Tcl_GetThreadData(&dataKey, sizeof(ThreadSpecificData));
-  Tcl_HashEntry *entryPtr;
-
-  entryPtr = Tcl_FindHashEntry(tsdPtr->docByPtr, (ClientData) nodePtr->doc);
-  if (!entryPtr) {
-    *tDocPtrPtr = NULL;
-    Tcl_SetResult(interp, "document not known", NULL);
-    return TCL_ERROR;
-  }
-
-  *tDocPtrPtr = (TclXML_libxml2_Document *) Tcl_GetHashValue(entryPtr);
-
-  return TCL_OK;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXML_libxml2_GetTclDocFromObj --
- *
- *  Retrieve the TclXML_libxml2_Document from a Tcl object.
- *
- * Results:
- *  Returns success code.
- *
- * Side effects:
- *  May set internal rep of object.
- *
- *----------------------------------------------------------------------------
- */
-
-int
-TclXML_libxml2_GetTclDocFromObj (interp, objPtr, tDocPtr)
-     Tcl_Interp *interp;
-     Tcl_Obj *objPtr;
-     TclXML_libxml2_Document **tDocPtr;
-{
-  if (objPtr->typePtr == &TclXMLlibxml2_DocObjType) {
-    *tDocPtr = (TclXML_libxml2_Document *) objPtr->internalRep.twoPtrValue.ptr1;
-  } else if (TclXMLlibxml2_DocSetFromAny(interp, objPtr) == TCL_OK) {
-    *tDocPtr = (TclXML_libxml2_Document *) objPtr->internalRep.twoPtrValue.ptr1;
-  } else {
-    return TCL_ERROR;
-  }
-
-  return TCL_OK;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXML_libxml2_DestroyDocument --
- *
- *  Manage destruction of a document.
- *  The trick here is to make sure that all Tcl_Obj's
- *  that reference this document have their internal rep
- *  invalidated.
- *
- * Results:
- *  None.
- *
- * Side effects:
- *  Memory deallocated, object internal reps changed.
- *
- *----------------------------------------------------------------------------
- */
-
-void
-TclXML_libxml2_DestroyDocument (tDocPtr)
-     TclXML_libxml2_Document *tDocPtr;
-{
-  ObjList *listPtr = (ObjList *) tDocPtr->objs;
-  ObjList *next;
-
-  /*
-   * Invalidate the internal representation of all Tcl_Obj's
-   * that refer to this document.
-   */
-  while (listPtr) {
-    next = listPtr->next;
-    TclXMLlibxml2_DocFree(listPtr->objPtr);
-    listPtr = next;
-  }
-
-  if (tDocPtr->keep == TCLXML_LIBXML2_DOCUMENT_KEEP) {
-    DestroyTclDoc(tDocPtr);
-  }
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXML_libxml2_DocKeep --
- *
- *  Changes how the document's destruction is handled.
- *
- * Results:
- *  None.
- *
- * Side effects:
- *  Changes document configuration.
- *
- *----------------------------------------------------------------------------
- */
-
-void
-TclXML_libxml2_DocKeep(objPtr, keep)
-     Tcl_Obj *objPtr;
-     TclXML_libxml2_DocumentHandling keep;
-{
-  TclXML_libxml2_Document *tDocPtr;
-
-  if (TclXML_libxml2_GetTclDocFromObj(NULL, objPtr, &tDocPtr) != TCL_OK) {
-    return;
-  }
-
-  tDocPtr->keep = keep;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXMLlibxml2_DocSetFromAny --
- *
- *  Finds the xmlDocPtr wrapper for a Tcl object.
- *
- * Results:
- *  Returns success code.
- *
- * Side effects:
- *  Changes the Tcl_Obj's internal rep.
- *
- *----------------------------------------------------------------------------
- */
-
-int
-TclXMLlibxml2_DocSetFromAny(interp, objPtr)
-     Tcl_Interp *interp;
-     Tcl_Obj *objPtr;
-{
-  ThreadSpecificData *tsdPtr = Tcl_GetThreadData(&dataKey, sizeof(ThreadSpecificData));
-  Tcl_HashEntry *entryPtr;
-  TclXML_libxml2_Document *tDocPtr;
-  ObjList *listPtr;
-
-  entryPtr = Tcl_FindHashEntry(tsdPtr->documents, Tcl_GetStringFromObj(objPtr, NULL));
-
-  if (entryPtr) {
-
-    if (objPtr->typePtr != NULL && objPtr->typePtr->freeIntRepProc != NULL) {
-      objPtr->typePtr->freeIntRepProc(objPtr);
-    }
-
-    objPtr->internalRep.twoPtrValue.ptr1 = Tcl_GetHashValue(entryPtr);
-    objPtr->typePtr = &TclXMLlibxml2_DocObjType;
-
-    tDocPtr = (TclXML_libxml2_Document *) objPtr->internalRep.twoPtrValue.ptr1;
-
-    /*
-     * Add this object to the Tcl_Obj list.
-     * NB. There should be no duplicates.
-     */
-    listPtr = (ObjList *) tDocPtr->objs;
-    if (listPtr == NULL) {
-      listPtr = (ObjList *) Tcl_Alloc(sizeof(ObjList));
-      listPtr->objPtr = objPtr;
-      listPtr->next = NULL;
-      tDocPtr->objs = listPtr;
-    } else {
-      ObjList *newPtr;
-
-      newPtr = (ObjList *) Tcl_Alloc(sizeof(ObjList));
-      newPtr->objPtr = objPtr;
-      newPtr->next = listPtr;
-      tDocPtr->objs = (void *) newPtr;
-    }
-    /* SANITY CHECK NEEDED: no duplicates in the list */
-
-  } else {
-
-    if (interp) {
-      Tcl_ResetResult(interp);
-      Tcl_AppendResult(interp, "token \"", Tcl_GetStringFromObj(objPtr, NULL), "\" is not a libxml2 document", NULL);
-    }
-
-    return TCL_ERROR;
-  }
-
-  return TCL_OK;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXMLlibxml2_DocUpdate --
- *
- *  Finds the token for a xmlDocPtr wrapper.
- *
- * Results:
- *  None.
- *
- * Side effects:
- *  Changes the Tcl_Obj's string rep.
- *
- *----------------------------------------------------------------------------
- */
-
-void
-TclXMLlibxml2_DocUpdate(objPtr)
-     Tcl_Obj *objPtr;
-{
-  ThreadSpecificData *tsdPtr = Tcl_GetThreadData(&dataKey, sizeof(ThreadSpecificData));
-  Tcl_HashEntry *entryPtr;
-
-  entryPtr = Tcl_FindHashEntry(tsdPtr->docByPtr, objPtr->internalRep.twoPtrValue.ptr1);
-  Tcl_InvalidateStringRep(objPtr);
-  if (entryPtr != NULL) {
-    TclXML_libxml2_Document *tDocPtr = (TclXML_libxml2_Document *) Tcl_GetHashValue(entryPtr);
-    objPtr->length = strlen(tDocPtr->token);
-    objPtr->bytes = Tcl_Alloc(objPtr->length + 1);
-    strcpy(objPtr->bytes, tDocPtr->token);
-  }
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXMLlibxml2_DocDup --
- *
- *  Duplicates the Tcl wrapper.
- *  NB. This does *not* copy the document itself - it simply creates
- *  another reference to the same document.
- *
- * Results:
- *  None.
- *
- * Side effects:
- *  Changes the target Tcl_Obj.
- *
- *----------------------------------------------------------------------------
- */
-
-void
-TclXMLlibxml2_DocDup(srcPtr, dstPtr)
-     Tcl_Obj *srcPtr;
-     Tcl_Obj *dstPtr;
-{
-  TclXML_libxml2_Document *tDocPtr;
-  ObjList *listPtr;
-
-  if (dstPtr->typePtr != NULL && dstPtr->typePtr->freeIntRepProc != NULL) {
-    dstPtr->typePtr->freeIntRepProc(dstPtr);
-  }
-
-  tDocPtr = (TclXML_libxml2_Document *) srcPtr->internalRep.twoPtrValue.ptr1;
-  listPtr = (ObjList *) Tcl_Alloc(sizeof(ObjList));
-  listPtr->objPtr = dstPtr;
-  listPtr->next = ((ObjList *) tDocPtr->objs)->next;
-  tDocPtr->objs = listPtr;
-
-  Tcl_InvalidateStringRep(dstPtr);
-
-  dstPtr->internalRep.twoPtrValue.ptr1 = srcPtr->internalRep.twoPtrValue.ptr1;
-  dstPtr->internalRep.twoPtrValue.ptr2 = NULL;
-  dstPtr->typePtr = srcPtr->typePtr;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXMLlibxml2_DocFree --
- *
- *  Removes a Tcl wrapper to a libxml2 document.
- *
- * Results:
- *  None.
- *
- * Side effects:
- *  May free the document.
- *
- *----------------------------------------------------------------------------
- */
-
-void
-TclXMLlibxml2_DocFree(objPtr)
-     Tcl_Obj *objPtr;
-{
-  TclXML_libxml2_Document *tDocPtr = (TclXML_libxml2_Document *) objPtr->internalRep.twoPtrValue.ptr1;
-  ObjList *listPtr = tDocPtr->objs;
-  ObjList *prevPtr = NULL;
-
-  while (listPtr) {
-    if (listPtr->objPtr == objPtr) {
-      break;
-    }
-    prevPtr = listPtr;
-    listPtr = listPtr->next;
-  }
-
-  if (listPtr == NULL) {
-    /* internal error */
-  } else if (prevPtr == NULL) {
-    tDocPtr->objs = listPtr->next;
-  } else {
-    prevPtr->next = listPtr->next;
-  }
-  Tcl_Free((char *) listPtr);
-
-  if (tDocPtr->objs == NULL && tDocPtr->keep == TCLXML_LIBXML2_DOCUMENT_IMPLICIT) {
-    DestroyTclDoc(tDocPtr);
-  }
-
-  objPtr->internalRep.twoPtrValue.ptr1 = NULL;
-  objPtr->internalRep.twoPtrValue.ptr2 = NULL;
-  objPtr->typePtr = NULL;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * DestroyTclDoc --
- *
- *  Destroy the Tcl wrapper for a document.
- *
- * Results:
- *  None.
- *
- * Side effects:
- *  Free memory.
- *
- *----------------------------------------------------------------------------
- */
-
-void
-DestroyTclDoc(tDocPtr)
-     TclXML_libxml2_Document *tDocPtr;
-{
-  ThreadSpecificData *tsdPtr = Tcl_GetThreadData(&dataKey, sizeof(ThreadSpecificData));
-  Tcl_HashEntry *entryPtr;
-
-  if (tDocPtr->domfree) {
-    (tDocPtr->domfree)(tDocPtr->dom);
-  }
-  if (tDocPtr->appfree) {
-    (tDocPtr->appfree)(tDocPtr->dom);
-  }
-
-  entryPtr = Tcl_FindHashEntry(tsdPtr->documents, tDocPtr->token);
-  if (entryPtr) {
-    Tcl_DeleteHashEntry(entryPtr);
-  } else {
-    /* Internal error */
-  }
-
-  entryPtr = Tcl_FindHashEntry(tsdPtr->docByPtr, (ClientData) tDocPtr->docPtr);
-  if (entryPtr) {
-    Tcl_DeleteHashEntry(entryPtr);
-  } else {
-    /* Internal error */
-  }
-
-  Tcl_MutexLock(&libxml2);
-  xmlFreeDoc(tDocPtr->docPtr);
-  Tcl_MutexUnlock(&libxml2);
-
-  Tcl_Free(tDocPtr->token);
-  Tcl_Free((char *) tDocPtr);
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXML_libxml2_ErrorHandler --
- *
- *  Handler for structured error reports
- *
- * Results:
- *  None.
- *
- * Side effects:
- *  Creates a Tcl_Obj to store the error information.
- *
- *----------------------------------------------------------------------------
- */
-
-static Tcl_Obj *
-ErrorDomainToString(domain)
-     int domain;
-{
-  switch ((xmlErrorDomain) domain) {
-  case XML_FROM_NONE:
-    return Tcl_NewStringObj("none", -1);
-  case XML_FROM_PARSER:
-    return Tcl_NewStringObj("parser", -1);
-  case XML_FROM_TREE:
-    return Tcl_NewStringObj("tree", -1);
-  case XML_FROM_NAMESPACE:
-    return Tcl_NewStringObj("namespace", -1);
-  case XML_FROM_DTD:
-    return Tcl_NewStringObj("dtd-validation", -1);
-  case XML_FROM_HTML:
-    return Tcl_NewStringObj("html-parser", -1);
-  case XML_FROM_MEMORY:
-    return Tcl_NewStringObj("memory", -1);
-  case XML_FROM_OUTPUT:
-    return Tcl_NewStringObj("output", -1);
-  case XML_FROM_IO:
-    return Tcl_NewStringObj("io", -1);
-  case XML_FROM_FTP:
-    return Tcl_NewStringObj("ftp", -1);
-  case XML_FROM_HTTP:
-    return Tcl_NewStringObj("http", -1);
-  case XML_FROM_XINCLUDE:
-    return Tcl_NewStringObj("XInclude", -1);
-  case XML_FROM_XPOINTER:
-    return Tcl_NewStringObj("XPointer", -1);
-  case XML_FROM_REGEXP:
-    return Tcl_NewStringObj("regexp", -1);
-  case XML_FROM_DATATYPE:
-    return Tcl_NewStringObj("schemas-datatype", -1);
-  case XML_FROM_SCHEMASP:
-    return Tcl_NewStringObj("schemas-parser", -1);
-  case XML_FROM_SCHEMASV:
-    return Tcl_NewStringObj("schemas-validation", -1);
-  case XML_FROM_RELAXNGP:
-    return Tcl_NewStringObj("relaxng-parser", -1);
-  case XML_FROM_RELAXNGV:
-    return Tcl_NewStringObj("relaxng-validation", -1);
-  case XML_FROM_CATALOG:
-    return Tcl_NewStringObj("catalog", -1);
-  case XML_FROM_C14N:
-    return Tcl_NewStringObj("canonicalization", -1);
-  case XML_FROM_XSLT:
-    return Tcl_NewStringObj("xslt", -1);
-  default:
-    return Tcl_NewObj();
-  }
-}
-
-static Tcl_Obj *
-ErrorLevelToString(level)
-     xmlErrorLevel level;
-{
-  switch (level) {
-  case XML_ERR_WARNING:
-    return Tcl_NewStringObj("warning", -1);
-  case XML_ERR_ERROR:
-    return Tcl_NewStringObj("error", -1);
-  case XML_ERR_FATAL:
-    return Tcl_NewStringObj("fatal", -1);
-  case XML_ERR_NONE:
-  default:
-    return Tcl_NewStringObj("none", -1);
-  }
-}
-
-static Tcl_Obj *
-ErrorCodeToString(code)
-     int code;
-{
-  switch ((xmlParserErrors) code) {
-  case XML_ERR_OK:
-    return Tcl_NewObj();
-  case XML_ERR_INTERNAL_ERROR:
-    return Tcl_NewStringObj("internal-error", -1);
-  case XML_ERR_NO_MEMORY:
-    return Tcl_NewStringObj("no-memory", -1);
-  case XML_ERR_DOCUMENT_START:
-    return Tcl_NewStringObj("document-start", -1);
-  case XML_ERR_DOCUMENT_EMPTY:
-    return Tcl_NewStringObj("document-empty", -1);
-  case XML_ERR_DOCUMENT_END:
-    return Tcl_NewStringObj("document-end", -1);
-  case XML_ERR_INVALID_HEX_CHARREF:
-    return Tcl_NewStringObj("invalid-hex-character-reference", -1);
-  case XML_ERR_INVALID_DEC_CHARREF:
-    return Tcl_NewStringObj("invalid-decimal-character-reference", -1);
-  case XML_ERR_INVALID_CHARREF:
-    return Tcl_NewStringObj("invalid-character-reference", -1);
-  case XML_ERR_INVALID_CHAR:
-    return Tcl_NewStringObj("invalid-character", -1);
-  case XML_ERR_CHARREF_AT_EOF:
-    return Tcl_NewStringObj("character-reference-at-eof", -1);
-  case XML_ERR_CHARREF_IN_PROLOG:
-    return Tcl_NewStringObj("character-reference-in-prolog", -1);
-  case XML_ERR_CHARREF_IN_EPILOG:
-    return Tcl_NewStringObj("character-reference-in-epilog", -1);
-  case XML_ERR_CHARREF_IN_DTD:
-    return Tcl_NewStringObj("character-reference-in-dtd", -1);
-  case XML_ERR_ENTITYREF_AT_EOF:
-    return Tcl_NewStringObj("entity-reference-at-eof", -1);
-  case XML_ERR_ENTITYREF_IN_PROLOG:
-    return Tcl_NewStringObj("entity-reference-in-prolog", -1);
-  case XML_ERR_ENTITYREF_IN_EPILOG:
-    return Tcl_NewStringObj("entity-reference-in-epilog", -1);
-  case XML_ERR_ENTITYREF_IN_DTD:
-    return Tcl_NewStringObj("entity-reference-in-dtd", -1);
-  case XML_ERR_PEREF_AT_EOF:
-    return Tcl_NewStringObj("parameter-entity-reference-at-eof", -1);
-  case XML_ERR_PEREF_IN_PROLOG:
-    return Tcl_NewStringObj("parameter-entity-reference-in-prolog", -1);
-  case XML_ERR_PEREF_IN_EPILOG:
-    return Tcl_NewStringObj("parameter-entity-reference-in-epilog", -1);
-  case XML_ERR_PEREF_IN_INT_SUBSET:
-    return Tcl_NewStringObj("parameter-entity-reference-in-internal-subset", -1);
-  case XML_ERR_ENTITYREF_NO_NAME:
-    return Tcl_NewStringObj("entity-reference-no-name", -1);
-  case XML_ERR_ENTITYREF_SEMICOL_MISSING:
-    return Tcl_NewStringObj("entity-reference-semicolon-missing", -1);
-  case XML_ERR_PEREF_NO_NAME:
-    return Tcl_NewStringObj("parameter-entity-reference-no-name", -1);
-  case XML_ERR_PEREF_SEMICOL_MISSING:
-    return Tcl_NewStringObj("parameter-entity-reference-semicolon-missing", -1);
-  case XML_ERR_UNDECLARED_ENTITY:
-    return Tcl_NewStringObj("undeclared-entity", -1);
-  case XML_WAR_UNDECLARED_ENTITY:
-    return Tcl_NewStringObj("undeclared-entity", -1);
-  case XML_ERR_UNPARSED_ENTITY:
-    return Tcl_NewStringObj("unparsed-entity", -1);
-  case XML_ERR_ENTITY_IS_EXTERNAL:
-    return Tcl_NewStringObj("entity-is-external", -1);
-  case XML_ERR_ENTITY_IS_PARAMETER:
-    return Tcl_NewStringObj("entity-is-parameter", -1);
-  case XML_ERR_UNKNOWN_ENCODING:
-    return Tcl_NewStringObj("unknown-encoding", -1);
-  case XML_ERR_UNSUPPORTED_ENCODING:
-    return Tcl_NewStringObj("unsupported-encoding", -1);
-  case XML_ERR_STRING_NOT_STARTED:
-    return Tcl_NewStringObj("string-not-started", -1);
-  case XML_ERR_STRING_NOT_CLOSED:
-    return Tcl_NewStringObj("string-not-closed", -1);
-  case XML_ERR_NS_DECL_ERROR:
-    return Tcl_NewStringObj("namespace-declaration-error", -1);
-  case XML_ERR_ENTITY_NOT_STARTED:
-    return Tcl_NewStringObj("entity-not-started", -1);
-  case XML_ERR_ENTITY_NOT_FINISHED:
-    return Tcl_NewStringObj("entity-not-finished", -1);
-  case XML_ERR_LT_IN_ATTRIBUTE:
-    return Tcl_NewStringObj("less-than-character-in-attribute", -1);
-  case XML_ERR_ATTRIBUTE_NOT_STARTED:
-    return Tcl_NewStringObj("attribute-not-started", -1);
-  case XML_ERR_ATTRIBUTE_NOT_FINISHED:
-    return Tcl_NewStringObj("attribute-not-finished", -1);
-  case XML_ERR_ATTRIBUTE_WITHOUT_VALUE:
-    return Tcl_NewStringObj("attribute-without-value", -1);
-  case XML_ERR_ATTRIBUTE_REDEFINED:
-    return Tcl_NewStringObj("attribute-redefined", -1);
-  case XML_ERR_LITERAL_NOT_STARTED:
-    return Tcl_NewStringObj("literal-not-started", -1);
-  case XML_ERR_LITERAL_NOT_FINISHED:
-    return Tcl_NewStringObj("literal-not-finished", -1);
-  case XML_ERR_COMMENT_NOT_FINISHED:
-    return Tcl_NewStringObj("comment-not-finished", -1);
-  case XML_ERR_PI_NOT_STARTED:
-    return Tcl_NewStringObj("processing-instruction-not-started", -1);
-  case XML_ERR_PI_NOT_FINISHED:
-    return Tcl_NewStringObj("processing-instruction-not-finished", -1);
-  case XML_ERR_NOTATION_NOT_STARTED:
-    return Tcl_NewStringObj("notation-not-started", -1);
-  case XML_ERR_NOTATION_NOT_FINISHED:
-    return Tcl_NewStringObj("notation-not-finished", -1);
-  case XML_ERR_ATTLIST_NOT_STARTED:
-    return Tcl_NewStringObj("attribute-list-not-started", -1);
-  case XML_ERR_ATTLIST_NOT_FINISHED:
-    return Tcl_NewStringObj("attribute-list-not-finished", -1);
-  case XML_ERR_MIXED_NOT_STARTED:
-    return Tcl_NewStringObj("mixed-content-not-started", -1);
-  case XML_ERR_MIXED_NOT_FINISHED:
-    return Tcl_NewStringObj("mixed-content-not-finished", -1);
-  case XML_ERR_ELEMCONTENT_NOT_STARTED:
-    return Tcl_NewStringObj("element-content-not-started", -1);
-  case XML_ERR_ELEMCONTENT_NOT_FINISHED:
-    return Tcl_NewStringObj("element-content-not-finished", -1);
-  case XML_ERR_XMLDECL_NOT_STARTED:
-    return Tcl_NewStringObj("xml-declaration-not-started", -1); 
-  case XML_ERR_XMLDECL_NOT_FINISHED:
-    return Tcl_NewStringObj("xml-declaration-not-finished", -1);
-  case XML_ERR_CONDSEC_NOT_STARTED:
-    return Tcl_NewStringObj("conditional-section-not-started", -1);
-  case XML_ERR_CONDSEC_NOT_FINISHED:
-    return Tcl_NewStringObj("conditional-section-not-finished", -1);
-  case XML_ERR_EXT_SUBSET_NOT_FINISHED:
-    return Tcl_NewStringObj("external-dtd-subset-not-finished", -1);
-  case XML_ERR_DOCTYPE_NOT_FINISHED:
-    return Tcl_NewStringObj("document-type-declaration-not-finished", -1);
-  case XML_ERR_MISPLACED_CDATA_END:
-    return Tcl_NewStringObj("misplaced-cdata-section-end", -1);
-  case XML_ERR_CDATA_NOT_FINISHED:
-    return Tcl_NewStringObj("cdata-section-not-finished", -1);
-  case XML_ERR_RESERVED_XML_NAME:
-    return Tcl_NewStringObj("reserved-xml-name", -1);
-  case XML_ERR_SPACE_REQUIRED:
-    return Tcl_NewStringObj("space-required", -1);
-  case XML_ERR_SEPARATOR_REQUIRED:
-    return Tcl_NewStringObj("separator-required", -1);
-  case XML_ERR_NMTOKEN_REQUIRED:
-    return Tcl_NewStringObj("NMTOKEN-required", -1);
-  case XML_ERR_NAME_REQUIRED:
-    return Tcl_NewStringObj("NAME-required", -1);
-  case XML_ERR_PCDATA_REQUIRED:
-    return Tcl_NewStringObj("PCDATA-required", -1);
-  case XML_ERR_URI_REQUIRED:
-    return Tcl_NewStringObj("URI-required", -1);
-  case XML_ERR_PUBID_REQUIRED:
-    return Tcl_NewStringObj("public-identifier-required", -1);
-  case XML_ERR_LT_REQUIRED:
-    return Tcl_NewStringObj("less-than-character-required", -1);
-  case XML_ERR_GT_REQUIRED:
-    return Tcl_NewStringObj("greater-than-character-required", -1);
-  case XML_ERR_LTSLASH_REQUIRED:
-    return Tcl_NewStringObj("less-than-and-slash-characters-required", -1);
-  case XML_ERR_EQUAL_REQUIRED:
-    return Tcl_NewStringObj("equal-character-required", -1);
-  case XML_ERR_TAG_NAME_MISMATCH:
-    return Tcl_NewStringObj("tag-name-mismatch", -1);
-  case XML_ERR_TAG_NOT_FINISHED:
-    return Tcl_NewStringObj("tag-not-finished", -1);
-  case XML_ERR_STANDALONE_VALUE:
-    return Tcl_NewStringObj("standalone-value", -1);
-  case XML_ERR_ENCODING_NAME:
-    return Tcl_NewStringObj("encoding-name", -1);
-  case XML_ERR_HYPHEN_IN_COMMENT:
-    return Tcl_NewStringObj("hyphen-in-comment", -1);
-  case XML_ERR_INVALID_ENCODING:
-    return Tcl_NewStringObj("invalid-encoding", -1);
-  case XML_ERR_EXT_ENTITY_STANDALONE:
-    return Tcl_NewStringObj("external-entity-standalone", -1);
-  case XML_ERR_CONDSEC_INVALID:
-    return Tcl_NewStringObj("conditional-section-invalid", -1);
-  case XML_ERR_VALUE_REQUIRED:
-    return Tcl_NewStringObj("value-required", -1);
-  case XML_ERR_NOT_WELL_BALANCED:
-    return Tcl_NewStringObj("not-well-balanced", -1);
-  case XML_ERR_EXTRA_CONTENT:
-    return Tcl_NewStringObj("extra-content", -1);
-  case XML_ERR_ENTITY_CHAR_ERROR:
-    return Tcl_NewStringObj("entity-character-error", -1);
-  case XML_ERR_ENTITY_PE_INTERNAL:
-    return Tcl_NewStringObj("parameter-entity-internal-error", -1);
-  case XML_ERR_ENTITY_LOOP:
-    return Tcl_NewStringObj("entity-loop", -1);
-  case XML_ERR_ENTITY_BOUNDARY:
-    return Tcl_NewStringObj("entity-boundary", -1);
-  case XML_ERR_INVALID_URI:
-    return Tcl_NewStringObj("invalid-URI", -1);
-  case XML_ERR_URI_FRAGMENT:
-    return Tcl_NewStringObj("URI-fragment", -1);
-  case XML_WAR_CATALOG_PI:
-    return Tcl_NewStringObj("catalog-processing-instruction", -1);
-  case XML_ERR_NO_DTD:
-    return Tcl_NewStringObj("no-document-type-definition", -1);
-  case XML_ERR_CONDSEC_INVALID_KEYWORD:
-    return Tcl_NewStringObj("conditional-section-invalid-keyword", -1);
-  case XML_ERR_VERSION_MISSING:
-    return Tcl_NewStringObj("version-missing", -1);
-  case XML_WAR_UNKNOWN_VERSION:
-    return Tcl_NewStringObj("unknown-version", -1);
-  case XML_WAR_LANG_VALUE:
-    return Tcl_NewStringObj("lang-value", -1);
-  case XML_WAR_NS_URI:
-    return Tcl_NewStringObj("namespace-uri", -1);
-  case XML_WAR_NS_URI_RELATIVE:
-    return Tcl_NewStringObj("namespace-uri-relative", -1);
-  case XML_NS_ERR_XML_NAMESPACE:
-    return Tcl_NewStringObj("xml-namespace", -1);
-  case XML_NS_ERR_UNDEFINED_NAMESPACE:
-    return Tcl_NewStringObj("undefined-namespace", -1);
-  case XML_NS_ERR_QNAME:
-    return Tcl_NewStringObj("qualified-name", -1);
-  case XML_NS_ERR_ATTRIBUTE_REDEFINED:
-    return Tcl_NewStringObj("attribute-redefined", -1);
-  case XML_DTD_ATTRIBUTE_DEFAULT:
-    return Tcl_NewStringObj("attribute-default", -1);
-  case XML_DTD_ATTRIBUTE_REDEFINED:
-    return Tcl_NewStringObj("attribute-redefined", -1);
-  case XML_DTD_ATTRIBUTE_VALUE:
-    return Tcl_NewStringObj("attribute-value", -1);
-  case XML_DTD_CONTENT_ERROR:
-    return Tcl_NewStringObj("content-error", -1);
-  case XML_DTD_CONTENT_MODEL:
-    return Tcl_NewStringObj("content-model", -1);
-  case XML_DTD_CONTENT_NOT_DETERMINIST:
-    return Tcl_NewStringObj("content-model-not-deterministic", -1);
-  case XML_DTD_DIFFERENT_PREFIX:
-    return Tcl_NewStringObj("different-prefix", -1);
-  case XML_DTD_ELEM_DEFAULT_NAMESPACE:
-    return Tcl_NewStringObj("element-default-namespace", -1);
-  case XML_DTD_ELEM_NAMESPACE:
-    return Tcl_NewStringObj("element-namespace", -1);
-  case XML_DTD_ELEM_REDEFINED:
-    return Tcl_NewStringObj("element-type-redefined", -1);
-  case XML_DTD_EMPTY_NOTATION:
-    return Tcl_NewStringObj("empty-notation", -1);
-  case XML_DTD_ENTITY_TYPE:
-    return Tcl_NewStringObj("entity-type", -1);
-  case XML_DTD_ID_FIXED:
-    return Tcl_NewStringObj("ID-fixed", -1);
-  case XML_DTD_ID_REDEFINED:
-    return Tcl_NewStringObj("ID-redefined", -1);
-  case XML_DTD_ID_SUBSET:
-    return Tcl_NewStringObj("ID-subset", -1);
-  case XML_DTD_INVALID_CHILD:
-    return Tcl_NewStringObj("invalid-child", -1);
-  case XML_DTD_INVALID_DEFAULT:
-    return Tcl_NewStringObj("invalid-default", -1);
-  case XML_DTD_LOAD_ERROR:
-    return Tcl_NewStringObj("load-error", -1);
-  case XML_DTD_MISSING_ATTRIBUTE:
-    return Tcl_NewStringObj("missing-attribute", -1);
-  case XML_DTD_MIXED_CORRUPT:
-    return Tcl_NewStringObj("mixed-content-corrupt", -1);
-  case XML_DTD_MULTIPLE_ID:
-    return Tcl_NewStringObj("multiple-ID", -1);
-  case XML_DTD_NO_DOC:
-    return Tcl_NewStringObj("no-document", -1);
-  case XML_DTD_NO_DTD:
-    return Tcl_NewStringObj("no-document-type-definition", -1);
-  case XML_DTD_NO_ELEM_NAME:
-    return Tcl_NewStringObj("no-element-name", -1);
-  case XML_DTD_NO_PREFIX:
-    return Tcl_NewStringObj("no-prefix", -1);
-  case XML_DTD_NO_ROOT:
-    return Tcl_NewStringObj("no-root", -1);
-  case XML_DTD_NOTATION_REDEFINED:
-    return Tcl_NewStringObj("notation-redefined", -1);
-  case XML_DTD_NOTATION_VALUE:
-    return Tcl_NewStringObj("notation-value", -1);
-  case XML_DTD_NOT_EMPTY:
-    return Tcl_NewStringObj("not-empty", -1);
-  case XML_DTD_NOT_PCDATA:
-    return Tcl_NewStringObj("not-PCDATA", -1);
-  case XML_DTD_NOT_STANDALONE:
-    return Tcl_NewStringObj("not-standalone", -1);
-  case XML_DTD_ROOT_NAME:
-    return Tcl_NewStringObj("root-name", -1);
-  case XML_DTD_STANDALONE_WHITE_SPACE:
-    return Tcl_NewStringObj("standalone-white-space", -1);
-  case XML_DTD_UNKNOWN_ATTRIBUTE:
-    return Tcl_NewStringObj("unknown-attribute", -1);
-  case XML_DTD_UNKNOWN_ELEM:
-    return Tcl_NewStringObj("unknown-element-type", -1);
-  case XML_DTD_UNKNOWN_ENTITY:
-    return Tcl_NewStringObj("unknown-entity", -1);
-  case XML_DTD_UNKNOWN_ID:
-    return Tcl_NewStringObj("unknown-ID", -1);
-  case XML_DTD_UNKNOWN_NOTATION:
-    return Tcl_NewStringObj("unknown-notation", -1);
-  case XML_HTML_STRUCURE_ERROR:
-    return Tcl_NewStringObj("structure-error", -1);
-  case XML_HTML_UNKNOWN_TAG:
-    return Tcl_NewStringObj("unknown-tag", -1);
-  case XML_RNGP_ANYNAME_ATTR_ANCESTOR:
-    return Tcl_NewStringObj("anyname-attribute-ancestor", -1);
-  case XML_RNGP_ATTR_CONFLICT:
-    return Tcl_NewStringObj("attribute-conflict", -1);
-  case XML_RNGP_ATTRIBUTE_CHILDREN:
-    return Tcl_NewStringObj("attribute-children", -1);
-  case XML_RNGP_ATTRIBUTE_CONTENT:
-    return Tcl_NewStringObj("attribute-content", -1);
-  case XML_RNGP_ATTRIBUTE_EMPTY:
-    return Tcl_NewStringObj("attribute-empty", -1);
-  case XML_RNGP_ATTRIBUTE_NOOP:
-    return Tcl_NewStringObj("attribute-noop", -1);
-  case XML_RNGP_CHOICE_CONTENT:
-    return Tcl_NewStringObj("choice-content", -1);
-  case XML_RNGP_CREATE_FAILURE:
-    return Tcl_NewStringObj("create-failure", -1);
-  case XML_RNGP_DATA_CONTENT:
-    return Tcl_NewStringObj("data-content", -1);
-  case XML_RNGP_DEF_CHOICE_AND_INTERLEAVE:
-    return Tcl_NewStringObj("def-choice-and-interleave", -1);
-  case XML_RNGP_DEFINE_CREATE_FAILED:
-    return Tcl_NewStringObj("define-create-failed", -1);
-  case XML_RNGP_DEFINE_EMPTY:
-    return Tcl_NewStringObj("define-empty", -1);
-  case XML_RNGP_DEFINE_MISSING:
-    return Tcl_NewStringObj("define-missing", -1);
-  case XML_RNGP_DEFINE_NAME_MISSING:
-    return Tcl_NewStringObj("define-name-missing", -1);
-  case XML_RNGP_ELEM_CONTENT_EMPTY:
-    return Tcl_NewStringObj("elem-content-empty", -1);
-  case XML_RNGP_ELEM_CONTENT_ERROR:
-    return Tcl_NewStringObj("elem-content-error", -1);
-  case XML_RNGP_ELEMENT_EMPTY:
-    return Tcl_NewStringObj("element-empty", -1);
-  case XML_RNGP_ELEMENT_CONTENT:
-    return Tcl_NewStringObj("element-content", -1);
-  case XML_RNGP_ELEMENT_NAME:
-    return Tcl_NewStringObj("element-name", -1);
-  case XML_RNGP_ELEMENT_NO_CONTENT:
-    return Tcl_NewStringObj("element-no-content", -1);
-  case XML_RNGP_ELEM_TEXT_CONFLICT:
-    return Tcl_NewStringObj("element-text-conflict", -1);
-  case XML_RNGP_EMPTY:
-    return Tcl_NewStringObj("empty", -1);
-  case XML_RNGP_EMPTY_CONSTRUCT:
-    return Tcl_NewStringObj("empty-construct", -1);
-  case XML_RNGP_EMPTY_CONTENT:
-    return Tcl_NewStringObj("empty-content", -1);
-  case XML_RNGP_EMPTY_NOT_EMPTY:
-    return Tcl_NewStringObj("empty-not-empty", -1);
-  case XML_RNGP_ERROR_TYPE_LIB:
-    return Tcl_NewStringObj("error-type-library", -1);
-  case XML_RNGP_EXCEPT_EMPTY:
-    return Tcl_NewStringObj("except-empty", -1);
-  case XML_RNGP_EXCEPT_MISSING:
-    return Tcl_NewStringObj("except-missing", -1);
-  case XML_RNGP_EXCEPT_MULTIPLE:
-    return Tcl_NewStringObj("except-multiple", -1);
-  case XML_RNGP_EXCEPT_NO_CONTENT:
-    return Tcl_NewStringObj("except-no-content", -1);
-  case XML_RNGP_EXTERNALREF_EMTPY:
-    return Tcl_NewStringObj("external-reference-empty", -1);
-  case XML_RNGP_EXTERNAL_REF_FAILURE:
-    return Tcl_NewStringObj("external-reference-failure", -1);
-  case XML_RNGP_EXTERNALREF_RECURSE:
-    return Tcl_NewStringObj("external-reference-recursive", -1);
-  case XML_RNGP_FORBIDDEN_ATTRIBUTE:
-    return Tcl_NewStringObj("forbidden-attribute", -1);
-  case XML_RNGP_FOREIGN_ELEMENT:
-    return Tcl_NewStringObj("foreign-element", -1);
-  case XML_RNGP_GRAMMAR_CONTENT:
-    return Tcl_NewStringObj("grammar-content", -1);
-  case XML_RNGP_GRAMMAR_EMPTY:
-    return Tcl_NewStringObj("grammar-empty", -1);
-  case XML_RNGP_GRAMMAR_MISSING:
-    return Tcl_NewStringObj("grammar-missing", -1);
-  case XML_RNGP_GRAMMAR_NO_START:
-    return Tcl_NewStringObj("grammar-no-start", -1);
-  case XML_RNGP_GROUP_ATTR_CONFLICT:
-    return Tcl_NewStringObj("group-attribute-conflict-", -1);
-  case XML_RNGP_HREF_ERROR:
-    return Tcl_NewStringObj("href-error", -1);
-  case XML_RNGP_INCLUDE_EMPTY:
-    return Tcl_NewStringObj("include-empty", -1);
-  case XML_RNGP_INCLUDE_FAILURE:
-    return Tcl_NewStringObj("include-failure", -1);
-  case XML_RNGP_INCLUDE_RECURSE:
-    return Tcl_NewStringObj("include-recurse", -1);
-  case XML_RNGP_INTERLEAVE_ADD:
-    return Tcl_NewStringObj("interleave-add", -1);
-  case XML_RNGP_INTERLEAVE_CREATE_FAILED:
-    return Tcl_NewStringObj("interleave-create-failed", -1);
-  case XML_RNGP_INTERLEAVE_EMPTY:
-    return Tcl_NewStringObj("interleave-empty", -1);
-  case XML_RNGP_INTERLEAVE_NO_CONTENT:
-    return Tcl_NewStringObj("interleave-no-content", -1);
-  case XML_RNGP_INVALID_DEFINE_NAME:
-    return Tcl_NewStringObj("invalid-define-name", -1);
-  case XML_RNGP_INVALID_URI:
-    return Tcl_NewStringObj("invalid-URI", -1);
-  case XML_RNGP_INVALID_VALUE:
-    return Tcl_NewStringObj("invalid-value", -1);
-  case XML_RNGP_MISSING_HREF:
-    return Tcl_NewStringObj("missing-href", -1);
-  case XML_RNGP_NAME_MISSING:
-    return Tcl_NewStringObj("NAME-missing", -1);
-  case XML_RNGP_NEED_COMBINE:
-    return Tcl_NewStringObj("need-combine", -1);
-  case XML_RNGP_NOTALLOWED_NOT_EMPTY:
-    return Tcl_NewStringObj("notallowed-not-empty", -1);
-  case XML_RNGP_NSNAME_ATTR_ANCESTOR:
-    return Tcl_NewStringObj("nsname-attr-ancestor", -1);
-  case XML_RNGP_NSNAME_NO_NS:
-    return Tcl_NewStringObj("nsname-no-namespace", -1);
-  case XML_RNGP_PARAM_FORBIDDEN:
-    return Tcl_NewStringObj("param-forbidden", -1);
-  case XML_RNGP_PARAM_NAME_MISSING:
-    return Tcl_NewStringObj("param-name-missing", -1);
-  case XML_RNGP_PARENTREF_CREATE_FAILED:
-    return Tcl_NewStringObj("parentref-create-failed", -1);
-  case XML_RNGP_PARENTREF_NAME_INVALID:
-    return Tcl_NewStringObj("parentref-name-invalid", -1);
-  case XML_RNGP_PARENTREF_NO_NAME:
-    return Tcl_NewStringObj("parentref-no-name", -1);
-  case XML_RNGP_PARENTREF_NO_PARENT:
-    return Tcl_NewStringObj("parentref-no-parent", -1);
-  case XML_RNGP_PARENTREF_NOT_EMPTY:
-    return Tcl_NewStringObj("parentref-not-empty", -1);
-  case XML_RNGP_PARSE_ERROR:
-    return Tcl_NewStringObj("parse-error", -1);
-  case XML_RNGP_PAT_ANYNAME_EXCEPT_ANYNAME:
-    return Tcl_NewStringObj("pat-anyname-except-anyname", -1);
-  case XML_RNGP_PAT_ATTR_ATTR:
-    return Tcl_NewStringObj("par-attr-attr", -1);
-  case XML_RNGP_PAT_ATTR_ELEM:
-    return Tcl_NewStringObj("pat-attr-elem", -1);
-  case XML_RNGP_PAT_DATA_EXCEPT_ATTR:
-    return Tcl_NewStringObj("pat-data-except-attr", -1);
-  case XML_RNGP_PAT_DATA_EXCEPT_ELEM:
-    return Tcl_NewStringObj("pat-data-except-elem", -1);
-  case XML_RNGP_PAT_DATA_EXCEPT_EMPTY:
-    return Tcl_NewStringObj("pat-data-except-empty", -1);
-  case XML_RNGP_PAT_DATA_EXCEPT_GROUP:
-    return Tcl_NewStringObj("pat-data-except-group", -1);
-  case XML_RNGP_PAT_DATA_EXCEPT_INTERLEAVE:
-    return Tcl_NewStringObj("pat-data-except-interleave", -1);
-  case XML_RNGP_PAT_DATA_EXCEPT_LIST:
-    return Tcl_NewStringObj("pat-data-except-list", -1);
-  case XML_RNGP_PAT_DATA_EXCEPT_ONEMORE:
-    return Tcl_NewStringObj("pat-data-except-onemore", -1);
-  case XML_RNGP_PAT_DATA_EXCEPT_REF:
-    return Tcl_NewStringObj("pat-data-except-ref", -1);
-  case XML_RNGP_PAT_DATA_EXCEPT_TEXT:
-    return Tcl_NewStringObj("pat-data-except-text", -1);
-  case XML_RNGP_PAT_LIST_ATTR:
-    return Tcl_NewStringObj("pat-list-attr", -1);
-  case XML_RNGP_PAT_LIST_ELEM:
-    return Tcl_NewStringObj("pat-list-elem", -1);
-  case XML_RNGP_PAT_LIST_INTERLEAVE:
-    return Tcl_NewStringObj("pat-list-interleave", -1);
-  case XML_RNGP_PAT_LIST_LIST:
-    return Tcl_NewStringObj("pat-list-list", -1);
-  case XML_RNGP_PAT_LIST_REF:
-    return Tcl_NewStringObj("pat-list-ref", -1);
-  case XML_RNGP_PAT_LIST_TEXT:
-    return Tcl_NewStringObj("pat-list-text", -1);
-  case XML_RNGP_PAT_NSNAME_EXCEPT_ANYNAME:
-    return Tcl_NewStringObj("pat-nsname-except-anyname", -1);
-  case XML_RNGP_PAT_NSNAME_EXCEPT_NSNAME:
-    return Tcl_NewStringObj("pat-nsname-except-nsname", -1);
-  case XML_RNGP_PAT_ONEMORE_GROUP_ATTR:
-    return Tcl_NewStringObj("pat-onemore-group-attr", -1);
-  case XML_RNGP_PAT_ONEMORE_INTERLEAVE_ATTR:
-    return Tcl_NewStringObj("pat-onemore-interleave-attr", -1);
-  case XML_RNGP_PAT_START_ATTR:
-    return Tcl_NewStringObj("pat-start-attr", -1);
-  case XML_RNGP_PAT_START_DATA:
-    return Tcl_NewStringObj("pat-start-data", -1);
-  case XML_RNGP_PAT_START_EMPTY:
-    return Tcl_NewStringObj("pat-start-empty", -1);
-  case XML_RNGP_PAT_START_GROUP:
-    return Tcl_NewStringObj("pat-start-group", -1);
-  case XML_RNGP_PAT_START_INTERLEAVE:
-    return Tcl_NewStringObj("pat-start-interleave", -1);
-  case XML_RNGP_PAT_START_LIST:
-    return Tcl_NewStringObj("pat-start-list", -1);
-  case XML_RNGP_PAT_START_ONEMORE:
-    return Tcl_NewStringObj("pat-start-onemore", -1);
-  case XML_RNGP_PAT_START_TEXT:
-    return Tcl_NewStringObj("pat-start-text", -1);
-  case XML_RNGP_PAT_START_VALUE:
-    return Tcl_NewStringObj("pat-start-value", -1);
-  case XML_RNGP_PREFIX_UNDEFINED:
-    return Tcl_NewStringObj("prefix-undefined", -1);
-  case XML_RNGP_REF_CREATE_FAILED:
-    return Tcl_NewStringObj("ref-create-failed", -1);
-  case XML_RNGP_REF_CYCLE:
-    return Tcl_NewStringObj("ref-cycle", -1);
-  case XML_RNGP_REF_NAME_INVALID:
-    return Tcl_NewStringObj("ref-name-invalid", -1);
-  case XML_RNGP_REF_NO_DEF:
-    return Tcl_NewStringObj("ref-no-def", -1);
-  case XML_RNGP_REF_NO_NAME:
-    return Tcl_NewStringObj("ref-no-name", -1);
-  case XML_RNGP_REF_NOT_EMPTY:
-    return Tcl_NewStringObj("ref-not-empty", -1);
-  case XML_RNGP_START_CHOICE_AND_INTERLEAVE:
-    return Tcl_NewStringObj("start-choice-and-interleave", -1);
-  case XML_RNGP_START_CONTENT:
-    return Tcl_NewStringObj("start-content", -1);
-  case XML_RNGP_START_EMPTY:
-    return Tcl_NewStringObj("start-empty", -1);
-  case XML_RNGP_START_MISSING:
-    return Tcl_NewStringObj("start-missing", -1);
-  case XML_RNGP_TEXT_EXPECTED:
-    return Tcl_NewStringObj("text-expected", -1);
-  case XML_RNGP_TEXT_HAS_CHILD:
-    return Tcl_NewStringObj("text-has-child", -1);
-  case XML_RNGP_TYPE_MISSING:
-    return Tcl_NewStringObj("type-missing", -1);
-  case XML_RNGP_TYPE_NOT_FOUND:
-    return Tcl_NewStringObj("type-not-found", -1);
-  case XML_RNGP_UNKNOWN_ATTRIBUTE:
-    return Tcl_NewStringObj("unknown-attribute", -1);
-  case XML_RNGP_UNKNOWN_COMBINE:
-    return Tcl_NewStringObj("unknown-combine", -1);
-  case XML_RNGP_UNKNOWN_CONSTRUCT:
-    return Tcl_NewStringObj("unknown-construct", -1);
-  case XML_RNGP_UNKNOWN_TYPE_LIB:
-    return Tcl_NewStringObj("unknown-type-lib", -1);
-  case XML_RNGP_URI_FRAGMENT:
-    return Tcl_NewStringObj("URI-fragment", -1);
-  case XML_RNGP_URI_NOT_ABSOLUTE:
-    return Tcl_NewStringObj("URI-not-absolute", -1);
-  case XML_RNGP_VALUE_EMPTY:
-    return Tcl_NewStringObj("value-empty", -1);
-  case XML_RNGP_VALUE_NO_CONTENT:
-    return Tcl_NewStringObj("value-no-content", -1);
-  case XML_RNGP_XMLNS_NAME:
-    return Tcl_NewStringObj("xmlns-name", -1);
-  case XML_RNGP_XML_NS:
-    return Tcl_NewStringObj("xml-ns", -1);
-  case XML_XPATH_EXPRESSION_OK:
-    return Tcl_NewStringObj("expression-ok", -1);
-  case XML_XPATH_NUMBER_ERROR:
-    return Tcl_NewStringObj("number-error", -1);
-  case XML_XPATH_UNFINISHED_LITERAL_ERROR:
-    return Tcl_NewStringObj("unfinished-literal", -1);
-  case XML_XPATH_START_LITERAL_ERROR:
-    return Tcl_NewStringObj("start-literal", -1);
-  case XML_XPATH_VARIABLE_REF_ERROR:
-    return Tcl_NewStringObj("variable-reference", -1);
-  case XML_XPATH_UNDEF_VARIABLE_ERROR:
-    return Tcl_NewStringObj("undefined-variable", -1);
-  case XML_XPATH_INVALID_PREDICATE_ERROR:
-    return Tcl_NewStringObj("invalid-predicate", -1);
-  case XML_XPATH_EXPR_ERROR:
-    return Tcl_NewStringObj("expression-error", -1);
-  case XML_XPATH_UNCLOSED_ERROR:
-    return Tcl_NewStringObj("unclosed", -1);
-  case XML_XPATH_UNKNOWN_FUNC_ERROR:
-    return Tcl_NewStringObj("unknown-function", -1);
-  case XML_XPATH_INVALID_OPERAND:
-    return Tcl_NewStringObj("invalid-operand", -1);
-  case XML_XPATH_INVALID_TYPE:
-    return Tcl_NewStringObj("invalid-type", -1);
-  case XML_XPATH_INVALID_ARITY:
-    return Tcl_NewStringObj("invalid-arity", -1);
-  case XML_XPATH_INVALID_CTXT_SIZE:
-    return Tcl_NewStringObj("invalid-context-size", -1);
-  case XML_XPATH_INVALID_CTXT_POSITION:
-    return Tcl_NewStringObj("invalid-context-position", -1);
-  case XML_XPATH_MEMORY_ERROR:
-    return Tcl_NewStringObj("memory-error", -1);
-  case XML_XPTR_SYNTAX_ERROR:
-    return Tcl_NewStringObj("syntax-error", -1);
-  case XML_XPTR_RESOURCE_ERROR:
-    return Tcl_NewStringObj("resource-error", -1);
-  case XML_XPTR_SUB_RESOURCE_ERROR:
-    return Tcl_NewStringObj("sub-resource-error", -1);
-  case XML_XPATH_UNDEF_PREFIX_ERROR:
-    return Tcl_NewStringObj("undefined-prefix", -1);
-  case XML_XPATH_ENCODING_ERROR:
-    return Tcl_NewStringObj("encoding-error", -1);
-  case XML_XPATH_INVALID_CHAR_ERROR:
-    return Tcl_NewStringObj("invalid-character", -1);
-  case XML_TREE_INVALID_HEX:
-    return Tcl_NewStringObj("invalid-hex", -1);
-  case XML_TREE_INVALID_DEC:
-    return Tcl_NewStringObj("invalid-decimal", -1);
-  case XML_TREE_UNTERMINATED_ENTITY:
-    return Tcl_NewStringObj("unterminated-entity", -1);
-  case XML_SAVE_NOT_UTF8:
-    return Tcl_NewStringObj("not-utf8", -1);
-  case XML_SAVE_CHAR_INVALID:
-    return Tcl_NewStringObj("invalid-character", -1);
-  case XML_SAVE_NO_DOCTYPE:
-    return Tcl_NewStringObj("no-document-type-declaration", -1);
-  case XML_SAVE_UNKNOWN_ENCODING:
-    return Tcl_NewStringObj("unknown-encoding", -1);
-  case XML_REGEXP_COMPILE_ERROR:
-    return Tcl_NewStringObj("compile-error", -1);
-  case XML_IO_UNKNOWN:
-    return Tcl_NewStringObj("unknown", -1);
-  case XML_IO_EACCES:
-    return Tcl_NewStringObj("eacces", -1);
-  case XML_IO_EAGAIN:
-    return Tcl_NewStringObj("eagain", -1);
-  case XML_IO_EBADF:
-    return Tcl_NewStringObj("ebadf", -1);
-  case XML_IO_EBADMSG:
-    return Tcl_NewStringObj("ebadmsg", -1);
-  case XML_IO_EBUSY:
-    return Tcl_NewStringObj("ebusy", -1);
-  case XML_IO_ECANCELED:
-    return Tcl_NewStringObj("ecanceled", -1);
-  case XML_IO_ECHILD:
-    return Tcl_NewStringObj("echild", -1);
-  case XML_IO_EDEADLK:
-    return Tcl_NewStringObj("edeadlk", -1);
-  case XML_IO_EDOM:
-    return Tcl_NewStringObj("edom", -1);
-  case XML_IO_EEXIST:
-    return Tcl_NewStringObj("eexist", -1);
-  case XML_IO_EINPROGRESS:
-    return Tcl_NewStringObj("einprogress", -1);
-  case XML_IO_EINTR:
-    return Tcl_NewStringObj("eintr", -1);
-  case XML_IO_EINVAL:
-    return Tcl_NewStringObj("einval", -1);
-  case XML_IO_EIO:
-    return Tcl_NewStringObj("eio", -1);
-  case XML_IO_EISDIR:
-    return Tcl_NewStringObj("eisdir", -1);
-  case XML_IO_EMFILE:
-    return Tcl_NewStringObj("emfile", -1);
-  case XML_IO_EMLINK:
-    return Tcl_NewStringObj("emlink", -1);
-  case XML_IO_EMSGSIZE:
-    return Tcl_NewStringObj("emsgsize", -1);
-  case XML_IO_ENAMETOOLONG:
-    return Tcl_NewStringObj("enametoolong", -1);
-  case XML_IO_ENFILE:
-    return Tcl_NewStringObj("enfile", -1);
-  case XML_IO_ENODEV:
-    return Tcl_NewStringObj("enodev", -1);
-  case XML_IO_ENOENT:
-    return Tcl_NewStringObj("enoent", -1);
-  case XML_IO_ENOEXEC:
-    return Tcl_NewStringObj("enoexec", -1);
-  case XML_IO_ENOLCK:
-    return Tcl_NewStringObj("enolck", -1);
-  case XML_IO_ENOMEM:
-    return Tcl_NewStringObj("enomem", -1);
-  case XML_IO_ENOSPC:
-    return Tcl_NewStringObj("enospc", -1);
-  case XML_IO_ENOSYS:
-    return Tcl_NewStringObj("enosys", -1);
-  case XML_IO_ENOTDIR:
-    return Tcl_NewStringObj("enotdir", -1);
-  case XML_IO_ENOTEMPTY:
-    return Tcl_NewStringObj("enotempty", -1);
-  case XML_IO_ENOTSUP:
-    return Tcl_NewStringObj("enotsup", -1);
-  case XML_IO_ENOTTY:
-    return Tcl_NewStringObj("enotty", -1);
-  case XML_IO_ENXIO:
-    return Tcl_NewStringObj("enxio", -1);
-  case XML_IO_EPERM:
-    return Tcl_NewStringObj("eperm", -1);
-  case XML_IO_EPIPE:
-    return Tcl_NewStringObj("epipe", -1);
-  case XML_IO_ERANGE:
-    return Tcl_NewStringObj("erange", -1);
-  case XML_IO_EROFS:
-    return Tcl_NewStringObj("erofs", -1);
-  case XML_IO_ESPIPE:
-    return Tcl_NewStringObj("espipe", -1);
-  case XML_IO_ESRCH:
-    return Tcl_NewStringObj("esrch", -1);
-  case XML_IO_ETIMEDOUT:
-    return Tcl_NewStringObj("etimedout", -1);
-  case XML_IO_EXDEV:
-    return Tcl_NewStringObj("exdev", -1);
-  case XML_IO_NETWORK_ATTEMPT:
-    return Tcl_NewStringObj("network-attempt", -1);
-  case XML_IO_ENCODER:
-    return Tcl_NewStringObj("encoder", -1);
-  case XML_IO_FLUSH:
-    return Tcl_NewStringObj("flush", -1);
-  case XML_IO_WRITE:
-    return Tcl_NewStringObj("write", -1);
-  case XML_IO_NO_INPUT:
-    return Tcl_NewStringObj("no-input", -1);
-  case XML_IO_BUFFER_FULL:
-    return Tcl_NewStringObj("buffer-full", -1);
-  case XML_IO_LOAD_ERROR:
-    return Tcl_NewStringObj("load-error", -1);
-  case XML_IO_ENOTSOCK:
-    return Tcl_NewStringObj("enotsock", -1);
-  case XML_IO_EISCONN:
-    return Tcl_NewStringObj("eisconn", -1);
-  case XML_IO_ECONNREFUSED:
-    return Tcl_NewStringObj("econnrefused", -1);
-  case XML_IO_ENETUNREACH:
-    return Tcl_NewStringObj("enetunreach", -1);
-  case XML_IO_EADDRINUSE:
-    return Tcl_NewStringObj("eaddrinuse", -1);
-  case XML_IO_EALREADY:
-    return Tcl_NewStringObj("ealready", -1);
-  case XML_IO_EAFNOSUPPORT:
-    return Tcl_NewStringObj("eafnosupport", -1);
-  case XML_XINCLUDE_RECURSION:
-    return Tcl_NewStringObj("recursion", -1);
-  case XML_XINCLUDE_PARSE_VALUE:
-    return Tcl_NewStringObj("parse-value", -1);
-  case XML_XINCLUDE_ENTITY_DEF_MISMATCH:
-    return Tcl_NewStringObj("entity-def-mismatch", -1);
-  case XML_XINCLUDE_NO_HREF:
-    return Tcl_NewStringObj("no-href", -1);
-  case XML_XINCLUDE_NO_FALLBACK:
-    return Tcl_NewStringObj("no-fallback", -1);
-  case XML_XINCLUDE_HREF_URI:
-    return Tcl_NewStringObj("href-URI", -1);
-  case XML_XINCLUDE_TEXT_FRAGMENT:
-    return Tcl_NewStringObj("text-fragment", -1);
-  case XML_XINCLUDE_TEXT_DOCUMENT:
-    return Tcl_NewStringObj("text-document", -1);
-  case XML_XINCLUDE_INVALID_CHAR:
-    return Tcl_NewStringObj("invalid-character", -1);
-  case XML_XINCLUDE_BUILD_FAILED:
-    return Tcl_NewStringObj("build-failed", -1);
-  case XML_XINCLUDE_UNKNOWN_ENCODING:
-    return Tcl_NewStringObj("unknown-encoding", -1);
-  case XML_XINCLUDE_MULTIPLE_ROOT:
-    return Tcl_NewStringObj("multiple-root", -1);
-  case XML_XINCLUDE_XPTR_FAILED:
-    return Tcl_NewStringObj("XPointer-failed", -1);
-  case XML_XINCLUDE_XPTR_RESULT:
-    return Tcl_NewStringObj("XPointer-result", -1);
-  case XML_XINCLUDE_INCLUDE_IN_INCLUDE:
-    return Tcl_NewStringObj("include-in-include", -1);
-  case XML_XINCLUDE_FALLBACKS_IN_INCLUDE:
-    return Tcl_NewStringObj("fallbacks-in-include", -1);
-  case XML_XINCLUDE_FALLBACK_NOT_IN_INCLUDE:
-    return Tcl_NewStringObj("fallback-not-in-include", -1);
-  case XML_CATALOG_MISSING_ATTR:
-    return Tcl_NewStringObj("missing-attribute", -1);
-  case XML_CATALOG_ENTRY_BROKEN:
-    return Tcl_NewStringObj("entry-broken", -1);
-  case XML_CATALOG_PREFER_VALUE:
-    return Tcl_NewStringObj("prefer-value", -1);
-  case XML_CATALOG_NOT_CATALOG:
-    return Tcl_NewStringObj("not-catalog", -1);
-  case XML_CATALOG_RECURSION:
-    return Tcl_NewStringObj("recursion", -1);
-  case XML_SCHEMAP_PREFIX_UNDEFINED:
-    return Tcl_NewStringObj("prefix-undefined", -1);
-  case XML_SCHEMAP_ATTRFORMDEFAULT_VALUE:
-    return Tcl_NewStringObj("attribute-form-default-value", -1);
-  case XML_SCHEMAP_ATTRGRP_NONAME_NOREF:
-    return Tcl_NewStringObj("attribute-group-noname-noref", -1);
-  case XML_SCHEMAP_ATTR_NONAME_NOREF:
-    return Tcl_NewStringObj("attribute-noname-noref", -1);
-  case XML_SCHEMAP_COMPLEXTYPE_NONAME_NOREF:
-    return Tcl_NewStringObj("complexType-noname-noref", -1);
-  case XML_SCHEMAP_ELEMFORMDEFAULT_VALUE:
-    return Tcl_NewStringObj("element-form-default-value", -1);
-  case XML_SCHEMAP_ELEM_NONAME_NOREF:
-    return Tcl_NewStringObj("element-noname-noref", -1);
-  case XML_SCHEMAP_EXTENSION_NO_BASE:
-    return Tcl_NewStringObj("extension-no-base", -1);
-  case XML_SCHEMAP_FACET_NO_VALUE:
-    return Tcl_NewStringObj("facet-no-value", -1);
-  case XML_SCHEMAP_FAILED_BUILD_IMPORT:
-    return Tcl_NewStringObj("failed-build-import", -1);
-  case XML_SCHEMAP_GROUP_NONAME_NOREF:
-    return Tcl_NewStringObj("group-noname-noref", -1);
-  case XML_SCHEMAP_IMPORT_NAMESPACE_NOT_URI:
-    return Tcl_NewStringObj("import-namespace-not-URI", -1);
-  case XML_SCHEMAP_IMPORT_REDEFINE_NSNAME:
-    return Tcl_NewStringObj("import-redefine-nsname", -1);
-  case XML_SCHEMAP_IMPORT_SCHEMA_NOT_URI:
-    return Tcl_NewStringObj("import-schema-not-URI", -1);
-  case XML_SCHEMAP_INVALID_BOOLEAN:
-    return Tcl_NewStringObj("invalid-boolean", -1);
-  case XML_SCHEMAP_INVALID_ENUM:
-    return Tcl_NewStringObj("invalid-enumeration", -1);
-  case XML_SCHEMAP_INVALID_FACET:
-    return Tcl_NewStringObj("invalid-facet", -1);
-  case XML_SCHEMAP_INVALID_FACET_VALUE:
-    return Tcl_NewStringObj("invalid-facet-value", -1);
-  case XML_SCHEMAP_INVALID_MAXOCCURS:
-    return Tcl_NewStringObj("invalid-maxOccurs", -1);
-  case XML_SCHEMAP_INVALID_MINOCCURS:
-    return Tcl_NewStringObj("invalid-minOccurs", -1);
-  case XML_SCHEMAP_INVALID_REF_AND_SUBTYPE:
-    return Tcl_NewStringObj("invalid-ref-and-subtype", -1);
-  case XML_SCHEMAP_INVALID_WHITE_SPACE:
-    return Tcl_NewStringObj("invalid-white-space", -1);
-  case XML_SCHEMAP_NOATTR_NOREF:
-    return Tcl_NewStringObj("noattr-noref", -1);
-  case XML_SCHEMAP_NOTATION_NO_NAME:
-    return Tcl_NewStringObj("notation-no-name", -1);
-  case XML_SCHEMAP_NOTYPE_NOREF:
-    return Tcl_NewStringObj("notype-noref", -1);
-  case XML_SCHEMAP_REF_AND_SUBTYPE:
-    return Tcl_NewStringObj("ref-and-subtype", -1);
-  case XML_SCHEMAP_RESTRICTION_NONAME_NOREF:
-    return Tcl_NewStringObj("restriction-noname-noref", -1);
-  case XML_SCHEMAP_SIMPLETYPE_NONAME:
-    return Tcl_NewStringObj("simpleType-noname", -1);
-  case XML_SCHEMAP_TYPE_AND_SUBTYPE:
-    return Tcl_NewStringObj("type-and-subtype", -1);
-  case XML_SCHEMAP_UNKNOWN_ALL_CHILD:
-    return Tcl_NewStringObj("unknown-all-child", -1);
-  case XML_SCHEMAP_UNKNOWN_ANYATTRIBUTE_CHILD:
-    return Tcl_NewStringObj("unknown-anyattribute-child", -1);
-  case XML_SCHEMAP_UNKNOWN_ATTR_CHILD:
-    return Tcl_NewStringObj("unknown-attribute-child", -1);
-  case XML_SCHEMAP_UNKNOWN_ATTRGRP_CHILD:
-    return Tcl_NewStringObj("unknown-attributeGroup-child", -1);
-  case XML_SCHEMAP_UNKNOWN_ATTRIBUTE_GROUP:
-    return Tcl_NewStringObj("unknown-attributeGroup", -1);
-  case XML_SCHEMAP_UNKNOWN_BASE_TYPE:
-    return Tcl_NewStringObj("unknown-base-type", -1);
-  case XML_SCHEMAP_UNKNOWN_CHOICE_CHILD:
-    return Tcl_NewStringObj("unknown-choice-child", -1);
-  case XML_SCHEMAP_UNKNOWN_COMPLEXCONTENT_CHILD:
-    return Tcl_NewStringObj("unknown-complexContent-child", -1);
-  case XML_SCHEMAP_UNKNOWN_COMPLEXTYPE_CHILD:
-    return Tcl_NewStringObj("unknown-complexType-child", -1);
-  case XML_SCHEMAP_UNKNOWN_ELEM_CHILD:
-    return Tcl_NewStringObj("unknown-element-child", -1);
-  case XML_SCHEMAP_UNKNOWN_EXTENSION_CHILD:
-    return Tcl_NewStringObj("unknown-extension-child", -1);
-  case XML_SCHEMAP_UNKNOWN_FACET_CHILD:
-    return Tcl_NewStringObj("unknown-facet-child", -1);
-  case XML_SCHEMAP_UNKNOWN_FACET_TYPE:
-    return Tcl_NewStringObj("unknown-facet-type", -1);
-  case XML_SCHEMAP_UNKNOWN_GROUP_CHILD:
-    return Tcl_NewStringObj("unknown-group-child", -1);
-  case XML_SCHEMAP_UNKNOWN_IMPORT_CHILD:
-    return Tcl_NewStringObj("unknown-import-child", -1);
-  case XML_SCHEMAP_UNKNOWN_LIST_CHILD:
-    return Tcl_NewStringObj("unknown-list-child", -1);
-  case XML_SCHEMAP_UNKNOWN_NOTATION_CHILD:
-    return Tcl_NewStringObj("unknown-notation-child", -1);
-  case XML_SCHEMAP_UNKNOWN_PROCESSCONTENT_CHILD:
-    return Tcl_NewStringObj("unknown-processContent-child", -1);
-  case XML_SCHEMAP_UNKNOWN_REF:
-    return Tcl_NewStringObj("unknown-ref", -1);
-  case XML_SCHEMAP_UNKNOWN_RESTRICTION_CHILD:
-    return Tcl_NewStringObj("unknown-restriction-child", -1);
-  case XML_SCHEMAP_UNKNOWN_SCHEMAS_CHILD:
-    return Tcl_NewStringObj("unknown-schemas-child", -1);
-  case XML_SCHEMAP_UNKNOWN_SEQUENCE_CHILD:
-    return Tcl_NewStringObj("unknown-sequence-child", -1);
-  case XML_SCHEMAP_UNKNOWN_SIMPLETYPE_CHILD:
-    return Tcl_NewStringObj("unknown-simpleType-child", -1);
-  case XML_SCHEMAP_UNKNOWN_TYPE:
-    return Tcl_NewStringObj("unknown-type", -1);
-  case XML_SCHEMAP_UNKNOWN_UNION_CHILD:
-    return Tcl_NewStringObj("unknown-union-child", -1);
-  case XML_SCHEMAP_ELEM_DEFAULT_FIXED:
-    return Tcl_NewStringObj("element-default-fixed", -1);
-  case XML_SCHEMAP_REGEXP_INVALID:
-    return Tcl_NewStringObj("regexp-invalid", -1);
-  case XML_SCHEMAP_FAILED_LOAD:
-    return Tcl_NewStringObj("failed-load", -1);
-  case XML_SCHEMAP_NOTHING_TO_PARSE:
-    return Tcl_NewStringObj("nothing-to-parse", -1);
-  case XML_SCHEMAP_NOROOT:
-    return Tcl_NewStringObj("no-root", -1);
-  case XML_SCHEMAP_REDEFINED_GROUP:
-    return Tcl_NewStringObj("redefined-group", -1);
-  case XML_SCHEMAP_REDEFINED_TYPE:
-    return Tcl_NewStringObj("redefined-type", -1);
-  case XML_SCHEMAP_REDEFINED_ELEMENT:
-    return Tcl_NewStringObj("redefined-element", -1);
-  case XML_SCHEMAP_REDEFINED_ATTRGROUP:
-    return Tcl_NewStringObj("redefined-attributeGroup", -1);
-  case XML_SCHEMAP_REDEFINED_ATTR:
-    return Tcl_NewStringObj("redefined-attribute", -1);
-  case XML_SCHEMAP_REDEFINED_NOTATION:
-    return Tcl_NewStringObj("redefined-notation", -1);
-  case XML_SCHEMAP_FAILED_PARSE:
-    return Tcl_NewStringObj("failed-parse", -1);
-  case XML_SCHEMAV_NOROOT:
-    return Tcl_NewStringObj("no-root", -1);
-  case XML_SCHEMAV_UNDECLAREDELEM:
-    return Tcl_NewStringObj("undeclared-element", -1);
-  case XML_SCHEMAV_NOTTOPLEVEL:
-    return Tcl_NewStringObj("not-toplevel", -1);
-  case XML_SCHEMAV_MISSING:
-    return Tcl_NewStringObj("missing", -1);
-  case XML_SCHEMAV_WRONGELEM:
-    return Tcl_NewStringObj("wrong-element", -1);
-  case XML_SCHEMAV_NOTYPE:
-    return Tcl_NewStringObj("no-type", -1);
-  case XML_SCHEMAV_NOROLLBACK:
-    return Tcl_NewStringObj("no-rollback", -1);
-  case XML_SCHEMAV_ISABSTRACT:
-    return Tcl_NewStringObj("is-abstract", -1);
-  case XML_SCHEMAV_NOTEMPTY:
-    return Tcl_NewStringObj("not-empty", -1);
-  case XML_SCHEMAV_ELEMCONT:
-    return Tcl_NewStringObj("element-content", -1);
-  case XML_SCHEMAV_HAVEDEFAULT:
-    return Tcl_NewStringObj("have-default", -1);
-  case XML_SCHEMAV_NOTNILLABLE:
-    return Tcl_NewStringObj("not-nillable", -1);
-  case XML_SCHEMAV_EXTRACONTENT:
-    return Tcl_NewStringObj("extra-content", -1);
-  case XML_SCHEMAV_INVALIDATTR:
-    return Tcl_NewStringObj("invalid-attribute", -1);
-  case XML_SCHEMAV_INVALIDELEM:
-    return Tcl_NewStringObj("invalid-element", -1);
-  case XML_SCHEMAV_NOTDETERMINIST:
-    return Tcl_NewStringObj("not-deterministic", -1);
-  case XML_SCHEMAV_CONSTRUCT:
-    return Tcl_NewStringObj("construct", -1);
-  case XML_SCHEMAV_INTERNAL:
-    return Tcl_NewStringObj("internal", -1);
-  case XML_SCHEMAV_NOTSIMPLE:
-    return Tcl_NewStringObj("not-simple", -1);
-  case XML_SCHEMAV_ATTRUNKNOWN:
-    return Tcl_NewStringObj("attribute-unknown", -1);
-  case XML_SCHEMAV_ATTRINVALID:
-    return Tcl_NewStringObj("attribute-invalid", -1);
-  case XML_SCHEMAV_VALUE:
-    return Tcl_NewStringObj("value", -1);
-  case XML_SCHEMAV_FACET:
-    return Tcl_NewStringObj("facet", -1);
-  case XML_XPTR_UNKNOWN_SCHEME:
-    return Tcl_NewStringObj("unknown-scheme", -1);
-  case XML_XPTR_CHILDSEQ_START:
-    return Tcl_NewStringObj("child-sequence-start", -1);
-  case XML_XPTR_EVAL_FAILED:
-    return Tcl_NewStringObj("eval-failed", -1);
-  case XML_XPTR_EXTRA_OBJECTS:
-    return Tcl_NewStringObj("extra-objects", -1);
-  case XML_C14N_CREATE_CTXT:
-    return Tcl_NewStringObj("create-context", -1);
-  case XML_C14N_REQUIRES_UTF8:
-    return Tcl_NewStringObj("requires-utf-8", -1);
-  case XML_C14N_CREATE_STACK:
-    return Tcl_NewStringObj("create-stack", -1);
-  case XML_C14N_INVALID_NODE:
-    return Tcl_NewStringObj("invalid-node", -1);
-  case XML_FTP_PASV_ANSWER:
-    return Tcl_NewStringObj("pasv-answer", -1);
-  case XML_FTP_EPSV_ANSWER:
-    return Tcl_NewStringObj("epsv-answer", -1);
-  case XML_FTP_ACCNT:
-    return Tcl_NewStringObj("account", -1);
-  case XML_HTTP_URL_SYNTAX:
-    return Tcl_NewStringObj("URL-syntax", -1);
-  case XML_HTTP_USE_IP:
-    return Tcl_NewStringObj("use-IP", -1);
-  case XML_HTTP_UNKNOWN_HOST:
-    return Tcl_NewStringObj("unknown-host", -1);
-  default:
-    return Tcl_NewIntObj(code);
-  }
-}
-
-void
-TclXML_libxml2_ErrorHandler (ctx, error)
-     void *ctx; /* ignore - depends on context */
-     xmlErrorPtr error;
-{
-  ThreadSpecificData *tsdPtr = Tcl_GetThreadData(&dataKey, sizeof(ThreadSpecificData));
-  Tcl_Obj *objPtr;
-
-  if (tsdPtr->errorInfoPtr->listPtr == NULL) {
-    tsdPtr->errorInfoPtr->listPtr = Tcl_NewObj();
-	Tcl_IncrRefCount(tsdPtr->errorInfoPtr->listPtr);
-  }
-
-  objPtr = Tcl_NewListObj(0, NULL);
-
-  Tcl_ListObjAppendElement(tsdPtr->errorInfoPtr->interp, objPtr,
-			   ErrorDomainToString(error->domain));
-  Tcl_ListObjAppendElement(tsdPtr->errorInfoPtr->interp, objPtr,
-			   ErrorLevelToString(error->level));
-  Tcl_ListObjAppendElement(tsdPtr->errorInfoPtr->interp, objPtr,
-			   ErrorCodeToString(error->code));
-
-  if (error->node == NULL) {
-    Tcl_ListObjAppendElement(tsdPtr->errorInfoPtr->interp, objPtr, Tcl_NewObj());
-  } else if (((xmlDocPtr) error->node)->type == XML_DOCUMENT_NODE) {
-    Tcl_ListObjAppendElement(tsdPtr->errorInfoPtr->interp, objPtr,
-			     TclXML_libxml2_CreateObjFromDoc((xmlDocPtr) error->node));
-  } else if (tsdPtr->errorInfoPtr->nodeHandlerProc != NULL) {
-	Tcl_Obj *nodeObjPtr;
-
-	nodeObjPtr = (tsdPtr->errorInfoPtr->nodeHandlerProc)(tsdPtr->errorInfoPtr->interp, (ClientData) error->node);
-	if (nodeObjPtr != NULL) {
-	  Tcl_ListObjAppendElement(tsdPtr->errorInfoPtr->interp, objPtr, nodeObjPtr);
-	} else {
-	  Tcl_ListObjAppendElement(tsdPtr->errorInfoPtr->interp, objPtr, Tcl_NewObj());
-	}
-  } else {
-    Tcl_ListObjAppendElement(tsdPtr->errorInfoPtr->interp, objPtr, Tcl_NewObj());
-  }
-
-  Tcl_ListObjAppendElement(tsdPtr->errorInfoPtr->interp, objPtr,
-			   Tcl_NewIntObj(error->line));
-  Tcl_ListObjAppendElement(tsdPtr->errorInfoPtr->interp, objPtr,
-			   Tcl_NewStringObj(error->message, -1));
-
-  Tcl_ListObjAppendElement(tsdPtr->errorInfoPtr->interp, objPtr,
-			   Tcl_NewIntObj(error->int1));
-  Tcl_ListObjAppendElement(tsdPtr->errorInfoPtr->interp, objPtr,
-			   Tcl_NewIntObj(error->int2));
-  if (error->str1) {
-    Tcl_ListObjAppendElement(tsdPtr->errorInfoPtr->interp, objPtr,
-			     Tcl_NewStringObj(error->str1, -1));
-  }
-  if (error->str2) {
-    Tcl_ListObjAppendElement(tsdPtr->errorInfoPtr->interp, objPtr,
-			     Tcl_NewStringObj(error->str2, -1));
-  }
-  if (error->str3) {
-    Tcl_ListObjAppendElement(tsdPtr->errorInfoPtr->interp, objPtr,
-			     Tcl_NewStringObj(error->str3, -1));
-  }
-
-  Tcl_ListObjAppendElement(tsdPtr->errorInfoPtr->interp, tsdPtr->errorInfoPtr->listPtr, objPtr);
-}
-
-void
-TclXML_libxml2_ResetError(interp)
-    Tcl_Interp *interp;
-{
-  ThreadSpecificData *tsdPtr = Tcl_GetThreadData(&dataKey, sizeof(ThreadSpecificData));
-
-  if (tsdPtr->errorInfoPtr->listPtr != NULL) {
-    Tcl_DecrRefCount(tsdPtr->errorInfoPtr->listPtr);
-    tsdPtr->errorInfoPtr->listPtr = NULL;
-  }
-}
-
-Tcl_Obj *
-TclXML_libxml2_GetErrorObj(interp)
-    Tcl_Interp *interp;
-{
-  ThreadSpecificData *tsdPtr = Tcl_GetThreadData(&dataKey, sizeof(ThreadSpecificData));
-
-  return tsdPtr->errorInfoPtr->listPtr;
-}
-
-void
-TclXML_libxml2_SetErrorNodeFunc(interp, proc)
-    Tcl_Interp *interp;
-    TclXML_ErrorNodeHandlerProc *proc;
-{
-  ThreadSpecificData *tsdPtr = Tcl_GetThreadData(&dataKey, sizeof(ThreadSpecificData));
-
-  if (!tsdPtr->initialized) {
-    Tcl_SetObjResult(interp, Tcl_NewStringObj("internal error: docObj data not initialized", -1));
-    Tcl_BackgroundError(interp);
-    return;
-  }
-
-  tsdPtr->errorInfoPtr->nodeHandlerProc = proc;
-}
-
diff --git a/tclxml-3.2/examples/README b/tclxml-3.2/examples/README
deleted file mode 100644
index 85a4a67..0000000
--- a/tclxml-3.2/examples/README
+++ /dev/null
@@ -1,21 +0,0 @@
-examples/README --
-
-These directories contain various example scripts to demonstrate
-the use of TclXML, TclDOM and TclXSLT.
-
----------------------------------------------------------------------------
-See the file "LICENSE" for information on usage and
-redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
----------------------------------------------------------------------------
-
-tclxml
-	Examples of streaming parsing using TclXML.
-
-tcldom
-	Examples of tree-based scripting using TclDOM.
-
-tclxslt
-	Examples of invoking XSL stylesheets using TclXSLT.
-
-
-
diff --git a/tclxml-3.2/examples/tcldom/Libxml2-Logo-180x168.gif.b64 b/tclxml-3.2/examples/tcldom/Libxml2-Logo-180x168.gif.b64
deleted file mode 100644
index c956bd4..0000000
--- a/tclxml-3.2/examples/tcldom/Libxml2-Logo-180x168.gif.b64
+++ /dev/null
@@ -1,183 +0,0 @@
-R0lGODlhtABEAPf/AP///wAAAP7+/vz8/Onq6aSloQUKAjE0L/v7+3JybC0t
-Kb29vWJiXJSVkTQ1Mjo7OJKTjt3d3YuMiUtMSpqalff394mKhuHh4fT09Bsc
-GtXV1NLS0ebm5tDQziQmI8nJxcXFwOTk5M3NyUtSUrW2sfPz8/n5+GlqZtnZ
-2UNEQZucmf39/fDw76ysqfLy8g4ODbm5stnZ1YGCgMHBvdXV0Tg5Nq2tpMrK
-yHFycAAEACwwK/L18bGwqe7u7gACAL6+uba2rWxuahMWEURLTICBfuTl4jtF
-Rm9wbfr6+nR1crCxrcXFvCcpJGRlYoSFgsnJwejo5rq6rKGinh4iHQIHALm5
-tWpsaWVmZNzc2ubm5FJSTVVYVs3NxhEWDuzs683NzHh5drCwpb29tXx9eklK
-RuDg3mFiYPb49Xp8ecLCwH1+fKmqpe/x7nV3dMHBuO3u7K2toVpaUcbGwxQY
-E3l7eGdoZlxdWX19clhZVsDAtHd4daGhmYKDge7w7n6AfWlraFxeXDY4NPP1
-8lpaWV9gXebp6mJjYXN0cEBCPlpcWlVVUfX29A4SDCgqJ6ammlZWVFpdXVda
-Wuvr6ff69ubo5vPz8uvs6paYlIWHhL29sAkJCdDQyoGBevr8+MTEuUZIRBgZ
-F4CAdKmpoo6QjFBUU11dVPX19cjIvqSknoeIhVFSUE5QTK6vrFFXVfr59+js
-7fHx8ezu60FHSQsPCV1hYL6/vcfIxW5ubKanpQMDA9TUzgQHAT0/PLq7uYaG
-fC02Nn9/dgwMC0lPUCEkH+Tm5LW1qYiIf4SEeSUqKKmpn9vb2M3S1J6fnNbZ
-2uzu7uPk4QYLBCAlIwYGBry8uJ+flfz7+AgMBvv8+fv7+pCQhltbUqOjnOHm
-6fHz8NfX1be3tFNXV3h4cd/j5gIFAODi3/j799PT09PW1AIHAtjc3czMyvP2
-9rO0rrOzq9vf4MzMw2JlZcTEvu3w8W9yb4iHg8TEw/3+/Hh4bTA6OqamoaSj
-m/b6+pCQjQIIAAIFAoCAgCH5BAEAAP8ALAAAAAC0AEQAAAj/AP8JFEjk0AQd
-uQIoXMiwocOHECNKnEixosWLGDM+zKVjwiEiA0MKVHNAo8mTKFOqXInygBqR
-Aq9oCpBLFa4vKwDo3Mmzp8+fQIMKHUq0qNGjSJP2XPEFl6qEmq6IHKSQyQ2l
-WLNq3cq1K9YbTBQOGohDIY4KXtOqXcu27c4KZQPg+EcEVIAtQAUIWDEAgd+/
-gAMLHkzY74ABKwS4Xcx465YAoIgcCSCNg8+9SExUwFDChefPoEOLHk26BAZT
-FUwgbsy69VAO0gIcmRBgkM8VCExgYOGFAAcOIYILH068uHHjvwn0cJF6gGLX
-0KNTneAhAK6lSCqw2EAkxZwu4MOL/x9Pvrz5LgfqVCnD4Q0G1c+jy2eMK4CH
-FwFQ8BSAxJQXZruwFIAPA/pgoA85JKggggoFsUwZBJSg2nyLCXAYAojFp5OF
-fWGooVIoBIBfALDsZGEFb8wTQA4BCPEJHnbEGCMhhAAiox2J4KHjI4qoosoq
-q0xAxicppIAIIrzw8kANgQSigxAJBoCMBhEQgAESH27IFxJccnlYlhT2NIAJ
-psACC3PO7TQAEou4wAIsFSCRU1awMMTTCibAksaKu3xiASvTgACCHLZ88ME7
-htoih6DxzODGNL1UQQI7SrDSAi4FFCAFMypQcEkDEGCCAx6BzMKiBOZc0EMF
-A1w25m49vP/xRg8slFABAnOG2RN/5oxiBxghvFHBnLwyY8UEIXhhSqta2amm
-KSGUtIsh+fxgiSvVYNPJNdx2e82210wi7iRnnLHIIqYIIsg6+5h7hiB99NDH
-G6+kA4EZEzCSgw8keMNBCVjuigQfaqChx8GY1BMCAS6YkKuuOq3AwS1maXAB
-LMwKUIEf+NWgSwRvmLCVswDw54IKA+Ihyg1n2PNtNTBX08nM5dRczriTXFPO
-ueoKcgYl9VRKAjnd9GB0D/K8wooZiFARwB9flNGDw0tV8EUGCh0xWQBEKBOC
-CwjoJbZSYoOp165n8zRAJVkodIIt3kiCRMSLQPFAAA48oQEHaDX/u9BOePaw
-RQ7QOMEOC/a4gjO55Zp77iLqntGHN1jsIMgOO5zhzShjoDGGHlLIGssrhRDw
-CiUyqGIqL7ZgIcmwu9Z9dwDZLBFWAErsLWEFpqBmAgKZVYBu76hVYLwJJgTf
-e3OHZcd7akgAr5nvGK5ZgRdlKNTEDx1AMXfJpmRxtwNucAFyasgbfzzySKT5
-E8krVCCJA1SAQgENnZT7OM89qwu5IHWjABFkkIYzdGMRH6CHGmTABz7IwAkR
-cEYhJjjBV9jCDFPIwTDS4A0oYIBZJpKdQoyRhyso5AofUIZyWtALAijHMz2Q
-BBR+wwEoEEASR2MBC3qwgBbYcDmVgMUX/wiAgipAwQsscIEQW4AC5VRCeC6o
-xTdioBAGwEAdHBBZyRZRhLsdIA8wUEEZoIDDN0hCEgTwAq1g8R4Q9oRkAzAF
-AQ7gAyaIwhLv6p8eLbcINkDuDN+ggwzoUADMEQACY5CBImXghwZQ4hWQJB03
-uCEONTTCB1Ooxd4+6JNFiE8hx4hCE7QXjw3oIQN6UEAGIFCGIlhBIS+YXQCS
-cLUA0KEIuMiAAurwgiSU4RkaoEMAeICfJmDhGbbgxQva8II6dIADklAGLwJw
-hU9UEQY3yOJbPgkK2oiIFVgAAywhMAPaSMALAAMTHDHAAQfUkQdsSJcee4Y5
-NlSBH7Y4AxsosP/AMRSADYLoBRoWyQcnEKEWznBHM5ZxjnSIg3QSuOQUFqA7
-BPikAnYDZRTIoJA7uCEIATBEB0igEAp4IwZYa8QTTqAQMXBBBY+IAStEFA8u
-BCIAEmDGiByAtQBs4gNYo8AmQGoGynFUEZsQwzWzqUUAVIADdwMFHLKBnxds
-Qhc1ENE7RKCCQ0QgWCZQ5990MgB2upMJSmDDDrrB1ra2NXO1ONgl2NCHS4yB
-CHRgxQ4IYFcG8gENZjCDElTghDGAIQl0GAUuaiEDBWByAeb4l0V7gtHZlQKk
-9olCMhQCgSe8oxEByMA7NkGxADjCEW7zhBUkoItH4O0U1MBPCrhgAYX/JGCU
-B3jCGBRyiiiE5QUigIFCwHCKUyxVmzp5qhczkQdtgPIJwgzAMZZgBRJ4bWpi
-VYiaSsABOjKBHT3oBhvYwFbyknetgigAGNTgBHIsogXrpYMtBIEFJzjQIHMI
-hhMaQAc66OEQR7DCFcxgiCvQcaKRLcFkeVJZhXyCDDoghA3yEA6FZMMTp9CC
-QpJxCqUGQBHFqI4HMjGI0Vb1ACg+wAme0ACF+KId2RDDKVKgkBQfYBW6tbAn
-lnDcpio3AAeIQh6OoT03LAE/E8gDIm6AAg7AYsFvHCsAEMBd77LjDXTtw3i3
-bDl1wVcNfMDCIrwhgzYUwBI9iIATHnEARijE/w8FcKAaDouDANfBEE04MGQl
-e9GMShcOPIBBGj6AWQu44RSYNcahaWy/YXAWDyDYRI2jUAwSTEMOH2ixdG1A
-gnhs4qYBoDQQLv0OzErAyD1+C1SBnAk3QOCablhFAIKxBzzIoYmcfJ+Uqdzd
-OrJDjUc72g68IQWW2QIMaHBCGejaAn6Qow+v8IasFWKNMeCigTKYcxLqbIU6
-NMHAj00wlJPr52OEoQq20IA31GBbNzwBs9T4gS3ooRAdZKPGDYg01kARBRjM
-4AYb0AUFXMyONJgjBopQCDWi8IMP6KIDpQUGhqtYhQ8g16mr/uISNB0OGMRj
-DwrhBT1AgAUWNNUnJP/jtZUl8YZYxEJWb2ABOUYxD0w8gw3sSAIELMHzGb5B
-GTMIQ2OnQIgG4EICmJAzne38bT2Lu5NZyGoAQmGDGfgrBL1QSBzycIpXgoId
-MxDBJvDjgWLoADIeF4EqRujvGcggBgMPgC9IcIMIXIAIsBbBIWgQ9617oook
-sEUIKvCcp2ZV4ywNRj6m8YFNYC0YQEgDFjAWlJRX2ddQiIUlCMBzS0yOCGgA
-Qy0EYYlvfCAWnGcDB0TQDlGsgQdrKAAJpCABCyQ920vvdtPDzef9hE/qnGDH
-B0JQiR6UgWIvaEc8wkKPb8AtBoQIAAOKwYAA2AHdGyABfoJxhFEEghkxkID/
-QsJRhS8sTBmglb4ECHGIGICgqgkwYQA+YQbBEz65HMiqB8TgCQdInwT1QAMx
-QDG8QAJyEAEY8DBRpl06oXK+RgkEYEMuxHl8pQdm9gaeJy9sUAZScAITgAg1
-8CJ8wAyXAAGjgHRKt21MB24I1nsmYgreBBlHsAEEIDxQoAF/8AIHMAig4AfT
-kAYa8AwXUAUBsA0wAHLMkAYdgAIxUAB2ISJ0oAE6pRDB0ATP9AYXEA/+pxCA
-oAHKQAN0sH0JAArBoAjMoA6DNycVQAAPcALdhAgv0AS9MAMbcAFDKBu9oA4X
-cH9AYXm9hlZZAAWUQAkSCAU9YAtocARnphxZUAsW/+AALNIQ0MALTkABJ3h7
-2sZt3saCe6ZgS2EKHEADM/ANJGB1koA8sHAB5vABo6AC8VAPN6ABIcAbZaAC
-tnCLzGALGxABwOENtkABFiBvG6ABHSAH0/ANQMgwkhAB6oALFqAEcmAOWIAF
-5lAFEgADMNAAJFAF9aABNfgcJvAGUqAO8SABFBAPaSAHdfgGUIAFjZAPIBBZ
-J4dyu3Z5aPUMHDCI+jiIlmALDXAD4yUHhjALCtEPBnCQCOk0c5AKEGB7DmRY
-2xYEupdnvOeJ+4EiZWAO6qAO/vJkY8ICIfCFG2AO3sCLcIIBXhACEYAFK/lV
-knAmHIACHXAD6kADdhcBxP/YAd4QAie5jBtwAwDHiwTwDN4wkx8AlDrJk2HT
-gNz1hR3QAeagAVgQLLAABV9QA3LwBRHQA25Ejww4ZfbIA89QBGNZBGZpllng
-G2/wBVaANTmwCwgZlwgZAHhwCRZgX34AkfMQBH/gbRTZghZpIghgCm/AAXYI
-BSzAKnthAi7gBcBRQz1gCnKCABUAC8GWRHGCBCgZAmVQBgvzBo4ZHIjJKpTZ
-AxzQmQvDRrBAAJwZAWVwARxAALAwIRHDmKEJmxzgBZWAARswAS9wBLHIARgA
-Jjvhh95lA7zIAVlwlsSwnGOpDLThA3I5nQdJlxSQCvalBnRwWHvZl03wl504
-bgD/wBeagQEY0BzPYSHleZ7wUTJ9wT5e4hzqaQqewZ7T4zvyuQLZ0RnniSG5
-YQqdYRqpgSv7gRvGwxnsSZkzFQDjiAKnOBTG6QPvCATx0AHKwJIRoAwasAEd
-oA6AEABwSZ1ySQU+sF+Y4AS4d1hHEAQncAV45nQuSDZjcxlCUTZGMaMmYqM1
-WjaKoTHK0AZqoA51SHlCEaGNUAA2YAM8QAK98AO14CgzYAsqkCAiKpe74ANm
-wAoOSQRz1gaaOGDg+XQQM6YCYAI9cAEoUJI1qIBeGQA74YCNIAVrYANh0A7s
-gI3TUAu18AGTUaVx6TSk0AujgJ18AHrcyZfeRmAwGphr/8Eh1UOcrsEXhpEY
-b4qSvyEJjNqH9dhdOcAEe4ALc8oDdkoC2Oik1uSn1YkOeNACdpkKckYHbZAE
-e9miTRBYOlCR4okUe9EhzUMmsLBDzLGU0WEh2LAZO4SZIDQm9MkcckIUxpkD
-HqACqJAPcxoGosoO28gOjuWnLNIIDcAODWABd1moEAlgLHoFTUAItHCrgCme
-uKEZ6qM+7ZOelFkJOwQLlVB8KJAKD9AGzyAsbNoYr/IGHwAGClAAHGByfFGs
-JXCstuI+lbepBwCtFCAF+pAPopCk1toOJNAOgSCd1BkgQgAGrgcBteeq2RZ6
-KuidZkAIZsCu4bkrlAkLXgAFM/8Um2/QMMwymKwwAYOQBhdgC6ugAAsRBHXI
-Al3ZGAKAACTAC1OwEA0giw1TmV6wBrgAAs+QljpbpBILrZfADMywDagAqklK
-p0DgWtRJBbtABhBQBZcwCic4rkRgWF66oi1qCC27rri6FCbwtEryAA+ANQ1g
-JRalMV+wEBmwCTcAAUSrPab4Pa5Rph1gASMSABZgC8rgBS7QswyRATgQA/8K
-O5r6lSoHrQ1AASrADHugDwVArWuwBjkHolbqA0kAA9sAAQ3QAKNwoqnApf4l
-q0fgnYZQI4AAs2L6LJKgBwyBCCQQNSyAJSuAAbu1EBIgAjSQAAthRd0Dua3B
-HyzwDFL/J10/QANFIAG9pAKlpRBasAkgE1aj66ZMyakeAAGXcAmpG7b6gApj
-awOjMAtUEJe74A9BAAOfwl94UAMeoABb8FeHZa602rKQAAnGG6PjKT/bwBBW
-ZAsR8GQAsDb1QYWiIAe6gL0KUQrt8AUX5xoD4ALkEL6hUAUdUAABwAwbsAlc
-gFkKcQh66AJJqxPPOgyjkLuXgLpgq7rbcLFrF5c5kAEFUMBO0FMsspCwegjd
-mag1kgiJMMGZWqaScMELUQo8AAIRUAKtsgKV8AwJ8AKgcAjsYAsj/MVAIAIh
-cCXtcxgXAhh2/BcZohcrwBd9wSUY0sd/HMhrA74LEQrYRAaP//CUT+kGDLF/
-NCA37/umVaZBFgABuFu/Q6wCnKwCUtAA1ZGQXSABl8APEIAG/nuQPqADDRCr
-8xBgD0wIkIAHg6AAOdCuPoEEXcwQcWAD9bCHPbqGMfAEYjBqHRADhwDHXIAF
-ZBRzlQCglnk0sGAaQZRE56k8JdAZsTIrlYAuLhAry3Er4SNLiPwBLyABHbAB
-KPCFW6gQPHADgzfJ8TuxU5AKcIu7udsA9UsB/CwFdYAgB3mlq0ABuWsGuxCi
-AbAKo3AIdcaiVgwIkbAFkdAItxyzYtIDMrwQcfDOyBU/b1AGugABJ/ABMYAF
-SbAQ2hAFTqAID1AHM1AGGjAGY2C1Bf/QBnpwa2qgArgABnQgmy7wBtNgBWOJ
-CxMwAcr2DFBgC1bQ0jNwAVZSAp+kEKEABHLwAt8gjbFZBuEbAKKQBmXQN21K
-yZw6BU4gARJwz/icz/pMAQkwCyC7CzmgA6tABnOA0BnAOThQxU0wvLKMB1sA
-DshQ0cerJhjNENrA0SKztBggCQWQVQ5A0ia9EApQEgwxBjTAD7IUACmgC8rg
-BArxCMzAHrZAFQFwCq61EIqgCzJQuS+QDzFgiFEdAMDQDiBQBSjAi54RdQsR
-CPng1WC9gPALlmMtA6kgrmYNt/xgypiMuypwBULw1gQSAP9rAD7ACPv1ysFb
-By7ashC9Ba3/0AoUjcsXndEKcdhMNZ4mQASNizelpAzJrBBzcA/AULkBAAFc
-EA+VywunIAIgYEs3MJOkrRCgsApBULlM4ABB0M4OIAfKwAHPIEt3IHxYkJtw
-wjYYLAr2J8/CTc9+4AROgAnFbQFmfdYjfoINoAaO5gMhepBO8wJjMAp5LZGx
-DAg5Ag6kAN6CTcEdXNgojdgdXAFqsN4HAAMigMwaHQZREHc15m7RNULUlQJy
-AHCsgAcYnAme8N6QYeVRULk2EDVlAOHsoIeJiTwskAqSTQ1K0AEEwL088axT
-MAYOVFAfngohLq52ngr8kAqqwATQwBCM4ABEcAnYbQUPDMF+3Qoj/0AK4W3R
-asPj5e3jcQQFUrAQOtAOtkADWB4HcAADnoAIDEENh9bOwxAGoBDCS1gGygBq
-U1cMbnBvCqEAxSBj7cwJ8RADEQDmKMwqA3A9sxMMDZAPtbDBPQwAz5oBYOAH
-fjBADeThzH6izF5QEsAPY4AHSTIIDcAMkqE13YauLSvLEY3oIzACgS3ejU7e
-AWDe2hQ/UAByr24DIKALWK4NNtBwOBwAnAADIPBqCzEMj8B4TQYFWr0Qd9AO
-M6BpAaAAcCAGT9DOwDANNIAFYN4BktAqa7MGVGgM+fANNOi+uka6lZwBbYAG
-aKAGajBABNVAKL9IXMoH4ooJEiADALaiff+Jrnjr7d5NCiMgDCMQDTmeqTtu
-7uguMvFDAJPe7u+O5WAswijzxTAgB1wwbRYGA19wAUpkyB0FBE+g5AjvBiKg
-6ncAwzEQvhEu8YiBIkTrAfrAaXoICwHT8cFdup4LBnLvOSSvBsjOQDJABETg
-B3avnf2lB9uW1zL/B7EMCZHg1zgvDIrP8+RO2EDP0azCJrts9PD+xe1wAzHA
-7uXNDjegC0DAECcABGhoChig2x1F5Et/8GHw7mIPA8cs9uzQAV7gF5UgTIjA
-adOgDjPAAVvr9mI9sRlwBEmQBDYt93Qg8n6ABnXwB2jQBsdfZ3RwCITwB20w
-D3/wBwLmolvgI4n/YPiIn/OKLwyMz+iOb9gcjRoQYJpFf/DuXvklzAPqoAzr
-HwBxcPnDzBBzUAxyUAamABCLoDwIUPAODBEqCgZQEAaErhoLD3aIEdEgiQ1e
-kFT48sLMqRm2OqgL8MyLCyQAVK5UuTDAygElOBzIkSHIPByHkiRpowcMnRMK
-AtVos2oVJl4p9Dh40EhVEgeEjvDC8SlDDV6EIuHZ0mrECGHChgyJlmPKAnMc
-SiBgqXJAjwIutfG4wYEFq5Jl9ixUYOPhoYWl2qlTJsXlPXZfsPAJ5JKBG289
-Kg2UiFBhwYYPLQaYWFEiRkmLWPA6tOkDFxoxkgTQUEZShbYrXcKU6aDm/4kg
-R47Mw6kTjAM7BSRIQBTgBC8yZPBIIcQEzRxEVxipQfQAzbwmW7aQ+hp2iCyy
-ZtGqZdv2bdyFc0WEkGQngLcYlxn6pQG4oGARWJwsDKavyoYOMmCHDP7CUCeE
-HrIgyCDL+HIIosoo2uwOjAjoYQwydOHinU3esc8WGkLAILaWFoIJg5lyAOUK
-K6wIIjfd5glCh1H0+MSQFBp5IJBPaghijCt0AAOUKVIYJ4hVrtoCEHBI4c47
-WaIs66y01optABbQK0gbIDa5gIYXAuBCFwoclKO+wLpUZrWC4oAjHg3aeGQT
-OFxSZAYUOChiwQBCESMhMyEsKJT/lNksFBg2eP9mDZcaDQCGDyJwgUQAZnML
-AygC2YURQk6o44Q//nDxRR1wSIKXVT45hJAAVnnAjjHsaMSKT1KYBRFVVKmB
-jiO2606sKI0wYg4qhllAA/Jiw8YLVFyKo5gPYrDPkycacDCeDRJIEzUFCgqG
-gnZsYZSEd06ZwKU9bsAigkNh4KJMzBzaZEKEPBsUhk1ECNPRhWyYQZlJSbQU
-gAFMISCIHHaZoI4mrriijk//CGKCKXgZRpVPrHBimE/MYOIBIVYZBJAmHjjE
-gy3m0MGpJ4GVRVh8oMmBjBm84QCDAdoSwAQC2MQsmVO0LSiTJYxZCJQwZtjE
-jIV0AOIJeIMxxoYf2mn/JIB3PngCApcemGEDb+j9AF6Gwohn3oUScFeXqwu6
-AoZ3PuHXpWRmwKIESgdeoQIvGM1BgSaaMMSQwB2+4o9HUJVgizHGAOSENhR5
-ABB+VknCEDrm+aQOXh5IgZawXBbWCGSoCOCPelAgwJScWdpbh7ldgqGOfQsC
-5RARAlkFDoJ4sSNMMvSxgZkUFnJgmgYyaHSCNtq2vQF6lF/ok3iK58+Q6Bs9
-oIXYvV1DjjJMydtElXZmoQymd2mE5MEDd/8WPfyY54ogGsbujyTAuIIWeCCp
-IxFaAJAWkGgFlF4mLGRYIwdzUMINIuCFCqzAPBhYwxriAQQ4JMMGJPiBCixA
-/w8IfGMN/HADDGxgASeQ4AtHaMEPYACBJtSBD+yoQhV+cAMVbOAGVeDHDWbQ
-gAvagBqcsEALGtACMfCgAURQwg9QAQIYhIETEABBAaRQNRsQARXIQ2I79sAJ
-IH4gHjDgQTIccUZH6EMfovjGBjgAG4GRDwACQIJM6jGLHPjAA8oZhB0SkQg7
-BDIRgwAkIQc5iEFwBRxNUkSuwCKW70TpgEb4xRR2YboG1GIDIWCBCQRgngpI
-IgIdkEMtapGGD6jjC7aoRxpEYo5VziAkHUCBMjTQgRvkUgS5vMEXvFGGZ0TA
-GxsAGxZQsIEPzOCUH+iAOTrwgTSkQQ4dgA8y01CPG/+YAwUaUAcIpPkFDQzz
-Bmk45Q024ExbpOEH02DnNHqxgHps4AKwKE9sXAILmFSgB2VogcwSxog5BFSg
-AyUoQYVwUIQitAuMYGhDZ2EAKuQgALfohboIgAEEfNJ1JnABAS5gTBSsKwIR
-QEFJI/CMEFyApCg4KQcIwAEOPKMMZRgpFsrAAUmwgAWS4MAFLuBSKISgDCVV
-hk0vQFMsrOunHBBqUssQAqZ+VKkhSGkEjGnUlJYBpCUtqU05AAsTSDA2sChI
-mFCwEjpigABYYMYDDJAwKsRVrnOla13tGtdd5FWvuxgHFTwwhl7YwmadFCtL
-BDAAE5jCBbBg7GJhwYIe9ID/BbAoQQkcy1jKmsIUFVAsLHrwBha4oAImQIIJ
-KmBZF2BAs5ZlrE4n29rGYgADrG1sZS8LCxdc9rUuqCxqc/vbEmwWAYVtCwoC
-8AIPBAAXG4UFFLDwBRUAwgE6oG51rXtd7GZXuzqYACZIkAZ1oABBFcgopQRw
-Xo2idQXrXS960cte+A5AvgNYQXrd697yCWAF9K3vff3L3vsC2L+UInBbcBEA
-D5xrEIZFLCwIUAZvdICV5DRlhS18YQxnGMMzcKU6NBABDvSgAkggboFNfGIU
-p1jFK2axSgYRgAkcIQDS4ACDTVCCN/SUpN7whgZ8/GMgB1nIQw6yN0J6U0nA
-YsQl4G5xk538ZCgTmAPSCMARiACKAGxBZwPYSAlY4AUCQAGmYyZzmc185jND
-gQCS6IELTGGCAaQ3ynOmc51TvIUAgIII/8BBQXAAR7Ry2bSmkG2hDX1oRCda
-0aodLRLoK2c7R1rSda5AnwOAg39k+sUBYMINYnPe9c5X1KMmdalNLer+TlrV
-q47yDZhQkEFkWtZX0EQAcqEKXHyByazmda99neIVfAEXqshFADRxBVknWw0H
-6F6znf1saEdb2tOmdrWtvZADqCHZ2ybCISagg2JfW9zjJne5zU3tXHD3EHtO
-dkAAADs=
diff --git a/tclxml-3.2/examples/tcldom/README b/tclxml-3.2/examples/tcldom/README
deleted file mode 100644
index 1e3744e..0000000
--- a/tclxml-3.2/examples/tcldom/README
+++ /dev/null
@@ -1,45 +0,0 @@
-examples/tcldom/README --
-
-This directory contains some small example scripts to demonstrate
-the use of TclDOM.
-
----------------------------------------------------------------------------
-See the file "LICENSE" for information on usage and
-redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
----------------------------------------------------------------------------
-
-cgi2dom.tcl
-	Not an application, but a package.  Provides the
-	'cgi2dom::createdocument' command which accepts a number
-	of name-value parameters and returns a DOM tree.
-
-	All parameters whose name starts with '/' are
-	interpreted as XPath location paths.  The 'createNode'
-	method is used to construct a DOM tree.  The parameter
-	values are inserted into the tree as text nodes.
-
-domtree.tcl
-	A BWidget mega-widget.  Displays a DOM documents as a
-	tree of nodes.  The BWidgets Tree widget provides the
-	display.  DOM events are used to maintain the tree view,
-	and DOM events are posted in response to Tk events.
-
-domtree-treectrl.tcl
-	Similar to above, but uses a treectrl widget.
-
-domtext.tcl
-	A Tk mega-widget.  Displays a DOM document in a Tk
-	text widget.  Control of the widget's contents is
-	at the level of DOM nodes, not lines and characters.
-	DOM events are used to maintain the text view and
-	DOM events are posted in response to Tk events.
-	Character data in the widget is editable.
-
-browser.tcl
-	A mini XML browser.  Uses above mega-widgets.
-
-tkxmllint
-	An XML document analyzer.  Performs well-formedness check,
-	DTD validation or XML Schema validation on a XML document.
-	Basically, the GUI version of xmllint.
-
diff --git a/tclxml-3.2/examples/tcldom/browser.tcl b/tclxml-3.2/examples/tcldom/browser.tcl
deleted file mode 100644
index f178b0a..0000000
--- a/tclxml-3.2/examples/tcldom/browser.tcl
+++ /dev/null
@@ -1,105 +0,0 @@
-#!/bin/sh
-# \
-exec wish "$0" "$@"
-
-# browser.tcl --
-#
-#	A mini XML browser
-#
-# Copyright (c) 2003 Zveno Pty Ltd
-# http://www.zveno.com/
-#
-# See the file "LICENSE" in this distribution for information on usage and
-# redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
-#
-# $Id: browser.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require dom
-package require domtree
-package require domtext
-
-proc Open {} {
-    global tree text doc view
-
-    set fname [tk_getOpenFile]
-    if {![string length $fname]} {
-        return {}
-    }
-
-    set ch [open $fname]
-    set newdoc [dom::parse [read $ch]]
-    close $ch
-
-    $tree configure -rootnode {}
-    $text configure -rootnode {}
-    catch {dom::destroy $doc}
-
-    set doc $newdoc
-    if {[lsearch $view tree] >= 0} {
-	$tree configure -rootnode $doc
-    }
-    if {[lsearch $view text] >= 0} {
-	$text configure -rootnode $doc
-    }
-
-    return {}
-}
-
-proc View:tree {} {
-    global view
-
-    set view tree
-
-    .controls.view configure -text {Tree & Text} -command View:both
-
-    return {}
-}
-proc View:both {} {
-    global view
-
-    set view {tree text}
-
-    .controls.view configure -text {Tree Only} -command View:tree
-
-    return {}
-}
-
-frame .controls
-button .controls.open -text Open -command Open
-button .controls.view
-View:both
-grid .controls.open .controls.view -sticky w
-
-set p [panedwindow .panes -orient horizontal]
-
-grid .controls -row 0 -column 0 -sticky ew
-grid $p -row 1 -column 0 -sticky news
-grid rowconfigure . 1 -weight 1
-grid columnconfigure . 0 -weight 1
-
-labelframe $p.tree -text {Tree View}
-$p add $p.tree -minsize 200
-set tree [domtree::create $p.tree.t \
-	      -yscrollcommand [list $p.tree.y set] \
-	      -xscrollcommand [list $p.tree.x set]]
-scrollbar $p.tree.y -orient vertical -command [list $p.tree.t yview]
-scrollbar $p.tree.x -orient horizontal -command [list $p.tree.t xview]
-grid $p.tree.t -row 0 -column 0 -sticky news
-grid $p.tree.y -row 0 -column 1 -sticky ns
-grid $p.tree.x -row 1 -column 0 -sticky ew
-grid rowconfigure $p.tree 0 -weight 1
-grid columnconfigure $p.tree 0 -weight 1
-
-labelframe $p.text -text {Source View}
-$p add $p.text -minsize 200
-set text [domtext::create $p.text.t \
-	      -yscrollcommand [list $p.text.y set] \
-	      -xscrollcommand [list $p.text.x set]]
-scrollbar $p.text.y -orient vertical -command [list $p.text.t yview]
-scrollbar $p.text.x -orient horizontal -command [list $p.text.t xview]
-grid $p.text.t -row 0 -column 0 -sticky news
-grid $p.text.y -row 0 -column 1 -sticky ns
-grid $p.text.x -row 1 -column 0 -sticky ew
-grid rowconfigure $p.text 0 -weight 1
-grid columnconfigure $p.text 0 -weight 1
-
diff --git a/tclxml-3.2/examples/tcldom/cgi2dom.tcl b/tclxml-3.2/examples/tcldom/cgi2dom.tcl
deleted file mode 100644
index 346a8f9..0000000
--- a/tclxml-3.2/examples/tcldom/cgi2dom.tcl
+++ /dev/null
@@ -1,56 +0,0 @@
-# cgi2dom.tcl --
-#
-#	Turns CGI parameters into a DOM document
-#
-# Copyright (c) 2000-2002 Zveno Pty Ltd
-#
-# See the file "LICENSE" in this distribution for information on usage and
-# redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
-#
-# $Id: cgi2dom.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require dom 2.5
-package require xpath
-
-package provide cgi2dom 1.1
-
-namespace eval cgi2dom {
-    namespace export createdocument
-}
-
-# cgi2dom::createdocument --
-#
-#	Construct a DOM document from XPath locations paths.
-#
-# Arguments:
-#	specs	List of XPath location path specifications
-#		given as location-path/cdata pairs
-#
-# Results:
-#	Returns token for new DOM document
-
-proc cgi2dom::createdocument specs {
-    set doc [dom::DOMImplementation create]
-
-    foreach {path value} $specs {
-	if {![string match /* $path]} continue
-
-	set node [dom::DOMImplementation createNode $doc $path]
-	if {[string length $value]} {
-	    switch [dom::node cget $node -nodeType] {
-		element {
-		    dom::document createTextNode $node $value
-		}
-		textNode {
-		    dom::node configure $node -nodeValue $value
-		}
-		default {}
-	    }
-	}
-    }
-
-    return $doc
-}
-
-
-
diff --git a/tclxml-3.2/examples/tcldom/common.tcl b/tclxml-3.2/examples/tcldom/common.tcl
deleted file mode 100644
index ac3eb59..0000000
--- a/tclxml-3.2/examples/tcldom/common.tcl
+++ /dev/null
@@ -1,510 +0,0 @@
-# common.tcl --
-#
-#	Common code shared between tkxmllint and tkxsltproc.
-#
-#	The master version of this file is in the TclDOM project.
-#
-# Copyright (c) 2005 Explain
-# http://www.explain.com.au
-# Copyright (c) 2004 Zveno
-# http://www.zveno.com/
-#
-# See the file "LICENSE" in this distribution for information on usage and
-# redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
-#
-# $Id: common.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require http
-
-# SetProperties --
-#
-#	Setup tag properties
-#
-# Arguments:
-#	win	toplevel window
-#	log	log window
-#
-# Results:
-#	Tag properties set
-
-proc SetProperties {win log} {
-
-    $log tag configure timing -background #bafdff
-    $log tag configure error -background #ff9d8d
-    $log tag configure errorhighlight -background #cd3030
-    $log tag configure related -background #ffe59f
-    $log tag configure relatedhighlight -background #e8b417
-    $log tag configure message -background #ffe59f
-    $log tag configure log -background #b9ffd4
-
-    return {}
-}
-
-# Browse --
-#
-#	Choose a file
-#
-# Arguments:
-#	win	toplevel window
-#	field	name of state variable field to update
-#	args	configuration options
-#
-# Results:
-#	Current file is set
-
-proc Browse {win field args} {
-    upvar \#0 State$win state
-
-    set w [expr {$win == "." ? {} : $win}]
-
-    array set opts {
-	-title {Select Document}
-	-type open
-	-command {}
-    }
-    array set opts $args
-
-    set cwd [pwd]
-    if {$state(cwd) != {}} {
-	set cwd $state(cwd)
-    }
-
-    switch -- $opts(-type) {
-	save {
-	    set fname [tk_getSaveFile -parent $win -title [mc $opts(-title)] -initialdir $cwd]
-	}
-	open -
-	default {
-	    set fname [tk_getOpenFile -parent $win -title [mc $opts(-title)] -initialdir $cwd]
-	}
-    }
-
-    if {![string length $fname]} {
-	return {}
-    }
-
-    set state($field) file:///$fname
-    set state(cwd) [file dirname $fname]
-
-    if {[string length $fname] && [string length $opts(-command)]} {
-	uplevel #0 $opts(-command)
-    }
-
-    return {}
-}
-
-# ReadAndParseXML --
-#
-#	Helper procedure to read an XML document from a file
-#	and parse it into a DOM tree.
-#
-# Arguments:
-#	win	toplevel window
-#	label	description of the document
-#	fname	filename of document to parse
-#	baseuri	base URI for document
-#	timearr	name of array for timing information,
-#		"start" entry must exist.
-#	args	additional options
-#
-# Results:
-#	Document read into memory.  Log messages provide feedback.
-#	Returns DOM document token.
-
-proc ReadAndParseXML {win label fname baseuri {timearr time} args} {
-    upvar 1 $timearr time
-    upvar \#0 State$win state
-
-    array set opts {
-	-noent 0
-	-nonet 0
-    }
-    array set opts $args
-
-    set state(externalentities) 0
-
-    Feedback $win [mc "Opening $label document \"$fname\""]
-    if {[string match http://* $fname]} {
-	FeedbackProgress $win 0
-	set state(start_download) [clock clicks -milliseconds]
-	if {[catch {::http::geturl $fname \
-			-command [list HTTPComplete $win] \
-			-progress [list HTTPProgress $win] \
-			-timeout 30000} token]} {
-	    tk_messageBox -message "unable to retrieve $label document \"$fname\" due to \"$token\"" -parent $win -type ok -icon error
-	    return -code error {}
-	}
-	::http::wait $token
-	if {[::http::status $token] != "ok"} {
-	    return -code error {}
-	}
-	set xml [::http::data $token]
-	::http::cleanup $token
-	set time(read) [clock clicks -milliseconds]
-    } else {
-	if {[catch {open $fname} ch]} {
-	    tk_messageBox -message "unable to open $label document \"$fname\" due to \"$ch\"" -parent $win -type ok -icon error
-	    return -code error {}
-	}
-	set time(open) [clock clicks -milliseconds]
-	Log timing $win "Opening $label document took [expr $time(open) - $time(start)]ms\n"
-
-	Feedback $win [mc "Reading $label document"]
-	# Take note of encoding information
-	set encoding {}
-	gets $ch xmldecl
-	set re ^[::sgml::cl $::xml::Wsp]*<\\?xml[::sgml::cl $::xml::Wsp]+(version[::sgml::cl $::xml::Wsp]*=[::sgml::cl $::xml::Wsp]*("|')[::sgml::cl ^"']+\\2)?[::sgml::cl $::xml::Wsp]*(encoding[::sgml::cl $::xml::Wsp]*=[::sgml::cl $::xml::Wsp]*("|')([::sgml::cl ^"']+)\\4)?[::sgml::cl $::xml::Wsp]*(standalone[::sgml::cl $::xml::Wsp]*=[::sgml::cl $::xml::Wsp]*("|')(yes|no)\\7)?[::sgml::cl $::xml::Wsp]*\\?>
-	if {[regexp $re $xmldecl discard allversion delimiter allencoding delimiter encoding allstandalone delimiter]} {
-	    if {[catch {fconfigure $ch -encoding $encoding} msg]} {
-		if {[catch {fconfigure $ch -encoding [string tolower $encoding]} msg]} {
-		    tk_messageBox -message "unable to read $label document \"$fname\" due to \"$msg\"" -parent $win -type ok -icon error
-		    return -code error {}
-		}
-	    }
-	}
-	set xml $xmldecl\n[read $ch]
-	close $ch
-	# Watch out for UTF-16 documents
-	if {[regexp "^(\xFF\xFE)|(\xFE\xFF)" $xml]} {
-	    set xml [encoding convertfrom unicode $xml]
-	}
-	set time(read) [clock clicks -milliseconds]
-	Log timing $win "Reading $label document took [expr $time(read) - $time(open)]ms\n"
-    }
-
-    Feedback $win [mc "Parsing $label XML"]
-    if {[catch {dom::parse $xml \
-	    -baseuri [uri_escape $baseuri] \
-	    -defaultexpandinternalentities $opts(-noent) \
-	    -externalentitycommand [list External $win]} doc]} {
-
-	if {[string match "unable to*" $doc]} {
-	    Log add $win $doc
-	} else {
-	    Log addXMLError $win $xml $doc
-	}
-	Feedback $win [mc "Parsing $label document failed"]
-	after 2000 [list Feedback $win {}]
-	return -code error {}
-    }
-    set time(parse) [clock clicks -milliseconds]
-    Log timing $win "Parsing $label document took [expr $time(parse) - $time(read)]ms\n"
-    set time(last) $time(parse)
-
-    if {$state(xinclude)} {
-	Feedback $win [mc "$label document XInclude processing"]
-	# TODO: handle doc in slave interp
-	if {[catch {dom::xinclude $doc} msg]} {
-	    Log addDocError $win $doc $msg
-	    Feedback $win [mc "$label document XInclude processing failed"]
-	    after 2000 [list Feedback $win {}]
-	}
-	set time(xinclude) [clock clicks -milliseconds]
-	Log timing $win "$label document XInclude took [expr $time(xinclude) - $time(last)]ms\n"
-	set time(last) $time(xinclude)
-    }
-
-    return $doc
-}
-
-# External --
-#
-#	Handle external entity references
-#
-# Arguments:
-#	win	toplevel window
-#	name	current parser
-#	baseuri	base URI of document
-#	uri	system identifier of referenced entity
-#	id	public identifier of referenced entity
-#
-# Results:
-#	This reference is logged.
-#	If loading of external entities is enabled then the entity is laoded as usual,
-#	otherwise an empty entity is returned.
-
-proc External {win name baseuri uri id} {
-    upvar \#0 State$win state
-
-    if {$state(nonet) &&
-	([string match http:* $uri] || [string match ftp:* $uri])} {
-	Log entity $win "external entity not loaded, network access not permitted: system ID \"$uri\" public ID \"$id\""
-	return {}
-    }
-
-    Log entity $win "external entity reference: system ID \"$uri\" public ID \"$id\""
-
-    incr state(externalentities)
-    # resume normal loading of external entity
-    return -code continue {}
-}
-
-# GetFilename --
-#
-#	Helper routine to retrieve resource filename
-#
-# Arguments:
-#	win	toplevel window
-#	entry	entry widget containing filename value
-#	field	member of state array containing URI
-#
-# Results:
-#	Returns filename.  If URI is not a valid file: URL,
-#	returns empty string and displays message.
-
-proc GetFilename {win entry field} {
-    upvar \#0 State$win state
-
-    set state($field) [$entry get]
-
-    if {[catch {uri::split $state($field)} spliturl]} {
-	# Try the URL as a pathname
-	set fname $state($field)
-	set state($field) file:///$state(field)
-    } else {
-	array set urlarray $spliturl
-	switch -- $urlarray(scheme) {
-	    http {
-		set fname $state($field)
-	    }
-	    file {
-		set fname $urlarray(path)
-	    }
-	    default {
-		tk_messageBox -message "\"$urlarray(scheme)\" type URLs are not supported" -parent $win -type ok -icon warning
-		return {}
-	    }
-	}
-    }
-
-    return $fname
-}
-
-# HTTPComplete --
-#
-#	HTTP download is finished
-#
-# Arguments:
-#	win	toplevel window
-#	token	http token
-#
-# Results:
-#	Set progress to completion
-
-proc HTTPComplete {win token} {
-    upvar \#0 State$win state
-
-    $state(progress) itemconfigure $state(progressbar) -state disabled
-    Log timing $win "Downloading document took [expr [clock clicks -milliseconds] - $state(start_download)]ms\n"
-
-    return {}
-}
-
-# HTTPProgress --
-#
-#	HTTP download is in progress
-#
-# Arguments:
-#	win	toplevel window
-#	token	http token
-#	total	total number of bytes to download
-#	current	number of bytes downloaded so far
-#
-# Results:
-#	Set progress bar
-
-proc HTTPProgress {win token total current} {
-    upvar \#0 State$win state
-
-    FeedbackProgress $win [expr ($current * 100) / $total]
-
-    return {}
-}
-
-# Log --
-#
-#	Manage the log window
-#
-# Arguments:
-#	win	toplevel window
-#	args	messages to display
-#
-# Results:
-#	Log window updated.
-
-proc Log {method win args} {
-    upvar \#0 State$win state
-
-    set w [expr {$win == "." ? {} : $win}]
-
-    switch -- $method {
-	clear {
-	    $state(messages).log configure -state normal
-	    $state(messages).log delete 1.0 end
-	    $state(messages).log configure -state disabled
-	}
-	view {
-	    set what [lindex $args 0]
-	    switch -- $what {
-		start {
-		    $state(messages).log see 1.0
-		}
-		end {
-		    $state(messages).log see end
-		}
-		default {
-		    return -code error "don't know how to view \"$what\""
-		}
-	    }
-	}
-	add {
-	    $state(messages).log configure -state normal
-	    $state(messages).log insert end [lindex $args 0]
-	    $state(messages).log configure -state disabled
-	    $state(messages).log see end
-	}
-	addXMLError {
-	    $state(messages).log configure -state normal
-
-	    set xml [lindex $args 0]
-	    set id 0
-	    $state(messages).log insert end [mc "Problems detected in document:\n"]
-	    foreach errormsg [lindex $args 1] {
-		foreach {domain level code node line message relatedLine dummy related1 related2} $errormsg break
-		lappend error($line) error$id
-		lappend related($relatedLine) related$id
-		$state(messages).log insert end $message [list error error$id]
-		if {[string index $message end] != "\n"} {
-		    $state(messages).log insert end \n
-		}
-		$state(messages).log tag bind error$id <Enter> [list ErrorHighlight $w $state(messages).log error$id $line $relatedLine]
-		$state(messages).log tag bind error$id <Leave> [list ErrorRemoveHighlight $w $state(messages).log error$id $line $relatedLine]
-		incr id
-	    }
-	    $state(messages).log insert end \n
-
-	    set linenum 1
-	    foreach line [split $xml \n] {
-
-		if {[info exists error($linenum)]} {
-		    $state(messages).log insert end $line "error errorline$linenum"
-		} elseif {[info exists related($linenum)]} {
-		    $state(messages).log insert end $line "related relatedline$linenum"
-		} else {
-		    $state(messages).log insert end $line
-		}
-		$state(messages).log insert end \n
-
-		incr linenum
-	    }
-
-	    $state(messages).log configure -state disabled
-	    $state(messages).log see end
-	}
-	addDocError {
-	    $state(messages).log configure -state normal
-
-	    set doc [lindex $args 0]
-	    foreach errormsg [lindex $args 1] {
-		foreach {domain level code node line message relatedLine dummy related1 related2} $errormsg break
-		$state(messages).log insert end $message
-		if {[string index $message end] != "\n"} {
-		    $state(messages).log insert end \n
-		}
-	    }
-
-	    $state(messages).log configure -state disabled
-	    $state(messages).log see end
-	}
-	addMessage {
-	    $state(messages).log configure -state normal
-	    $state(messages).log insert end [lindex $args 0] message
-	    $state(messages).log configure -state disabled
-	    $state(messages).log see end
-	}
-	timing {
-	    if {$state(timing)} {
-		$state(messages).log configure -state normal
-		$state(messages).log insert end [lindex $args 0] timing
-		$state(messages).log configure -state disabled
-		$state(messages).log see end
-	    }
-	}
-	entity {
-	    if {$state(display:entrefs)} {
-		$state(messages).log configure -state normal
-		$state(messages).log insert end [lindex $args 0] log \n
-		$state(messages).log configure -state disabled
-		$state(messages).log see end
-	    }
-	}
-	default {
-	    return -code error "unknown method \"$method\""
-	}
-    }
-
-    return {}
-}
-
-# ErrorHighlight -- Highlight an error
-
-proc ErrorHighlight {win log tag line related} {
-    $log tag configure $tag -background [$log tag cget errorhighlight -background]
-    $log tag configure errorline$line -background [$log tag cget errorhighlight -background]
-    $log tag raise errorline$line error
-    $log tag configure relatedline$related -background [$log tag cget relatedhighlight -background]
-    $log tag raise relatedline$related related
-
-    return {}
-}
-proc ErrorRemoveHighlight {win log tag line related} {
-    Feedback $win {}
-
-    $log tag configure $tag -background {}
-    $log tag configure errorline$line -background {}
-    $log tag configure relatedline$related -background {}
-
-    return {}
-}
-
-# Feedback -- Manage the feedback widget
-
-proc Feedback {win msg} {
-    upvar \#0 State$win state
-
-    set state(feedback) $msg
-    update
-
-    return {}
-}
-proc FeedbackProgress {win percent} {
-    upvar \#0 State$win state
-
-    $state(progress) coords $state(progressbar) 0 0 $percent 25
-    update
-
-    return {}
-}
-
-# Incr -- utility to increment a variable, handling non-existance
-
-proc Incr var {
-    upvar $var v
-    if {[info exists v]} {
-	incr v
-    } else {
-	set v 1
-    }
-
-    return $v
-}
-
-# This should be part of the uri package
-
-proc uri_escape uri {
-    # TODO: other characters must also be escaped
-    regsub -all { } $uri {%20} uri
-
-    return $uri
-}
-
diff --git a/tclxml-3.2/examples/tcldom/domtext.tcl b/tclxml-3.2/examples/tcldom/domtext.tcl
deleted file mode 100644
index 630ea8b..0000000
--- a/tclxml-3.2/examples/tcldom/domtext.tcl
+++ /dev/null
@@ -1,1302 +0,0 @@
-# domtext.tcl --
-#
-#	Megawidget to display a DOM document in a Text widget.
-#
-#	This widget both generates and reacts to DOM Events.
-#
-# Copyright (c) 2008 Explain
-# http://www.explain.com.au/
-# Copyright (c) 1999-2003 Zveno Pty Ltd
-# http://www.zveno.com/
-#
-# See the file "LICENSE" in this distribution for information on usage and
-# redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
-#
-# $Id: domtext.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package provide domtext 2.5
-
-# We need BWidgets
-
-package require BWidget 1.4
-
-# We need the DOM
-# V2.0 gives us Level 2 Events
-
-package require dom 3.2
-
-# Configuration options:
-#
-#	-elementbgcolorlist {colour1 colour2 ...}
-#		Specifies a list of colours to cycle through for
-#		backgrounds of sucessive element content.
-#
-#	-showtag text|tab|<empty>
-#		"text" denotes that start and end tags are shown
-#		as their XML text.  "tab" denotes that start and
-#		end tags are shown as an image.  Empty value
-#		denotes that start and end tags are not shown.
-
-namespace eval domtext {
-    Widget::tkinclude domtext text .text \
-	    remove {-command -state}
-
-    Widget::declare domtext {
-	{-highlightcolor	String	"#d9ffff"	0}
-	{-rootnode		String	""		0}
-	{-state			String	"normal"	0}
-	{-tagcolor		String	"#18605a"	0}
-	{-commentcolor		String	"#660f91"	0}
-	{-entityrefcolor	String	"#0080c0"	0}
-	{-elementbgcolorlist	String	""		0}
-	{-showxmldecl		Boolean	1		0}
-	{-showdoctypedecl	Boolean	1		0}
-	{-showtag		String	"text"		0}
-    }
-
-    proc ::domtext { path args } { return [eval domtext::create $path $args] }
-    proc use {} {}
-
-    # Define bindings for domtext widget class
-
-    # Certain mouse event bindings for the Text widget class must be overridden
-
-    bind domtext <Button-1> [namespace code [list _tkevent_override %W %x %y]]
-    bind domtext <Double-Button-1> [namespace code [list _tkevent_override %W %x %y]]
-
-    # All of these bindings for the Text widget class cause characters
-    # to be inserted or deleted.  These must be caught and prevented if the
-    # characters are part of markup, otherwise the node value must be
-    # updated
-    # TODO: update with all bindings for Text widget
-
-    foreach spec {
-	<Meta-Key-d> <Meta-Key-Delete> <Meta-Key-BackSpace>
-	<Control-Key-h> <Control-Key-t> <Control-Key-k> <Control-Key-d>
-	<Control-Key-i> <Key>
-	<<Cut>> <<Paste>> <<PasteSelection>> <<Clear>>
-	<Key-BackSpace> <Key-Delete> <Key-Return>
-    } {
-	bind domtext $spec [list domtext::_tkevent_filter_$spec %W %A]
-    }
-    foreach spec {
-	<Key-Up> <Key-Down> <Key-Left> <Key-Right>
-    } {
-	bind domtext $spec [list domtext::_key_select %W $spec]
-    }
-    foreach spec {
-	<Meta-Key> <Control-Key>
-    } {
-	bind domtext $spec {# Do nothing - allow the normal Text class binding to take effect}
-    }
-
-    variable eventTypeMap
-    array set eventTypeMap {
-	ButtonPress	mousedown
-	ButtonRelease	mouseup
-	Enter		mouseover
-	Leave		mouseout
-	Motion		mousemove
-	FocusIn		DOMFocusIn
-	FocusOut	DOMFocusOut
-    }
-}
-
-# domtext::create --
-#
-#	Widget class creation command
-#
-# Arguments:
-#	path	widget path
-#	args	configuration options
-#
-# Results:
-#	Widget created, returns path
-
-proc domtext::create {path args} {
-    upvar #0 [namespace current]::$path data
-    array set maps [list Text {} :text {} .text {}]
-
-    eval frame $path $maps(:text) -bd 0 -relief flat -takefocus 0 \
-	    -class domtext -highlightthickness 0
-
-    Widget::initFromODB domtext $path $maps(Text)
-
-    # Setup event bindings for generating DOM events
-    bindtags $path [list $path Bwdomtext [winfo toplevel $path] all]
-
-    set text [eval text $path.text $maps(.text) \
-	    -state [Widget::getMegawidgetOption $path -state] -wrap none \
-	    -takefocus 1]
-    $text tag configure starttab -elide 1
-    $text tag configure endtab -elide 1
-    $text tag configure xmldecl -elide 1
-    $text tag configure doctypedecl -elide 1
-
-    bindtags $path [list $path domtext [winfo toplevel $path] all]
-
-    grid $text -sticky news
-    grid rowconfigure $path 0 -weight 1
-    grid columnconfigure $path 0 -weight 1
-
-    # Certain class bindings must be overridden
-    bindtags $text [list $path domtext [winfo class $text] [winfo toplevel $path] all]
-
-    rename $path ::$path:cmd
-    proc ::$path { cmd args } "return \[eval domtext::\$cmd $path \$args\]"
-
-    set root [Widget::getMegawidgetOption $path -rootnode]
-    if {[string length $root]} {
-	_refresh $path $root
-    }
-
-    set data(insert) end
-    set data(nextElemBgColor) 0
-
-    configure $path \
-	    -showtag [Widget::getMegawidgetOption $path -showtag] \
-	    -showxmldecl [Widget::getMegawidgetOption $path -showxmldecl] \
-	    -showdoctypedecl [Widget::getMegawidgetOption $path -showdoctypedecl]
-
-    return $path
-}
-
-# domtext::cget --
-#
-#	Implements the cget method
-#
-# Arguments:
-#	path	widget path
-#	option	configuration option
-#
-# Results:
-#	Returns value of option
-
-proc domtext::cget {path option} {
-    return [Widget::getoption $path $option]
-}
-
-# domtext::configure --
-#
-#	Implements the configure method
-#
-# Arguments:
-#	path	widget path
-#	args	configuration options
-#
-# Results:
-#	Sets values of options
-
-proc domtext::configure {path args} {
-    upvar #0 [namespace current]::$path data
-
-    set res [Widget::configure $path $args]
-
-    set rn [Widget::hasChanged $path -rootnode root]
-    if {$rn} {
-
-	$path.text delete 1.0 end
-	# Delete all marks and tags
-	# This doesn't delete the standard marks and tags
-	eval $path.text tag delete [$path.text tag names]
-	eval $path.text mark unset [$path.text mark names]
-	# Remove event listeners from previous DOM tree
-
-	set data(insert) 1.0
-
-	if {[string length $root]} {
-	    set docel [dom::document cget $root -documentElement]
-
-	    if {[string length $docel]} {
-		# Listen for UI events
-		dom::node addEventListener $root DOMActivate [namespace code [list _node_selected $path]] -usecapture 1
-
-		# Listen for mutation events
-		dom::node addEventListener $root DOMNodeInserted [namespace code [list _node_inserted $path]] -usecapture 1
-		dom::node addEventListener $root DOMNodeRemoved [namespace code [list _node_removed $path]] -usecapture 1
-		dom::node addEventListener $root DOMCharacterDataModified [namespace code [list _node_pcdata_modified $path]] -usecapture 1
-		dom::node addEventListener $root DOMAttrModified [namespace code [list _node_attr_modified $path]] -usecapture 1
-		dom::node addEventListener $root DOMAttrRemoved [namespace code [list _node_attr_removed $path]] -usecapture 1
-
-		_refresh $path $root
-	    }
-	}
-    }
-
-    set tc [Widget::hasChanged $path -tagcolor tagcolor]
-    set hc [Widget::hasChanged $path -highlightcolor hlcolor]
-    set cc [Widget::hasChanged $path -commentcolor commcolor]
-    set ec [Widget::hasChanged $path -entityrefcolor ercolor]
-    set ebg [Widget::hasChanged $path -elementbgcolorlist ebgcolor]
-    if {($rn && [string length $root]) || $tc} {
-	$path.text tag configure tags -foreground $tagcolor
-    }
-    if {($rn && [string length $root]) || $cc} {
-	$path.text tag configure comment -foreground $commcolor
-    }
-    if {($rn && [string length $root]) || $ec} {
-	$path.text tag configure entityreference -foreground $ercolor
-    }
-    if {($rn && [string length $root]) || $hc} {
-	$path.text tag configure highlight -background $hlcolor
-    }
-    if {($rn && [string length $root]) || $ebg} {
-	set data(nextElemBgColor) 0
-	_elementbg_setall $path $root
-    }
-
-    if {[Widget::hasChanged $path -showtag showtag]} {
-	switch -- $showtag {
-	    text {
-		$path.text tag configure starttab -elide 1
-		$path.text tag configure endtab -elide 1
-		$path.text tag configure tags -elide 0
-	    }
-	    tab {
-		$path.text tag configure tags -elide 1
-		$path.text tag configure starttab -elide 0
-		$path.text tag configure endtab -elide 0
-	    }
-	    {} {
-		$path.text tag configure tags -elide 1
-		$path.text tag configure starttab -elide 1
-		$path.text tag configure endtab -elide 1
-	    }
-	    default {
-		return -code error "invalid value \"$showtag\""
-	    }
-	}
-    }
-
-    if {[Widget::hasChanged $path -showxmldecl showxmldecl]} {
-	$path.text tag configure xmldecl -elide [expr !$showxmldecl]
-    }
-    if {[Widget::hasChanged $path -showdoctypedecl showdoctypedecl]} {
-	$path.text tag configure doctypedecl -elide [expr !$showdoctypedecl]
-    }
-    return $res
-}
-
-# domtext::xview --
-#
-#	Implements xview method
-#
-# Arguments:
-#	path	widget path
-#	args	additional arguments
-#
-# Results:
-#	Depends on Text's xview method
-
-proc domtext::xview {path args} {
-    eval $path.text xview $args
-}
-
-# domtext::yview --
-#
-#	Implements yview method
-#
-# Arguments:
-#	path	widget path
-#	args	additional arguments
-#
-# Results:
-#	Depends on Text's yview method
-
-proc domtext::yview {path args} {
-    eval $path.text yview $args
-}
-
-# domtext::_refresh --
-#
-#	Inserts serialized nodes into the Text widget,
-#	while at the same time marking up the text to support
-#	DOM-level editing functions.
-#
-#	This function is similar to the DOM package's
-#	serialization feature.  The code started by being copied
-#	from there.
-#
-#	Assumes that the widget is in normal state
-#
-# Arguments:
-#	path	widget path
-#	node	DOM node
-#
-# Results:
-#	Text widget populated with serialized text.
-
-proc domtext::_refresh {path node} {
-    upvar #0 [namespace current]::$path data
-
-    $path.text mark set $node $data(insert)
-    $path.text mark gravity $node left
-
-    set end $data(insert)
-
-    # For all nodes we bind Tk events to be able to generate DOM events
-    $path.text tag bind $node <1> [namespace code [list _tkevent_select $path $node %x %y]]
-    $path.text tag bind $node <Double-1> [namespace code [list _tkevent_open $path $node]]
-
-    $path.text tag configure $node -background [_elementbg_cycle $path]
-
-    switch [::dom::node cget $node -nodeType] {
-	document -
-	documentFragment {
-
-	    # Display the XML declaration
-	    if {0} {
-	    # OUCH!  Need an interface in the DOM package for this data
-	    array set nodeInfo [set $node]
-	    # XML Declaration attributes have a defined order, so can't use array directly
-	    array set xmldecl $nodeInfo(document:xmldecl)
-	    set xmldecllist [list version $xmldecl(version)]
-	    catch {lappend xmldecllist standalone $xmldecl(standalone)}
-	    catch {lappend xmldecllist encoding $xmldecl(encoding)}
-	    $path.text insert $data(insert) "<?xml[dom::Serialize:attributeList $xmldecllist]?>\n" [list $node xmldecl]
-	    set data(insert) [lindex [$path.text tag ranges $node] end]
-	}
-	    foreach childToken [::dom::node children $node] {
-		set end [_refresh $path $childToken]
-		set data(insert) $end
-	    }
-
-	    $path.text tag add $node $node $end
-	    $path.text tag configure xmldecl -elide [expr ![Widget::cget $path -showxmldecl]]
-	    $path.text tag raise xmldecl
-	}
-
-	element {
-
-	    # Serialize the start tag
-	    $path.text insert $data(insert) <[::dom::node cget $node -nodeName] [list tags tag:start:$node] [_serialize:attributeList [array get [::dom::node cget $node -attributes]]] [list tags attrs:$node] > [list tags tag:start:$node]
-
-	    # Add the start tab icon
-	    $path.text image create $data(insert) -image ::domtext::starttab -align center -name tab:start:$node
-	    foreach t [list starttab tags tag:start:$node] {
-		$path.text tag add $t tab:start:$node
-	    }
-
-	    set data(insert) [lindex [$path.text tag ranges tag:start:$node] end]
-
-	    # Serialize the content
-	    $path.text mark set content:$node $data(insert)
-	    $path.text mark gravity content:$node left
-	    foreach childToken [::dom::node children $node] {
-		set end [_refresh $path $childToken]
-		set data(insert) $end
-	    }
-	    $path.text tag add content:$node content:$node $end
-
-	    # Serialize the end tag
-	    $path.text insert $data(insert) </[::dom::node cget $node -nodeName]> [list tags tag:end:$node]
-	    set end [lindex [$path.text tag ranges tag:end:$node] end]
-	    # Add the end tab icon
-	    $path.text image create $end -image ::domtext::endtab -align center -name tab:end:$node
-	    foreach t [list endtab tags tag:end:$node] {
-		$path.text tag add $t tab:end:$node
-	    }
-	    set end [lindex [$path.text tag ranges tag:end:$node] end]
-
-	    set data(insert) $end
-	    $path.text tag add $node $node $end
-
-	    $path.text tag raise starttab
-	    $path.text tag raise endtab
-	    $path.text tag configure starttab -elide [expr {[Widget::cget $path -showtag] != "tab"}]
-	    $path.text tag configure endtab -elide [expr {[Widget::cget $path -showtag] != "tab"}]
-
-	}
-
-	textNode {
-	    set text [_encode [dom::node cget $node -nodeValue]]
-	    if {[string length $text]} {
-		$path.text insert $data(insert) $text $node
-		set end [lindex [$path.text tag ranges $node] 1]
-		set data(insert) $end
-	    } else {
-		set end $data(insert)
-	    }
-	}
-
-	docType {
-	    array set nodeInfo [set $node]
-	    $path.text insert $data(insert) "<!DOCTYPE $nodeInfo(doctype:name)" [list $node doctypedecl]
-	    set data(insert) [lindex [$path.text tag ranges $node] end]
-
-	    if {[string length $nodeInfo(doctype:internaldtd)]} {
-		$path.text insert $data(insert) " \[$nodeInfo(doctype:internaldtd)\]" [list $node doctypedecl]
-		set data(insert) [lindex [$path.text tag ranges $node] end]
-	    }
-
-	    $path.text insert $data(insert) >\n [list $node doctypedecl]
-	    set end [lindex [$path.text tag ranges $node] end]
-	    set data(insert) $end
-	    $path.text tag configure doctypedecl -elide [expr ![Widget::cget $path -showdoctypedecl]]
-	    $path.text tag raise doctypedecl
-	}
-
-	comment {
-	    set text [::dom::node cget $node -nodeValue]
-	    $path.text insert $data(insert) <!-- [list comment markup $node] $text [list comment $node] --> [list comment markup $node]
-	    set end [lindex [$path.text tag ranges $node] 1]
-	    set data(insert) $end
-	}
-
-	entityReference {
-	    set text [::dom::node cget $node -nodeName]
-	    $path.text insert $data(insert) & [list entityreference markup $node] $text [list entityreference $node] \; [list entityreference markup $node]
-	    set end [lindex [$path.text tag ranges $node] 1]
-	    set data(insert) $end
-	}
-
-	processingInstruction {
-	    set text [::dom::node cget $node -nodeValue]
-	    if {[string length $text]} {
-		set text " $text"
-	    }
-	    $path.text insert $data(insert) "<?[::dom::node cget $node -nodeName]$text?>" $node
-	    set end [lindex [$path.text tag ranges $node] 1]
-	    set data(insert) $end
-	}
-
-	default {
-	    # Ignore it
-	}
-
-    }
-
-    return $end
-}
-
-# domtext::_serialize:attributeList --
-#
-#	Produce textual representation of an attribute list.
-#
-#	NB. This is copied from TclDOM's domimpl.tcl,
-#	but with the namespace handling removed.
-#
-# Arguments:
-#	atlist	name/value list of attributes
-#
-# Results:
-#	Returns string
-
-proc domtext::_serialize:attributeList atlist {
-
-    set result {}
-    foreach {name value} $atlist {
-
-	append result { } $name =
-
-	# Handle special characters
-	regsub -all & $value {\&} value
-	regsub -all < $value {\<} value
-
-	if {![string match *\"* $value]} {
-	    append result \"$value\"
-	} elseif {![string match *'* $value]} {
-	    append result '$value'
-	} else {
-	    regsub -all \" $value {\"} value
-	    append result \"$value\"
-	}
-
-    }
-
-    return $result
-}
-
-# domtext::_encode --
-#
-#	Protect XML special characters
-#
-#	NB. This is copied from TclDOM's domimpl.tcl.
-#
-# Arguments:
-#	value	text
-#
-# Results:
-#	Returns string
-
-proc domtext::_encode value {
-    array set Entity {
-	$ $
-	< <
-	> >
-	& &
-	\" "
-	' '
-    }
-
-    regsub -all {([$<>&"'])} $value {$Entity(\1)} value
-
-    return [subst -nocommand -nobackslash $value]
-}
-
-# domtext::_elementbg_setall --
-#
-#	Recurse node hierarchy setting element background color property
-#
-# Arguments:
-#	path	widget path
-#	node	DOM node
-#
-# Results:
-#	Text widget tag configured
-
-proc domtext::_elementbg_setall {path node} {
-
-    $path.text tag configure $node -background [_elementbg_cycle $path]
-
-    switch [dom::node cget $node -nodeType] {
-	document -
-	documentFragment -
-	element {
-	    foreach child [dom::node children $node] {
-		_elementbg_setall $path $child
-	    }
-	}
-	default {
-	    # No more to do here
-	}
-    }
-
-    return {}
-}
-proc domtext::_elementbg_cycle path {
-    upvar #0 [namespace current]::$path data
-
-    set list [Widget::cget $path -elementbgcolorlist]
-    set colour [lindex $list $data(nextElemBgColor)]
-
-    set data(nextElemBgColor) [expr [incr data(nextElemBgColor)] % [llength $$list]]
-
-    return $colour
-}
-
-# domtext::_node_inserted --
-#
-#	React to addition of a node
-#
-# Arguments:
-#	path	widget path
-#	evid	DOM event node
-#
-# Results:
-#	Display updated to reflect change to DOM structure
-
-proc domtext::_node_inserted {path evid} {
-    upvar #0 [namespace current]::$path data
-
-    set node [dom::event cget $evid -target]
-
-    # Remove parent's content and then render new content
-    set parent [dom::node parent $node]
-    set tags [$path.text tag ranges $parent]
-    set start [lindex $tags 0]
-    set end [lindex $tags end]
-    if {[string length $start]} {
-	$path.text delete $start $end
-    } else {
-	set start end
-    }
-
-    set data(insert) $start
-    set end [_refresh $path $parent]
-
-    # Restore grandparent element tags
-    set parent [::dom::node parent $parent]
-    while {[string length $parent]} {
-	set ranges [$path.text tag ranges $parent]
-	catch {eval [list $path.text] tag remove [list $parent] $ranges}
-	catch {$path.text tag add $parent [lindex $ranges 0] [lindex $ranges end]}
-	# Also do content tag for elements
-	if {![string compare [::dom::node cget $parent -nodeType] "element"]} {
-	    set ranges [$path.text tag ranges content:$parent]
-	    catch {eval [list $path.text] tag remove [list $parent] $ranges}
-	    catch {$path.text tag add content:$parent [lindex $ranges 0] [lindex $ranges end]}
-	}
-
-	set parent [::dom::node parent $parent]
-    }
-
-    return {}
-}
-
-# domtext::_node_removed --
-#
-#	React to removal of a node.
-#	This is almost identical to node insertion,
-#	except that we must get the parent from the event.
-#
-# Arguments:
-#	path	widget path
-#	evid	DOM event node
-#
-# Results:
-#	Display updated to reflect change to DOM structure
-
-proc domtext::_node_removed {path evid} {
-    upvar #0 [namespace current]::selected$path selected
-
-    set node [dom::event cget $evid -target]
-
-    if {[info exists selected] && ![string compare $node $selected]} {
-	unset selected
-    }
-
-    # Remove parent's content and then render new content
-    set parent [dom::event cget $evid -relatedNode]
-    set tags [$path.text tag ranges $parent]
-    set start [lindex $tags 0]
-    set end [lindex $tags end]
-    if {[string length $start]} {
-	$path.text delete $start $end
-    } else {
-	set start end
-    }
-
-    set data(insert) $start
-    set end [_refresh $path $parent]
-
-    # Restore grandparent element tags
-    set parent [::dom::node parent $parent]
-    while {[string length $parent]} {
-	set ranges [$path.text tag ranges $parent]
-	catch {eval [list $path.text] tag remove [list $parent] $ranges}
-	catch {$path.text tag add $parent [lindex $ranges 0] [lindex $ranges end]}
-	# Also do content tag for elements
-	if {![string compare [::dom::node cget $parent -nodeType] "element"]} {
-	    set ranges [$path.text tag ranges content:$parent]
-	    catch {eval [list $path.text] tag remove [list $parent] $ranges}
-	    catch {$path.text tag add content:$parent [lindex $ranges 0] [lindex $ranges end]}
-	}
-
-	set parent [::dom::node parent $parent]
-    }
-
-    return {}
-}
-
-# domtext::_node_attr_modified --
-#
-#	React to a change in the attribute list for a node
-#
-# Arguments:
-#	path	widget path
-#	evid	DOM event node
-#
-# Results:
-#	Display updated to reflect change to DOM structure
-
-proc domtext::_node_attr_modified {path evid} {
-
-    set node [dom::event cget $evid -target]
-
-    set tags [$path.text tag ranges attrs:$node]
-    if {[llength $tags]} {
-
-	# Remove previously defined attributes
-
-	foreach {start end} $tags break
-	set existingTags [$path.text tag names $start]
-	$path.text delete $start $end
-	$path.text tag delete attrs:$node
-
-    } else {
-	set tagStartEnd [lindex [$path.text tag ranges tag:start:$node] end]
-	set start [$path.text index "$tagStartEnd - 1 char"]
-	set existingTags [$path.text tag names $start]
-    }
-
-    # Replace with current attributes
-
-    lappend existingTags attrs:$node
-    $path.text insert $start [::dom::Serialize:attributeList [array get [::dom::node cget $node -attributes]]] $existingTags
-
-    return {}
-}
-
-# domtext::_node_attr_removed --
-#
-#	React to a change in the attribute list for a node
-#
-# Arguments:
-#	path	widget path
-#	evid	DOM event node
-#
-# Results:
-#	Display updated to reflect change to DOM structure
-
-proc domtext::_node_attr_removed {path evid} {
-    _node_attr_modified $path $evid
-}
-
-# domtext::_node_pcdata_modified --
-#
-#	React to a change in character data
-#
-# Arguments:
-#	path	widget path
-#	evid	DOM event node
-#
-# Results:
-#	Display updated to reflect change to DOM structure
-
-proc domtext::_node_pcdata_modified {path evid} {
-
-    set node [dom::event cget $evid -target]
-
-    if {[string compare [dom::node cget $node -nodeType] "textNode"]} {
-	return -code error "node is not a text node"
-    }
-
-    # Remember where the insertion point is
-    set insert [$path.text index insert]
-
-    # Remove previous text
-    set ranges [$path.text tag ranges $node]
-    set tags [$path.text tag names [lindex $ranges 0]]
-    eval [list $path.text] delete $ranges
-
-    # Replace with new text
-    $path.text insert [lindex $ranges 0] [dom::event cget $evid -newValue] $tags
-
-    # Restore insertion point
-    $path.text mark set insert $insert
-
-    return {}
-}
-
-# domtext::_node_selected --
-#
-#	A node has been selected.
-#
-# Arguments:
-#	path	widget path
-#	evid	DOM event node
-#
-# Results:
-#	Node's text is selected
-
-proc domtext::_node_selected {path evid} {
-    upvar #0 [namespace current]::selected$path selected
-
-    set node [dom::event cget $evid -target]
-    set selected $node
-
-    catch {eval [list $path.text] tag remove sel [$path.text tag ranges sel]}
-
-    set ranges [$path.text tag ranges $node]
-    if {[llength $ranges]} {
-	eval [list $path.text] tag add sel $ranges
-    }
-
-    $path.text mark set insert [lindex $ranges end]
-
-    return {}
-}
-
-# domtext::_tkevent_override --
-#
-#	Certain Text widget class bindings must be prevented from firing
-#
-# Arguments:
-#	path	widget path
-#	x	x coord
-#	y	y coord
-#
-# Results:
-#	Return break error code
-
-proc domtext::_tkevent_override {w x y} {
-    return -code break
-}
-
-# domtext::_tkevent_select --
-#
-#	Single click.  We only want the highest priority tag to fire.
-#
-# Arguments:
-#	path	widget path
-#	node	DOM node
-#	x
-#	y	Coordinates
-#
-# Results:
-#	DOM event posted
-
-proc domtext::_tkevent_select {path node x y} {
-    variable tkeventid
-
-    catch {after cancel $tkeventid}
-    set tkeventid [after idle "
-    dom::event postUIEvent [list $node] DOMActivate -detail 1
-    dom::event postMouseEvent [list $node] click -detail 1
-    [namespace current]::_tkevent_select_setinsert [list $path] [list $node] [::tk::TextClosestGap $path.text $x $y]
-"]
-    return {}
-}
-
-# Helper routine for above proc
-
-proc domtext::_tkevent_select_setinsert {path node idx} {
-    switch [::dom::node cget $node -nodeType] {
-	textNode {
-	    # No need to change where the insertion point is going
-	}
-	element {
-	    # Set the insertion point to the end of the first
-	    # child textNode, or if none to immediately following
-	    # the start tag.
-	    set fc [::dom::node cget $node -firstChild]
-	    if {[string length $fc] && [::dom::node cget $fc -nodeType] == "textNode"} {
-		set idx [lindex [$path.text tag ranges $fc] end]
-	    } else {
-		set idx [lindex [$path.text tag ranges tag:start:$node] end]
-	    }
-	}
-	default {
-	    # Set the insertion point following the node
-	    set idx [lindex [$path.text tag ranges $node] end]
-	}
-    }
-
-    $path.text mark set insert $idx
-    $path.text mark set anchor insert
-    focus $path.text
-
-    return {}
-}
-
-# domtext::_tkevent_open --
-#
-#	Double click
-#
-# Arguments:
-#	path	widget path
-#	node	DOM node
-#
-# Results:
-#	DOM event posted
-
-proc domtext::_tkevent_open {path node} {
-    variable tkeventid
-
-    catch {after cancel $tkeventid}
-    set tkeventid [after idle "
-    dom::event postUIEvent [list $node] DOMActivate -detail 2
-    dom::event postMouseEvent [list $node] click -detail 2
-"]
-    return {}
-}
-
-# domtext::_key_select --
-#
-#	Select a node in which a key event has occurred.
-#
-# Arguments:
-#	path	widget path
-#	spec	the event specifier
-#
-# Results:
-#	Appropriate node is selected.  Returns node id.
-
-proc domtext::_key_select {path spec} {
-    # Once the Text widget gets the focus, it receives the event.
-    # We compensate for this here
-    if {[winfo class $path] == "Text"} {
-	set path [winfo parent $path]
-    }
-    upvar #0 [namespace current]::selected$path selected
-
-    set root [Widget::cget $path -rootnode]
-
-    # If selected node is a textNode move around the text itself
-    # Otherwise markup has been selected.
-    # Move around the nodes
-
-    switch -glob [dom::node cget $selected -nodeType],$spec {
-	textNode,<Key-Up> {
-	    set ranges [$path.text tag ranges $selected]
-	    foreach {line char} [split [lindex $ranges 0] .] break
-	    set index [$path.text index insert]
-	    foreach {iline ichar} [split [lindex $index 0] .] break
-	    if {$line == $iline} {
-		set new [dom::node parent $selected]
-	    } else {
-		::tk::TextSetCursor $path.text [::tk::TextUpDownLine $path.text -1]
-		# The insertion point may now be in another node
-		set newnode [_insert_to_node $path]
-		if {[string compare $newnode $selected]} {
-		    dom::event postUIEvent $newnode DOMActivate -detail 1
-		}
-		return -code break
-	    }
-	}
-	textNode,<Key-Down> {
-	    set ranges [$path.text tag ranges $selected]
-	    foreach {line char} [split [lindex $ranges end] .] break
-	    set index [$path.text index insert]
-	    foreach {iline ichar} [split [lindex $index 0] .] break
-	    if {$line == $iline} {
-		bell
-		return {}
-	    } else {
-		::tk::TextSetCursor $path.text [::tk::TextUpDownLine $path.text 1]
-		# The insertion point may now be in another node
-		set newnode [_insert_to_node $path]
-		if {[string compare $newnode $selected]} {
-		    dom::event postUIEvent $newnode DOMActivate -detail 1
-		}
-		return -code break
-	    }
-	}
-	textNode,<Key-Left> {
-	    set ranges [$path.text tag ranges $selected]
-	    set index [$path.text index insert]
-	    if {[$path.text compare $index == [lindex $ranges 0]]} {
-		set new [dom::node cget $selected -previousSibling]
-		if {![string length $new]} {
-		    set new [dom::node parent $selected]
-		}
-	    } else {
-		::tk::TextSetCursor $path.text insert-1c
-		return -code break
-	    }
-	}
-	textNode,<Key-Right> {
-	    set ranges [$path.text tag ranges $selected]
-	    set index [$path.text index insert]
-	    if {[$path.text compare $index == [lindex $ranges end]]} {
-		set new [dom::node cget $selected -nextSibling]
-		if {![string length $new]} {
-		    set new [dom::node parent $selected]
-		}
-	    } else {
-		::tk::TextSetCursor $path.text insert+1c
-		return -code break
-	    }
-	}
-
-	*,<Key-Up>	{
-	    set new [dom::node parent $selected]
-	}
-	*,<Key-Down>	{
-	    set new [dom::node cget $selected -firstChild]
-	    if {![string length $new]} {
-		bell
-		return {}
-	    }
-	}
-	*,<Key-Left>	{
-	    if {[dom::node parent $selected] == $root} {
-		bell
-		return {}
-	    }
-	    set new [dom::node cget $selected -previousSibling]
-	    if {![string length $new]} {
-		set new [dom::node parent $selected]
-	    }
-	}
-	*,<Key-Right>	{
-	    set new [dom::node cget $selected -nextSibling]
-	    if {![string length $new]} {
-		set new [dom::node parent $selected]
-	    }
-	}
-    }
-    if {![string length $new]} {
-	bell
-    }
-
-    dom::event postUIEvent $new DOMActivate -detail 1
-
-    return -code break
-}
-
-# domtext::_tkevent_filter_* --
-#
-#	React to editing events to keep the DOM structure
-#	synchronised
-#
-# Arguments:
-#	path	widget path
-#	detail	key pressed
-#
-# Results:
-#	Either event is blocked or passed through to the Text class binding
-#	DOM events may be generated if text is inserted or deleted
-
-proc domtext::_tkevent_filter_<Key> {path detail} {
-    # Once the Text widget gets the focus, it receives the event.
-    # We compensate for this here
-    set code ok
-    if {[winfo class $path] == "Text"} {
-	set path [winfo parent $path]
-	set code break
-    }
-    upvar #0 [namespace current]::selected$path selected
-
-    set index [$path.text index insert]
-
-    $path.text tag remove sel 0.0 end
-
-    # Take action depending upon which node type the event has occurred.
-    # Possibilities are:
-    #	text node			insert the text, update node
-    #	element				If a text node exists as first child,
-    #					redirect event to it and make it active.
-    #					Otherwise create a text node
-    #	Document Type Declaration	ignore
-    #	XML Declaration			ignore
-
-    switch [dom::node cget $selected -nodeType] {
-	element {
-	    set child [dom::node cget $selected -firstChild]
-	    if {[string length $child]} {
-		if {[dom::node cget $child -nodeType] == "textNode"} {
-		    dom::event postUIEvent $child DOMActivate -detail 1
-		    dom::node configure $child -nodeValue [dom::node cget $child -nodeValue]$detail
-		    ::tk::TextSetCursor $path.text insert+1c
-		    focus $path.text
-		    return -code $code {}
-		} else {
-		    bell
-		    return -code $code {}
-		}
-	    } else {
-		set child [dom::document createTextNode $selected $detail]
-		dom::event postUIEvent $child DOMActivate -detail 1
-		# When we return the new text node will have been
-		# inserted into the Text widget
-		set end [lindex [$path.text tag ranges $child] 1]
-		$path.text mark set insert $end
-		$path.text tag remove sel 0.0 end
-		focus $path.text
-		return -code $code {}
-	    }
-	}
-	textNode {
-
-	    # We need to know where in the character data to insert the
-	    # character.  This is hard, so instead allow the Text widget
-	    # to do the insertion then take all of the text and
-	    # set that as the node's value
-
-	    $path.text insert insert $detail $selected
-	    $path.text see insert
-	    focus $path.text
-	    set ranges [$path.text tag ranges $selected]
-	    set newvalue [$path.text get [lindex $ranges 0] [lindex $ranges end]]
-	    dom::node configure $selected -nodeValue $newvalue
-	    return -code $code {}
-
-	}
-	default {
-	    bell
-	    return -code $code {}
-	}
-    }
-
-    return -code $code {}
-}
-
-proc domtext::_tkevent_filter_<Key-Return> {path detail} {
-    set code [catch {_tkevent_filter_<Key> $path \n} msg]
-    return -code $code $msg
-}
-proc domtext::_tkevent_filter_<Control-Key-i> {path detail} {
-    set code [catch {_tkevent_filter_<Key> $path \t} msg]
-    return -code $code $msg
-}
-# Don't support transposition (yet)
-proc domtext::_tkevent_filter_<Control-Key-t> {path detail} {
-    return -code break
-}
-
-proc domtext::_tkevent_filter_<Control-Key-h> {path detail} {
-    set code [catch {_tkevent_filter_<Key-Backspace> $path $detail} msg]
-    return -code $code $msg
-}
-proc domtext::_tkevent_filter_<Key-BackSpace> {path detail} {
-    # Once the Text widget gets the focus, it receives the event.
-    # We compensate for this here
-    if {[winfo class $path] == "Text"} {
-	set path [winfo parent $path]
-    }
-    upvar #0 [namespace current]::selected$path selected
-
-    switch [dom::node cget $selected -nodeType] {
-	textNode {
-	    # If we're at the beginning of the text node stop here
-	    set ranges [$path.text tag ranges $selected]
-	    if {![llength $ranges] || [$path.text compare insert <= [lindex $ranges 0]]} {
-		bell
-		return -code break
-	    }
-	}
-	default {
-	    switch [tk_messageBox -parent [winfo toplevel $path] -title [mc {Confirm Delete Node}] -message [format [mc {Are you sure you want to delete a node of type %s?}] [dom::node cget $selected -nodeType]] -type okcancel] {
-		ok {
-		    dom::node removeNode [dom::node parent $selected] $selected
-		}
-		cancel {
-		    return -code break
-		}
-	    }
-	}
-    }
-
-    $path.text delete insert-1c
-    $path.text see insert
-
-    _tkevent_filter_update $path
-
-    return -code break
-}
-proc domtext::_tkevent_filter_<Key-Delete> {path detail} {
-    # Once the Text widget gets the focus, it receives the event.
-    # We compensate for this here
-    if {[winfo class $path] == "Text"} {
-	set path [winfo parent $path]
-    }
-    upvar #0 [namespace current]::selected$path selected
-
-    switch [dom::node cget $selected -nodeType] {
-	textNode {
-	    # If we're at the beginning of the text node stop here
-	    set ranges [$path.text tag ranges $selected]
-	    if {[$path.text compare insert >= [lindex $ranges end]]} {
-		bell
-		return -code break
-	    }
-	}
-	default {
-	    switch [tk_messageBox -parent [winfo toplevel $path] -title [mc {Confirm Delete Node}] -message [format [mc {Are you sure you want to delete a node of type %s?}] [dom::node cget $selected -nodeType]] -type okcancel] {
-		ok {
-		    dom::node removeNode [dom::node parent $selected] $selected
-		}
-		cancel {
-		    return -code break
-		}
-	    }
-	}
-    }
-
-    $path.text delete insert
-    $path.text see insert
-
-    _tkevent_filter_update $path
-
-    return -code break
-}
-proc domtext::_tkevent_filter_update path {
-    upvar #0 [namespace current]::selected$path selected
-
-    # Now update the DOM node's value
-
-    set ranges [$path.text tag ranges $selected]
-
-    # If all text has been deleted then remove the node
-    if {[llength $ranges]} {
-	set newtext [$path.text get [lindex $ranges 0] [lindex $ranges end]]
-	dom::node configure $selected -nodeValue $newtext
-    } else {
-	set parent [dom::node parent $selected]
-	dom::node removeNode [dom::node parent $selected] $selected
-	# Move selection to parent element, rather than removing selection
-	#unset selected
-	dom::event postUIEvent $parent DOMActivate -detail 1
-    }
-
-    return {}
-}
-
-# This will delete from the insertion point to the end of the line
-# or text node, whichever is shorter
-# TODO: implement this
-proc domtext::_tkevent_filter_<Control-Key-k> {path detail} {
-    return -code break
-}
-# TODO: this will delete the word to the left of the insertion point
-# (only within the text node)
-proc domtext::_tkevent_filter_<Meta-Key-Delete> {path detail} {
-    return -code break
-}
-proc domtext::_tkevent_filter_<Meta-Key-BackSpace> {path detail} {
-    _tkevent_filter_<Meta-Key-Delete> $path $detail
-}
-
-### Utilities
-
-# domtext::_insert_to_node --
-#
-#	Finds the DOM node for the insertion point
-#
-# Arguments:
-#	path	widget path
-#
-# Results:
-#	Returns DOM token
-
-proc domtext::_insert_to_node path {
-    set tags [$path.text tag names insert]
-    set newnode [lindex $tags end]
-    while {![dom::DOMImplementation isNode $newnode]} {
-	set tags [lreplace $tags end end]
-	set newnode [lindex $tags end]
-    }
-    return $newnode
-}
-
-### Inlined images
-
-image create photo ::domtext::starttab -data {
-R0lGODlhEAAYAPcAAP//////zP//mf//Zv//M///AP/M///MzP/Mmf/MZv/M
-M//MAP+Z//+ZzP+Zmf+ZZv+ZM/+ZAP9m//9mzP9mmf9mZv9mM/9mAP8z//8z
-zP8zmf8zZv8zM/8zAP8A//8AzP8Amf8AZv8AM/8AAMz//8z/zMz/mcz/Zsz/
-M8z/AMzM/8zMzMzMmczMZszMM8zMAMyZ/8yZzMyZmcyZZsyZM8yZAMxm/8xm
-zMxmmcxmZsxmM8xmAMwz/8wzzMwzmcwzZswzM8wzAMwA/8wAzMwAmcwAZswA
-M8wAAJn//5n/zJn/mZn/Zpn/M5n/AJnM/5nMzJnMmZnMZpnMM5nMAJmZ/5mZ
-zJmZmZmZZpmZM5mZAJlm/5lmzJlmmZlmZplmM5lmAJkz/5kzzJkzmZkzZpkz
-M5kzAJkA/5kAzJkAmZkAZpkAM5kAAGb//2b/zGb/mWb/Zmb/M2b/AGbM/2bM
-zGbMmWbMZmbMM2bMAGaZ/2aZzGaZmWaZZmaZM2aZAGZm/2ZmzGZmmWZmZmZm
-M2ZmAGYz/2YzzGYzmWYzZmYzM2YzAGYA/2YAzGYAmWYAZmYAM2YAADP//zP/
-zDP/mTP/ZjP/MzP/ADPM/zPMzDPMmTPMZjPMMzPMADOZ/zOZzDOZmTOZZjOZ
-MzOZADNm/zNmzDNmmTNmZjNmMzNmADMz/zMzzDMzmTMzZjMzMzMzADMA/zMA
-zDMAmTMAZjMAMzMAAAD//wD/zAD/mQD/ZgD/MwD/AADM/wDMzADMmQDMZgDM
-MwDMAACZ/wCZzACZmQCZZgCZMwCZAABm/wBmzABmmQBmZgBmMwBmAAAz/wAz
-zAAzmQAzZgAzMwAzAAAA/wAAzAAAmQAAZgAAM+4AAN0AALsAAKoAAIgAAHcA
-AFUAAEQAACIAABEAAADuAADdAAC7AACqAACIAAB3AABVAABEAAAiAAARAAAA
-7gAA3QAAuwAAqgAAiAAAdwAAVQAARAAAIgAAEe7u7t3d3bu7u6qqqoiIiHd3
-d1VVVURERCIiIhEREQAAACwAAAAAEAAYAAcIgwABCBxIsKBAfAjx2TNYMCHC
-hQwPOrwHkaFDhRQjXtR3L6PBix3teSR4USRHexUlJuTY8WRFkBQ7dsQ3sOS9
-kzNrOmR5M6dKhCFl3qP5EyPOoTpXymRJFABMkTKb2sSZL19ShDz1WSU5MeZW
-rglNfgWL9d5YsvjMRgRQte3ZtXABAggIADs=
-}
-image create photo ::domtext::endtab -data {
-R0lGODlhEAAYAPcAAP//////zP//mf//Zv//M///AP/M///MzP/Mmf/MZv/M
-M//MAP+Z//+ZzP+Zmf+ZZv+ZM/+ZAP9m//9mzP9mmf9mZv9mM/9mAP8z//8z
-zP8zmf8zZv8zM/8zAP8A//8AzP8Amf8AZv8AM/8AAMz//8z/zMz/mcz/Zsz/
-M8z/AMzM/8zMzMzMmczMZszMM8zMAMyZ/8yZzMyZmcyZZsyZM8yZAMxm/8xm
-zMxmmcxmZsxmM8xmAMwz/8wzzMwzmcwzZswzM8wzAMwA/8wAzMwAmcwAZswA
-M8wAAJn//5n/zJn/mZn/Zpn/M5n/AJnM/5nMzJnMmZnMZpnMM5nMAJmZ/5mZ
-zJmZmZmZZpmZM5mZAJlm/5lmzJlmmZlmZplmM5lmAJkz/5kzzJkzmZkzZpkz
-M5kzAJkA/5kAzJkAmZkAZpkAM5kAAGb//2b/zGb/mWb/Zmb/M2b/AGbM/2bM
-zGbMmWbMZmbMM2bMAGaZ/2aZzGaZmWaZZmaZM2aZAGZm/2ZmzGZmmWZmZmZm
-M2ZmAGYz/2YzzGYzmWYzZmYzM2YzAGYA/2YAzGYAmWYAZmYAM2YAADP//zP/
-zDP/mTP/ZjP/MzP/ADPM/zPMzDPMmTPMZjPMMzPMADOZ/zOZzDOZmTOZZjOZ
-MzOZADNm/zNmzDNmmTNmZjNmMzNmADMz/zMzzDMzmTMzZjMzMzMzADMA/zMA
-zDMAmTMAZjMAMzMAAAD//wD/zAD/mQD/ZgD/MwD/AADM/wDMzADMmQDMZgDM
-MwDMAACZ/wCZzACZmQCZZgCZMwCZAABm/wBmzABmmQBmZgBmMwBmAAAz/wAz
-zAAzmQAzZgAzMwAzAAAA/wAAzAAAmQAAZgAAM+4AAN0AALsAAKoAAIgAAHcA
-AFUAAEQAACIAABEAAADuAADdAAC7AACqAACIAAB3AABVAABEAAAiAAARAAAA
-7gAA3QAAuwAAqgAAiAAAdwAAVQAARAAAIgAAEe7u7t3d3bu7u6qqqoiIiHd3
-d1VVVURERCIiIhEREQAAACwAAAAAEAAYAAcIgwABCBxIsKDBgvbwKcR3cGDC
-hQwb2rsHMaLBiQ8XHpx4T1/Fi/c4fiRob6K+kCMBlOx4r6VHiAPxtWwpEqZA
-mSFZZlQY0+XMlxpvzsxJ0SYAnCZRGsV50mVKnDRbpsyXL+fJnRYF5mvaMeXA
-qjWDFtyqVOzYrkYNVvWqlqrbhg0BAggIADs=
-}
-
diff --git a/tclxml-3.2/examples/tcldom/domtree-treectrl.tcl b/tclxml-3.2/examples/tcldom/domtree-treectrl.tcl
deleted file mode 100644
index 81e105c..0000000
--- a/tclxml-3.2/examples/tcldom/domtree-treectrl.tcl
+++ /dev/null
@@ -1,1080 +0,0 @@
-# domtree-treectrl.tcl --
-#
-#	A megawidget to support display of a DOM hierarchy
-#	based on the treectrl widget.
-#
-#	This widget both generates and reacts to DOM Events.
-#
-# This package features ordered and non-unique directories and items.
-# Paths are managed as live links into a DOM hierarchy.
-#
-# Copyright (c) 2005 Explain
-# http://www.explain.com.au/
-# Copyright (c) 2004 Zveno Pty Ltd
-# http://www.zveno.com/
-#
-# See the file "LICENSE" in this distribution for information on usage and
-# redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
-#
-# $Id: domtree-treectrl.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package provide domtree::treectrl 3.1
-
-# We need the treectrl widget
-
-package require treectrl 1.1
-
-# We need the DOM
-# V2.0 gives us Level 2 event model
-# V2.1 gives us libxml2
-
-package require dom 3.1
-
-namespace eval domtree {
-    # Just make sure this namespace exists
-    variable exists {}
-}
-namespace eval domtree::treectrl {
-    variable defaults
-    array set defaults {
-	showlength 20
-	showtextcontent 0
-	showelementid 0
-    }
-
-    catch {font create [namespace current]::bold -weight bold}
-
-    proc ::domtree::treectrl { path args } { return [eval domtree::treectrl::create $path $args] }
-
-    # We may be able to use tktreectrl's event mechanism
-    # to exactly match treectrl events to DOM events
-    variable eventTypeMap
-    array set eventTypeMap {
-	ButtonPress	mousedown
-	ButtonRelease	mouseup
-	Enter		mouseover
-	Leave		mouseout
-	Motion		mousemove
-	FocusIn		DOMFocusIn
-	FocusOut	DOMFocusOut
-    }
-}
-
-# domtree::treectrl::create --
-#
-#	Create a DOM Treectrl widget
-#
-# Arguments:
-#	path	widget path
-#	args	configuration options
-#
-# Results:
-#	Tree widget created
-
-proc domtree::treectrl::create {path args} {
-    upvar \#0 [namespace current]::Widget$path widget
-
-    eval frame $path -bd 0 -relief flat -takefocus 0 \
-	    -class domtree::treectrl -highlightthickness 0
-
-    bindtags $path [list $path domtree::treectrl [winfo toplevel $path] all]
-
-    set tree [eval treectrl $path.tree -showroot yes -showrootbutton yes \
-		  -showbuttons yes -showlines yes \
-		  -itemheight 0 \
-		  -openbuttonimage ::domtree::collapse -closedbuttonimage ::domtree::expand]
-
-    $path.tree column create -expand yes -text Elements -tag element
-    $path.tree column create -text Attributes -tag attr
-    $path.tree column create -text Depth -tag depth
-
-    $path.tree element create e1 image -image {::domtree::element {open} ::domtree::element {}}
-    $path.tree element create Edocument image -image ::domtree::textNode
-    $path.tree element create EtextNode text
-    $path.tree element create Ecomment image -image ::domtree::Comment
-    $path.tree element create e3 text \
-	-fill [list [$path cget -highlightcolor] {selected focus}] \
-	-font [list [namespace current]::bold {}]
-    $path.tree element create e4 text -fill blue
-    $path.tree element create e6 text
-    $path.tree element create e5 rect -showfocus yes \
-	-fill [list [$path cget -highlightbackground] {selected focus} gray {selected !focus}]
-
-    $path.tree style create Selement
-    $path.tree style elements Selement {e5 e1 e3 e4}
-    $path.tree style layout Selement e1 -padx {0 4} -expand ns
-    $path.tree style layout Selement e3 -padx {0 4} -expand ns
-    $path.tree style layout Selement e4 -padx {0 6} -expand ns
-    $path.tree style layout Selement e5 -union [list e3] -iexpand ns -ipadx 2
-
-    $path.tree style create Sdocument
-    $path.tree style elements Sdocument {e5 Edocument e3 e4}
-    $path.tree style layout Sdocument Edocument -padx {0 4} -expand ns
-    $path.tree style layout Sdocument e3 -padx {0 4} -expand ns
-    $path.tree style layout Sdocument e4 -padx {0 6} -expand ns
-    $path.tree style layout Sdocument e5 -union [list e3] -iexpand ns -ipadx 2
-
-    $path.tree style create StextNode
-    $path.tree style elements StextNode EtextNode
-    $path.tree style layout StextNode EtextNode -padx {0 4} -squeeze x
-
-    $path.tree style create Scomment
-    $path.tree style elements Scomment {e5 Ecomment e3 e4}
-    $path.tree style layout Scomment Ecomment -padx {0 4} -expand ns
-    $path.tree style layout Scomment e3 -padx {0 4} -expand ns
-    $path.tree style layout Scomment e4 -padx {0 6} -expand ns
-    $path.tree style layout Scomment e5 -union [list e3] -iexpand ns -ipadx 2
-
-    $path.tree style create s3
-    $path.tree style elements s3 {e6}
-    $path.tree style layout s3 e6 -padx 6 -expand ns
-
-    # Create custom event to allow mapping to DOM nodes
-    $path.tree notify install event MapDOMNode
-
-    # Set various bindings to generate DOM events
-
-    if {0} {
-    foreach event {ButtonRelease ButtonPress Enter Leave Motion} {
-	$path.tree bindImage <$event> [namespace code [list _node_mouse_event $event {} $path]]
-	$path.tree bindText <$event> [namespace code [list _node_mouse_event $event {} $path]]
-	foreach modifier {Control Shift Alt Meta Double} {
-	    $path.tree bindImage <$modifier-$event> [namespace code [list _node_mouse_event $event $modifier $path]]
-	    $path.tree bindText <$modifier-$event> [namespace code [list _node_mouse_event $event $modifier $path]]
-	}
-    }
-    }
-
-    grid $tree -row 0 -column 0 -sticky news
-    grid rowconfigure $path 0 -weight 1
-    grid columnconfigure $path 0 -weight 1
-
-    rename $path ::$path:cmd
-    proc ::$path { cmd args } "return \[eval domtree::treectrl::cmd $path \$cmd \$args\]"
-
-    array set widget {
-	-rootnode {}
-	-populate normal
-    }
-
-    foreach {option value} $args {
-	configure $path $option $value
-    }
-
-    return $path
-}
-
-# domtree::treectrl::see --
-#
-#	Display a DOM node in the tree.
-#
-# Arguments:
-#	path	widget path
-#	dnode	DOM node
-#
-# Results:
-#	The tree node for the corresponding DOM node is expanded,
-#	all parent nodes are also expanded.
-#	Returns the id of the tree item.
-
-proc domtree::treectrl::see {path dnode} {
-    foreach pathnode [dom::node path $dnode] {
-	$path.tree expand [_dnode_to_treeid $path $pathnode]
-	update idletasks
-    }
-    set id [_dnode_to_treeid $path $dnode]
-    $path.tree see $id
-    return $id
-}
-
-# domtree::treectrl::cmd --
-#
-#	Widget command
-#
-# Arguments:
-#	path	widget path
-#	method	command method
-#	args	method arguments
-#
-# Results:
-#	Depends on method.
-
-proc domtree::treectrl::cmd {path method args} {
-    return [eval [list $method $path] $args]
-}
-
-# domtree::treectrl::cget --
-#
-#	Implements the cget method
-#
-# Arguments:
-#	path	widget path
-#	option	configuration option
-#
-# Results:
-#	Returns value of option
-
-proc domtree::treectrl::cget {path option} {
-    switch -- $option {
-	-rootnode -
-	-populate {
-	    upvar \#0 [namespace current]::Widget$path widget
-
-	    return $widget($option)
-	}
-	default {
-	    return [$path.tree cget $option]
-	}
-    }
-}
-
-# domtree::treectrl::configure --
-#
-#	Implements the configure method
-#
-# Arguments:
-#	path	widget path
-#	args	configuration options
-#
-# Results:
-#	Sets value of options
-
-proc domtree::treectrl::configure {path args} {
-    if {[catch {eval configure:dbg [list $path] $args} msg]} {
-	puts stderr "domtree::treectrl::configure incurred error\n$msg"
-    }
-}
-
-proc domtree::treectrl::configure:dbg {path args} {
-    set res {}
-
-    foreach {option value} $args {
-	switch -- $option {
-	    -rootnode {
-		upvar \#0 [namespace current]::Widget$path widget
-
-		if {$widget(-rootnode) != ""} {
-		    $path.tree item delete all
-		    _dom_unmap $path $widget(-rootnode)
-		}
-
-		if {$value != ""} {
-		    set widget(-rootnode) $value
-		    _add_node $path 0 $value
-		}
-	    }
-	    -populate {
-		upvar \#0 [namespace current]::Widget$path widget
-
-		switch -- $value {
-		    {} -
-		    normal {
-			set widget(-populate) normal
-		    }
-		    lazy {
-			set widget(-populate) lazy
-		    }
-		    default {
-			return -code error "unknown value \"$value\" for option \"-populate\""
-		    }
-		}
-	    }
-	    default {
-		return [$path.tree configure $option $value]
-	    }
-	}
-    }
-
-    # May need to add these to above switch code
-    if {0} {
-		# Listen for UI events
-		dom::node addEventListener $docel DOMActivate [namespace code [list _node_selected $path]] -usecapture 1
-
-		# Listen for mutation events
-		dom::node addEventListener $docel DOMSubtreeModified [namespace code [list _node_tree_modified $path]] -usecapture 1
-		dom::node addEventListener $docel DOMNodeInserted [namespace code [list _node_inserted $path]] -usecapture 1
-		dom::node addEventListener $docel DOMNodeRemoved [namespace code [list _node_removed $path]] -usecapture 1
-		dom::node addEventListener $docel DOMCharacterDataModified [namespace code [list _node_data_modified $path]] -usecapture 1
-		dom::node addEventListener $docel DOMAttrModified [namespace code [list _node_attr_modified $path]] -usecapture 1
-		dom::node addEventListener $docel DOMAttrRemoved [namespace code [list _node_attr_removed $path]] -usecapture 1
-    }
-
-    return $res
-}
-
-# domtree::treectrl::refresh --
-#
-#	Updates the Tree display with the value of a node
-#
-# Arguments:
-#	path	widget path
-#	node	DOM node
-#
-# Results:
-#	May change node display
-
-proc domtree::treectrl::refresh {path node} {
-    _refresh $path $node
-    return {}
-}
-
-# domtree::treectrl::xview --
-#
-#	Implement xview method
-#
-# Arguments:
-#	path	widget path
-#	args	additional arguments
-#
-# Results:
-#	Depends on Tree xview method
-
-proc domtree::treectrl::xview {path args} {
-    eval $path.tree xview $args
-}
-
-# domtree::treectrl::yview --
-#
-#	Implement yview method
-#
-# Arguments:
-#	path	widget path
-#	args	additional arguments
-#
-# Results:
-#	Depends on Tree yview method
-
-proc domtree::treectrl::yview {path args} {
-    eval $path.tree yview $args
-}
-
-# domtree::treectrl::selection --
-proc domtree::treectrl::selection {path args} {
-    eval $path.tree selection $args
-}
-
-# domtree::treectrl::find --
-#
-#	Find DOM node at given location
-#
-# Arguments:
-#	path	widget path
-#	findInfo	location
-#	confine
-#
-# Results:
-#	DOM node at location
-
-proc domtree::treectrl::find {path findInfo {confine {}}} {
-    set tnode [$path.tree find $findInfo $confine]
-    return [_treeid_to_dnode $tnode]
-}
-
-# Procedures to implement display
-
-# domtree::treectrl::_refresh --
-#
-#	Configure node with appropriate images, labels, etc
-#
-# Arguments:
-#	path	widget path
-#	node	DOM node
-#	args	additional options
-#
-# Results:
-#	Tree node may have image or label changed
-
-proc domtree::treectrl::_refresh {path node args} {
-
-    switch [set nodetype [::dom::node cget $node -nodeType]] {
-	document -
-	documentFragment -
-	element {
-	    set label [dom::node cget $node -nodeName]
-	    set icon ::domtree::element
-
-	    if {![string compare $nodetype element]} {
-
-		# ID attribute display
-		if {[Widget::getoption $path -showelementid]} {
-		    array set attributes [array get [::dom::node cget $node -attributes]]
-		    if {[catch {
-			append label "    (id $attributes(id))"
-		    }] && [catch {
-			append label "    (ID $attributes(ID))"
-		    }]} {}
-		}
-
-		if {[Widget::getoption $path -showtextcontent]} {
-		    # Text content display
-		    set temp [_refresh_text_content_display_find_text $node [Widget::getoption $path -showlength]]
-		    if {[string length $temp]} {
-			append label "    \[ [_refresh_string_trim $temp [Widget::getoption $path -showlength]] \]"
-		    }
-		}
-
-	    }
-
-	    if {![string length [dom::node parent $node]]} {
-		# Root node is special
-		return {}
-	    }
-
-	}
-	textNode {
-	    array set opts [list -label [dom::node cget $node -nodeValue]]
-	    array set opts $args
-	    set label [_refresh_string_trim [string trim $opts(-label)] [Widget::getoption $path -showlength]]
-	    set icon ::domtree::textNode
-
-	    # Also do the ancestors
-	    foreach ancestor [lrange [lreplace [::dom::node path $node] end end] 1 end] {
-		_refresh $path $ancestor
-	    }
-	}
-	processingInstruction {
-	    set label [string trim [dom::node cget $node -nodeName]]
-	    set icon ::domtree::PI
-	}
-	docType {
-	    set label {}
-	    set icon ::domtree::DocType
-	}
-	comment {
-	    set label [_refresh_string_trim [string trim [::dom::node cget $node -nodeValue]] [Widget::getoption $path -showlength]]
-	    set icon ::domtree::Comment
-	}
-	entityReference {
-	    set label [::dom::node cget $node -nodeName]
-	    set icon ::domtree::EntityReference
-	}
-	default {
-	    set label $nodetype
-	    set icon ::domtree::other
-	}
-    }
-
-    catch {
-	$path.tree itemconfigure [_dom_to_tree $node] -image $icon
-	$path.tree itemconfigure [_dom_to_tree $node] -text $label
-    }
-
-    return {}
-}
-
-# domtree::treectrl::_refresh_text_content_display_find_text --
-#
-#	Searches given element for text.
-#	In future could use XPath - just get the string value
-#	of the node.
-#
-# Arguments:
-#	node	DOM element node to search
-#	len	amount of text to return
-#
-# Results:
-#	Returns string
-
-proc domtree::treectrl::_refresh_text_content_display_find_text {node len} {
-    switch -- $len {
-	0 {
-	    return {}
-	}
-	default {
-	    set text {}
-	    foreach child [::dom::node children $node] {
-		switch [::dom::node cget $child -nodeType] {
-		    document -
-		    documentFragment -
-		    element {
-			append text \
-				[_refresh_text_content_display_find_text $child [expr $len - [string length $text]]]
-		    }
-		    textNode {
-			append text [string range \
-				[::dom::node cget $child -nodeValue] \
-				0 [expr $len - [string length $text]] \
-			]
-		    }
-		    default {
-			# Nothing to do
-		    }
-		}
-		if {[string length $text] >= $len} {
-		    return $text
-		}
-	    }
-
-	    return $text
-
-	}
-    }
-
-    return {}
-}
-
-# domtree::treectrl::_refresh_all --
-#
-#	Updates display of all tree nodes
-#
-# Arguments:
-#	path	widget pathname
-#	node	Tree node
-#
-# Results:
-#	Returns empty string
-
-proc domtree::treectrl::_refresh_all {path node} {
-    foreach child [$path.tree nodes $node] {
-	_refresh $path [_tree_to_dom $child]
-	_refresh_all $path $child
-    }
-
-    return {}
-}
-
-# domtree::treectrl::_refresh_string_trim --
-#
-#	Massage text for display
-#
-# Arguments:
-#	text	text string
-#	max	maximum length for string
-#
-# Results:
-#	Returns string
-
-proc domtree::treectrl::_refresh_string_trim {text max} {
-    if {[string length $text] > $max} {
-	set text [string range $text 0 [expr $max - 3]]...
-    }
-    if {[info tclversion] >= 8.1} {
-	set dot \u2022
-    } else {
-	set dot { }
-    }
-    regsub -all [format {[%s%s%s%s]+} \n \r { } \t] $text $dot text
-    return $text
-}
-
-# domtree::treectrl::_node_selected --
-#
-#	A node has been selected.
-#
-#	This is invoked via a DOM event.
-#
-# Arguments:
-#	path	widget path
-#	evid	event node
-
-proc domtree::treectrl::_node_selected {path evid} {
-
-    set domnode [dom::event cget $evid -target]
-
-    # Temporarily remove the -selectcommand callback
-    # to avoid an infinite loop (continually posting DOM click events)
-    set cmd [$path.tree cget -selectcommand]
-    $path.tree configure -selectcommand {}
-
-    $path.tree selection set [_dom_to_tree $domnode]
-
-    $path.tree configure -selectcommand $cmd
-
-    return {}
-}
-
-# domtree::treectrl::_select_node --
-#
-#	A tree node has been selected.
-#
-# Arguments:
-#	path	widget path
-#	tree	tree path
-#	tnode	tree node
-
-proc domtree::treectrl::_select_node {path tree tnode} {
-
-    dom::event postMouseEvent [_tree_to_dom $tnode] click -detail 1
-
-    return {}
-}
-
-# domtree::treectrl::_node_mouse_event --
-#
-#	Generate DOM Mouse Event
-#
-# Arguments:
-#	event	event type
-#	mod	modifier
-#	path	widget path
-#	tnode	tree node
-#
-# Results:
-#	Event synthesized for DOM
-
-proc domtree::treectrl::_node_mouse_event {event mod path tnode} {
-    variable eventTypeMap
-
-    set type $event
-    catch {set type $eventTypeMap($event)}
-
-    set evid [dom::document createEvent [_tree_to_dom $tnode] $type]
-    dom::event initMouseEvent $evid $type 1 1 {} 0 0 0 0 0 \
-	    [expr {$mod == "Control"}] \
-	    [expr {$mod == "Alt"}] \
-	    [expr {$mod == "Shift"}] \
-	    [expr {$mod == "Meta"}] \
-	    0 {}
-    dom::node dispatchEvent [_tree_to_dom $tnode] $evid
-    dom::destroy $evid
-
-    # ButtonRelease events also generate DOMActivate events
-
-    if {![string compare $event "ButtonRelease"]} {
-	set detail 1
-	if {![string compare $mod "Double"]} {
-	    set detail 2
-	}
-	dom::event postUIEvent [_tree_to_dom $tnode] DOMActivate -detail $detail
-    }
-
-    return {}
-}
-
-# domtree::treectrl::_node_ui_event --
-#
-#	Generate DOM UI Event
-#
-# Arguments:
-#	event	event type
-#	path	widget path
-#	tnode	tree node
-#
-# Results:
-#	Event synthesized for DOM
-
-proc domtree::treectrl::_node_ui_event {event path tnode} {
-    variable eventTypeMap
-
-    set type $event
-    catch {set type $eventTypeMap($event)}
-    dom::event postUIEvent [_tree_to_dom $tnode] $type
-
-    return {}
-}
-
-# domtree::treectrl::_add_node --
-#
-#	Recurse DOM structure, inserting tree nodes as we go.
-#
-#
-# Arguments:
-#	w	tree widget path
-#	tnode	tree node to add children to
-#	dnode	DOM node corresponding to tree path above
-#
-# Results:
-#	Nodes added to tree
-
-proc domtree::treectrl::_add_node {path tnode dnode} {
-    upvar \#0 [namespace current]::Widget$path widget
-
-    switch [dom::node cget $dnode -nodeType] {
-	document {
-	    set nodename {}
-	    set hasChildren 1
-	    set text {}
-	    set attrs {}
-	}
-	element {
-	    set nodename [$dnode cget -nodeName]
-	    set hasChildren [$dnode hasChildNodes]
-	    set text {}
-	    set attrs {}
-	    foreach atnode [dom::node selectNode $dnode @*] {
-		lappend attrs [dom::node cget $atnode -nodeName]
-	    }
-	}
-	textNode {
-	    set nodename {}
-	    set hasChildren 0
-	    set text [$dnode cget -nodeValue]
-	    set attrs {}
-	}
-	default {
-	    set nodename [dom::node cget $dnode -nodeType]
-	    set hasChildren 0
-	    set text {}
-	    set attrs {}
-	}
-    }
-
-    set id [$path.tree item create]
-    if {$tnode != ""} {
-	$path.tree item lastchild $tnode $id
-    }
-    $path.tree item configure $id -button $hasChildren
-    switch [dom::node cget $dnode -nodeType] {
-	textNode {
-	    $path.tree item style set $id 0 S[dom::node cget $dnode -nodeType]
-	    $path.tree item text $id 0 $text
-	}
-	default {
-	    $path.tree item style set $id 0 S[dom::node cget $dnode -nodeType] \
-		1 s3 2 s3
-	    $path.tree item complex $id \
-		[list [list e3 -text $nodename]] \
-		[list [list e6 -text $attrs]] \
-		[list [list e6 -text [llength [dom::node path $dnode]]]]
-	}
-    }
-
-    # Create a two-way mapping between DOM node and tree id
-    $path.tree notify bind $id <MapDOMNode> [list [namespace current]::_domid $dnode]
-    dom::node addEventListener $dnode DOMActivate [list [namespace current]::_treeid $path $id]
-
-    # Implement lazy population of the tree widget
-    if {$widget(-populate) == "lazy"} {
-	$path.tree collapse $id
-	after idle [list $path.tree notify bind $id <Expand-before> [namespace code [list _node_open $path %I $id $dnode]]]
-    }
-    if {$widget(-populate) == "normal"} {
-	foreach dchild [dom::node children $dnode] {
-	    _add_node $path $id $dchild
-	}
-    }
-
-    return {}
-}
-# These should not be called
-proc domtree::treectrl::_domid {dnode} {
-    return $dnode
-}
-proc domtree::treectrl::_treeid {id} {
-    return $id
-}
-
-# domtree::treectrl::_dnode_to_treeid --
-#
-#	Find the tree item for a DOM node
-#
-# Arguments:
-#	path	widget path
-#	dnode	DOM node
-#
-# Results:
-#	Returns a tree item descriptor
-
-proc domtree::treectrl::_dnode_to_treeid {path dnode} {
-    set listener {}
-    foreach l [dom::node addEventListener $dnode DOMActivate] {
-	foreach {key dpath value} $l break
-	if {[string equal $path $dpath] && \
-		[string equal $key "[namespace current]::_treeid"]} {
-	    return $value
-	}
-    }
-
-    return {}
-}
-
-# domtree::treectrl::_treeid_to_dnode --
-#
-#	Find the DOM node for a tree item
-#
-# Arguments:
-#	path	widget path
-#	id	item descriptor
-#
-# Results:
-#	Returns a DOM node token
-
-proc domtree::treectrl::_treeid_to_dnode {path id} {
-    return [lindex [$path.tree notify bind $id <MapDOMNode>] end]
-}
-
-# domtree::treectrl::_dom_unmap --
-#
-#	Remove all event listeners for a tree widget.
-#
-# Arguments:
-#	path	widget path
-#	node	DOM node
-#
-# Results:
-#	Returns empty string.
-#	Event listeners may be removed from DOM document nodes.
-
-proc domtree::treectrl::_dom_unmap {path node} {
-    # Crashing bug in TclDOM v3.1 prevents us from cleaning up
-    return {}
-
-    foreach listener [dom::node addEventListener $node DOMActivate] {
-	foreach {key dpath value} $listener break
-	if {[string match [namespace current]::_* $key] && \
-		[string equal $dpath $path]} {
-	    # This is one of ours
-	    dom::node removeEventListener $node DOMActivate $listener
-	}
-    }
-
-    foreach child [dom::node children $node] {
-	_dom_unmap $path $child
-    }
-}
-
-# domtree::_set_client_data --
-#
-#	Manage data for tree nodes
-#
-# Arguments:
-#	path	widget path
-#	node	tree node
-#	field	field name
-#	value	value for field
-#
-# Results:
-#	Item's configuration changed
-
-proc domtree::_set_client_data {path node field value} {
-    array set nodeinfo [$path.tree itemcget $node -data]
-    set nodeinfo($field) $value
-    $path.tree itemconfigure $node -data [array get nodeinfo]
-}
-
-# domtree::_unset_client_data --
-#
-#	Manage data for tree nodes
-#
-# Arguments:
-#	path	widget path
-#	node	tree node
-#	field	field name to unset
-#
-# Results:
-#	Item's configuration changed
-
-proc domtree::_unset_client_data {path node field} {
-    array set nodeinfo [$path.tree itemcget $node -data]
-    catch {unset nodeinfo($field)}
-    $path.tree itemconfigure $node -data [array get nodeinfo]
-}
-
-# domtree::_node_open --
-#
-#	Invoked when a tree item is opened and
-#	the tree is being populated lazily.
-#
-# Arguments:
-#	path	widget path
-#	id	tree item
-#	dnode	DOM node
-#
-# Results:
-#	Tree nodes may be added
-
-proc domtree::treectrl::_node_open {path tnode id dnode} {
-    if {[string equal $tnode $id]} {
-	$path.tree notify bind $id <Expand-before> {}
-	foreach dchild [dom::node children $dnode] {
-	    _add_node $path $id $dchild
-	}
-    }
-
-    return {}
-}
-
-# domtree::_node_tree_modified --
-#
-#	Invoked when the node's subtree has changed.
-#	Could be because a child node has been removed.
-#
-#	Refresh the
-#	display of the node, since if textual content
-#	is enabled the node's string value may have
-#	changed.
-#
-# Arguments:
-#	path	widget path
-#	evid	DOM event node
-#
-# Results:
-#	Tree nodes inserted or removed
-
-proc domtree::_node_tree_modified {path evid} {
-
-    set target [dom::event cget $evid -target]
-    set children [dom::node children $target]
-    set branch [Tree::nodes $path.tree [_dom_to_tree $target]]
-    if {[llength $children] < [llength $branch]} {
-	for {set idx 0} {$idx < [llength $branch]} {incr idx} {
-	    if {![string length [lindex $children $idx]] || \
-		    [_dom_to_tree [lindex $children $idx]] != [lindex $branch $idx]} {
-		$path.tree delete [lindex $branch $idx]
-		break
-	    }
-	}
-    }
-
-    _refresh $path [dom::event cget $evid -currentNode]
-
-    return {}
-}
-
-# domtree::_node_inserted --
-#
-#	A node has been inserted.
-#
-# Arguments:
-#	path	widget path
-#	evid	DOM event node
-#
-# Results:
-#	Insert tree node
-
-proc domtree::_node_inserted {path evid} {
-
-    # Find where the node was inserted into the child list
-    set newnode [dom::event cget $evid -target]
-    set parent [dom::node parent $newnode]
-    set children [dom::node children $parent]
-    set idx [lsearch $children $newnode]
-
-    # Get old tree info
-    set tparent [_dom_to_tree $parent]
-    set branch [Tree::nodes $path.tree $tparent]
-
-    if {$idx > [llength $branch]} {
-	# Append the new node to the branch
-	$path.tree insert end $tparent [_dom_to_tree $newnode]
-    } else {
-	# Insert the new node into the branch
-	$path.tree insert $idx $tparent [_dom_to_tree $newnode]
-    }
-
-    _refresh $path $newnode
-    _add_node $path [_dom_to_tree $newnode] $newnode
-
-    return {}
-}
-
-# domtree::_node_removed --
-#
-#	A node has been removed.
-#
-# Arguments:
-#	path	widget path
-#	evid	DOM event node
-#
-# Results:
-#	Remove tree node
-
-proc domtree::_node_removed {path evid} {
-
-    set oldnode [dom::event cget $evid -target]
-    Tree::delete $path.tree [_dom_to_tree $oldnode]
-
-    return {}
-}
-
-# domtree::_node_data_modified --
-#
-#	Character data has changed
-#
-# Arguments:
-#	path	widget path
-#	evid	DOM L2 event node
-#
-# Results:
-#	Tree display updated
-
-proc domtree::_node_data_modified {path evid} {
-    _refresh $path [dom::event cget $evid -target] \
-	    -label [dom::event cget $evid -newValue]
-    return {}
-}
-
-# domtree::_node_attr_modified --
-#
-#	Attribute value modified
-#
-# Arguments:
-#	path	widget path
-#	evid	DOM L2 event node
-#
-# Results:
-#	Display updated
-
-proc domtree::_node_attr_modified {path evid} {
-    _refresh $path [dom::event cget $evid -target]
-    return {}
-}
-
-# domtree::_node_attr_removed --
-#
-#	Attribute removed
-#
-# Arguments:
-#	path	widget path
-#	evid	DOM L2 event node
-#
-# Results:
-#	Display updated
-
-proc domtree::_node_attr_removed {path evid} {
-    _refresh $path [dom::event cget $evid -target]
-    return {}
-}
-
-### Image data
-
-image create photo ::domtree::element -data {R0lGODlhEAAQANX/AP7///3//vv+/vn+/fj+/ff9/fb9/fL8/PL6+e/8++78+u37+uz7+ur7
-+ef6+d349tv49df18tT289P288718sPz773y7bPw6qzo4qTt5o3o4Ivn4IHb0nTj2XPj2Wrh
-107bzzDVxxnQwRecjBCtmRCtmA+AdA6Hew21oQ2NgQq+rQqjlQpoXApmWgm/rQeekAXMuwXG
-tQTMu////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH/C0FET0JFOklS
-MS4wAt7tACH5BAEAADMALAAAAAAQABAAAAaRwJlwCBgajZCKBeE4GhuXCCIinQycs+iUA8N4
-HgHnZyuTcUoZAyAwIAgA5LKMNGIckksHgiOXoRAnElpUCCB8MlKEGolcGBsiMIwyGCFxHBMd
-LpZxZQMPnDJ7fSVConIlKocyJSNChqcjKzEwqyMmQo+0rCYpLyUmwC1CmL/BLBQZIy3KQp7J
-yy0KAgUJCwcCQQA7
-}
-image create photo ::domtree::textNode -data {R0lGODlhEAAOAJH/AP///39/fwAAAP///yH/C0FET0JFOklSMS4wAt7tACH5BAEAAAMALAAA
-AAAQAA4AAAI0nIUpxi0AIWoOhAveouPFnHDPhV1CQHmfhFYkmbWMup6p9QbxvbJ3rrNVejuH
-4ihjAF+GAgA7
-}
-image create photo ::domtree::PI -data {R0lGODdhEAAOAPEAALLA3AAAAAAA/////ywAAAAAEAAOAAACL4yPoBvi78Jio9oqJwh3oG90
-DfSEF9dhKIioGFmqR4phFL3eaa6g+6ETaTYsw6IAADs=
-}
-image create photo ::domtree::DocType -data {R0lGODlhEAAQAKL/APfQ0MmZmYJfX2YAAEoBAf///wAAAAAAACH/C0FET0JFOklSMS4wAt7t
-ACH5BAEAAAUALAAAAAAQABAAAAM7WDKyUjBGB8AaUl4RQFhZNIxM8D2hQJBNgIUKOZ5wsbJu
-fcmNfrM1iEoWnIyKqRGqWHoFd0sdEOmAJAAAOw==
-}
-image create photo ::domtree::Comment -data {R0lGODlhEAAQAKL/AP///8fHx7CwsJ6enpycnHp6egAAAP///yH/C0FET0JFOklSMS4wAt7t
-ACH5BAEAAAcALAAAAAAQABAAAANDeLrcazBGZ4C917CKTegPBnigwmVDJ5iikWbEelpuV8hi
-bhTEMY8vGo+VE8Yeswhv1eDsCkuHb8Qj9KSRo9RniDG3CQA7
-}
-image create photo ::domtree::EntityReference -data {R0lGODlhEAAQALP/AP7+/vfQ0NOsrMmZmci5uYMwMIJfX2YAAEoBAf///wAAAAAAAAAAAAAA
-AAAAAAAAACH/C0FET0JFOklSMS4wAt7tACH5BAEAAAkALAAAAAAQABAAAARPMEl5jAlhzJ2O
-r1WmbV+CfEdGVtzJTp4xwq90XuvBmZVAeTtbxVAK0nQTYg11mKUGyJJL8ykQOiwAr1nsyDau
-mgn3+8xsFwuzeUYopR5NBAA7
-}
-image create photo ::domtree::other -data {R0lGODlhEAAOAKL/AP///39/fxAQEAAAAP///wAAAAAAAAAAACH/C0FET0JFOklSMS4wAt7t
-ACH5BAEAAAQALAAAAAAQAA4AAAM4SDSj/m8E0ByrdtI1wI4aFV6ZR5kiJpmrJ6kj+pbuGMCs
-fIO1O/MdhmcHeUkCSGJEIriQIByoIwEAOw==
-}
-image create photo ::domtree::collapse -data {R0lGODlhEAAQALIAAAAAAAAAMwAAZgAAmQAAzAAA/wAzAAAzMyH5BAUAAAYA
-LAAAAAAQABAAggAAAGZmzIiIiLu7u5mZ/8zM/////wAAAAMlaLrc/jDKSRm4
-OAMHiv8EIAwcYRKBSD6AmY4S8K4xXNFVru9SAgAh/oBUaGlzIGFuaW1hdGVk
-IEdJRiBmaWxlIHdhcyBjb25zdHJ1Y3RlZCB1c2luZyBVbGVhZCBHSUYgQW5p
-bWF0b3IgTGl0ZSwgdmlzaXQgdXMgYXQgaHR0cDovL3d3dy51bGVhZC5jb20g
-dG8gZmluZCBvdXQgbW9yZS4BVVNTUENNVAAh/wtQSUFOWUdJRjIuMAdJbWFn
-ZQEBADs=
-}
-image create photo ::domtree::expand -data {R0lGODlhEAAQALIAAAAAAAAAMwAAZgAAmQAAzAAA/wAzAAAzMyH5BAUAAAYA
-LAAAAAAQABAAggAAAGZmzIiIiLu7u5mZ/8zM/////wAAAAMnaLrc/lCB6MCk
-C5SLNeGR93UFQQRgVaLCEBasG35tB9Qdjhny7vsJACH+gFRoaXMgYW5pbWF0
-ZWQgR0lGIGZpbGUgd2FzIGNvbnN0cnVjdGVkIHVzaW5nIFVsZWFkIEdJRiBB
-bmltYXRvciBMaXRlLCB2aXNpdCB1cyBhdCBodHRwOi8vd3d3LnVsZWFkLmNv
-bSB0byBmaW5kIG91dCBtb3JlLgFVU1NQQ01UACH/C1BJQU5ZR0lGMi4wB0lt
-YWdlAQEAOw==
-}
-
diff --git a/tclxml-3.2/examples/tcldom/domtree.tcl b/tclxml-3.2/examples/tcldom/domtree.tcl
deleted file mode 100644
index 0087fe6..0000000
--- a/tclxml-3.2/examples/tcldom/domtree.tcl
+++ /dev/null
@@ -1,908 +0,0 @@
-# domtree.tcl --
-#
-#	Extension to tree (mega)widget to support display of a DOM hierarchy.
-#
-#	This widget both generates and reacts to DOM Events.
-#
-# This package features ordered and non-unique directories and items.
-# Paths are managed as live links into a DOM hierarchy.
-#
-# Copyright (c) 1999-2003 Zveno Pty Ltd
-# http://www.zveno.com/
-#
-# See the file "LICENSE" in this distribution for information on usage and
-# redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
-#
-# $Id: domtree.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package provide domtree 2.5
-
-# We need BWidgets
-
-package require BWidget 1.4
-
-# We need the DOM
-# V2.0 gives us Level 2 event model
-# V2.1 gives us libxml2
-
-package require dom 2.5
-
-namespace eval domtree {
-    Tree::use
-
-    Widget::bwinclude domtree Tree .tree
-
-    Widget::declare domtree {
-        {-rootnode         String  ""        0}
-	{-showlength       Int     20        0}
-	{-showtextcontent  Boolean 0         0}
-	{-showelementid    Boolean 0         0}
-    }
-
-    proc ::domtree { path args } { return [eval domtree::create $path $args] }
-    proc use {} {}
-
-    variable eventTypeMap
-    array set eventTypeMap {
-	ButtonPress	mousedown
-	ButtonRelease	mouseup
-	Enter		mouseover
-	Leave		mouseout
-	Motion		mousemove
-	FocusIn		DOMFocusIn
-	FocusOut	DOMFocusOut
-    }
-}
-
-# domtree::create --
-#
-#	Create a DOM Tree widget
-#
-# Arguments:
-#	path	widget path
-#	args	configuration options
-#
-# Results:
-#	Tree widget created
-
-proc domtree::create {path args} {
-    array set maps [list Tree {} :cmd {} .tree {}]
-    array set maps [Widget::parseArgs domtree $args]
-
-    eval frame $path $maps(:cmd) -bd 0 -relief flat -takefocus 0 \
-	    -class domtree -highlightthickness 0
-
-    Widget::initFromODB domtree $path $maps(Tree)
-
-    bindtags $path [list $path Bwdomtree [winfo toplevel $path] all]
-
-    set tree [eval ::Tree::create $path.tree $maps(.tree) \
-	    -opencmd [list [namespace code [list _node_open $path]]] \
-	    -selectcommand [list [namespace code [list _select_node $path]]]]
-
-    $tree configure -xscrollcommand [Widget::cget $path -xscrollcommand] \
-	-yscrollcommand [Widget::cget $path -yscrollcommand]
-
-    # Set various bindings to generate DOM events
-
-    foreach event {ButtonRelease ButtonPress Enter Leave Motion} {
-	$path.tree bindImage <$event> [namespace code [list _node_mouse_event $event {} $path]]
-	$path.tree bindText <$event> [namespace code [list _node_mouse_event $event {} $path]]
-	foreach modifier {Control Shift Alt Meta Double} {
-	    $path.tree bindImage <$modifier-$event> [namespace code [list _node_mouse_event $event $modifier $path]]
-	    $path.tree bindText <$modifier-$event> [namespace code [list _node_mouse_event $event $modifier $path]]
-	}
-    }
-
-    grid $tree -row 0 -column 0 -sticky news
-    grid rowconfigure $path 0 -weight 1
-    grid columnconfigure $path 0 -weight 1
-
-    $path configure -background [Widget::cget $path -background]
-	    
-    rename $path ::$path:cmd
-    proc ::$path { cmd args } "return \[eval domtree::\$cmd $path \$args\]"
-
-    set root [Widget::getMegawidgetOption $path -rootnode]
-    if {[string length $root]} {
-	_add_node $path root $root
-    }
-
-    return $path
-}
-
-# domtree::cget --
-#
-#	Implements the cget method
-#
-# Arguments:
-#	path	widget path
-#	option	configuration option
-#
-# Results:
-#	Returns value of option
-
-proc domtree::cget {path option} {
-    return [Widget::getoption $path $option]
-}
-
-# domtree::configure --
-#
-#	Implements the configure method
-#
-# Arguments:
-#	path	widget path
-#	args	configuration options
-#
-# Results:
-#	Sets value of options
-
-proc domtree::configure {path args} {
-    if {[catch {eval configure:dbg [list $path] $args} msg]} {
-	puts stderr "domtree::configure incurred error\n$msg"
-    } else {
-	#puts stderr [list domtree::configure ran OK]
-    }
-}
-
-proc domtree::configure:dbg {path args} {
-    set res [Widget::configure $path $args]
-
-    set rn [Widget::hasChanged $path -rootnode root]
-    if {$rn} {
-
-	eval Tree::delete $path.tree [Tree::nodes $path.tree root]
-	# Remove event listeners from previous DOM tree
-
-	if {[llength $root]} {
-	    #puts stderr [list domtree::configure root $root]
-	    set docel [dom::document cget $root -documentElement]
-	    if {[string length $docel]} {
-		_refresh $path $root
-		_add_node $path root $root
-
-		# Listen for UI events
-		dom::node addEventListener $docel DOMActivate [namespace code [list _node_selected $path]] -usecapture 1
-
-		# Listen for mutation events
-		dom::node addEventListener $docel DOMSubtreeModified [namespace code [list _node_tree_modified $path]] -usecapture 1
-		dom::node addEventListener $docel DOMNodeInserted [namespace code [list _node_inserted $path]] -usecapture 1
-		dom::node addEventListener $docel DOMNodeRemoved [namespace code [list _node_removed $path]] -usecapture 1
-		dom::node addEventListener $docel DOMCharacterDataModified [namespace code [list _node_data_modified $path]] -usecapture 1
-		dom::node addEventListener $docel DOMAttrModified [namespace code [list _node_attr_modified $path]] -usecapture 1
-		dom::node addEventListener $docel DOMAttrRemoved [namespace code [list _node_attr_removed $path]] -usecapture 1
-	    }
-	}
-    }
-
-    if {!$rn && [Widget::hasChanged $path -showtextcontent showtext]} {
-	_refresh_all $path root
-    }
-
-    return $res
-}
-
-# domtree::refresh --
-#
-#	Updates the Tree display with the value of a node
-#
-# Arguments:
-#	path	widget path
-#	node	DOM node
-#
-# Results:
-#	May change node display
-
-proc domtree::refresh {path node} {
-    _refresh $path $node
-    return {}
-}
-
-# domtree::xview --
-#
-#	Implement xview method
-#
-# Arguments:
-#	path	widget path
-#	args	additional arguments
-#
-# Results:
-#	Depends on Tree xview method
-
-proc domtree::xview {path args} {
-    eval $path.tree xview $args
-}
-
-# domtree::yview --
-#
-#	Implement yview method
-#
-# Arguments:
-#	path	widget path
-#	args	additional arguments
-#
-# Results:
-#	Depends on Tree yview method
-
-proc domtree::yview {path args} {
-    eval $path.tree yview $args
-}
-
-# domtree::find --
-#
-#	Find DOM node at given location
-#
-# Arguments:
-#	path	widget path
-#	findInfo	location
-#	confine
-#
-# Results:
-#	DOM node at location
-
-proc domtree::find {path findInfo {confine {}}} {
-    set tnode [$path.tree find $findInfo $confine]
-    return [_tree_to_dom $tnode]
-}
-
-# domtree::_dom_to_tree --
-#
-#	Map a DOM node to a tree node
-#
-# Arguments:
-#	node	DOM node id
-#
-# Results:
-#	A string suitable for use as a tree node path
-
-proc domtree::_dom_to_tree node {
-    if {[catch {dom::document cget $node -documentElement} docel]} {
-	return $node
-    } else {
-	return root
-    }
-}
-
-# domtree::_tree_to_dom --
-#
-#	Map a tree node to a DOM node
-#
-# Arguments:
-#	node	Tree node path
-#
-# Results:
-#	A string suitable for use as a DOM node id
-
-proc domtree::_tree_to_dom node {
-    if {[string compare $node "root"]} {
-	return $node
-    } else {
-	# Really want to return the document node,
-	# but don't know it here
-	return {}
-    }
-}
-
-# domtree::_open_ancestors --
-#
-#	Make sure that all ancestors of the given node are open.
-#	Don't use "opentree", since that will recursively open
-#	all children.
-#
-# Arguments:
-#	path	widget path
-#	node	tree node
-#
-# Results:
-#	All ancestors of the node are opened
-
-proc domtree::_open_ancestors {path node} {
-    while {[string compare $node root]} {
-	#$path.tree opentree $node
-	if {[namespace eval ::Tree [list Widget::getoption $path.tree.$node -open]] != 1} {
-	    namespace eval ::Tree [list Widget::setoption $path.tree.$node -open 1]
-	    uplevel #0 [namespace eval ::Tree [list Widget::getoption $path.tree -opencmd]] [list $node]
-	}
-	set node [$path.tree parent $node]
-    }
-}
-
-# Procedures to implement display
-
-# domtree::_refresh --
-#
-#	Configure node with appropriate images, labels, etc
-#
-# Arguments:
-#	path	widget path
-#	node	DOM node
-#	args	additional options
-#
-# Results:
-#	Tree node may have image or label changed
-
-proc domtree::_refresh {path node args} {
-
-    #puts stderr [list domtree::_refresh $path $node]
-
-    switch [set nodetype [::dom::node cget $node -nodeType]] {
-	document -
-	documentFragment -
-	element {
-	    set label [dom::node cget $node -nodeName]
-	    set icon ::domtree::element
-
-	    if {![string compare $nodetype element]} {
-
-		# ID attribute display
-		if {[Widget::getoption $path -showelementid]} {
-		    array set attributes [array get [::dom::node cget $node -attributes]]
-		    if {[catch {
-			append label "    (id $attributes(id))"
-		    }] && [catch {
-			append label "    (ID $attributes(ID))"
-		    }]} {}
-		}
-
-		if {[Widget::getoption $path -showtextcontent]} {
-		    # Text content display
-		    set temp [_refresh_text_content_display_find_text $node [Widget::getoption $path -showlength]]
-		    if {[string length $temp]} {
-			append label "    \[ [_refresh_string_trim $temp [Widget::getoption $path -showlength]] \]"
-		    }
-		}
-
-	    }
-
-	    if {![string length [dom::node parent $node]]} {
-		# Root node is special
-		return {}
-	    }
-
-	}
-	textNode {
-	    array set opts [list -label [dom::node cget $node -nodeValue]]
-	    array set opts $args
-	    set label [_refresh_string_trim [string trim $opts(-label)] [Widget::getoption $path -showlength]]
-	    set icon ::domtree::textNode
-
-	    # Also do the ancestors
-	    foreach ancestor [lrange [lreplace [::dom::node path $node] end end] 1 end] {
-		_refresh $path $ancestor
-	    }
-	}
-	processingInstruction {
-	    set label [string trim [dom::node cget $node -nodeName]]
-	    set icon ::domtree::PI
-	}
-	docType {
-	    set label {}
-	    set icon ::domtree::DocType
-	}
-	comment {
-	    set label [_refresh_string_trim [string trim [::dom::node cget $node -nodeValue]] [Widget::getoption $path -showlength]]
-	    set icon ::domtree::Comment
-	}
-	entityReference {
-	    set label [::dom::node cget $node -nodeName]
-	    set icon ::domtree::EntityReference
-	}
-	default {
-	    set label $nodetype
-	    set icon ::domtree::other
-	}
-    }
-
-    catch {
-	$path.tree itemconfigure [_dom_to_tree $node] -image $icon
-	$path.tree itemconfigure [_dom_to_tree $node] -text $label
-    }
-
-    return {}
-}
-
-# domtree::_refresh_text_content_display_find_text --
-#
-#	Searches given element for text.
-#	In future could use XPath - just get the string value
-#	of the node.
-#
-# Arguments:
-#	node	DOM element node to search
-#	len	amount of text to return
-#
-# Results:
-#	Returns string
-
-proc domtree::_refresh_text_content_display_find_text {node len} {
-    switch -- $len {
-	0 {
-	    return {}
-	}
-	default {
-	    set text {}
-	    foreach child [::dom::node children $node] {
-		switch [::dom::node cget $child -nodeType] {
-		    document -
-		    documentFragment -
-		    element {
-			append text \
-				[_refresh_text_content_display_find_text $child [expr $len - [string length $text]]]
-		    }
-		    textNode {
-			append text [string range \
-				[::dom::node cget $child -nodeValue] \
-				0 [expr $len - [string length $text]] \
-			]
-		    }
-		    default {
-			# Nothing to do
-		    }
-		}
-		if {[string length $text] >= $len} {
-		    return $text
-		}
-	    }
-
-	    return $text
-
-	}
-    }
-
-    return {}
-}
-
-# domtree::_refresh_all --
-#
-#	Updates display of all tree nodes
-#
-# Arguments:
-#	path	widget pathname
-#	node	Tree node
-#
-# Results:
-#	Returns empty string
-
-proc domtree::_refresh_all {path node} {
-    foreach child [$path.tree nodes $node] {
-	_refresh $path [_tree_to_dom $child]
-	_refresh_all $path $child
-    }
-
-    return {}
-}
-
-# domtree::_refresh_string_trim --
-#
-#	Massage text for display
-#
-# Arguments:
-#	text	text string
-#	max	maximum length for string
-#
-# Results:
-#	Returns string
-
-proc domtree::_refresh_string_trim {text max} {
-    if {[string length $text] > $max} {
-	set text [string range $text 0 [expr $max - 3]]...
-    }
-    if {[info tclversion] >= 8.1} {
-	set dot \u2022
-    } else {
-	set dot { }
-    }
-    regsub -all [format {[%s%s%s%s]+} \n \r { } \t] $text $dot text
-    return $text
-}
-
-# domtree::_node_selected --
-#
-#	A node has been selected.
-#
-#	This is invoked via a DOM event.
-#
-# Arguments:
-#	path	widget path
-#	evid	event node
-
-proc domtree::_node_selected {path evid} {
-
-    set domnode [dom::event cget $evid -target]
-
-    # Temporarily remove the -selectcommand callback
-    # to avoid an infinite loop (continually posting DOM click events)
-    set cmd [$path.tree cget -selectcommand]
-    $path.tree configure -selectcommand {}
-
-    $path.tree selection set [_dom_to_tree $domnode]
-
-    $path.tree configure -selectcommand $cmd
-
-    return {}
-}
-
-# domtree::_select_node --
-#
-#	A tree node has been selected.
-#
-# Arguments:
-#	path	widget path
-#	tree	tree path
-#	tnode	tree node
-
-proc domtree::_select_node {path tree tnode} {
-
-    dom::event postMouseEvent [_tree_to_dom $tnode] click -detail 1
-
-    return {}
-}
-
-# domtree::_node_mouse_event --
-#
-#	Generate DOM Mouse Event
-#
-# Arguments:
-#	event	event type
-#	mod	modifier
-#	path	widget path
-#	tnode	tree node
-#
-# Results:
-#	Event synthesized for DOM
-
-proc domtree::_node_mouse_event {event mod path tnode} {
-    variable eventTypeMap
-
-    set type $event
-    catch {set type $eventTypeMap($event)}
-
-    set evid [dom::document createEvent [_tree_to_dom $tnode] $type]
-    dom::event initMouseEvent $evid $type 1 1 {} 0 0 0 0 0 \
-	    [expr {$mod == "Control"}] \
-	    [expr {$mod == "Alt"}] \
-	    [expr {$mod == "Shift"}] \
-	    [expr {$mod == "Meta"}] \
-	    0 {}
-    dom::node dispatchEvent [_tree_to_dom $tnode] $evid
-    dom::destroy $evid
-
-    # ButtonRelease events also generate DOMActivate events
-
-    if {![string compare $event "ButtonRelease"]} {
-	set detail 1
-	if {![string compare $mod "Double"]} {
-	    set detail 2
-	}
-	dom::event postUIEvent [_tree_to_dom $tnode] DOMActivate -detail $detail
-    }
-
-    return {}
-}
-
-# domtree::_node_ui_event --
-#
-#	Generate DOM UI Event
-#
-# Arguments:
-#	event	event type
-#	path	widget path
-#	tnode	tree node
-#
-# Results:
-#	Event synthesized for DOM
-
-proc domtree::_node_ui_event {event path tnode} {
-    variable eventTypeMap
-
-    set type $event
-    catch {set type $eventTypeMap($event)}
-    dom::event postUIEvent [_tree_to_dom $tnode] $type
-
-    return {}
-}
-
-# domtree::_add_node --
-#
-#	Recurse DOM structure, inserting tree nodes as we go.
-#
-#	Trouble is, this is very expensive when beyond a certain
-#	depth we're not going to see the nodes anyway.
-#	Instead, build the tree as the user opens nodes.
-#	This will spread the cost of building the tree, and the
-#	user may never open certain nodes anyway.
-#
-# Arguments:
-#	path	widget path
-#	tnode	tree node to add children to
-#	dnode	DOM node corresponding to tree path above
-#
-# Results:
-#	Nodes added to tree
-
-proc domtree::_add_node {path tnode dnode} {
-
-    if {[string compare $tnode "root"]} {
-
-	# If the grandparent is open, then do add the items
-	# This is so that the open/close toggle is added to the parent
-
-	set parent [$path.tree parent $tnode]
-
-	if {[string compare $parent "root"]} {
-	    set grandParent [$path.tree parent $parent]
-	    if {[string compare $grandParent "root"]} {
-
-		# We are beyond the second level from the root
-
-		array set ParentInfo [$path.tree itemcget $parent -data]
-		array set GrandParentInfo [$path.tree itemcget $grandParent -data]
-		if {[info exists ParentInfo(nodeOpen)]} {
-		    # Parent is open, so add ourself
-		} elseif {[info exists GrandParentInfo(nodeOpen)]} {
-		    # Grandparent is open, so add ourself
-		} else {
-		    return {}
-		}
-
-	    } else {
-		# We are two levels down from the root.  Go ahead and build,
-		# but don't automatically mark this node as being open.
-	    }
-
-	} else {
-	    # We are a child of the root, so go ahead and build here
-	    _set_client_data $path $tnode nodeOpen 1
-	}
-
-    } else {
-	# We are the root node, so definitely go ahead and build children
-    }
-
-    foreach child [::dom::node children $dnode] {
-	# Due to lazy population of the tree, the node may already exist
-	catch {$path.tree insert end $tnode [_dom_to_tree $child]}
-	_refresh $path $child
-
-	_add_node $path [_dom_to_tree $child] $child
-    }
-
-    return {}
-}
-
-# domtree::_set_client_data --
-#
-#	Manage data for tree nodes
-#
-# Arguments:
-#	path	widget path
-#	node	tree node
-#	field	field name
-#	value	value for field
-#
-# Results:
-#	Item's configuration changed
-
-proc domtree::_set_client_data {path node field value} {
-    array set nodeinfo [$path.tree itemcget $node -data]
-    set nodeinfo($field) $value
-    $path.tree itemconfigure $node -data [array get nodeinfo]
-}
-
-# domtree::_unset_client_data --
-#
-#	Manage data for tree nodes
-#
-# Arguments:
-#	path	widget path
-#	node	tree node
-#	field	field name to unset
-#
-# Results:
-#	Item's configuration changed
-
-proc domtree::_unset_client_data {path node field} {
-    array set nodeinfo [$path.tree itemcget $node -data]
-    catch {unset nodeinfo($field)}
-    $path.tree itemconfigure $node -data [array get nodeinfo]
-}
-
-# domtree::_node_open --
-#
-#	Invoked when a tree item is opened.
-#	If we haven't done this node's children yet, 
-#	do it now.  This lazily populates the tree.
-#
-# Arguments:
-#	path	widget path
-#	node	tree node
-#
-# Results:
-#	Tree nodes may be added
-
-proc domtree::_node_open {path node} {
-
-    _set_client_data $path $node nodeOpen 1
-    _add_node $path $node [_tree_to_dom $node]
-
-    return {}
-}
-
-# domtree::_node_tree_modified --
-#
-#	Invoked when the node's subtree has changed.
-#	Could be because a child node has been removed.
-#
-#	Refresh the
-#	display of the node, since if textual content
-#	is enabled the node's string value may have
-#	changed.
-#
-# Arguments:
-#	path	widget path
-#	evid	DOM event node
-#
-# Results:
-#	Tree nodes inserted or removed
-
-proc domtree::_node_tree_modified {path evid} {
-
-    set target [dom::event cget $evid -target]
-    set children [dom::node children $target]
-    set branch [Tree::nodes $path.tree [_dom_to_tree $target]]
-    if {[llength $children] < [llength $branch]} {
-	for {set idx 0} {$idx < [llength $branch]} {incr idx} {
-	    if {![string length [lindex $children $idx]] || \
-		    [_dom_to_tree [lindex $children $idx]] != [lindex $branch $idx]} {
-		$path.tree delete [lindex $branch $idx]
-		break
-	    }
-	}
-    }
-
-    _refresh $path [dom::event cget $evid -currentNode]
-
-    return {}
-}
-
-# domtree::_node_inserted --
-#
-#	A node has been inserted.
-#
-# Arguments:
-#	path	widget path
-#	evid	DOM event node
-#
-# Results:
-#	Insert tree node
-
-proc domtree::_node_inserted {path evid} {
-
-    # Find where the node was inserted into the child list
-    set newnode [dom::event cget $evid -target]
-    set parent [dom::node parent $newnode]
-    set children [dom::node children $parent]
-    set idx [lsearch $children $newnode]
-
-    # Get old tree info
-    set tparent [_dom_to_tree $parent]
-    set branch [Tree::nodes $path.tree $tparent]
-
-    if {$idx > [llength $branch]} {
-	# Append the new node to the branch
-	$path.tree insert end $tparent [_dom_to_tree $newnode]
-    } else {
-	# Insert the new node into the branch
-	$path.tree insert $idx $tparent [_dom_to_tree $newnode]
-    }
-
-    _refresh $path $newnode
-    _add_node $path [_dom_to_tree $newnode] $newnode
-
-    return {}
-}
-
-# domtree::_node_removed --
-#
-#	A node has been removed.
-#
-# Arguments:
-#	path	widget path
-#	evid	DOM event node
-#
-# Results:
-#	Remove tree node
-
-proc domtree::_node_removed {path evid} {
-
-    set oldnode [dom::event cget $evid -target]
-    Tree::delete $path.tree [_dom_to_tree $oldnode]
-
-    return {}
-}
-
-# domtree::_node_data_modified --
-#
-#	Character data has changed
-#
-# Arguments:
-#	path	widget path
-#	evid	DOM L2 event node
-#
-# Results:
-#	Tree display updated
-
-proc domtree::_node_data_modified {path evid} {
-    _refresh $path [dom::event cget $evid -target] \
-	    -label [dom::event cget $evid -newValue]
-    return {}
-}
-
-# domtree::_node_attr_modified --
-#
-#	Attribute value modified
-#
-# Arguments:
-#	path	widget path
-#	evid	DOM L2 event node
-#
-# Results:
-#	Display updated
-
-proc domtree::_node_attr_modified {path evid} {
-    _refresh $path [dom::event cget $evid -target]
-    return {}
-}
-
-# domtree::_node_attr_removed --
-#
-#	Attribute removed
-#
-# Arguments:
-#	path	widget path
-#	evid	DOM L2 event node
-#
-# Results:
-#	Display updated
-
-proc domtree::_node_attr_removed {path evid} {
-    _refresh $path [dom::event cget $evid -target]
-    return {}
-}
-
-### Image data
-
-image create photo ::domtree::element -data {R0lGODlhEAAQANX/AP7///3//vv+/vn+/fj+/ff9/fb9/fL8/PL6+e/8++78+u37+uz7+ur7
-+ef6+d349tv49df18tT289P288718sPz773y7bPw6qzo4qTt5o3o4Ivn4IHb0nTj2XPj2Wrh
-107bzzDVxxnQwRecjBCtmRCtmA+AdA6Hew21oQ2NgQq+rQqjlQpoXApmWgm/rQeekAXMuwXG
-tQTMu////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH/C0FET0JFOklS
-MS4wAt7tACH5BAEAADMALAAAAAAQABAAAAaRwJlwCBgajZCKBeE4GhuXCCIinQycs+iUA8N4
-HgHnZyuTcUoZAyAwIAgA5LKMNGIckksHgiOXoRAnElpUCCB8MlKEGolcGBsiMIwyGCFxHBMd
-LpZxZQMPnDJ7fSVConIlKocyJSNChqcjKzEwqyMmQo+0rCYpLyUmwC1CmL/BLBQZIy3KQp7J
-yy0KAgUJCwcCQQA7
-}
-image create photo ::domtree::textNode -data {R0lGODlhEAAOAJH/AP///39/fwAAAP///yH/C0FET0JFOklSMS4wAt7tACH5BAEAAAMALAAA
-AAAQAA4AAAI0nIUpxi0AIWoOhAveouPFnHDPhV1CQHmfhFYkmbWMup6p9QbxvbJ3rrNVejuH
-4ihjAF+GAgA7
-}
-image create photo ::domtree::PI -data {R0lGODdhEAAOAPEAALLA3AAAAAAA/////ywAAAAAEAAOAAACL4yPoBvi78Jio9oqJwh3oG90
-DfSEF9dhKIioGFmqR4phFL3eaa6g+6ETaTYsw6IAADs=
-}
-image create photo ::domtree::DocType -data {R0lGODlhEAAQAKL/APfQ0MmZmYJfX2YAAEoBAf///wAAAAAAACH/C0FET0JFOklSMS4wAt7t
-ACH5BAEAAAUALAAAAAAQABAAAAM7WDKyUjBGB8AaUl4RQFhZNIxM8D2hQJBNgIUKOZ5wsbJu
-fcmNfrM1iEoWnIyKqRGqWHoFd0sdEOmAJAAAOw==
-}
-image create photo ::domtree::Comment -data {R0lGODlhEAAQAKL/AP///8fHx7CwsJ6enpycnHp6egAAAP///yH/C0FET0JFOklSMS4wAt7t
-ACH5BAEAAAcALAAAAAAQABAAAANDeLrcazBGZ4C917CKTegPBnigwmVDJ5iikWbEelpuV8hi
-bhTEMY8vGo+VE8Yeswhv1eDsCkuHb8Qj9KSRo9RniDG3CQA7
-}
-image create photo ::domtree::EntityReference -data {R0lGODlhEAAQALP/AP7+/vfQ0NOsrMmZmci5uYMwMIJfX2YAAEoBAf///wAAAAAAAAAAAAAA
-AAAAAAAAACH/C0FET0JFOklSMS4wAt7tACH5BAEAAAkALAAAAAAQABAAAARPMEl5jAlhzJ2O
-r1WmbV+CfEdGVtzJTp4xwq90XuvBmZVAeTtbxVAK0nQTYg11mKUGyJJL8ykQOiwAr1nsyDau
-mgn3+8xsFwuzeUYopR5NBAA7
-}
-image create photo ::domtree::other -data {R0lGODlhEAAOAKL/AP///39/fxAQEAAAAP///wAAAAAAAAAAACH/C0FET0JFOklSMS4wAt7t
-ACH5BAEAAAQALAAAAAAQAA4AAAM4SDSj/m8E0ByrdtI1wI4aFV6ZR5kiJpmrJ6kj+pbuGMCs
-fIO1O/MdhmcHeUkCSGJEIriQIByoIwEAOw==
-}
-
diff --git a/tclxml-3.2/examples/tcldom/pwrdLogo150.gif.b64 b/tclxml-3.2/examples/tcldom/pwrdLogo150.gif.b64
deleted file mode 100644
index 0e3f0b6..0000000
--- a/tclxml-3.2/examples/tcldom/pwrdLogo150.gif.b64
+++ /dev/null
@@ -1,56 +0,0 @@
-R0lGODlhYQCWAPUAAP//////zP//mf//AP/MzP/Mmf/MAP+Zmf+ZZv+ZAMz/
-/8zM/8zMzMyZzMyZmcyZZsyZAMxmZsxmM8xmAMwzM8wzAJnM/5nMzJmZzJmZ
-mZlmmZlmZplmM5kzM5kzAGaZzGZmzGZmmWZmZmYzZmYzMzNmzDNmmTMzmTMz
-ZgAzmQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
-AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH+BSAtZGwtACH5BAEKAAIALAAA
-AABhAJYAAAb+QIFwSCwaj8ikcslsOp/Oh1RClVSu2KxWAu16jY9IpGrVms9o
-9OPLJqbf8Lic2/7K0ZN0IpG/p9dGCAgPZBSGZ05+WRADBmcTA5EDfYqVcomV
-jJNnkpGOlqBvmIqeZwaSBhOUoaxZo3eaq1eQkbKttxVOFIqnn1qnm7jCV7q8
-AxBmscPDdEy7frVmkQnLzE5ld43JkdXDEdek1L/BlhKE3VffTdhy5LPalRIF
-APQABOhP7HHuFQnHlRHqCbxXLR8vaQMqHRAIYMECeg8KRjmYBZIvOfPoLfiQ
-ouMJBwEkNonoRxyWU7bSEKjHsaPLFBn0tXpC8o4sbncWNjTxsqf+hmU0Fa2y
-mJPehZ5IT3QYBoWVv5RmAgLAgBQpCaBPWJ2aQ69lVZcollFoGgoenJVUv7o8
-Ua1Zk1CQTKZZeFSty6XL3DIJxQjZGwkN7bq8amkCnzOAXil6ehYAT8Fh3xg2
-IPeKv1RaEr8FtfXNAwBe7cbxNw3hxQobPnxQDO20mQAMBHckDAeYa9JaRvRc
-UtZ1loWP7UYeXVoLLS0odispW1kLgLqCPdwh7VeL2SvJXZrgXZhfls/B1dIm
-7r0CvxMvQXCvBAlqBQKxIZ+hYuo6lgmue65e3j0NYBCy4VUBBQ+sBEBIZpzS
-XD+2KKeETHFAkgYCAMgWGQUMMASATNH+mGGLBw4mASEc+KmUll0joJBdRyBc
-AJFx9r3RQYhIjFhbGgAAKNtXAQCAgBaMLIjGjNoxYeMbQgK241corHTAOO6Z
-QWRH+ykRAShQPbDAklV14KR1vqVBwktNXLnMASdy6VIFL95XnphkMmHmMATo
-qKZHFNDDjj+VrJhCmdUQEJ6aI0j1zBUDCJnGitsxUZMwAdz5UgcLEfSOJSuq
-t9kw8UmawnsAPInFHpag11FWy3R6Jwp5bphFmHDEuakwaapJwmcIzqLoG7Lu
-tUwGnqbgJQCP7sqrS6gOo0GwbAJwaAVRpjFlo7PisoFag76Ewmei3jJllb4O
-c21VJmQ72Er+w4x5arLCTPnSCaEhxQGx6SLLLi7udoQCCbX25ICluOi2Lmu3
-WMWvWk0eWYnAJ5C1DFIdbNCvSxr8uEx2JTjMyqN+fppBvC850E124IbLygHd
-+hkWAyV8Nd4w9t4LykoWCzybB45VNVw1MRNciYEMpDhpBxVWhc4VPVc7cz0b
-veRBBAp0eXQFHVHrhIChrATdSxU4sGVPI2ShsCJEavoE1kuDHFYDW3e01AEE
-xL0MkV6gbclKdoJVAQNtr5Vht/gOLPPdOfd01VRqbQDAnLio6wUuwEHM5sQd
-OeDqMDM23AXkRffUwX9qoTt3ChlvfstCVXkAelUn2FPNjCUrbcn+Z6ZyHVDe
-L4UQ6ut/Pn7LZx1/Ct5XGtDLsx23AGazvl0XjlQGi3fTOxQY4KJ8T2FFXpXl
-Y1ditRMhCAPAuHpnaG4K3Hdj9hPh47Ih2Ht3jtRC+HjxEy4ERAD/SkzS380X
-7btF/vYnv5eM4DP160IAW4EyP13lIS4DTAKhsEBWROAAy3tgAe/Cpu4p4gs7
-Y4UECKCu2VQAgqnr4P+8EDZhkPAlGvxKBSS4wi60EH/uimFSKlCgCT7hhqeT
-AAxPuMEUhCV/PnQCEFsRgQcMEYVgG+HRvPCBlzGwdmGD4qQK4MFKaKYJJbDb
-yVaUxSLS52hfZIIJxBgKBNisjEgZATb+uniHNC5BWHkRgd4sAIDadUQ6MyQA
-HefQBTwuY1nM42N4UCABuOmpG3phgiG9UT7n4bGRj2xLIdkYCiF6pAIYsGQF
-OkACFIDgcnmBAkc4GQquhbJlVTnlFJ+wSuthY0XNw51LQJArkTSBJ6y8A2BI
-siIPFE+XHcEAwLDihI7Q6UAO8ErEQPOVBgCOmU1wpjB0kqZpUo4Aj8KmJD81
-DADAcjBEmxgKnDXLZpJzm20bQZ76loIN9NKX4xSLJcPikO1dU5xKaEk1tPSu
-vUUNewEYpB+eAKAQ4qIAaWoeUjawTHwqgScOxZ80aactQU4tF+7MKP50RALA
-nDMFIvinRZP+wLyjRTMFcqSmS0T2UZBm04gfDQEIwiJTmNb0CggIaU1RwBYC
-QOen6WhCS0S6jLAV4GtLnJo6lqAjplZjIR0I5jKmqgRYWhUUEArIs34aySMM
-hhmfKcB8UInUshrhrMsAgFrPED2kXsGtRYBrOedqBgJYzK54JYJexebRSsgV
-DQfgq11vmgIrViAgCj3sGSJQ0ZoyQZpmkIdc/4qFCx4gnFeQbGYBYFcsMMFO
-YoSsGeCWjoqK1gxs/akaORiV2AKmDP7Lwmu1AM7S2pSltNWCan9zOQrIZLe/
-Uaxs7xjcLAwXC/M4EnKxQMPFMvePk43tQrAxVjYp1zkKDcU4tVn+W30MEwv/
-nC4W/FraJYQGDYAhwDVHSIgDsAOT8p1LZduJhLz5Z0RnLMd+k1iEk/p2vaW1
-4xD8eOArqBSNSuhJg2eY4AhzbcKlDayEMZdVEpAgqyDW6tE0fGE5gNjDKSJq
-sLCnohaP4MUv9rCMPxxiTuI1NMPxwIlLqSI/rvjHXILCSY0I5CIbWXCzPbKS
-jwyFJTu5yE1+spQ9FeUpW3lH37vulbf8lSxbGCkluMAFdFkCBjStJxhoGQZ4
-kuaeiLlWLbrAkE3w5p6E+QIgK5ITkJmCDyjgAwU0wVROWSsMUGUqrfOxOQf1
-gQWEsieCLgGjN9JTOz9hyC7x8yn1E5/VRtvZnA0BwddeMpV4NdrTLxE0BnDn
-aVQjJXZJOB+gGRAvDHT6oKSmNQBojRTQsJoegxL0B4bc6lHr5wlqcfVLSgCa
-EiigXy4yQYZ8nALHTNrRkF60fhbgbMrBGglqAYGqXgLo58RyS6KuigIUMO4P
-XMAECggPvNmtn3VTrs/I5rK+q1Llfft7epf9t8ChAIKCG/zgBi+XwhfOcIUL
-3C51iHgRPgACTO9b4hhPAsXPt+SMe1ypIOA4lT9OclVKOlglT3kbKi5yJKv8
-5V+g+JBhTvOaGyEIADs=
diff --git a/tclxml-3.2/examples/tcldom/simple.tcl b/tclxml-3.2/examples/tcldom/simple.tcl
deleted file mode 100644
index 1eaa7b5..0000000
--- a/tclxml-3.2/examples/tcldom/simple.tcl
+++ /dev/null
@@ -1,25 +0,0 @@
-#!/bin/sh
-# -*- tcl -*- \
-exec tclsh "$0" "$@"
-
-# simple.tcl --
-#
-#	Simple character count of a DOM document,
-#	from README.
-#
-# Copyright (c) 2008 Explain
-# http://www.explain.com.au/
-#
-# $Id: simple.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require xml 3.2
-
-set doc [dom::parse [read stdin]]
-set count 0
-foreach textNode [dom::selectNode $doc //text()] {
-    incr count [string length [$textNode cget -nodeValue]]
-}
-
-puts "The document contains $count characters"
-exit 0
-
diff --git a/tclxml-3.2/examples/tcldom/tkxmllint.tcl b/tclxml-3.2/examples/tcldom/tkxmllint.tcl
deleted file mode 100644
index e3bba56..0000000
--- a/tclxml-3.2/examples/tcldom/tkxmllint.tcl
+++ /dev/null
@@ -1,665 +0,0 @@
-#!/bin/sh
-# \
-exec wish "$0" "$@"
-
-# tkxmllint --
-#
-#	Simple GUI for xmllint-style processing of XML documents
-#
-# Copyright (c) 2005-2007 Explain
-# http://www.explain.com.au/
-# Copyright (c) 2003-2004 Zveno
-# http://www.zveno.com/
-#
-# See the file "LICENSE" in this distribution for information on usage and
-# redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
-#
-# $Id: tkxmllint.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-# Global initialisation
-
-set VERSION 1.9
-
-# Temporary hack for TclApp-wrapped executables
-lappend auto_path [file dirname [info nameofexecutable]]
-
-package require dom::libxml2 3.2
-
-package require msgcat
-namespace import ::msgcat::mc
-
-package require uri 1.2
-
-tk appname tkxmllint
-
-# We need the code shared with tkxsltproc
-source [file join [file dirname [info script]] common.tcl]
-
-# Init --
-#
-#	Create the GUI
-#
-# Arguments:
-#	win	toplevel window
-#
-# Results:
-#	Tk widgets created
-
-proc Init win {
-    upvar \#0 State$win state
-
-    set w [expr {$win == "." ? {} : $win}]
-
-    array set state {
-	url {}
-	cwd {}
-	noent 0
-	nonet 0
-
-	display:entrefs 0
-    }
-
-    wm title $win "Tk XML Lint"
-
-    switch [tk windowingsystem] {
-	aqua -
-	classic {
-	    set metakey Command
-	    set metakeylabel Command-
-	}
-	default {
-	    set metakey Control
-	    set metakeylabel Ctrl+
-	}
-    }
-
-    menu $w.menu -tearoff 0
-    $win configure -menu $w.menu
-    $w.menu add cascade -label [mc File] -menu $w.menu.file
-    menu $w.menu.file -tearoff 1
-    $w.menu.file add command -label [mc {New Window}] -command NewWindow -accel ${metakeylabel}N
-    bind $win <${metakey}-n> NewWindow
-    $w.menu.file add separator
-    $w.menu.file add command -label [mc {Save As...}] -command [list SaveAs $win] -state disabled
-    $w.menu.file add separator
-    $w.menu.file add command -label [mc Quit] -command {destroy .} -accel ${metakeylabel}Q
-    bind $win <${metakey}-q> {destroy .}
-
-    $w.menu add cascade -label [mc Help] -menu $w.menu.help
-    menu $w.menu.help -tearoff 0
-    $w.menu.help add command -label [mc {About tkxmllint}] -command tkAboutDialog -accel ${metakeylabel}?
-    # This fails on Linux
-    catch {bind $win <${metakey}-?> tkAboutDialog}
-
-    if {$::tcl_platform(platform) == "macintosh" ||
-	($::tcl_platform(platform) == "unix" && $::tcl_platform(os) == "Darwin")} {
-	$w.menu add cascade -label tkxmllint -menu $w.menu.apple
-	menu $w.menu.apple -tearoff 0
-	$w.menu.apple add command -label [mc {About tkxmllint}] -command tkAboutDialog
-    }
-
-    frame $w.controls
-    grid $w.controls - -row 0 -column 0 -sticky ew
-    button $w.controls.check -text [mc Check] -command [list Check $win]
-    # TODO: add a nice icon
-    grid $w.controls.check -row 0 -column 0 -sticky w
-    grid columnconfigure $w.controls 0 -weight 1
-
-    labelframe $w.doc -text [mc Document]
-    grid $w.doc - -row 1 -column 0 -sticky ew
-    label $w.doc.url -text [mc URL:]
-    entry $w.doc.urlentry -width 60 -textvariable State${win}(url)
-    button $w.doc.browse -text [mc Browse] -command [list Browse $win url -title {Select XML Document}]
-    grid $w.doc.url -row 0 -column 0 -sticky w
-    grid $w.doc.urlentry -row 0 -column 1 -sticky ew
-    grid $w.doc.browse -row 0 -column 2 -sticky e
-    grid columnconfigure $w.doc 1 -weight 1
-
-    labelframe $w.options -text [mc Options]
-    grid $w.options - -row 2 -column 0 -sticky news
-    checkbutton $w.options.noout -text [mc {Display document}] -variable State${win}(display)
-    checkbutton $w.options.timing -text [mc {Display timing}] -variable State${win}(timing)
-    checkbutton $w.options.xinclude -text [mc XInclude] -variable State${win}(xinclude)
-    checkbutton $w.options.noent -text [mc {Substitute entities}] -variable State${win}(noent)
-    checkbutton $w.options.logentities -text [mc {Log entities}] -variable State${win}(display:entrefs)
-    checkbutton $w.options.nonet -text [mc {No network}] -variable State${win}(nonet)
-    menubutton $w.options.encode -text [mc Encoding...] -menu $w.options.encode.menu
-    set m [menu $w.options.encode.menu -tearoff 0]
-    $m add radiobutton -label [mc utf-8] -variable ::State${win}(encoding) -value utf-8
-    $m add radiobutton -label [mc ascii] -variable ::State${win}(encoding) -value ascii
-    entry $w.options.encoding -textvariable ::State${win}(encoding)
-    set state(encoding) utf-8
-    grid $w.options.noout -row 0 -column 0 -sticky w
-    grid $w.options.timing -row 1 -column 0 -sticky w
-    grid $w.options.logentities -row 2 -column 0 -sticky w
-    grid $w.options.xinclude -row 0 -column 1 -sticky w
-    grid $w.options.noent -row 1 -column 1 -sticky w
-    grid $w.options.nonet -row 2 -column 1 -sticky w
-    grid $w.options.encode -row 0 -column 2 -sticky w
-    grid $w.options.encoding -row 0 -column 3 -sticky ew
-    grid columnconfigure $w.options 3 -weight 1
-
-    labelframe $w.validation -text [mc Validation]
-    grid $w.validation - -row 3 -column 0 -sticky news
-    radiobutton $w.validation.none -text [mc none] -variable State${win}(validate) -value no
-    radiobutton $w.validation.dtd -text [mc DTD] -variable State${win}(validate) -value dtd
-    radiobutton $w.validation.wxs -text [mc WXS] -variable State${win}(validate) -value wxs
-    labelframe $w.validation.doc -text [mc {Schema Document}]
-    label $w.validation.doc.url -text [mc URL:]
-    entry $w.validation.doc.urlentry -width 40 -textvariable State${win}(schemaurl)
-    button $w.validation.doc.browse -text [mc Browse] -command [list Browse $win schemaurl -title {Select Schema Document}]
-    grid $w.validation.doc.url -row 0 -column 0 -sticky w
-    grid $w.validation.doc.urlentry -row 0 -column 1 -sticky ew
-    grid $w.validation.doc.browse -row 0 -column 2 -sticky e
-    grid columnconfigure $w.validation.doc 1 -weight 1
-    set state(validate) no
-    grid $w.validation.none -row 0 -column 0 -sticky w
-    grid $w.validation.dtd -row 0 -column 1 -sticky w
-    grid $w.validation.wxs -row 0 -column 2 -sticky w
-    grid $w.validation.doc - - - -row 1 -sticky ew
-    grid columnconfigure $w.validation 2 -weight 1
-
-    set state(messages) [labelframe $w.messages -text [mc Messages]]
-    grid $w.messages - -row 4 -column 0 -sticky news
-    text $w.messages.log -wrap none \
-	-state disabled \
-	-xscrollcommand [list $w.messages.xscroll set] \
-	-yscrollcommand [list $w.messages.yscroll set]
-    scrollbar $w.messages.xscroll -orient horizontal \
-	-command [list $w.messages.log xview]
-    scrollbar $w.messages.yscroll -orient vertical \
-	-command [list $w.messages.log yview]
-    grid $w.messages.log -row 0 -column 0 -sticky news
-    grid $w.messages.yscroll -row 0 -column 1 -sticky ns
-    grid $w.messages.xscroll -row 1 -column 0 -sticky ew
-    grid rowconfigure $w.messages 0 -weight 1
-    grid columnconfigure $w.messages 0 -weight 1
-
-    SetProperties $win $w.messages.log
-
-    frame $w.feedback
-    grid $w.feedback - -row 5 -column 0 -sticky ew
-    label $w.feedback.msg -textvariable State${win}(feedback)
-    set state(progress) [canvas $w.feedback.progress \
-			     -width 100 -height 25 -relief sunken]
-    set state(progressbar) [$w.feedback.progress create rectangle 0 0 1 25 \
-				-fill blue -disabledfill white -state disabled]
-    grid $w.feedback.progress -row 0 -column 1
-    grid $w.feedback.msg -row 0 -column 0 -sticky ew
-    grid columnconfigure $w.feedback 0 -weight 1
-
-    grid rowconfigure $win 3 -weight 1
-    grid columnconfigure $win 1 -weight 1
-
-    return {}
-}
-
-# tkAboutDialog --
-#
-#	Information about this application
-#
-# Arguments:
-#	None
-#
-# Results:
-#	Displays window
-
-proc tkAboutDialog {} {
-    catch {destroy .about}
-    toplevel .about
-    catch {::tk::unsupported::MacWindowStyle style .about floatProc}
-    wm title .about [mc {About tkxmllint}]
-    label .about.libxml2logo -image libxml2Logo
-    label .about.tcllogo -image tclLogo
-    text .about.msg -width 40 -height 10 -font Arial
-    .about.msg insert end [mc [format "tkxmllint - A GUI for xmllint
-
-Version %s
-
-Powered by:
-\tlibxml2\tv%s
-\tTclXML\tv%s
-\tTcl/Tk\tv%s
-
-http://tclxml.sourceforge.net/tkxmllint.html
-" $::VERSION $::xml::libxml2::libxml2version \
-	[package require xml] [info patchlevel]]]
-
-    .about.msg configure -state disabled
-
-    grid .about.libxml2logo -row 0 -column 2 -sticky news
-    grid .about.tcllogo -row 1 -column 2 -sticky news
-    grid .about.msg -row 0 -column 1 -rowspan 2 -sticky news -padx 20 -pady 20
-    grid rowconfigure .about 0 -weight 1
-    grid rowconfigure .about 1 -weight 1
-    grid columnconfigure .about 1 -weight 1
-
-    return {}
-}
-
-# SaveAs --
-#
-#	Save document into a file
-#
-# Arguments:
-#	win	toplevel
-#
-# Results:
-#	File written
-
-proc SaveAs {win} {
-    upvar \#0 State$win state
-
-    if {![info exists state(dom)]} {
-	tk_messageBox -parent $win -title [mc {No Document}] \
-	    -message [mc {No document to save}] -type ok
-	return {}
-    }
-
-    set w [expr {$win == "." ? {} : $win}]
-
-    set cwd [pwd]
-    if {$state(cwd) != {}} {
-	set cwd $state(cwd)
-    }
-
-    set fname [tk_getSaveFile -parent $win -title [mc {Save As...}] -initialdir $cwd]
-
-    if {![string length $fname]} {
-	return {}
-    }
-
-    set state(cwd) [file dirname $fname]
-
-    if {[catch {open $fname w} ch]} {
-	tk_messageBox -parent $win -icon error -type ok -message "Unable to open \"[file nativename $fname]\" for writing"
-	return {}
-    }
-
-    fconfigure $ch -encoding $state(encoding)
-    puts $ch [dom::serialize $state(dom) -encoding $state(encoding)]
-    close $ch
-
-    return {}
-}
-
-# NewWindow --
-#
-#	Create another toplevel window
-#
-# Arguments:
-#	None
-#
-# Results:
-#	Tk toplevel created and initialised
-
-proc NewWindow {} {
-    global counter
-
-    Init [toplevel .top[Incr counter]]
-
-    return {}
-}
-
-# Check --
-#
-#	Parse the given document and display report
-#
-# Arguments:
-#	win	toplevel window
-#
-# Results:
-#	Document read into memory, parsed and report displayed
-
-proc Check win {
-    upvar \#0 State$win state
-
-    set w [expr {$win == "." ? {} : $win}]
-
-    set fname [GetFilename $win $w.doc.urlentry url]
-    if {![string length $fname]} {
-	return
-    }
-
-    set dodisplay $state(display)
-
-    Log clear $win
-    $w.menu.file entryconfigure [mc {Save As...}] -state disabled
-
-    catch {
-	dom::destroy $state(dom)
-	unset state(dom)
-    }
-
-    set time(start) [clock clicks -milliseconds]
-
-    if {[catch {ReadAndParseXML $win [mc "source"] $fname $state(url) time \
-		    -noent $state(noent) \
-		-nonet $state(nonet)} doc]} {
-	return
-    }
-    $w.menu.file entryconfigure [mc {Save As...}] -state normal
-
-    switch -- $state(validate) {
-	dtd {
-	    Feedback $win [mc "Validating document"]
-	    if {[catch {$doc dtd validate} msg]} {
-		Log addXMLError $win [dom::serialize $doc] $msg
-		Feedback $win [mc "Document is not valid"]
-		set dodisplay 0
-	    } else {
-		Log add $win $msg
-	    }
-	    set time(validate) [clock clicks -milliseconds]
-	    Log timing $win "Validation took [expr $time(validate) - $time(last)]ms\n"
-	    set time(last) $time(validate)
-	}
-	wxs {
-	    Feedback $win [mc "Schema-validating document"]
-	    set schemafname [GetFilename $win $w.validation.doc.urlentry schemaurl]
-	    if {[string length $schemafname]} {
-		set schematime(start) $time(last)
-		if {[catch {ReadAndParseXML $win [mc "schema"] $schemafname ? schematime} schemadoc]} {
-		    # continue
-		} else {
-		    set time(last) $schematime(last)
-		    Feedback $win [mc "Preparing schema"]
-		    if {[catch {$schemadoc schema compile} msg]} {
-			Log add $win $msg
-			Feedback $win [mc "Preparing schema failed"]
-			set time(schemacompile) [clock clicks -milliseconds]
-			set time(last) $time(schemacompile)
-			set dodisplay 0
-		    } else {
-			set time(schemacompile) [clock clicks -milliseconds]
-			Log timing $win "Preparing schema took [expr $time(schemacompile) - $time(last)]ms\n"
-			set time(last) $time(schemacompile)
-
-			Feedback $win [mc "Schema-validating document"]
-			if {[catch {$schemadoc schema validate $doc} msg]} {
-			    Log addXMLError $win [dom::serialize $doc] $msg
-			    Feedback $win [mc "Document is not schema-valid"]
-			    set dodisplay 0
-			} else {
-			    Log add $win $msg
-			    Feedback $win [mc "Document is schema-valid"]
-			}
-			set time(schemavalidate) [clock clicks -milliseconds]
-			Log timing $win "Schema validation took [expr $time(schemavalidate) - $time(last)]ms\n"
-			set time(last) $time(schemavalidate)
-		    }
-
-		    # TODO: cache the compiled schema
-		    dom::destroy $schemadoc
-		}
-	    }
-	}
-    }
-
-    if {$dodisplay} {
-	Log add $win [dom::serialize $doc -encoding $state(encoding)]
-	set time(serialize) [clock clicks -milliseconds]
-	Log timing $win "Displaying document took [expr $time(serialize) - $time(last)]ms\n"
-	set time(last) $time(serialize)
-    }
-
-    Feedback $win [mc "Processing completed"]
-    after 2000 [list Feedback $win {}]
-
-    # We no longer destroy the document, since the user may wish to save it
-    set state(dom) $doc
-
-    Log timing $win "Total time: [expr $time(last) - $time(start)]ms\n"
-
-    Log view $win start
-
-    return {}
-}
-
-### Image data - end of script
-
-image create photo libxml2Logo -data {
-R0lGODlhtABEAPf/AP///wAAAP7+/vz8/Onq6aSloQUKAjE0L/v7+3JybC0t
-Kb29vWJiXJSVkTQ1Mjo7OJKTjt3d3YuMiUtMSpqalff394mKhuHh4fT09Bsc
-GtXV1NLS0ebm5tDQziQmI8nJxcXFwOTk5M3NyUtSUrW2sfPz8/n5+GlqZtnZ
-2UNEQZucmf39/fDw76ysqfLy8g4ODbm5stnZ1YGCgMHBvdXV0Tg5Nq2tpMrK
-yHFycAAEACwwK/L18bGwqe7u7gACAL6+uba2rWxuahMWEURLTICBfuTl4jtF
-Rm9wbfr6+nR1crCxrcXFvCcpJGRlYoSFgsnJwejo5rq6rKGinh4iHQIHALm5
-tWpsaWVmZNzc2ubm5FJSTVVYVs3NxhEWDuzs683NzHh5drCwpb29tXx9eklK
-RuDg3mFiYPb49Xp8ecLCwH1+fKmqpe/x7nV3dMHBuO3u7K2toVpaUcbGwxQY
-E3l7eGdoZlxdWX19clhZVsDAtHd4daGhmYKDge7w7n6AfWlraFxeXDY4NPP1
-8lpaWV9gXebp6mJjYXN0cEBCPlpcWlVVUfX29A4SDCgqJ6ammlZWVFpdXVda
-Wuvr6ff69ubo5vPz8uvs6paYlIWHhL29sAkJCdDQyoGBevr8+MTEuUZIRBgZ
-F4CAdKmpoo6QjFBUU11dVPX19cjIvqSknoeIhVFSUE5QTK6vrFFXVfr59+js
-7fHx8ezu60FHSQsPCV1hYL6/vcfIxW5ubKanpQMDA9TUzgQHAT0/PLq7uYaG
-fC02Nn9/dgwMC0lPUCEkH+Tm5LW1qYiIf4SEeSUqKKmpn9vb2M3S1J6fnNbZ
-2uzu7uPk4QYLBCAlIwYGBry8uJ+flfz7+AgMBvv8+fv7+pCQhltbUqOjnOHm
-6fHz8NfX1be3tFNXV3h4cd/j5gIFAODi3/j799PT09PW1AIHAtjc3czMyvP2
-9rO0rrOzq9vf4MzMw2JlZcTEvu3w8W9yb4iHg8TEw/3+/Hh4bTA6OqamoaSj
-m/b6+pCQjQIIAAIFAoCAgCH5BAEAAP8ALAAAAAC0AEQAAAj/AP8JFEjk0AQd
-uQIoXMiwocOHECNKnEixosWLGDM+zKVjwiEiA0MKVHNAo8mTKFOqXInygBqR
-Aq9oCpBLFa4vKwDo3Mmzp8+fQIMKHUq0qNGjSJP2XPEFl6qEmq6IHKSQyQ2l
-WLNq3cq1K9YbTBQOGohDIY4KXtOqXcu27c4KZQPg+EcEVIAtQAUIWDEAgd+/
-gAMLHkzY74ABKwS4Xcx465YAoIgcCSCNg8+9SExUwFDChefPoEOLHk26BAZT
-FUwgbsy69VAO0gIcmRBgkM8VCExgYOGFAAcOIYILH068uHHjvwn0cJF6gGLX
-0KNTneAhAK6lSCqw2EAkxZwu4MOL/x9Pvrz5LgfqVCnD4Q0G1c+jy2eMK4CH
-FwFQ8BSAxJQXZruwFIAPA/pgoA85JKggggoFsUwZBJSg2nyLCXAYAojFp5OF
-fWGooVIoBIBfALDsZGEFb8wTQA4BCPEJHnbEGCMhhAAiox2J4KHjI4qoosoq
-q0xAxicppIAIIrzw8kANgQSigxAJBoCMBhEQgAESH27IFxJccnlYlhT2NIAJ
-psACC3PO7TQAEou4wAIsFSCRU1awMMTTCibAksaKu3xiASvTgACCHLZ88ME7
-htoih6DxzODGNL1UQQI7SrDSAi4FFCAFMypQcEkDEGCCAx6BzMKiBOZc0EMF
-A1w25m49vP/xRg8slFABAnOG2RN/5oxiBxghvFHBnLwyY8UEIXhhSqta2amm
-KSGUtIsh+fxgiSvVYNPJNdx2e82210wi7iRnnLHIIqYIIsg6+5h7hiB99NDH
-G6+kA4EZEzCSgw8keMNBCVjuigQfaqChx8GY1BMCAS6YkKuuOq3AwS1maXAB
-LMwKUIEf+NWgSwRvmLCVswDw54IKA+Ihyg1n2PNtNTBX08nM5dRczriTXFPO
-ueoKcgYl9VRKAjnd9GB0D/K8wooZiFARwB9flNGDw0tV8EUGCh0xWQBEKBOC
-CwjoJbZSYoOp165n8zRAJVkodIIt3kiCRMSLQPFAAA48oQEHaDX/u9BOePaw
-RQ7QOMEOC/a4gjO55Zp77iLqntGHN1jsIMgOO5zhzShjoDGGHlLIGssrhRDw
-CiUyqGIqL7ZgIcmwu9Z9dwDZLBFWAErsLWEFpqBmAgKZVYBu76hVYLwJJgTf
-e3OHZcd7akgAr5nvGK5ZgRdlKNTEDx1AMXfJpmRxtwNucAFyasgbfzzySKT5
-E8krVCCJA1SAQgENnZT7OM89qwu5IHWjABFkkIYzdGMRH6CHGmTABz7IwAkR
-cEYhJjjBV9jCDFPIwTDS4A0oYIBZJpKdQoyRhyso5AofUIZyWtALAijHMz2Q
-BBR+wwEoEEASR2MBC3qwgBbYcDmVgMUX/wiAgipAwQsscIEQW4AC5VRCeC6o
-xTdioBAGwEAdHBBZyRZRhLsdIA8wUEEZoIDDN0hCEgTwAq1g8R4Q9oRkAzAF
-AQ7gAyaIwhLv6p8eLbcINkDuDN+ggwzoUADMEQACY5CBImXghwZQ4hWQJB03
-uCEONTTCB1Ooxd4+6JNFiE8hx4hCE7QXjw3oIQN6UEAGIFCGIlhBIS+YXQCS
-cLUA0KEIuMiAAurwgiSU4RkaoEMAeICfJmDhGbbgxQva8II6dIADklAGLwJw
-hU9UEQY3yOJbPgkK2oiIFVgAAywhMAPaSMALAAMTHDHAAQfUkQdsSJcee4Y5
-NlSBH7Y4AxsosP/AMRSADYLoBRoWyQcnEKEWznBHM5ZxjnSIg3QSuOQUFqA7
-BPikAnYDZRTIoJA7uCEIATBEB0igEAp4IwZYa8QTTqAQMXBBBY+IAStEFA8u
-BCIAEmDGiByAtQBs4gNYo8AmQGoGynFUEZsQwzWzqUUAVIADdwMFHLKBnxds
-Qhc1ENE7RKCCQ0QgWCZQ5990MgB2upMJSmDDDrrB1ra2NXO1ONgl2NCHS4yB
-CHRgxQ4IYFcG8gENZjCDElTghDGAIQl0GAUuaiEDBWByAeb4l0V7gtHZlQKk
-9olCMhQCgSe8oxEByMA7NkGxADjCEW7zhBUkoItH4O0U1MBPCrhgAYX/JGCU
-B3jCGBRyiiiE5QUigIFCwHCKUyxVmzp5qhczkQdtgPIJwgzAMZZgBRJ4bWpi
-VYiaSsABOjKBHT3oBhvYwFbyknetgigAGNTgBHIsogXrpYMtBIEFJzjQIHMI
-hhMaQAc66OEQR7DCFcxgiCvQcaKRLcFkeVJZhXyCDDoghA3yEA6FZMMTp9CC
-QpJxCqUGQBHFqI4HMjGI0Vb1ACg+wAme0ACF+KId2RDDKVKgkBQfYBW6tbAn
-lnDcpio3AAeIQh6OoT03LAE/E8gDIm6AAg7AYsFvHCsAEMBd77LjDXTtw3i3
-bDl1wVcNfMDCIrwhgzYUwBI9iIATHnEARijE/w8FcKAaDouDANfBEE04MGQl
-e9GMShcOPIBBGj6AWQu44RSYNcahaWy/YXAWDyDYRI2jUAwSTEMOH2ixdG1A
-gnhs4qYBoDQQLv0OzErAyD1+C1SBnAk3QOCablhFAIKxBzzIoYmcfJ+Uqdzd
-OrJDjUc72g68IQWW2QIMaHBCGejaAn6Qow+v8IasFWKNMeCigTKYcxLqbIU6
-NMHAj00wlJPr52OEoQq20IA31GBbNzwBs9T4gS3ooRAdZKPGDYg01kARBRjM
-4AYb0AUFXMyONJgjBopQCDWi8IMP6KIDpQUGhqtYhQ8g16mr/uISNB0OGMRj
-DwrhBT1AgAUWNNUnJP/jtZUl8YZYxEJWb2ABOUYxD0w8gw3sSAIELMHzGb5B
-GTMIQ2OnQIgG4EICmJAzne38bT2Lu5NZyGoAQmGDGfgrBL1QSBzycIpXgoId
-MxDBJvDjgWLoADIeF4EqRujvGcggBgMPgC9IcIMIXIAIsBbBIWgQ9617oook
-sEUIKvCcp2ZV4ywNRj6m8YFNYC0YQEgDFjAWlJRX2ddQiIUlCMBzS0yOCGgA
-Qy0EYYlvfCAWnGcDB0TQDlGsgQdrKAAJpCABCyQ920vvdtPDzef9hE/qnGDH
-B0JQiR6UgWIvaEc8wkKPb8AtBoQIAAOKwYAA2AHdGyABfoJxhFEEghkxkID/
-QsJRhS8sTBmglb4ECHGIGICgqgkwYQA+YQbBEz65HMiqB8TgCQdInwT1QAMx
-QDG8QAJyEAEY8DBRpl06oXK+RgkEYEMuxHl8pQdm9gaeJy9sUAZScAITgAg1
-8CJ8wAyXAAGjgHRKt21MB24I1nsmYgreBBlHsAEEIDxQoAF/8AIHMAig4AfT
-kAYa8AwXUAUBsA0wAHLMkAYdgAIxUAB2ISJ0oAE6pRDB0ATP9AYXEA/+pxCA
-oAHKQAN0sH0JAArBoAjMoA6DNycVQAAPcALdhAgv0AS9MAMbcAFDKBu9oA4X
-cH9AYXm9hlZZAAWUQAkSCAU9YAtocARnphxZUAsW/+AALNIQ0MALTkABJ3h7
-2sZt3saCe6ZgS2EKHEADM/ANJGB1koA8sHAB5vABo6AC8VAPN6ABIcAbZaAC
-tnCLzGALGxABwOENtkABFiBvG6ABHSAH0/ANQMgwkhAB6oALFqAEcmAOWIAF
-5lAFEgADMNAAJFAF9aABNfgcJvAGUqAO8SABFBAPaSAHdfgGUIAFjZAPIBBZ
-J4dyu3Z5aPUMHDCI+jiIlmALDXAD4yUHhjALCtEPBnCQCOk0c5AKEGB7DmRY
-2xYEupdnvOeJ+4EiZWAO6qAO/vJkY8ICIfCFG2AO3sCLcIIBXhACEYAFK/lV
-knAmHIACHXAD6kADdhcBxP/YAd4QAie5jBtwAwDHiwTwDN4wkx8AlDrJk2HT
-gNz1hR3QAeagAVgQLLAABV9QA3LwBRHQA25Ejww4ZfbIA89QBGNZBGZpllng
-G2/wBVaANTmwCwgZlwgZAHhwCRZgX34AkfMQBH/gbRTZghZpIghgCm/AAXYI
-BSzAKnthAi7gBcBRQz1gCnKCABUAC8GWRHGCBCgZAmVQBgvzBo4ZHIjJKpTZ
-AxzQmQvDRrBAAJwZAWVwARxAALAwIRHDmKEJmxzgBZWAARswAS9wBLHIARgA
-Jjvhh95lA7zIAVlwlsSwnGOpDLThA3I5nQdJlxSQCvalBnRwWHvZl03wl504
-bgD/wBeagQEY0BzPYSHleZ7wUTJ9wT5e4hzqaQqewZ7T4zvyuQLZ0RnniSG5
-YQqdYRqpgSv7gRvGwxnsSZkzFQDjiAKnOBTG6QPvCATx0AHKwJIRoAwasAEd
-oA6AEABwSZ1ySQU+sF+Y4AS4d1hHEAQncAV45nQuSDZjcxlCUTZGMaMmYqM1
-WjaKoTHK0AZqoA51SHlCEaGNUAA2YAM8QAK98AO14CgzYAsqkCAiKpe74ANm
-wAoOSQRz1gaaOGDg+XQQM6YCYAI9cAEoUJI1qIBeGQA74YCNIAVrYANh0A7s
-gI3TUAu18AGTUaVx6TSk0AujgJ18AHrcyZfeRmAwGphr/8Eh1UOcrsEXhpEY
-b4qSvyEJjNqH9dhdOcAEe4ALc8oDdkoC2Oik1uSn1YkOeNACdpkKckYHbZAE
-e9miTRBYOlCR4okUe9EhzUMmsLBDzLGU0WEh2LAZO4SZIDQm9MkcckIUxpkD
-HqACqJAPcxoGosoO28gOjuWnLNIIDcAODWABd1moEAlgLHoFTUAItHCrgCme
-uKEZ6qM+7ZOelFkJOwQLlVB8KJAKD9AGzyAsbNoYr/IGHwAGClAAHGByfFGs
-JXCstuI+lbepBwCtFCAF+pAPopCk1toOJNAOgSCd1BkgQgAGrgcBteeq2RZ6
-KuidZkAIZsCu4bkrlAkLXgAFM/8Um2/QMMwymKwwAYOQBhdgC6ugAAsRBHXI
-Al3ZGAKAACTAC1OwEA0giw1TmV6wBrgAAs+QljpbpBILrZfADMywDagAqklK
-p0DgWtRJBbtABhBQBZcwCic4rkRgWF66oi1qCC27rri6FCbwtEryAA+ANQ1g
-JRalMV+wEBmwCTcAAUSrPab4Pa5Rph1gASMSABZgC8rgBS7QswyRATgQA/8K
-O5r6lSoHrQ1AASrADHugDwVArWuwBjkHolbqA0kAA9sAAQ3QAKNwoqnApf4l
-q0fgnYZQI4AAs2L6LJKgBwyBCCQQNSyAJSuAAbu1EBIgAjSQAAthRd0Dua3B
-HyzwDFL/J10/QANFIAG9pAKlpRBasAkgE1aj66ZMyakeAAGXcAmpG7b6gApj
-awOjMAtUEJe74A9BAAOfwl94UAMeoABb8FeHZa602rKQAAnGG6PjKT/bwBBW
-ZAsR8GQAsDb1QYWiIAe6gL0KUQrt8AUX5xoD4ALkEL6hUAUdUAABwAwbsAlc
-gFkKcQh66AJJqxPPOgyjkLuXgLpgq7rbcLFrF5c5kAEFUMBO0FMsspCwegjd
-mag1kgiJMMGZWqaScMELUQo8AAIRUAKtsgKV8AwJ8AKgcAjsYAsj/MVAIAIh
-cCXtcxgXAhh2/BcZohcrwBd9wSUY0sd/HMhrA74LEQrYRAaP//CUT+kGDLF/
-NCA37/umVaZBFgABuFu/Q6wCnKwCUtAA1ZGQXSABl8APEIAG/nuQPqADDRCr
-8xBgD0wIkIAHg6AAOdCuPoEEXcwQcWAD9bCHPbqGMfAEYjBqHRADhwDHXIAF
-ZBRzlQCglnk0sGAaQZRE56k8JdAZsTIrlYAuLhAry3Er4SNLiPwBLyABHbAB
-KPCFW6gQPHADgzfJ8TuxU5AKcIu7udsA9UsB/CwFdYAgB3mlq0ABuWsGuxCi
-AbAKo3AIdcaiVgwIkbAFkdAItxyzYtIDMrwQcfDOyBU/b1AGugABJ/ABMYAF
-SbAQ2hAFTqAID1AHM1AGGjAGY2C1Bf/QBnpwa2qgArgABnQgmy7wBtNgBWOJ
-CxMwAcr2DFBgC1bQ0jNwAVZSAp+kEKEABHLwAt8gjbFZBuEbAKKQBmXQN21K
-yZw6BU4gARJwz/icz/pMAQkwCyC7CzmgA6tABnOA0BnAOThQxU0wvLKMB1sA
-DshQ0cerJhjNENrA0SKztBggCQWQVQ5A0ia9EApQEgwxBjTAD7IUACmgC8rg
-BArxCMzAHrZAFQFwCq61EIqgCzJQuS+QDzFgiFEdAMDQDiBQBSjAi54RdQsR
-CPng1WC9gPALlmMtA6kgrmYNt/xgypiMuypwBULw1gQSAP9rAD7ACPv1ysFb
-By7ashC9Ba3/0AoUjcsXndEKcdhMNZ4mQASNizelpAzJrBBzcA/AULkBAAFc
-EA+VywunIAIgYEs3MJOkrRCgsApBULlM4ABB0M4OIAfKwAHPIEt3IHxYkJtw
-wjYYLAr2J8/CTc9+4AROgAnFbQFmfdYjfoINoAaO5gMhepBO8wJjMAp5LZGx
-DAg5Ag6kAN6CTcEdXNgojdgdXAFqsN4HAAMigMwaHQZREHc15m7RNULUlQJy
-AHCsgAcYnAme8N6QYeVRULk2EDVlAOHsoIeJiTwskAqSTQ1K0AEEwL088axT
-MAYOVFAfngohLq52ngr8kAqqwATQwBCM4ABEcAnYbQUPDMF+3Qoj/0AK4W3R
-asPj5e3jcQQFUrAQOtAOtkADWB4HcAADnoAIDEENh9bOwxAGoBDCS1gGygBq
-U1cMbnBvCqEAxSBj7cwJ8RADEQDmKMwqA3A9sxMMDZAPtbDBPQwAz5oBYOAH
-fjBADeThzH6izF5QEsAPY4AHSTIIDcAMkqE13YauLSvLEY3oIzACgS3ejU7e
-AWDe2hQ/UAByr24DIKALWK4NNtBwOBwAnAADIPBqCzEMj8B4TQYFWr0Qd9AO
-M6BpAaAAcCAGT9DOwDANNIAFYN4BktAqa7MGVGgM+fANNOi+uka6lZwBbYAG
-aKAGajBABNVAKL9IXMoH4ooJEiADALaiff+Jrnjr7d5NCiMgDCMQDTmeqTtu
-7uguMvFDAJPe7u+O5WAswijzxTAgB1wwbRYGA19wAUpkyB0FBE+g5AjvBiKg
-6ncAwzEQvhEu8YiBIkTrAfrAaXoICwHT8cFdup4LBnLvOSSvBsjOQDJABETg
-B3avnf2lB9uW1zL/B7EMCZHg1zgvDIrP8+RO2EDP0azCJrts9PD+xe1wAzHA
-7uXNDjegC0DAECcABGhoChig2x1F5Et/8GHw7mIPA8cs9uzQAV7gF5UgTIjA
-adOgDjPAAVvr9mI9sRlwBEmQBDYt93Qg8n6ABnXwB2jQBsdfZ3RwCITwB20w
-D3/wBwLmolvgI4n/YPiIn/OKLwyMz+iOb9gcjRoQYJpFf/DuXvklzAPqoAzr
-HwBxcPnDzBBzUAxyUAamABCLoDwIUPAODBEqCgZQEAaErhoLD3aIEdEgiQ1e
-kFT48sLMqRm2OqgL8MyLCyQAVK5UuTDAygElOBzIkSHIPByHkiRpowcMnRMK
-AtVos2oVJl4p9Dh40EhVEgeEjvDC8SlDDV6EIuHZ0mrECGHChgyJlmPKAnMc
-SiBgqXJAjwIutfG4wYEFq5Jl9ixUYOPhoYWl2qlTJsXlPXZfsPAJ5JKBG289
-Kg2UiFBhwYYPLQaYWFEiRkmLWPA6tOkDFxoxkgTQUEZShbYrXcKU6aDm/4kg
-R47Mw6kTjAM7BSRIQBTgBC8yZPBIIcQEzRxEVxipQfQAzbwmW7aQ+hp2iCyy
-ZtGqZdv2bdyFc0WEkGQngLcYlxn6pQG4oGARWJwsDKavyoYOMmCHDP7CUCeE
-HrIgyCDL+HIIosoo2uwOjAjoYQwydOHinU3esc8WGkLAILaWFoIJg5lyAOUK
-K6wIIjfd5glCh1H0+MSQFBp5IJBPaghijCt0AAOUKVIYJ4hVrtoCEHBI4c47
-WaIs66y01optABbQK0gbIDa5gIYXAuBCFwoclKO+wLpUZrWC4oAjHg3aeGQT
-OFxSZAYUOChiwQBCESMhMyEsKJT/lNksFBg2eP9mDZcaDQCGDyJwgUQAZnML
-AygC2YURQk6o44Q//nDxRR1wSIKXVT45hJAAVnnAjjHsaMSKT1KYBRFVVKmB
-jiO2606sKI0wYg4qhllAA/Jiw8YLVFyKo5gPYrDPkycacDCeDRJIEzUFCgqG
-gnZsYZSEd06ZwKU9bsAigkNh4KJMzBzaZEKEPBsUhk1ECNPRhWyYQZlJSbQU
-gAFMISCIHHaZoI4mrriijk//CGKCKXgZRpVPrHBimE/MYOIBIVYZBJAmHjjE
-gy3m0MGpJ4GVRVh8oMmBjBm84QCDAdoSwAQC2MQsmVO0LSiTJYxZCJQwZtjE
-jIV0AOIJeIMxxoYf2mn/JIB3PngCApcemGEDb+j9AF6Gwohn3oUScFeXqwu6
-AoZ3PuHXpWRmwKIESgdeoQIvGM1BgSaaMMSQwB2+4o9HUJVgizHGAOSENhR5
-ABB+VknCEDrm+aQOXh5IgZawXBbWCGSoCOCPelAgwJScWdpbh7ldgqGOfQsC
-5RARAlkFDoJ4sSNMMvSxgZkUFnJgmgYyaHSCNtq2vQF6lF/ok3iK58+Q6Bs9
-oIXYvV1DjjJMydtElXZmoQymd2mE5MEDd/8WPfyY54ogGsbujyTAuIIWeCCp
-IxFaAJAWkGgFlF4mLGRYIwdzUMINIuCFCqzAPBhYwxriAQQ4JMMGJPiBCixA
-/w8IfGMN/HADDGxgASeQ4AtHaMEPYACBJtSBD+yoQhV+cAMVbOAGVeDHDWbQ
-gAvagBqcsEALGtACMfCgAURQwg9QAQIYhIETEABBAaRQNRsQARXIQ2I79sAJ
-IH4gHjDgQTIccUZH6EMfovjGBjgAG4GRDwACQIJM6jGLHPjAA8oZhB0SkQg7
-BDIRgwAkIQc5iEFwBRxNUkSuwCKW70TpgEb4xRR2YboG1GIDIWCBCQRgngpI
-IgIdkEMtapGGD6jjC7aoRxpEYo5VziAkHUCBMjTQgRvkUgS5vMEXvFGGZ0TA
-GxsAGxZQsIEPzOCUH+iAOTrwgTSkQQ4dgA8y01CPG/+YAwUaUAcIpPkFDQzz
-Bmk45Q024ExbpOEH02DnNHqxgHps4AKwKE9sXAILmFSgB2VogcwSxog5BFSg
-AyUoQYVwUIQitAuMYGhDZ2EAKuQgALfohboIgAEEfNJ1JnABAS5gTBSsKwIR
-QEFJI/CMEFyApCg4KQcIwAEOPKMMZRgpFsrAAUmwgAWS4MAFLuBSKISgDCVV
-hk0vQFMsrOunHBBqUssQAqZ+VKkhSGkEjGnUlJYBpCUtqU05AAsTSDA2sChI
-mFCwEjpigABYYMYDDJAwKsRVrnOla13tGtdd5FWvuxgHFTwwhl7YwmadFCtL
-BDAAE5jCBbBg7GJhwYIe9ID/BbAoQQkcy1jKmsIUFVAsLHrwBha4oAImQIIJ
-KmBZF2BAs5ZlrE4n29rGYgADrG1sZS8LCxdc9rUuqCxqc/vbEmwWAYVtCwoC
-8AIPBAAXG4UFFLDwBRUAwgE6oG51rXtd7GZXuzqYACZIkAZ1oABBFcgopQRw
-Xo2idQXrXS960cte+A5AvgNYQXrd697yCWAF9K3vff3L3vsC2L+UInBbcBEA
-D5xrEIZFLCwIUAZvdICV5DRlhS18YQxnGMMzcKU6NBABDvSgAkggboFNfGIU
-p1jFK2axSgYRgAkcIQDS4ACDTVCCN/SUpN7whgZ8/GMgB1nIQw6yN0J6U0nA
-YsQl4G5xk538ZCgTmAPSCMARiACKAGxBZwPYSAlY4AUCQAGmYyZzmc185jND
-gQCS6IELTGGCAaQ3ynOmc51TvIUAgIII/8BBQXAAR7Ry2bSmkG2hDX1oRCda
-0aodLRLoK2c7R1rSda5AnwOAg39k+sUBYMINYnPe9c5X1KMmdalNLer+TlrV
-q47yDZhQkEFkWtZX0EQAcqEKXHyByazmda99neIVfAEXqshFADRxBVknWw0H
-6F6znf1saEdb2tOmdrWtvZADqCHZ2ybCISagg2JfW9zjJne5zU3tXHD3EHtO
-dkAAADs=
-}
-image create photo tclLogo -data {
-R0lGODlhYQCWAPUAAP//////zP//mf//AP/MzP/Mmf/MAP+Zmf+ZZv+ZAMz/
-/8zM/8zMzMyZzMyZmcyZZsyZAMxmZsxmM8xmAMwzM8wzAJnM/5nMzJmZzJmZ
-mZlmmZlmZplmM5kzM5kzAGaZzGZmzGZmmWZmZmYzZmYzMzNmzDNmmTMzmTMz
-ZgAzmQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
-AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH+BSAtZGwtACH5BAEKAAIALAAA
-AABhAJYAAAb+QIFwSCwaj8ikcslsOp/Oh1RClVSu2KxWAu16jY9IpGrVms9o
-9OPLJqbf8Lic2/7K0ZN0IpG/p9dGCAgPZBSGZ05+WRADBmcTA5EDfYqVcomV
-jJNnkpGOlqBvmIqeZwaSBhOUoaxZo3eaq1eQkbKttxVOFIqnn1qnm7jCV7q8
-AxBmscPDdEy7frVmkQnLzE5ld43JkdXDEdek1L/BlhKE3VffTdhy5LPalRIF
-APQABOhP7HHuFQnHlRHqCbxXLR8vaQMqHRAIYMECeg8KRjmYBZIvOfPoLfiQ
-ouMJBwEkNonoRxyWU7bSEKjHsaPLFBn0tXpC8o4sbncWNjTxsqf+hmU0Fa2y
-mJPehZ5IT3QYBoWVv5RmAgLAgBQpCaBPWJ2aQ69lVZcollFoGgoenJVUv7o8
-Ua1Zk1CQTKZZeFSty6XL3DIJxQjZGwkN7bq8amkCnzOAXil6ehYAT8Fh3xg2
-IPeKv1RaEr8FtfXNAwBe7cbxNw3hxQobPnxQDO20mQAMBHckDAeYa9JaRvRc
-UtZ1loWP7UYeXVoLLS0odispW1kLgLqCPdwh7VeL2SvJXZrgXZhfls/B1dIm
-7r0CvxMvQXCvBAlqBQKxIZ+hYuo6lgmue65e3j0NYBCy4VUBBQ+sBEBIZpzS
-XD+2KKeETHFAkgYCAMgWGQUMMASATNH+mGGLBw4mASEc+KmUll0joJBdRyBc
-AJFx9r3RQYhIjFhbGgAAKNtXAQCAgBaMLIjGjNoxYeMbQgK241corHTAOO6Z
-QWRH+ykRAShQPbDAklV14KR1vqVBwktNXLnMASdy6VIFL95XnphkMmHmMATo
-qKZHFNDDjj+VrJhCmdUQEJ6aI0j1zBUDCJnGitsxUZMwAdz5UgcLEfSOJSuq
-t9kw8UmawnsAPInFHpag11FWy3R6Jwp5bphFmHDEuakwaapJwmcIzqLoG7Lu
-tUwGnqbgJQCP7sqrS6gOo0GwbAJwaAVRpjFlo7PisoFag76Ewmei3jJllb4O
-c21VJmQ72Er+w4x5arLCTPnSCaEhxQGx6SLLLi7udoQCCbX25ICluOi2Lmu3
-WMWvWk0eWYnAJ5C1DFIdbNCvSxr8uEx2JTjMyqN+fppBvC850E124IbLygHd
-+hkWAyV8Nd4w9t4LykoWCzybB45VNVw1MRNciYEMpDhpBxVWhc4VPVc7cz0b
-veRBBAp0eXQFHVHrhIChrATdSxU4sGVPI2ShsCJEavoE1kuDHFYDW3e01AEE
-xL0MkV6gbclKdoJVAQNtr5Vht/gOLPPdOfd01VRqbQDAnLio6wUuwEHM5sQd
-OeDqMDM23AXkRffUwX9qoTt3ChlvfstCVXkAelUn2FPNjCUrbcn+Z6ZyHVDe
-L4UQ6ut/Pn7LZx1/Ct5XGtDLsx23AGazvl0XjlQGi3fTOxQY4KJ8T2FFXpXl
-Y1ditRMhCAPAuHpnaG4K3Hdj9hPh47Ih2Ht3jtRC+HjxEy4ERAD/SkzS380X
-7btF/vYnv5eM4DP160IAW4EyP13lIS4DTAKhsEBWROAAy3tgAe/Cpu4p4gs7
-Y4UECKCu2VQAgqnr4P+8EDZhkPAlGvxKBSS4wi60EH/uimFSKlCgCT7hhqeT
-AAxPuMEUhCV/PnQCEFsRgQcMEYVgG+HRvPCBlzGwdmGD4qQK4MFKaKYJJbDb
-yVaUxSLS52hfZIIJxBgKBNisjEgZATb+uniHNC5BWHkRgd4sAIDadUQ6MyQA
-HefQBTwuY1nM42N4UCABuOmpG3phgiG9UT7n4bGRj2xLIdkYCiF6pAIYsGQF
-OkACFIDgcnmBAkc4GQquhbJlVTnlFJ+wSuthY0XNw51LQJArkTSBJ6y8A2BI
-siIPFE+XHcEAwLDihI7Q6UAO8ErEQPOVBgCOmU1wpjB0kqZpUo4Aj8KmJD81
-DADAcjBEmxgKnDXLZpJzm20bQZ76loIN9NKX4xSLJcPikO1dU5xKaEk1tPSu
-vUUNewEYpB+eAKAQ4qIAaWoeUjawTHwqgScOxZ80aactQU4tF+7MKP50RALA
-nDMFIvinRZP+wLyjRTMFcqSmS0T2UZBm04gfDQEIwiJTmNb0CggIaU1RwBYC
-QOen6WhCS0S6jLAV4GtLnJo6lqAjplZjIR0I5jKmqgRYWhUUEArIs34aySMM
-hhmfKcB8UInUshrhrMsAgFrPED2kXsGtRYBrOedqBgJYzK54JYJexebRSsgV
-DQfgq11vmgIrViAgCj3sGSJQ0ZoyQZpmkIdc/4qFCx4gnFeQbGYBYFcsMMFO
-YoSsGeCWjoqK1gxs/akaORiV2AKmDP7Lwmu1AM7S2pSltNWCan9zOQrIZLe/
-Uaxs7xjcLAwXC/M4EnKxQMPFMvePk43tQrAxVjYp1zkKDcU4tVn+W30MEwv/
-nC4W/FraJYQGDYAhwDVHSIgDsAOT8p1LZduJhLz5Z0RnLMd+k1iEk/p2vaW1
-4xD8eOArqBSNSuhJg2eY4AhzbcKlDayEMZdVEpAgqyDW6tE0fGE5gNjDKSJq
-sLCnohaP4MUv9rCMPxxiTuI1NMPxwIlLqSI/rvjHXILCSY0I5CIbWXCzPbKS
-jwyFJTu5yE1+spQ9FeUpW3lH37vulbf8lSxbGCkluMAFdFkCBjStJxhoGQZ4
-kuaeiLlWLbrAkE3w5p6E+QIgK5ITkJmCDyjgAwU0wVROWSsMUGUqrfOxOQf1
-gQWEsieCLgGjN9JTOz9hyC7x8yn1E5/VRtvZnA0BwddeMpV4NdrTLxE0BnDn
-aVQjJXZJOB+gGRAvDHT6oKSmNQBojRTQsJoegxL0B4bc6lHr5wlqcfVLSgCa
-EiigXy4yQYZ8nALHTNrRkF60fhbgbMrBGglqAYGqXgLo58RyS6KuigIUMO4P
-XMAECggPvNmtn3VTrs/I5rK+q1Llfft7epf9t8ChAIKCG/zgBi+XwhfOcIUL
-3C51iHgRPgACTO9b4hhPAsXPt+SMe1ypIOA4lT9OclVKOlglT3kbKi5yJKv8
-5V+g+JBhTvOaGyEIADs=
-}
-
-Init .
diff --git a/tclxml-3.2/examples/tclxml/README b/tclxml-3.2/examples/tclxml/README
deleted file mode 100644
index 0765018..0000000
--- a/tclxml-3.2/examples/tclxml/README
+++ /dev/null
@@ -1,29 +0,0 @@
-examples/tclxml/README --
-
-This directory contains example scripts to demonstrate
-the use of TclXML.
-
----------------------------------------------------------------------------
-See the file "LICENSE" for information on usage and
-redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
----------------------------------------------------------------------------
-
-flatten.tcl
-	Parses an XML document or DTD and produces the document's DTD
-	with all external entities expanded, parameter entities
-	resolved and conditional sections resolved.
-
-xmlwc
-	Counts the number of lines, words, characters and bytes
-	in the character data of an XML document.
-	Inspired by the Unix wc program.
-
-REC-xml-20001006.xml 
-        The W3C XML spec in XML format. A handy file to run xmlwc over
-        to test your build. You should get this output with the command
-             tclsh xmlwc REC-xml-20001006.xml 
-        :
- 
-           2929   14978  116827 REC-xml-20001006.xml 
-
-
diff --git a/tclxml-3.2/examples/tclxml/REC-xml-20001006.xml b/tclxml-3.2/examples/tclxml/REC-xml-20001006.xml
deleted file mode 100755
index ac20327..0000000
--- a/tclxml-3.2/examples/tclxml/REC-xml-20001006.xml
+++ /dev/null
@@ -1,3277 +0,0 @@
-<?xml version="1.0" encoding="iso-8859-1"?>
-<!DOCTYPE spec PUBLIC "-//W3C//DTD Specification V2.1//EN"
- "http://www.w3.org/XML/1998/06/xmlspec-v21.dtd" [
-<!--ArborText, Inc., 1988-2000, v.4002-->
-<!ENTITY http-ident "http://www.w3.org/TR/2000/REC-xml">
-<!ENTITY draft.month "October">
-<!ENTITY draft.day "6">
-<!ENTITY iso6.doc.date "20001006">
-<!ENTITY draft.year "2000">
-<!ENTITY versionOfXML "1.0">
-<!ENTITY pio "'<?xml'">
-<!ENTITY doc.date "10 February 1998">
-<!ENTITY w3c.doc.date "02-Feb-1998">
-<!ENTITY WebSGML "WebSGML Adaptations Annex to ISO 8879">
-<!ENTITY pic "'?>'">
-<!ENTITY br "\n">
-<!ENTITY cellback "#c0d9c0">
-<!ENTITY mdash "--">
-<!ENTITY com "--">
-<!ENTITY como "--">
-<!ENTITY comc "--">
-<!ENTITY hcro "&#x">
-<!ENTITY nbsp " ">
-<!ENTITY magicents "<code>amp</code>,
-<code>lt</code>,
-<code>gt</code>,
-<code>apos</code>,
-<code>quot</code>">
-<!ENTITY doc.audience "public review and discussion">
-<!ENTITY doc.distribution "may be distributed freely, as long as
-all text and legal notices remain intact">
-]>
-<spec w3c-doctype="rec">
-<!--
-Notes on preparation of the Second Edition:
-
-- Worked from http://www.w3.org/XML/xml-19980210-errata.
-- Changed DTD reference to point to V2.1 of XMLspec.
-- Moved version number from <title> to <version> element and
-  added "second edition" wording.  Mentioned edition information
-  in status.
-- Removed bgcolor="&cellback;" attributes from all <td>
-  elements because that attribute is not in the current table model.
-- Reversed status and abstract, so that abstract is first, according
-  to W3C guidelines.
-- Changed some <emph>s to <titleref>s in bibliography.
-- Changed some <code>s to <at> etc. throughout; where used <attval>,
-  removed existing <quote>s because the stylesheet produces them.
-- Removed some spurious spaces.
-- Added affiliation markup to the original member list.
-- Added commas between individual <thisver> elements, because
-  whitespace is now significant there.
-- Moved <eg>s, <scrap>s, and lists outside of <p>s for cleaner HTML
-  conversion.
-- Revised Status section to reflect new status.
-- Fixed all titleref hrefs so they get transformed properly; at
-  next revision, these all probably need to be changed to some
-  other markup.
-- Incorporated all errata (barring obsoleted and invalid ones);
-  added links to the errata document with <loc role="erratumref">
-  elements; used diff="{add|chg|del}" attribute.  This version 
-  expects that the official HTML output will have diff="del" 
-  elements suppressed.
--->
-<header>
-<title>Extensible Markup Language (XML)</title>
-<version>1.0 (Second Edition)</version>
-<w3c-designation>REC-xml-&iso6.doc.date;</w3c-designation>
-<w3c-doctype>W3C Recommendation</w3c-doctype>
-<pubdate><day>&draft.day;</day><month>&draft.month;</month><year>&draft.year;</year>
-</pubdate>
-<publoc><loc href="&http-ident;-&iso6.doc.date;">&http-ident;-&iso6.doc.date;</loc>
-(<loc href="&http-ident;-&iso6.doc.date;.html">XHTML</loc>, <loc href="&http-ident;-&iso6.doc.date;.xml">XML</loc>, <loc
-href="&http-ident;-&iso6.doc.date;.pdf">PDF</loc>, <loc href="&http-ident;-&iso6.doc.date;-review.html">XHTML
-review version</loc> with color-coded revision indicators)</publoc>
-<latestloc><loc href="http://www.w3.org/TR/REC-xml">http://www.w3.org/TR/REC-xml</loc></latestloc>
-<prevlocs><loc href="http://www.w3.org/TR/2000/WD-xml-2e-20000814"> http://www.w3.org/TR/2000/WD-xml-2e-20000814</loc>
-<loc href="http://www.w3.org/TR/1998/REC-xml-19980210"> http://www.w3.org/TR/1998/REC-xml-19980210</loc><!--
-<loc href='http://www.w3.org/TR/PR-xml-971208'>
-http://www.w3.org/TR/PR-xml-971208</loc>
-<loc href='http://www.w3.org/TR/WD-xml-961114'>
-http://www.w3.org/TR/WD-xml-961114</loc>
-<loc href='http://www.w3.org/TR/WD-xml-lang-970331'>
-http://www.w3.org/TR/WD-xml-lang-970331</loc>
-<loc href='http://www.w3.org/TR/WD-xml-lang-970630'>
-http://www.w3.org/TR/WD-xml-lang-970630</loc>
-<loc href='http://www.w3.org/TR/WD-xml-970807'>
-http://www.w3.org/TR/WD-xml-970807</loc>
-<loc href='http://www.w3.org/TR/WD-xml-971117'>
-http://www.w3.org/TR/WD-xml-971117</loc>--> </prevlocs>
-<authlist>
-<author role="1e"><name>Tim Bray</name><affiliation>Textuality and Netscape</affiliation>
-<email href="mailto:tbray at textuality.com">tbray at textuality.com</email></author>
-<author role="1e"><name>Jean Paoli</name><affiliation>Microsoft</affiliation>
-<email href="mailto:jeanpa at microsoft.com">jeanpa at microsoft.com</email></author>
-<author role="1e" diff="chg"><name>C. M. Sperberg-McQueen</name><affiliation>University
-of Illinois at Chicago and Text Encoding Initiative</affiliation><email href="mailto:cmsmcq at uic.edu">cmsmcq at uic.edu</email>
-</author>
-<author role="2e" diff="add"><name>Eve Maler</name><affiliation>Sun Microsystems,
-Inc.</affiliation><email href="mailto:elm at east.sun.com">eve.maler at east.sun.com</email>
-</author>
-</authlist>
-<abstract>
-<p>The Extensible Markup Language (XML) is a subset of SGML that is completely
-described in this document. Its goal is to enable generic SGML to be served,
-received, and processed on the Web in the way that is now possible with HTML.
-XML has been designed for ease of implementation and for interoperability
-with both SGML and HTML.</p>
-</abstract>
-<status>
-<p>This document has been reviewed by W3C Members and other interested parties
-and has been endorsed by the Director as a W3C Recommendation. It is a stable
-document and may be used as reference material or cited as a normative reference
-from another document. W3C's role in making the Recommendation is to draw
-attention to the specification and to promote its widespread deployment. This
-enhances the functionality and interoperability of the Web.</p>
-<p>This document specifies a syntax created by subsetting an existing, widely
-used international text processing standard (Standard Generalized Markup Language,
-ISO 8879:1986(E) as amended and corrected) for use on the World Wide Web.
-It is a product of the W3C XML Activity, details of which can be found at <loc
-href="http://www.w3.org/XML/">http://www.w3.org/XML</loc>. <phrase diff="add"><loc
-role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E100">[E100]</loc>
-The English version of this specification is the only normative version. However,
-for translations of this document, see <loc href="http://www.w3.org/XML/#trans">http://www.w3.org/XML/#trans</loc>. </phrase>A
-list of current W3C Recommendations and other technical documents can be found
-at <loc href="http://www.w3.org/TR/">http://www.w3.org/TR</loc>.</p>
-<p diff="del"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E66">[E66]</loc>This
-specification uses the term URI, which is defined by <bibref ref="Berners-Lee"/>,
-a work in progress expected to update <bibref ref="RFC1738"/> and <bibref
-ref="RFC1808"/>.</p>
-<p diff="add">This second edition is <emph>not</emph> a new version of XML (first published 10 February 1998);
-it merely incorporates the changes dictated by the first-edition errata (available
-at <loc href="http://www.w3.org/XML/xml-19980210-errata">http://www.w3.org/XML/xml-19980210-errata</loc>)
-as a convenience to readers. The errata list for this second edition is available
-at <loc href="http://www.w3.org/XML/xml-V10-2e-errata">http://www.w3.org/XML/xml-V10-2e-errata</loc>.</p>
-<p>Please report errors in this document to <loc href="mailto:xml-editor at w3.org">xml-editor at w3.org</loc><phrase
-diff="add"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E101">[E101]</loc>; <loc
-href="http://lists.w3.org/Archives/Public/xml-editor">archives</loc> are available</phrase>.</p>
-<note diff="add">
-<p>C. M. Sperberg-McQueen's affiliation has changed since the publication
-of the first edition. He is now at the World Wide Web Consortium, and can
-be contacted at <loc href="mailto:cmsmcq at w3.org">cmsmcq at w3.org</loc>.</p>
-</note>
-</status>
-<pubstmt>
-<p>Chicago, Vancouver, Mountain View, et al.: World-Wide Web Consortium, XML
-Working Group, 1996, 1997, 2000.</p>
-</pubstmt>
-<sourcedesc>
-<p>Created in electronic form.</p>
-</sourcedesc>
-<langusage>
-<language id="EN">English</language>
-<language id="ebnf">Extended Backus-Naur Form (formal grammar)</language>
-</langusage>
-<revisiondesc>
-<slist>
-<sitem>1997-12-03 : CMSMcQ : yet further changes</sitem>
-<sitem>1997-12-02 : TB : further changes (see TB to XML WG, 2 December 1997)</sitem>
-<sitem>1997-12-02 : CMSMcQ : deal with as many corrections and comments from
-the proofreaders as possible: entify hard-coded document date in pubdate element,
-change expansion of entity WebSGML, update status description as per Dan Connolly
-(am not sure about refernece to Berners-Lee et al.), add 'The' to abstract
-as per WG decision, move Relationship to Existing Standards to back matter
-and combine with References, re-order back matter so normative appendices
-come first, re-tag back matter so informative appendices are tagged informdiv1,
-remove XXX XXX from list of 'normative' specs in prose, move some references
-from Other References to Normative References, add RFC 1738, 1808, and 2141
-to Other References (they are not normative since we do not require the processor
-to enforce any rules based on them), add reference to 'Fielding draft' (Berners-Lee
-et al.), move notation section to end of body, drop URIchar non-terminal and
-use SkipLit instead, lose stray reference to defunct nonterminal 'markupdecls',
-move reference to Aho et al. into appendix (Tim's right), add prose note saying
-that hash marks and fragment identifiers are NOT part of the URI formally
-speaking, and are NOT legal in system identifiers (processor 'may' signal
-an error). Work through: Tim Bray reacting to James Clark, Tim Bray on his
-own, Eve Maler, NOT DONE YET: change binary / text to unparsed / parsed. handle
-James's suggestion about < in attriubte values uppercase hex characters,
-namechar list, </sitem>
-<sitem>1997-12-01 : JB : add some column-width parameters</sitem>
-<sitem>1997-12-01 : CMSMcQ : begin round of changes to incorporate recent
-WG decisions and other corrections: binding sources of character encoding
-info (27 Aug / 3 Sept), correct wording of Faust quotation (restore dropped
-line), drop SDD from EncodingDecl, change text at version number 1.0, drop
-misleading (wrong!) sentence about ignorables and extenders, modify definition
-of PCData to make bar on msc grammatical, change grammar's handling of internal
-subset (drop non-terminal markupdecls), change definition of includeSect to
-allow conditional sections, add integral-declaration constraint on internal
-subset, drop misleading / dangerous sentence about relationship of entities
-with system storage objects, change table body tag to htbody as per EM change
-to DTD, add rule about space normalization in public identifiers, add description
-of how to generate our name-space rules from Unicode character database (needs
-further work!). </sitem>
-<sitem>1997-10-08 : TB : Removed %-constructs again, new rules for PE appearance.</sitem>
-<sitem>1997-10-01 : TB : Case-sensitive markup; cleaned up element-type defs,
-lotsa little edits for style</sitem>
-<sitem>1997-09-25 : TB : Change to elm's new DTD, with substantial detail
-cleanup as a side-effect</sitem>
-<sitem>1997-07-24 : CMSMcQ : correct error (lost *) in definition of ignoreSectContents
-(thanks to Makoto Murata)</sitem>
-<sitem>Allow all empty elements to have end-tags, consistent with SGML TC
-(as per JJC).</sitem>
-<sitem>1997-07-23 : CMSMcQ : pre-emptive strike on pending corrections: introduce
-the term 'empty-element tag', note that all empty elements may use it, and
-elements declared EMPTY must use it. Add WFC requiring encoding decl to come
-first in an entity. Redefine notations to point to PIs as well as binary entities.
-Change autodetection table by removing bytes 3 and 4 from examples with Byte
-Order Mark. Add content model as a term and clarify that it applies to both
-mixed and element content. </sitem>
-<sitem>1997-06-30 : CMSMcQ : change date, some cosmetic changes, changes to
-productions for choice, seq, Mixed, NotationType, Enumeration. Follow James
-Clark's suggestion and prohibit conditional sections in internal subset. TO
-DO: simplify production for ignored sections as a result, since we don't need
-to worry about parsers which don't expand PErefs finding a conditional section.</sitem>
-<sitem>1997-06-29 : TB : various edits</sitem>
-<sitem>1997-06-29 : CMSMcQ : further changes: Suppress old FINAL EDIT comments
-and some dead material. Revise occurrences of % in grammar to exploit Henry
-Thompson's pun, especially markupdecl and attdef. Remove RMD requirement relating
-to element content (?). </sitem>
-<sitem>1997-06-28 : CMSMcQ : Various changes for 1 July draft: Add text for
-draconian error handling (introduce the term Fatal Error). RE deleta est (changing
-wording from original announcement to restrict the requirement to validating
-parsers). Tag definition of validating processor and link to it. Add colon
-as name character. Change def of %operator. Change standard definitions of
-lt, gt, amp. Strip leading zeros from #x00nn forms.</sitem>
-<sitem>1997-04-02 : CMSMcQ : final corrections of editorial errors found in
-last night's proofreading. Reverse course once more on well-formed: Webster's
-Second hyphenates it, and that's enough for me.</sitem>
-<sitem>1997-04-01 : CMSMcQ : corrections from JJC, EM, HT, and self</sitem>
-<sitem>1997-03-31 : Tim Bray : many changes</sitem>
-<sitem>1997-03-29 : CMSMcQ : some Henry Thompson (on entity handling), some
-Charles Goldfarb, some ERB decisions (PE handling in miscellaneous declarations.
-Changed Ident element to accept def attribute. Allow normalization of Unicode
-characters. move def of systemliteral into section on literals.</sitem>
-<sitem>1997-03-28 : CMSMcQ : make as many corrections as possible, from Terry
-Allen, Norbert Mikula, James Clark, Jon Bosak, Henry Thompson, Paul Grosso,
-and self. Among other things: give in on "well formed" (Terry is right), tentatively
-rename QuotedCData as AttValue and Literal as EntityValue to be more informative,
-since attribute values are the <emph>only</emph> place QuotedCData was used,
-and vice versa for entity text and Literal. (I'd call it Entity Text, but
-8879 uses that name for both internal and external entities.)</sitem>
-<sitem>1997-03-26 : CMSMcQ : resynch the two forks of this draft, reapply
-my changes dated 03-20 and 03-21. Normalize old 'may not' to 'must not' except
-in the one case where it meant 'may or may not'.</sitem>
-<sitem>1997-03-21 : TB : massive changes on plane flight from Chicago to Vancouver</sitem>
-<sitem>1997-03-21 : CMSMcQ : correct as many reported errors as possible. </sitem>
-<sitem>1997-03-20 : CMSMcQ : correct typos listed in CMSMcQ hand copy of spec.</sitem>
-<sitem>1997-03-20 : CMSMcQ : cosmetic changes preparatory to revision for
-WWW conference April 1997: restore some of the internal entity references
-(e.g. to docdate, etc.), change character xA0 to &nbsp; and define nbsp
-as &#160;, and refill a lot of paragraphs for legibility.</sitem>
-<sitem>1996-11-12 : CMSMcQ : revise using Tim's edits: Add list type of NUMBERED
-and change most lists either to BULLETS or to NUMBERED. Suppress QuotedNames,
-Names (not used). Correct trivial-grammar doc type decl. Rename 'marked section'
-as 'CDATA section' passim. Also edits from James Clark: Define the set of
-characters from which [^abc] subtracts. Charref should use just [0-9] not
-Digit. Location info needs cleaner treatment: remove? (ERB question). One
-example of a PI has wrong pic. Clarify discussion of encoding names. Encoding
-failure should lead to unspecified results; don't prescribe error recovery.
-Don't require exposure of entity boundaries. Ignore white space in element
-content. Reserve entity names of the form u-NNNN. Clarify relative URLs. And
-some of my own: Correct productions for content model: model cannot consist
-of a name, so "elements ::= cp" is no good. </sitem>
-<sitem>1996-11-11 : CMSMcQ : revise for style. Add new rhs to entity declaration,
-for parameter entities.</sitem>
-<sitem>1996-11-10 : CMSMcQ : revise for style. Fix / complete section on names,
-characters. Add sections on parameter entities, conditional sections. Still
-to do: Add compatibility note on deterministic content models. Finish stylistic
-revision.</sitem>
-<sitem>1996-10-31 : TB : Add Entity Handling section</sitem>
-<sitem>1996-10-30 : TB : Clean up term & termdef. Slip in ERB decision
-re EMPTY.</sitem>
-<sitem>1996-10-28 : TB : Change DTD. Implement some of Michael's suggestions.
-Change comments back to //. Introduce language for XML namespace reservation.
-Add section on white-space handling. Lots more cleanup.</sitem>
-<sitem>1996-10-24 : CMSMcQ : quick tweaks, implement some ERB decisions. Characters
-are not integers. Comments are /* */ not //. Add bibliographic refs to 10646,
-HyTime, Unicode. Rename old Cdata as MsData since it's <emph>only</emph> seen
-in marked sections. Call them attribute-value pairs not name-value pairs,
-except once. Internal subset is optional, needs '?'. Implied attributes should
-be signaled to the app, not have values supplied by processor.</sitem>
-<sitem>1996-10-16 : TB : track down & excise all DSD references; introduce
-some EBNF for entity declarations.</sitem>
-<sitem>1996-10-?? : TB : consistency check, fix up scraps so they all parse,
-get formatter working, correct a few productions.</sitem>
-<sitem>1996-10-10/11 : CMSMcQ : various maintenance, stylistic, and organizational
-changes: Replace a few literals with xmlpio and pic entities, to make them
-consistent and ensure we can change pic reliably when the ERB votes. Drop
-paragraph on recognizers from notation section. Add match, exact match to
-terminology. Move old 2.2 XML Processors and Apps into intro. Mention comments,
-PIs, and marked sections in discussion of delimiter escaping. Streamline discussion
-of doctype decl syntax. Drop old section of 'PI syntax' for doctype decl,
-and add section on partial-DTD summary PIs to end of Logical Structures section.
-Revise DSD syntax section to use Tim's subset-in-a-PI mechanism.</sitem>
-<sitem>1996-10-10 : TB : eliminate name recognizers (and more?)</sitem>
-<sitem>1996-10-09 : CMSMcQ : revise for style, consistency through 2.3 (Characters)</sitem>
-<sitem>1996-10-09 : CMSMcQ : re-unite everything for convenience, at least
-temporarily, and revise quickly</sitem>
-<sitem>1996-10-08 : TB : first major homogenization pass</sitem>
-<sitem>1996-10-08 : TB : turn "current" attribute on div type into CDATA</sitem>
-<sitem>1996-10-02 : TB : remould into skeleton + entities</sitem>
-<sitem>1996-09-30 : CMSMcQ : add a few more sections prior to exchange with
-Tim.</sitem>
-<sitem>1996-09-20 : CMSMcQ : finish transcribing notes.</sitem>
-<sitem>1996-09-19 : CMSMcQ : begin transcribing notes for draft.</sitem>
-<sitem>1996-09-13 : CMSMcQ : made outline from notes of 09-06, do some housekeeping</sitem>
-</slist>
-</revisiondesc>
-</header>
-<body>
-<div1 id="sec-intro">
-<head>Introduction</head>
-<p>Extensible Markup Language, abbreviated XML, describes a class of data
-objects called <termref def="dt-xml-doc">XML documents</termref> and partially
-describes the behavior of computer programs which process them. XML is an
-application profile or restricted form of SGML, the Standard Generalized Markup
-Language <bibref ref="ISO8879"/>. By construction, XML documents are conforming
-SGML documents.</p>
-<p>XML documents are made up of storage units called <termref def="dt-entity">entities</termref>,
-which contain either parsed or unparsed data. Parsed data is made up of <termref
-def="dt-character">characters</termref>, some of which form <termref def="dt-chardata">character
-data</termref>, and some of which form <termref def="dt-markup">markup</termref>.
-Markup encodes a description of the document's storage layout and logical
-structure. XML provides a mechanism to impose constraints on the storage layout
-and logical structure.</p>
-<p><termdef id="dt-xml-proc" term="XML Processor">A software module called
-an <term>XML processor</term> is used to read XML documents and provide access
-to their content and structure.</termdef> <termdef id="dt-app" term="Application">It
-is assumed that an XML processor is doing its work on behalf of another module,
-called the <term>application</term>.</termdef> This specification describes
-the required behavior of an XML processor in terms of how it must read XML
-data and the information it must provide to the application.</p>
-<div2 id="sec-origin-goals">
-<head>Origin and Goals</head>
-<p>XML was developed by an XML Working Group (originally known as the SGML
-Editorial Review Board) formed under the auspices of the World Wide Web Consortium
-(W3C) in 1996. It was chaired by Jon Bosak of Sun Microsystems with the active
-participation of an XML Special Interest Group (previously known as the SGML
-Working Group) also organized by the W3C. The membership of the XML Working
-Group is given in an appendix. Dan Connolly served as the WG's contact with
-the W3C.</p>
-<p>The design goals for XML are:</p>
-<olist>
-<item><p>XML shall be straightforwardly usable over the Internet.</p></item>
-<item><p>XML shall support a wide variety of applications.</p></item>
-<item><p>XML shall be compatible with SGML.</p></item>
-<item><p>It shall be easy to write programs which process XML documents.</p>
-</item>
-<item><p>The number of optional features in XML is to be kept to the absolute
-minimum, ideally zero.</p></item>
-<item><p>XML documents should be human-legible and reasonably clear.</p></item>
-<item><p>The XML design should be prepared quickly.</p></item>
-<item><p>The design of XML shall be formal and concise.</p></item>
-<item><p>XML documents shall be easy to create.</p></item>
-<item><p>Terseness in XML markup is of minimal importance.</p></item>
-</olist>
-<p>This specification, together with associated standards (Unicode and ISO/IEC
-10646 for characters, Internet RFC 1766 for language identification tags,
-ISO 639 for language name codes, and ISO 3166 for country name codes), provides
-all the information necessary to understand XML Version &versionOfXML; and
-construct computer programs to process it.</p>
-<p>This version of the XML specification <!-- is for &doc.audience;.--> &doc.distribution;.</p>
-</div2>
-<div2 id="sec-terminology">
-<head>Terminology</head>
-<p>The terminology used to describe XML documents is defined in the body of
-this specification. The terms defined in the following list are used in building
-those definitions and in describing the actions of an XML processor: <glist>
-<gitem><label>may</label>
-<def>
-<p><termdef id="dt-may" term="May">Conforming documents and XML processors
-are permitted to but need not behave as described.</termdef></p>
-</def></gitem>
-<gitem><label>must</label>
-<def>
-<p><termdef id="dt-must" term="Must">Conforming documents and XML processors
-are required to behave as described; otherwise they are in error. <!-- do NOT change this! this is what defines a violation of
-a 'must' clause as 'an error'. -MSM --></termdef></p>
-</def></gitem>
-<gitem><label>error</label>
-<def>
-<p><termdef id="dt-error" term="Error">A violation of the rules of this specification;
-results are undefined. Conforming software may detect and report an error
-and may recover from it.</termdef></p>
-</def></gitem>
-<gitem><label>fatal error</label>
-<def>
-<p><termdef id="dt-fatal" term="Fatal Error">An error which a conforming <termref
-def="dt-xml-proc">XML processor</termref> must detect and report to the application.
-After encountering a fatal error, the processor may continue processing the
-data to search for further errors and may report such errors to the application.
-In order to support correction of errors, the processor may make unprocessed
-data from the document (with intermingled character data and markup) available
-to the application. Once a fatal error is detected, however, the processor
-must not continue normal processing (i.e., it must not continue to pass character
-data and information about the document's logical structure to the application
-in the normal way).</termdef></p>
-</def></gitem>
-<gitem><label>at user option</label>
-<def>
-<p><termdef id="dt-atuseroption" term="At user option">Conforming software
-may or must (depending on the modal verb in the sentence) behave as described;
-if it does, it must provide users a means to enable or disable the behavior
-described.</termdef></p>
-</def></gitem>
-<gitem><label>validity constraint</label>
-<def>
-<p><termdef id="dt-vc" term="Validity constraint">A rule which applies to
-all <termref def="dt-valid">valid</termref> XML documents. Violations of validity
-constraints are errors; they must, at user option, be reported by <termref
-def="dt-validating">validating XML processors</termref>.</termdef></p>
-</def></gitem>
-<gitem><label>well-formedness constraint</label>
-<def>
-<p><termdef id="dt-wfc" term="Well-formedness constraint">A rule which applies
-to all <termref def="dt-wellformed">well-formed</termref> XML documents. Violations
-of well-formedness constraints are <termref def="dt-fatal">fatal errors</termref>.</termdef></p>
-</def></gitem>
-<gitem><label>match</label>
-<def>
-<p><termdef id="dt-match" term="match">(Of strings or names:) Two strings
-or names being compared must be identical. Characters with multiple possible
-representations in ISO/IEC 10646 (e.g. characters with both precomposed and
-base+diacritic forms) match only if they have the same representation in both
-strings. <phrase diff="del"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E85">[E85]</loc>At
-user option, processors may normalize such characters to some canonical form. </phrase>No
-case folding is performed. (Of strings and rules in the grammar:) A string
-matches a grammatical production if it belongs to the language generated by
-that production. (Of content and content models:) An element matches its declaration
-when it conforms in the fashion described in the constraint <specref ref="elementvalid"/>.</termdef></p>
-</def></gitem>
-<gitem><label>for compatibility</label>
-<def>
-<p><termdef id="dt-compat" term="For Compatibility"><phrase diff="add"><loc
-role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E87">[E87]</loc>Marks
-a sentence describing</phrase> a feature of XML included solely to ensure
-that XML remains compatible with SGML.</termdef></p>
-</def></gitem>
-<gitem><label>for interoperability</label>
-<def>
-<p><termdef id="dt-interop" term="For interoperability"><phrase diff="add"><loc
-role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E87">[E87]</loc>Marks
-a sentence describing</phrase> a non-binding recommendation included to increase
-the chances that XML documents can be processed by the existing installed
-base of SGML processors which predate the &WebSGML;.</termdef></p>
-</def></gitem>
-</glist></p>
-</div2>
-</div1>
-<!-- &Docs; -->
-<div1 id="sec-documents">
-<head>Documents</head>
-<p><termdef id="dt-xml-doc" term="XML Document"> A data object is an <term>XML
-document</term> if it is <termref def="dt-wellformed">well-formed</termref>,
-as defined in this specification. A well-formed XML document may in addition
-be <termref def="dt-valid">valid</termref> if it meets certain further constraints.</termdef></p>
-<p>Each XML document has both a logical and a physical structure. Physically,
-the document is composed of units called <termref def="dt-entity">entities</termref>.
-An entity may <termref def="dt-entref">refer</termref> to other entities to
-cause their inclusion in the document. A document begins in a <quote>root</quote>
-or <termref def="dt-docent">document entity</termref>. Logically, the document
-is composed of declarations, elements, comments, character references, and
-processing instructions, all of which are indicated in the document by explicit
-markup. The logical and physical structures must nest properly, as described
-in <specref ref="wf-entities"/>.</p>
-<div2 id="sec-well-formed">
-<head>Well-Formed XML Documents</head>
-<p><termdef id="dt-wellformed" term="Well-Formed"> A textual object is a <term>well-formed</term>
-XML document if:</termdef></p>
-<olist>
-<item><p>Taken as a whole, it matches the production labeled <nt def="NT-document">document</nt>.</p>
-</item>
-<item><p>It meets all the well-formedness constraints given in this specification.</p>
-</item>
-<item><p>Each of the <termref def="dt-parsedent">parsed entities</termref>
-which is referenced directly or indirectly within the document is <termref
-def="dt-wellformed">well-formed</termref>.</p></item>
-</olist>
-<scrap id="document" lang="ebnf">
-<head>Document</head>
-<prod id="NT-document">
-<lhs>document</lhs><rhs><nt def="NT-prolog">prolog</nt> <nt def="NT-element">element</nt> <nt
-def="NT-Misc">Misc</nt>*</rhs>
-</prod>
-</scrap>
-<p>Matching the <nt def="NT-document">document</nt> production implies that:</p>
-<olist>
-<item><p>It contains one or more <termref def="dt-element">elements</termref>.</p>
-</item>
-<!--* N.B. some readers (notably JC) find the following
-paragraph awkward and redundant. I agree it's logically redundant:
-it *says* it is summarizing the logical implications of
-matching the grammar, and that means by definition it's
-logically redundant. I don't think it's rhetorically
-redundant or unnecessary, though, so I'm keeping it. It
-could however use some recasting when the editors are feeling
-stronger. -MSM *-->
-<item><p><termdef id="dt-root" term="Root Element">There is exactly one element,
-called the <term>root</term>, or document element, no part of which appears
-in the <termref def="dt-content">content</termref> of any other element.</termdef> <phrase
-diff="chg"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E17">[E17]</loc>For
-all other elements, if the <termref def="dt-stag">start-tag</termref> is in
-the content of another element, the <termref def="dt-etag">end-tag</termref>
-is in the content of the same element.</phrase> More simply stated, the elements,
-delimited by start- and end-tags, nest properly within each other.</p></item>
-</olist>
-<p><termdef id="dt-parentchild" term="Parent/Child">As a consequence of this,
-for each non-root element <el>C</el> in the document, there is one other element <el>P</el>
-in the document such that <el>C</el> is in the content of <el>P</el>, but
-is not in the content of any other element that is in the content of <el>P</el>. <el>P</el>
-is referred to as the <term>parent</term> of <el>C</el>, and <el>C</el> as
-a <term>child</term> of <el>P</el>.</termdef></p>
-</div2>
-<div2 id="charsets">
-<head>Characters</head>
-<p><termdef id="dt-text" term="Text">A parsed entity contains <term>text</term>,
-a sequence of <termref def="dt-character">characters</termref>, which may
-represent markup or character data.</termdef> <termdef id="dt-character" term="Character">A <term>character</term>
-is an atomic unit of text as specified by ISO/IEC 10646 <bibref ref="ISO10646"/> <phrase
-diff="add"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E67">[E67]</loc>(see
-also <bibref ref="ISO10646-2000"/>)</phrase>. Legal characters are tab, carriage
-return, line feed, and the legal <phrase diff="del"><loc role="erratumref"
-href="http://www.w3.org/XML/xml-19980210-errata#E35">[E35]</loc>graphic </phrase>characters
-of Unicode and ISO/IEC 10646. <phrase diff="add"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E69">[E69]</loc>The
-versions of these standards cited in <specref ref="sec-existing-stds"/> were
-current at the time this document was prepared. New characters may be added
-to these standards by amendments or new editions. Consequently, XML processors
-must accept any character in the range specified for <nt def="NT-Char">Char</nt>.</phrase>
-The use of <quote>compatibility characters</quote>, as defined in section
-6.8 of <bibref ref="Unicode"/> <phrase diff="add"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E67">[E67]</loc>(see
-also D21 in section 3.6 of <bibref ref="Unicode3"/>)</phrase>, is discouraged.</termdef></p>
-<scrap id="char32" lang="ebnf">
-<head>Character Range</head>
-<prodgroup pcw2="4" pcw4="17.5" pcw5="11">
-<prod id="NT-Char">
-<lhs>Char</lhs><rhs>#x9 | #xA | #xD | [#x20-#xD7FF] | [#xE000-#xFFFD] | [#x10000-#x10FFFF]</rhs>
-<com>any Unicode character, excluding the surrogate blocks, FFFE, and FFFF.</com>
-</prod>
-</prodgroup></scrap>
-<p>The mechanism for encoding character code points into bit patterns may
-vary from entity to entity. All XML processors must accept the UTF-8 and UTF-16
-encodings of 10646; the mechanisms for signaling which of the two is in use,
-or for bringing other encodings into play, are discussed later, in <specref
-ref="charencoding"/>.</p>
-<!--
-<p>Regardless of the specific encoding used, any character in
-the ISO/IEC 10646 character set may be referred to by the decimal
-or hexadecimal equivalent of its UCS-4 code value.
-</p>-->
-</div2>
-<div2 id="sec-common-syn">
-<head>Common Syntactic Constructs</head>
-<p>This section defines some symbols used widely in the grammar.</p>
-<p><nt def="NT-S">S</nt> (white space) consists of one or more space (#x20)
-characters, carriage returns, line feeds, or tabs.</p>
-<scrap id="white" lang="ebnf">
-<head>White Space</head>
-<prodgroup pcw2="4" pcw4="17.5" pcw5="11">
-<prod id="NT-S">
-<lhs>S</lhs><rhs>(#x20 | #x9 | #xD | #xA)+</rhs>
-</prod>
-</prodgroup></scrap>
-<p>Characters are classified for convenience as letters, digits, or other
-characters. <phrase diff="chg"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E30">[E30]</loc>A
-letter consists of an alphabetic or syllabic base character or an ideographic
-character.</phrase> Full definitions of the specific characters in each class
-are given in <specref ref="CharClasses"/>.</p>
-<p><termdef id="dt-name" term="Name">A <term>Name</term> is a token beginning
-with a letter or one of a few punctuation characters, and continuing with
-letters, digits, hyphens, underscores, colons, or full stops, together known
-as name characters.</termdef> Names beginning with the string <quote><code>xml</code></quote>,
-or any string which would match <code>(('X'|'x') ('M'|'m') ('L'|'l'))</code>,
-are reserved for standardization in this or future versions of this specification.</p>
-<note>
-<p diff="chg"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E98">[E98]</loc>The
-Namespaces in XML Recommendation <bibref ref="xml-names"/> assigns a meaning
-to names containing colon characters. Therefore, authors should not use the
-colon in XML names except for namespace purposes, but XML processors must
-accept the colon as a name character.</p>
-</note>
-<p>An <nt def="NT-Nmtoken">Nmtoken</nt> (name token) is any mixture of name
-characters.</p>
-<scrap lang="ebnf">
-<head>Names and Tokens</head>
-<prod id="NT-NameChar">
-<lhs>NameChar</lhs><rhs><nt def="NT-Letter">Letter</nt> | <nt def="NT-Digit">Digit</nt>
-| '.' | '-' | '_' | ':' | <nt def="NT-CombiningChar">CombiningChar</nt> | <nt
-def="NT-Extender">Extender</nt></rhs>
-</prod>
-<prod id="NT-Name">
-<lhs>Name</lhs><rhs>(<nt def="NT-Letter">Letter</nt> | '_' | ':') (<nt def="NT-NameChar">NameChar</nt>)*</rhs>
-</prod>
-<prod id="NT-Names">
-<lhs>Names</lhs><rhs><nt def="NT-Name">Name</nt> (<nt def="NT-S">S</nt> <nt
-def="NT-Name">Name</nt>)*</rhs>
-</prod>
-<prod id="NT-Nmtoken">
-<lhs>Nmtoken</lhs><rhs>(<nt def="NT-NameChar">NameChar</nt>)+</rhs>
-</prod>
-<prod id="NT-Nmtokens">
-<lhs>Nmtokens</lhs><rhs><nt def="NT-Nmtoken">Nmtoken</nt> (<nt def="NT-S">S</nt> <nt
-def="NT-Nmtoken">Nmtoken</nt>)*</rhs>
-</prod>
-</scrap>
-<p>Literal data is any quoted string not containing the quotation mark used
-as a delimiter for that string. Literals are used for specifying the content
-of internal entities (<nt def="NT-EntityValue">EntityValue</nt>), the values
-of attributes (<nt def="NT-AttValue">AttValue</nt>), and external identifiers
-(<nt def="NT-SystemLiteral">SystemLiteral</nt>). Note that a <nt def="NT-SystemLiteral">SystemLiteral</nt>
-can be parsed without scanning for markup.</p>
-<scrap lang="ebnf">
-<head>Literals</head>
-<prod id="NT-EntityValue">
-<lhs>EntityValue</lhs><rhs>'"' ([^%&"] | <nt def="NT-PEReference">PEReference</nt>
-| <nt def="NT-Reference">Reference</nt>)* '"' </rhs>
-<rhs>|  "'" ([^%&'] | <nt def="NT-PEReference">PEReference</nt> | <nt
-def="NT-Reference">Reference</nt>)* "'"</rhs>
-</prod>
-<prod id="NT-AttValue">
-<lhs>AttValue</lhs><rhs>'"' ([^<&"] | <nt def="NT-Reference">Reference</nt>)*
-'"' </rhs>
-<rhs>|  "'" ([^<&'] | <nt def="NT-Reference">Reference</nt>)*
-"'"</rhs>
-</prod>
-<prod id="NT-SystemLiteral">
-<lhs>SystemLiteral</lhs><rhs>('"' [^"]* '"') | ("'" [^']* "'") </rhs>
-</prod>
-<prod id="NT-PubidLiteral">
-<lhs>PubidLiteral</lhs><rhs>'"' <nt def="NT-PubidChar">PubidChar</nt>* '"'
-| "'" (<nt def="NT-PubidChar">PubidChar</nt> - "'")* "'"</rhs>
-</prod>
-<prod id="NT-PubidChar">
-<lhs>PubidChar</lhs><rhs>#x20 | #xD | #xA | [a-zA-Z0-9] | [-'()+,./:=?;!*#@$_%]</rhs>
-</prod>
-</scrap>
-<note diff="add">
-<p><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E72">[E72]</loc>Although
-the <nt def="NT-EntityValue">EntityValue</nt> production allows the definition
-of an entity consisting of a single explicit <code><</code> in the literal
-(e.g., <code><!ENTITY mylt "<"></code>), it is strongly advised to avoid
-this practice since any reference to that entity will cause a well-formedness
-error.</p>
-</note>
-</div2>
-<div2 id="syntax">
-<head>Character Data and Markup</head>
-<p><termref def="dt-text">Text</termref> consists of intermingled <termref
-def="dt-chardata">character data</termref> and markup. <termdef id="dt-markup"
-term="Markup"><term>Markup</term> takes the form of <termref def="dt-stag">start-tags</termref>, <termref
-def="dt-etag">end-tags</termref>, <termref def="dt-empty">empty-element tags</termref>, <termref
-def="dt-entref">entity references</termref>, <termref def="dt-charref">character
-references</termref>, <termref def="dt-comment">comments</termref>, <termref
-def="dt-cdsection">CDATA section</termref> delimiters, <termref def="dt-doctype">document
-type declarations</termref>, <termref def="dt-pi">processing instructions</termref>, <phrase
-diff="add"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E89">[E89]</loc><nt
-def="NT-XMLDecl">XML declarations</nt>, <nt def="NT-TextDecl">text declarations</nt>,
-and any white space that is at the top level of the document entity (that
-is, outside the document element and not inside any other markup).</phrase></termdef></p>
-<p><termdef id="dt-chardata" term="Character Data">All text that is not markup
-constitutes the <term>character data</term> of the document.</termdef></p>
-<p>The ampersand character (&) and the left angle bracket (<) may appear
-in their literal form <emph>only</emph> when used as markup delimiters, or
-within a <termref def="dt-comment">comment</termref>, a <termref def="dt-pi">processing
-instruction</termref>, or a <termref def="dt-cdsection">CDATA section</termref>.<phrase
-diff="del"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E18">[E18]</loc>They
-are also legal within the <termref def="dt-litentval">literal entity value</termref>
-of an internal entity declaration; see <specref ref="wf-entities"/>.</phrase> <!-- FINAL EDIT: restore internal entity decl or leave it out. -->
-If they are needed elsewhere, they must be <termref def="dt-escape">escaped</termref>
-using either <termref def="dt-charref">numeric character references</termref>
-or the strings <quote><code>&amp;</code></quote> and <quote><code>&lt;</code></quote>
-respectively. The right angle bracket (>) may be represented using the string <quote><code>&gt;</code></quote>,
-and must, <termref def="dt-compat">for compatibility</termref>, be escaped
-using <quote><code>&gt;</code></quote> or a character reference when it
-appears in the string <quote><code>]]></code></quote> in content, when
-that string is not marking the end of a <termref def="dt-cdsection">CDATA
-section</termref>.</p>
-<p>In the content of elements, character data is any string of characters
-which does not contain the start-delimiter of any markup. In a CDATA section,
-character data is any string of characters not including the CDATA-section-close
-delimiter, <quote><code>]]></code></quote>.</p>
-<p>To allow attribute values to contain both single and double quotes, the
-apostrophe or single-quote character (') may be represented as <quote><code>&apos;</code></quote>,
-and the double-quote character (") as <quote><code>&quot;</code></quote>.</p>
-<scrap lang="ebnf">
-<head>Character Data</head>
-<prod id="NT-CharData">
-<lhs>CharData</lhs><rhs>[^<&]* - ([^<&]* ']]>' [^<&]*)</rhs>
-</prod>
-</scrap>
-</div2>
-<div2 id="sec-comments">
-<head>Comments</head>
-<p><termdef id="dt-comment" term="Comment"><term>Comments</term> may appear
-anywhere in a document outside other <termref def="dt-markup">markup</termref>;
-in addition, they may appear within the document type declaration at places
-allowed by the grammar. They are not part of the document's <termref def="dt-chardata">character
-data</termref>; an XML processor may, but need not, make it possible for an
-application to retrieve the text of comments. <termref def="dt-compat">For
-compatibility</termref>, the string <quote><code>--</code></quote> (double-hyphen)
-must not occur within comments.</termdef> <phrase diff="add"><loc role="erratumref"
-href="http://www.w3.org/XML/xml-19980210-errata#E63">[E63]</loc>Parameter
-entity references are not recognized within comments.</phrase></p>
-<scrap lang="ebnf">
-<head>Comments</head>
-<prod id="NT-Comment">
-<lhs>Comment</lhs><rhs>'<!--' ((<nt def="NT-Char">Char</nt> - '-') | ('-'
-(<nt def="NT-Char">Char</nt> - '-')))* '-->'</rhs>
-</prod>
-</scrap>
-<p>An example of a comment:</p>
-<eg><!&como; declarations for <head> & <body> &comc;></eg>
-<p diff="add"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E27">[E27]</loc>Note
-that the grammar does not allow a comment ending in <code>---></code>. The
-following example is <emph>not</emph> well-formed.</p>
-<eg diff="add"><!-- B+, B, or B---></eg>
-</div2>
-<div2 id="sec-pi">
-<head>Processing Instructions</head>
-<p><termdef id="dt-pi" term="Processing instruction"><term>Processing instructions</term>
-(PIs) allow documents to contain instructions for applications.</termdef></p>
-<scrap lang="ebnf">
-<head>Processing Instructions</head>
-<prod id="NT-PI">
-<lhs>PI</lhs><rhs>'<?' <nt def="NT-PITarget">PITarget</nt> (<nt def="NT-S">S</nt>
-(<nt def="NT-Char">Char</nt>* - (<nt def="NT-Char">Char</nt>* &pic; <nt def="NT-Char">Char</nt>*)))? &pic;</rhs>
-</prod>
-<prod id="NT-PITarget">
-<lhs>PITarget</lhs><rhs><nt def="NT-Name">Name</nt> - (('X' | 'x') ('M' |
-'m') ('L' | 'l'))</rhs>
-</prod>
-</scrap>
-<p>PIs are not part of the document's <termref def="dt-chardata">character
-data</termref>, but must be passed through to the application. The PI begins
-with a target (<nt def="NT-PITarget">PITarget</nt>) used to identify the application
-to which the instruction is directed. The target names <quote><code>XML</code></quote>, <quote><code>xml</code></quote>,
-and so on are reserved for standardization in this or future versions of this
-specification. The XML <termref def="dt-notation">Notation</termref> mechanism
-may be used for formal declaration of PI targets. <phrase diff="add"><loc
-role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E63">[E63]</loc>Parameter
-entity references are not recognized within processing instructions.</phrase></p>
-</div2>
-<div2 id="sec-cdata-sect">
-<head>CDATA Sections</head>
-<p><termdef id="dt-cdsection" term="CDATA Section"><term>CDATA sections</term>
-may occur anywhere character data may occur; they are used to escape blocks
-of text containing characters which would otherwise be recognized as markup.
-CDATA sections begin with the string <quote><code><![CDATA[</code></quote>
-and end with the string <quote><code>]]></code></quote>:</termdef></p>
-<scrap lang="ebnf">
-<head>CDATA Sections</head>
-<prod id="NT-CDSect">
-<lhs>CDSect</lhs><rhs><nt def="NT-CDStart">CDStart</nt> <nt def="NT-CData">CData</nt> <nt
-def="NT-CDEnd">CDEnd</nt></rhs>
-</prod>
-<prod id="NT-CDStart">
-<lhs>CDStart</lhs><rhs>'<![CDATA['</rhs>
-</prod>
-<prod id="NT-CData">
-<lhs>CData</lhs><rhs>(<nt def="NT-Char">Char</nt>* - (<nt def="NT-Char">Char</nt>*
-']]>' <nt def="NT-Char">Char</nt>*)) </rhs>
-</prod>
-<prod id="NT-CDEnd">
-<lhs>CDEnd</lhs><rhs>']]>'</rhs>
-</prod>
-</scrap>
-<p>Within a CDATA section, only the <nt def="NT-CDEnd">CDEnd</nt> string is
-recognized as markup, so that left angle brackets and ampersands may occur
-in their literal form; they need not (and cannot) be escaped using <quote><code>&lt;</code></quote>
-and <quote><code>&amp;</code></quote>. CDATA sections cannot nest.</p>
-<p>An example of a CDATA section, in which <quote><code><greeting></code></quote>
-and <quote><code></greeting></code></quote> are recognized as <termref
-def="dt-chardata">character data</termref>, not <termref def="dt-markup">markup</termref>:</p>
-<eg><![CDATA[<greeting>Hello, world!</greeting>]]> </eg>
-</div2>
-<div2 id="sec-prolog-dtd">
-<head>Prolog and Document Type Declaration</head>
-<p><termdef id="dt-xmldecl" term="XML Declaration">XML documents <phrase diff="chg"><loc
-role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E107">[E107]</loc>should</phrase>
-begin with an <term>XML declaration</term> which specifies the version of
-XML being used.</termdef> For example, the following is a complete XML document, <termref
-def="dt-wellformed">well-formed</termref> but not <termref def="dt-valid">valid</termref>:</p>
-<eg><![CDATA[<?xml version="1.0"?> <greeting>Hello, world!</greeting> ]]></eg>
-<p>and so is this:</p>
-<eg><![CDATA[<greeting>Hello, world!</greeting>]]></eg>
-<p>The version number <quote><code>1.0</code></quote> should be used to indicate
-conformance to this version of this specification; it is an error for a document
-to use the value <quote><code>1.0</code></quote> if it does not conform to
-this version of this specification. It is the intent of the XML working group
-to give later versions of this specification numbers other than <quote><code>1.0</code></quote>,
-but this intent does not indicate a commitment to produce any future versions
-of XML, nor if any are produced, to use any particular numbering scheme. Since
-future versions are not ruled out, this construct is provided as a means to
-allow the possibility of automatic version recognition, should it become necessary.
-Processors may signal an error if they receive documents labeled with versions
-they do not support.</p>
-<p>The function of the markup in an XML document is to describe its storage
-and logical structure and to associate attribute-value pairs with its logical
-structures. XML provides a mechanism, the <termref def="dt-doctype">document
-type declaration</termref>, to define constraints on the logical structure
-and to support the use of predefined storage units. <termdef id="dt-valid"
-term="Validity">An XML document is <term>valid</term> if it has an associated
-document type declaration and if the document complies with the constraints
-expressed in it.</termdef></p>
-<p>The document type declaration must appear before the first <termref def="dt-element">element</termref>
-in the document.</p>
-<scrap id="xmldoc" lang="ebnf">
-<head>Prolog</head>
-<prodgroup pcw2="6" pcw4="17.5" pcw5="9">
-<prod id="NT-prolog">
-<lhs>prolog</lhs><rhs><nt def="NT-XMLDecl">XMLDecl</nt>? <nt def="NT-Misc">Misc</nt>*
-(<nt def="NT-doctypedecl">doctypedecl</nt> <nt def="NT-Misc">Misc</nt>*)?</rhs>
-</prod>
-<prod id="NT-XMLDecl">
-<lhs>XMLDecl</lhs><rhs>&pio; <nt def="NT-VersionInfo">VersionInfo</nt> <nt
-def="NT-EncodingDecl">EncodingDecl</nt>? <nt def="NT-SDDecl">SDDecl</nt>? <nt
-def="NT-S">S</nt>? &pic;</rhs>
-</prod>
-<prod id="NT-VersionInfo" diff="chg">
-<lhs>VersionInfo</lhs><rhs><nt def="NT-S">S</nt> 'version' <nt def="NT-Eq">Eq</nt>
-("'" <nt def="NT-VersionNum">VersionNum</nt> "'" | '"' <nt def="NT-VersionNum">VersionNum</nt>
-'"')<com><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E15">[E15]</loc></com></rhs>
-</prod>
-<prod id="NT-Eq">
-<lhs>Eq</lhs><rhs><nt def="NT-S">S</nt>? '=' <nt def="NT-S">S</nt>?</rhs>
-</prod>
-<prod id="NT-VersionNum">
-<lhs>VersionNum</lhs><rhs>([a-zA-Z0-9_.:] | '-')+</rhs>
-</prod>
-<prod id="NT-Misc">
-<lhs>Misc</lhs><rhs><nt def="NT-Comment">Comment</nt> | <nt def="NT-PI">PI</nt>
-| <nt def="NT-S">S</nt></rhs>
-</prod>
-</prodgroup></scrap>
-<p><termdef id="dt-doctype" term="Document Type Declaration">The XML <term>document
-type declaration</term> contains or points to <termref def="dt-markupdecl">markup
-declarations</termref> that provide a grammar for a class of documents. This
-grammar is known as a document type definition, or <term>DTD</term>. The document
-type declaration can point to an external subset (a special kind of <termref
-def="dt-extent">external entity</termref>) containing markup declarations,
-or can contain the markup declarations directly in an internal subset, or
-can do both. The DTD for a document consists of both subsets taken together.</termdef></p>
-<p><termdef id="dt-markupdecl" term="markup declaration"> A <term>markup declaration</term>
-is an <termref def="dt-eldecl">element type declaration</termref>, an <termref
-def="dt-attdecl">attribute-list declaration</termref>, an <termref def="dt-entdecl">entity
-declaration</termref>, or a <termref def="dt-notdecl">notation declaration</termref>.</termdef>
-These declarations may be contained in whole or in part within <termref def="dt-PE">parameter
-entities</termref>, as described in the well-formedness and validity constraints
-below. For <phrase diff="chg"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E14">[E14]</loc>further</phrase>
-information, see <specref ref="sec-physical-struct"/>.</p>
-<scrap id="dtd" lang="ebnf">
-<head>Document Type Definition</head>
-<prodgroup pcw2="6" pcw4="17.5" pcw5="9">
-<prod id="NT-doctypedecl" diff="chg">
-<lhs>doctypedecl</lhs><rhs>'<!DOCTYPE' <nt def="NT-S">S</nt> <nt def="NT-Name">Name</nt>
-(<nt def="NT-S">S</nt> <nt def="NT-ExternalID">ExternalID</nt>)? <nt def="NT-S">S</nt>?
-('[' (<nt def="NT-markupdecl">markupdecl</nt> | <nt diff="chg" def="NT-DeclSep">DeclSep</nt>)*
-']' <nt def="NT-S">S</nt>?)? '>'</rhs><vc def="vc-roottype"/><wfc def="ExtSubset"
-diff="add"/><com><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E109">[E109]</loc></com>
-</prod>
-<prod id="NT-DeclSep" diff="add">
-<lhs>DeclSep</lhs><rhs><nt def="NT-PEReference">PEReference</nt> | <nt def="NT-S">S</nt></rhs>
-<wfc def="PE-between-Decls" diff="add"/><com><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E109">[E109]</loc></com>
-</prod>
-<prod id="NT-markupdecl">
-<lhs>markupdecl</lhs><rhs><nt def="NT-elementdecl">elementdecl</nt> | <nt
-def="NT-AttlistDecl">AttlistDecl</nt> | <nt def="NT-EntityDecl">EntityDecl</nt>
-| <nt def="NT-NotationDecl">NotationDecl</nt> | <nt def="NT-PI">PI</nt> | <nt
-def="NT-Comment">Comment</nt> </rhs><vc def="vc-PEinMarkupDecl"/><wfc def="wfc-PEinInternalSubset"/>
-</prod>
-</prodgroup></scrap>
-<p diff="add"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E82">[E82]</loc>Note
-that it is possible to construct a well-formed document containing a <nt def="NT-doctypedecl">doctypedecl</nt>
-that neither points to an external subset nor contains an internal subset.</p>
-<p>The markup declarations may be made up in whole or in part of the <termref
-def="dt-repltext">replacement text</termref> of <termref def="dt-PE">parameter
-entities</termref>. The productions later in this specification for individual
-nonterminals (<nt def="NT-elementdecl">elementdecl</nt>, <nt def="NT-AttlistDecl">AttlistDecl</nt>,
-and so on) describe the declarations <emph>after</emph> all the parameter
-entities have been <termref def="dt-include">included</termref>.</p>
-<p diff="add"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E75">[E75]</loc>Parameter
-entity references are recognized anywhere in the DTD (internal and external
-subsets and external parameter entities), except in literals, processing instructions,
-comments, and the contents of ignored conditional sections (see <specref ref="sec-condition-sect"/>).
-They are also recognized in entity value literals. The use of parameter entities
-in the internal subset is restricted as described below.</p>
-<vcnote id="vc-roottype"><head>Root Element Type</head><p>The <nt def="NT-Name">Name</nt>
-in the document type declaration must match the element type of the <termref
-def="dt-root">root element</termref>.</p>
-</vcnote>
-<vcnote id="vc-PEinMarkupDecl"><head>Proper Declaration/PE Nesting</head>
-<p>Parameter-entity <termref def="dt-repltext">replacement text</termref>
-must be properly nested with markup declarations. That is to say, if either
-the first character or the last character of a markup declaration (<nt def="NT-markupdecl">markupdecl</nt>
-above) is contained in the replacement text for a <termref def="dt-PERef">parameter-entity
-reference</termref>, both must be contained in the same replacement text.</p>
-</vcnote>
-<wfcnote id="wfc-PEinInternalSubset"><head>PEs in Internal Subset</head><p>In
-the internal DTD subset, <termref def="dt-PERef">parameter-entity references</termref>
-can occur only where markup declarations can occur, not within markup declarations.
-(This does not apply to references that occur in external parameter entities
-or to the external subset.)</p>
-</wfcnote>
-<wfcnote id="ExtSubset" diff="add"><head><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E109">[E109]</loc>External
-Subset</head><p>The external subset, if any, must match the production for <nt
-def="NT-extSubset">extSubset</nt>.</p>
-</wfcnote>
-<wfcnote id="PE-between-Decls" diff="add"><head><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E109">[E109]</loc>PE
-Between Declarations</head><p>The replacement text of a parameter entity reference
-in a <nt def="NT-DeclSep">DeclSep</nt> must match the production <nt def="NT-extSubsetDecl">extSubsetDecl</nt>.</p>
-</wfcnote>
-<p>Like the internal subset, the external subset and any external parameter
-entities <phrase diff="chg"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E109">[E109]</loc>referenced
-in a <nt def="NT-DeclSep">DeclSep</nt></phrase> must consist of a series of
-complete markup declarations of the types allowed by the non-terminal symbol <nt
-def="NT-markupdecl">markupdecl</nt>, interspersed with white space or <termref
-def="dt-PERef">parameter-entity references</termref>. However, portions of
-the contents of the external subset or of <phrase diff="add"><loc role="erratumref"
-href="http://www.w3.org/XML/xml-19980210-errata#E109">[E109]</loc>these </phrase>
-external parameter entities may conditionally be ignored by using the <termref
-def="dt-cond-section">conditional section</termref> construct; this is not
-allowed in the internal subset.</p>
-<scrap id="ext-Subset">
-<head>External Subset</head>
-<prodgroup pcw2="6" pcw4="17.5" pcw5="9">
-<prod id="NT-extSubset">
-<lhs>extSubset</lhs><rhs><nt def="NT-TextDecl">TextDecl</nt>? <nt def="NT-extSubsetDecl">extSubsetDecl</nt></rhs>
-</prod>
-<prod id="NT-extSubsetDecl" diff="chg">
-<lhs>extSubsetDecl</lhs><rhs>( <nt def="NT-markupdecl">markupdecl</nt> | <nt
-def="NT-conditionalSect">conditionalSect</nt> | <nt diff="chg" def="NT-DeclSep">DeclSep</nt>)*</rhs>
-<com><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E109">[E109]</loc></com>
-</prod>
-</prodgroup></scrap>
-<p>The external subset and external parameter entities also differ from the
-internal subset in that in them, <termref def="dt-PERef">parameter-entity
-references</termref> are permitted <emph>within</emph> markup declarations,
-not only <emph>between</emph> markup declarations.</p>
-<p>An example of an XML document with a document type declaration:</p>
-<eg><![CDATA[<?xml version="1.0"?> <!DOCTYPE greeting SYSTEM "hello.dtd"> <greeting>Hello, world!</greeting> ]]></eg>
-<p>The <termref def="dt-sysid">system identifier</termref> <quote><code>hello.dtd</code></quote>
-gives the <phrase diff="chg"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E78">[E78]</loc>address
-(a URI reference)</phrase> of a DTD for the document.</p>
-<p>The declarations can also be given locally, as in this example:</p>
-<eg><![CDATA[<?xml version="1.0" encoding="UTF-8" ?>
-<!DOCTYPE greeting [
-  <!ELEMENT greeting (#PCDATA)>
-]>
-<greeting>Hello, world!</greeting>]]></eg>
-<p>If both the external and internal subsets are used, the internal subset
-is considered to occur before the external subset. <!-- 'is considered to'? boo. whazzat mean? -->
-This has the effect that entity and attribute-list declarations in the internal
-subset take precedence over those in the external subset.</p>
-</div2>
-<div2 id="sec-rmd">
-<head>Standalone Document Declaration</head>
-<p>Markup declarations can affect the content of the document, as passed from
-an <termref def="dt-xml-proc">XML processor</termref> to an application; examples
-are attribute defaults and entity declarations. The standalone document declaration,
-which may appear as a component of the XML declaration, signals whether or
-not there are such declarations which appear external to the <termref def="dt-docent">document
-entity</termref><phrase diff="add"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E64">[E64]</loc>
-or in parameter entities. <termdef id="dt-extmkpdecl" term="External Markup Declaration">An <term>external
-markup declaration</term> is defined as a markup declaration occurring in
-the external subset or in a parameter entity (external or internal, the latter
-being included because non-validating processors are not required to read
-them).</termdef></phrase></p>
-<scrap id="fulldtd" lang="ebnf">
-<head>Standalone Document Declaration</head>
-<prodgroup pcw2="4" pcw4="19.5" pcw5="9">
-<prod id="NT-SDDecl">
-<lhs>SDDecl</lhs><rhs> <nt def="NT-S">S</nt> 'standalone' <nt def="NT-Eq">Eq</nt>
-(("'" ('yes' | 'no') "'") | ('"' ('yes' | 'no') '"')) </rhs><vc def="vc-check-rmd"/>
-</prod>
-</prodgroup></scrap>
-<p>In a standalone document declaration, the value <attval>yes</attval> indicates
-that there are no <phrase diff="chg"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E64">[E64]</loc><termref
-def="dt-extmkpdecl">external markup declarations</termref></phrase> which
-affect the information passed from the XML processor to the application. The
-value <attval>no</attval> indicates that there are or may be such external
-markup declarations. Note that the standalone document declaration only denotes
-the presence of external <emph>declarations</emph>; the presence, in a document,
-of references to external <emph>entities</emph>, when those entities are internally
-declared, does not change its standalone status.</p>
-<p>If there are no external markup declarations, the standalone document declaration
-has no meaning. If there are external markup declarations but there is no
-standalone document declaration, the value <attval>no</attval> is assumed.</p>
-<p>Any XML document for which <code>standalone="no"</code> holds can be converted
-algorithmically to a standalone document, which may be desirable for some
-network delivery applications.</p>
-<vcnote id="vc-check-rmd"><head>Standalone Document Declaration</head><p>The
-standalone document declaration must have the value <attval>no</attval> if
-any external markup declarations contain declarations of:</p>
-<ulist>
-<item><p>attributes with <termref def="dt-default">default</termref> values,
-if elements to which these attributes apply appear in the document without
-specifications of values for these attributes, or</p></item>
-<item><p>entities (other than &magicents;), if <termref def="dt-entref">references</termref>
-to those entities appear in the document, or</p></item>
-<item><p>attributes with values subject to <titleref href="#AVNormalize">normalization</titleref>,
-where the attribute appears in the document with a value which will change
-as a result of normalization, or</p></item>
-<item><p>element types with <termref def="dt-elemcontent">element content</termref>,
-if white space occurs directly within any instance of those types.</p></item>
-</ulist>
-</vcnote>
-<p>An example XML declaration with a standalone document declaration:</p>
-<eg><?xml version="&versionOfXML;" standalone='yes'?></eg>
-</div2>
-<div2 id="sec-white-space">
-<head>White Space Handling</head>
-<p>In editing XML documents, it is often convenient to use <quote>white space</quote>
-(spaces, tabs, and blank lines<phrase diff="del"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E39">[E39]</loc>,
-denoted by the nonterminal <nt def="NT-S">S</nt> in this specification</phrase>)
-to set apart the markup for greater readability. Such white space is typically
-not intended for inclusion in the delivered version of the document. On the
-other hand, <quote>significant</quote> white space that should be preserved
-in the delivered version is common, for example in poetry and source code.</p>
-<p>An <termref def="dt-xml-proc">XML processor</termref> must always pass
-all characters in a document that are not markup through to the application.
-A <termref def="dt-validating"> validating XML processor</termref> must also
-inform the application which of these characters constitute white space appearing
-in <termref def="dt-elemcontent">element content</termref>.</p>
-<p>A special <termref def="dt-attr">attribute</termref> named <att>xml:space</att>
-may be attached to an element to signal an intention that in that element,
-white space should be preserved by applications. In valid documents, this
-attribute, like any other, must be <termref def="dt-attdecl">declared</termref>
-if it is used. When declared, it must be given as an <termref def="dt-enumerated">enumerated
-type</termref> whose <phrase diff="chg"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E81">[E81]</loc>values
-are one or both of</phrase> <attval>default</attval> and <attval>preserve</attval>.
-For example:</p>
-<eg diff="chg"><![CDATA[<!ATTLIST poem  xml:space (default|preserve) 'preserve'>]]>
-
-<!-- <loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E81">[E81]</loc>-->
-<!ATTLIST pre xml:space (preserve) #FIXED 'preserve'></eg>
-<p>The value <attval>default</attval> signals that applications' default white-space
-processing modes are acceptable for this element; the value <attval>preserve</attval>
-indicates the intent that applications preserve all the white space. This
-declared intent is considered to apply to all elements within the content
-of the element where it is specified, unless overriden with another instance
-of the <att>xml:space</att> attribute.</p>
-<p>The <termref def="dt-root">root element</termref> of any document is considered
-to have signaled no intentions as regards application space handling, unless
-it provides a value for this attribute or the attribute is declared with a
-default value.</p>
-</div2>
-<div2 id="sec-line-ends">
-<head>End-of-Line Handling</head>
-<p>XML <termref def="dt-parsedent">parsed entities</termref> are often stored
-in computer files which, for editing convenience, are organized into lines.
-These lines are typically separated by some combination of the characters
-carriage-return (#xD) and line-feed (#xA).</p>
-<p diff="del">To simplify the tasks of <termref def="dt-app">applications</termref>,
-wherever an external parsed entity or the literal entity value of an internal
-parsed entity contains either the literal two-character sequence <quote>#xD#xA</quote>
-or a standalone literal #xD, an <termref def="dt-xml-proc">XML processor</termref>
-must pass to the application the single character #xA. (This behavior can
-conveniently be produced by normalizing all line breaks to #xA on input, before
-parsing.)</p>
-<p diff="add"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E104">[E104]</loc>To
-simplify the tasks of <termref def="dt-app">applications</termref>, the characters
-passed to an application by the <termref def="dt-xml-proc">XML processor</termref>
-must be as if the XML processor normalized all line breaks in external parsed
-entities (including the document entity) on input, before parsing, by translating
-both the two-character sequence #xD #xA and any #xD that is not followed by
-#xA to a single #xA character.</p>
-</div2>
-<div2 id="sec-lang-tag">
-<head>Language Identification</head>
-<p>In document processing, it is often useful to identify the natural or formal
-language in which the content is written. A special <termref def="dt-attr">attribute</termref>
-named <att>xml:lang</att> may be inserted in documents to specify the language
-used in the contents and attribute values of any element in an XML document.
-In valid documents, this attribute, like any other, must be <termref def="dt-attdecl">declared</termref>
-if it is used. <phrase diff="chg"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E73">[E73]</loc>The
-values of the attribute are language identifiers as defined by <bibref ref="RFC1766"/>, <titleref>Tags
-for the Identification of Languages</titleref>, or its successor on the IETF
-Standards Track.</phrase></p>
-<note diff="add">
-<p><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E73">[E73]</loc><bibref
-ref="RFC1766"/> tags are constructed from two-letter language codes as defined
-by <bibref ref="ISO639"/>, from two-letter country codes as defined by <bibref
-ref="ISO3166"/>, or from language identifiers registered with the Internet
-Assigned Numbers Authority <phrase diff="chg"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E58">[E58]</loc><bibref
-diff="chg" ref="IANA-LANGCODES"/></phrase>. It is expected that the successor
-to <bibref ref="RFC1766"/> will introduce three-letter language codes for
-languages not presently covered by <bibref ref="ISO639"/>.</p>
-</note>
-<p diff="add"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E73">[E73]</loc>(Productions
-33 through 38 have been removed.)</p>
-<scrap diff="del" lang="ebnf">
-<head>Language Identification</head>
-<prod id="NT-LanguageID">
-<lhs>LanguageID</lhs><rhs><nt def="NT-Langcode">Langcode</nt> ('-' <nt def="NT-Subcode">Subcode</nt>)*</rhs>
-</prod>
-<prod id="NT-Langcode">
-<lhs>Langcode</lhs><rhs><nt def="NT-ISO639Code">ISO639Code</nt> | <nt def="NT-IanaCode">IanaCode</nt>
-| <nt def="NT-UserCode">UserCode</nt></rhs>
-</prod>
-<prod id="NT-ISO639Code">
-<lhs>ISO639Code</lhs><rhs>([a-z] | [A-Z]) ([a-z] | [A-Z])</rhs>
-</prod>
-<prod id="NT-IanaCode">
-<lhs>IanaCode</lhs><rhs>('i' | 'I') '-' ([a-z] | [A-Z])+</rhs>
-</prod>
-<prod id="NT-UserCode">
-<lhs>UserCode</lhs><rhs>('x' | 'X') '-' ([a-z] | [A-Z])+</rhs>
-</prod>
-<prod id="NT-Subcode">
-<lhs>Subcode</lhs><rhs>([a-z] | [A-Z])+</rhs>
-</prod>
-</scrap>
-<p diff="del">The <nt def="NT-Langcode">Langcode</nt> may be any of the following:</p>
-<ulist diff="del">
-<item><p>a two-letter language code as defined by <bibref ref="ISO639"/>, <titleref>Codes
-for the representation of names of languages</titleref></p></item>
-<item><p>a language identifier registered with the Internet Assigned Numbers
-Authority <bibref diff="chg" ref="IANA-LANGCODES"/>; these begin with the
-prefix <quote><code>i-</code></quote> (or <quote><code>I-</code></quote>)</p>
-</item>
-<item><p>a language identifier assigned by the user, or agreed on between
-parties in private use; these must begin with the prefix <quote><code>x-</code></quote>
-or <quote><code>X-</code></quote> in order to ensure that they do not conflict
-with names later standardized or registered with IANA</p></item>
-</ulist>
-<p diff="del">There may be any number of <nt def="NT-Subcode">Subcode</nt>
-segments; if the first subcode segment exists and the Subcode consists of
-two letters, then it must be a country code from <bibref ref="ISO3166"/>,
-"Codes for the representation of names of countries." If the first subcode
-consists of more than two letters, it must be a subcode for the language in
-question registered with IANA, unless the <nt def="NT-Langcode">Langcode</nt>
-begins with the prefix "<code>x-</code>" or "<code>X-</code>". </p>
-<p diff="del">It is customary to give the language code in lower case, and
-the country code (if any) in upper case. Note that these values, unlike other
-names in XML documents, are case insensitive.</p>
-<p>For example:</p>
-<eg><![CDATA[<p xml:lang="en">The quick brown fox jumps over the lazy dog.</p>
-<p xml:lang="en-GB">What colour is it?</p>
-<p xml:lang="en-US">What color is it?</p>
-<sp who="Faust" desc='leise' xml:lang="de">
-  <l>Habe nun, ach! Philosophie,</l>
-  <l>Juristerei, und Medizin</l>
-  <l>und leider auch Theologie</l>
-  <l>durchaus studiert mit heißem Bemüh'n.</l>
-</sp>]]></eg>
-<!--<p>The xml:lang value is considered to apply both to the contents of an
-element and
-(unless otherwise via attribute default values) to the
-values of all of its attributes with free-text (CDATA) values. -->
-<p>The intent declared with <att>xml:lang</att> is considered to apply to
-all attributes and content of the element where it is specified, unless overridden
-with an instance of <att>xml:lang</att> on another element within that content.</p>
-<!--
-If no
-value is specified for xml:lang on an element, and no default value is
-defined for it in the DTD, then the xml:lang attribute of any element
-takes the same value it has in the parent element, if any. The two
-technical terms in the following example both have the same effective
-value for xml:lang:
-
-  <p xml:lang="en">Here the keywords are
-  <term xml:lang="en">shift</term> and
-  <term>reduce</term>. ...</p>
-
-The application, not the XML processor, is responsible for this '
-inheritance' of attribute values.
--->
-<p>A simple declaration for <att>xml:lang</att> might take the form</p>
-<eg>xml:lang NMTOKEN #IMPLIED</eg>
-<p>but specific default values may also be given, if appropriate. In a collection
-of French poems for English students, with glosses and notes in English, the <att>xml:lang</att>
-attribute might be declared this way:</p>
-<eg><![CDATA[<!ATTLIST poem   xml:lang NMTOKEN 'fr'>
-<!ATTLIST gloss  xml:lang NMTOKEN 'en'>
-<!ATTLIST note   xml:lang NMTOKEN 'en'>]]></eg>
-</div2>
-</div1>
-<!-- &Elements; -->
-<div1 id="sec-logical-struct">
-<head>Logical Structures</head>
-<p><termdef id="dt-element" term="Element">Each <termref def="dt-xml-doc">XML
-document</termref> contains one or more <term>elements</term>, the boundaries
-of which are either delimited by <termref def="dt-stag">start-tags</termref>
-and <termref def="dt-etag">end-tags</termref>, or, for <termref def="dt-empty">empty</termref>
-elements, by an <termref def="dt-eetag">empty-element tag</termref>. Each
-element has a type, identified by name, sometimes called its <quote>generic
-identifier</quote> (GI), and may have a set of attribute specifications.</termdef>
-Each attribute specification has a <termref def="dt-attrname">name</termref>
-and a <termref def="dt-attrval">value</termref>.</p>
-<scrap lang="ebnf">
-<head>Element</head>
-<prod id="NT-element">
-<lhs>element</lhs><rhs><nt def="NT-EmptyElemTag">EmptyElemTag</nt></rhs>
-<rhs>| <nt def="NT-STag">STag</nt> <nt def="NT-content">content</nt> <nt def="NT-ETag">ETag</nt></rhs>
-<wfc def="GIMatch"/><vc def="elementvalid"/>
-</prod>
-</scrap>
-<p>This specification does not constrain the semantics, use, or (beyond syntax)
-names of the element types and attributes, except that names beginning with
-a match to <code>(('X'|'x')('M'|'m')('L'|'l'))</code> are reserved for standardization
-in this or future versions of this specification.</p>
-<wfcnote id="GIMatch"><head>Element Type Match</head><p>The <nt def="NT-Name">Name</nt>
-in an element's end-tag must match the element type in the start-tag.</p>
-</wfcnote>
-<vcnote id="elementvalid"><head>Element Valid</head><p>An element is valid
-if there is a declaration matching <nt def="NT-elementdecl">elementdecl</nt>
-where the <nt def="NT-Name">Name</nt> matches the element type, and one of
-the following holds:</p>
-<olist>
-<item><p>The declaration matches <kw>EMPTY</kw> and the element has no <termref
-def="dt-content">content</termref>.</p></item>
-<item><p>The declaration matches <nt def="NT-children">children</nt> and the
-sequence of <termref def="dt-parentchild">child elements</termref> belongs
-to the language generated by the regular expression in the content model,
-with optional white space (characters matching the nonterminal <nt def="NT-S">S</nt>)
-between <phrase diff="chg"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E59">[E59]</loc>the
-start-tag and the first child element, between child elements, or between
-the last child element and the end-tag. Note that a CDATA section containing
-only white space does not match the nonterminal <nt def="NT-S">S</nt>, and
-hence cannot appear in these positions.</phrase></p></item>
-<item><p>The declaration matches <nt def="NT-Mixed">Mixed</nt> and the content
-consists of <termref def="dt-chardata">character data</termref> and <termref
-def="dt-parentchild">child elements</termref> whose types match names in the
-content model.</p></item>
-<item><p>The declaration matches <kw>ANY</kw>, and the types of any <termref
-def="dt-parentchild">child elements</termref> have been declared.</p></item>
-</olist>
-</vcnote>
-<div2 id="sec-starttags">
-<head>Start-Tags, End-Tags, and Empty-Element Tags</head>
-<p><termdef id="dt-stag" term="Start-Tag">The beginning of every non-empty
-XML element is marked by a <term>start-tag</term>.</termdef></p>
-<scrap lang="ebnf">
-<head>Start-tag</head>
-<prodgroup pcw2="6" pcw4="15" pcw5="11.5">
-<prod id="NT-STag">
-<lhs>STag</lhs><rhs>'<' <nt def="NT-Name">Name</nt> (<nt def="NT-S">S</nt> <nt
-def="NT-Attribute">Attribute</nt>)* <nt def="NT-S">S</nt>? '>'</rhs><wfc def="uniqattspec"/>
-</prod>
-<prod id="NT-Attribute">
-<lhs>Attribute</lhs><rhs><nt def="NT-Name">Name</nt> <nt def="NT-Eq">Eq</nt> <nt
-def="NT-AttValue">AttValue</nt></rhs><vc def="ValueType"/><wfc def="NoExternalRefs"/>
-<wfc def="CleanAttrVals"/>
-</prod>
-</prodgroup></scrap>
-<p>The <nt def="NT-Name">Name</nt> in the start- and end-tags gives the element's <term>type</term>. <termdef
-id="dt-attr" term="Attribute"> The <nt def="NT-Name">Name</nt>-<nt def="NT-AttValue">AttValue</nt>
-pairs are referred to as the <term>attribute specifications</term> of the
-element</termdef>, <termdef id="dt-attrname" term="Attribute Name">with the <nt
-def="NT-Name">Name</nt> in each pair referred to as the <term>attribute name</term></termdef>
-and <termdef id="dt-attrval" term="Attribute Value">the content of the <nt
-def="NT-AttValue">AttValue</nt> (the text between the <code>'</code> or <code>"</code>
-delimiters) as the <term>attribute value</term>.</termdef><phrase diff="add"><loc
-role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E46">[E46]</loc>Note
-that the order of attribute specifications in a start-tag or empty-element
-tag is not significant.</phrase></p>
-<wfcnote id="uniqattspec"><head>Unique Att Spec</head><p>No attribute name
-may appear more than once in the same start-tag or empty-element tag.</p>
-</wfcnote>
-<vcnote id="ValueType"><head>Attribute Value Type</head><p>The attribute must
-have been declared; the value must be of the type declared for it. (For attribute
-types, see <specref ref="attdecls"/>.)</p>
-</vcnote>
-<wfcnote id="NoExternalRefs"><head>No External Entity References</head><p>Attribute
-values cannot contain direct or indirect entity references to external entities.</p>
-</wfcnote>
-<wfcnote id="CleanAttrVals"><head>No <code><</code> in Attribute Values</head>
-<p>The <termref def="dt-repltext">replacement text</termref> of any entity
-referred to directly or indirectly in an attribute value <phrase diff="del"><loc
-role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E83">[E83]</loc>(other
-than <quote><code>&lt;</code></quote>) </phrase>must not contain a <code><</code>.</p>
-</wfcnote>
-<p>An example of a start-tag:</p>
-<eg><termdef id="dt-dog" term="dog"></eg>
-<p><termdef id="dt-etag" term="End Tag">The end of every element that begins
-with a start-tag must be marked by an <term>end-tag</term> containing a name
-that echoes the element's type as given in the start-tag:</termdef></p>
-<scrap lang="ebnf">
-<head>End-tag</head>
-<prodgroup pcw2="6" pcw4="15" pcw5="11.5">
-<prod id="NT-ETag">
-<lhs>ETag</lhs><rhs>'</' <nt def="NT-Name">Name</nt> <nt def="NT-S">S</nt>?
-'>'</rhs>
-</prod>
-</prodgroup></scrap>
-<p>An example of an end-tag:</p>
-<eg></termdef></eg>
-<p><termdef id="dt-content" term="Content">The <termref def="dt-text">text</termref>
-between the start-tag and end-tag is called the element's <term>content</term>:</termdef></p>
-<scrap lang="ebnf">
-<head>Content of Elements</head>
-<prodgroup pcw2="6" pcw4="15" pcw5="11.5">
-<prod id="NT-content" diff="chg">
-<lhs>content</lhs><rhs><nt def="NT-CharData">CharData</nt>? ((<nt def="NT-element">element</nt>
-| <nt def="NT-Reference">Reference</nt> | <nt def="NT-CDSect">CDSect</nt>
-| <nt def="NT-PI">PI</nt> | <nt def="NT-Comment">Comment</nt>) <nt def="NT-CharData">CharData</nt>?)*</rhs>
-<com><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E71">[E71]</loc></com>
-</prod>
-</prodgroup></scrap>
-<p><phrase diff="chg"><termdef id="dt-empty" term="Empty"><loc role="erratumref"
-href="http://www.w3.org/XML/xml-19980210-errata#E97">[E97]</loc>An element
-with no content is said to be <term>empty</term>.</termdef> The representation
-of an empty element is either a start-tag immediately followed by an end-tag,
-or an empty-element tag.</phrase> <termdef id="dt-eetag" term="empty-element tag">An <term>empty-element
-tag</term> takes a special form:</termdef></p>
-<scrap lang="ebnf">
-<head>Tags for Empty Elements</head>
-<prodgroup pcw2="6" pcw4="15" pcw5="11.5">
-<prod id="NT-EmptyElemTag">
-<lhs>EmptyElemTag</lhs><rhs>'<' <nt def="NT-Name">Name</nt> (<nt def="NT-S">S</nt> <nt
-def="NT-Attribute">Attribute</nt>)* <nt def="NT-S">S</nt>? '/>'</rhs><wfc
-def="uniqattspec"/>
-</prod>
-</prodgroup></scrap>
-<p>Empty-element tags may be used for any element which has no content, whether
-or not it is declared using the keyword <kw>EMPTY</kw>. <termref def="dt-interop">For
-interoperability</termref>, the empty-element tag <phrase diff="chg"><loc
-role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E45">[E45]</loc>should
-be used, and should only be used,</phrase> for elements which are declared
-EMPTY.</p>
-<p>Examples of empty elements:</p>
-<eg><IMG align="left"
- src="http://www.w3.org/Icons/WWW/w3c_home" />
-<br></br>
-<br/></eg>
-</div2>
-<div2 id="elemdecls">
-<head>Element Type Declarations</head>
-<p>The <termref def="dt-element">element</termref> structure of an <termref
-def="dt-xml-doc">XML document</termref> may, for <termref def="dt-valid">validation</termref>
-purposes, be constrained using element type and attribute-list declarations.
-An element type declaration constrains the element's <termref def="dt-content">content</termref>.</p>
-<p>Element type declarations often constrain which element types can appear
-as <termref def="dt-parentchild">children</termref> of the element. At user
-option, an XML processor may issue a warning when a declaration mentions an
-element type for which no declaration is provided, but this is not an error.</p>
-<p><termdef id="dt-eldecl" term="Element Type declaration">An <term>element
-type declaration</term> takes the form:</termdef></p>
-<scrap lang="ebnf">
-<head>Element Type Declaration</head>
-<prodgroup pcw2="5.5" pcw4="18" pcw5="9">
-<prod id="NT-elementdecl">
-<lhs>elementdecl</lhs><rhs>'<!ELEMENT' <nt def="NT-S">S</nt> <nt def="NT-Name">Name</nt> <nt
-def="NT-S">S</nt> <nt def="NT-contentspec">contentspec</nt> <nt def="NT-S">S</nt>?
-'>'</rhs><vc def="EDUnique"/>
-</prod>
-<prod id="NT-contentspec">
-<lhs>contentspec</lhs><rhs>'EMPTY' | 'ANY' | <nt def="NT-Mixed">Mixed</nt>
-| <nt def="NT-children">children</nt> </rhs>
-</prod>
-</prodgroup></scrap>
-<p>where the <nt def="NT-Name">Name</nt> gives the element type being declared.</p>
-<vcnote id="EDUnique"><head>Unique Element Type Declaration</head><p>No element
-type may be declared more than once.</p>
-</vcnote>
-<p>Examples of element type declarations:</p>
-<eg><!ELEMENT br EMPTY>
-<!ELEMENT p (#PCDATA|emph)* >
-<!ELEMENT %name.para; %content.para; >
-<!ELEMENT container ANY></eg>
-<div3 id="sec-element-content">
-<head>Element Content</head>
-<p><termdef id="dt-elemcontent" term="Element content">An element <termref
-def="dt-stag">type</termref> has <term>element content</term> when elements
-of that type must contain only <termref def="dt-parentchild">child</termref>
-elements (no character data), optionally separated by white space (characters
-matching the nonterminal <nt def="NT-S">S</nt>).</termdef><termdef id="dt-content-model"
-term="Content model">In this case, the constraint includes a <phrase diff="chg"><loc
-role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E55">[E55]</loc><term>content
-model</term></phrase>, a simple grammar governing the allowed types of the
-child elements and the order in which they are allowed to appear.</termdef>
-The grammar is built on content particles (<nt def="NT-cp">cp</nt>s), which
-consist of names, choice lists of content particles, or sequence lists of
-content particles:</p>
-<scrap lang="ebnf">
-<head>Element-content Models</head>
-<prodgroup pcw2="5.5" pcw4="16" pcw5="11">
-<prod id="NT-children">
-<lhs>children</lhs><rhs>(<nt def="NT-choice">choice</nt> | <nt def="NT-seq">seq</nt>)
-('?' | '*' | '+')?</rhs>
-</prod>
-<prod id="NT-cp">
-<lhs>cp</lhs><rhs>(<nt def="NT-Name">Name</nt> | <nt def="NT-choice">choice</nt>
-| <nt def="NT-seq">seq</nt>) ('?' | '*' | '+')?</rhs>
-</prod>
-<prod id="NT-choice" diff="chg">
-<lhs>choice</lhs><rhs>'(' <nt def="NT-S">S</nt>? <nt def="NT-cp">cp</nt> ( <nt
-def="NT-S">S</nt>? '|' <nt def="NT-S">S</nt>? <nt def="NT-cp">cp</nt> )+ <nt
-def="NT-S">S</nt>? ')'</rhs><com><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E50">[E50]</loc></com>
-<com><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E52">[E52]</loc></com>
-<vc def="vc-PEinGroup"/>
-</prod>
-<prod id="NT-seq" diff="chg">
-<lhs>seq</lhs><rhs>'(' <nt def="NT-S">S</nt>? <nt def="NT-cp">cp</nt> ( <nt
-def="NT-S">S</nt>? ',' <nt def="NT-S">S</nt>? <nt def="NT-cp">cp</nt> )* <nt
-def="NT-S">S</nt>? ')'</rhs><com><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E52">[E52]</loc></com>
-<vc def="vc-PEinGroup"/>
-</prod>
-</prodgroup></scrap>
-<p>where each <nt def="NT-Name">Name</nt> is the type of an element which
-may appear as a <termref def="dt-parentchild">child</termref>. Any content
-particle in a choice list may appear in the <termref def="dt-elemcontent">element
-content</termref> at the location where the choice list appears in the grammar;
-content particles occurring in a sequence list must each appear in the <termref
-def="dt-elemcontent">element content</termref> in the order given in the list.
-The optional character following a name or list governs whether the element
-or the content particles in the list may occur one or more (<code>+</code>),
-zero or more (<code>*</code>), or zero or one times (<code>?</code>). The
-absence of such an operator means that the element or content particle must
-appear exactly once. This syntax and meaning are identical to those used in
-the productions in this specification.</p>
-<p>The content of an element matches a content model if and only if it is
-possible to trace out a path through the content model, obeying the sequence,
-choice, and repetition operators and matching each element in the content
-against an element type in the content model. <termref def="dt-compat">For
-compatibility</termref>, it is an error if an element in the document can
-match more than one occurrence of an element type in the content model. For
-more information, see <specref ref="determinism"/>.</p>
-<!--appendix <specref ref="determinism"/>.-->
-<!-- appendix on deterministic content models. -->
-<vcnote id="vc-PEinGroup"><head>Proper Group/PE Nesting</head><p>Parameter-entity <termref
-def="dt-repltext">replacement text</termref> must be properly nested with <phrase
-diff="chg"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E11">[E11]</loc>parenthesized</phrase>
-groups. That is to say, if either of the opening or closing parentheses in
-a <nt def="NT-choice">choice</nt>, <nt def="NT-seq">seq</nt>, or <nt def="NT-Mixed">Mixed</nt>
-construct is contained in the replacement text for a <termref def="dt-PERef">parameter
-entity</termref>, both must be contained in the same replacement text.</p>
-<p diff="chg"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E19">[E19]</loc><termref
-def="dt-interop">For interoperability</termref>, if a parameter-entity reference
-appears in a <nt def="NT-choice">choice</nt>, <nt def="NT-seq">seq</nt>, or <nt
-def="NT-Mixed">Mixed</nt> construct, its replacement text should contain at
-least one non-blank character, and neither the first nor last non-blank character
-of the replacement text should be a connector (<code>|</code> or <code>,</code>).</p>
-</vcnote>
-<p>Examples of element-content models:</p>
-<eg><!ELEMENT spec (front, body, back?)>
-<!ELEMENT div1 (head, (p | list | note)*, div2*)>
-<!ELEMENT dictionary-body (%div.mix; | %dict.mix;)*></eg>
-</div3>
-<div3 id="sec-mixed-content">
-<head>Mixed Content</head>
-<p><termdef id="dt-mixed" term="Mixed Content">An element <termref def="dt-stag">type</termref>
-has <term>mixed content</term> when elements of that type may contain character
-data, optionally interspersed with <termref def="dt-parentchild">child</termref>
-elements.</termdef> In this case, the types of the child elements may be constrained,
-but not their order or their number of occurrences:</p>
-<scrap lang="ebnf">
-<head>Mixed-content Declaration</head>
-<prodgroup pcw2="5.5" pcw4="16" pcw5="11">
-<prod id="NT-Mixed">
-<lhs>Mixed</lhs><rhs>'(' <nt def="NT-S">S</nt>? '#PCDATA' (<nt def="NT-S">S</nt>?
-'|' <nt def="NT-S">S</nt>? <nt def="NT-Name">Name</nt>)* <nt def="NT-S">S</nt>?
-')*' </rhs>
-<rhs>| '(' <nt def="NT-S">S</nt>? '#PCDATA' <nt def="NT-S">S</nt>? ')' </rhs>
-<vc def="vc-PEinGroup"/><vc def="vc-MixedChildrenUnique"/>
-</prod>
-</prodgroup></scrap>
-<p>where the <nt def="NT-Name">Name</nt>s give the types of elements that
-may appear as children. <phrase diff="add"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E10">[E10]</loc>The
-keyword <kw>#PCDATA</kw> derives historically from the term <quote>parsed
-character data.</quote></phrase></p>
-<vcnote id="vc-MixedChildrenUnique"><head>No Duplicate Types</head><p>The
-same name must not appear more than once in a single mixed-content declaration.</p>
-</vcnote>
-<p>Examples of mixed content declarations:</p>
-<eg><!ELEMENT p (#PCDATA|a|ul|b|i|em)*>
-<!ELEMENT p (#PCDATA | %font; | %phrase; | %special; | %form;)* >
-<!ELEMENT b (#PCDATA)></eg>
-</div3>
-</div2>
-<div2 id="attdecls">
-<head>Attribute-List Declarations</head>
-<p><termref def="dt-attr">Attributes</termref> are used to associate name-value
-pairs with <termref def="dt-element">elements</termref>. Attribute specifications
-may appear only within <termref def="dt-stag">start-tags</termref> and <termref
-def="dt-eetag">empty-element tags</termref>; thus, the productions used to
-recognize them appear in <specref ref="sec-starttags"/>. Attribute-list declarations
-may be used:</p>
-<ulist>
-<item><p>To define the set of attributes pertaining to a given element type.</p>
-</item>
-<item><p>To establish type constraints for these attributes.</p></item>
-<item><p>To provide <termref def="dt-default">default values</termref> for
-attributes.</p></item>
-</ulist>
-<p><termdef id="dt-attdecl" term="Attribute-List Declaration"> <term>Attribute-list
-declarations</term> specify the name, data type, and default value (if any)
-of each attribute associated with a given element type:</termdef></p>
-<scrap lang="ebnf">
-<head>Attribute-list Declaration</head>
-<prod id="NT-AttlistDecl">
-<lhs>AttlistDecl</lhs><rhs>'<!ATTLIST' <nt def="NT-S">S</nt> <nt def="NT-Name">Name</nt> <nt
-def="NT-AttDef">AttDef</nt>* <nt def="NT-S">S</nt>? '>'</rhs>
-</prod>
-<prod id="NT-AttDef">
-<lhs>AttDef</lhs><rhs><nt def="NT-S">S</nt> <nt def="NT-Name">Name</nt> <nt
-def="NT-S">S</nt> <nt def="NT-AttType">AttType</nt> <nt def="NT-S">S</nt> <nt
-def="NT-DefaultDecl">DefaultDecl</nt></rhs>
-</prod>
-</scrap>
-<p>The <nt def="NT-Name">Name</nt> in the <nt def="NT-AttlistDecl">AttlistDecl</nt>
-rule is the type of an element. At user option, an XML processor may issue
-a warning if attributes are declared for an element type not itself declared,
-but this is not an error. The <nt def="NT-Name">Name</nt> in the <nt def="NT-AttDef">AttDef</nt>
-rule is the name of the attribute.</p>
-<p>When more than one <nt def="NT-AttlistDecl">AttlistDecl</nt> is provided
-for a given element type, the contents of all those provided are merged. When
-more than one definition is provided for the same attribute of a given element
-type, the first declaration is binding and later declarations are ignored. <phrase
-diff="chg"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E9">[E9]</loc><termref
-def="dt-interop">For interoperability,</termref> writers of DTDs may choose
-to provide at most one attribute-list declaration for a given element type,
-at most one attribute definition for a given attribute name in an attribute-list
-declaration, and at least one attribute definition in each attribute-list
-declaration.</phrase> For interoperability, an XML processor may at user option
-issue a warning when more than one attribute-list declaration is provided
-for a given element type, or more than one attribute definition is provided
-for a given attribute, but this is not an error.</p>
-<div3 id="sec-attribute-types">
-<head>Attribute Types</head>
-<p>XML attribute types are of three kinds: a string type, a set of tokenized
-types, and enumerated types. The string type may take any literal string as
-a value; the tokenized types have varying lexical and semantic constraints<phrase
-diff="chg"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E8">[E8]</loc>.
-The validity constraints noted in the grammar are applied after the attribute
-value has been normalized as described in <specref ref="attdecls"/>.</phrase></p>
-<scrap lang="ebnf">
-<head>Attribute Types</head>
-<prodgroup pcw4="14" pcw5="11.5">
-<prod id="NT-AttType">
-<lhs>AttType</lhs><rhs><nt def="NT-StringType">StringType</nt> | <nt def="NT-TokenizedType">TokenizedType</nt>
-| <nt def="NT-EnumeratedType">EnumeratedType</nt> </rhs>
-</prod>
-<prod id="NT-StringType">
-<lhs>StringType</lhs><rhs>'CDATA'</rhs>
-</prod>
-<prod id="NT-TokenizedType">
-<lhs>TokenizedType</lhs><rhs>'ID'</rhs><vc def="id"/><vc def="one-id-per-el"/>
-<vc def="id-default"/>
-<rhs>| 'IDREF'</rhs><vc def="idref"/>
-<rhs>| 'IDREFS'</rhs><vc def="idref"/>
-<rhs>| 'ENTITY'</rhs><vc def="entname"/>
-<rhs>| 'ENTITIES'</rhs><vc def="entname"/>
-<rhs>| 'NMTOKEN'</rhs><vc def="nmtok"/>
-<rhs>| 'NMTOKENS'</rhs><vc def="nmtok"/>
-</prod>
-</prodgroup></scrap>
-<vcnote id="id"><head>ID</head><p>Values of type <kw>ID</kw> must match the <nt
-def="NT-Name">Name</nt> production. A name must not appear more than once
-in an XML document as a value of this type; i.e., ID values must uniquely
-identify the elements which bear them.</p>
-</vcnote>
-<vcnote id="one-id-per-el"><head>One ID per Element Type</head><p>No element
-type may have more than one ID attribute specified.</p>
-</vcnote>
-<vcnote id="id-default"><head>ID Attribute Default</head><p>An ID attribute
-must have a declared default of <kw>#IMPLIED</kw> or <kw>#REQUIRED</kw>.</p>
-</vcnote>
-<vcnote id="idref"><head>IDREF</head><p>Values of type <kw>IDREF</kw> must
-match the <nt def="NT-Name">Name</nt> production, and values of type <kw>IDREFS</kw>
-must match <nt def="NT-Names">Names</nt>; each <nt def="NT-Name">Name</nt>
-must match the value of an ID attribute on some element in the XML document;
-i.e. <kw>IDREF</kw> values must match the value of some ID attribute.</p>
-</vcnote>
-<vcnote id="entname"><head>Entity Name</head><p>Values of type <kw>ENTITY</kw>
-must match the <nt def="NT-Name">Name</nt> production, values of type <kw>ENTITIES</kw>
-must match <nt def="NT-Names">Names</nt>; each <nt def="NT-Name">Name</nt>
-must match the name of an <termref def="dt-unparsed">unparsed entity</termref>
-declared in the <termref def="dt-doctype">DTD</termref>.</p>
-</vcnote>
-<vcnote id="nmtok"><head>Name Token</head><p>Values of type <kw>NMTOKEN</kw>
-must match the <nt def="NT-Nmtoken">Nmtoken</nt> production; values of type <kw>NMTOKENS</kw>
-must match <termref def="NT-Nmtokens">Nmtokens</termref>.</p>
-</vcnote>
-<!-- why?
-<p>The XML processor must normalize attribute values before
-passing them to the application, as described in
-<specref ref="AVNormalize"/>.</p>-->
-<p><termdef id="dt-enumerated" term="Enumerated Attribute
-Values"><term>Enumerated attributes</term> can take one of a list of values
-provided in the declaration</termdef>. There are two kinds of enumerated types:</p>
-<scrap lang="ebnf">
-<head>Enumerated Attribute Types</head>
-<prod id="NT-EnumeratedType">
-<lhs>EnumeratedType</lhs><rhs><nt def="NT-NotationType">NotationType</nt>
-| <nt def="NT-Enumeration">Enumeration</nt> </rhs>
-</prod>
-<prod id="NT-NotationType">
-<lhs>NotationType</lhs><rhs>'NOTATION' <nt def="NT-S">S</nt> '(' <nt def="NT-S">S</nt>? <nt
-def="NT-Name">Name</nt> (<nt def="NT-S">S</nt>? '|' <nt def="NT-S">S</nt>? <nt
-def="NT-Name">Name</nt>)* <nt def="NT-S">S</nt>? ')' </rhs><vc def="notatn"/>
-<vc def="OneNotationPer" diff="add"/><vc def="NoNotationEmpty" diff="add"/>
-</prod>
-<prod id="NT-Enumeration">
-<lhs>Enumeration</lhs><rhs>'(' <nt def="NT-S">S</nt>? <nt def="NT-Nmtoken">Nmtoken</nt>
-(<nt def="NT-S">S</nt>? '|' <nt def="NT-S">S</nt>? <nt def="NT-Nmtoken">Nmtoken</nt>)* <nt
-def="NT-S">S</nt>? ')'</rhs><vc def="enum"/>
-</prod>
-</scrap>
-<p>A <kw>NOTATION</kw> attribute identifies a <termref def="dt-notation">notation</termref>,
-declared in the DTD with associated system and/or public identifiers, to be
-used in interpreting the element to which the attribute is attached.</p>
-<vcnote id="notatn"><head>Notation Attributes</head><p>Values of this type
-must match one of the <titleref href="#Notations">notation</titleref> names
-included in the declaration; all notation names in the declaration must be
-declared.</p>
-</vcnote>
-<vcnote id="OneNotationPer" diff="add"><head><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E7">[E7]</loc>One
-Notation Per Element Type</head><p>No element type may have more than one <kw>NOTATION</kw>
-attribute specified.</p>
-</vcnote>
-<vcnote id="NoNotationEmpty" diff="add"><head><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E68">[E68]</loc>No
-Notation on Empty Element</head><p><termref def="dt-compat">For compatibility</termref>,
-an attribute of type <kw>NOTATION</kw> must not be declared on an element
-declared <kw>EMPTY</kw>.</p>
-</vcnote>
-<vcnote id="enum"><head>Enumeration</head><p>Values of this type must match
-one of the <nt def="NT-Nmtoken">Nmtoken</nt> tokens in the declaration.</p>
-</vcnote>
-<p><termref def="dt-interop">For interoperability,</termref> the same <nt
-def="NT-Nmtoken">Nmtoken</nt> should not occur more than once in the enumerated
-attribute types of a single element type.</p>
-</div3>
-<div3 id="sec-attr-defaults">
-<head>Attribute Defaults</head>
-<p>An <termref def="dt-attdecl">attribute declaration</termref> provides information
-on whether the attribute's presence is required, and if not, how an XML processor
-should react if a declared attribute is absent in a document.</p>
-<scrap lang="ebnf">
-<head>Attribute Defaults</head>
-<prodgroup pcw4="14" pcw5="11.5">
-<prod id="NT-DefaultDecl">
-<lhs>DefaultDecl</lhs><rhs>'#REQUIRED' | '#IMPLIED' </rhs>
-<rhs>| (('#FIXED' S)? <nt def="NT-AttValue">AttValue</nt>)</rhs><vc def="RequiredAttr"/>
-<vc def="defattrvalid"/><wfc def="CleanAttrVals"/><vc def="FixedAttr"/>
-</prod>
-</prodgroup></scrap>
-<p>In an attribute declaration, <kw>#REQUIRED</kw> means that the attribute
-must always be provided, <kw>#IMPLIED</kw> that no default value is provided. <!-- not any more!!
-<kw>#IMPLIED</kw> means that if the attribute is omitted
-from an element of this type,
-the XML processor must inform the application
-that no value was specified; no constraint is placed on the behavior
-of the application. --> <termdef id="dt-default" term="Attribute Default">If
-the declaration is neither <kw>#REQUIRED</kw> nor <kw>#IMPLIED</kw>, then
-the <nt def="NT-AttValue">AttValue</nt> value contains the declared <term>default</term>
-value; the <kw>#FIXED</kw> keyword states that the attribute must always have
-the default value. If a default value is declared, when an XML processor encounters
-an omitted attribute, it is to behave as though the attribute were present
-with the declared default value.</termdef></p>
-<vcnote id="RequiredAttr"><head>Required Attribute</head><p>If the default
-declaration is the keyword <kw>#REQUIRED</kw>, then the attribute must be
-specified for all elements of the type in the attribute-list declaration.</p>
-</vcnote>
-<vcnote id="defattrvalid"><head>Attribute Default Legal</head><p>The declared
-default value must meet the lexical constraints of the declared attribute
-type.</p>
-</vcnote>
-<vcnote id="FixedAttr"><head>Fixed Attribute Default</head><p>If an attribute
-has a default value declared with the <kw>#FIXED</kw> keyword, instances of
-that attribute must match the default value.</p>
-</vcnote>
-<p>Examples of attribute-list declarations:</p>
-<eg><!ATTLIST termdef
-          id      ID      #REQUIRED
-          name    CDATA   #IMPLIED>
-<!ATTLIST list
-          type    (bullets|ordered|glossary)  "ordered">
-<!ATTLIST form
-          method  CDATA   #FIXED "POST"></eg>
-</div3>
-<div3 id="AVNormalize" diff="chg">
-<head><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E70">[E70]</loc>Attribute-Value
-Normalization</head>
-<p>Before the value of an attribute is passed to the application or checked
-for validity, the XML processor must normalize the attribute value by applying
-the algorithm below, or by using some other method such that the value passed
-to the application is the same as that produced by the algorithm.</p>
-<olist>
-<item><p>All line breaks must have been normalized on input to #xA as described
-in <specref ref="sec-line-ends"/>, so the rest of this algorithm operates
-on text normalized in this way.</p></item>
-<item><p>Begin with a normalized value consisting of the empty string.</p>
-</item>
-<item><p>For each character, entity reference, or character reference in the
-unnormalized attribute value, beginning with the first and continuing to the
-last, do the following:</p>
-<ulist>
-<item><p>For a character reference, append the referenced character to the
-normalized value.</p></item>
-<item><p>For an entity reference, recursively apply step 3 of this algorithm
-to the replacement text of the entity.</p></item>
-<item><p>For a white space character (#x20, #xD, #xA, #x9), append a space
-character (#x20) to the normalized value.</p></item>
-<item><p>For another character, append the character to the normalized value.</p>
-</item>
-</ulist>
-</item>
-</olist>
-<p>If the attribute type is not CDATA, then the XML processor must further
-process the normalized attribute value by discarding any leading and trailing
-space (#x20) characters, and by replacing sequences of space (#x20) characters
-by a single space (#x20) character.</p>
-<p>Note that if the unnormalized attribute value contains a character reference
-to a white space character other than space (#x20), the normalized value contains
-the referenced character itself (#xD, #xA or #x9). This contrasts with the
-case where the unnormalized value contains a white space character (not a
-reference), which is replaced with a space character (#x20) in the normalized
-value and also contrasts with the case where the unnormalized value contains
-an entity reference whose replacement text contains a white space character;
-being recursively processed, the white space character is replaced with a
-space character (#x20) in the normalized value.</p>
-<p>All attributes for which no declaration has been read should be treated
-by a non-validating <phrase diff="chg"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E95">[E95]</loc>processor</phrase>
-as if declared <kw>CDATA</kw>.</p>
-<p>Following are examples of attribute normalization. Given the following
-declarations:</p>
-<eg><!ENTITY d "&#xD;">
-<!ENTITY a "&#xA;">
-<!ENTITY da "&#xD;&#xA;"></eg>
-<p>the attribute specifications in the left column below would be normalized
-to the character sequences of the middle column if the attribute <att>a</att>
-is declared <kw>NMTOKENS</kw> and to those of the right columns if <att>a</att>
-is declared <kw>CDATA</kw>.</p>
-<table border="1" frame="border"><thead><tr><th>Attribute specification</th>
-<th>a is NMTOKENS</th><th>a is CDATA</th></tr></thead><tbody><tr><td><eg>a="
-
-xyz"</eg></td><td><code>x y z</code></td><td><code>#x20 #x20 x y z</code></td>
-</tr><tr><td><eg>a="&d;&d;A&a;&a;B&da;"</eg></td><td><code>A
-#x20 B</code></td><td><code>#x20 #x20 A #x20 #x20 B #x20 #x20</code></td>
-</tr><tr><td><eg>a=
-"&#xd;&#xd;A&#xa;&#xa;B&#xd;&#xa;"</eg></td><td><code>#xD
-#xD A #xA #xA B #xD #xA</code></td><td><code>#xD #xD A #xA #xA B #xD #xD</code></td>
-</tr></tbody></table>
-<p>Note that the last example is invalid (but well-formed) if <att>a</att>
-is declared to be of type <kw>NMTOKENS</kw>.</p>
-</div3>
-</div2>
-<div2 id="sec-condition-sect">
-<head>Conditional Sections</head>
-<p><termdef id="dt-cond-section" term="conditional section"> <term>Conditional
-sections</term> are portions of the <termref def="dt-doctype">document type
-declaration external subset</termref> which are included in, or excluded from,
-the logical structure of the DTD based on the keyword which governs them.</termdef></p>
-<scrap lang="ebnf">
-<head>Conditional Section</head>
-<prodgroup pcw2="9" pcw4="14.5">
-<prod id="NT-conditionalSect">
-<lhs>conditionalSect</lhs><rhs><nt def="NT-includeSect">includeSect</nt> | <nt
-def="NT-ignoreSect">ignoreSect</nt> </rhs>
-</prod>
-<prod id="NT-includeSect">
-<lhs>includeSect</lhs><rhs>'<![' S? 'INCLUDE' S? '[' <nt def="NT-extSubsetDecl">extSubsetDecl</nt>
-']]>' </rhs><com><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E90">[E90]</loc></com>
-<vc def="condsec-nesting" diff="add"/>
-</prod>
-<prod id="NT-ignoreSect">
-<lhs>ignoreSect</lhs><rhs>'<![' S? 'IGNORE' S? '[' <nt def="NT-ignoreSectContents">ignoreSectContents</nt>*
-']]>'</rhs><com><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E90">[E90]</loc></com>
-<vc def="condsec-nesting" diff="add"/>
-</prod>
-<prod id="NT-ignoreSectContents">
-<lhs>ignoreSectContents</lhs><rhs><nt def="NT-Ignore">Ignore</nt> ('<![' <nt
-def="NT-ignoreSectContents">ignoreSectContents</nt> ']]>' <nt def="NT-Ignore">Ignore</nt>)*</rhs>
-</prod>
-<prod id="NT-Ignore">
-<lhs>Ignore</lhs><rhs><nt def="NT-Char">Char</nt>* - (<nt def="NT-Char">Char</nt>*
-('<![' | ']]>') <nt def="NT-Char">Char</nt>*) </rhs>
-</prod>
-</prodgroup></scrap>
-<vcnote id="condsec-nesting" diff="add"><head><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E90">[E90]</loc>Proper
-Conditional Section/PE Nesting</head><p>If any of the "<code><![</code>",
-"<code>[</code>", or "<code>]]></code>" of a conditional section is contained
-in the replacement text for a parameter-entity reference, all of them must
-be contained in the same replacement text.</p>
-</vcnote>
-<p>Like the internal and external DTD subsets, a conditional section may contain
-one or more complete declarations, comments, processing instructions, or nested
-conditional sections, intermingled with white space.</p>
-<p>If the keyword of the conditional section is <kw>INCLUDE</kw>, then the
-contents of the conditional section are part of the DTD. If the keyword of
-the conditional section is <kw>IGNORE</kw>, then the contents of the conditional
-section are not logically part of the DTD. <phrase diff="del"><loc role="erratumref"
-href="http://www.w3.org/XML/xml-19980210-errata#E90">[E90]</loc>Note that
-for reliable parsing, the contents of even ignored conditional sections must
-be read in order to detect nested conditional sections and ensure that the
-end of the outermost (ignored) conditional section is properly detected.</phrase>
-If a conditional section with a keyword of <kw>INCLUDE</kw> occurs within
-a larger conditional section with a keyword of <kw>IGNORE</kw>, both the outer
-and the inner conditional sections are ignored.<phrase diff="add"> <loc role="erratumref"
-href="http://www.w3.org/XML/xml-19980210-errata#E90">[E90]</loc>The contents
-of an ignored conditional section are parsed by ignoring all characters after
-the "<code>[</code>" following the keyword, except conditional section starts
-"<code><![</code>" and ends "<code>]]></code>", until the matching conditional
-section end is found. Parameter entity references are not recognized in this
-process.</phrase></p>
-<p>If the keyword of the conditional section is a parameter-entity reference,
-the parameter entity must be replaced by its content before the processor
-decides whether to include or ignore the conditional section.</p>
-<p>An example:</p>
-<eg><!ENTITY % draft 'INCLUDE' >
-<!ENTITY % final 'IGNORE' >
-
-<![%draft;[
-<!ELEMENT book (comments*, title, body, supplements?)>
-]]>
-<![%final;[
-<!ELEMENT book (title, body, supplements?)>
-]]></eg>
-</div2>
-<!--
-<div2 id='sec-pass-to-app'>
-<head>XML Processor Treatment of Logical Structure</head>
-<p>When an XML processor encounters a start-tag, it must make
-at least the following information available to the application:
-<ulist>
-<item>
-<p>the element type's generic identifier</p>
-</item>
-<item>
-<p>the names of attributes known to apply to this element type
-(validating processors must make available names of all attributes
-declared for the element type; non-validating processors must
-make available at least the names of the attributes for which
-values are specified.
-</p>
-</item>
-</ulist>
-</p>
-</div2>
--->
-</div1>
-<!-- &Entities; -->
-<div1 id="sec-physical-struct">
-<head>Physical Structures</head>
-<p><termdef id="dt-entity" term="Entity">An XML document may consist of one
-or many storage units. <phrase diff="chg"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E6">[E6]</loc>These
-are called <term>entities</term>; they all have <term>content</term> and are
-all (except for the <termref def="dt-docent">document entity</termref> and
-the <termref def="dt-doctype">external DTD subset</termref>) identified by
-entity <term>name</term></phrase>.</termdef> Each XML document has one entity
-called the <termref def="dt-docent">document entity</termref>, which serves
-as the starting point for the <termref def="dt-xml-proc">XML processor</termref>
-and may contain the whole document.</p>
-<p>Entities may be either parsed or unparsed. <termdef id="dt-parsedent" term="Text Entity">A <term>parsed
-entity's</term> contents are referred to as its <termref def="dt-repltext">replacement
-text</termref>; this <termref def="dt-text">text</termref> is considered an
-integral part of the document.</termdef></p>
-<p><termdef id="dt-unparsed" term="Unparsed Entity">An <term>unparsed entity</term>
-is a resource whose contents may or may not be <termref def="dt-text">text</termref>,
-and if text, <phrase diff="chg"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E25">[E25]</loc>may
-be other than</phrase> XML. Each unparsed entity has an associated <termref
-def="dt-notation">notation</termref>, identified by name. Beyond a requirement
-that an XML processor make the identifiers for the entity and notation available
-to the application, XML places no constraints on the contents of unparsed
-entities.</termdef></p>
-<p>Parsed entities are invoked by name using entity references; unparsed entities
-by name, given in the value of <kw>ENTITY</kw> or <kw>ENTITIES</kw> attributes.</p>
-<p><termdef id="gen-entity" term="general entity"><term>General entities</term>
-are entities for use within the document content. In this specification, general
-entities are sometimes referred to with the unqualified term <emph>entity</emph>
-when this leads to no ambiguity.</termdef> <termdef id="dt-PE" term="Parameter entity"><phrase
-diff="chg"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E53">[E53]</loc><term>Parameter
-entities</term></phrase> are parsed entities for use within the DTD.</termdef>
-These two types of entities use different forms of reference and are recognized
-in different contexts. Furthermore, they occupy different namespaces; a parameter
-entity and a general entity with the same name are two distinct entities.</p>
-<div2 id="sec-references">
-<head>Character and Entity References</head>
-<p><termdef id="dt-charref" term="Character Reference"> A <term>character
-reference</term> refers to a specific character in the ISO/IEC 10646 character
-set, for example one not directly accessible from available input devices.</termdef></p>
-<scrap lang="ebnf">
-<head>Character Reference</head>
-<prod id="NT-CharRef">
-<lhs>CharRef</lhs><rhs>'&#' [0-9]+ ';' </rhs>
-<rhs>| '&hcro;' [0-9a-fA-F]+ ';'</rhs><wfc def="wf-Legalchar"/>
-</prod>
-</scrap>
-<wfcnote id="wf-Legalchar"><head>Legal Character</head><p>Characters referred
-to using character references must match the production for <termref def="NT-Char">Char</termref>.</p>
-</wfcnote>
-<p>If the character reference begins with <quote><code>&#x</code></quote>,
-the digits and letters up to the terminating <code>;</code> provide a hexadecimal
-representation of the character's code point in ISO/IEC 10646. If it begins
-just with <quote><code>&#</code></quote>, the digits up to the terminating <code>;</code>
-provide a decimal representation of the character's code point.</p>
-<p><termdef id="dt-entref" term="Entity Reference">An <term>entity reference</term>
-refers to the content of a named entity.</termdef> <termdef id="dt-GERef"
-term="General Entity Reference">References to parsed general entities use
-ampersand (<code>&</code>) and semicolon (<code>;</code>) as delimiters.</termdef> <termdef
-id="dt-PERef" term="Parameter-entity reference"> <term>Parameter-entity references</term>
-use percent-sign (<code>%</code>) and semicolon (<code>;</code>) as delimiters.</termdef></p>
-<scrap lang="ebnf">
-<head>Entity Reference</head>
-<prod id="NT-Reference">
-<lhs>Reference</lhs><rhs><nt def="NT-EntityRef">EntityRef</nt> | <nt def="NT-CharRef">CharRef</nt></rhs>
-</prod>
-<prod id="NT-EntityRef">
-<lhs>EntityRef</lhs><rhs>'&' <nt def="NT-Name">Name</nt> ';'</rhs><wfc
-def="wf-entdeclared"/><vc def="vc-entdeclared"/><wfc def="textent"/><wfc def="norecursion"/>
-</prod>
-<prod id="NT-PEReference">
-<lhs>PEReference</lhs><rhs>'%' <nt def="NT-Name">Name</nt> ';'</rhs><vc def="vc-entdeclared"/>
-<wfc def="norecursion"/><wfc def="indtd"/>
-</prod>
-</scrap>
-<wfcnote id="wf-entdeclared"><head>Entity Declared</head><p>In a document
-without any DTD, a document with only an internal DTD subset which contains
-no parameter entity references, or a document with <quote><code>standalone='yes'</code></quote>, <phrase
-diff="chg"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E34">[E34]</loc>for
-an entity reference that does not occur within the external subset or a parameter
-entity, the <nt def="NT-Name">Name</nt> given in the entity reference must <termref
-def="dt-match">match</termref> that in an <titleref href="#sec-entity-decl">entity
-declaration</titleref> that does not occur within the external subset or a
-parameter entity</phrase>, except that well-formed documents need not declare
-any of the following entities: &magicents;. <phrase diff="del"><loc role="erratumref"
-href="http://www.w3.org/XML/xml-19980210-errata#E29">[E29]</loc>The declaration
-of a parameter entity must precede any reference to it. Similarly, </phrase>The
-declaration of a general entity must precede any reference to it which appears
-in a default value in an attribute-list declaration.</p>
-<p>Note that if entities are declared in the external subset or in external
-parameter entities, a non-validating processor is <titleref href="#include-if-valid">not
-obligated to</titleref> read and process their declarations; for such documents,
-the rule that an entity must be declared is a well-formedness constraint only
-if <titleref href="#sec-rmd">standalone='yes'</titleref>.</p>
-</wfcnote>
-<vcnote id="vc-entdeclared"><head>Entity Declared</head><p>In a document with
-an external subset or external parameter entities with <quote><code>standalone='no'</code></quote>,
-the <nt def="NT-Name">Name</nt> given in the entity reference must <termref
-def="dt-match">match</termref> that in an <titleref href="#sec-entity-decl">entity
-declaration</titleref>. For interoperability, valid documents should declare
-the entities &magicents;, in the form specified in <specref ref="sec-predefined-ent"/>.
-The declaration of a parameter entity must precede any reference to it. Similarly,
-the declaration of a general entity must precede any <phrase diff="chg"><loc
-role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E92">[E92]</loc>attribute-list
-declaration containing a default value with a direct or indirect reference
-to that general entity.</phrase></p>
-</vcnote>
-<!-- FINAL EDIT: is this duplication too clumsy? -->
-<wfcnote id="textent"><head>Parsed Entity</head><p>An entity reference must
-not contain the name of an <termref def="dt-unparsed">unparsed entity</termref>.
-Unparsed entities may be referred to only in <termref def="dt-attrval">attribute
-values</termref> declared to be of type <kw>ENTITY</kw> or <kw>ENTITIES</kw>.</p>
-</wfcnote>
-<wfcnote id="norecursion"><head>No Recursion</head><p>A parsed entity must
-not contain a recursive reference to itself, either directly or indirectly.</p>
-</wfcnote>
-<wfcnote id="indtd"><head>In DTD</head><p>Parameter-entity references may
-only appear in the <termref def="dt-doctype">DTD</termref>.</p>
-</wfcnote>
-<p>Examples of character and entity references:</p>
-<eg>Type <key>less-than</key> (&hcro;3C;) to save options.
-This document was prepared on &docdate; and
-is classified &security-level;.</eg>
-<p>Example of a parameter-entity reference:</p>
-<eg><![CDATA[<!-- declare the parameter entity "ISOLat2"... -->
-<!ENTITY % ISOLat2
-         SYSTEM "http://www.xml.com/iso/isolat2-xml.entities" >
-<!-- ... now reference it. -->
-%ISOLat2;]]></eg>
-</div2>
-<div2 id="sec-entity-decl">
-<head>Entity Declarations</head>
-<p><termdef id="dt-entdecl" term="entity declaration"> Entities are declared
-thus:</termdef></p>
-<scrap lang="ebnf">
-<head>Entity Declaration</head>
-<prodgroup pcw2="5" pcw4="18.5">
-<prod id="NT-EntityDecl">
-<lhs>EntityDecl</lhs><rhs><nt def="NT-GEDecl">GEDecl</nt><!--</rhs><com>General entities</com>
-<rhs>--> | <nt def="NT-PEDecl">PEDecl</nt></rhs>
-<!--<com>Parameter entities</com>-->
-</prod>
-<prod id="NT-GEDecl">
-<lhs>GEDecl</lhs><rhs>'<!ENTITY' <nt def="NT-S">S</nt> <nt def="NT-Name">Name</nt> <nt
-def="NT-S">S</nt> <nt def="NT-EntityDef">EntityDef</nt> <nt def="NT-S">S</nt>?
-'>'</rhs>
-</prod>
-<prod id="NT-PEDecl">
-<lhs>PEDecl</lhs><rhs>'<!ENTITY' <nt def="NT-S">S</nt> '%' <nt def="NT-S">S</nt> <nt
-def="NT-Name">Name</nt> <nt def="NT-S">S</nt> <nt def="NT-PEDef">PEDef</nt> <nt
-def="NT-S">S</nt>? '>'</rhs>
-<!--<com>Parameter entities</com>-->
-</prod>
-<prod id="NT-EntityDef">
-<lhs>EntityDef</lhs><rhs><nt def="NT-EntityValue">EntityValue</nt> <!--</rhs>
-<rhs>-->| (<nt def="NT-ExternalID">ExternalID</nt> <nt def="NT-NDataDecl">NDataDecl</nt>?)</rhs>
-<!-- <nt def='NT-ExternalDef'>ExternalDef</nt></rhs> -->
-</prod>
-<!-- FINAL EDIT: what happened to WFs here? -->
-<prod id="NT-PEDef">
-<lhs>PEDef</lhs><rhs><nt def="NT-EntityValue">EntityValue</nt> | <nt def="NT-ExternalID">ExternalID</nt></rhs>
-</prod>
-</prodgroup></scrap>
-<p>The <nt def="NT-Name">Name</nt> identifies the entity in an <termref def="dt-entref">entity
-reference</termref> or, in the case of an unparsed entity, in the value of
-an <kw>ENTITY</kw> or <kw>ENTITIES</kw> attribute. If the same entity is declared
-more than once, the first declaration encountered is binding; at user option,
-an XML processor may issue a warning if entities are declared multiple times.</p>
-<div3 id="sec-internal-ent">
-<head>Internal Entities</head>
-<p><termdef id="dt-internent" term="Internal Entity Replacement Text">If the
-entity definition is an <nt def="NT-EntityValue">EntityValue</nt>, the defined
-entity is called an <term>internal entity</term>. There is no separate physical
-storage object, and the content of the entity is given in the declaration.</termdef>
-Note that some processing of entity and character references in the <termref
-def="dt-litentval">literal entity value</termref> may be required to produce
-the correct <termref def="dt-repltext">replacement text</termref>: see <specref
-ref="intern-replacement"/>.</p>
-<p>An internal entity is a <termref def="dt-parsedent">parsed entity</termref>.</p>
-<p>Example of an internal entity declaration:</p>
-<eg><!ENTITY Pub-Status "This is a pre-release of the
- specification."></eg>
-</div3>
-<div3 id="sec-external-ent">
-<head>External Entities</head>
-<p><termdef id="dt-extent" term="External Entity">If the entity is not internal,
-it is an <term>external entity</term>, declared as follows:</termdef></p>
-<scrap lang="ebnf">
-<head>External Entity Declaration</head>
-<!--
-<prod id='NT-ExternalDef'><lhs>ExternalDef</lhs>
-<rhs></prod> -->
-<prod id="NT-ExternalID">
-<lhs>ExternalID</lhs><rhs>'SYSTEM' <nt def="NT-S">S</nt> <nt def="NT-SystemLiteral">SystemLiteral</nt></rhs>
-<rhs>| 'PUBLIC' <nt def="NT-S">S</nt> <nt def="NT-PubidLiteral">PubidLiteral</nt> <nt
-def="NT-S">S</nt> <nt def="NT-SystemLiteral">SystemLiteral</nt> </rhs>
-</prod>
-<prod id="NT-NDataDecl">
-<lhs>NDataDecl</lhs><rhs><nt def="NT-S">S</nt> 'NDATA' <nt def="NT-S">S</nt> <nt
-def="NT-Name">Name</nt></rhs><vc def="not-declared"/>
-</prod>
-</scrap>
-<p>If the <nt def="NT-NDataDecl">NDataDecl</nt> is present, this is a general <termref
-def="dt-unparsed">unparsed entity</termref>; otherwise it is a parsed entity.</p>
-<vcnote id="not-declared"><head>Notation Declared</head><p>The <nt def="NT-Name">Name</nt>
-must match the declared name of a <termref def="dt-notation">notation</termref>.</p>
-</vcnote>
-<p><phrase diff="chg"><termdef id="dt-sysid" term="System Identifier">The <nt
-def="NT-SystemLiteral">SystemLiteral</nt> is called the entity's <term>system
-identifier</term>. It is a <phrase diff="chg"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E88">[E88]</loc>URI
-reference</phrase><phrase diff="add"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E66">[E66]</loc>
-(as defined in <bibref ref="rfc2396"/>, updated by <bibref ref="rfc2732"/>)</phrase>, <loc
-role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E76">[E76]</loc>meant
-to be dereferenced to obtain input for the XML processor to construct the
-entity's replacement text.</termdef> It is an error for a fragment identifier
-(beginning with a <code>#</code> character) to be part of a system identifier.</phrase>
-Unless otherwise provided by information outside the scope of this specification
-(e.g. a special XML element type defined by a particular DTD, or a processing
-instruction defined by a particular application specification), relative URIs
-are relative to the location of the resource within which the entity declaration
-occurs. A URI might thus be relative to the <termref def="dt-docent">document
-entity</termref>, to the entity containing the <termref def="dt-doctype">external
-DTD subset</termref>, or to some other <termref def="dt-extent">external parameter
-entity</termref>.</p>
-<p diff="chg"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E78">[E78]</loc>URI
-references require encoding and escaping of certain characters. The disallowed
-characters include all non-ASCII characters, plus the excluded characters
-listed in Section 2.4 of <bibref ref="rfc2396"/>, except for the number sign
-(<code>#</code>) and percent sign (<code>%</code>) characters and the square
-bracket characters re-allowed in <bibref ref="rfc2732"/>. Disallowed characters
-must be escaped as follows:</p>
-<olist diff="add">
-<item><p>Each disallowed character is converted to UTF-8 <bibref ref="rfc2279"/>
-as one or more bytes.</p></item>
-<item><p>Any octets corresponding to a disallowed character are escaped with
-the URI escaping mechanism (that is, converted to <code>%</code><var>HH</var>,
-where HH is the hexadecimal notation of the byte value).</p></item>
-<item><p>The original character is replaced by the resulting character sequence.</p>
-</item>
-</olist>
-<p><termdef id="dt-pubid" term="Public identifier"> In addition to a system
-identifier, an external identifier may include a <term>public identifier</term>.</termdef>
-An XML processor attempting to retrieve the entity's content may use the public
-identifier to try to generate an alternative <phrase diff="chg"><loc role="erratumref"
-href="http://www.w3.org/XML/xml-19980210-errata#E88">[E88]</loc>URI reference</phrase>.
-If the processor is unable to do so, it must use the <phrase diff="chg"><loc
-role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E88">[E88]</loc>URI
-reference</phrase> specified in the system literal. Before a match is attempted,
-all strings of white space in the public identifier must be normalized to
-single space characters (#x20), and leading and trailing white space must
-be removed.</p>
-<p>Examples of external entity declarations:</p>
-<eg><!ENTITY open-hatch
-         SYSTEM "http://www.textuality.com/boilerplate/OpenHatch.xml">
-<!ENTITY open-hatch
-         PUBLIC "-//Textuality//TEXT Standard open-hatch boilerplate//EN"
-         "http://www.textuality.com/boilerplate/OpenHatch.xml">
-<!ENTITY hatch-pic
-         SYSTEM "../grafix/OpenHatch.gif"
-         NDATA gif ></eg>
-</div3>
-</div2>
-<div2 id="TextEntities">
-<head>Parsed Entities</head>
-<div3 id="sec-TextDecl">
-<head>The Text Declaration</head>
-<p>External parsed entities <phrase diff="chg"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E107">[E107]</loc>should</phrase
-> each begin with a <term>text declaration</term>.</p>
-<scrap lang="ebnf">
-<head>Text Declaration</head>
-<prodgroup pcw4="12.5" pcw5="13">
-<prod id="NT-TextDecl">
-<lhs>TextDecl</lhs><rhs>&pio; <nt def="NT-VersionInfo">VersionInfo</nt>? <nt
-def="NT-EncodingDecl">EncodingDecl</nt> <nt def="NT-S">S</nt>? &pic;</rhs>
-</prod>
-</prodgroup></scrap>
-<p>The text declaration must be provided literally, not by reference to a
-parsed entity. No text declaration may appear at any position other than the
-beginning of an external parsed entity. <phrase diff="add"><loc role="erratumref"
-href="http://www.w3.org/XML/xml-19980210-errata#E94">[E94]</loc>The text declaration
-in an external parsed entity is not considered part of its <termref def="dt-repltext">replacement
-text</termref>.</phrase></p>
-</div3>
-<div3 id="wf-entities">
-<head>Well-Formed Parsed Entities</head>
-<p>The document entity is well-formed if it matches the production labeled <nt
-def="NT-document">document</nt>. An external general parsed entity is well-formed
-if it matches the production labeled <nt def="NT-extParsedEnt">extParsedEnt</nt>. <phrase
-diff="chg"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E109">[E109]</loc>All
-external parameter entities are well-formed by definition.</phrase></p>
-<scrap lang="ebnf">
-<head>Well-Formed External Parsed Entity</head>
-<prod id="NT-extParsedEnt">
-<lhs>extParsedEnt</lhs><rhs><nt def="NT-TextDecl">TextDecl</nt>? <nt def="NT-content">content</nt></rhs>
-</prod>
-<prod id="NT-extPE" diff="del">
-<lhs>extPE</lhs><rhs><nt def="NT-TextDecl">TextDecl</nt>? <nt def="NT-extSubsetDecl">extSubsetDecl</nt></rhs>
-<com><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E109">[E109]</loc></com>
-</prod>
-</scrap>
-<p>An internal general parsed entity is well-formed if its replacement text
-matches the production labeled <nt def="NT-content">content</nt>. All internal
-parameter entities are well-formed by definition.</p>
-<p>A consequence of well-formedness in entities is that the logical and physical
-structures in an XML document are properly nested; no <termref def="dt-stag">start-tag</termref>, <termref
-def="dt-etag">end-tag</termref>, <termref def="dt-empty">empty-element tag</termref>, <termref
-def="dt-element">element</termref>, <termref def="dt-comment">comment</termref>, <termref
-def="dt-pi">processing instruction</termref>, <termref def="dt-charref">character
-reference</termref>, or <termref def="dt-entref">entity reference</termref>
-can begin in one entity and end in another.</p>
-</div3>
-<div3 id="charencoding">
-<head>Character Encoding in Entities</head>
-<p>Each external parsed entity in an XML document may use a different encoding
-for its characters. All XML processors must be able to read entities in <phrase
-diff="chg"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E56">[E56]</loc>both
-the UTF-8 and UTF-16 encodings.</phrase> <phrase diff="add"><loc role="erratumref"
-href="http://www.w3.org/XML/xml-19980210-errata#E77">[E77]</loc>The terms <quote>UTF-8</quote>
-and <quote>UTF-16</quote> in this specification do not apply to character
-encodings with any other labels, even if the encodings or labels are very
-similar to UTF-8 or UTF-16.</phrase></p>
-<p>Entities encoded in UTF-16 must begin with the Byte Order Mark described
-by <phrase diff="chg"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E67">[E67]</loc>Annex
-F of <bibref ref="ISO10646"/>, Annex H of <bibref ref="ISO10646-2000"/>, section
-2.4 of <bibref ref="Unicode"/>, and section 2.7 of <bibref ref="Unicode3"/></phrase>
-(the ZERO WIDTH NO-BREAK SPACE character, #xFEFF). This is an encoding signature,
-not part of either the markup or the character data of the XML document. XML
-processors must be able to use this character to differentiate between UTF-8
-and UTF-16 encoded documents.</p>
-<p>Although an XML processor is required to read only entities in the UTF-8
-and UTF-16 encodings, it is recognized that other encodings are used around
-the world, and it may be desired for XML processors to read entities that
-use them. <phrase diff="add"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E47">[E47]</loc>In
-the absence of external character encoding information (such as MIME headers),</phrase>
-parsed entities which are stored in an encoding other than UTF-8 or UTF-16
-must begin with a text declaration <phrase diff="add">(see <specref ref="sec-TextDecl"/>) </phrase>containing
-an encoding declaration:</p>
-<scrap lang="ebnf">
-<head>Encoding Declaration</head>
-<prod id="NT-EncodingDecl">
-<lhs>EncodingDecl</lhs><rhs><nt def="NT-S">S</nt> 'encoding' <nt def="NT-Eq">Eq</nt>
-('"' <nt def="NT-EncName">EncName</nt> '"' | "'" <nt def="NT-EncName">EncName</nt>
-"'" ) </rhs>
-</prod>
-<prod id="NT-EncName">
-<lhs>EncName</lhs><rhs>[A-Za-z] ([A-Za-z0-9._] | '-')*</rhs><com>Encoding
-name contains only Latin characters</com>
-</prod>
-</scrap>
-<p>In the <termref def="dt-docent">document entity</termref>, the encoding
-declaration is part of the <termref def="dt-xmldecl">XML declaration</termref>.
-The <nt def="NT-EncName">EncName</nt> is the name of the encoding used.</p>
-<!-- FINAL EDIT: check name of IANA and charset names -->
-<p>In an encoding declaration, the values <quote><code>UTF-8</code></quote>, <quote><code>UTF-16</code></quote>, <quote><code>ISO-10646-UCS-2</code
-></quote>, and <quote><code>ISO-10646-UCS-4</code></quote> should be used
-for the various encodings and transformations of Unicode / ISO/IEC 10646,
-the values <quote><code>ISO-8859-1</code></quote>, <quote><code>ISO-8859-2</code></quote>,
-... <loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E106">[E106]</loc><phrase
-diff="chg"><quote><code>ISO-8859-</code><var>n</var></quote> (where <var>n</var>
-is the part number)</phrase> should be used for the parts of ISO 8859, and
-the values <quote><code>ISO-2022-JP</code></quote>, <quote><code>Shift_JIS</code></quote>,
-and <quote><code>EUC-JP</code></quote> should be used for the various encoded
-forms of JIS X-0208-1997. <phrase diff="chg"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E57">[E57]</loc>It
-is recommended that character encodings registered (as <emph>charset</emph>s)
-with the Internet Assigned Numbers Authority <phrase diff="chg"><loc role="erratumref"
-href="http://www.w3.org/XML/xml-19980210-errata#E58">[E58]</loc><bibref ref="IANA"/></phrase>,
-other than those just listed, be referred to using their registered names;
-other encodings should use names starting with an <quote>x-</quote> prefix.
-XML processors should match character encoding names in a case-insensitive
-way and should either interpret an IANA-registered name as the encoding registered
-at IANA for that name or treat it as unknown (processors are, of course, not
-required to support all IANA-registered encodings).</phrase></p>
-<p>In the absence of information provided by an external transport protocol
-(e.g. HTTP or MIME), it is an <termref def="dt-error">error</termref> for
-an entity including an encoding declaration to be presented to the XML processor
-in an encoding other than that named in the declaration, <phrase diff="del"><loc
-role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E5">[E5]</loc>for
-an encoding declaration to occur other than at the beginning of an external
-entity, </phrase>or for an entity which begins with neither a Byte Order Mark
-nor an encoding declaration to use an encoding other than UTF-8. Note that
-since ASCII is a subset of UTF-8, ordinary ASCII entities do not strictly
-need an encoding declaration.</p>
-<p diff="add"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E5">[E5]</loc>It
-is <phrase diff="chg"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E36">[E36]</loc>a
-fatal</phrase> error for a <nt def="NT-TextDecl">TextDecl</nt> to occur other
-than at the beginning of an external entity.</p>
-<p>It is a <termref def="dt-fatal">fatal error</termref> when an XML processor
-encounters an entity with an encoding that it is unable to process. <phrase
-diff="add"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E79">[E79]</loc>It
-is a fatal error if an XML entity is determined (via default, encoding declaration,
-or higher-level protocol) to be in a certain encoding but contains octet sequences
-that are not legal in that encoding. It is also a fatal error if an XML entity
-contains no encoding declaration and its content is not legal UTF-8 or UTF-16.</phrase></p>
-<p>Examples of <phrase diff="add"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E23">[E23]</loc>text
-declarations containing </phrase>encoding declarations:</p>
-<eg><?xml encoding='UTF-8'?>
-<?xml encoding='EUC-JP'?></eg>
-</div3>
-</div2>
-<div2 id="entproc">
-<head>XML Processor Treatment of Entities and References</head>
-<p>The table below summarizes the contexts in which character references,
-entity references, and invocations of unparsed entities might appear and the
-required behavior of an <termref def="dt-xml-proc">XML processor</termref>
-in each case. The labels in the leftmost column describe the recognition context: <glist>
-<gitem><label>Reference in Content</label>
-<def>
-<p>as a reference anywhere after the <termref def="dt-stag">start-tag</termref>
-and before the <termref def="dt-etag">end-tag</termref> of an element; corresponds
-to the nonterminal <nt def="NT-content">content</nt>.</p>
-</def></gitem>
-<gitem><label>Reference in Attribute Value</label>
-<def>
-<p>as a reference within either the value of an attribute in a <termref def="dt-stag">start-tag</termref>,
-or a default value in an <termref def="dt-attdecl">attribute declaration</termref>;
-corresponds to the nonterminal <nt def="NT-AttValue">AttValue</nt>.</p>
-</def></gitem>
-<gitem><label>Occurs as Attribute Value</label>
-<def>
-<p>as a <nt def="NT-Name">Name</nt>, not a reference, appearing either as
-the value of an attribute which has been declared as type <kw>ENTITY</kw>,
-or as one of the space-separated tokens in the value of an attribute which
-has been declared as type <kw>ENTITIES</kw>.</p>
-</def></gitem>
-<gitem><label>Reference in Entity Value</label>
-<def>
-<p>as a reference within a parameter or internal entity's <termref def="dt-litentval">literal
-entity value</termref> in the entity's declaration; corresponds to the nonterminal <nt
-def="NT-EntityValue">EntityValue</nt>.</p>
-</def></gitem>
-<gitem><label>Reference in DTD</label>
-<def>
-<p diff="chg"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E90">[E90]</loc>as
-a reference within either the internal or external subsets of the <termref
-def="dt-doctype">DTD</termref>, but outside of an <nt def="NT-EntityValue">EntityValue</nt>, <nt
-def="NT-AttValue">AttValue</nt>, <nt def="NT-PI">PI</nt>, <nt def="NT-Comment">Comment</nt>, <nt
-def="NT-SystemLiteral">SystemLiteral</nt>, <nt def="NT-PubidLiteral">PubidLiteral</nt>,
-or the contents of an ignored conditional section (see <specref ref="sec-condition-sect"/>).</p>
-<p>.</p>
-</def></gitem>
-</glist></p>
-<table border="1" frame="border" cellpadding="7"><tbody align="center"><tr>
-<td rowspan="2" colspan="1"></td><td colspan="4" align="center" valign="bottom">Entity
-Type</td><td rowspan="2" align="center">Character</td></tr><tr align="center"
-valign="bottom"><td>Parameter</td><td>Internal General</td><td>External Parsed
-General</td><td>Unparsed</td></tr><tr align="center" valign="middle"><td align="right">Reference
-in Content</td><td><titleref href="#not-recognized">Not recognized</titleref></td>
-<td><titleref href="#included">Included</titleref></td><td><titleref href="#include-if-valid">Included
-if validating</titleref></td><td><titleref href="#forbidden">Forbidden</titleref></td>
-<td><titleref href="#included">Included</titleref></td></tr><tr align="center"
-valign="middle"><td align="right">Reference in Attribute Value</td><td><titleref
-href="#not-recognized">Not recognized</titleref></td><td><titleref href="#inliteral">Included
-in literal</titleref></td><td><titleref href="#forbidden">Forbidden</titleref></td>
-<td><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E51">[E51]</loc><titleref
-diff="chg" href="#forbidden">Forbidden</titleref></td><td><titleref href="#included">Included</titleref></td>
-</tr><tr align="center" valign="middle"><td align="right">Occurs as Attribute
-Value</td><td><titleref href="#not-recognized">Not recognized</titleref></td>
-<td><titleref href="#forbidden">Forbidden</titleref></td><td><loc role="erratumref"
-href="http://www.w3.org/XML/xml-19980210-errata#E51">[E51]</loc><titleref
-diff="chg" href="#forbidden">Forbidden</titleref></td><td><titleref href="#notify">Notify</titleref></td>
-<td><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E51">[E51]</loc><titleref
-diff="chg" href="#not-recognized">Not recognized</titleref></td></tr><tr align="center"
-valign="middle"><td align="right">Reference in EntityValue</td><td><titleref
-href="#inliteral">Included in literal</titleref></td><td><titleref href="#bypass">Bypassed</titleref></td>
-<td><titleref href="#bypass">Bypassed</titleref></td><td><titleref href="#forbidden">Forbidden</titleref></td>
-<td><titleref href="#included">Included</titleref></td></tr><tr align="center"
-valign="middle"><td align="right">Reference in DTD</td><td><titleref href="#as-PE">Included
-as PE</titleref></td><td><titleref href="#forbidden">Forbidden</titleref></td>
-<td><titleref href="#forbidden">Forbidden</titleref></td><td><titleref href="#forbidden">Forbidden</titleref></td>
-<td><titleref href="#forbidden">Forbidden</titleref></td></tr></tbody></table>
-<div3 id="not-recognized">
-<head>Not Recognized</head>
-<p>Outside the DTD, the <code>%</code> character has no special significance;
-thus, what would be parameter entity references in the DTD are not recognized
-as markup in <nt def="NT-content">content</nt>. Similarly, the names of unparsed
-entities are not recognized except when they appear in the value of an appropriately
-declared attribute.</p>
-</div3>
-<div3 id="included">
-<head>Included</head>
-<p><termdef id="dt-include" term="Include">An entity is <term>included</term>
-when its <termref def="dt-repltext">replacement text</termref> is retrieved
-and processed, in place of the reference itself, as though it were part of
-the document at the location the reference was recognized.</termdef> The replacement
-text may contain both <termref def="dt-chardata">character data</termref>
-and (except for parameter entities) <termref def="dt-markup">markup</termref>,
-which must be recognized in the usual way<phrase diff="del"><loc role="erratumref"
-href="http://www.w3.org/XML/xml-19980210-errata#E65">[E65]</loc>, except that
-the replacement text of entities used to escape markup delimiters (the entities &magicents;)
-is always treated as data</phrase>. (The string <quote><code>AT&amp;T;</code></quote>
-expands to <quote><code>AT&T;</code></quote> and the remaining ampersand
-is not recognized as an entity-reference delimiter.) A character reference
-is <term>included</term> when the indicated character is processed in place
-of the reference itself. </p>
-</div3>
-<div3 id="include-if-valid">
-<head>Included If Validating</head>
-<p>When an XML processor recognizes a reference to a parsed entity, in order
-to <termref def="dt-valid">validate</termref> the document, the processor
-must <termref def="dt-include">include</termref> its replacement text. If
-the entity is external, and the processor is not attempting to validate the
-XML document, the processor <termref def="dt-may">may</termref>, but need
-not, include the entity's replacement text. If a non-validating <phrase diff="chg"><loc
-role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E95">[E95]</loc>processor</phrase>
-does not include the replacement text, it must inform the application that
-it recognized, but did not read, the entity.</p>
-<p>This rule is based on the recognition that the automatic inclusion provided
-by the SGML and XML entity mechanism, primarily designed to support modularity
-in authoring, is not necessarily appropriate for other applications, in particular
-document browsing. Browsers, for example, when encountering an external parsed
-entity reference, might choose to provide a visual indication of the entity's
-presence and retrieve it for display only on demand.</p>
-</div3>
-<div3 id="forbidden">
-<head>Forbidden</head>
-<p>The following are forbidden, and constitute <termref def="dt-fatal">fatal</termref>
-errors:</p>
-<ulist>
-<item><p>the appearance of a reference to an <termref def="dt-unparsed">unparsed
-entity</termref>.</p></item>
-<item><p>the appearance of any character or general-entity reference in the
-DTD except within an <nt def="NT-EntityValue">EntityValue</nt> or <nt def="NT-AttValue">AttValue</nt>.</p>
-</item>
-<item><p>a reference to an external entity in an attribute value.</p></item>
-</ulist>
-</div3>
-<div3 id="inliteral">
-<head>Included in Literal</head>
-<p>When an <termref def="dt-entref">entity reference</termref> appears in
-an attribute value, or a parameter entity reference appears in a literal entity
-value, its <termref def="dt-repltext">replacement text</termref> is processed
-in place of the reference itself as though it were part of the document at
-the location the reference was recognized, except that a single or double
-quote character in the replacement text is always treated as a normal data
-character and will not terminate the literal. For example, this is well-formed:</p>
-<eg diff="chg"><!-- <loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E4">[E4]</loc> -->
-<![CDATA[<!ENTITY % YN '"Yes"' >
-<!ENTITY WhatHeSaid "He said %YN;" >]]></eg>
-<p>while this is not:</p>
-<eg><!ENTITY EndAttr "27'" >
-<element attribute='a-&EndAttr;></eg>
-</div3>
-<div3 id="notify">
-<head>Notify</head>
-<p>When the name of an <termref def="dt-unparsed">unparsed entity</termref>
-appears as a token in the value of an attribute of declared type <kw>ENTITY</kw>
-or <kw>ENTITIES</kw>, a validating processor must inform the application of
-the <termref def="dt-sysid">system</termref> and <termref def="dt-pubid">public</termref>
-(if any) identifiers for both the entity and its associated <termref def="dt-notation">notation</termref>.</p>
-</div3>
-<div3 id="bypass">
-<head>Bypassed</head>
-<p>When a general entity reference appears in the <nt def="NT-EntityValue">EntityValue</nt>
-in an entity declaration, it is bypassed and left as is.</p>
-</div3>
-<div3 id="as-PE">
-<head>Included as PE</head>
-<p>Just as with external parsed entities, parameter entities need only be <titleref
-href="#include-if-valid">included if validating</titleref>. When a parameter-entity
-reference is recognized in the DTD and included, its <termref def="dt-repltext">replacement
-text</termref> is enlarged by the attachment of one leading and one following
-space (#x20) character; the intent is to constrain the replacement text of
-parameter entities to contain an integral number of grammatical tokens in
-the DTD. <phrase diff="add"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E96">[E96]</loc>This
-behavior does not apply to parameter entity references within entity values;
-these are described in <specref ref="inliteral"/>.</phrase></p>
-</div3>
-</div2>
-<div2 id="intern-replacement">
-<head>Construction of Internal Entity Replacement Text</head>
-<p>In discussing the treatment of internal entities, it is useful to distinguish
-two forms of the entity's value. <termdef id="dt-litentval" term="Literal Entity Value">The <term>literal
-entity value</term> is the quoted string actually present in the entity declaration,
-corresponding to the non-terminal <nt def="NT-EntityValue">EntityValue</nt>.</termdef> <termdef
-id="dt-repltext" term="Replacement Text">The <term>replacement text</term>
-is the content of the entity, after replacement of character references and
-parameter-entity references.</termdef></p>
-<p>The literal entity value as given in an internal entity declaration (<nt
-def="NT-EntityValue">EntityValue</nt>) may contain character, parameter-entity,
-and general-entity references. Such references must be contained entirely
-within the literal entity value. The actual replacement text that is <termref
-def="dt-include">included</termref> as described above must contain the <emph>replacement
-text</emph> of any parameter entities referred to, and must contain the character
-referred to, in place of any character references in the literal entity value;
-however, general-entity references must be left as-is, unexpanded. For example,
-given the following declarations:</p>
-<eg><![CDATA[<!ENTITY % pub    "&#xc9;ditions Gallimard" >
-<!ENTITY   rights "All rights reserved" >
-<!ENTITY   book   "La Peste: Albert Camus,
-&#xA9; 1947 %pub;. &rights;" >]]></eg>
-<p>then the replacement text for the entity <quote><code>book</code></quote>
-is:</p>
-<eg>La Peste: Albert Camus,
-© 1947 Éditions Gallimard. &rights;</eg>
-<p>The general-entity reference <quote><code>&rights;</code></quote> would
-be expanded should the reference <quote><code>&book;</code></quote> appear
-in the document's content or an attribute value.</p>
-<p>These simple rules may have complex interactions; for a detailed discussion
-of a difficult example, see <specref ref="sec-entexpand"/>.</p>
-</div2>
-<div2 id="sec-predefined-ent">
-<head>Predefined Entities</head>
-<p><termdef id="dt-escape" term="escape">Entity and character references can
-both be used to <term>escape</term> the left angle bracket, ampersand, and
-other delimiters. A set of general entities (&magicents;) is specified for
-this purpose. Numeric character references may also be used; they are expanded
-immediately when recognized and must be treated as character data, so the
-numeric character references <quote><code>&#60;</code></quote> and <quote><code>&#38;</code></quote>
-may be used to escape <code><</code> and <code>&</code> when they occur
-in character data.</termdef></p>
-<p>All XML processors must recognize these entities whether they are declared
-or not. <termref def="dt-interop">For interoperability</termref>, valid XML
-documents should declare these entities, like any others, before using them. <phrase
-diff="chg"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E80">[E80]</loc>If
-the entities <code>lt</code> or <code>amp</code> are declared, they must be
-declared as internal entities whose replacement text is a character reference
-to the <phrase diff="chg"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E103">[E103]</loc>respective
-character (less-than sign or ampersand)</phrase> being escaped; the double
-escaping is required for these entities so that references to them produce
-a well-formed result. If the entities <code>gt</code>, <code>apos</code>,
-or <code>quot</code> are declared, they must be declared as internal entities
-whose replacement text is the single character being escaped (or a character
-reference to that character; the double escaping here is unnecessary but harmless).
-For example:</phrase></p>
-<eg><![CDATA[<!ENTITY lt     "&#60;">
-<!ENTITY gt     ">">
-<!ENTITY amp    "&#38;">
-<!ENTITY apos   "'">
-<!ENTITY quot   """>]]></eg>
-<p diff="del">Note that the <code><</code> and <code>&</code> characters
-in the declarations of <quote><code>lt</code></quote> and <quote><code>amp</code></quote>
-are doubly escaped to meet the requirement that entity replacement be well-formed.</p>
-</div2>
-<div2 id="Notations">
-<head>Notation Declarations</head>
-<p><termdef id="dt-notation" term="Notation"><term>Notations</term> identify
-by name the format of <termref def="dt-extent">unparsed entities</termref>,
-the format of elements which bear a notation attribute, or the application
-to which a <termref def="dt-pi">processing instruction</termref> is addressed.</termdef></p>
-<p><termdef id="dt-notdecl" term="Notation Declaration"> <term>Notation declarations</term>
-provide a name for the notation, for use in entity and attribute-list declarations
-and in attribute specifications, and an external identifier for the notation
-which may allow an XML processor or its client application to locate a helper
-application capable of processing data in the given notation.</termdef></p>
-<scrap lang="ebnf">
-<head>Notation Declarations</head>
-<prod id="NT-NotationDecl">
-<lhs>NotationDecl</lhs><rhs>'<!NOTATION' <nt def="NT-S">S</nt> <nt def="NT-Name">Name</nt> <nt
-def="NT-S">S</nt> (<nt def="NT-ExternalID">ExternalID</nt> | <nt def="NT-PublicID">PublicID</nt>) <nt
-def="NT-S">S</nt>? '>'</rhs><vc def="UniqueNotationName" diff="add"/>
-</prod>
-<prod id="NT-PublicID">
-<lhs>PublicID</lhs><rhs>'PUBLIC' <nt def="NT-S">S</nt> <nt def="NT-PubidLiteral">PubidLiteral</nt> </rhs>
-</prod>
-</scrap>
-<vcnote id="UniqueNotationName" diff="add"><head><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E22">[E22]</loc>Unique
-Notation Name</head><p>Only one notation declaration can declare a given <nt
-def="NT-Name">Name</nt>.</p>
-</vcnote>
-<p>XML processors must provide applications with the name and external identifier(s)
-of any notation declared and referred to in an attribute value, attribute
-definition, or entity declaration. They may additionally resolve the external
-identifier into the <termref def="dt-sysid">system identifier</termref>, file
-name, or other information needed to allow the application to call a processor
-for data in the notation described. (It is not an error, however, for XML
-documents to declare and refer to notations for which notation-specific applications
-are not available on the system where the XML processor or application is
-running.)</p>
-</div2>
-<div2 id="sec-doc-entity">
-<head>Document Entity</head>
-<p><termdef id="dt-docent" term="Document Entity">The <term>document entity</term>
-serves as the root of the entity tree and a starting-point for an <termref
-def="dt-xml-proc">XML processor</termref>.</termdef> This specification does
-not specify how the document entity is to be located by an XML processor;
-unlike other entities, the document entity has no name and might well appear
-on a processor input stream without any identification at all.</p>
-</div2>
-</div1>
-<!-- &Conformance; -->
-<div1 id="sec-conformance">
-<head>Conformance</head>
-<div2 id="proc-types">
-<head>Validating and Non-Validating Processors</head>
-<p>Conforming <termref def="dt-xml-proc">XML processors</termref> fall into
-two classes: validating and non-validating.</p>
-<p>Validating and non-validating processors alike must report violations of
-this specification's well-formedness constraints in the content of the <termref
-def="dt-docent">document entity</termref> and any other <termref def="dt-parsedent">parsed
-entities</termref> that they read.</p>
-<p><termdef id="dt-validating" term="Validating Processor"><term>Validating
-processors</term> must<phrase diff="add"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E21">[E21]</loc>,
-at user option,</phrase> report violations of the constraints expressed by
-the declarations in the <termref def="dt-doctype">DTD</termref>, and failures
-to fulfill the validity constraints given in this specification.</termdef>
-To accomplish this, validating XML processors must read and process the entire
-DTD and all external parsed entities referenced in the document.</p>
-<p>Non-validating processors are required to check only the <termref def="dt-docent">document
-entity</termref>, including the entire internal DTD subset, for well-formedness. <termdef
-id="dt-use-mdecl" term="Process Declarations"> While they are not required
-to check the document for validity, they are required to <term>process</term>
-all the declarations they read in the internal DTD subset and in any parameter
-entity that they read, up to the first reference to a parameter entity that
-they do <emph>not</emph> read; that is to say, they must use the information
-in those declarations to <titleref href="#AVNormalize">normalize</titleref>
-attribute values, <titleref href="#included">include</titleref> the replacement
-text of internal entities, and supply <titleref href="#sec-attr-defaults">default
-attribute values</titleref>.</termdef> <phrase diff="add"><loc role="erratumref"
-href="http://www.w3.org/XML/xml-19980210-errata#E33">[E33]</loc>Except when <code>standalone="yes"</code>, </phrase>they
-must not <termref def="dt-use-mdecl">process</termref> <termref def="dt-entdecl">entity
-declarations</termref> or <termref def="dt-attdecl">attribute-list declarations</termref>
-encountered after a reference to a parameter entity that is not read, since
-the entity may have contained overriding declarations.</p>
-</div2>
-<div2 id="safe-behavior">
-<head>Using XML Processors</head>
-<p>The behavior of a validating XML processor is highly predictable; it must
-read every piece of a document and report all well-formedness and validity
-violations. Less is required of a non-validating processor; it need not read
-any part of the document other than the document entity. This has two effects
-that may be important to users of XML processors:</p>
-<ulist>
-<item><p>Certain well-formedness errors, specifically those that require reading
-external entities, may not be detected by a non-validating processor. Examples
-include the constraints entitled <titleref href="#wf-entdeclared">Entity Declared</titleref>, <titleref
-href="#textent">Parsed Entity</titleref>, and <titleref href="#norecursion">No
-Recursion</titleref>, as well as some of the cases described as <titleref
-href="#forbidden">forbidden</titleref> in <specref ref="entproc"/>.</p></item>
-<item><p>The information passed from the processor to the application may
-vary, depending on whether the processor reads parameter and external entities.
-For example, a non-validating processor may not <titleref href="#AVNormalize">normalize</titleref>
-attribute values, <titleref href="#included">include</titleref> the replacement
-text of internal entities, or supply <titleref href="#sec-attr-defaults">default
-attribute values</titleref>, where doing so depends on having read declarations
-in external or parameter entities.</p></item>
-</ulist>
-<p>For maximum reliability in interoperating between different XML processors,
-applications which use non-validating processors should not rely on any behaviors
-not required of such processors. Applications which require facilities such
-as the use of default attributes or internal entities which are declared in
-external entities should use validating XML processors.</p>
-</div2>
-</div1>
-<div1 id="sec-notation">
-<head>Notation</head>
-<p>The formal grammar of XML is given in this specification using a simple
-Extended Backus-Naur Form (EBNF) notation. Each rule in the grammar defines
-one symbol, in the form</p>
-<eg>symbol ::= expression</eg>
-<p>Symbols are written with an initial capital letter if they are <phrase
-diff="chg"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E42">[E42]</loc>the
-start symbol of a regular language,</phrase> otherwise with an initial lower
-case letter. Literal strings are quoted.</p>
-<p>Within the expression on the right-hand side of a rule, the following expressions
-are used to match strings of one or more characters: <glist>
-<gitem><label><code>#xN</code></label>
-<def>
-<p>where <code>N</code> is a hexadecimal integer, the expression matches the
-character in ISO/IEC 10646 whose canonical (UCS-4) code value, when interpreted
-as an unsigned binary number, has the value indicated. The number of leading
-zeros in the <code>#xN</code> form is insignificant; the number of leading
-zeros in the corresponding code value is governed by the character encoding
-in use and is not significant for XML.</p>
-</def></gitem>
-<gitem><label><code>[a-zA-Z]</code>, <code>[#xN-#xN]</code></label>
-<def>
-<p>matches any <phrase diff="chg"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E93">[E93]</loc><nt
-def="NT-Char">Char</nt></phrase> with a value in the range(s) indicated (inclusive).</p>
-</def></gitem>
-<gitem diff="add"><label><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E3">[E3]</loc><code>[abc]</code>, <code>[#xN#xN#xN]</code
-></label>
-<def>
-<p>matches any <nt def="NT-Char">Char</nt> with a value among the characters
-enumerated. Enumerations and ranges can be mixed in one set of brackets.</p>
-</def></gitem>
-<gitem><label><code>[^a-z]</code>, <code>[^#xN-#xN]</code></label>
-<def>
-<p>matches any <phrase diff="chg"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E93">[E93]</loc><nt
-def="NT-Char">Char</nt></phrase> with a value <emph>outside</emph> the range
-indicated.</p>
-</def></gitem>
-<gitem><label><code>[^abc]</code>, <code>[^#xN#xN#xN]</code></label>
-<def>
-<p>matches any <phrase diff="chg"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E93">[E93]</loc><nt
-def="NT-Char">Char</nt></phrase> with a value not among the characters given. <phrase
-diff="add"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E3">[E3]</loc>Enumerations
-and ranges of forbidden values can be mixed in one set of brackets.</phrase></p>
-</def></gitem>
-<gitem><label><code>"string"</code></label>
-<def>
-<p>matches a literal string <termref def="dt-match">matching</termref> that
-given inside the double quotes.</p>
-</def></gitem>
-<gitem><label><code>'string'</code></label>
-<def>
-<p>matches a literal string <termref def="dt-match">matching</termref> that
-given inside the single quotes.</p>
-</def></gitem>
-</glist> These symbols may be combined to match more complex patterns as follows,
-where <code>A</code> and <code>B</code> represent simple expressions: <glist>
-<gitem><label>(<code>expression</code>)</label>
-<def>
-<p><code>expression</code> is treated as a unit and may be combined as described
-in this list.</p>
-</def></gitem>
-<gitem><label><code>A?</code></label>
-<def>
-<p>matches <code>A</code> or nothing; optional <code>A</code>.</p>
-</def></gitem>
-<gitem><label><code>A B</code></label>
-<def>
-<p>matches <code>A</code> followed by <code>B</code>. <phrase diff="add"><loc
-role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E20">[E20]</loc>This
-operator has higher precedence than alternation; thus <code>A B | C D</code>
-is identical to <code>(A B) | (C D)</code>.</phrase></p>
-</def></gitem>
-<gitem><label><code>A | B</code></label>
-<def>
-<p>matches <code>A</code> or <code>B</code> but not both.</p>
-</def></gitem>
-<gitem><label><code>A - B</code></label>
-<def>
-<p>matches any string that matches <code>A</code> but does not match <code>B</code>.</p>
-</def></gitem>
-<gitem><label><code>A+</code></label>
-<def>
-<p>matches one or more occurrences of <code>A</code>.<phrase diff="add"><loc
-role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E20">[E20]</loc>Concatenation
-has higher precedence than alternation; thus <code>A+ | B+</code> is identical
-to <code>(A+) | (B+)</code>.</phrase></p>
-</def></gitem>
-<gitem><label><code>A*</code></label>
-<def>
-<p>matches zero or more occurrences of <code>A</code>. <phrase diff="add"><loc
-role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E20">[E20]</loc>Concatenation
-has higher precedence than alternation; thus <code>A* | B*</code> is identical
-to <code>(A*) | (B*)</code>.</phrase></p>
-</def></gitem>
-</glist> Other notations used in the productions are: <glist>
-<gitem><label><code>/* ... */</code></label>
-<def>
-<p>comment.</p>
-</def></gitem>
-<gitem><label><code>[ wfc: ... ]</code></label>
-<def>
-<p>well-formedness constraint; this identifies by name a constraint on <termref
-def="dt-wellformed">well-formed</termref> documents associated with a production.</p>
-</def></gitem>
-<gitem><label><code>[ vc: ... ]</code></label>
-<def>
-<p>validity constraint; this identifies by name a constraint on <termref def="dt-valid">valid</termref>
-documents associated with a production.</p>
-</def></gitem>
-</glist></p>
-</div1>
-</body><back>
-<!-- &SGML; -->
-<!-- &Biblio; -->
-<div1 id="sec-bibliography">
-<head>References</head>
-<div2 id="sec-existing-stds">
-<head>Normative References</head>
-<blist>
-<bibl id="IANA" diff="chg" key="IANA-CHARSETS"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E58">[E58]</loc>(Internet
-Assigned Numbers Authority) <titleref>Official Names for Character Sets</titleref>,
-ed. Keld Simonsen et al. See <loc href="ftp://ftp.isi.edu/in-notes/iana/assignments/character-sets">ftp://ftp.isi.edu/in-notes/iana/assignments/character-sets</loc
->. </bibl>
-<bibl id="RFC1766" href="http://www.ietf.org/rfc/rfc1766.txt" key="IETF RFC 1766">IETF
-(Internet Engineering Task Force). <titleref>RFC 1766: Tags for the Identification
-of Languages</titleref>, ed. H. Alvestrand. 1995.</bibl>
-<bibl id="ISO639-old" diff="del" key="ISO 639"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E38">[E38]</loc>
-(International Organization for Standardization). <titleref>ISO 639:1988 (E).
-Code for the representation of names of languages.</titleref> [Geneva]: International
-Organization for Standardization, 1988.</bibl>
-<bibl id="ISO3166-old" diff="del" key="ISO 3166"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E38">[E38]</loc>
-(International Organization for Standardization). <titleref>ISO 3166-1:1997
-(E). Codes for the representation of names of countries and their subdivisions —
-Part 1: Country codes</titleref> [Geneva]: International Organization for
-Standardization, 1997.</bibl>
-<bibl id="ISO10646" key="ISO/IEC 10646">ISO (International Organization for
-Standardization). <titleref>ISO/IEC 10646-1993 (E). Information technology —
-Universal Multiple-Octet Coded Character Set (UCS) — Part 1: Architecture
-and Basic Multilingual Plane.</titleref> [Geneva]: International Organization
-for Standardization, 1993 (plus amendments AM 1 through AM 7).</bibl>
-<bibl id="ISO10646-2000" diff="add" key="ISO/IEC 10646-2000"><loc role="erratumref"
-href="http://www.w3.org/XML/xml-19980210-errata#E67">[E67]</loc> ISO (International
-Organization for Standardization). <titleref>ISO/IEC 10646-1:2000. Information
-technology — Universal Multiple-Octet Coded Character Set (UCS) —
-Part 1: Architecture and Basic Multilingual Plane.</titleref> [Geneva]: International
-Organization for Standardization, 2000.</bibl>
-<bibl id="Unicode" key="Unicode">The Unicode Consortium. <emph>The Unicode
-Standard, Version 2.0.</emph> Reading, Mass.: Addison-Wesley Developers Press,
-1996.</bibl>
-<bibl id="Unicode3" diff="add" key="Unicode3"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E67">[E67]</loc>
-The Unicode Consortium. <emph>The Unicode Standard, Version 3.0.</emph> Reading,
-Mass.: Addison-Wesley Developers Press, 2000. ISBN 0-201-61633-5.</bibl>
-</blist></div2>
-<div2 id="null">
-<!--
-ID made "null" to match its previous value in the First
-Edition; it's odd, but if there's no set value, the stylesheet 
-currently generates an odd string that would be backwards
-incompatible with any references anyone might have made before.
--->
-<head>Other References</head>
-<blist>
-<bibl id="Aho" key="Aho/Ullman">Aho, Alfred V., Ravi Sethi, and Jeffrey D.
-Ullman. <titleref>Compilers: Principles, Techniques, and Tools</titleref>.
-Reading: Addison-Wesley, 1986, rpt. corr. 1988.</bibl>
-<bibl id="Berners-Lee" key="Berners-Lee et al."> Berners-Lee, T., R. Fielding,
-and L. Masinter. <titleref>Uniform Resource Identifiers (URI): Generic Syntax
-and Semantics</titleref>. 1997. (Work in progress; see updates to RFC1738.)</bibl>
-<bibl id="ABK" diff="chg" key="Brüggemann-Klein"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E2">[E2]</loc>Brüggemann-Klein,
-Anne. Formal Models in Document Processing. Habilitationsschrift. Faculty
-of Mathematics at the University of Freiburg, 1993. (See <loc href="ftp://ftp.informatik.uni-freiburg.de/documents/papers/brueggem/habil.ps">ftp://ftp.informatik.uni-freiburg.de/documents/papers/brueggem/habil.ps</loc
->.)</bibl>
-<bibl id="ABKDW" diff="chg" key="Brüggemann-Klein and Wood"><loc role="erratumref"
-href="http://www.w3.org/XML/xml-19980210-errata#E2">[E2]</loc>Brüggemann-Klein,
-Anne, and Derick Wood. <titleref>Deterministic Regular Languages</titleref>.
-Universität Freiburg, Institut für Informatik, Bericht 38, Oktober 1991. Extended
-abstract in A. Finkel, M. Jantzen, Hrsg., STACS 1992, S. 173-184. Springer-Verlag,
-Berlin 1992. Lecture Notes in Computer Science 577. Full version titled <titleref>One-Unambiguous
-Regular Languages</titleref> in Information and Computation 140 (2): 229-253,
-February 1998.</bibl>
-<bibl id="Clark" key="Clark">James Clark. Comparison of SGML and XML. See <loc
-href="http://www.w3.org/TR/NOTE-sgml-xml-971215">http://www.w3.org/TR/NOTE-sgml-xml-971215</loc>. </bibl>
-<bibl id="IANA-LANGCODES" diff="add" href="http://www.isi.edu/in-notes/iana/assignments/languages/"
-key="IANA-LANGCODES"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E58">[E58]</loc>(Internet
-Assigned Numbers Authority) <titleref>Registry of Language Tags</titleref>,
-ed. Keld Simonsen et al.</bibl>
-<bibl id="RFC1738" diff="del" href="http://www.ietf.org/rfc/rfc1738.txt" key="IETF RFC1738">IETF
-(Internet Engineering Task Force). <titleref>RFC 1738: Uniform Resource Locators
-(URL)</titleref>, ed. T. Berners-Lee, L. Masinter, M. McCahill. 1994. </bibl>
-<bibl id="RFC1808" diff="del" href="http://www.ietf.org/rfc/rfc1808.txt" key="IETF RFC1808">IETF
-(Internet Engineering Task Force). <titleref>RFC 1808: Relative Uniform Resource
-Locators</titleref>, ed. R. Fielding. 1995. </bibl>
-<bibl id="RFC2141" href="http://www.ietf.org/rfc/rfc2141.txt" key="IETF RFC2141">IETF
-(Internet Engineering Task Force). <emph>RFC 2141: URN Syntax</emph>, ed.
-R. Moats. 1997. </bibl>
-<bibl id="rfc2279" diff="add" href="http://www.ietf.org/rfc/rfc2279.txt" key="IETF RFC 2279"><loc
-role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E78">[E78]</loc>IETF
-(Internet Engineering Task Force). <titleref>RFC 2279: UTF-8, a transformation
-format of ISO 10646</titleref>, <phrase diff="add">ed. F. Yergeau, </phrase>1998.</bibl>
-<bibl id="rfc2376" diff="add" href="http://www.ietf.org/rfc/rfc2376.txt" key="IETF RFC 2376"><loc
-role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E48">[E48]</loc>IETF
-(Internet Engineering Task Force). <titleref>RFC 2376: XML Media Types</titleref>.
-ed. E. Whitehead, M. Murata. 1998.</bibl>
-<bibl id="rfc2396" diff="add" href="http://www.ietf.org/rfc/rfc2396.txt" key="IETF RFC 2396"><loc
-role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E66">[E66]</loc>IETF
-(Internet Engineering Task Force). <titleref>RFC 2396: Uniform Resource Identifiers
-(URI): Generic Syntax</titleref>. T. Berners-Lee, R. Fielding, L. Masinter.
-1998.</bibl>
-<bibl id="rfc2732" diff="add" href="http://www.ietf.org/rfc/rfc2732.txt" key="IETF RFC 2732"><loc
-role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E66">[E66]</loc>IETF
-(Internet Engineering Task Force). <titleref>RFC 2732: Format for Literal
-IPv6 Addresses in URL's</titleref>. R. Hinden, B. Carpenter, L. Masinter.
-1999.</bibl>
-<bibl id="rfc2781" diff="add" href="http://www.ietf.org/rfc/rfc2781.txt" key="IETF RFC 2781"><loc
-role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E77">[E77]</loc>
-IETF (Internet Engineering Task Force). <emph>RFC 2781: UTF-16, an encoding
-of ISO 10646</emph>, ed. P. Hoffman, F. Yergeau. 2000.</bibl>
-<bibl id="ISO639" diff="add" key="ISO 639"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E38">[E38]</loc>
-(International Organization for Standardization). <titleref>ISO 639:1988 (E).
-Code for the representation of names of languages.</titleref> [Geneva]: International
-Organization for Standardization, 1988.</bibl>
-<bibl id="ISO3166" diff="add" key="ISO 3166"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E38">[E38]</loc>
-(International Organization for Standardization). <titleref>ISO 3166-1:1997
-(E). Codes for the representation of names of countries and their subdivisions —
-Part 1: Country codes</titleref> [Geneva]: International Organization for
-Standardization, 1997.</bibl>
-<bibl id="ISO8879" key="ISO 8879">ISO (International Organization for Standardization). <titleref>ISO
-8879:1986(E). Information processing — Text and Office Systems —
-Standard Generalized Markup Language (SGML).</titleref> First edition —
-1986-10-15. [Geneva]: International Organization for Standardization, 1986. </bibl>
-<bibl id="ISO10744" key="ISO/IEC 10744">ISO (International Organization for
-Standardization). <titleref>ISO/IEC 10744-1992 (E). Information technology —
-Hypermedia/Time-based Structuring Language (HyTime). </titleref> [Geneva]:
-International Organization for Standardization, 1992. <emph>Extended Facilities
-Annexe.</emph> [Geneva]: International Organization for Standardization, 1996. </bibl>
-<bibl id="websgml" diff="add" href="http://www.sgmlsource.com/8879rev/n0029.htm"
-key="WEBSGML"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E43">[E43]</loc>ISO
-(International Organization for Standardization). <titleref>ISO 8879:1986
-TC2. Information technology — Document Description and Processing Languages. </titleref>
-[Geneva]: International Organization for Standardization, 1998.</bibl>
-<bibl id="xml-names" diff="add" xmlns:xlink="http://www.w3.org/TR/WD-xlink"
-href="http://www.w3.org/TR/REC-xml-names/" key="XML Names"><loc role="erratumref"
-href="http://www.w3.org/XML/xml-19980210-errata#E98">[E98]</loc>Tim Bray,
-Dave Hollander, and Andrew Layman, editors. <titleref>Namespaces in XML</titleref>.
-Textuality, Hewlett-Packard, and Microsoft. World Wide Web Consortium, 1999.</bibl>
-</blist></div2>
-</div1>
-<div1 id="CharClasses">
-<head>Character Classes</head>
-<p>Following the characteristics defined in the Unicode standard, characters
-are classed as base characters (among others, these contain the alphabetic
-characters of the Latin alphabet<phrase diff="del"><loc role="erratumref"
-href="http://www.w3.org/XML/xml-19980210-errata#E84">[E84]</loc>, without
-diacritics</phrase>), ideographic characters, and combining characters (among
-others, this class contains most diacritics)<phrase diff="del"><loc role="erratumref"
-href="http://www.w3.org/XML/xml-19980210-errata#E30">[E30]</loc>; these classes
-combine to form the class of letters.</phrase> Digits and extenders are also
-distinguished.</p>
-<scrap id="CHARACTERS" lang="ebnf">
-<head>Characters</head>
-<prodgroup pcw3="3" pcw4="15">
-<prod id="NT-Letter">
-<lhs>Letter</lhs><rhs><nt def="NT-BaseChar">BaseChar</nt> | <nt def="NT-Ideographic">Ideographic</nt></rhs>
-</prod>
-<prod id="NT-BaseChar">
-<lhs>BaseChar</lhs><rhs>[#x0041-#x005A] | [#x0061-#x007A] | [#x00C0-#x00D6]
-| [#x00D8-#x00F6] | [#x00F8-#x00FF] | [#x0100-#x0131] | [#x0134-#x013E]
-| [#x0141-#x0148] | [#x014A-#x017E] | [#x0180-#x01C3] | [#x01CD-#x01F0]
-| [#x01F4-#x01F5] | [#x01FA-#x0217] | [#x0250-#x02A8] | [#x02BB-#x02C1]
-| #x0386 | [#x0388-#x038A] | #x038C | [#x038E-#x03A1]
-| [#x03A3-#x03CE] | [#x03D0-#x03D6] | #x03DA | #x03DC
-| #x03DE | #x03E0 | [#x03E2-#x03F3] | [#x0401-#x040C]
-| [#x040E-#x044F] | [#x0451-#x045C] | [#x045E-#x0481] | [#x0490-#x04C4]
-| [#x04C7-#x04C8] | [#x04CB-#x04CC] | [#x04D0-#x04EB] | [#x04EE-#x04F5]
-| [#x04F8-#x04F9] | [#x0531-#x0556] | #x0559 | [#x0561-#x0586]
-| [#x05D0-#x05EA] | [#x05F0-#x05F2] | [#x0621-#x063A] | [#x0641-#x064A]
-| [#x0671-#x06B7] | [#x06BA-#x06BE] | [#x06C0-#x06CE] | [#x06D0-#x06D3]
-| #x06D5 | [#x06E5-#x06E6] | [#x0905-#x0939] | #x093D
-| [#x0958-#x0961] | [#x0985-#x098C] | [#x098F-#x0990] | [#x0993-#x09A8]
-| [#x09AA-#x09B0] | #x09B2 | [#x09B6-#x09B9] | [#x09DC-#x09DD]
-| [#x09DF-#x09E1] | [#x09F0-#x09F1] | [#x0A05-#x0A0A] | [#x0A0F-#x0A10]
-| [#x0A13-#x0A28] | [#x0A2A-#x0A30] | [#x0A32-#x0A33] | [#x0A35-#x0A36]
-| [#x0A38-#x0A39] | [#x0A59-#x0A5C] | #x0A5E | [#x0A72-#x0A74]
-| [#x0A85-#x0A8B] | #x0A8D | [#x0A8F-#x0A91] | [#x0A93-#x0AA8]
-| [#x0AAA-#x0AB0] | [#x0AB2-#x0AB3] | [#x0AB5-#x0AB9] | #x0ABD
-| #x0AE0 | [#x0B05-#x0B0C] | [#x0B0F-#x0B10] | [#x0B13-#x0B28]
-| [#x0B2A-#x0B30] | [#x0B32-#x0B33] | [#x0B36-#x0B39] | #x0B3D
-| [#x0B5C-#x0B5D] | [#x0B5F-#x0B61] | [#x0B85-#x0B8A] | [#x0B8E-#x0B90]
-| [#x0B92-#x0B95] | [#x0B99-#x0B9A] | #x0B9C | [#x0B9E-#x0B9F]
-| [#x0BA3-#x0BA4] | [#x0BA8-#x0BAA] | [#x0BAE-#x0BB5] | [#x0BB7-#x0BB9]
-| [#x0C05-#x0C0C] | [#x0C0E-#x0C10] | [#x0C12-#x0C28] | [#x0C2A-#x0C33]
-| [#x0C35-#x0C39] | [#x0C60-#x0C61] | [#x0C85-#x0C8C] | [#x0C8E-#x0C90]
-| [#x0C92-#x0CA8] | [#x0CAA-#x0CB3] | [#x0CB5-#x0CB9] | #x0CDE
-| [#x0CE0-#x0CE1] | [#x0D05-#x0D0C] | [#x0D0E-#x0D10] | [#x0D12-#x0D28]
-| [#x0D2A-#x0D39] | [#x0D60-#x0D61] | [#x0E01-#x0E2E] | #x0E30
-| [#x0E32-#x0E33] | [#x0E40-#x0E45] | [#x0E81-#x0E82] | #x0E84
-| [#x0E87-#x0E88] | #x0E8A | #x0E8D | [#x0E94-#x0E97]
-| [#x0E99-#x0E9F] | [#x0EA1-#x0EA3] | #x0EA5 | #x0EA7
-| [#x0EAA-#x0EAB] | [#x0EAD-#x0EAE] | #x0EB0 | [#x0EB2-#x0EB3]
-| #x0EBD | [#x0EC0-#x0EC4] | [#x0F40-#x0F47] | [#x0F49-#x0F69]
-| [#x10A0-#x10C5] | [#x10D0-#x10F6] | #x1100 | [#x1102-#x1103]
-| [#x1105-#x1107] | #x1109 | [#x110B-#x110C] | [#x110E-#x1112]
-| #x113C | #x113E | #x1140 | #x114C | #x114E | #x1150
-| [#x1154-#x1155] | #x1159 | [#x115F-#x1161] | #x1163
-| #x1165 | #x1167 | #x1169 | [#x116D-#x116E] | [#x1172-#x1173]
-| #x1175 | #x119E | #x11A8 | #x11AB | [#x11AE-#x11AF]
-| [#x11B7-#x11B8] | #x11BA | [#x11BC-#x11C2] | #x11EB
-| #x11F0 | #x11F9 | [#x1E00-#x1E9B] | [#x1EA0-#x1EF9]
-| [#x1F00-#x1F15] | [#x1F18-#x1F1D] | [#x1F20-#x1F45] | [#x1F48-#x1F4D]
-| [#x1F50-#x1F57] | #x1F59 | #x1F5B | #x1F5D | [#x1F5F-#x1F7D]
-| [#x1F80-#x1FB4] | [#x1FB6-#x1FBC] | #x1FBE | [#x1FC2-#x1FC4]
-| [#x1FC6-#x1FCC] | [#x1FD0-#x1FD3] | [#x1FD6-#x1FDB] | [#x1FE0-#x1FEC]
-| [#x1FF2-#x1FF4] | [#x1FF6-#x1FFC] | #x2126 | [#x212A-#x212B]
-| #x212E | [#x2180-#x2182] | [#x3041-#x3094] | [#x30A1-#x30FA]
-| [#x3105-#x312C] | [#xAC00-#xD7A3] </rhs>
-</prod>
-<prod id="NT-Ideographic">
-<lhs>Ideographic</lhs><rhs>[#x4E00-#x9FA5] | #x3007 | [#x3021-#x3029] </rhs>
-</prod>
-<prod id="NT-CombiningChar">
-<lhs>CombiningChar</lhs><rhs>[#x0300-#x0345] | [#x0360-#x0361] | [#x0483-#x0486]
-| [#x0591-#x05A1] | [#x05A3-#x05B9] | [#x05BB-#x05BD] | #x05BF
-| [#x05C1-#x05C2] | #x05C4 | [#x064B-#x0652] | #x0670
-| [#x06D6-#x06DC] | [#x06DD-#x06DF] | [#x06E0-#x06E4] | [#x06E7-#x06E8]
-| [#x06EA-#x06ED] | [#x0901-#x0903] | #x093C | [#x093E-#x094C]
-| #x094D | [#x0951-#x0954] | [#x0962-#x0963] | [#x0981-#x0983]
-| #x09BC | #x09BE | #x09BF | [#x09C0-#x09C4] | [#x09C7-#x09C8]
-| [#x09CB-#x09CD] | #x09D7 | [#x09E2-#x09E3] | #x0A02
-| #x0A3C | #x0A3E | #x0A3F | [#x0A40-#x0A42] | [#x0A47-#x0A48]
-| [#x0A4B-#x0A4D] | [#x0A70-#x0A71] | [#x0A81-#x0A83] | #x0ABC
-| [#x0ABE-#x0AC5] | [#x0AC7-#x0AC9] | [#x0ACB-#x0ACD] | [#x0B01-#x0B03]
-| #x0B3C | [#x0B3E-#x0B43] | [#x0B47-#x0B48] | [#x0B4B-#x0B4D]
-| [#x0B56-#x0B57] | [#x0B82-#x0B83] | [#x0BBE-#x0BC2] | [#x0BC6-#x0BC8]
-| [#x0BCA-#x0BCD] | #x0BD7 | [#x0C01-#x0C03] | [#x0C3E-#x0C44]
-| [#x0C46-#x0C48] | [#x0C4A-#x0C4D] | [#x0C55-#x0C56] | [#x0C82-#x0C83]
-| [#x0CBE-#x0CC4] | [#x0CC6-#x0CC8] | [#x0CCA-#x0CCD] | [#x0CD5-#x0CD6]
-| [#x0D02-#x0D03] | [#x0D3E-#x0D43] | [#x0D46-#x0D48] | [#x0D4A-#x0D4D]
-| #x0D57 | #x0E31 | [#x0E34-#x0E3A] | [#x0E47-#x0E4E]
-| #x0EB1 | [#x0EB4-#x0EB9] | [#x0EBB-#x0EBC] | [#x0EC8-#x0ECD]
-| [#x0F18-#x0F19] | #x0F35 | #x0F37 | #x0F39 | #x0F3E
-| #x0F3F | [#x0F71-#x0F84] | [#x0F86-#x0F8B] | [#x0F90-#x0F95]
-| #x0F97 | [#x0F99-#x0FAD] | [#x0FB1-#x0FB7] | #x0FB9
-| [#x20D0-#x20DC] | #x20E1 | [#x302A-#x302F] | #x3099
-| #x309A </rhs>
-</prod>
-<prod id="NT-Digit">
-<lhs>Digit</lhs><rhs>[#x0030-#x0039] | [#x0660-#x0669] | [#x06F0-#x06F9]
-| [#x0966-#x096F] | [#x09E6-#x09EF] | [#x0A66-#x0A6F] | [#x0AE6-#x0AEF]
-| [#x0B66-#x0B6F] | [#x0BE7-#x0BEF] | [#x0C66-#x0C6F] | [#x0CE6-#x0CEF]
-| [#x0D66-#x0D6F] | [#x0E50-#x0E59] | [#x0ED0-#x0ED9] | [#x0F20-#x0F29] </rhs>
-</prod>
-<prod id="NT-Extender">
-<lhs>Extender</lhs><rhs>#x00B7 | #x02D0 | #x02D1 | #x0387 | #x0640
-| #x0E46 | #x0EC6 | #x3005 | [#x3031-#x3035] | [#x309D-#x309E]
-| [#x30FC-#x30FE] </rhs>
-</prod>
-</prodgroup></scrap>
-<p>The character classes defined here can be derived from the Unicode <phrase
-diff="add"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E67">[E67]</loc>2.0</phrase>
-character database as follows:</p>
-<ulist>
-<item><p>Name start characters must have one of the categories Ll, Lu, Lo,
-Lt, Nl.</p></item>
-<item><p>Name characters other than Name-start characters must have one of
-the categories Mc, Me, Mn, Lm, or Nd.</p></item>
-<item><p>Characters in the compatibility area (i.e. with character code greater
-than #xF900 and less than #xFFFE) are not allowed in XML names.</p></item>
-<item><p>Characters which have a font or compatibility decomposition (i.e.
-those with a <quote>compatibility formatting tag</quote> in field 5 of the
-database -- marked by field 5 beginning with a <quote><</quote>) are not
-allowed.</p></item>
-<item><p>The following characters are treated as name-start characters rather
-than name characters, because the property file classifies them as Alphabetic:
-[#x02BB-#x02C1], #x0559, #x06E5, #x06E6.</p></item>
-<item><p>Characters #x20DD-#x20E0 are excluded (in accordance with Unicode <phrase
-diff="add"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E67">[E67]</loc>2.0</phrase>,
-section 5.14).</p></item>
-<item><p>Character #x00B7 is classified as an extender, because the property
-list so identifies it.</p></item>
-<item><p>Character #x0387 is added as a name character, because #x00B7 is
-its canonical equivalent.</p></item>
-<item><p>Characters ':' and '_' are allowed as name-start characters.</p>
-</item>
-<item><p>Characters '-' and '.' are allowed as name characters.</p></item>
-</ulist>
-</div1>
-<inform-div1 id="sec-xml-and-sgml">
-<head>XML and SGML</head>
-<p><phrase diff="chg"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E43">[E43]</loc>XML
-is designed to be a subset of SGML, in that every XML document should also
-be a conforming SGML document.</phrase> For a detailed comparison of the additional
-restrictions that XML places on documents beyond those of SGML, see <bibref
-ref="Clark"/>.</p>
-</inform-div1>
-<inform-div1 id="sec-entexpand">
-<head>Expansion of Entity and Character References</head>
-<p>This appendix contains some examples illustrating the sequence of entity-
-and character-reference recognition and expansion, as specified in <specref
-ref="entproc"/>.</p>
-<p>If the DTD contains the declaration</p>
-<eg><![CDATA[<!ENTITY example "<p>An ampersand (&#38;) may be escaped
-numerically (&#38;#38;) or with a general entity
-(&amp;).</p>" >]]></eg>
-<p>then the XML processor will recognize the character references when it
-parses the entity declaration, and resolve them before storing the following
-string as the value of the entity <quote><code>example</code></quote>:</p>
-<eg><![CDATA[<p>An ampersand (&) may be escaped
-numerically (&#38;) or with a general entity
-(&amp;).</p>]]></eg>
-<p>A reference in the document to <quote><code>&example;</code></quote>
-will cause the text to be reparsed, at which time the start- and end-tags
-of the <el>p</el> element will be recognized and the three references will
-be recognized and expanded, resulting in a <el>p</el> element with the following
-content (all data, no delimiters or markup):</p>
-<eg><![CDATA[An ampersand (&) may be escaped
-numerically (&) or with a general entity
-(&).]]></eg>
-<p>A more complex example will illustrate the rules and their effects fully.
-In the following example, the line numbers are solely for reference.</p>
-<eg><![CDATA[1 <?xml version='1.0'?>
-2 <!DOCTYPE test [
-3 <!ELEMENT test (#PCDATA) >
-4 <!ENTITY % xx '%zz;'>
-5 <!ENTITY % zz '<!ENTITY tricky "error-prone" >' >
-6 %xx;
-7 ]>
-8 <test>This sample shows a &tricky; method.</test>]]></eg>
-<p>This produces the following:</p>
-<ulist spacing="compact">
-<item><p>in line 4, the reference to character 37 is expanded immediately,
-and the parameter entity <quote><code>xx</code></quote> is stored in the symbol
-table with the value <quote><code>%zz;</code></quote>. Since the replacement
-text is not rescanned, the reference to parameter entity <quote><code>zz</code></quote>
-is not recognized. (And it would be an error if it were, since <quote><code>zz</code></quote>
-is not yet declared.)</p></item>
-<item><p>in line 5, the character reference <quote><code>&#60;</code></quote>
-is expanded immediately and the parameter entity <quote><code>zz</code></quote>
-is stored with the replacement text <quote><code><!ENTITY tricky "error-prone"
-></code></quote>, which is a well-formed entity declaration.</p></item>
-<item><p>in line 6, the reference to <quote><code>xx</code></quote> is recognized,
-and the replacement text of <quote><code>xx</code></quote> (namely <quote><code>%zz;</code></quote>)
-is parsed. The reference to <quote><code>zz</code></quote> is recognized in
-its turn, and its replacement text (<quote><code><!ENTITY tricky "error-prone"
-></code></quote>) is parsed. The general entity <quote><code>tricky</code></quote>
-has now been declared, with the replacement text <quote><code>error-prone</code></quote>.</p>
-</item>
-<item><p>in line 8, the reference to the general entity <quote><code>tricky</code></quote>
-is recognized, and it is expanded, so the full content of the <el>test</el>
-element is the self-describing (and ungrammatical) string <emph>This sample
-shows a error-prone method.</emph></p></item>
-</ulist>
-</inform-div1>
-<inform-div1 id="determinism">
-<head>Deterministic Content Models</head>
-<p><phrase diff="chg"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E102">[E102]</loc>As
-noted in <specref ref="sec-element-content"/>, it is required that content
-models in element type declarations be deterministic. This requirement is <termref
-def="dt-compat">for compatibility</termref> with SGML (which calls deterministic
-content models <quote>unambiguous</quote>);</phrase> XML processors built
-using SGML systems may flag non-deterministic content models as errors.</p>
-<p>For example, the content model <code>((b, c) | (b, d))</code> is non-deterministic,
-because given an initial <el>b</el> the <phrase diff="chg"><loc role="erratumref"
-href="http://www.w3.org/XML/xml-19980210-errata#E95">[E95]</loc>XML processor</phrase>
-cannot know which <el>b</el> in the model is being matched without looking
-ahead to see which element follows the <el>b</el>. In this case, the two references
-to <el>b</el> can be collapsed into a single reference, making the model read <code>(b,
-(c | d))</code>. An initial <el>b</el> now clearly matches only a single name
-in the content model. The <phrase diff="chg"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E95">[E95]</loc>processor</phrase
-> doesn't need to look ahead to see what follows; either <el>c</el> or <el>d</el>
-would be accepted.</p>
-<p>More formally: a finite state automaton may be constructed from the content
-model using the standard algorithms, e.g. algorithm 3.5 in section 3.9 of
-Aho, Sethi, and Ullman <bibref ref="Aho"/>. In many such algorithms, a follow
-set is constructed for each position in the regular expression (i.e., each
-leaf node in the syntax tree for the regular expression); if any position
-has a follow set in which more than one following position is labeled with
-the same element type name, then the content model is in error and may be
-reported as an error.</p>
-<p>Algorithms exist which allow many but not all non-deterministic content
-models to be reduced automatically to equivalent deterministic models; see
-Brüggemann-Klein 1991 <bibref ref="ABK"/>.</p>
-</inform-div1>
-<inform-div1 id="sec-guessing">
-<head><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E105">[E105]</loc><loc
-role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E48">[E48]</loc>Autodetection
-of Character Encodings</head>
-<p>The XML encoding declaration functions as an internal label on each entity,
-indicating which character encoding is in use. Before an XML processor can
-read the internal label, however, it apparently has to know what character
-encoding is in use—which is what the internal label is trying to indicate.
-In the general case, this is a hopeless situation. It is not entirely hopeless
-in XML, however, because XML limits the general case in two ways: each implementation
-is assumed to support only a finite set of character encodings, and the XML
-encoding declaration is restricted in position and content in order to make
-it feasible to autodetect the character encoding in use in each entity in
-normal cases. Also, in many cases other sources of information are available
-in addition to the XML data stream itself. Two cases may be distinguished,
-depending on whether the XML entity is presented to the processor without,
-or with, any accompanying (external) information. We consider the first case
-first.</p>
-<div2 id="sec-guessing-no-ext-info">
-<head diff="add">Detection Without External Encoding Information</head>
-<p>Because each XML entity <phrase diff="add">not accompanied by external
-encoding information and </phrase>not in UTF-8 or UTF-16 <phrase diff="chg">encoding</phrase> <emph>must</emph>
-begin with an XML encoding declaration, in which the first characters must
-be '<code><?xml</code>', any conforming processor can detect, after two
-to four octets of input, which of the following cases apply. In reading this
-list, it may help to know that in UCS-4, '<' is <quote><code>#x0000003C</code></quote>
-and '?' is <quote><code>#x0000003F</code></quote>, and the Byte Order Mark
-required of UTF-16 data streams is <quote><code>#xFEFF</code></quote>. <phrase
-diff="add">The notation <var>##</var> is used to denote any byte value except <phrase
-diff="chg">that two consecutive <var>##</var>s cannot be both 00</phrase>.</phrase></p>
-<p diff="add">With a Byte Order Mark:</p>
-<table diff="add" border="1" frame="border"><tbody><tr><td><code>00 00 FE
-FF</code></td><td>UCS-4, big-endian machine (1234 order)</td></tr><tr><td><code>FF
-FE 00 00</code></td><td>UCS-4, little-endian machine (4321 order)</td></tr>
-<tr><td><code>00 00 FF FE</code></td><td>UCS-4, unusual octet order (2143)</td>
-</tr><tr><td><code>FE FF 00 00</code></td><td>UCS-4, unusual octet order (3412)</td>
-</tr><tr><td><code>FE FF ## ##</code></td><td>UTF-16, big-endian</td></tr>
-<tr><td><code>FF FE ## ##</code></td><td>UTF-16, little-endian</td></tr><tr>
-<td><code>EF BB BF</code></td><td>UTF-8</td></tr></tbody></table>
-<p diff="add">Without a Byte Order Mark:</p>
-<table diff="add" border="1" frame="border"><tbody><tr><td><code>00 00 00 3C</code></td>
-<td rowspan="4">UCS-4 or other encoding with a 32-bit code unit and ASCII
-characters encoded as ASCII values, in respectively big-endian (1234), little-endian
-(4321) and two unusual byte orders (2143 and 3412). The encoding declaration
-must be read to determine which of UCS-4 or other supported 32-bit encodings
-applies.</td></tr><tr><td><code>3C 00 00 00</code></td>
-<!--<td>UCS-4, little-endian machine (4321 order)</td>-->
-</tr><tr><td><code>00 00 3C 00</code></td>
-<!--<td>UCS-4, unusual octet order (2143)</td>-->
-</tr><tr><td><code>00 3C 00 00</code></td>
-<!--<td>UCS-4, unusual octet order (3412)</td>-->
-</tr><tr><td><code>00 3C 00 3F</code></td><td>UTF-16BE or big-endian ISO-10646-UCS-2
-or other encoding with a 16-bit code unit in big-endian order and ASCII characters
-encoded as ASCII values (the encoding declaration must be read to determine
-which)</td></tr><tr><td><code>3C 00 3F 00</code></td><td>UTF-16LE or little-endian
-ISO-10646-UCS-2 or other encoding with a 16-bit code unit in little-endian
-order and ASCII characters encoded as ASCII values (the encoding declaration
-must be read to determine which)</td></tr><tr><td><code>3C 3F 78 6D</code></td>
-<td>UTF-8, ISO 646, ASCII, some part of ISO 8859, Shift-JIS, EUC, or any other
-7-bit, 8-bit, or mixed-width encoding which ensures that the characters of
-ASCII have their normal positions, width, and values; the actual encoding
-declaration must be read to detect which of these applies, but since all of
-these encodings use the same bit patterns for the relevant ASCII characters,
-the encoding declaration itself may be read reliably</td></tr><tr><td><code>4C
-6F A7 94</code></td><td>EBCDIC (in some flavor; the full encoding declaration
-must be read to tell which code page is in use)</td></tr><tr><td>Other</td>
-<td>UTF-8 without an encoding declaration, or else the data stream is mislabeled
-(lacking a required encoding declaration), corrupt, fragmentary, or enclosed
-in a wrapper of some kind</td></tr></tbody></table>
-<note diff="add">
-<p>In cases above which do not require reading the encoding declaration to
-determine the encoding, section 4.3.3 still requires that the encoding declaration,
-if present, be read and that the encoding name be checked to match the actual
-encoding of the entity. Also, it is possible that new character encodings
-will be invented that will make it necessary to use the encoding declaration
-to determine the encoding, in cases where this is not required at present.</p>
-</note>
-<p>This level of autodetection is enough to read the XML encoding declaration
-and parse the character-encoding identifier, which is still necessary to distinguish
-the individual members of each family of encodings (e.g. to tell UTF-8 from
-8859, and the parts of 8859 from each other, or to distinguish the specific
-EBCDIC code page in use, and so on).</p>
-<p>Because the contents of the encoding declaration are restricted to <phrase
-diff="chg">characters from the ASCII repertoire (however encoded)</phrase>,
-a processor can reliably read the entire encoding declaration as soon as it
-has detected which family of encodings is in use. Since in practice, all widely
-used character encodings fall into one of the categories above, the XML encoding
-declaration allows reasonably reliable in-band labeling of character encodings,
-even when external sources of information at the operating-system or transport-protocol
-level are unreliable. <phrase diff="del">Note that since external parsed entities
-in UTF-16 may begin with any character, this autodetection does not always
-work. Also, </phrase><phrase diff="add">Character encodings such as UTF-7
-that make overloaded usage of ASCII-valued bytes may fail to be reliably detected.</phrase></p>
-<p>Once the processor has detected the character encoding in use, it can act
-appropriately, whether by invoking a separate input routine for each case,
-or by calling the proper conversion function on each character of input.</p>
-<p>Like any self-labeling system, the XML encoding declaration will not work
-if any software changes the entity's character set or encoding without updating
-the encoding declaration. Implementors of character-encoding routines should
-be careful to ensure the accuracy of the internal and external information
-used to label the entity.</p>
-</div2>
-<div2 id="sec-guessing-with-ext-info">
-<head diff="add">Priorities in the Presence of External Encoding Information</head>
-<p>The second possible case occurs when the XML entity is accompanied by encoding
-information, as in some file systems and some network protocols. When multiple
-sources of information are available, their relative priority and the preferred
-method of handling conflict should be specified as part of the higher-level
-protocol used to deliver XML. <phrase diff="chg">In particular, please refer
-to <bibref ref="rfc2376"/> or its successor, which defines the <code>text/xml</code>
-and <code>application/xml</code> MIME types and provides some useful guidance.
-In the interests of interoperability, however, the following rule is recommended.</phrase></p>
-<ulist>
-<item><p>If an XML entity is in a file, the Byte-Order Mark and encoding declaration <phrase
-diff="del">PI </phrase>are used (if present) to determine the character encoding.<phrase
-diff="del"><loc role="erratumref" href="http://www.w3.org/XML/xml-19980210-errata#E74">[E74]</loc>
-All other heuristics and sources of information are solely for error recovery.</phrase></p>
-</item>
-</ulist>
-<ulist diff="del">
-<item><p>If an XML entity is delivered with a MIME type of text/xml, then
-the <code>charset</code> parameter on the MIME type determines the character
-encoding method; all other heuristics and sources of information are solely
-for error recovery.</p></item>
-<item><p>If an XML entity is delivered with a MIME type of application/xml,
-then the Byte-Order Mark and encoding-declaration PI are used (if present)
-to determine the character encoding. All other heuristics and sources of information
-are solely for error recovery.</p></item>
-</ulist>
-<p diff="del">These rules apply only in the absence of protocol-level documentation;
-in particular, when the MIME types text/xml and application/xml are defined,
-the recommendations of the relevant RFC will supersede these rules.</p>
-</div2>
-</inform-div1>
-<inform-div1 id="sec-xml-wg">
-<head>W3C XML Working Group</head>
-<p>This specification was prepared and approved for publication by the W3C
-XML Working Group (WG). WG approval of this specification does not necessarily
-imply that all WG members voted for its approval. The current and former members
-of the XML WG are:</p>
-<orglist>
-<member><name>Jon Bosak</name><affiliation>Sun</affiliation><role>Chair</role>
-</member>
-<member><name>James Clark</name><role>Technical Lead</role></member>
-<member><name>Tim Bray</name><affiliation>Textuality and Netscape</affiliation>
-<role>XML Co-editor</role></member>
-<member><name>Jean Paoli</name><affiliation>Microsoft</affiliation><role>XML
-Co-editor</role></member>
-<member><name>C. M. Sperberg-McQueen</name><affiliation>U. of Ill.</affiliation>
-<role>XML Co-editor</role></member>
-<member><name>Dan Connolly</name><affiliation>W3C</affiliation><role>W3C Liaison</role>
-</member>
-<member><name>Paula Angerstein</name><affiliation>Texcel</affiliation></member>
-<member><name>Steve DeRose</name><affiliation>INSO</affiliation></member>
-<member><name>Dave Hollander</name><affiliation>HP</affiliation></member>
-<member><name>Eliot Kimber</name><affiliation>ISOGEN</affiliation></member>
-<member><name>Eve Maler</name><affiliation>ArborText</affiliation></member>
-<member><name>Tom Magliery</name><affiliation>NCSA</affiliation></member>
-<member><name>Murray Maloney</name><affiliation diff="chg">SoftQuad, Grif
-SA, Muzmo and Veo Systems</affiliation></member>
-<member><name diff="chg">MURATA Makoto (FAMILY Given)</name><affiliation>Fuji
-Xerox Information Systems</affiliation></member>
-<member><name>Joel Nava</name><affiliation>Adobe</affiliation></member>
-<member><name>Conleth O'Connell</name><affiliation>Vignette</affiliation>
-</member>
-<member><name>Peter Sharpe</name><affiliation>SoftQuad</affiliation></member>
-<member><name>John Tigue</name><affiliation>DataChannel</affiliation></member>
-</orglist>
-</inform-div1>
-<inform-div1 id="sec-core-wg" diff="add">
-<head>W3C XML Core Group</head>
-<p>The second edition of this specification was prepared by the W3C XML Core
-Working Group (WG). The members of the WG at the time of publication of this
-edition were:</p>
-<orglist>
-<member><name>Paula Angerstein</name><affiliation>Vignette</affiliation></member>
-<member><name>Daniel Austin</name><affiliation>Ask Jeeves</affiliation></member>
-<member><name>Tim Boland</name></member>
-<member><name>Allen Brown</name><affiliation>Microsoft</affiliation></member>
-<member><name>Dan Connolly</name><affiliation>W3C</affiliation><role>Staff
-Contact</role></member>
-<member><name>John Cowan</name><affiliation>Reuters Limited</affiliation>
-</member>
-<member><name>John Evdemon</name><affiliation>XMLSolutions Corporation</affiliation>
-</member>
-<member><name>Paul Grosso</name><affiliation>Arbortext</affiliation><role>Co-Chair</role>
-</member>
-<member><name>Arnaud Le Hors</name><affiliation>IBM</affiliation><role>Co-Chair</role>
-</member>
-<member><name>Eve Maler</name><affiliation>Sun Microsystems</affiliation>
-<role>Second Edition Editor</role></member>
-<member><name>Jonathan Marsh</name><affiliation>Microsoft</affiliation></member>
-<member><name>MURATA Makoto (FAMILY Given)</name><affiliation>IBM</affiliation>
-</member>
-<member><name>Mark Needleman</name><affiliation>Data Research Associates</affiliation>
-</member>
-<member><name>David Orchard</name><affiliation>Jamcracker</affiliation></member>
-<member><name>Lew Shannon</name><affiliation>NCR</affiliation></member>
-<member><name>Richard Tobin</name><affiliation>University of Edinburgh</affiliation>
-</member>
-<member><name>Daniel Veillard</name><affiliation>W3C</affiliation></member>
-<member><name>Dan Vint</name><affiliation>Lexica</affiliation></member>
-<member><name>Norman Walsh</name><affiliation>Sun Microsystems</affiliation>
-</member>
-<member><name>François Yergeau</name><affiliation>Alis Technologies</affiliation>
-<role>Errata List Editor</role></member>
-<member><name>Kongyi Zhou</name><affiliation>Oracle</affiliation></member>
-</orglist>
-</inform-div1>
-<inform-div1 diff="add">
-<head>Production Notes</head>
-<p>This Second Edition was encoded in the <loc href="http://www.w3.org/XML/1998/06/xmlspec-v21.dtd">XMLspec
-DTD</loc> (which has <loc href="http://www.w3.org/XML/1998/06/xmlspec-report-v21.htm">documentation</loc>
-available). The HTML versions were produced with a combination of the <loc
-href="http://www.w3.org/XML/1998/06/xmlspec.xsl">xmlspec.xsl</loc>, <loc href="http://www.w3.org/XML/1998/06/diffspec.xsl">diffspec.xsl</loc>,
-and <loc href="http://www.w3.org/XML/1998/06/REC-xml-2e.xsl">REC-xml-2e.xsl</loc>
-XSLT stylesheets.  The PDF version was produced with the <loc href="http://www.tdb.uu.se/~jan/html2ps.html">html2ps</loc>
-facility and a distiller program.</p>
-</inform-div1>
-</back></spec>
diff --git a/tclxml-3.2/examples/tclxml/flatten.tcl b/tclxml-3.2/examples/tclxml/flatten.tcl
deleted file mode 100755
index 48e1d44..0000000
--- a/tclxml-3.2/examples/tclxml/flatten.tcl
+++ /dev/null
@@ -1,316 +0,0 @@
-#!/bin/sh
-# -*- tcl -*- \
-exec tclsh8.3 "$0" "$@"
-
-# flatten.tcl --
-#
-#	Parse a DTD, resolve all external entities, parameter
-#	entities and conditional sections and save the result.
-#
-# Copyright (c) 2000 Zveno Pty Ltd
-# http://www.zveno.com/
-# 
-# Zveno makes this software and all associated data and documentation
-# ('Software') available free of charge for any purpose.
-# Copies may be made of this Software but all of this notice must be included
-# on any copy.
-# 
-# The Software was developed for research purposes and Zveno does not warrant
-# that it is error free or fit for any purpose.  Zveno disclaims any
-# liability for all claims, expenses, losses, damages and costs any user may
-# incur as a result of using, copying or modifying the Software.
-#
-# CVS: $Id: flatten.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-# Allow the script to work from the source directory
-set auto_path [linsert $auto_path 0 [file dirname [file dirname [file join [pwd] [info script]]]]]
-
-# We need TclXML
-package require xml 2.0
-
-# Process --
-#
-#	Parse a XML document or DTD and emit result
-#
-# Arguments:
-#	data	XML text
-#	type	"xml" or "dtd"
-#	out	output channel
-#	args	configration options
-#
-# Results:
-#	Data is parsed and flattened DTD written to output channel
-
-proc Process {data type out args} {
-    global elementDeclCount PEDeclCount AttListDeclCount CommentCount
-    global config
-    set elementDeclCount [set PEDeclCount [set AttListDeclCount [set CommentCount 0]]]
-
-    # Create the parser object.
-    # We want to use the Tcl-only parser for this application,
-    # because it can resolve entities without doing full
-    # validation.
-
-    set parser [eval ::xml::parser \
-	    -elementstartcommand ElementStart \
-	    -validate 1 \
-	    $args \
-	    ]
-
-    if {$config(wantElementDecls)} {
-	$parser configure -elementdeclcommand [list ElementDeclaration $out]
-    }
-    if {$config(wantPEDecls)} {
-	$parser configure -parameterentitydeclcommand [list PEDecl $out]
-    }
-    if {$config(wantAttListDecls)} {
-	$parser configure -attlistdeclcommand [list AttListDecl $out]
-    }
-    if {$config(wantComments)} {
-	$parser configure -commentcommand [list Comment $out]
-    }
-
-    switch $type {
-	xml {
-	    # Proceed with normal parsing method
-	    $parser parse $data
-	}
-
-	dtd {
-	    # Use the DTD parsing method instead
-	    $parser parse $data -dtdsubset external
-	}
-    }
-
-    # Clean up parser object
-    #$parser free
-    #rename $parser {}
-
-    return {}
-}
-
-# ElementStart --
-#
-#	Callback for the start of an element.
-#
-# Arguments:
-#	name	tag name
-#	attlist	attribute list
-#	args	other information
-#
-# Results:
-#	Returns break error code, since we don't
-#	care about the document instance, only the DTD
-
-proc ElementStart {name attlist args} {
-    return -code break
-}
-
-# ElementDeclaration --
-#
-#	Callback for an element declaration.
-#
-# Arguments:
-#	out	output channel
-#	name	tag name
-#	cmodel	content model specification
-#
-# Results:
-#	Writes element declaration to output channel
-
-proc ElementDeclaration {out name cmodel} {
-    global elementDeclCount
-    incr elementDeclCount
-
-    regsub -all "\[ \t\n\r\]+" $cmodel { } cmodel
-    puts $out "<!ELEMENT $name $cmodel>"
-
-    return {}
-}
-
-# PEDecl --
-#
-#	Callback for a parameter entity declaration.
-#
-# Arguments:
-#	out	output channel
-#	name	PE name
-#	repl	replacement text
-#
-# Results:
-#	Writes info to stderr
-
-proc PEDecl {out name repl args} {
-    global PEDeclCount
-    incr PEDeclCount
-
-    if {[llength $args]} {
-	puts $out "<!ENTITY % $name PUBLIC \"[lindex $args 0]\" \"$repl\">"
-    } else {
-	puts $out "<!ENTITY % $name \"[string trim $repl]\">"
-    }
-
-    return {}
-}
-
-# AttListDecl --
-#
-#	Callback for an attribute list declaration.
-#
-# Arguments:
-#	out	output channel
-#	name	element name
-#	attname	attribute name
-#	type	attribute definition type
-#	dflt	default type
-#	dfltval	default value
-#
-# Results:
-#	Writes info to stderr
-
-proc AttListDecl {out name attname type dflt dfltval} {
-    global AttListDeclCount
-    incr AttListDeclCount
-
-    puts $out "<!ATTLIST $name $attname $type $dflt $dfltval>"
-
-    return {}
-}
-
-# Comment --
-#
-#	Callback for a comment.
-#
-# Arguments:
-#	out	output channel
-#	data	comment data
-#
-# Results:
-#	Writes info to stderr
-
-proc Comment {out data} {
-    global CommentCount
-    incr CommentCount
-
-    puts $out "<!--${data}-->"
-
-    return {}
-}
-
-# Open --
-#
-#	Manage opening document in GUI environment
-#
-# Arguments:
-#	None
-#
-# Results:
-#	XML or DTD document opened and parsed
-
-proc Open {} {
-    global currentDir status
-
-    set filename [tk_getOpenFile -parent . -title "Open Document" -initialdir $currentDir -defaultextension ".xml" -filetypes {
-	{{XML Documents}	{.xml}	}
-	{{DTD Files}		{.dtd}	}
-	{{All File}		*	}
-    }]
-    if {![string length $filename]} {
-	return {}
-    }
-
-    set currentDir [file dirname $filename]
-    set savename [file join [file rootname $filename].dtd]
-    set savename [tk_getSaveFile -parent . -title "Save DTD" -initialdir $currentDir -initialfile $savename -defaultextension ".dtd" -filetypes {
-	{{XML Documents}	{.xml}	}
-	{{DTD Files}		{.dtd}	}
-	{{All File}		*	}
-    }]
-    if {![string length $savename]} {
-	return {}
-    }
-
-    set status Processing
-    set oldcursor [. cget -cursor]
-    . configure -cursor watch
-    grab .elementDecls
-    update
-
-    set ch [open $filename]
-    set out [open $savename w]
-    if {[catch {Process [read $ch] [expr {[file extension $filename] == ".dtd" ? "dtd" : "xml"}] $out -baseurl file://[file join [pwd] $filename]} err]} {
-
-	tk_messageBox -message [format [mc {Unable to process document "%s" due to "%s"}] $filename $err] -icon error -default ok -parent . -type ok
-    } else {
-	tk_messageBox -message [mc "DTD Saved OK"] -icon info -default ok -parent . -type ok
-    }
-
-    close $ch
-    close $out
-    set status {}
-    grab release .elementDecls
-    . configure -cursor $oldcursor
-    return {}
-}
-
-### Main script
-
-# Initialize message catalog, in case it is used
-package require msgcat
-namespace import msgcat::mc
-catch {::msgcat::mcload [file join [file dirname [info script]] msgs]}
-
-# Usage: flatten.tcl file1 file2 ...
-# "-" reads input from stdin
-# No arguments - Tk means read from stdin
-# Files read from stdin assumed to be XML documents
-# When given files to read, all output goes to stdout
-# No arguments + Tk means use GUI
-
-switch [llength $argv] {
-    0 {
-	if {![catch {package require Tk}]} {
-	    # Create a nice little GUI
-	    array set config {wantElementDecls 1 wantPEDecls 0 wantAttlistDecls 1 wantComments 0}
-	    checkbutton .wantElementDecls -variable config(wantElementDecls)
-	    label .elementDeclLabel -text [mc "Element declarations:"]
-	    label .elementDecls -textvariable elementDeclCount
-	    checkbutton .wantPEDecls -variable config(wantPEDecls)
-	    label .peDeclLabel -text [mc "PE declarations:"]
-	    label .peDecls -textvariable PEDeclCount
-	    checkbutton .wantAttListDecls -variable config(wantAttListDecls)
-	    label .attListDeclLabel -text [mc "Atttribute List declarations:"]
-	    label .attListDecls -textvariable AttListDeclCount
-	    checkbutton .wantComments -variable config(wantComments)
-	    label .commentLabel -text [mc "Comments:"]
-	    label .comments -textvariable CommentCount
-	    label .status -textvariable status -foreground red
-	    grid .wantElementDecls .elementDeclLabel .elementDecls
-	    grid .wantPEDecls .peDeclLabel .peDecls
-	    grid .wantAttListDecls .attListDeclLabel .attListDecls
-	    grid .wantComments .commentLabel .comments
-	    grid .status - -
-	    . configure -menu .menu
-	    menu .menu -tearoff 0
-	    .menu add cascade -label [mc File] -menu .menu.file
-	    menu .menu.file
-	    .menu.file add command -label [mc Open] -command Open
-	    .menu.file add separator
-	    .menu.file add command -label [mc Quit] -command exit
-	    set currentDir [pwd]
-	} else {
-	    Process [read stdin] xml stdout
-	}
-    }
-    default {
-	foreach filename $argv {
-	    if {$filename == "-"} {
-		Process [read stdin] xml stdout
-	    } else {
-		set ch [open $filename]
-		Process [read $ch] [expr {[file extension $filename] == ".dtd" ? "dtd" : "xml"}] stdout -baseurl file://[file join [pwd] $filename]
-		close $ch
-	    }
-	}
-    }
-}
diff --git a/tclxml-3.2/examples/tclxml/simple.tcl b/tclxml-3.2/examples/tclxml/simple.tcl
deleted file mode 100644
index ff80206..0000000
--- a/tclxml-3.2/examples/tclxml/simple.tcl
+++ /dev/null
@@ -1,36 +0,0 @@
-#!/bin/sh
-# -*- tcl -*- \
-exec tclsh "$0" "$@"
-
-# simple.tcl --
-#
-#	Count the characters in a XML document,
-#	from README.
-#
-# Copyright (c) 2008 Explain
-# http://www.explain.com.au/
-#
-# $Id: simple.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require xml 3.2
-
-
-set parser [xml::parser]
-$parser configure -elementstartcommand EStart \
-    -characterdatacommand PCData
-
-proc EStart {tag attlist args} {
-    array set attr $attlist
-    puts "Element \"$tag\" started with [array size attr] attributes"
-}
-
-proc PCData text {
-    incr ::count [string length $text]
-}
-
-set count 0
-$parser parse [read stdin]
-
-puts "The document contains $count characters"
-exit 0
-
diff --git a/tclxml-3.2/examples/tclxml/xmlwc b/tclxml-3.2/examples/tclxml/xmlwc
deleted file mode 100755
index fdbea35..0000000
--- a/tclxml-3.2/examples/tclxml/xmlwc
+++ /dev/null
@@ -1,85 +0,0 @@
-#!/bin/sh
-# \
-exec tclsh8.3 "$0" "$@"
-
-package require xml
-
-set bytes 0
-set chars 0
-set words 0
-set lines 0
-
-proc cdata {data args} {
-    global bytes chars words lines
-
-    incr bytes [string bytelength $data]
-    incr chars [string length $data]
-    incr lines [regsub -all \n $data {} discard]
-    regsub -all "\[ \t\r\n\]+" [string trim $data] { } data
-    incr words [regsub -all { } $data {} discard]
-
-    return {}
-}
-
-set format {%1$7d%2$8d%3$8d %5$10s}
-
-set input {}
-foreach opt $argv {
-    switch -- $opt {
-	--bytes {
-	    set format {%4$7d}
-	}
-
-	-c -
-	--chars {
-	    set format {%3$7d}
-	}
-
-	-w -
-	--words {
-	    set format {%2$7d}
-	}
-
-	-l -
-	--lines {
-	    set format {%1$7d}
-	}
-
-	-h -
-	--help {
-	    puts stderr "$argv0 \[-clw\] \[--bytes\] \[--chars\] \[--words\] \[--lines\] \[--help\] \[--version\] \[file...\]"
-	    puts stderr "Counts number of bytes, characters, words and lines in an XML document"
-	}
-	--version {
-	    puts stderr "xmlwc version 1.0"
-	}
-
-	default {
-	    lappend input $opt
-	}
-    }
-}
-
-if {![llength $input]} {
-    set p [xml::parser -characterdatacommand cdata]
-    if {[catch {$p parse [read stdin]} err]} {
-	puts stderr $err
-	exit 1
-    }
-} else {
-    foreach in $input {
-	if {[catch {open $in} ch]} {
-	    puts stderr "unable to open file \"$in\""
-	    exit 1
-	}
-	set p [xml::parser -characterdatacommand cdata]
-	if {[catch {$p parse [read $ch]} err]} {
-	    puts stderr $err
-	    exit 1
-	}
-	catch {close $ch}
-    }
-}
-
-puts [format $format $lines $words $chars $bytes $input]
-exit 0
diff --git a/tclxml-3.2/examples/tclxslt/Libxslt-Logo-180x168.gif.b64 b/tclxml-3.2/examples/tclxslt/Libxslt-Logo-180x168.gif.b64
deleted file mode 100644
index 2016ea5..0000000
--- a/tclxml-3.2/examples/tclxslt/Libxslt-Logo-180x168.gif.b64
+++ /dev/null
@@ -1,183 +0,0 @@
-R0lGODlhtABEAPf/AP///wAAAP7+/vz8/AUKAjU1Mvv7+729vd7e3SwtKWJi
-XPb29pKTjpSVkUtMSoODfIuMiXFyb/T09La2sYmKhpmaldnZ2BscGtHRzdXV
-1fPz8yQmI9LS0c3NyeHh4ZydmWprZDs8OdnZ1UtSUubm5sXFweTk5P39/Q4O
-DcnJxfj4+FlaVTEyLsHBvL6+ufDw8BMWEnR1ckNFQtXV0YGCgPLy8rm5sQAE
-ACwwKu7u7qysqvL18SgqJnFycAACALm5rFFSTbKyprW1ruTl4q2tpTk5N0RL
-TKGhnaSkoezs7DtFRm9wbcrKyMHBudzc2icpJPr6+s7OzElKRuDg3mxuah4i
-HWVmZMnJwgIHAGpsaenp6FZYVn1+fOjo5rGxrhEWDmRlYrm6tcbGw8LCwMzM
-xfb49cXFvXp8eYSFgl1dWO3u7KmpoXh5djI1L7Gxqebm5GFiYHx9el1eXKam
-mu/x7qampcDAtOrq6hQYE3d4dWdoZYKDgaWlnXZ2dO7w7uzs6mlqaH+Afvv6
-+L29tnl7eKCgmvP18qqqpTY4NX19cV9gXebp6mJjYVpaWXJ0cQ4SDPX29KCg
-lVpcWr29sfPz8lpdXebo5oWHhOrs6UFDP5eYlFdXVSEjHqqqnff69ldaWcXF
-uVVVUXt7cFFSUOnr6Pn8+EZIRK6uoo6QjBgYFlBUU4eIhQoKCU5QTK6vq1FX
-Vezu6+js7dDQysjIvbq7uUFHSfHx8ba2qAsPCaeno/X19V1hYL6/vMfIxejq
-5z4/PAQHAQMDA0lPUC02NgwMC6GioOTm5AYLBCYrKNrb2dbZ2s3S1OLl4dPT
-zp2fnH19duzu7qKkoSAlIwYGBry8uS8wLICAdczMwvv8+fz7+G1ubAgMBuHm
-6d/j5vH08NfX1re3taOjnVNXV8/PxwIFALOzq8/Qz9jc3fj799PT09PW1J6e
-j+3w8fb6+szMyvP29v3+/MPEvmJlZdvf4MPEw6Sjm4iHgrO0ruDi36+vp29y
-cPv7+gIGApCQjQIIAICAgCH5BAEAAP8ALAAAAAC0AEQAAAj/AP8JFBjIkYNq
-wQIoXMiwocOHECNKnEixosWLGDM+DFbNgaNAA0MK5MJCo8mTKFOqXImSBReR
-Aq2wChBsVJ0oJwDo3Mmzp8+fQIMKHUq0qNGjSJP2PBGlzqiErKyIbKTwCROl
-WLNq3cq1K1YmTxQ2GthDYY8FXtOqXcu27c4FZQP0+BcoVYBNQAUIODHAgN+/
-gAMLHkzY74ABJwS4Xcx466YAqQItCTCNhM+9UFQskKChhufPoEOLHk1agwRd
-C1Qgbsy69VAS0wIscRCgkc8TBlRIeJFECwkSJoILH068uHHjv+/kqJF6gGLX
-0KNTdbAhQJ2lUBa84BBIBp4v4MOL/x9Pvrz5Lyz0gJtCQo0E1c+jt93b93B8
-AYcNx+daJ8AGFAFYwJMAUOiShDPAsBSADwv64KAPN0QoIYQKabPMFHdooBpQ
-fBkAxYdQGLCafEOdkF0NL9iyABQ5DXBiiivm1JUFAQAYgC074beAGhEEcEMA
-MJiygiRpFJmGHEgamYYkK6ywySahjAJEK604IIUpMsiQSSa//BJCEYggwgIM
-EQaATAYI3CEBFPvpZOIClOSghho55EBJcyTmZYAJzmThgAlJ6OIcFOn0+Weg
-A3hlC0M8naCCLWP4CIwpFLhCTQkliNFLCleQkUIKvYiBqRkt8EINLWFMcI8X
-ruiQSx1IFP/jzAcVaNIAA5c4sgIiuPwIQToe5LBAoj0NAE4gcbCRRx95IGFC
-F8ISm+eAKgQCYBHNIKCGCgIsYG0A2GqrQlqM7jSALiaUBAwjubiAiSCC7IPN
-vPTWi40n+HpSRhmQQKKLIYa80w6/ZRjiRw5+qBHLOQzA4cAjN/gwwTckaMDm
-gFDUEIdCF1TAQwAJMDGFGgvkpFebRp38k14DqrzTCbpoEUIABZSQDgklLyAz
-zVdkgDO5C+WY8QcLrrAGE2XAg00p2TSdTSlQoyM1Ovl6gg06/QJsSBmW0MPq
-BPh4U2ed7MTiChy/YBEAIFFMkYMKMu4ERQ65KFQAKA8oBETbwmr/hpoKKmS2
-wAK6FI5aaoAnPvjfIg6wj9+DB55d4c31tUAOQxRB8yBMeLCAALq8oXkBTZDh
-hLCpDR554iMOVS4AjuawxQ3HoHEPHfCoULW++/LbLyQAl+GHOk7sYMgOO5Tx
-DSpxnBFHHkfMCUssi/gSiyU0jNLrL704kUTJPc2NhEIsTGKHQijE08wQakSh
-QzJ30PlCDnf49lsXWiiXQ4rzuw9/DraogS2mkIwuHIIE+svBAXSQPzt1JgqH
-cAIiAsCCCYhhCp9bQOYoaAcbfGAKXbjDHTAhQuWkiDkXc13Q3LSAJLQBC6mo
-wAxKsa/fZU1rAAOeISDRhQoEggZjKIM3/yCRAntwgQZ72AMN0IAAaCziiU+M
-RS/gUIUbcGIM3+iCBKSlEwPkYHwUvMUkFjKJFLgiBA7QQwC2gAFmAAJ9mlNI
-DKJwgQCc4Q1i+AUK+oACPWBgCG+gAAoakACQJWMKdbhAAvSwRw+8oQtZCIAU
-QgEgFtyjBBgEwAJEBxna1MgVLSikJDuwChRUIxkqiltQXncuLbTBB09YAyYK
-hsNaGg8SdABeGcBBCBoQAgne8IYvGBAHGhiTBoFogCViwUzqcYMb3eBCAnxQ
-BV74bIvF+qJCqnGLSChkA5OwAYBKgIFQgGsGM6gjD2YBAoUMggwV2IQIOlDH
-CoyDCgGAwxXqGP8AHoQlAJo4RI3MMI4JQkAEMQjABcZxjbBYEpNoWQAJNJeK
-U0AAQCgYRwUUQgUyYEAK7piCFjTARaCwUgIkeOUT3ECHf9VSa8ijQxj60Ysy
-0KECR4wDEuhgCGqc4Zh7QEMgeAGNeShjGeo4RzeoBwEeUPMAPtOAAbIJxg08
-oCQBEMUkWsGza1BAIWy4Bj4DMIc5KAQEZsgCBGYQCIXMwgZhQQEZWqAQBzSg
-RjYAAs1m8QEAyWAcdQTCLGZRAAoKAaKanCgFzbcChTxgFnV8QhOuAIcMiBSb
-KlSIuVCqUi/QYQfBDK1ok8eLPORBE3TwgybiEAhCuMIbpFgtEvdwBjj/wMEL
-H0BDsmJACFTUgRc0mGYVDnAzqVJVIalQBAtCgIYwNKGOpDNDPhTSClDYQCGh
-uEV1wNkIj5qCfCwIbyuucA2FKCAIH3CDGTAaXha0AQTTDYAe7ACKwrLgsJmU
-qOZY8AM75C0ACrCDFRQyh0DkAQMe+J4qTbpCAAxAAymF5T0ASAc6BNPCFgat
-IZDABi6gAR+Q0EGHCdELQzgBDUo0CB6IgYYGEIIQeXDEErJgBTgwwgoseGpx
-p8qTAWgzANU4BRHu4QIxkIF8kzBDeRdrh0xAZh2cUAgDNiEGWUwwAD+4xQTC
-UIIUHBnA+RBCC65Avh+UwwZNmAUDFAIG+tp3/wK9yK9iWYDmNQPYBmYFsBTu
-EQUPvIBbRHmdASCs0nuoIbV+qLCivaE1EXNhD06AxDdo0Ack/CEHCEBDKFjw
-CIUEAglK5AIbYtCDGeuBEWDI8XB3XKwXgDHI5WgBBr6RTsgk+ctSQPN/qwEB
-8jVADOVUSCRs4IJeoLMZ5i0HL6LQjDqm4gc2aEEHMHDXu6T5zZjURWL3awcz
-VFsUNmiyf6QwCHOQQFBFETShJXzpsY3NG98oBtJ6wYYzMDG1OugHPvyAiW9w
-VSHbiEMdkkgDUZPa1GDAsY4rxuOdeDEc21zDBNzhgS4gwJwByIcZyBwAKtgg
-HikA0AZuUQ3ITICcG/+7cxPcEQMLzMC8h/1GMjBuj2iPIRDj+KabDTsGBGig
-W3PudjuJkYswxIMN5g2DObrwuXQ3eNAR5sE9SKEGWMBiTmp4AT5QoY9LMIMO
-94gBAzDxB0x0oT3JaEE+glsFRTQgFxC4RKhHXeos6CHhqiYuw8OnhiNskwgu
-+IZ7usAEAIGhCWig4ARc4A4MKALAt1BAAORgg15kYAYfAzAEFBGDZHA8FHBG
-gAdoASBiLAEViPgABgobADBYQ+QKKIHPga45cDahsAqYwBii0AIA9YMWHLgD
-FIyi7qjfowuw+AMp/sB8P3wjEGdgAy8M8QdwpAAWy6cDCTpQjjUcwg2HQML/
-BIoBAQrIveB0R7jCV713nkDBGfwEMiYtZgsEIKEAKGjEExzgChcwwQLJAA4B
-EA42UAgBUAhjwAEI4ATxwHqTlwFMEH+/0Dkk4ARIwE8oQAgzwAHhwE+M8AsB
-YApocEEacAI6UwSAcAEOoEdgQA2ylgwiMAoXYANYpAYltUpPt25PcA+W4Atd
-4AukEITKpwnLggRq8AcHk2gIUAyAsIJFICR74AyawACoEHdzd3B2h3cLZ1w5
-ogJq4AQpEAb3EAYUJ1U6kwwdoAOocHIlEAVOQAJdMAUf0At06Ay9wAEg1AVO
-4A65QAFeIAYcQGtM4AJh4ALmACgk8A29UAEUUGwc/5ABzSAGEJAPNnAERBAG
-CYgzjqIGxeAOJQABFVACYwCIHkACUwABrdAC7oAANbBgOKhZXbRuPOAFj2QJ
-lvCDPpgDvXAGSxANypcDb8ALFFAAP9IQx/ALaFABVXh+Bld3d7d+eseFDgdh
-FhAFTGAOCKBgAyABdzAFGZAOHJAOFpBgEkAJSWACC5iOgKIBGnAHCMABTOAO
-6eAEHjAFFoABUZAOIyMBNUACyWAO8ZgOCGACHmAB5uAOKcAETBAFGeBn3AJ1
-yTADGGAO6ZABTgAo3dgDq2B5P0N8ORh1XsAMJGCLJGmLmNALDcAEFSYGjIAL
-CuEPBBCTMqk2eLAKDGB+Sv+0Wz1ABVmYalvYcDoxAI+iBR5QioFiAHphAJej
-BcFBAkmgIi6yALbgbi/AHH5xOaY4BSagBXTClCbQHrqQGRJwjlPAHknwArxB
-AvVYllv5AsMCOypQA0kAHKXYHp4hTQGwkNoyfB4JiwAAdSrlBswwBIM5BIZp
-mG/gC+0RBVlQRzcADDIZmTIZACugCRSAYsgyahFABYBwdz7JftKoE/gxOaeh
-AgYgI6O5GRLQHCbTF4ADIvYBO9nRGRqAOISzmqqRGEKpC56xmn6hGbSJm1Dg
-HACwF0q5GaaBODUAgjLABOlgAjVwg68YANMYYU9ABAjwG29wmMawnYOZDLTh
-A5L/OZ4xSZkVsAooxgWEoJmc6Zl5x2pZ4TI9gTLzyTJEcTJtgp9BgZ8sYwCU
-UAeO4AVRkAxa0HR9SZ2xGGHIkAsTEA8YkAxOgAAIkAwZMJHuIAcBAJnkKZlY
-4AMtdglogH6jtgScaQWo9p7txxj0gRj02Rj0kRgOJgF6+A0WYAK2AJSB9pGv
-xANIQARE4AZb5gK80AJNMGYfECEbKpnA4ANw4Ao4GQii1gfOWGOfGY04qhX8
-aZzASQm1iZStkZrlyByqMQDa0QXP4pauKBTFt6PhcAhEkA/lcA82YAPUwAu8
-kAKTkaSRqTaqQAuogJ57AH3s2ZlgYGMoGppukh+N8xcs/1osk/M3m/ECfyAC
-FAAIJkAy0qkWAqCUcaIF4CAJ4KAFNQA3u6kBurAhSLGmN/AEhZALbuoGcToB
-NlCIvPBdelqe/LACRGCZqxBqhNAHMbCZhGpb1fCT2AEn8+Nuy7EAXhqUUqkD
-YUACXCmHZzAz4NIMbsOXi0GmYwABjcBPFWABJCABJsMXMJoUqroBH8AHrnoK
-+QCr97Bl9zBNevojCdAA99AAFHCZgbpbMlaiYKAIu4ADxpojAzAByPIqSIAE
-DdAHbGABbkksjjIFJXcXIoAAnrQQBdAC6dAF48IYA0APDgEBKYAAL5AoenEC
-Ktui01mdbXADG1ABR1AP7Oqj7/9aDkJQDoggnuSZIDDABq7KAOXXqwUXfQc3
-rIoABwQLmkBJIGMQSQ1xAXDgDl2AbjGKoQvxALIgAtQQf9UgBExgAmjBGBkz
-BAmVtS6QATa4qZrRHCz7E+mqCc5QCDTrqj76pkLwGOSJBcAgBQwQBpqAClXI
-r5kppSQKCCYKBwK7tFaKMbYwBAPGEESwbCaAWV5krealPjNwZSBDBIgFshIw
-BAa4EM8wARyQBH6hC0fABXcQsamqozDbABVQAc4ws+x6CLgbdhmqpD4QA2EQ
-DgzQAA2ACiC6ClAKY8G6BITKCIogB5XAuPApmgNACWbbEKcQBlGAM8QyN3nA
-EPbgAhj/sLkLkQBrMAaZxBgm2AWjqxCiIASnqwK64AQoEALJYAIvoK1O55eA
-CbMMoAma8AEfUAjhQLNIkAtEgAq4gAWRCQz84HG24mJbUAQbkABbQFuj9q+I
-W6iKUAnPW7AvowskcLYLMQemK3zPYQAvgACPRwxWQATxkAEiEEcgcwokeBjO
-oRgpi58qmxhZOiCKihiOggl+txCJMAHNIKpOUEiI0AEWoAUfe6Aua0WoILya
-MLvOMLd0Ww+5oFeReQMXgAQPjAb89CM1+auOIKx3p7hyIAmSAL0puhMqoAUi
-rBD1AA4Z8AJx82AmMAPxYANCYANRgABTIMMJEARi4AT6UwOn/wo4C8COlPDI
-lLCat/nIqNE4mlEDY1OVg6MGYKQQiWADfyQCokQ6q/gCpwnFCfqynEABDBC8
-/lvFAAzAR9AA1TGTXwABmtAPDHAGCRyTPlANDZu8WYC0lbAFjZAAN8C0PgEF
-f9AHDTEH1GABOPIyKpAD+DADZNAHYfAN9UjIt2AGh8AsXsAeamALXqADFrCd
-M1AHddAFSeAKVJsBuQCxqCEBOUAL67kKSIABbXkHnRwA1mADsoAGNgJkP9AC
-HFAxcJO/CPqXhJbMqyC4wSu8DeC/syuzegAhMbmkrVABwgsHwKChAdAKqOAI
-pdaeGiwHn7AFn4AMydy44dPMzxzNNf9gsDsyBEegOQ3QkIO8EDAAAg4ILoec
-ARm7EEUgMhk7SNCSAx9QR0UgSiH4DYYJcQsR0JnnECiQDJjK0FFcBWgAARAg
-0RNN0RVdARGACzwLDDdQDa0gBXgg0hfAPD2AxmDAvBu8BeIgDi6tzDHtzAwB
-zRZQ026iAh4AAZiLCm6IADIMGVi1ECjgAjOQDK5Q0AHwAFfQDDG8Nr2AASBE
-CArBB1dwBVAbAGLwDQgwxJ5ciRQQf6ywAnIABgldA1cKt7BbBTSwCvsK1oLb
-D7rcysH7AVYAA2nNIAGgwATgA4/QYhGwBMqrB4m7wSv9Cq+w1zDtfjL91zRt
-LhlA2QFgDyX/YJEyzArrcAuaQNkOQE7NMBkLUQ2lgwEXAAgtIAbN4AF1QzOg
-EA+dkgYKAb4WgNoBkAhCcAXj4IA8MAeAxwFdQFJcncrJHAhogAaXgNsUANZh
-TeFV2ABcEGU+oKExqTYocAaoMNc8ibRrjNeq8Ao88NLRKzfXPcLZ3UWUkAGP
-UdWDwAGZrRA80AnlYAdzHAD1IAZRIAvxl1WgkAU80AJj4A7J4AGeRAynYAdi
-0AFXgH+DgAH9zRDtmwKrtxAF/odO4Lo5qr8PXQVxoERBBeGrIOH7uuar0A+r
-MApPcAwM8QgFEAiaoA/MPcxprLiVEN0joArUveI6wcx+7eKBvVlv/7C+/w3K
-N95PcyAE+E3ZaTAIjVdtyBUJKAABLfB/JjAEDLHKs9ABHSAGLVACpu3fojBx
-zcC5CVAPE2BuzPq2O6GqF8AGgXDrs/Xgug6iuh5UENAPcbAFXtIIDeAMkpHn
-epDGigDdW/AKI/Dsgf7Gg97iBPbisLMA6ovlAt3oCQDNzBbUQDBx39AMTrYQ
-qcACYdALTQyMDvEEhNAEHeAOeGgCqA7I3L4GvOAEtnCuYd7Q+3sBfXAGZ8AF
-XPBDQJVECH9MULoH+3oJEEADMna4zl3XfB7dqjACwjAC0qDi0g4AhD7Thy6a
-KiDE2r61hLwGpu4EPTK+bpACEDoBDdG+cf9WAxrQBd+F1SBABjPgASZA1ey7
-7SdvvmOLyg6dUl7cA2yQ9M5D8AX/Q0p061B6vC+WB6Q214cLCBlc8SaO8cIg
-DBvP19Zd6NUe2PSRG5xc8vdeAk4wBXOcAEQgBgOZDHq1ECtQDr3gAat5B64Q
-EQVABhYwBfVu8uNbvudL9P++BDEQA8yS9IQg8NCnB1lwBn3Q+KVGCI6gCIDQ
-BxEACFlAYya6BaMwCpLQ5yuwBRff9V3/9dXN4mJPVtSASkKZAex4Bz6fVUA/
-+LI3BGJPvmLgAXdQ2AzBCnMge6OKaYIEEXrQASKg6OAm+ApBvkL/un75YEZ/
-AVQQAT3gCIm/+IT/AAgJgAhF0AdUcgm/kAl5UABFgAyjEAMFoAhL8As9YAoX
-gAghoAgr3ezP3vVGYASqDxDpSGgwAMDgQSh/+gRgyHAOtWQ1VGiocujOkCMN
-A4iyIUtEkYYJ1pRAMGRhwxWHepnIQWKTxgAKXGRIsoDSmxk2FKSCGSBVE1kf
-NHL0CJKhyDFTFhxk2pSpxoMDNJBoc+MCICpLlkSI0MNRDDZt5CCBACFTAEC/
-pEjZUkwRjzN4Mll5xCVTiDP6wGwSp2rECGHCjNQyIu1GlQMCCTpNeLLhw2S2
-JAg9gsBJoaEdP4ZcI8bJkJcNQRBxRyJHLxREiGksxMSErRq0knWIZ0NU/zWY
-P65UyFw0JJESU3Q5JX4QqsEBEqjeSGUlSxYqWbVGoIIDVR5TjGTwCIHIVBEq
-caxUY5OqSiZyVFpdQLSlUl+/gQfXqmUYseKCTRvDnOMiWQ41HAhAk2ZEEKoh
-ojY76hDP8DEqAFYiuSedLpL4JYIrwNBIiia+qTAAPZpxp4QW7KCioVSCMIM3
-BG3AQMEAEgiiBCdeMGAAAYpr6jgAkusCEWAeUQQQPQAxErrocPjql1ZMiUGR
-AFoJQZI4JOEhC1NkwCWTUUYpgpAltvALMMHoU0IJPLCQ5oAMBsqPqf00OqWF
-ZO7ohaF+yGjmQIasCePFBxM4JQUnptAoFD5acP+iiwpQiOcKG1ZryB4ynGCG
-oXtkiWIGDK5hgaFMZmSxzz9FMKUhTm5p4gMTKFFhAB2faigqXbSg4gZgHNAD
-DCv08NVIKhyo4hdORjEFBDQ4MQWOJ0KAoZVG5ACjCEc22AIPHJAZJb4yazlz
-mGNukGKMb0iQAFamBFhAixhg6mSQGRCQgiEK4hln1AASscGdGR7kJAgxZtgD
-1UjccAeBZlCAg4wrrgBBo2qAEoGhAq7oQAQRMHgiAGLWEWI3jRIRwh0RItAo
-jWdQYOIOCd6MlccTFkjikABuSAAMMBhhBGcregYkFCYh2CKOOOQApI9QQpCj
-n1ZiYISQCEzR45cQMtn/JbBuz1QCGSwCyIIeC7TQBd2oNMjgApjSGKSF0AJ4
-oAkyltColQlSwAAFFHhy24wW0A6AE03WaCGDMRIIQI4SyOjAHpioEGOchlqx
-YQYRAuGYAjdc6EDuyMtJYQaaYdrEHQ9egCJW42Y1SAAVXpgCjgCA4UFanXG2
-XZs8uIjACip4jQAMQMCyYhd5KtFDkl2Q36WSV+Qz88wNtrkBDy+YQKCmE9KF
-ohgUevL+bb9hKiSKABy5JY3VCuj+AhDWIIKaCULQSA934ugeJgeuAKIhFBDh
-AQVJ5GMCvEDC/WByhAxkYH+Rq1vpXKYjHgkAClOhBy5u4IMNSGEFjZBEB+Xw
-/0FJcFAOHAxhIxrxiS2Ioy+h6BKZjDCf5ylhGFUARtcawAsOmOAFKsjRQVgX
-BSTcwwVu6MQc+JCPMLTgAxRAwwOEMAYvNKAFQjhFJOLQgBJEYRTxGIQN1rAE
-K8SgAja4xwTGwIEp1IEJHRiDJj7gDnBoIh4TIEIn7PEATYghBfd4hgIYoQcG
-9KIEY0gBByzgCk1MsYpxCOQ3koGBCiggDQwgAi3MYS6yvawhtojKAnIwBR2E
-C1ePwEMpTXlKVKISBqtkJSu/8AhYxhIXBMDCDQKgDVowwQlaaFkPV6cCW5jg
-G0yIhwtcwIsSuCMKHejFGMbQC0NmIAokcsEYmGDIZP+kwxwdYAITUtCLXujR
-HE4gQRLu4IFvRMEdhkTAI3vRAmOWgAnpSEcUehGPMYjBHeZIxzemQAItmCAZ
-04SnNb/hARIgwBzxCAM4eBGFKeRABdlDnS0Y0j0L+BAKEtCCE5wRAgLgCgsj
-JWlJTXpSlI4UGCtlKTDIgYUNxIEWvSjXDinqwwF4MqHJsIAFnOAEBEwBARb4
-hgUQYAISkMADTuhpMqaA0C4k1QQemAJTfeqBLthiAQuoQRJMMIWnkuAOXTBB
-O3taKKR6YKgZsIBTTaCFF0hAAy8gQVWb+k81vEANAs1AOpKhwwVkUkcWCAAK
-NhCAOjDlBMDsghOi8AE5tAH/B5OlbGUte1nMZhYHDrjEPcbgDguwZAEG8OVB
-TmCABWjAFquFTQ1W+wIAvcAWGtCFBlxrixfIVjK60MVWJWALNSQhCXF91QAG
-oILUrlYDEtCFXG+b29nK1Rbm1MJwNTDaARhABb/FLXSvqwIV6EKvatAqFG6K
-ujoEYAMCakS6jmsLLUzhG+boBT3GwAv8HkC/++Vvf/373wPg15m9cEcGEGCa
-BZi3OAJgMIOdIoATnGAAEW5whSEc4RMwOMLGNW5pAWBhC6/uwhrOrgFudF4Q
-V/jDAuAwjlDXlEYEwAFymwYJ3DsRNSh1qN/4RgJ9/GMgB1nIQS5qocpZ3vO+
-WMlL3mZyk5385KaQYBoBWEIgeLKJprAYCql9QRK0ENWkhlnMYyZzmcncherm
-oAa6eJWHofxmOMdZzk15SSoC8Y8eMKQHS3EvFJDbXAkEWtCDJnShDW3o3qoA
-ChN285wd/WhIO2UBeQ5AD/5x6RgH4AlMePCFW/xpUIda1KHOcKMjfWpUx5kJ
-GwtAIy79aiuwIgDBGEUdopDkVOda17uW8wmiUIdRBANCVnh1sbnwKe8lW9nL
-Znaznf1saEdb2tOWNgu4UGxsB8IRDqiGsKn9bXCHW9zjJjdMglENBzjizsUO
-CAA7
diff --git a/tclxml-3.2/examples/tclxslt/README b/tclxml-3.2/examples/tclxslt/README
deleted file mode 100644
index d56be16..0000000
--- a/tclxml-3.2/examples/tclxslt/README
+++ /dev/null
@@ -1,13 +0,0 @@
-examples/tclxslt/README --
-
-This directory contains example scripts to demonstrate
-the use of TclXSLT.
-
----------------------------------------------------------------------------
-See the file "LICENSE" for information on usage and
-redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
----------------------------------------------------------------------------
-
-tkxsltproc
-	A GUI version of libxslt's xsltproc.
-
diff --git a/tclxml-3.2/examples/tclxslt/common.tcl b/tclxml-3.2/examples/tclxslt/common.tcl
deleted file mode 100644
index ac3eb59..0000000
--- a/tclxml-3.2/examples/tclxslt/common.tcl
+++ /dev/null
@@ -1,510 +0,0 @@
-# common.tcl --
-#
-#	Common code shared between tkxmllint and tkxsltproc.
-#
-#	The master version of this file is in the TclDOM project.
-#
-# Copyright (c) 2005 Explain
-# http://www.explain.com.au
-# Copyright (c) 2004 Zveno
-# http://www.zveno.com/
-#
-# See the file "LICENSE" in this distribution for information on usage and
-# redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
-#
-# $Id: common.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require http
-
-# SetProperties --
-#
-#	Setup tag properties
-#
-# Arguments:
-#	win	toplevel window
-#	log	log window
-#
-# Results:
-#	Tag properties set
-
-proc SetProperties {win log} {
-
-    $log tag configure timing -background #bafdff
-    $log tag configure error -background #ff9d8d
-    $log tag configure errorhighlight -background #cd3030
-    $log tag configure related -background #ffe59f
-    $log tag configure relatedhighlight -background #e8b417
-    $log tag configure message -background #ffe59f
-    $log tag configure log -background #b9ffd4
-
-    return {}
-}
-
-# Browse --
-#
-#	Choose a file
-#
-# Arguments:
-#	win	toplevel window
-#	field	name of state variable field to update
-#	args	configuration options
-#
-# Results:
-#	Current file is set
-
-proc Browse {win field args} {
-    upvar \#0 State$win state
-
-    set w [expr {$win == "." ? {} : $win}]
-
-    array set opts {
-	-title {Select Document}
-	-type open
-	-command {}
-    }
-    array set opts $args
-
-    set cwd [pwd]
-    if {$state(cwd) != {}} {
-	set cwd $state(cwd)
-    }
-
-    switch -- $opts(-type) {
-	save {
-	    set fname [tk_getSaveFile -parent $win -title [mc $opts(-title)] -initialdir $cwd]
-	}
-	open -
-	default {
-	    set fname [tk_getOpenFile -parent $win -title [mc $opts(-title)] -initialdir $cwd]
-	}
-    }
-
-    if {![string length $fname]} {
-	return {}
-    }
-
-    set state($field) file:///$fname
-    set state(cwd) [file dirname $fname]
-
-    if {[string length $fname] && [string length $opts(-command)]} {
-	uplevel #0 $opts(-command)
-    }
-
-    return {}
-}
-
-# ReadAndParseXML --
-#
-#	Helper procedure to read an XML document from a file
-#	and parse it into a DOM tree.
-#
-# Arguments:
-#	win	toplevel window
-#	label	description of the document
-#	fname	filename of document to parse
-#	baseuri	base URI for document
-#	timearr	name of array for timing information,
-#		"start" entry must exist.
-#	args	additional options
-#
-# Results:
-#	Document read into memory.  Log messages provide feedback.
-#	Returns DOM document token.
-
-proc ReadAndParseXML {win label fname baseuri {timearr time} args} {
-    upvar 1 $timearr time
-    upvar \#0 State$win state
-
-    array set opts {
-	-noent 0
-	-nonet 0
-    }
-    array set opts $args
-
-    set state(externalentities) 0
-
-    Feedback $win [mc "Opening $label document \"$fname\""]
-    if {[string match http://* $fname]} {
-	FeedbackProgress $win 0
-	set state(start_download) [clock clicks -milliseconds]
-	if {[catch {::http::geturl $fname \
-			-command [list HTTPComplete $win] \
-			-progress [list HTTPProgress $win] \
-			-timeout 30000} token]} {
-	    tk_messageBox -message "unable to retrieve $label document \"$fname\" due to \"$token\"" -parent $win -type ok -icon error
-	    return -code error {}
-	}
-	::http::wait $token
-	if {[::http::status $token] != "ok"} {
-	    return -code error {}
-	}
-	set xml [::http::data $token]
-	::http::cleanup $token
-	set time(read) [clock clicks -milliseconds]
-    } else {
-	if {[catch {open $fname} ch]} {
-	    tk_messageBox -message "unable to open $label document \"$fname\" due to \"$ch\"" -parent $win -type ok -icon error
-	    return -code error {}
-	}
-	set time(open) [clock clicks -milliseconds]
-	Log timing $win "Opening $label document took [expr $time(open) - $time(start)]ms\n"
-
-	Feedback $win [mc "Reading $label document"]
-	# Take note of encoding information
-	set encoding {}
-	gets $ch xmldecl
-	set re ^[::sgml::cl $::xml::Wsp]*<\\?xml[::sgml::cl $::xml::Wsp]+(version[::sgml::cl $::xml::Wsp]*=[::sgml::cl $::xml::Wsp]*("|')[::sgml::cl ^"']+\\2)?[::sgml::cl $::xml::Wsp]*(encoding[::sgml::cl $::xml::Wsp]*=[::sgml::cl $::xml::Wsp]*("|')([::sgml::cl ^"']+)\\4)?[::sgml::cl $::xml::Wsp]*(standalone[::sgml::cl $::xml::Wsp]*=[::sgml::cl $::xml::Wsp]*("|')(yes|no)\\7)?[::sgml::cl $::xml::Wsp]*\\?>
-	if {[regexp $re $xmldecl discard allversion delimiter allencoding delimiter encoding allstandalone delimiter]} {
-	    if {[catch {fconfigure $ch -encoding $encoding} msg]} {
-		if {[catch {fconfigure $ch -encoding [string tolower $encoding]} msg]} {
-		    tk_messageBox -message "unable to read $label document \"$fname\" due to \"$msg\"" -parent $win -type ok -icon error
-		    return -code error {}
-		}
-	    }
-	}
-	set xml $xmldecl\n[read $ch]
-	close $ch
-	# Watch out for UTF-16 documents
-	if {[regexp "^(\xFF\xFE)|(\xFE\xFF)" $xml]} {
-	    set xml [encoding convertfrom unicode $xml]
-	}
-	set time(read) [clock clicks -milliseconds]
-	Log timing $win "Reading $label document took [expr $time(read) - $time(open)]ms\n"
-    }
-
-    Feedback $win [mc "Parsing $label XML"]
-    if {[catch {dom::parse $xml \
-	    -baseuri [uri_escape $baseuri] \
-	    -defaultexpandinternalentities $opts(-noent) \
-	    -externalentitycommand [list External $win]} doc]} {
-
-	if {[string match "unable to*" $doc]} {
-	    Log add $win $doc
-	} else {
-	    Log addXMLError $win $xml $doc
-	}
-	Feedback $win [mc "Parsing $label document failed"]
-	after 2000 [list Feedback $win {}]
-	return -code error {}
-    }
-    set time(parse) [clock clicks -milliseconds]
-    Log timing $win "Parsing $label document took [expr $time(parse) - $time(read)]ms\n"
-    set time(last) $time(parse)
-
-    if {$state(xinclude)} {
-	Feedback $win [mc "$label document XInclude processing"]
-	# TODO: handle doc in slave interp
-	if {[catch {dom::xinclude $doc} msg]} {
-	    Log addDocError $win $doc $msg
-	    Feedback $win [mc "$label document XInclude processing failed"]
-	    after 2000 [list Feedback $win {}]
-	}
-	set time(xinclude) [clock clicks -milliseconds]
-	Log timing $win "$label document XInclude took [expr $time(xinclude) - $time(last)]ms\n"
-	set time(last) $time(xinclude)
-    }
-
-    return $doc
-}
-
-# External --
-#
-#	Handle external entity references
-#
-# Arguments:
-#	win	toplevel window
-#	name	current parser
-#	baseuri	base URI of document
-#	uri	system identifier of referenced entity
-#	id	public identifier of referenced entity
-#
-# Results:
-#	This reference is logged.
-#	If loading of external entities is enabled then the entity is laoded as usual,
-#	otherwise an empty entity is returned.
-
-proc External {win name baseuri uri id} {
-    upvar \#0 State$win state
-
-    if {$state(nonet) &&
-	([string match http:* $uri] || [string match ftp:* $uri])} {
-	Log entity $win "external entity not loaded, network access not permitted: system ID \"$uri\" public ID \"$id\""
-	return {}
-    }
-
-    Log entity $win "external entity reference: system ID \"$uri\" public ID \"$id\""
-
-    incr state(externalentities)
-    # resume normal loading of external entity
-    return -code continue {}
-}
-
-# GetFilename --
-#
-#	Helper routine to retrieve resource filename
-#
-# Arguments:
-#	win	toplevel window
-#	entry	entry widget containing filename value
-#	field	member of state array containing URI
-#
-# Results:
-#	Returns filename.  If URI is not a valid file: URL,
-#	returns empty string and displays message.
-
-proc GetFilename {win entry field} {
-    upvar \#0 State$win state
-
-    set state($field) [$entry get]
-
-    if {[catch {uri::split $state($field)} spliturl]} {
-	# Try the URL as a pathname
-	set fname $state($field)
-	set state($field) file:///$state(field)
-    } else {
-	array set urlarray $spliturl
-	switch -- $urlarray(scheme) {
-	    http {
-		set fname $state($field)
-	    }
-	    file {
-		set fname $urlarray(path)
-	    }
-	    default {
-		tk_messageBox -message "\"$urlarray(scheme)\" type URLs are not supported" -parent $win -type ok -icon warning
-		return {}
-	    }
-	}
-    }
-
-    return $fname
-}
-
-# HTTPComplete --
-#
-#	HTTP download is finished
-#
-# Arguments:
-#	win	toplevel window
-#	token	http token
-#
-# Results:
-#	Set progress to completion
-
-proc HTTPComplete {win token} {
-    upvar \#0 State$win state
-
-    $state(progress) itemconfigure $state(progressbar) -state disabled
-    Log timing $win "Downloading document took [expr [clock clicks -milliseconds] - $state(start_download)]ms\n"
-
-    return {}
-}
-
-# HTTPProgress --
-#
-#	HTTP download is in progress
-#
-# Arguments:
-#	win	toplevel window
-#	token	http token
-#	total	total number of bytes to download
-#	current	number of bytes downloaded so far
-#
-# Results:
-#	Set progress bar
-
-proc HTTPProgress {win token total current} {
-    upvar \#0 State$win state
-
-    FeedbackProgress $win [expr ($current * 100) / $total]
-
-    return {}
-}
-
-# Log --
-#
-#	Manage the log window
-#
-# Arguments:
-#	win	toplevel window
-#	args	messages to display
-#
-# Results:
-#	Log window updated.
-
-proc Log {method win args} {
-    upvar \#0 State$win state
-
-    set w [expr {$win == "." ? {} : $win}]
-
-    switch -- $method {
-	clear {
-	    $state(messages).log configure -state normal
-	    $state(messages).log delete 1.0 end
-	    $state(messages).log configure -state disabled
-	}
-	view {
-	    set what [lindex $args 0]
-	    switch -- $what {
-		start {
-		    $state(messages).log see 1.0
-		}
-		end {
-		    $state(messages).log see end
-		}
-		default {
-		    return -code error "don't know how to view \"$what\""
-		}
-	    }
-	}
-	add {
-	    $state(messages).log configure -state normal
-	    $state(messages).log insert end [lindex $args 0]
-	    $state(messages).log configure -state disabled
-	    $state(messages).log see end
-	}
-	addXMLError {
-	    $state(messages).log configure -state normal
-
-	    set xml [lindex $args 0]
-	    set id 0
-	    $state(messages).log insert end [mc "Problems detected in document:\n"]
-	    foreach errormsg [lindex $args 1] {
-		foreach {domain level code node line message relatedLine dummy related1 related2} $errormsg break
-		lappend error($line) error$id
-		lappend related($relatedLine) related$id
-		$state(messages).log insert end $message [list error error$id]
-		if {[string index $message end] != "\n"} {
-		    $state(messages).log insert end \n
-		}
-		$state(messages).log tag bind error$id <Enter> [list ErrorHighlight $w $state(messages).log error$id $line $relatedLine]
-		$state(messages).log tag bind error$id <Leave> [list ErrorRemoveHighlight $w $state(messages).log error$id $line $relatedLine]
-		incr id
-	    }
-	    $state(messages).log insert end \n
-
-	    set linenum 1
-	    foreach line [split $xml \n] {
-
-		if {[info exists error($linenum)]} {
-		    $state(messages).log insert end $line "error errorline$linenum"
-		} elseif {[info exists related($linenum)]} {
-		    $state(messages).log insert end $line "related relatedline$linenum"
-		} else {
-		    $state(messages).log insert end $line
-		}
-		$state(messages).log insert end \n
-
-		incr linenum
-	    }
-
-	    $state(messages).log configure -state disabled
-	    $state(messages).log see end
-	}
-	addDocError {
-	    $state(messages).log configure -state normal
-
-	    set doc [lindex $args 0]
-	    foreach errormsg [lindex $args 1] {
-		foreach {domain level code node line message relatedLine dummy related1 related2} $errormsg break
-		$state(messages).log insert end $message
-		if {[string index $message end] != "\n"} {
-		    $state(messages).log insert end \n
-		}
-	    }
-
-	    $state(messages).log configure -state disabled
-	    $state(messages).log see end
-	}
-	addMessage {
-	    $state(messages).log configure -state normal
-	    $state(messages).log insert end [lindex $args 0] message
-	    $state(messages).log configure -state disabled
-	    $state(messages).log see end
-	}
-	timing {
-	    if {$state(timing)} {
-		$state(messages).log configure -state normal
-		$state(messages).log insert end [lindex $args 0] timing
-		$state(messages).log configure -state disabled
-		$state(messages).log see end
-	    }
-	}
-	entity {
-	    if {$state(display:entrefs)} {
-		$state(messages).log configure -state normal
-		$state(messages).log insert end [lindex $args 0] log \n
-		$state(messages).log configure -state disabled
-		$state(messages).log see end
-	    }
-	}
-	default {
-	    return -code error "unknown method \"$method\""
-	}
-    }
-
-    return {}
-}
-
-# ErrorHighlight -- Highlight an error
-
-proc ErrorHighlight {win log tag line related} {
-    $log tag configure $tag -background [$log tag cget errorhighlight -background]
-    $log tag configure errorline$line -background [$log tag cget errorhighlight -background]
-    $log tag raise errorline$line error
-    $log tag configure relatedline$related -background [$log tag cget relatedhighlight -background]
-    $log tag raise relatedline$related related
-
-    return {}
-}
-proc ErrorRemoveHighlight {win log tag line related} {
-    Feedback $win {}
-
-    $log tag configure $tag -background {}
-    $log tag configure errorline$line -background {}
-    $log tag configure relatedline$related -background {}
-
-    return {}
-}
-
-# Feedback -- Manage the feedback widget
-
-proc Feedback {win msg} {
-    upvar \#0 State$win state
-
-    set state(feedback) $msg
-    update
-
-    return {}
-}
-proc FeedbackProgress {win percent} {
-    upvar \#0 State$win state
-
-    $state(progress) coords $state(progressbar) 0 0 $percent 25
-    update
-
-    return {}
-}
-
-# Incr -- utility to increment a variable, handling non-existance
-
-proc Incr var {
-    upvar $var v
-    if {[info exists v]} {
-	incr v
-    } else {
-	set v 1
-    }
-
-    return $v
-}
-
-# This should be part of the uri package
-
-proc uri_escape uri {
-    # TODO: other characters must also be escaped
-    regsub -all { } $uri {%20} uri
-
-    return $uri
-}
-
diff --git a/tclxml-3.2/examples/tclxslt/count.xsl b/tclxml-3.2/examples/tclxslt/count.xsl
deleted file mode 100644
index 244bfd0..0000000
--- a/tclxml-3.2/examples/tclxslt/count.xsl
+++ /dev/null
@@ -1,32 +0,0 @@
-<xsl:stylesheet version='1.0'
-  xmlns:xsl='http://www.w3.org/1999/XSL/Transform'>
-
-  <xsl:template match='/'>
-    <xsl:text>The document contains </xsl:text>
-    <xsl:call-template name='add'>
-      <xsl:with-param name='nodes' select='//text()'/>
-    </xsl:call-template>
-    <xsl:text> characters.
-</xsl:text>
-  </xsl:template>
-
-  <xsl:template name='add'>
-    <xsl:param name='sum' select='0'/>
-    <xsl:param name='nodes' select='/..'/>
-
-    <xsl:choose>
-      <xsl:when test='not($nodes)'>
-        <xsl:value-of select='$sum'/>
-      </xsl:when>
-      <xsl:otherwise>
-        <xsl:call-template name='add'>
-          <xsl:with-param name='sum'
-            select='$sum + string-length($nodes[1])'/>
-          <xsl:with-param name='nodes'
-            select='$nodes[position() != 1]'/>
-        </xsl:call-template>
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:template>
-
-</xsl:stylesheet>
diff --git a/tclxml-3.2/examples/tclxslt/pwrdLogo150.gif.b64 b/tclxml-3.2/examples/tclxslt/pwrdLogo150.gif.b64
deleted file mode 100644
index 0e3f0b6..0000000
--- a/tclxml-3.2/examples/tclxslt/pwrdLogo150.gif.b64
+++ /dev/null
@@ -1,56 +0,0 @@
-R0lGODlhYQCWAPUAAP//////zP//mf//AP/MzP/Mmf/MAP+Zmf+ZZv+ZAMz/
-/8zM/8zMzMyZzMyZmcyZZsyZAMxmZsxmM8xmAMwzM8wzAJnM/5nMzJmZzJmZ
-mZlmmZlmZplmM5kzM5kzAGaZzGZmzGZmmWZmZmYzZmYzMzNmzDNmmTMzmTMz
-ZgAzmQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
-AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH+BSAtZGwtACH5BAEKAAIALAAA
-AABhAJYAAAb+QIFwSCwaj8ikcslsOp/Oh1RClVSu2KxWAu16jY9IpGrVms9o
-9OPLJqbf8Lic2/7K0ZN0IpG/p9dGCAgPZBSGZ05+WRADBmcTA5EDfYqVcomV
-jJNnkpGOlqBvmIqeZwaSBhOUoaxZo3eaq1eQkbKttxVOFIqnn1qnm7jCV7q8
-AxBmscPDdEy7frVmkQnLzE5ld43JkdXDEdek1L/BlhKE3VffTdhy5LPalRIF
-APQABOhP7HHuFQnHlRHqCbxXLR8vaQMqHRAIYMECeg8KRjmYBZIvOfPoLfiQ
-ouMJBwEkNonoRxyWU7bSEKjHsaPLFBn0tXpC8o4sbncWNjTxsqf+hmU0Fa2y
-mJPehZ5IT3QYBoWVv5RmAgLAgBQpCaBPWJ2aQ69lVZcollFoGgoenJVUv7o8
-Ua1Zk1CQTKZZeFSty6XL3DIJxQjZGwkN7bq8amkCnzOAXil6ehYAT8Fh3xg2
-IPeKv1RaEr8FtfXNAwBe7cbxNw3hxQobPnxQDO20mQAMBHckDAeYa9JaRvRc
-UtZ1loWP7UYeXVoLLS0odispW1kLgLqCPdwh7VeL2SvJXZrgXZhfls/B1dIm
-7r0CvxMvQXCvBAlqBQKxIZ+hYuo6lgmue65e3j0NYBCy4VUBBQ+sBEBIZpzS
-XD+2KKeETHFAkgYCAMgWGQUMMASATNH+mGGLBw4mASEc+KmUll0joJBdRyBc
-AJFx9r3RQYhIjFhbGgAAKNtXAQCAgBaMLIjGjNoxYeMbQgK241corHTAOO6Z
-QWRH+ykRAShQPbDAklV14KR1vqVBwktNXLnMASdy6VIFL95XnphkMmHmMATo
-qKZHFNDDjj+VrJhCmdUQEJ6aI0j1zBUDCJnGitsxUZMwAdz5UgcLEfSOJSuq
-t9kw8UmawnsAPInFHpag11FWy3R6Jwp5bphFmHDEuakwaapJwmcIzqLoG7Lu
-tUwGnqbgJQCP7sqrS6gOo0GwbAJwaAVRpjFlo7PisoFag76Ewmei3jJllb4O
-c21VJmQ72Er+w4x5arLCTPnSCaEhxQGx6SLLLi7udoQCCbX25ICluOi2Lmu3
-WMWvWk0eWYnAJ5C1DFIdbNCvSxr8uEx2JTjMyqN+fppBvC850E124IbLygHd
-+hkWAyV8Nd4w9t4LykoWCzybB45VNVw1MRNciYEMpDhpBxVWhc4VPVc7cz0b
-veRBBAp0eXQFHVHrhIChrATdSxU4sGVPI2ShsCJEavoE1kuDHFYDW3e01AEE
-xL0MkV6gbclKdoJVAQNtr5Vht/gOLPPdOfd01VRqbQDAnLio6wUuwEHM5sQd
-OeDqMDM23AXkRffUwX9qoTt3ChlvfstCVXkAelUn2FPNjCUrbcn+Z6ZyHVDe
-L4UQ6ut/Pn7LZx1/Ct5XGtDLsx23AGazvl0XjlQGi3fTOxQY4KJ8T2FFXpXl
-Y1ditRMhCAPAuHpnaG4K3Hdj9hPh47Ih2Ht3jtRC+HjxEy4ERAD/SkzS380X
-7btF/vYnv5eM4DP160IAW4EyP13lIS4DTAKhsEBWROAAy3tgAe/Cpu4p4gs7
-Y4UECKCu2VQAgqnr4P+8EDZhkPAlGvxKBSS4wi60EH/uimFSKlCgCT7hhqeT
-AAxPuMEUhCV/PnQCEFsRgQcMEYVgG+HRvPCBlzGwdmGD4qQK4MFKaKYJJbDb
-yVaUxSLS52hfZIIJxBgKBNisjEgZATb+uniHNC5BWHkRgd4sAIDadUQ6MyQA
-HefQBTwuY1nM42N4UCABuOmpG3phgiG9UT7n4bGRj2xLIdkYCiF6pAIYsGQF
-OkACFIDgcnmBAkc4GQquhbJlVTnlFJ+wSuthY0XNw51LQJArkTSBJ6y8A2BI
-siIPFE+XHcEAwLDihI7Q6UAO8ErEQPOVBgCOmU1wpjB0kqZpUo4Aj8KmJD81
-DADAcjBEmxgKnDXLZpJzm20bQZ76loIN9NKX4xSLJcPikO1dU5xKaEk1tPSu
-vUUNewEYpB+eAKAQ4qIAaWoeUjawTHwqgScOxZ80aactQU4tF+7MKP50RALA
-nDMFIvinRZP+wLyjRTMFcqSmS0T2UZBm04gfDQEIwiJTmNb0CggIaU1RwBYC
-QOen6WhCS0S6jLAV4GtLnJo6lqAjplZjIR0I5jKmqgRYWhUUEArIs34aySMM
-hhmfKcB8UInUshrhrMsAgFrPED2kXsGtRYBrOedqBgJYzK54JYJexebRSsgV
-DQfgq11vmgIrViAgCj3sGSJQ0ZoyQZpmkIdc/4qFCx4gnFeQbGYBYFcsMMFO
-YoSsGeCWjoqK1gxs/akaORiV2AKmDP7Lwmu1AM7S2pSltNWCan9zOQrIZLe/
-Uaxs7xjcLAwXC/M4EnKxQMPFMvePk43tQrAxVjYp1zkKDcU4tVn+W30MEwv/
-nC4W/FraJYQGDYAhwDVHSIgDsAOT8p1LZduJhLz5Z0RnLMd+k1iEk/p2vaW1
-4xD8eOArqBSNSuhJg2eY4AhzbcKlDayEMZdVEpAgqyDW6tE0fGE5gNjDKSJq
-sLCnohaP4MUv9rCMPxxiTuI1NMPxwIlLqSI/rvjHXILCSY0I5CIbWXCzPbKS
-jwyFJTu5yE1+spQ9FeUpW3lH37vulbf8lSxbGCkluMAFdFkCBjStJxhoGQZ4
-kuaeiLlWLbrAkE3w5p6E+QIgK5ITkJmCDyjgAwU0wVROWSsMUGUqrfOxOQf1
-gQWEsieCLgGjN9JTOz9hyC7x8yn1E5/VRtvZnA0BwddeMpV4NdrTLxE0BnDn
-aVQjJXZJOB+gGRAvDHT6oKSmNQBojRTQsJoegxL0B4bc6lHr5wlqcfVLSgCa
-EiigXy4yQYZ8nALHTNrRkF60fhbgbMrBGglqAYGqXgLo58RyS6KuigIUMO4P
-XMAECggPvNmtn3VTrs/I5rK+q1Llfft7epf9t8ChAIKCG/zgBi+XwhfOcIUL
-3C51iHgRPgACTO9b4hhPAsXPt+SMe1ypIOA4lT9OclVKOlglT3kbKi5yJKv8
-5V+g+JBhTvOaGyEIADs=
diff --git a/tclxml-3.2/examples/tclxslt/simple.tcl b/tclxml-3.2/examples/tclxslt/simple.tcl
deleted file mode 100644
index 626c45a..0000000
--- a/tclxml-3.2/examples/tclxslt/simple.tcl
+++ /dev/null
@@ -1,27 +0,0 @@
-#!/bin/sh
-# -*- tcl -*- \
-exec tclsh "$0" "$@"
-
-# simple.tcl --
-#
-#	Simple transformation of a XML document,
-#	from README.
-#
-# Copyright (c) 2008 Explain
-# http://www.explain.com.au/
-#
-# $Id: simple.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require xml 3.2
-
-set chan [open "count.xsl"]
-set styleDoc [dom::parse [read $chan]]
-close $chan
-set sourceDoc [dom::parse [read stdin]]
-
-set style [xslt::compile $styleDoc]
-set resultDoc [$style transform $sourceDoc]
-
-puts [dom::serialize $resultDoc]
-exit 0
-
diff --git a/tclxml-3.2/examples/tclxslt/tkxsltproc-sml.gif.b64 b/tclxml-3.2/examples/tclxslt/tkxsltproc-sml.gif.b64
deleted file mode 100644
index 99f8a26..0000000
--- a/tclxml-3.2/examples/tclxslt/tkxsltproc-sml.gif.b64
+++ /dev/null
@@ -1,277 +0,0 @@
-R0lGODlh8AAPAfcAMf///84SB0kMDM6JGS4JCVZWVs3NzczMzNacJdOJitGR
-HsrKytujpNOVIJKSkpCQkJSUlBAODpiYmIyMjJaWloCAgI6Ojvfr0JycnJ6e
-noqKiqurq5qamqCgoMDAwIWFhaOjozMzM4iIiIKCgrCwsKWlpISEhKenp6mp
-qa2trcdqa7a2tq6urrOysrS0tOSiI7m4uH5+frEwMbq6usPDw25ubry8vHx7
-e76+vnp6esjIyNypLcXFxcTExHh4eHBwcOKYHHRzc8h8EiIiInV1deeqKnJy
-ctCPHO3Trevr67hHR+G1Ne3NlfTh4UFBQd+xMpxiDtWYIuXBPevCO92tMGBg
-YMqBFPHhVasSCerNRocRC/rx8dmjKffuXu/bUcuCFfbpq5URC3gRDLkSCNmt
-atakUsd6EfDw8OG2d8yGIem5NO7S0ubEQOm1MtqlKvHUSrJxce3VTOS1WuK5
-OE1NTbWKi5lpaqoYGeOdIGsQDPr04ezRSvTncsyGGO3TeOiyL/PlWFwODNWd
-SujKRJowMdOWPtHMxWhoaMh8EdfFqfDeUsqCFvTpXJJPTe/YTuO8OoBQC/Xn
-j9O5kMyFF/z48e3JQefGQeq+OOO9PMl+E+vQSM+MG9qmK9abI+jIQ+/NRMuD
-FU8wBnIIBe3US+WmPfTnWsl9Er6mheG3NqOBgYsHCMh7EdGTNOanJ76goO7L
-QnlmZtzT09igJzMgBeLXyJh2SObBYOO+PNGUKdCNHPPgwebBiKMNBMmAFKGR
-kerOR8ewsc6LL9zAl+S9OtObMuGzQ6EZGmRAC+fHQvDSSMqAE+bm5s+OMOXl
-5ePj4+Tk5OLi4uDg4OHh4d7e3t/f39vb293d3dzc3NefJ9ra2tnZ2djY2NfX
-19XV1dbW1tTU1NPT09LS0tHR0dDQ0HYVFaASC8p/E+fn59igKOnCwr5XV+Kz
-s+evLZkICezGPvDQRqQhIsqCILCgoMB+G3wlJciaXNXDwK19Iqh9QejIUJJ9
-emcaGsuZJ8+OJqQJCgAAACH5BAEAAAAALAAAAADwAA8BAAj/AAEIHEiwoMGD
-CBMqXMiwocOHECNKnEixosWLGDNq3Mixo8ePIEOKHEmypMmTKFOqXMmypcuX
-MGPKnEmzps2bOHPq3Mmzp8+fQIMKHaqwCdGjSEGmu2M0qdOnFIFhkQG1qlWG
-CeDducq168AEd6gCAOa17FMVvJSADZDArFug6xKog4elLpZ2d7AweMtXp9a6
-vO5i4SVjb8IEcFQkaNq3MUoVUxMowQKPscAEFwrKGMPrTmd1mB2LNqkOi7qC
-SsIWHBOmM692vDqr0DO6NkgZWFQMTIcbr26BTTwP9uya8GLbyDVqbQtgXd47
-eccMZICF+ODOsDsrSc49oWGFF+C1/4XTGZ66sIwvAEuQQAW84nk7y0jXvf7A
-tA0v3BmDZXtesgDYYZlAS2FXnFj2cRccZcwpdB5muCWwjgr7/WYQWHW1M9x2
-DDFgYYJXNaEhbGPQp9AaAEAGnXCeNVjQOq4JhgWA3lUHYlfpDDcYPHBkdtgd
-Gt6hhHuDuViQVDLmphADrGGxzo1XpYNXcZ09idAFeCmhCwPPGWlQaUC2thVC
-YIUxBjw+QgmVVK/F5pln6pho0DrpNAFWWFYCMOBXYQCW154AgFWenGo+xeWb
-bsbWGRwJKREYPASdR+Z7gXVG6GVYhHEHpIVaJeh1ir45hhLfESQDL8ylQ2Fn
-pU6XV5+xXf8Kx2BTpdmpodl1hiiQbsJDG2PpmJhaca0KhFaiWFimAmtC3srV
-BaveRVxs0p6p1aZGNTHrm3ckQJtBelAKJGUDNaHiHeoA6qxTa7w33GuIVucm
-h03whxejCeFmHS+nGRtYO/2u61VW1mkIL7X8NkUhmgpt6+Zge5kr2IcCeyUD
-cUDmNaJwMzbXma2aueYZbGOmhpe3Fb+1zrB19ZlhXfvFORmCBCVwsWBTwrPG
-BaV1hnLKfIGlYXV43dXOlHdQ2E6eAHBJF5VFAnBqi0A7RsuyLg+dIXFmPrkO
-HHTJK62umKVWnZdVv7UGkBqG0bbI8kFn73XW3UHfe3gVm/Zb6mj/LS1gbhYd
-WNbVMtrufvAwvTdf6fwrJNFUwo3dy/gCAA+lly7+FhxDt8Ubra+9PGVgSTPw
-rUBKcLapDIoxUKfmZvHXJ2NZkfwv5BlnnoDB8rIoZGiwV6WCpmNUTqBwQ7uc
-ZJwE2dmeDMqP2LsMoEkIcvA+6eemQfriNbTW7Wh6dkJrSJaxm+cjKgPa2OOU
-gGtGcpkk3bwQLp/ezccFhxJ/uYYXkChqH0+gg5dLKaFoU1JCa2Q0Opgp4XQM
-0UM64HAqRSlJgDp5n2coRov4uKwt6+jby3TksvWpSyHpYEB7OITBm+iBV2NC
-jcHCQLMyCac17WBWXmRwwhYe5X11odh0//QVwHJBBjAwEwzx4ABBHybFUbDJ
-XM0CVpAmyMB70oJNEu+gOCcKZQONeJMoQhACJzihAAWoQQ1iEIMJOMAXDiCB
-HA0QizoCYA0MoIv07qKpzuRGil7cCQn+8Q9VYIeQiEykIhe5SHJURzCOO9r4
-AtmTDTiBkAK4jigSGQEBCCACjAxlIgUghqEVZ4Z30AI9hkBGM6JRjWx0owM2
-IEcS0LGOSaCkSAygSFF4TwCIzEObeBEIURrzHwJozb+KM5gwhGGTx4zmP4Yw
-hA3oMiMkuGQiCVA0VSByHwjrzD4KcEYzltEJ1KQmKBdJgEDUD3S7yhQwpXnM
-WFzTIkkIASNVIf+YeXITPhragEBpWctYGOCgsTCEQg+6AQdMgI10GZfBxhWb
-dqyTnosswD0pEosYEGCRQ2hEpigTA0zaBT4xaChB52jLWxoiCbFIgkLXkIQk
-XABs77xLYMaWCoc+FBZqRCM5naDPUNpzoxEZJCNT2ojB2WEChNzHxnjFC33E
-UaC13MBBSVDHhMYUpoaIaULbNbaxwcYAhlgDWg16UITGwgGhrAFSIWIAbSqy
-Bg4wgC9ENYEJDAGZgNEiL+DhgFmqlARaneNBX4rLmsL0sWs4z8G+Z4A1eJWt
-bTUAVDmJSGvOtSE1YGQIEOqKix3NDg69JDeVSRwlFNaNcqRlYrm62Jj/hrWm
-YgWbvG4XpK7WMbMMveg/IqDNCHyWIRsoaiKHMIE62tIXLiNsXwuAyQV2hhCy
-nMBAV2rLWHQ3oY41BAPUIabQJUlTvq1jWLf6V0RGYALrNMBxFULdRcYgpgg1
-wHnwgtq+lhSR0AtDAR6a3Yb6gruZTahCU3EHVeTQbSMjGswIkdBb/vagyiXk
-BLTphPkihAQZJmQ1xcpWEowLC270byILwEZ9tFGWhd3uHBN70FTAQVPcitFI
-x9bcsHZ1vXYlJF4ROQEPG+S/iuwwbn9LAgXWxQ5wdGgMlBuCNbLxxYWN8UAR
-awA56sN70wocJAWTOJq+1Md1DO2KLYnIXBpZ/yCxqK8iJ0DTx8LUAMB4kwyi
-TGA5/wOWV+5rllU6UDjYIcyj29cd+sS6W8r00V3dLCKdMMv2xuDNAkmCcBFJ
-Asde1qB2IJprG/pQNq5YjVbuK4w3oF07tCnR6LPdYGRAR5mG9cy2TsIGFBmC
-wv7XuJh2xab/EQIS0PSrjDUopVBMav/GoL3/cAKgYwljOyiwohhLVOg6EwYV
-MACyj370S5NAAmgP1427JuSl35zuRRqgpu/+Kn5DnSVXzNK/a6RyDFAd6AmE
-sWjQCZyBeFUdhSYbpsiu6RoMwUtOstoBav6HfI0MV5DWurGPZTg8xDdQVbOx
-BnaNwL5hqY8CEEKLmf9SlMoRlkMV+MIQTTC4p2s67jP7+R9trDQhQ4DpUMZb
-3mC9cCwGOkuffjziEVjjGuGRw+pkG2nTgg4c6ngBgysUt1eX6cKTcPMaoFvS
-RzVyxCcNiwl8l+Zd3WqXBfraUqtxxY2gx9E0Nra8jI3bQ2rp1cdt56/SPAlI
-JiSls9zeDmNaqcZ0Qht9awCtEp0ERt/3s6MqyZTzNnS5CkstG39QcUPazuNu
-t4iz7NDOYlogIT7mOdUoS7a7XY2EyEP4gvS9EQ5tU0/dvGL3XmfH2toQrlDk
-EEjvALu6GdOxwKgxhyBtNsKiEeGT0QJvmMT6EUIfkHdFVrvM+b3PPNzm/of/
-oLO8TgfoRLPOZ30sc076wyKWxi1FKMJ9r6eW2DUEQCXjsOkZgU56Mg+iQA6q
-AGGEs2iNoA/oZlgIZksyF1O9lwQGEGLsV1j1NQQ5EQvhp3waKEoRkE5lVACe
-9RGiZ1AkqFk1kHobqEgRQAACQAAEQFRnhEaSl3Nsp3feF25B9meqlmKItG42
-EXgpGIT854MdcVFO0FYMR4IG1VD7VgAhkIFCGIXulWQ76EZyNnE14WcREAha
-kAde6IUCEAhh6Elk2EnDJYXSFHYbgXj/EH9oNla/1VUQOAEniIZ26F4+NX7r
-ZHg1UXHIpApjEACCOIiEGACBaIiFmIiHOAaMyIiC/8EafeJMqvBRIrZGBQBt
-Q6CGGqFcNeBW6uVbuJZeSWBZiNVXsDBUQ9B/dyhNIVCFD4VImhgTyWdSjViL
-g1GLuJiLhsiIAYAFgfiLg8iLiNiLk6ZwABBniXR8GuGHEZB2onhrEJhxdhZu
-saAHvodbpbhvRPWE+xeEA1aFiCRXNiFpWqA8fWIwnOFH1GIXdjEG0dGOdcEf
-7OiIvhgYlBgCo0hiSSBpPMcRSZBI92VhoLhkoihWx+ZYD/hpvtVd7/daV9aE
-5DRU2xh+LyZochaCNFFU++BMHMmR4VOObtORzhQ+iyaSJhmJKFkdZqIFRIZw
-uBRW/NgRftiGlpVetjVuuP8kb35nW141ii/laELHVUKZVWx3VVm2g0HWim30
-YsqFE+ukClogBlowlVQ5lWFQleVolVR5lVl5lV4Jklb5lR8pBogEDDnpkmsg
-Z0SYEdB2XwMZirhUkzo5jT35WLGwcMCldkSpUkV3lKpmbktJYJKGkTRBSBEg
-BoiZmOQgBou5mIrJmJCpmFFJDlPJmFRJmVQplVg5T/9gky6Jgaa3EUgWAs9I
-c5Y1jTLFk7h1jY2Vdo0nlI5HlEX3cH75iojEXBUJXzuXE4b5hb75m3kgBsEp
-nME5nMJ5nIhpnMNZnMmJnJxJYp/oW8pFAhthCInkAOC1d/Fml3K4mn5nlwjn
-Y3n/aUuIFVtE11C12UZBpnilRodExpvDFYaBkAdh6JsCQJ/4eZ9gOJ9fyJ95
-EAj86Z/A+YXPaZPpxYYcMXbq9Xe4hmt/R5dox3AK9VuGEJvct5eGBWN5aGoA
-KZgToFyxOBPtJYYkSob/N4aeJIZkSJ8oep8nCqAkGqMAmp+cZqDOuAHrlIka
-oWmI5AANamae13diNXNiNaGYpZfl+X5sh55t518T4GdDsH5ttE4alRNyZqJY
-KgCzkKVc2qVYqqJc2ll5mV9tJWl8iBFy5gS2xgBWJ3O39Z3h9YaMx1BbZUsE
-taSsRpsbOmWJZGVMiUg70W6dxIKE2oIsaKKHuqWedKiL/+qlXcqCiFQAYzqm
-EXemFsGGG5CaDPqg3+edOOma3uVdM/Z+kFeU2eVsbARt7xVoSCaOFeFpW8V2
-G2Fus+CCtmqrK+iChvpRBLCluXqruWqGteqCgzqoLihikzqmarmJiBQCbmpb
-4cZ34eZpSeiabaVVa6ek6MmkeVhqHCp4DxkDdkWdCSFTiOUAI0dGUKhIG5EE
-qvoPBNB/8QpMLbiCwfpJn4Sr+cqCnfSrt/qvlIhzyZqXymV+GDGLhLQBWfd7
-vrewGQetc9pl5FlL5TmbxOdxV2ZuLBZo0CaRT5iKdghsGtFwUghKJrtO/Zey
-hsmr8AqvAfsP2DqwCAVt5HoRdv9VAA8qXo/GAHA6pOLmmrTEVtz1eHqKqh83
-Zw85dqu4SJZ6sDe3tBs4BPE3sEOXoyGaVImEVps6rbj1gMl2YdyXrVkFeRnq
-l0t5ZX6meA/Zje6VitTUSq7EYjVQdrKUg3/2EcgItUGYiSVIR/nFVt6VjBhx
-UTjLppzaoL6HbOpFpxcqqg1ZlOl5ZWqUYd4aA3I2BDLIRu23XVsWW0MZC3b7
-Dwb7ERDYVknKlxcbmLBwdKeYRmhUTmZkTq2UTpMWh6CohHVkphjBhiQgc1x7
-jdEKVm0lqhJLsYbVl00art9KbOGqXLnZejEWR4ZFsRKLYZxFSDXLFXY1AQJp
-o7k7aRj/0ZYOynDhVb65ZnB1WrwYyq3JK7k1kLbhOmlVSHysVp5YxVUCJap3
-BW1F1BXb673pZQDLShEOIFwRsLBpBbzme2Z01FJctpdFiZ47mLRqBJhKFwMX
-Nb/Ri6f3+8CNZ25OIHpu0QSJxFUA7FvQRpgN4a5LxalJ8G2H+8IMl75dNnTm
-ibq0ibEfx0Z+VmUZ26w7OGja1VBKunlBO5PEBnnu9RYsPFyZKofQ6ZIRGJoO
-4QCYGGTvlnXS6n23hlYOHJvauq0ppsOSp0ZBdsEZ9o0a2pcyxlK2pJu3aVjN
-yheIl4mfOaSVhUuIJ7IMYW4RQEdt+cLXKK3fdmYzHKqNt1IR/3xvTeqtVlbB
-t/lxIaZqpBfGHUyeHaWCsoVkTesV7eYEwMCd+miQJICyVzsQSHxfChVxQwBW
-0sqghuzFdbqXpXpvY1y5SgdLiRQCTchJWPZai3y/8Ke04jdQSFalfCFpOJua
-cgqeuosQCCtiE2qu13m+5WvIC6W+xVuDerqhlTtydRiO73tX48fGnbt5rtB4
-T6uAGxBxa+kWarlWQzrP+fjMBAF4qtqJ4sZwl+u7XBvLNUyeskVLx8ukHofL
-qFYD+VwDwvWNR8mX5xxbXWa3KbVdA9wYduWjWVdh84db7nzP4de7W2d1JCu6
-wMumV7dVhuDGFItVRQdjTiq54DzOkf+qtAXgUO0XY5CXpOTZeKkHW8eb0aIB
-mk48yn33WHXVowIBhDVwl7+XzYZwfzRXczTHAGi10tXb0rXMrRO8wwnNp4Y5
-efIL04SGVXfKfVacUQS91nalwnxxUe8Gnn63nbGgXJJmmJ0Gjba2WIiVtWt6
-k6WrsHb6mjecpzD9zQkNaND2hMuF00Jc1itF2BkYA1dVgw4wnbVRxxgHdAdJ
-bsMWAZLqeTOcWbaEiQYHraON1RQbxsjbrTINziO3XHO2xhzMXXJUwIuEV+cK
-0dB2ym5Rx6tJjbf2VUgMs/v8e6Stv53lptnMeRd6wzGmoTHtvl+9rsy1avc2
-0PdrAFYtepH/yrnbBcf/oIyioczBTaQQaNN3Ob5W17sOnNSEVABXV8imq77Q
-DbltF66JXcai5HX0O5tbNltAGN843H4XxR12FQPB/Z3eHQF5/WhqRdJoRcNj
-h3amq7COl8iPp12k19Vl/NXiGkoDRr9D3MaJPOA4d1VDbHbbepvd8b+jaJcC
-rEih3aDYrNpdttLvB21O0Nx8zXnavaQd7mwPlcu5zEYoSGkpBtHsvNpP+2cF
-PWgvDb4Kkki+BVPebdLZKW5WjYQ0/Jp33Wl6udKypaRFV8uu7dUgvkbDdt3R
-zbmzRLHeBYWtN8Rlq10f3R1E3YbOlYNHGHN/V8jrhYTxN7FyBG2d/0jozw3n
-Erynas5vsETMzEV8Uh7RybVUUf7SEixnRVYfml3c5oe40Gi6o01LYitHSKdl
-YAzdFuvNFBzpMzjZ0EvEZi3nWT5cOc2teqpcWNgdOCpiNE6dfEfVo13fM2bf
-t85I7fVX6dTsrOTsrPSEZAS3qYdXOd3kD5zWKpiAqHuUpAdt5M0dKD4BDDrS
-L8WmKt14FUqngp1VKK63x+R1q3aenbsBviBaO/3fZEt8Bw4idx1tnVZnjJVW
-Z2ZQK+1dYWvoLS1Q6wrvolXOEB3gXSbWieQEHL6tlE7pSwwiQNhK+4ZucvST
-mXXwQwnkqy1QdDjt1DRNDr9IvSZLW93GiP+F4jdNm+yb8X1F5Qny7/Tktsx3
-TjEoVH6KZRze6rXpdjPtukIVkbHb9DAIg5Sd6wqYVcScdMB89TjvcTpvH+/e
-8sIXAXArbe/bb8rr1SOnvK64wYVFy40XukX/cKRG6a4oZ8hsH5KmTl4vhcze
-7NIe9kKfag7FpODNZcUHUtKd8UePbz14I4OJrZBX5Ga08nk/+dMU7WfEekOc
-gYOH8VnvitO1+CDih9xLY2W+8BuKakIVux+78g1P+ULodXHf+Z5PYEId+kQm
-toRNyyiPp0WP8/n9vuSk8qro+sc0fEsu+64opcrl1snhh3H0wKtNqnFusQZ9
-843spBiL0EoPu6r/r/LNPvxBaPGBL/fdWoVnu5S8fiPOb98Lb9bS23Gzucbl
-763fTMFnf8FlTGDPK934BvyRDxBDIvwjSLCAgwkOECpkOMHhQ4cxJsSgWHHi
-hCEFYwHg2NHjR5AhRY4kWdLkSZIbCk4gYYDES5gkNsyc6aDmBoY4Ge5ECDHi
-xYoUawitMdRoUaRCg06U+DBnQ5w0N8AcWPAgz54+fUqkyLRr1X9JUI4lW9bs
-WY4OVsqM+VKqTRI2N0yYaxNrQ4hdg+4dGqOoX6RG/e5tCnEnXbkO4sqc+TKj
-1cNaH+6NSDgGWLSZNW8mq5Igy7Y049JMrBAnYp5am1pWChhwYMFLCzvk/xnV
-tNSpLwsSrNEwa16gXrnuLTiE83HkydV+Do1b8c6odGlHBj48aF/BsAdvtzh7
-+ty6z3HH3P3voOTJlVnHgDVhaEEnyeXPN0uiYIyYuHGOrnkYq2qg+FIKNgIJ
-u8gw6G7Tzy0DPCuoBvSYEq6AEB4jKIIIKgwhhPvo8/DDkewjCD/GSNvvOYUW
-u+u3n6zjKzvtLEOvthNLbAymmcqDML2uJPSrPCCDnABEIokU8R8S3xrNJsR0
-uksyvSzL7rW/YpPNp9oUXHADlwxY7sGfArSIwyDLLM+BItOUz8EY9HMuRdOe
-3Eq9ivoarMC/DDzQqQRvGi+mBr8ckavghjPz0P/yQlBz0c0MuO+mxHSybUUA
-17uTwKTs7A7LPu1aENCWBP0HQhctAgu+hBCKoYACnKiwzBoYlbW+R6cSD7yn
-5KzORTurpNI17iziNE4VbcwtlgYNcImECcoj1DIgI4jFkCSqNeRabC+IoUwS
-ZvX2JEd5q2nJ06LTlcf1qsSTNcn6jKox0WBaFpiWDGh2N8osspC3avv1N4lY
-tj1UrG8LDulIiabSidklmUwNOB/rbE1dXzUdjlPwpFPs3dzknQpZLjcQ+D7W
-nHA2CWoB/jdcRGMw+GWPWK7h3dIQOo26MC09Ck8r9Ro2Tk//9LhLEmIhwZCR
-RxQOMB1jiWUNlWOpFtn/fc00DmaYZZ4pobjsUihVvFTrjihgMW2tR+9ySog0
-Y+XtkktllUW2ht0iYAoWpU4NYVqpU5ba6TJfLc8ArF9mOWFPgX5416Wxu1Q7
-iwlFEKqo+Os4NGXrrZfugiIItqjdhjAA2b+jTsLk8pwoOuDUCzc4lgdP9A/n
-ypYmDDvILd5zcqDZjndoZUMeXVnOCRqiTqPKm8CQNZx2mlpqi3/QeadRL8j1
-gmHnTTpJ/6vU9sd5NjBtmxO/CUd5W5KJ6LjjLiD0O/2y/p8hDKF+WpSTEPUf
-J4Z3/t6CEA57s9LeqHQCtsXlJUrXkZjZ1qOVhnTtfFIZGtxeMrz2xeJ9BQnB
-/2v8cipkjc55KFuDIebHP6OFcHRHIsgGBkjABykugbVjzc6olKl8QfApNLMR
-qF5itJaoUG7V200IKLabAgjRAIZYoiEcVJCpKGsCtYjB6PY1pBcyKglg6s8M
-J5OuAQUmWJT5WcbGRUGPFa1BRktW3Kg3PydQ6VRwa5+ymAgkurjEAVCAwgDu
-4QoAIimLjCrgeby3FZ25Zl3B2h1tmhQnN62vJVxSXwrreD84wiZ0daxj0v4R
-ArdsABJCGIAQ7lFKSBwjFOYZ5KIKOLND8ihiitxZpvI0Nh3ajC77+dT6orjG
-DQjRfk6bGpl4Exhj/sMBTOSkspKJpNzAopRCoGY1Sf8phHqsoZVqsgoCWbQa
-2zmulmKUEaceyTE0UnJZ7BOi86hFzH0VICkWGsL9nCY3EpxqCDSZABSs+c9q
-DkAQSNgmiLa4PdrRqYZEWeSVMLa2oMmlYw3agCsyV69L2rNa8RQMEu3pPAN4
-kmsbCAVATVpNMhTUQwc1T9iqA75aerBnPjNn9ySKRlB1SadufJ7pknCqisBC
-ehMgpj0NUZ4h2KWfJ2UqGfSg0vlAhkUKFY44zXZLMvIpUhtDpw8v2BL7ZXCE
-KVOZs4oygVORAGDvRJnTnsg/u8DiCExtKlTlI9VKleooNySnQ3nXPd/lRnjq
-bOYQ8UfWvjmrK3XLH8DwBzD/T8bAZqOk60nTwAS7IqebiATjdiAnsaXk0jSp
-Es2NJum2NmbUsdZKQgmrVbc64QtbZIXeCVNVA39WlqkXyCxnNvtF8HEHU77K
-Ie92KZcetuWCLjFE0TAqQuqxlrVHxRdFNtjCa6EMetndVwgSMoFQzFW3J0VD
-bzcDGcY1cK9inKnkEPSuXW4Np0Zj4gWbSzqe/q1v2p2W/Vg4hIvMT7r9gp6O
-IpLb8Z7UvJr5bamkNNwxulerO6ycab9KyeY2U6N9m221nng8h1hvCNodsP6U
-J5ECJJiuguDtgs3SzYsJiL0OzOpfI8rViYYqc8h6rmFLR+Br7TeQAJ6IMZ2A
-MgNY/wt6Sbgu/SpSAPGq2KRpaLGLx/KYAjj4bOvFYeR29zXbnK9EytXcjsU6
-QmKmjK39GvJDLHRk5imZu/CTCGWlzNTyWhklWH4WA2lJzsh5ZzpqOyNOMxe8
-H2LQjmn2V3//9TfpedchFqpBh5PAgH4lqi92vvNJEdAEPZvkMU4I7q8gfCXy
-7fCmpV2W+pbLxvw+lq20VVm1mkzqSVulidqFHssIYsQawALBnT5pIQga6pHw
-WcaeZS9ohYWxoMUXpxf82Arllt/8kVXO2a31rRkClgIEr4nZZSH/hhICYo/3
-2MgGCZmyfLvwNVtPvItoL33Jvh67s7ED5nZjpZZMJzCE0v9frVdz3+qEojhh
-2OmeMmbZ/RHUkbqBf84TVns0rC66ybQNggkQ7xnrbPsLW1D7l7XiKXCrKKzV
-yhKVPGMQgigznKnrfjgAyBTHAcV7r8W1cb1/52qXsFGJ0VUzbbW972uVpwBR
-sdDSFdYWUeF8CHSNuUmnyVQq15wjEb/dVWUk6JyA50QKs3CyOl40OkJ3hLxm
-ALYI3C/XJh2J0nnzThjzkqjjDd0yv/rVrymENGgdAFy/FF/j59cJ46q0Pzd7
-YdVOzGwX/e1ALvBuYLkBY3p3UjdJHUVKmu5phh6gpdyF1jlH6hl3mYxgZ5IZ
-/TTRkGG0x9DNH+SBLHJuz1bu99n/pYgXQlrFBPKTReZ7QP9OzVKmQRCmJwjC
-dZ6U8dX0nF2lJGHVx8l71n7fJXa72/Pna2jOpMkIAps+K7Jwv1ez6sYvZfqv
-OYAqIzvi4ySupsI0uTD3Mjccv68az8zof8m9bfM+JFMemkga+3OKE3IAiqAH
-vxuAq1s/a+o7q6OmPGO30xuu9pKQv5q+n/uqLuk/sZo1OeO1ACxB6FmDcosv
-QfEc+5MI6RmViDiGWqhA9xu945tAISiEmjs998gddsE4YrG3o1kfccMvwwo5
-yqM13KsWTOuXt5KofLK8AqEIPKIIBoyBhUswCsTBmhMYhFM9nks8SHo9Brm+
-6zs00qGe/yW7PSZku+zyPlF5OpEpIlM7N6WbjIwQgGPYQmpavy78p/aruXsB
-NhuatwnTkne5O2qLCSDqkhCKLg4zwe5TsxIqOt1zovK4nA3YF+SpkhPynAlw
-glOJAPSzOggUPR0UAgQgxOaLEd2ZDawArOQ6w51iJsNqQ92bLtwTQF4zhCcM
-pAggOBJoMs95kRiomkOphzT4wxwkpfYzPvYTgpR6ODAEFkTUKh6KpEZ0Ilzc
-gGsBuf3SxV8cQExkAKnJH2HsOJd4KwBjDUSBDwBAgvFqP/drP5oLtUJ0nHyR
-xSx5PQtTJ/VpLlxcop7SRUzcRV4swZBLGlDCN0/6JFZhFeyIx/8IMAQAuAC6
-SsX3E0Ro1DrP6CDiAid6Wxi4SCf+Sy1wxEXomcTtcsJMRMFrabs4nK6k6R/h
-cZ94/LVDiQBtAgBaULFolMZqfLjlwLnoI78wWzVWu7c0ZKaaVMKa3MXc6zAC
-VLMkkJ4aALrra7KdjJZu4QgmmEAKTMWhJMt8DLWjHMNBC7u3MLSpaC6MKsiX
-JLG6LLnGskpLa7vGYoAmCzd8Ip2iicivpB+C4QhBiDkIRL6/W0yPbEWQbD7Z
-cK9Oyb8boSQQzLCMekKs3L4mfMmElC410yB82Sk3WqGXU8ZDqYGN4Ag9KANA
-fD97dEzkg0BdEDwRQcqL08bbYEpOREP/56JLfbs0ytu+SuwXTCs6zpzJlJmf
-CTCzM1syt3KPEDiVAPoIKtjIaDzLgCrKmgsXnGuku5CUT8FM5gKr9sGWnjLO
-qszEfrPK20uCJKut3YCboZM1v1EZkpOJ64qFJkCCXSADZtBOs6TN2oQ/wQMA
-8GykQRs7jcsPzeQSqHSjvJRKfgPGcow8DXVCtouFZMI+Nlwyv0lHf3mfCDiG
-QrjB0Ws/BTBLQRyAtGS33GQ9SIqU8RBI9jHN+RTRkju6vHxPAXzCkGvJJPjQ
-aztIkSuxqUkHSbgHf1LRFy3QAp3AC8TN5msXh/EaW6EglRM3OmLJIW3CChXS
-7ns7HuVLdBRR/0NIpo+qUM90LDIwUC6czY78J8hMUADQHlzjE8Q4rgeVJLbQ
-UTuyUIbEy1+UPA4d0nRMTpShJzZcKzdtLfkEBgGFUqaSUkz9J2bA0444qIDT
-Rq5JkV4KHmYCq7SrSSGNz39BRyUTUprszEMtU5QBi3rSL6RrQwOAAxedU7M8
-ghaVUgUAqCpNUE9NxKDhGMz5Ks20o6kUTW17w+xKx6sEGEZlVBHFNLDYm8My
-U2oxgARghj6yVLJMRX5IxV/NVICiBU7lCOoKuMqUwp9jIgtCFrokMUZVMuI8
-Tmf1Pr6criCzy8jbDSewnyWklg24ByGYqzQQ19kcAH44grny1WAdgP8WVYCK
-vcE75dSDuorK1L91Wi5OytDIe9Ze9FdZDVPizJ/kpBaPktbs2gA0kAEEoKZT
-ulRoJFcIhFiIrViLpdhzvcH449TmgxP54sajoShSnb0O48v23LZWzR8AsDT3
-ZCL1pJa2OywWSqK3IwGEPaXFVFFgtVhfpVid7VmLPVvHTL9hFVr+4R4Fuakz
-NMIirKM4nFpKJDHpItGo3EVMiwUyHVJMY6EasBYDYAJ8uIc0WFiwvVmzRICz
-5VlfdVyfPdc6rSZBALV17QiDcL0KuxGO05wiVCKrtVvoWdmjs9YyTV38cbRm
-vRZBiQH5dAAhgIK5QgCOXFGz3AGH5dnHVQD/ybXdnv1a9wu8zPWI5iPPrmoL
-olnW9qk95nTP4iTHqAxTWrPap82u160HBEjcB8Rdhx0ABChX8O3dx3XcseVI
-7qQmZgjazDUI8aCLMaM2/ks0uq1b6O03E3RDTKTeulXZltyuezHFI0hf790B
-2z1g8B1f3XVcBdiBYD2CmWXM7bw6Hizej3DfLf0dzEzDJDhaZo1Vu5289oxW
-mgxTzlTZu8VQQygAAoCEAZBA3C1XBEBgx63hI9Bd3zXbtN3O4xsA77RgjhiI
-g+AlCwPBuJEJFULVqe1fvMzEqHU7a+1LYNxW690uQ7ADfihX3YLANFhgAwbf
-HbjhA+7ZGR7bjvza/2dEUCC+YOMJAXnaJVvkSrrk0SU2Om6dSjoewLZSU16T
-ImZY2C0egDQ4YASA4Bmm4TKW3ExFX78rBIdbY48ooGjJsplISfSMG9A8TgJM
-WfYk2SHVy5BD0/zZgAHAA8ADvOGtTX5wYAPOYdvV3TC+YV8d4OBlZO6EUUgO
-CfArkwgYApdLu0FFyJiEVg5VTxS20CpG4Uo0ADsoBFNW3O6tzUP2XVY+5Bn2
-XQh+4QHGVHv8O34ggxjN5Y6IhQl4JkTxZQdYor4UU7z8Wzf8UQzt1+xi2qhE
-RweggkKgJtsdNtGDQH4oZAR4gVcG40PeWW6m2Paz3WpKg3AWZ5EwmolwAv/V
-BJIhMCLJUucTzt9I3S5pFc09Ttl5zrbkJIFT+OOEndnb7TtBNuBDNmCWdmAE
-cGDw1dmDXsw0AOefdGjNYJaJLhNSS7J2TlKFrN4LVVOjtgNBVmkeJqUudmkE
-IIUBcGoDnmXfzVmI5WYhKAP21enjaBDq7OndIACEo4t+hWc3tV6UWU5lVmZD
-OAXw5QfG7WZ7/GenjukdcGmYTmDbnemr/lUEKAMkoIWn4mo1SYINiMF4/Omj
-o7UopkTJS1P8ESjdxWqyDOiYtuuobuAcrmoEfmHb9dUyuE3CNpjYnYBW2ckM
-GWsu4cVrfbuV/WgmgoNCOALxTcVTQljZVABS2AH/KsDru77rQ05gCNzrQh4A
-OUACzB3tAYoFB5DowoyApeNRe10yVhVRA0jgyfYj4f1afliCF7jrAehtu/5t
-v9Zr4S6DwVbugjIaBqSQr3SCLFOMTI685DQAfCgERZbS90MA8X6Cu+7t3wZu
-CPZd8d3rAUADdVVvKzOEUSxMJwPHSzNqA0hMgbZlaGTqJwhvKQhwDpdY8z2C
-F3hYgdpqBXcxiI4B547HIYBvyVIrJsIHa67pqF6CJ6ACAP/vALfmax7gHWSC
-9C5xPCWBZHRwJ6ACQQDv7X5hhI3q395w3q5x3l4CmIZgiYXYHfxxIC9el/AL
-wQkSKCiEVjbwVNxmJq/x/yd4ASpYAhp/giUAcB1HaSF45CznagbcF2awcQW4
-4ZregSfYcCl4AjZ/ckCHZQiucGpKAyyfc8KO3VqwcZd2UfTlcxpXc0qXAkr/
-7RneAUAegDJIbkUvcRungvDObkylAktP8yx4glTfgSXIgt8GY4784U9Xbj1A
-A0enAjGXUja39FT/c0tXc0z/YvFCg0SfdcIGAwWwcf7OdbPs81b38x1wdSlY
-9fHm8QM39iwvhjbnbVIvUARQ81639F+n8Rz/2rXFdsImgzQP8INW9T6XAnjP
-Ang/9XJPWFlHd67WBWB39IOmglSX9yzIgiWY9z+vd073dHwnbD+gAjYHcAjs
-dv/ejoOAl/Y4kAKJ928oV+gjWL6EV289kINBJwVcf+EXrm1VD/hWl/hWF3hA
-53doFO2OH20kWHP/XgIxz2Y+jwMqiIMn0Hkv8IIl4HlAr3GOJPGYh2Q9gHc2
-b/gB/uxUfAIvyIKol3iq5/k1X4IWJaVzP/pc1oVUH3r/juqcneyA94I4OPuJ
-l3eh7+1UJF6uV/h/H/gnKO5sLmR/P3u8zwK8//NtT8VCQPi3F2c0GPhoH/So
-pmEqMHu8X3x/b3yzLL3AJ2x5h/eBx3UqB+gjMHvF13yJ//cv9ufIJ2yvF/iB
-l3LznlkEiIOf1/yfv4KJ/3wINPrQL14kEHh5r/wZBl//gN6BK7gCL+j91Xd9
-0jfwMph9rgaDP+jz218CijVgVjRgReh96Zd+V4+DAm1o48/cqLd9wg/jGs70
-6Q//oJ/7700DmM9+SEYDi3d1vYdqL7bdYgj/6c8Chs/ZAXgC9HdoRdD7Z5eC
-PwAIBQgEDkQg5coVPgkXZsnihcqANAMQoAFg8SLGjBo3cuzo8SPIkCJHkixp
-8mRJPw0bPnkiZQeCIzsm7liCcOHNK1moPJmIYAAYlEKHEi1q9CjSk5GyLMki
-hSUCBDB3KNiRRaFCnA3jwPSZ9CvYsGLHGkXzJo4UtFx37JDJ1qoihFmvePGS
-Lw7En/zI8u3r929SMHGyoHX6/5JtVKn55N7k4yUOZJhHEAgCbPky5swXL3hZ
-mfbJVKlSs+Bk/HjtgB1UNLNu7RopYbUNQ7+92lihIshcByog8/o38OAe9ajU
-bfUtYrhY5So6vcRnReHSp/+OpJtwFuRvF5dGWDfOksRyqJMvf1mwbrXaazJO
-mFWRouwxo5uvbx+sruuQD7+lYjPrXFfEVUxittx3IIJFnbZfHKRoZ1N7pe2m
-AH0JWnghSEgsGNkOfyzBFim2LRTgG1LtMB6GKaqYkS4IpSdFSzGy11hOCE1V
-xoo5rshHc9fF2NISVMQFYHvZ1aQjkheCcUV6cfwIWlNxjVjjW7okeeV9LboI
-GVMtSf+xBJhDCticlFd8uEOFWKo5HV1tQvaEk09kFyZCiixRDJgNnbnDBWv6
-KR0S3p2WxRNLFMpUUzp9KcUfpLzw6Asd7qLHn5X+5h1dg1k12BJSOIroH39A
-+igeO4BGqaWpahYJpo/l2VCojy4x6gtAPArEl0ugqCqvgC3ZKqdZvDArpMQC
-YWutQIAJZp+9OsuXHjfV1dBTX976AqO04gGEh8QG9Sy4Yi05mBTllruEqI9W
-G2q6j8b6KBLhyvsVGG9QO6uH7/7xxpfp4urhqEBYOS/BRsWR77voqtsvpEBc
-ETAQuxQ8MVH5KHytudgyXOuwUshhy8fxUjzySWAQmyy2sf5pwaiotsZaDMkx
-CwWGHKSQsjK/7b6g8sVAyPzzzIq80fMLCOXcLtBJm1TvxTvbtDEQpCg99UhL
-8luuqCu/C4TIVHvtkdUsu5tuMV1/ffZGOoF5q9S6oIo23Bsp8u4LZsd9N0YX
-ECv1mgEBADs=
diff --git a/tclxml-3.2/examples/tclxslt/tkxsltproc.gif b/tclxml-3.2/examples/tclxslt/tkxsltproc.gif
deleted file mode 100644
index c1faa27..0000000
Binary files a/tclxml-3.2/examples/tclxslt/tkxsltproc.gif and /dev/null differ
diff --git a/tclxml-3.2/examples/tclxslt/tkxsltproc.tcl b/tclxml-3.2/examples/tclxslt/tkxsltproc.tcl
deleted file mode 100644
index 8b095a4..0000000
--- a/tclxml-3.2/examples/tclxslt/tkxsltproc.tcl
+++ /dev/null
@@ -1,1548 +0,0 @@
-#!/bin/sh
-# \
-exec wish "$0" "$@"
-
-# tkxsltproc --
-#
-#	Simple GUI for xsltproc-style transformations
-#
-# Copyright (c) 2005-2007 Explain
-# http://www.explain.com.au
-# Copyright (c) 2003-2004 Zveno
-# http://www.zveno.com/
-#
-# See the file "LICENSE" in this distribution for information on usage and
-# redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
-#
-# $Id: tkxsltproc.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-# Global initialisation
-
-set VERSION 1.9
-
-# Temporary hack for TclApp-wrapped executables
-lappend auto_path [file dirname [info nameofexecutable]]
-
-# v3.1+ gives us the "-indent", "-resulturi" and "-profilefilename" options
-package require xslt 3.2
-
-package require msgcat
-catch {namespace import ::msgcat::mc}
-
-package require uri 1.2
-
-# We need common routines from tkxmllint
-source [file join [file dirname [info script]] common.tcl]
-
-# Pre-load "standard" XSLT extension packages
-
-catch {
-    package require xslt::resources
-    ::xslt::extension add http://www.zveno.com/resources ::xslt::resources
-}
-catch {
-    package require xslt::process
-    ::xslt::extension add http://www.zveno.com/process ::xslt::process
-}
-catch {
-    package require xslt::utilities
-    ::xslt::extension add http://www.zveno.com/utilities ::xslt::utilities
-}
-
-tk appname tkxsltproc
-
-# Init --
-#
-#	Create the GUI
-#
-# Arguments:
-#	win	toplevel window
-#
-# Results:
-#	Tk widgets created
-
-proc Init win {
-    upvar \#0 State$win state
-
-    if {[info exists state(initialised)]} {
-	return
-    }
-
-    set w [expr {$win == "." ? {} : $win}]
-
-    array set state {
-	src {}
-	ssheet {}
-	result {}
-	cwd {}
-	profile 0
-	profilefilename {}
-	nonet 0
-	nowrite 0
-	nomkdir 0
-	writesubtree None
-    }
-
-    wm title $win "Tk XSLTPROC"
-
-    switch [tk windowingsystem] {
-	aqua -
-	classic {
-	    set metakey Command
-	    set metakeylabel Command-
-	}
-	default {
-	    set metakey Control
-	    set metakeylabel Ctrl+
-	}
-    }
-
-    menu $w.menu -tearoff 0
-    $win configure -menu $w.menu
-    $w.menu add cascade -label [mc File] -menu $w.menu.file
-    menu $w.menu.file -tearoff 0
-    $w.menu.file add command -label [mc {New Window}] -command NewWindow -accel ${metakeylabel}N
-    bind $win <${metakey}-n> NewWindow
-    $w.menu.file add separator
-    $w.menu.file add command -label [mc {Reload Stylesheet}] -command [list Compile $win] -accel ${metakeylabel}R
-    bind $win <${metakey}-r> [list Compile $win]
-    if {[tk windowingsystem] != "aqua"} {
-	$w.menu.file add separator
-	$w.menu.file add command -label [mc Preferences...] -command Preferences
-	$w.menu.file add separator
-	$w.menu.file add command -label [mc Quit] -command {destroy .} -accel ${metakeylabel}Q
-    }
-    bind $win <${metakey}-q> {destroy .}
-
-    $w.menu add cascade -label [mc Help] -menu $w.menu.help
-    menu $w.menu.help -tearoff 0
-    $w.menu.help add command -label [mc {About tkxsltproc}] -command tkAboutDialog -accel ${metakeylabel}?
-    # This fails on Linux
-    catch {bind $win <${metakey}-?> tkAboutDialog}
-
-    if {[tk windowingsystem] == "aqua"} {
-	$w.menu add cascade -label tkxsltproc -menu $w.menu.apple
-	menu $w.menu.apple -tearoff 0
-	$w.menu.apple add command -label [mc {About tkxsltproc}] -command tkAboutDialog
-	$w.menu.apple add command -label [mc Preferences...] -command Preferences
-    }
-
-    frame $w.controls
-    grid $w.controls -row 0 -column 0 -sticky ew
-    button $w.controls.xform -text [mc Transform] -command [list Transform $win]
-    button $w.controls.reload -text [mc {Reload Stylesheet}] -command [list Compile $win]
-    # TODO: add nice icons
-    grid $w.controls.xform -row 0 -column 0 -sticky w
-    grid $w.controls.reload -row 0 -column 1 -sticky w
-    grid columnconfigure $w.controls 1 -weight 1
-
-    Doc $win src -title [mc {Source Document}] -row 1
-    Doc $win ssheet -title [mc {Stylesheet Document}] -row 2 -command [list Compile $win]
-    Doc $win result -title [mc {Result Document}] -row 3 -type save
-
-    labelframe $w.options -text [mc Options]
-    grid $w.options -row 4 -column 0 -sticky ew
-    checkbutton $w.options.validate -text [mc {Skip validation}] -variable State${win}(novalidate)
-    checkbutton $w.options.timing -text [mc {Display timing}] -variable State${win}(timing)
-    checkbutton $w.options.xinclude -text [mc XInclude] -variable State${win}(xinclude)
-    checkbutton $w.options.nonet -text [mc {No network}] -variable State${win}(nonet)
-    checkbutton $w.options.nowrite -text [mc {No write}] -variable State${win}(nowrite)
-    checkbutton $w.options.nomkdir -text [mc {No mkdir}] -variable State${win}(nomkdir)
-    label $w.options.writesubtreelabel -text [mc {Write subtree}]
-    button $w.options.writesubtree -text [file tail $state(writesubtree)] -command [list WriteSubtree $win]
-    button $w.options.profile -text [mc Profile...] -command [list Profile $win]
-    if {$::tcl_platform(platform) == "windows"} {
-	$w.options.profile configure -state disabled
-    }
-    button $w.options.security -text [mc Security...] \
-	-command [list SecuritySettings $win]
-
-    ### xsltproc options not yet provided
-    # novalid
-    # nodtdattr
-    # maxdepth
-    # maxparserdepth
-    # catalogs
-    # load-trace
-
-    grid $w.options.validate -row 0 -column 0 -sticky w
-    grid $w.options.timing -row 0 -column 1 -sticky w
-    grid $w.options.xinclude -row 1 -column 0 -sticky w
-    grid $w.options.profile -row 1 -column 1 -sticky w
-    grid $w.options.nonet -row 0 -column 2 -sticky w
-    grid $w.options.nowrite -row 1 -column 2 -sticky w
-    grid $w.options.nomkdir -row 0 -column 3 -sticky w
-    grid $w.options.writesubtreelabel -row 1 -column 3 -sticky e
-    grid $w.options.writesubtree -row 1 -column 4 -sticky w
-    grid columnconfigure $w.options 5 -weight 1
-
-    labelframe $w.parameters -text [mc Parameters]
-    ShowParameters $win
-    text $w.parameters.t -wrap none -height 8 \
-	-xscrollcommand [list $w.parameters.xs set] \
-	-yscrollcommand [list $w.parameters.ys set]
-    scrollbar $w.parameters.xs -orient horizontal \
-	-command [list $w.parameters.t xview]
-    scrollbar $w.parameters.ys -orient vertical \
-	-command [list $w.parameters.t yview]
-    $w.parameters.t insert end [mc {No parameters defined}]
-    $w.parameters.t configure -tabs {4c right 5c left} -state disabled
-    grid $w.parameters.t -row 0 -column 0 -sticky news
-    grid $w.parameters.xs -row 1 -column 0 -sticky ew
-    grid $w.parameters.ys -row 0 -column 1 -sticky ns
-    grid columnconfigure $w.parameters 0 -weight 1
-
-    set state(messages) [labelframe $w.messages -text [mc Messages]]
-    grid $w.messages -row 7 -column 0 -sticky news
-    text $w.messages.log -wrap none \
-	-state disabled \
-	-xscrollcommand [list $w.messages.xscroll set] \
-	-yscrollcommand [list $w.messages.yscroll set]
-    scrollbar $w.messages.xscroll -orient horizontal \
-	-command [list $w.messages.log xview]
-    scrollbar $w.messages.yscroll -orient vertical \
-	-command [list $w.messages.log yview]
-    grid $w.messages.log -row 0 -column 0 -sticky news
-    grid $w.messages.yscroll -row 0 -column 1 -sticky ns
-    grid $w.messages.xscroll -row 1 -column 0 -sticky ew
-    grid rowconfigure $w.messages 0 -weight 1
-    grid columnconfigure $w.messages 0 -weight 1
-
-    SetProperties $win $w.messages.log
-
-    frame $w.feedback
-    grid $w.feedback -row 8 -column 0 -sticky ew
-    label $w.feedback.msg -textvariable State${win}(feedback)
-    set state(progress) [canvas $w.feedback.progress \
-			     -width 100 -height 25]
-    set state(progressbar) [$w.feedback.progress create rectangle 0 0 1 25 \
-				-fill blue -disabledfill white -state disabled]
-    grid $w.feedback.progress -row 0 -column 0
-    grid $w.feedback.msg -row 0 -column 1 -sticky ew
-    grid columnconfigure $w.feedback 1 -weight 1
-
-    grid rowconfigure $win 7 -weight 1
-    grid columnconfigure $win 0 -weight 1
-
-    set state(initialised) 1
-
-    return {}
-}
-
-# tkAboutDialog --
-#
-#	Information about this application
-#
-# Arguments:
-#	None
-#
-# Results:
-#	Displays window
-
-proc tkAboutDialog {} {
-    catch {destroy .about}
-    toplevel .about
-    catch {::tk::unsupported::MacWindowStyle style .about floatProc}
-    wm title .about [mc {About tkxsltproc}]
-    label .about.libxsltlogo -image libxsltLogo
-    label .about.tcllogo -image tclLogo
-    label .about.tkxsltproclogo -image tkxsltprocLogo
-    text .about.msg -width 40 -height 10 -font Arial
-    .about.msg insert end [mc [format "tkxsltproc - A GUI for xsltproc
-
-Version %s
-
-Powered by:
-\tlibxml2\tv%s
-\tlibxslt\tv%s
-\tlibexslt\tv%s
-\tTclXSLT\tv%s
-\tTcl/Tk\tv%s
-
-http://tclxml.sourceforge.net/tkxsltproc.html
-" $::VERSION $::xml::libxml2::libxml2version \
-	$::xslt::libxsltversion $::xslt::libexsltversion \
-	[package require xslt] [info patchlevel]]]
-
-    .about.msg configure -state disabled
-
-    grid .about.tkxsltproclogo -row 0 -column 0 -rowspan 2 -sticky news
-    grid .about.msg -row 0 -column 1 -rowspan 2 -sticky news -padx 20 -pady 20
-    grid .about.libxsltlogo -row 0 -column 2 -sticky news
-    grid .about.tcllogo -row 1 -column 2 -sticky news
-    grid rowconfigure .about 0 -weight 1
-    grid rowconfigure .about 1 -weight 1
-    grid columnconfigure .about 1 -weight 1
-
-    return {}
-}
-
-# Preferences --
-#
-#	Manage application preferences
-#
-# Arguments:
-#	None
-#
-# Results:
-#	Preferences dialog displayed
-
-proc Preferences {} {
-    catch {destroy .prefs}
-    toplevel .prefs
-    wm title .prefs [mc {tkxsltproc Preferences}]
-
-    labelframe .prefs.extensions -text [mc Extensions]
-
-    grid .prefs.extensions -row 0 -column 0 -sticky news
-    grid columnconfigure .prefs 0 -weight 1
-
-    button .prefs.extensions.load -text [mc Load] -command [list Preferences:LoadExtension]
-    entry .prefs.extensions.script -textvariable ::preferences(extensionScript)
-    button .prefs.extensions.browse -text [mc Browse] -command [list Preferences:Browse]
-
-    grid .prefs.extensions.load - -row 0 -column 0 -sticky w
-    grid .prefs.extensions.script -row 1 -column 0 -sticky ew
-    grid .prefs.extensions.browse -row 1 -column 1 -sticky e
-    grid columnconfigure .prefs.extensions 0 -weight 1
-
-    return {}
-}
-
-proc Preferences:LoadExtension {} {
-    set fname [.prefs.extensions.script get]
-
-    if {![string length $fname]} {
-	tk_messageBox -icon warning -message [mc {No extension script has been given}]
-	return {}
-    }
-    if {![file readable $fname]} {
-	tk_messageBox -icon error -message [mc {Unable to open extension script}]
-	return {}
-    }
-    if {[catch {uplevel \#0 source $fname} err]} {
-	tk_messageBox -icon error -message "An error occurred while loading the extension\n$err"
-	return {}
-    }
-
-    return {}
-}
-
-proc Preferences:Browse {} {
-    set fname [tk_getOpenFile -title [mc {Load Extension Script}]]
-    if {![string length $fname]} {
-	return {}
-    }
-    .prefs.extensions.script delete 0 end
-    .prefs.extensions.script insert 0 $fname
-
-    return {}
-}
-
-proc WriteSubtree {win} {
-    upvar \#0 State$win state
-
-    set w [expr {$win == "." ? {} : $win}]
-
-    set dir [tk_chooseDirectory -parent $win -title [mc {Choose Write Subtree}] \
-		   -mustexist 1 -initialdir [expr {$state(writesubtree) == "None" ? [pwd] : $state(writesubtree)}]]
-    if {$dir != ""} {
-	set state(writesubtree) $dir
-	$w.options.writesubtree configure -text [file tail $dir]
-    }
-}
-
-proc Profile win {
-    upvar \#0 State$win state
-
-    set w [expr {$win == "." ? {} : $win}]
-
-    catch {destroy .profile}
-    toplevel .profile
-    wm title .profile [mc {tkxsltproc Profile}]
-
-    set f [labelframe .profile.f -text [mc Profile]]
-    grid $f -row 0 -column 0 -sticky news
-    grid columnconfigure .profile 0 -weight 1
-
-    checkbutton $f.state -text [mc Enabled] -variable State${win}(profile)
-    entry $f.fname -textvariable State${win}(profilefilename) -width 30
-    button $f.browse -text [mc Browse] -command [list Profile:Browse $win]
-    grid $f.state - -row 0 -column 0 -sticky ew
-    grid $f.fname -row 1 -column 0 -sticky ew
-    grid $f.browse -row 1 -column 1 -sticky w
-    grid columnconfigure $f 0 -weight 1
-
-    return {}
-}
-
-proc Profile:Browse win {
-    upvar \#0 State$win state
-
-    set fname [tk_getSaveFile -title [mc {Save Profiling Data}]]
-    if {![string length $fname]} {
-	return {}
-    }
-
-    set state(profilefilename) $fname
-
-    return {}
-}
-
-# Doc --
-#
-#	Setup a document pane
-#
-# Arguments:
-#	win	toplevel window
-#	p	pane
-#	args	configuration options
-#
-# Results:
-#	Widgets created and positioned
-
-proc Doc {win p args} {
-    upvar \#0 State$win state
-
-    set w [expr {$win == "." ? {} : $win}]
-
-    array set options {
-	-type open
-	-title {}
-	-command {}
-    }
-    array set options $args
-
-    labelframe $w.$p -text $options(-title)
-    grid $w.$p -row $options(-row) -column 0 -sticky ew
-    label $w.$p.url -text [mc URL:]
-    entry $w.$p.urlentry -width 60 -textvariable State${win}(${p})
-    button $w.$p.browse -text [mc Browse] -command [list Browse $win $p -title $options(-title) -type $options(-type) -command $options(-command)]
-    grid $w.$p.url -row 0 -column 0 -sticky w
-    grid $w.$p.urlentry -row 0 -column 1 -sticky ew
-    grid $w.$p.browse -row 0 -column 2 -sticky e
-    grid columnconfigure $w.$p 1 -weight 1
-
-    return {}
-}
-
-# NewWindow --
-#
-#	Create another toplevel window
-#
-# Arguments:
-#	None
-#
-# Results:
-#	Tk toplevel created and initialised
-
-proc NewWindow {} {
-    global counter
-
-    Init [toplevel .top[Incr counter]]
-
-    return {}
-}
-
-# Compile --
-#
-#	Manage loading the stylesheet
-#
-# Arguments:
-#	win	toplevel window
-#
-# Results:
-#	Compiles stylesheet, adds widgets for parameters
-
-proc Compile {win} {
-    global stylesheets
-    upvar \#0 State$win state
-
-    set w [expr {$win == "." ? {} : $win}]
-
-    Log clear $win
-    catch {unset state(stylesheetLoaded)}
-
-    Feedback $win [mc {Loading stylesheet document}]
-    if {[catch {LoadDoc $win ssheet [mc stylesheet]} ssheetdoc]} {
-	puts stderr "Compile: unable to load stylesheet due to \"$ssheetdoc\""
-	return {}
-    }
-
-    Feedback $win [mc {Compiling stylesheet}]
-    set time(precompile) [clock clicks -milliseconds]
-    if {[catch {XSLTCompile $win $ssheetdoc} ssheet]} {
-	Log add $win $ssheet
-	Feedback $win [mc {Compiling stylesheet failed}]
-	after 2000 [list Feedback $win {}]
-	return {}
-    }
-    set time(compile) [clock clicks -milliseconds]
-    Log timing $win "Compiling stylesheet took [expr $time(compile) - $time(precompile)]ms\n"
-
-    set state(ssheet_cmd) $ssheet
-    set stylesheets($ssheet) $win
-
-    $ssheet configure -messagecommand [list messages $win]
-
-    PopulateParams $win
-
-    set state(stylesheetLoaded) $state(ssheet:mtime)
-
-    Feedback $win [mc {Loading stylesheet completed}]
-    after 2000 [list Feedback $win {}]
-
-    return {}
-}
-
-# XSLTCompile --
-#
-#	Stub for compilation of the stylesheet
-#
-# Arguments:
-#	win	toplevel window
-#	doc	DOM document token of stylesheet to compile
-#
-# Results:
-#	Returns stylesheet command or error message
-
-proc XSLTCompile {win doc} {
-    return [::xslt::compile $doc]
-}
-
-# PopulateParams --
-#
-#	Add widgets for stylesheet parameters
-#
-# Arguments:
-#	win	toplevel window
-#
-# Results:
-#	Widgets added for each stylesheet parameter
-
-proc PopulateParams win {
-    upvar \#0 State$win state
-    upvar \#0 Parameters$win params
-
-    set w [expr {$win == "." ? {} : $win}]
-    set t $w.parameters.t
-
-    ShowParameters $win
-
-    $t configure -state normal
-
-    foreach child [winfo children $w.parameters.t] {
-	destroy $child
-    }
-    $t delete 1.0 end
-
-    set state(parameters) {}
-
-    set parameters [$state(ssheet_cmd) get parameters]
-    if {[llength $parameters] == 0} {
-	HideParameters $win
-    }
-
-    foreach parameter [lsort $parameters] {
-	foreach {name ns select} $parameter break
-
-	# Bug workaround: Variables cannot be resolved when passed
-	# in as parameters, so do not attempt to set a default
-	# value that computes using a variable reference.
-	if {[string first \$ $select] >= 0} {
-	    set select {}
-	}
-
-	# Workaround #2: XPath select expressions may need to be
-	# resolved against the base URI of the stylesheet that
-	# defines the parameter.
-	if {![regexp {^("|').*("|')$} $select]} {
-	    set select {}
-	}
-
-	if {[string first . $name] >= 0} {
-	    set splitname [split $name .]
-	    set head [lindex $splitname 0]
-	    if {[winfo exists $t.menu$head]} {
-		if {[winfo class $t.menu$head] != "Menubutton"} {
-		    Log add $win "Unable to add parameter entry for \"$name\""
-		    continue
-		}
-	    } else {
-		menubutton $t.menu$head -text $head -menu $t.menu$head.menu
-		menu $t.menu$head.menu -tearoff 0
-		$t window create end -window $t.menu$head
-		$t insert end \n
-		$t insert end \t\t
-		entry $t.menu${head}_value -width 50
-		bindtags $t.menu${head}_value "[bindtags $t.menu${head}_value] parameter"
-		$t window create end -window $t.menu${head}_value
-		$t insert end \n
-	    }
-	    set root .menu
-	    foreach step [lrange $splitname 1 [expr [llength $splitname] - 2]] {
-		if {![winfo exists $t.menu$head${root}_$step]} {
-		    $t.menu$head$root insert 0 cascade -label $step \
-			-menu $t.menu$head${root}_$step
-		    menu $t.menu$head${root}_$step -tearoff 0
-		}
-		append root _$step
-	    }
-	    set tail [lindex $splitname end]
-	    set m $t.menu$head$root
-	    $m insert 0 command -label $tail -command [list NestedParameter $win $name $ns $t.menu$head $t.menu$head$root $t.menu${head}_value]
-	    set params($name) $select
-	    lappend state(parameters) [list $name $ns [list set ::Parameters${win}($name)]]
-	} else {
-	    entry $t.value$name -width 50
-	    if {[string length $name] > 15} {
-		$t insert end $name\n\t\t
-	    } else {
-		$t insert end \t$name\t
-	    }
-	    $t.value$name insert 0 $select
-	    $t window create end -window $t.value$name -stretch yes -align center
-	    $t insert end \n
-
-	    lappend state(parameters) [list $name $ns [list $t.value$name get]]
-	}
-    }
-
-    $t configure -state disabled
-
-    return {}
-}
-
-proc ShowParameters {win} {
-    upvar \#0 State$win state
-
-    set w [expr {$win == "." ? {} : $win}]
-
-    grid $w.parameters -row 6 -column 0 -sticky news
-
-    return {}
-}
-
-proc HideParameters {win} {
-    upvar \#0 State$win state
-
-    set w [expr {$win == "." ? {} : $win}]
-
-    grid forget $w.parameters
-
-    return {}
-}
-
-# NestedParameter --
-#
-#	Displays parameter value for a "nested" parameter.
-#
-# Arguments:
-#	win	toplevel window
-#	name	parameter name
-#	ns	parameter's XML Namespace
-#	mb	menu button for this parameter group
-#	menu	menu widget for this parameter
-#	entry	entry widget to display parameter select value
-#
-# Results:
-#	Widget display changed
-
-proc NestedParameter {win name ns mb menu entry} {
-    upvar \#0 State$win state
-    upvar \#0 Parameters$win select
-
-    set w [expr {$win == "." ? {} : $win}]
-
-    set t $w.parameters.t
-    $t configure -state normal
-
-    set tags [$t tag ranges $mb]
-    foreach {start end} $tags {
-	$t delete $start $end
-    }
-
-    $t insert [list $mb + 1 chars] \t$name $mb
-
-    $entry delete 0 end
-    $entry insert 0 $select($name)
-
-    bind parameter <Key> [list ChangeParameter $win $name $entry]
-
-    $t configure -state disabled
-    return {}
-}
-
-# ChangeParameter --
-#
-#	Keep track of parameter values
-#
-# Arguments:
-#	win	toplevel window
-#	name	parameter name
-#	entry	entry widget containing value
-#
-# Results:
-#	State variable updated
-
-proc ChangeParameter {win name entry} {
-    upvar \#0 State$win state
-    upvar \#0 Parameters$win select
-
-    set w [expr {$win == "." ? {} : $win}]
-
-    set select($name) [$entry get]
-
-    return {}
-}
-
-# Transform --
-#
-#	Perform XSL transformation and display report
-#
-# Arguments:
-#	win	toplevel window
-#
-# Results:
-#	Documents read into memory, parsed, transformed and report displayed
-
-proc Transform win {
-    upvar \#0 State$win state
-
-    set w [expr {$win == "." ? {} : $win}]
-
-    Log clear $win
-
-    if {![info exists state(stylesheetLoaded)]} {
-	tk_messageBox -parent $win -message [mc "Stylesheet has not been loaded"] -type ok
-	return {}
-    }
-
-    set time(start) [clock clicks -milliseconds]
-
-    Feedback $win [mc {Loading source document}]
-    if {[catch {LoadDoc $win src [mc source]} srcdoc]} {
-	return {}
-    }
-    if {![info exists state(ssheet_cmd)] || \
-	[string equal $state(ssheet_cmd) {}] || \
-	    $state(stylesheetLoaded) < [LastModTime $state(ssheet)]} {
-	Compile $win
-    }
-
-    set parameters {}
-    foreach parameter $state(parameters) {
-	foreach {name ns entry} $parameter break
-	set value [eval $entry]
-	if {[string length $value]} {
-	    lappend parameters $name $value
-	}
-    }
-
-    $state(ssheet_cmd) configure -resulturi [$w.result.urlentry get]
-    if {$state(profile)} {
-	if {[catch {open $state(profilefilename) w} profilech]} {
-	    tk_messageBox -icon error -type ok -parent $win -message "Unable to write profiling data to \"$state(profilefilename)\" due to \"$profilech\""
-	    return {}
-	}
-	$state(ssheet_cmd) configure -profilechannel $profilech
-    }
-
-    Feedback $win [mc {Perform transformation}]
-    if {[catch {eval $state(ssheet_cmd) transform [list $srcdoc] $parameters} resultdoc]} {
-	catch {close $profilech}
-	Log add $win $resultdoc
-	Feedback $win [mc {Transformation failed}]
-	after 2000 [list Feedback $win {}]
-	return {}
-    }
-    catch {close $profilech}
-    set time(xform) [clock clicks -milliseconds]
-    Log timing $win "Transformation took [expr $time(xform) - $time(start)]ms\n"
-
-    # When the stylesheet's method is NULL, the type of the result document
-    # determines the default output method.
-    set method [$state(ssheet_cmd) cget -method]
-    switch -glob -- $method,[dom::node cget $resultdoc -nodeType] {
-	,HTMLdocument {
-	    set method html
-	}
-	,* {
-	    set method xml
-	}
-    }
-
-    if {[string length $state(result)]} {
-
-	set fname {}
-	set state(result) [$w.result.urlentry get]
-	if {[catch {uri::split $state(result)} spliturl]} {
-	    # Treat as a pathname
-	    set fname $state(result)
-	    set state(result) file:///$state(result)
-	} else {
-	    array set urlarray $spliturl
-	    switch -- $urlarray(scheme) {
-		http {
-		    tk_messageBox -message "Saving to a http URL is not yet supported" -parent $win -type ok -icon warning
-		    Log add $win [Serialize $win $resultdoc -method [$state(ssheet_cmd) cget -method]]
-		}
-		file {
-		    set fname $urlarray(path)
-		}
-		default {
-		    tk_messageBox -message "Saving to a \"$urlarray(scheme)\" type URL is not supported" -parent $win -type ok -icon warning
-		    Log add $win [Serialize $win $resultdoc -method [$state(ssheet_cmd) cget -method]]
-		}
-	    }
-	}
-
-	if {[string length $fname] && [catch {open $fname w} ch]} {
-	    Log add $win $ch
-	    Feedback $win [mc {Unable to save result}]
-	    after 2000 [list Feedback $win {}]
-	    return {}
-	}
-	fconfigure $ch -encoding utf-8
-	puts $ch [Serialize $win $resultdoc -method $method -indent [$state(ssheet_cmd) cget -indent]]
-	close $ch
-    } else {
-	Log add $win [Serialize $win $resultdoc -method $method -indent [$state(ssheet_cmd) cget -indent]]
-    }
-    set time(finish) [clock clicks -milliseconds]
-    Log timing $win "saving result took [expr $time(finish) - $time(xform)]ms\n"
-    Log timing $win "total time for processing: [expr $time(finish) - $time(start)]ms\n"
-
-    Feedback $win [mc {Processing completed}]
-    after 2000 [list Feedback $win {}]
-
-    return {}
-}
-
-# Serialize --
-#
-#	Stub for serializing DOM document
-#
-# Arguments:
-#	win	toplevel window
-#	doc	DOM document
-#	args	additional arguments
-#
-# Results:
-#	Document text
-
-proc Serialize {win doc args} {
-    return [eval dom::serialize [list $doc] $args]
-}
-
-# messages --
-#
-#	Display messages emitted by the stylesheet
-#
-# Arguments:
-#	win	toplevel window
-#	args	messages
-#
-# Results:
-#	Updates message display
-
-proc messages {win args} {
-    upvar \#0 State$win state
-
-    foreach msg $args {
-	if {[catch {Log addMessage $win "$msg"} errmsg]} {
-	    puts stderr "messages: $args"
-	}
-    }
-    update
-
-    return {}
-}
-
-# LoadDoc --
-#
-#	Load a document into an in-memory DOM tree
-#
-# Arguments:
-#	win	toplevel window
-#	type	type of document
-#	label	display label
-#
-# Results:
-#	Returns DOM tree token
-
-proc LoadDoc {win type label} {
-    upvar \#0 State$win state
-
-    set w [expr {$win == "." ? {} : $win}]
-
-    set state($type) [$w.$type.urlentry get]
-
-    if {![string length $state($type)]} {
-	tk_messageBox -parent $win -type ok -icon error -message [mc "You haven't specified a $label document"]
-	return -code error "unable to load $label document"
-    }
-
-    if {[catch {uri::split $state($type)} spliturl]} {
-	# Try the URL as a pathname
-	set fname $state($type)
-	set state($type) file:///$state($type)
-	array set urlarray {scheme file}
-    } else {
-	array set urlarray $spliturl
-	switch -- $urlarray(scheme) {
-	    http {
-		set fname $state($type)
-	    }
-	    file {
-		set fname $urlarray(path)
-	    }
-	    default {
-		tk_messageBox -message "\"$urlarray(scheme)\" type URLs are not supported" -parent $win -type ok -icon warning
-		return -code error "unable to load $label document"
-	    }
-	}
-    }
-
-    set time(start) [clock clicks -milliseconds]
-
-    if {[catch {ReadAndParseXML $win $type $fname $state($type) time \
-		    -noent 1 -nonet $state(nonet)} doc]} {
-	return
-    }
-
-    set state(${type}:mtime) 0
-    # HTTP downloads will not have mtime set
-    catch {set state(${type}:mtime) [file mtime $fname]}
-    set state(${type}_doc) $doc
-
-    # BUG WORKAROUND: store the source doc's directory
-    set state(${type}_dir) {}
-    catch {set state(${type}_dir) [file dirname $fname]}
-
-    return $doc
-}
-
-# LastModTime --
-
-proc LastModTime {uri} {
-    if {[catch {uri::split $uri} spliturl]} {
-	# Try the URL as a pathname
-	set fname $uri
-    } else {
-	array set urlarray $spliturl
-	switch -- $urlarray(scheme) {
-	    http {
-		# Not yet supported
-		return 0
-	    }
-	    file {
-		set fname $urlarray(path)
-	    }
-	    default {
-		return 0
-	    }
-	}
-    }
-
-    return [file mtime $fname]
-}
-
-# ::xslt::security --
-#
-#	Implement restrictions on stylesheet operations
-#
-# Arguments:
-#	name	name of requesting stylesheet
-#	op	requested operation
-#	value	additional info
-#
-# Results:
-#	Returns boolean
-
-proc ::xslt::security {name op value} {
-    global stylesheets
-
-    upvar #0 State$stylesheets($name) state
-
-    switch -- $op {
-	readfile {
-	    return 1
-	}
-	writefile {
-	    if {$value == {}} {
-		# This is the console
-		return 1
-	    } elseif {!$state(nowrite)} {
-		if {$state(writesubtree) != "None"} {
-		    set towrite [file split [file normalize $value]]
-		    set ok 1
-		    set split [file split $state(writesubtree)]
-		    for {set count 0} {$count < [llength $split]} {incr count} {
-			if {[lindex $towrite $count] != [lindex $split $count]} {
-			    set ok 0
-			}
-		    }
-		    return $ok
-		} else {
-		    return 1
-		}
-	    } else {
-		return 0
-	    }
-	}
-	createdirectory {
-	    return [expr !$state(nomkdir)]
-	}
-	readnetwork -
-	writenetwork {
-	    if {$state(nonet) && \
-		    ([string match http://* $value] || \
-		     [string match ftp://* $value])} {
-		return 0
-	    } else {
-		return 1
-	    }
-	}
-    }
-    # shouldn't be here
-    return 0
-}
-
-### Image data - end of script
-
-image create photo libxsltLogo -data {
-R0lGODlhtABEAPf/AP///wAAAP7+/vz8/AUKAjU1Mvv7+729vd7e3SwtKWJi
-XPb29pKTjpSVkUtMSoODfIuMiXFyb/T09La2sYmKhpmaldnZ2BscGtHRzdXV
-1fPz8yQmI9LS0c3NyeHh4ZydmWprZDs8OdnZ1UtSUubm5sXFweTk5P39/Q4O
-DcnJxfj4+FlaVTEyLsHBvL6+ufDw8BMWEnR1ckNFQtXV0YGCgPLy8rm5sQAE
-ACwwKu7u7qysqvL18SgqJnFycAACALm5rFFSTbKyprW1ruTl4q2tpTk5N0RL
-TKGhnaSkoezs7DtFRm9wbcrKyMHBudzc2icpJPr6+s7OzElKRuDg3mxuah4i
-HWVmZMnJwgIHAGpsaenp6FZYVn1+fOjo5rGxrhEWDmRlYrm6tcbGw8LCwMzM
-xfb49cXFvXp8eYSFgl1dWO3u7KmpoXh5djI1L7Gxqebm5GFiYHx9el1eXKam
-mu/x7qampcDAtOrq6hQYE3d4dWdoZYKDgaWlnXZ2dO7w7uzs6mlqaH+Afvv6
-+L29tnl7eKCgmvP18qqqpTY4NX19cV9gXebp6mJjYVpaWXJ0cQ4SDPX29KCg
-lVpcWr29sfPz8lpdXebo5oWHhOrs6UFDP5eYlFdXVSEjHqqqnff69ldaWcXF
-uVVVUXt7cFFSUOnr6Pn8+EZIRK6uoo6QjBgYFlBUU4eIhQoKCU5QTK6vq1FX
-Vezu6+js7dDQysjIvbq7uUFHSfHx8ba2qAsPCaeno/X19V1hYL6/vMfIxejq
-5z4/PAQHAQMDA0lPUC02NgwMC6GioOTm5AYLBCYrKNrb2dbZ2s3S1OLl4dPT
-zp2fnH19duzu7qKkoSAlIwYGBry8uS8wLICAdczMwvv8+fz7+G1ubAgMBuHm
-6d/j5vH08NfX1re3taOjnVNXV8/PxwIFALOzq8/Qz9jc3fj799PT09PW1J6e
-j+3w8fb6+szMyvP29v3+/MPEvmJlZdvf4MPEw6Sjm4iHgrO0ruDi36+vp29y
-cPv7+gIGApCQjQIIAICAgCH5BAEAAP8ALAAAAAC0AEQAAAj/AP8JFBjIkYNq
-wQIoXMiwocOHECNKnEixosWLGDM+DFbNgaNAA0MK5MJCo8mTKFOqXImSBReR
-Aq2wChBsVJ0oJwDo3Mmzp8+fQIMKHUq0qNGjSJP2PBGlzqiErKyIbKTwCROl
-WLNq3cq1K1YmTxQ2GthDYY8FXtOqXcu27c4FZQP0+BcoVYBNQAUIODHAgN+/
-gAMLHkzY74ABJwS4Xcx466YAqQItCTCNhM+9UFQskKChhufPoEOLHk1agwRd
-C1Qgbsy69VAS0wIscRCgkc8TBlRIeJFECwkSJoILH068uHHjv+/kqJF6gGLX
-0KNTdbAhQJ2lUBa84BBIBp4v4MOL/x9Pvrz5Lyz0gJtCQo0E1c+jt93b93B8
-AYcNx+daJ8AGFAFYwJMAUOiShDPAsBSADwv64KAPN0QoIYQKabPMFHdooBpQ
-fBkAxYdQGLCafEOdkF0NL9iyABQ5DXBiiivm1JUFAQAYgC074beAGhEEcEMA
-MJiygiRpFJmGHEgamYYkK6ywySahjAJEK604IIUpMsiQSSa//BJCEYggwgIM
-EQaATAYI3CEBFPvpZOIClOSghho55EBJcyTmZYAJzmThgAlJ6OIcFOn0+Weg
-A3hlC0M8naCCLWP4CIwpFLhCTQkliNFLCleQkUIKvYiBqRkt8EINLWFMcI8X
-ruiQSx1IFP/jzAcVaNIAA5c4sgIiuPwIQToe5LBAoj0NAE4gcbCRRx95IGFC
-F8ISm+eAKgQCYBHNIKCGCgIsYG0A2GqrQlqM7jSALiaUBAwjubiAiSCC7IPN
-vPTWi40n+HpSRhmQQKKLIYa80w6/ZRjiRw5+qBHLOQzA4cAjN/gwwTckaMDm
-gFDUEIdCF1TAQwAJMDGFGgvkpFebRp38k14DqrzTCbpoEUIABZSQDgklLyAz
-zVdkgDO5C+WY8QcLrrAGE2XAg00p2TSdTSlQoyM1Ovl6gg06/QJsSBmW0MPq
-BPh4U2ed7MTiChy/YBEAIFFMkYMKMu4ERQ65KFQAKA8oBETbwmr/hpoKKmS2
-wAK6FI5aaoAnPvjfIg6wj9+DB55d4c31tUAOQxRB8yBMeLCAALq8oXkBTZDh
-hLCpDR554iMOVS4AjuawxQ3HoHEPHfCoULW++/LbLyQAl+GHOk7sYMgOO5Tx
-DSpxnBFHHkfMCUssi/gSiyU0jNLrL704kUTJPc2NhEIsTGKHQijE08wQakSh
-QzJ30PlCDnf49lsXWiiXQ4rzuw9/DraogS2mkIwuHIIE+svBAXSQPzt1JgqH
-cAIiAsCCCYhhCp9bQOYoaAcbfGAKXbjDHTAhQuWkiDkXc13Q3LSAJLQBC6mo
-wAxKsa/fZU1rAAOeISDRhQoEggZjKIM3/yCRAntwgQZ72AMN0IAAaCziiU+M
-RS/gUIUbcGIM3+iCBKSlEwPkYHwUvMUkFjKJFLgiBA7QQwC2gAFmAAJ9mlNI
-DKJwgQCc4Q1i+AUK+oACPWBgCG+gAAoakACQJWMKdbhAAvSwRw+8oQtZCIAU
-QgEgFtyjBBgEwAJEBxna1MgVLSikJDuwChRUIxkqiltQXncuLbTBB09YAyYK
-hsNaGg8SdABeGcBBCBoQAgne8IYvGBAHGhiTBoFogCViwUzqcYMb3eBCAnxQ
-BV74bIvF+qJCqnGLSChkA5OwAYBKgIFQgGsGM6gjD2YBAoUMggwV2IQIOlDH
-CoyDCgGAwxXqGP8AHoQlAJo4RI3MMI4JQkAEMQjABcZxjbBYEpNoWQAJNJeK
-U0AAQCgYRwUUQgUyYEAK7piCFjTARaCwUgIkeOUT3ECHf9VSa8ijQxj60Ysy
-0KECR4wDEuhgCGqc4Zh7QEMgeAGNeShjGeo4RzeoBwEeUPMAPtOAAbIJxg08
-oCQBEMUkWsGza1BAIWy4Bj4DMIc5KAQEZsgCBGYQCIXMwgZhQQEZWqAQBzSg
-RjYAAs1m8QEAyWAcdQTCLGZRAAoKAaKanCgFzbcChTxgFnV8QhOuAIcMiBSb
-KlSIuVCqUi/QYQfBDK1ok8eLPORBE3TwgybiEAhCuMIbpFgtEvdwBjj/wMEL
-H0BDsmJACFTUgRc0mGYVDnAzqVJVIalQBAtCgIYwNKGOpDNDPhTSClDYQCGh
-uEV1wNkIj5qCfCwIbyuucA2FKCAIH3CDGTAaXha0AQTTDYAe7ACKwrLgsJmU
-qOZY8AM75C0ACrCDFRQyh0DkAQMe+J4qTbpCAAxAAymF5T0ASAc6BNPCFgat
-IZDABi6gAR+Q0EGHCdELQzgBDUo0CB6IgYYGEIIQeXDEErJgBTgwwgoseGpx
-p8qTAWgzANU4BRHu4QIxkIF8kzBDeRdrh0xAZh2cUAgDNiEGWUwwAD+4xQTC
-UIIUHBnA+RBCC65Avh+UwwZNmAUDFAIG+tp3/wK9yK9iWYDmNQPYBmYFsBTu
-EQUPvIBbRHmdASCs0nuoIbV+qLCivaE1EXNhD06AxDdo0Ack/CEHCEBDKFjw
-CIUEAglK5AIbYtCDGeuBEWDI8XB3XKwXgDHI5WgBBr6RTsgk+ctSQPN/qwEB
-8jVADOVUSCRs4IJeoLMZ5i0HL6LQjDqm4gc2aEEHMHDXu6T5zZjURWL3awcz
-VFsUNmiyf6QwCHOQQFBFETShJXzpsY3NG98oBtJ6wYYzMDG1OugHPvyAiW9w
-VSHbiEMdkkgDUZPa1GDAsY4rxuOdeDEc21zDBNzhgS4gwJwByIcZyBwAKtgg
-HikA0AZuUQ3ITICcG/+7cxPcEQMLzMC8h/1GMjBuj2iPIRDj+KabDTsGBGig
-W3PudjuJkYswxIMN5g2DObrwuXQ3eNAR5sE9SKEGWMBiTmp4AT5QoY9LMIMO
-94gBAzDxB0x0oT3JaEE+glsFRTQgFxC4RKhHXeos6CHhqiYuw8OnhiNskwgu
-+IZ7usAEAIGhCWig4ARc4A4MKALAt1BAAORgg15kYAYfAzAEFBGDZHA8FHBG
-gAdoASBiLAEViPgABgobADBYQ+QKKIHPga45cDahsAqYwBii0AIA9YMWHLgD
-FIyi7qjfowuw+AMp/sB8P3wjEGdgAy8M8QdwpAAWy6cDCTpQjjUcwg2HQML/
-BIoBAQrIveB0R7jCV713nkDBGfwEMiYtZgsEIKEAKGjEExzgChcwwQLJAA4B
-EA42UAgBUAhjwAEI4ATxwHqTlwFMEH+/0Dkk4ARIwE8oQAgzwAHhwE+M8AsB
-YApocEEacAI6UwSAcAEOoEdgQA2ylgwiMAoXYANYpAYltUpPt25PcA+W4Atd
-4AukEITKpwnLggRq8AcHk2gIUAyAsIJFICR74AyawACoEHdzd3B2h3cLZ1w5
-ogJq4AQpEAb3EAYUJ1U6kwwdoAOocHIlEAVOQAJdMAUf0At06Ay9wAEg1AVO
-4A65QAFeIAYcQGtM4AJh4ALmACgk8A29UAEUUGwc/5ABzSAGEJAPNnAERBAG
-CYgzjqIGxeAOJQABFVACYwCIHkACUwABrdAC7oAANbBgOKhZXbRuPOAFj2QJ
-lvCDPpgDvXAGSxANypcDb8ALFFAAP9IQx/ALaFABVXh+Bld3d7d+eseFDgdh
-FhAFTGAOCKBgAyABdzAFGZAOHJAOFpBgEkAJSWACC5iOgKIBGnAHCMABTOAO
-6eAEHjAFFoABUZAOIyMBNUACyWAO8ZgOCGACHmAB5uAOKcAETBAFGeBn3AJ1
-yTADGGAO6ZABTgAo3dgDq2B5P0N8ORh1XsAMJGCLJGmLmNALDcAEFSYGjIAL
-CuEPBBCTMqk2eLAKDGB+Sv+0Wz1ABVmYalvYcDoxAI+iBR5QioFiAHphAJej
-BcFBAkmgIi6yALbgbi/AHH5xOaY4BSagBXTClCbQHrqQGRJwjlPAHknwArxB
-AvVYllv5AsMCOypQA0kAHKXYHp4hTQGwkNoyfB4JiwAAdSrlBswwBIM5BIZp
-mG/gC+0RBVlQRzcADDIZmTIZACugCRSAYsgyahFABYBwdz7JftKoE/gxOaeh
-AgYgI6O5GRLQHCbTF4ADIvYBO9nRGRqAOISzmqqRGEKpC56xmn6hGbSJm1Dg
-HACwF0q5GaaBODUAgjLABOlgAjVwg68YANMYYU9ABAjwG29wmMawnYOZDLTh
-A5L/OZ4xSZkVsAooxgWEoJmc6Zl5x2pZ4TI9gTLzyTJEcTJtgp9BgZ8sYwCU
-UAeO4AVRkAxa0HR9SZ2xGGHIkAsTEA8YkAxOgAAIkAwZMJHuIAcBAJnkKZlY
-4AMtdglogH6jtgScaQWo9p7txxj0gRj02Rj0kRgOJgF6+A0WYAK2AJSB9pGv
-xANIQARE4AZb5gK80AJNMGYfECEbKpnA4ANw4Ao4GQii1gfOWGOfGY04qhX8
-aZzASQm1iZStkZrlyByqMQDa0QXP4pauKBTFt6PhcAhEkA/lcA82YAPUwAu8
-kAKTkaSRqTaqQAuogJ57AH3s2ZlgYGMoGppukh+N8xcs/1osk/M3m/ECfyAC
-FAAIJkAy0qkWAqCUcaIF4CAJ4KAFNQA3u6kBurAhSLGmN/AEhZALbuoGcToB
-NlCIvPBdelqe/LACRGCZqxBqhNAHMbCZhGpb1fCT2AEn8+Nuy7EAXhqUUqkD
-YUACXCmHZzAz4NIMbsOXi0GmYwABjcBPFWABJCABJsMXMJoUqroBH8AHrnoK
-+QCr97Bl9zBNevojCdAA99AAFHCZgbpbMlaiYKAIu4ADxpojAzAByPIqSIAE
-DdAHbGABbkksjjIFJXcXIoAAnrQQBdAC6dAF48IYA0APDgEBKYAAL5AoenEC
-Ktui01mdbXADG1ABR1AP7Oqj7/9aDkJQDoggnuSZIDDABq7KAOXXqwUXfQc3
-rIoABwQLmkBJIGMQSQ1xAXDgDl2AbjGKoQvxALIgAtQQf9UgBExgAmjBGBkz
-BAmVtS6QATa4qZrRHCz7E+mqCc5QCDTrqj76pkLwGOSJBcAgBQwQBpqAClXI
-r5kppSQKCCYKBwK7tFaKMbYwBAPGEESwbCaAWV5krealPjNwZSBDBIgFshIw
-BAa4EM8wARyQBH6hC0fABXcQsamqozDbABVQAc4ws+x6CLgbdhmqpD4QA2EQ
-DgzQAA2ACiC6ClAKY8G6BITKCIogB5XAuPApmgNACWbbEKcQBlGAM8QyN3nA
-EPbgAhj/sLkLkQBrMAaZxBgm2AWjqxCiIASnqwK64AQoEALJYAIvoK1O55eA
-CbMMoAma8AEfUAjhQLNIkAtEgAq4gAWRCQz84HG24mJbUAQbkABbQFuj9q+I
-W6iKUAnPW7AvowskcLYLMQemK3zPYQAvgACPRwxWQATxkAEiEEcgcwokeBjO
-oRgpi58qmxhZOiCKihiOggl+txCJMAHNIKpOUEiI0AEWoAUfe6Aua0WoILya
-MLvOMLd0Ww+5oFeReQMXgAQPjAb89CM1+auOIKx3p7hyIAmSAL0puhMqoAUi
-rBD1AA4Z8AJx82AmMAPxYANCYANRgABTIMMJEARi4AT6UwOn/wo4C8COlPDI
-lLCat/nIqNE4mlEDY1OVg6MGYKQQiWADfyQCokQ6q/gCpwnFCfqynEABDBC8
-/lvFAAzAR9AA1TGTXwABmtAPDHAGCRyTPlANDZu8WYC0lbAFjZAAN8C0PgEF
-f9AHDTEH1GABOPIyKpAD+DADZNAHYfAN9UjIt2AGh8AsXsAeamALXqADFrCd
-M1AHddAFSeAKVJsBuQCxqCEBOUAL67kKSIABbXkHnRwA1mADsoAGNgJkP9AC
-HFAxcJO/CPqXhJbMqyC4wSu8DeC/syuzegAhMbmkrVABwgsHwKChAdAKqOAI
-pdaeGiwHn7AFn4AMydy44dPMzxzNNf9gsDsyBEegOQ3QkIO8EDAAAg4ILoec
-ARm7EEUgMhk7SNCSAx9QR0UgSiH4DYYJcQsR0JnnECiQDJjK0FFcBWgAARAg
-0RNN0RVdARGACzwLDDdQDa0gBXgg0hfAPD2AxmDAvBu8BeIgDi6tzDHtzAwB
-zRZQ026iAh4AAZiLCm6IADIMGVi1ECjgAjOQDK5Q0AHwAFfQDDG8Nr2AASBE
-CArBB1dwBVAbAGLwDQgwxJ5ciRQQf6ywAnIABgldA1cKt7BbBTSwCvsK1oLb
-D7rcysH7AVYAA2nNIAGgwATgA4/QYhGwBMqrB4m7wSv9Cq+w1zDtfjL91zRt
-LhlA2QFgDyX/YJEyzArrcAuaQNkOQE7NMBkLUQ2lgwEXAAgtIAbN4AF1QzOg
-EA+dkgYKAb4WgNoBkAhCcAXj4IA8MAeAxwFdQFJcncrJHAhogAaXgNsUANZh
-TeFV2ABcEGU+oKExqTYocAaoMNc8ibRrjNeq8Ao88NLRKzfXPcLZ3UWUkAGP
-UdWDwAGZrRA80AnlYAdzHAD1IAZRIAvxl1WgkAU80AJj4A7J4AGeRAynYAdi
-0AFXgH+DgAH9zRDtmwKrtxAF/odO4Lo5qr8PXQVxoERBBeGrIOH7uuar0A+r
-MApPcAwM8QgFEAiaoA/MPcxprLiVEN0joArUveI6wcx+7eKBvVlv/7C+/w3K
-N95PcyAE+E3ZaTAIjVdtyBUJKAABLfB/JjAEDLHKs9ABHSAGLVACpu3fojBx
-zcC5CVAPE2BuzPq2O6GqF8AGgXDrs/Xgug6iuh5UENAPcbAFXtIIDeAMkpHn
-epDGigDdW/AKI/Dsgf7Gg97iBPbisLMA6ovlAt3oCQDNzBbUQDBx39AMTrYQ
-qcACYdALTQyMDvEEhNAEHeAOeGgCqA7I3L4GvOAEtnCuYd7Q+3sBfXAGZ8AF
-XPBDQJVECH9MULoH+3oJEEADMna4zl3XfB7dqjACwjAC0qDi0g4AhD7Thy6a
-KiDE2r61hLwGpu4EPTK+bpACEDoBDdG+cf9WAxrQBd+F1SBABjPgASZA1ey7
-7SdvvmOLyg6dUl7cA2yQ9M5D8AX/Q0p061B6vC+WB6Q214cLCBlc8SaO8cIg
-DBvP19Zd6NUe2PSRG5xc8vdeAk4wBXOcAEQgBgOZDHq1ECtQDr3gAat5B64Q
-EQVABhYwBfVu8uNbvudL9P++BDEQA8yS9IQg8NCnB1lwBn3Q+KVGCI6gCIDQ
-BxEACFlAYya6BaMwCpLQ5yuwBRff9V3/9dXN4mJPVtSASkKZAex4Bz6fVUA/
-+LI3BGJPvmLgAXdQ2AzBCnMge6OKaYIEEXrQASKg6OAm+ApBvkL/un75YEZ/
-AVQQAT3gCIm/+IT/AAgJgAhF0AdUcgm/kAl5UABFgAyjEAMFoAhL8As9YAoX
-gAghoAgr3ezP3vVGYASqDxDpSGgwAMDgQSh/+gRgyHAOtWQ1VGiocujOkCMN
-A4iyIUtEkYYJ1pRAMGRhwxWHepnIQWKTxgAKXGRIsoDSmxk2FKSCGSBVE1kf
-NHL0CJKhyDFTFhxk2pSpxoMDNJBoc+MCICpLlkSI0MNRDDZt5CCBACFTAEC/
-pEjZUkwRjzN4Mll5xCVTiDP6wGwSp2rECGHCjNQyIu1GlQMCCTpNeLLhw2S2
-JAg9gsBJoaEdP4ZcI8bJkJcNQRBxRyJHLxREiGksxMSErRq0knWIZ0NU/zWY
-P65UyFw0JJESU3Q5JX4QqsEBEqjeSGUlSxYqWbVGoIIDVR5TjGTwCIHIVBEq
-caxUY5OqSiZyVFpdQLSlUl+/gQfXqmUYseKCTRvDnOMiWQ41HAhAk2ZEEKoh
-ojY76hDP8DEqAFYiuSedLpL4JYIrwNBIiia+qTAAPZpxp4QW7KCioVSCMIM3
-BG3AQMEAEgiiBCdeMGAAAYpr6jgAkusCEWAeUQQQPQAxErrocPjql1ZMiUGR
-AFoJQZI4JOEhC1NkwCWTUUYpgpAltvALMMHoU0IJPLCQ5oAMBsqPqf00OqWF
-ZO7ohaF+yGjmQIasCePFBxM4JQUnptAoFD5acP+iiwpQiOcKG1ZryB4ynGCG
-oXtkiWIGDK5hgaFMZmSxzz9FMKUhTm5p4gMTKFFhAB2faigqXbSg4gZgHNAD
-DCv08NVIKhyo4hdORjEFBDQ4MQWOJ0KAoZVG5ACjCEc22AIPHJAZJb4yazlz
-mGNukGKMb0iQAFamBFhAixhg6mSQGRCQgiEK4hln1AASscGdGR7kJAgxZtgD
-1UjccAeBZlCAg4wrrgBBo2qAEoGhAq7oQAQRMHgiAGLWEWI3jRIRwh0RItAo
-jWdQYOIOCd6MlccTFkjikABuSAAMMBhhBGcregYkFCYh2CKOOOQApI9QQpCj
-n1ZiYISQCEzR45cQMtn/JbBuz1QCGSwCyIIeC7TQBd2oNMjgApjSGKSF0AJ4
-oAkyltColQlSwAAFFHhy24wW0A6AE03WaCGDMRIIQI4SyOjAHpioEGOchlqx
-YQYRAuGYAjdc6EDuyMtJYQaaYdrEHQ9egCJW42Y1SAAVXpgCjgCA4UFanXG2
-XZs8uIjACip4jQAMQMCyYhd5KtFDkl2Q36WSV+Qz88wNtrkBDy+YQKCmE9KF
-ohgUevL+bb9hKiSKABy5JY3VCuj+AhDWIIKaCULQSA934ugeJgeuAKIhFBDh
-AQVJ5GMCvEDC/WByhAxkYH+Rq1vpXKYjHgkAClOhBy5u4IMNSGEFjZBEB+Xw
-/0FJcFAOHAxhIxrxiS2Ioy+h6BKZjDCf5ylhGFUARtcawAsOmOAFKsjRQVgX
-BSTcwwVu6MQc+JCPMLTgAxRAwwOEMAYvNKAFQjhFJOLQgBJEYRTxGIQN1rAE
-K8SgAja4xwTGwIEp1IEJHRiDJj7gDnBoIh4TIEIn7PEATYghBfd4hgIYoQcG
-9KIEY0gBByzgCk1MsYpxCOQ3koGBCiggDQwgAi3MYS6yvawhtojKAnIwBR2E
-C1ePwEMpTXlKVKISBqtkJSu/8AhYxhIXBMDCDQKgDVowwQlaaFkPV6cCW5jg
-G0yIhwtcwIsSuCMKHejFGMbQC0NmIAokcsEYmGDIZP+kwxwdYAITUtCLXujR
-HE4gQRLu4IFvRMEdhkTAI3vRAmOWgAnpSEcUehGPMYjBHeZIxzemQAItmCAZ
-04SnNb/hARIgwBzxCAM4eBGFKeRABdlDnS0Y0j0L+BAKEtCCE5wRAgLgCgsj
-JWlJTXpSlI4UGCtlKTDIgYUNxIEWvSjXDinqwwF4MqHJsIAFnOAEBEwBARb4
-hgUQYAISkMADTuhpMqaA0C4k1QQemAJTfeqBLthiAQuoQRJMMIWnkuAOXTBB
-O3taKKR6YKgZsIBTTaCFF0hAAy8gQVWb+k81vEANAs1AOpKhwwVkUkcWCAAK
-NhCAOjDlBMDsghOi8AE5tAH/B5OlbGUte1nMZhYHDrjEPcbgDguwZAEG8OVB
-TmCABWjAFquFTQ1W+wIAvcAWGtCFBlxrixfIVjK60MVWJWALNSQhCXF91QAG
-oILUrlYDEtCFXG+b29nK1Rbm1MJwNTDaARhABb/FLXSvqwIV6EKvatAqFG6K
-ujoEYAMCakS6jmsLLUzhG+boBT3GwAv8HkC/++Vvf/373wPg15m9cEcGEGCa
-BZi3OAJgMIOdIoATnGAAEW5whSEc4RMwOMLGNW5pAWBhC6/uwhrOrgFudF4Q
-V/jDAuAwjlDXlEYEwAFymwYJ3DsRNSh1qN/4RgJ9/GMgB1nIQS5qocpZ3vO+
-WMlL3mZyk5385KaQYBoBWEIgeLKJprAYCql9QRK0ENWkhlnMYyZzmcncherm
-oAa6eJWHofxmOMdZzk15SSoC8Y8eMKQHS3EvFJDbXAkEWtCDJnShDW3o3qoA
-ChN285wd/WhIO2UBeQ5AD/5x6RgH4AlMePCFW/xpUIda1KHOcKMjfWpUx5kJ
-GwtAIy79aiuwIgDBGEUdopDkVOda17uW8wmiUIdRBANCVnh1sbnwKe8lW9nL
-Znaznf1saEdb2tOWNgu4UGxsB8IRDqiGsKn9bXCHW9zjJjdMglENBzjizsUO
-CAA7
-}
-image create photo tclLogo -data {
-R0lGODlhYQCWAPUAAP//////zP//mf//AP/MzP/Mmf/MAP+Zmf+ZZv+ZAMz/
-/8zM/8zMzMyZzMyZmcyZZsyZAMxmZsxmM8xmAMwzM8wzAJnM/5nMzJmZzJmZ
-mZlmmZlmZplmM5kzM5kzAGaZzGZmzGZmmWZmZmYzZmYzMzNmzDNmmTMzmTMz
-ZgAzmQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
-AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH+BSAtZGwtACH5BAEKAAIALAAA
-AABhAJYAAAb+QIFwSCwaj8ikcslsOp/Oh1RClVSu2KxWAu16jY9IpGrVms9o
-9OPLJqbf8Lic2/7K0ZN0IpG/p9dGCAgPZBSGZ05+WRADBmcTA5EDfYqVcomV
-jJNnkpGOlqBvmIqeZwaSBhOUoaxZo3eaq1eQkbKttxVOFIqnn1qnm7jCV7q8
-AxBmscPDdEy7frVmkQnLzE5ld43JkdXDEdek1L/BlhKE3VffTdhy5LPalRIF
-APQABOhP7HHuFQnHlRHqCbxXLR8vaQMqHRAIYMECeg8KRjmYBZIvOfPoLfiQ
-ouMJBwEkNonoRxyWU7bSEKjHsaPLFBn0tXpC8o4sbncWNjTxsqf+hmU0Fa2y
-mJPehZ5IT3QYBoWVv5RmAgLAgBQpCaBPWJ2aQ69lVZcollFoGgoenJVUv7o8
-Ua1Zk1CQTKZZeFSty6XL3DIJxQjZGwkN7bq8amkCnzOAXil6ehYAT8Fh3xg2
-IPeKv1RaEr8FtfXNAwBe7cbxNw3hxQobPnxQDO20mQAMBHckDAeYa9JaRvRc
-UtZ1loWP7UYeXVoLLS0odispW1kLgLqCPdwh7VeL2SvJXZrgXZhfls/B1dIm
-7r0CvxMvQXCvBAlqBQKxIZ+hYuo6lgmue65e3j0NYBCy4VUBBQ+sBEBIZpzS
-XD+2KKeETHFAkgYCAMgWGQUMMASATNH+mGGLBw4mASEc+KmUll0joJBdRyBc
-AJFx9r3RQYhIjFhbGgAAKNtXAQCAgBaMLIjGjNoxYeMbQgK241corHTAOO6Z
-QWRH+ykRAShQPbDAklV14KR1vqVBwktNXLnMASdy6VIFL95XnphkMmHmMATo
-qKZHFNDDjj+VrJhCmdUQEJ6aI0j1zBUDCJnGitsxUZMwAdz5UgcLEfSOJSuq
-t9kw8UmawnsAPInFHpag11FWy3R6Jwp5bphFmHDEuakwaapJwmcIzqLoG7Lu
-tUwGnqbgJQCP7sqrS6gOo0GwbAJwaAVRpjFlo7PisoFag76Ewmei3jJllb4O
-c21VJmQ72Er+w4x5arLCTPnSCaEhxQGx6SLLLi7udoQCCbX25ICluOi2Lmu3
-WMWvWk0eWYnAJ5C1DFIdbNCvSxr8uEx2JTjMyqN+fppBvC850E124IbLygHd
-+hkWAyV8Nd4w9t4LykoWCzybB45VNVw1MRNciYEMpDhpBxVWhc4VPVc7cz0b
-veRBBAp0eXQFHVHrhIChrATdSxU4sGVPI2ShsCJEavoE1kuDHFYDW3e01AEE
-xL0MkV6gbclKdoJVAQNtr5Vht/gOLPPdOfd01VRqbQDAnLio6wUuwEHM5sQd
-OeDqMDM23AXkRffUwX9qoTt3ChlvfstCVXkAelUn2FPNjCUrbcn+Z6ZyHVDe
-L4UQ6ut/Pn7LZx1/Ct5XGtDLsx23AGazvl0XjlQGi3fTOxQY4KJ8T2FFXpXl
-Y1ditRMhCAPAuHpnaG4K3Hdj9hPh47Ih2Ht3jtRC+HjxEy4ERAD/SkzS380X
-7btF/vYnv5eM4DP160IAW4EyP13lIS4DTAKhsEBWROAAy3tgAe/Cpu4p4gs7
-Y4UECKCu2VQAgqnr4P+8EDZhkPAlGvxKBSS4wi60EH/uimFSKlCgCT7hhqeT
-AAxPuMEUhCV/PnQCEFsRgQcMEYVgG+HRvPCBlzGwdmGD4qQK4MFKaKYJJbDb
-yVaUxSLS52hfZIIJxBgKBNisjEgZATb+uniHNC5BWHkRgd4sAIDadUQ6MyQA
-HefQBTwuY1nM42N4UCABuOmpG3phgiG9UT7n4bGRj2xLIdkYCiF6pAIYsGQF
-OkACFIDgcnmBAkc4GQquhbJlVTnlFJ+wSuthY0XNw51LQJArkTSBJ6y8A2BI
-siIPFE+XHcEAwLDihI7Q6UAO8ErEQPOVBgCOmU1wpjB0kqZpUo4Aj8KmJD81
-DADAcjBEmxgKnDXLZpJzm20bQZ76loIN9NKX4xSLJcPikO1dU5xKaEk1tPSu
-vUUNewEYpB+eAKAQ4qIAaWoeUjawTHwqgScOxZ80aactQU4tF+7MKP50RALA
-nDMFIvinRZP+wLyjRTMFcqSmS0T2UZBm04gfDQEIwiJTmNb0CggIaU1RwBYC
-QOen6WhCS0S6jLAV4GtLnJo6lqAjplZjIR0I5jKmqgRYWhUUEArIs34aySMM
-hhmfKcB8UInUshrhrMsAgFrPED2kXsGtRYBrOedqBgJYzK54JYJexebRSsgV
-DQfgq11vmgIrViAgCj3sGSJQ0ZoyQZpmkIdc/4qFCx4gnFeQbGYBYFcsMMFO
-YoSsGeCWjoqK1gxs/akaORiV2AKmDP7Lwmu1AM7S2pSltNWCan9zOQrIZLe/
-Uaxs7xjcLAwXC/M4EnKxQMPFMvePk43tQrAxVjYp1zkKDcU4tVn+W30MEwv/
-nC4W/FraJYQGDYAhwDVHSIgDsAOT8p1LZduJhLz5Z0RnLMd+k1iEk/p2vaW1
-4xD8eOArqBSNSuhJg2eY4AhzbcKlDayEMZdVEpAgqyDW6tE0fGE5gNjDKSJq
-sLCnohaP4MUv9rCMPxxiTuI1NMPxwIlLqSI/rvjHXILCSY0I5CIbWXCzPbKS
-jwyFJTu5yE1+spQ9FeUpW3lH37vulbf8lSxbGCkluMAFdFkCBjStJxhoGQZ4
-kuaeiLlWLbrAkE3w5p6E+QIgK5ITkJmCDyjgAwU0wVROWSsMUGUqrfOxOQf1
-gQWEsieCLgGjN9JTOz9hyC7x8yn1E5/VRtvZnA0BwddeMpV4NdrTLxE0BnDn
-aVQjJXZJOB+gGRAvDHT6oKSmNQBojRTQsJoegxL0B4bc6lHr5wlqcfVLSgCa
-EiigXy4yQYZ8nALHTNrRkF60fhbgbMrBGglqAYGqXgLo58RyS6KuigIUMO4P
-XMAECggPvNmtn3VTrs/I5rK+q1Llfft7epf9t8ChAIKCG/zgBi+XwhfOcIUL
-3C51iHgRPgACTO9b4hhPAsXPt+SMe1ypIOA4lT9OclVKOlglT3kbKi5yJKv8
-5V+g+JBhTvOaGyEIADs=
-}
-image create photo tkxsltprocLogo -data {
-R0lGODlh8AAPAfcAMf///84SB0kMDM6JGS4JCVZWVs3NzczMzNacJdOJitGR
-HsrKytujpNOVIJKSkpCQkJSUlBAODpiYmIyMjJaWloCAgI6Ojvfr0JycnJ6e
-noqKiqurq5qamqCgoMDAwIWFhaOjozMzM4iIiIKCgrCwsKWlpISEhKenp6mp
-qa2trcdqa7a2tq6urrOysrS0tOSiI7m4uH5+frEwMbq6usPDw25ubry8vHx7
-e76+vnp6esjIyNypLcXFxcTExHh4eHBwcOKYHHRzc8h8EiIiInV1deeqKnJy
-ctCPHO3Trevr67hHR+G1Ne3NlfTh4UFBQd+xMpxiDtWYIuXBPevCO92tMGBg
-YMqBFPHhVasSCerNRocRC/rx8dmjKffuXu/bUcuCFfbpq5URC3gRDLkSCNmt
-atakUsd6EfDw8OG2d8yGIem5NO7S0ubEQOm1MtqlKvHUSrJxce3VTOS1WuK5
-OE1NTbWKi5lpaqoYGeOdIGsQDPr04ezRSvTncsyGGO3TeOiyL/PlWFwODNWd
-SujKRJowMdOWPtHMxWhoaMh8EdfFqfDeUsqCFvTpXJJPTe/YTuO8OoBQC/Xn
-j9O5kMyFF/z48e3JQefGQeq+OOO9PMl+E+vQSM+MG9qmK9abI+jIQ+/NRMuD
-FU8wBnIIBe3US+WmPfTnWsl9Er6mheG3NqOBgYsHCMh7EdGTNOanJ76goO7L
-QnlmZtzT09igJzMgBeLXyJh2SObBYOO+PNGUKdCNHPPgwebBiKMNBMmAFKGR
-kerOR8ewsc6LL9zAl+S9OtObMuGzQ6EZGmRAC+fHQvDSSMqAE+bm5s+OMOXl
-5ePj4+Tk5OLi4uDg4OHh4d7e3t/f39vb293d3dzc3NefJ9ra2tnZ2djY2NfX
-19XV1dbW1tTU1NPT09LS0tHR0dDQ0HYVFaASC8p/E+fn59igKOnCwr5XV+Kz
-s+evLZkICezGPvDQRqQhIsqCILCgoMB+G3wlJciaXNXDwK19Iqh9QejIUJJ9
-emcaGsuZJ8+OJqQJCgAAACH5BAEAAAAALAAAAADwAA8BAAj/AAEIHEiwoMGD
-CBMqXMiwocOHECNKnEixosWLGDNq3Mixo8ePIEOKHEmypMmTKFOqXMmypcuX
-MGPKnEmzps2bOHPq3Mmzp8+fQIMKHaqwCdGjSEGmu2M0qdOnFIFhkQG1qlWG
-CeDducq168AEd6gCAOa17FMVvJSADZDArFug6xKog4elLpZ2d7AweMtXp9a6
-vO5i4SVjb8IEcFQkaNq3MUoVUxMowQKPscAEFwrKGMPrTmd1mB2LNqkOi7qC
-SsIWHBOmM692vDqr0DO6NkgZWFQMTIcbr26BTTwP9uya8GLbyDVqbQtgXd47
-eccMZICF+ODOsDsrSc49oWGFF+C1/4XTGZ66sIwvAEuQQAW84nk7y0jXvf7A
-tA0v3BmDZXtesgDYYZlAS2FXnFj2cRccZcwpdB5muCWwjgr7/WYQWHW1M9x2
-DDFgYYJXNaEhbGPQp9AaAEAGnXCeNVjQOq4JhgWA3lUHYlfpDDcYPHBkdtgd
-Gt6hhHuDuViQVDLmphADrGGxzo1XpYNXcZ09idAFeCmhCwPPGWlQaUC2thVC
-YIUxBjw+QgmVVK/F5pln6pho0DrpNAFWWFYCMOBXYQCW154AgFWenGo+xeWb
-bsbWGRwJKREYPASdR+Z7gXVG6GVYhHEHpIVaJeh1ir45hhLfESQDL8ylQ2Fn
-pU6XV5+xXf8Kx2BTpdmpodl1hiiQbsJDG2PpmJhaca0KhFaiWFimAmtC3srV
-BaveRVxs0p6p1aZGNTHrm3ckQJtBelAKJGUDNaHiHeoA6qxTa7w33GuIVucm
-h03whxejCeFmHS+nGRtYO/2u61VW1mkIL7X8NkUhmgpt6+Zge5kr2IcCeyUD
-cUDmNaJwMzbXma2aueYZbGOmhpe3Fb+1zrB19ZlhXfvFORmCBCVwsWBTwrPG
-BaV1hnLKfIGlYXV43dXOlHdQ2E6eAHBJF5VFAnBqi0A7RsuyLg+dIXFmPrkO
-HHTJK62umKVWnZdVv7UGkBqG0bbI8kFn73XW3UHfe3gVm/Zb6mj/LS1gbhYd
-WNbVMtrufvAwvTdf6fwrJNFUwo3dy/gCAA+lly7+FhxDt8Ubra+9PGVgSTPw
-rUBKcLapDIoxUKfmZvHXJ2NZkfwv5BlnnoDB8rIoZGiwV6WCpmNUTqBwQ7uc
-ZJwE2dmeDMqP2LsMoEkIcvA+6eemQfriNbTW7Wh6dkJrSJaxm+cjKgPa2OOU
-gGtGcpkk3bwQLp/ezccFhxJ/uYYXkChqH0+gg5dLKaFoU1JCa2Q0Opgp4XQM
-0UM64HAqRSlJgDp5n2coRov4uKwt6+jby3TksvWpSyHpYEB7OITBm+iBV2NC
-jcHCQLMyCac17WBWXmRwwhYe5X11odh0//QVwHJBBjAwEwzx4ABBHybFUbDJ
-XM0CVpAmyMB70oJNEu+gOCcKZQONeJMoQhACJzihAAWoQQ1iEIMJOMAXDiCB
-HA0QizoCYA0MoIv07qKpzuRGil7cCQn+8Q9VYIeQiEykIhe5SHJURzCOO9r4
-AtmTDTiBkAK4jigSGQEBCCACjAxlIgUghqEVZ4Z30AI9hkBGM6JRjWx0owM2
-IEcS0LGOSaCkSAygSFF4TwCIzEObeBEIURrzHwJozb+KM5gwhGGTx4zmP4Yw
-hA3oMiMkuGQiCVA0VSByHwjrzD4KcEYzltEJ1KQmKBdJgEDUD3S7yhQwpXnM
-WFzTIkkIASNVIf+YeXITPhragEBpWctYGOCgsTCEQg+6AQdMgI10GZfBxhWb
-dqyTnosswD0pEosYEGCRQ2hEpigTA0zaBT4xaChB52jLWxoiCbFIgkLXkIQk
-XABs77xLYMaWCoc+FBZqRCM5naDPUNpzoxEZJCNT2ojB2WEChNzHxnjFC33E
-UaC13MBBSVDHhMYUpoaIaULbNbaxwcYAhlgDWg16UITGwgGhrAFSIWIAbSqy
-Bg4wgC9ENYEJDAGZgNEiL+DhgFmqlARaneNBX4rLmsL0sWs4z8G+Z4A1eJWt
-bTUAVDmJSGvOtSE1YGQIEOqKix3NDg69JDeVSRwlFNaNcqRlYrm62Jj/hrWm
-YgWbvG4XpK7WMbMMveg/IqDNCHyWIRsoaiKHMIE62tIXLiNsXwuAyQV2hhCy
-nMBAV2rLWHQ3oY41BAPUIabQJUlTvq1jWLf6V0RGYALrNMBxFULdRcYgpgg1
-wHnwgtq+lhSR0AtDAR6a3Yb6gruZTahCU3EHVeTQbSMjGswIkdBb/vagyiXk
-BLTphPkihAQZJmQ1xcpWEowLC270byILwEZ9tFGWhd3uHBN70FTAQVPcitFI
-x9bcsHZ1vXYlJF4ROQEPG+S/iuwwbn9LAgXWxQ5wdGgMlBuCNbLxxYWN8UAR
-awA56sN70wocJAWTOJq+1Md1DO2KLYnIXBpZ/yCxqK8iJ0DTx8LUAMB4kwyi
-TGA5/wOWV+5rllU6UDjYIcyj29cd+sS6W8r00V3dLCKdMMv2xuDNAkmCcBFJ
-Asde1qB2IJprG/pQNq5YjVbuK4w3oF07tCnR6LPdYGRAR5mG9cy2TsIGFBmC
-wv7XuJh2xab/EQIS0PSrjDUopVBMav/GoL3/cAKgYwljOyiwohhLVOg6EwYV
-MACyj370S5NAAmgP1427JuSl35zuRRqgpu/+Kn5DnSVXzNK/a6RyDFAd6AmE
-sWjQCZyBeFUdhSYbpsiu6RoMwUtOstoBav6HfI0MV5DWurGPZTg8xDdQVbOx
-BnaNwL5hqY8CEEKLmf9SlMoRlkMV+MIQTTC4p2s67jP7+R9trDQhQ4DpUMZb
-3mC9cCwGOkuffjziEVjjGuGRw+pkG2nTgg4c6ngBgysUt1eX6cKTcPMaoFvS
-RzVyxCcNiwl8l+Zd3WqXBfraUqtxxY2gx9E0Nra8jI3bQ2rp1cdt56/SPAlI
-JiSls9zeDmNaqcZ0Qht9awCtEp0ERt/3s6MqyZTzNnS5CkstG39QcUPazuNu
-t4iz7NDOYlogIT7mOdUoS7a7XY2EyEP4gvS9EQ5tU0/dvGL3XmfH2toQrlDk
-EEjvALu6GdOxwKgxhyBtNsKiEeGT0QJvmMT6EUIfkHdFVrvM+b3PPNzm/of/
-oLO8TgfoRLPOZ30sc076wyKWxi1FKMJ9r6eW2DUEQCXjsOkZgU56Mg+iQA6q
-AGGEs2iNoA/oZlgIZksyF1O9lwQGEGLsV1j1NQQ5EQvhp3waKEoRkE5lVACe
-9RGiZ1AkqFk1kHobqEgRQAACQAAEQFRnhEaSl3Nsp3feF25B9meqlmKItG42
-EXgpGIT854MdcVFO0FYMR4IG1VD7VgAhkIFCGIXulWQ76EZyNnE14WcREAha
-kAde6IUCEAhh6Elk2EnDJYXSFHYbgXj/EH9oNla/1VUQOAEniIZ26F4+NX7r
-ZHg1UXHIpApjEACCOIiEGACBaIiFmIiHOAaMyIiC/8EafeJMqvBRIrZGBQBt
-Q6CGGqFcNeBW6uVbuJZeSWBZiNVXsDBUQ9B/dyhNIVCFD4VImhgTyWdSjViL
-g1GLuJiLhsiIAYAFgfiLg8iLiNiLk6ZwABBniXR8GuGHEZB2onhrEJhxdhZu
-saAHvodbpbhvRPWE+xeEA1aFiCRXNiFpWqA8fWIwnOFH1GIXdjEG0dGOdcEf
-7OiIvhgYlBgCo0hiSSBpPMcRSZBI92VhoLhkoihWx+ZYD/hpvtVd7/daV9aE
-5DRU2xh+LyZochaCNFFU++BMHMmR4VOObtORzhQ+iyaSJhmJKFkdZqIFRIZw
-uBRW/NgRftiGlpVetjVuuP8kb35nW141ii/laELHVUKZVWx3VVm2g0HWim30
-YsqFE+ukClogBlowlVQ5lWFQleVolVR5lVl5lV4Jklb5lR8pBogEDDnpkmsg
-Z0SYEdB2XwMZirhUkzo5jT35WLGwcMCldkSpUkV3lKpmbktJYJKGkTRBSBEg
-BoiZmOQgBou5mIrJmJCpmFFJDlPJmFRJmVQplVg5T/9gky6Jgaa3EUgWAs9I
-c5Y1jTLFk7h1jY2Vdo0nlI5HlEX3cH75iojEXBUJXzuXE4b5hb75m3kgBsEp
-nME5nMJ5nIhpnMNZnMmJnJxJYp/oW8pFAhthCInkAOC1d/Fml3K4mn5nlwjn
-Y3n/aUuIFVtE11C12UZBpnilRodExpvDFYaBkAdh6JsCQJ/4eZ9gOJ9fyJ95
-EAj86Z/A+YXPaZPpxYYcMXbq9Xe4hmt/R5dox3AK9VuGEJvct5eGBWN5aGoA
-KZgToFyxOBPtJYYkSob/N4aeJIZkSJ8oep8nCqAkGqMAmp+cZqDOuAHrlIka
-oWmI5AANamae13diNXNiNaGYpZfl+X5sh55t518T4GdDsH5ttE4alRNyZqJY
-KgCzkKVc2qVYqqJc2ll5mV9tJWl8iBFy5gS2xgBWJ3O39Z3h9YaMx1BbZUsE
-taSsRpsbOmWJZGVMiUg70W6dxIKE2oIsaKKHuqWedKiL/+qlXcqCiFQAYzqm
-EXemFsGGG5CaDPqg3+edOOma3uVdM/Z+kFeU2eVsbARt7xVoSCaOFeFpW8V2
-G2Fus+CCtmqrK+iChvpRBLCluXqruWqGteqCgzqoLihikzqmarmJiBQCbmpb
-4cZ34eZpSeiabaVVa6ek6MmkeVhqHCp4DxkDdkWdCSFTiOUAI0dGUKhIG5EE
-qvoPBNB/8QpMLbiCwfpJn4Sr+cqCnfSrt/qvlIhzyZqXymV+GDGLhLQBWfd7
-vrewGQetc9pl5FlL5TmbxOdxV2ZuLBZo0CaRT5iKdghsGtFwUghKJrtO/Zey
-hsmr8AqvAfsP2DqwCAVt5HoRdv9VAA8qXo/GAHA6pOLmmrTEVtz1eHqKqh83
-Zw85dqu4SJZ6sDe3tBs4BPE3sEOXoyGaVImEVps6rbj1gMl2YdyXrVkFeRnq
-l0t5ZX6meA/Zje6VitTUSq7EYjVQdrKUg3/2EcgItUGYiSVIR/nFVt6VjBhx
-UTjLppzaoL6HbOpFpxcqqg1ZlOl5ZWqUYd4aA3I2BDLIRu23XVsWW0MZC3b7
-Dwb7ERDYVknKlxcbmLBwdKeYRmhUTmZkTq2UTpMWh6CohHVkphjBhiQgc1x7
-jdEKVm0lqhJLsYbVl00art9KbOGqXLnZejEWR4ZFsRKLYZxFSDXLFXY1AQJp
-o7k7aRj/0ZYOynDhVb65ZnB1WrwYyq3JK7k1kLbhOmlVSHysVp5YxVUCJap3
-BW1F1BXb673pZQDLShEOIFwRsLBpBbzme2Z01FJctpdFiZ47mLRqBJhKFwMX
-Nb/Ri6f3+8CNZ25OIHpu0QSJxFUA7FvQRpgN4a5LxalJ8G2H+8IMl75dNnTm
-ibq0ibEfx0Z+VmUZ26w7OGja1VBKunlBO5PEBnnu9RYsPFyZKofQ6ZIRGJoO
-4QCYGGTvlnXS6n23hlYOHJvauq0ppsOSp0ZBdsEZ9o0a2pcyxlK2pJu3aVjN
-yheIl4mfOaSVhUuIJ7IMYW4RQEdt+cLXKK3fdmYzHKqNt1IR/3xvTeqtVlbB
-t/lxIaZqpBfGHUyeHaWCsoVkTesV7eYEwMCd+miQJICyVzsQSHxfChVxQwBW
-0sqghuzFdbqXpXpvY1y5SgdLiRQCTchJWPZai3y/8Ke04jdQSFalfCFpOJua
-cgqeuosQCCtiE2qu13m+5WvIC6W+xVuDerqhlTtydRiO73tX48fGnbt5rtB4
-T6uAGxBxa+kWarlWQzrP+fjMBAF4qtqJ4sZwl+u7XBvLNUyeskVLx8ukHofL
-qFYD+VwDwvWNR8mX5xxbXWa3KbVdA9wYduWjWVdh84db7nzP4de7W2d1JCu6
-wMumV7dVhuDGFItVRQdjTiq54DzOkf+qtAXgUO0XY5CXpOTZeKkHW8eb0aIB
-mk48yn33WHXVowIBhDVwl7+XzYZwfzRXczTHAGi10tXb0rXMrRO8wwnNp4Y5
-efIL04SGVXfKfVacUQS91nalwnxxUe8Gnn63nbGgXJJmmJ0Gjba2WIiVtWt6
-k6WrsHb6mjecpzD9zQkNaND2hMuF00Jc1itF2BkYA1dVgw4wnbVRxxgHdAdJ
-bsMWAZLqeTOcWbaEiQYHraON1RQbxsjbrTINziO3XHO2xhzMXXJUwIuEV+cK
-0dB2ym5Rx6tJjbf2VUgMs/v8e6Stv53lptnMeRd6wzGmoTHtvl+9rsy1avc2
-0PdrAFYtepH/yrnbBcf/oIyioczBTaQQaNN3Ob5W17sOnNSEVABXV8imq77Q
-DbltF66JXcai5HX0O5tbNltAGN843H4XxR12FQPB/Z3eHQF5/WhqRdJoRcNj
-h3amq7COl8iPp12k19Vl/NXiGkoDRr9D3MaJPOA4d1VDbHbbepvd8b+jaJcC
-rEih3aDYrNpdttLvB21O0Nx8zXnavaQd7mwPlcu5zEYoSGkpBtHsvNpP+2cF
-PWgvDb4Kkki+BVPebdLZKW5WjYQ0/Jp33Wl6udKypaRFV8uu7dUgvkbDdt3R
-zbmzRLHeBYWtN8Rlq10f3R1E3YbOlYNHGHN/V8jrhYTxN7FyBG2d/0jozw3n
-Erynas5vsETMzEV8Uh7RybVUUf7SEixnRVYfml3c5oe40Gi6o01LYitHSKdl
-YAzdFuvNFBzpMzjZ0EvEZi3nWT5cOc2teqpcWNgdOCpiNE6dfEfVo13fM2bf
-t85I7fVX6dTsrOTsrPSEZAS3qYdXOd3kD5zWKpiAqHuUpAdt5M0dKD4BDDrS
-L8WmKt14FUqngp1VKK63x+R1q3aenbsBviBaO/3fZEt8Bw4idx1tnVZnjJVW
-Z2ZQK+1dYWvoLS1Q6wrvolXOEB3gXSbWieQEHL6tlE7pSwwiQNhK+4ZucvST
-mXXwQwnkqy1QdDjt1DRNDr9IvSZLW93GiP+F4jdNm+yb8X1F5Qny7/Tktsx3
-TjEoVH6KZRze6rXpdjPtukIVkbHb9DAIg5Sd6wqYVcScdMB89TjvcTpvH+/e
-8sIXAXArbe/bb8rr1SOnvK64wYVFy40XukX/cKRG6a4oZ8hsH5KmTl4vhcze
-7NIe9kKfag7FpODNZcUHUtKd8UePbz14I4OJrZBX5Ga08nk/+dMU7WfEekOc
-gYOH8VnvitO1+CDih9xLY2W+8BuKakIVux+78g1P+ULodXHf+Z5PYEId+kQm
-toRNyyiPp0WP8/n9vuSk8qro+sc0fEsu+64opcrl1snhh3H0wKtNqnFusQZ9
-843spBiL0EoPu6r/r/LNPvxBaPGBL/fdWoVnu5S8fiPOb98Lb9bS23Gzucbl
-763fTMFnf8FlTGDPK934BvyRDxBDIvwjSLCAgwkOECpkOMHhQ4cxJsSgWHHi
-hCEFYwHg2NHjR5AhRY4kWdLkSZIbCk4gYYDES5gkNsyc6aDmBoY4Ge5ECDHi
-xYoUawitMdRoUaRCg06U+DBnQ5w0N8AcWPAgz54+fUqkyLRr1X9JUI4lW9bs
-WY4OVsqM+VKqTRI2N0yYaxNrQ4hdg+4dGqOoX6RG/e5tCnEnXbkO4sqc+TKj
-1cNaH+6NSDgGWLSZNW8mq5Igy7Y049JMrBAnYp5am1pWChhwYMFLCzvk/xnV
-tNSpLwsSrNEwa16gXrnuLTiE83HkydV+Do1b8c6odGlHBj48aF/BsAdvtzh7
-+ty6z3HH3P3voOTJlVnHgDVhaEEnyeXPN0uiYIyYuHGOrnkYq2qg+FIKNgIJ
-u8gw6G7Tzy0DPCuoBvSYEq6AEB4jKIIIKgwhhPvo8/DDkewjCD/GSNvvOYUW
-u+u3n6zjKzvtLEOvthNLbAymmcqDML2uJPSrPCCDnABEIokU8R8S3xrNJsR0
-uksyvSzL7rW/YpPNp9oUXHADlwxY7sGfArSIwyDLLM+BItOUz8EY9HMuRdOe
-3Eq9ivoarMC/DDzQqQRvGi+mBr8ckavghjPz0P/yQlBz0c0MuO+mxHSybUUA
-17uTwKTs7A7LPu1aENCWBP0HQhctAgu+hBCKoYACnKiwzBoYlbW+R6cSD7yn
-5KzORTurpNI17iziNE4VbcwtlgYNcImECcoj1DIgI4jFkCSqNeRabC+IoUwS
-ZvX2JEd5q2nJ06LTlcf1qsSTNcn6jKox0WBaFpiWDGh2N8osspC3avv1N4lY
-tj1UrG8LDulIiabSidklmUwNOB/rbE1dXzUdjlPwpFPs3dzknQpZLjcQ+D7W
-nHA2CWoB/jdcRGMw+GWPWK7h3dIQOo26MC09Ck8r9Ro2Tk//9LhLEmIhwZCR
-RxQOMB1jiWUNlWOpFtn/fc00DmaYZZ4pobjsUihVvFTrjihgMW2tR+9ySog0
-Y+XtkktllUW2ht0iYAoWpU4NYVqpU5ba6TJfLc8ArF9mOWFPgX5416Wxu1Q7
-iwlFEKqo+Os4NGXrrZfugiIItqjdhjAA2b+jTsLk8pwoOuDUCzc4lgdP9A/n
-ypYmDDvILd5zcqDZjndoZUMeXVnOCRqiTqPKm8CQNZx2mlpqi3/QeadRL8j1
-gmHnTTpJ/6vU9sd5NjBtmxO/CUd5W5KJ6LjjLiD0O/2y/p8hDKF+WpSTEPUf
-J4Z3/t6CEA57s9LeqHQCtsXlJUrXkZjZ1qOVhnTtfFIZGtxeMrz2xeJ9BQnB
-/2v8cipkjc55KFuDIebHP6OFcHRHIsgGBkjABykugbVjzc6olKl8QfApNLMR
-qF5itJaoUG7V200IKLabAgjRAIZYoiEcVJCpKGsCtYjB6PY1pBcyKglg6s8M
-J5OuAQUmWJT5WcbGRUGPFa1BRktW3Kg3PydQ6VRwa5+ymAgkurjEAVCAwgDu
-4QoAIimLjCrgeby3FZ25Zl3B2h1tmhQnN62vJVxSXwrreD84wiZ0daxj0v4R
-ArdsABJCGIAQ7lFKSBwjFOYZ5KIKOLND8ihiitxZpvI0Nh3ajC77+dT6orjG
-DQjRfk6bGpl4Exhj/sMBTOSkspKJpNzAopRCoGY1Sf8phHqsoZVqsgoCWbQa
-2zmulmKUEaceyTE0UnJZ7BOi86hFzH0VICkWGsL9nCY3EpxqCDSZABSs+c9q
-DkAQSNgmiLa4PdrRqYZEWeSVMLa2oMmlYw3agCsyV69L2rNa8RQMEu3pPAN4
-kmsbCAVATVpNMhTUQwc1T9iqA75aerBnPjNn9ySKRlB1SadufJ7pknCqisBC
-ehMgpj0NUZ4h2KWfJ2UqGfSg0vlAhkUKFY44zXZLMvIpUhtDpw8v2BL7ZXCE
-KVOZs4oygVORAGDvRJnTnsg/u8DiCExtKlTlI9VKleooNySnQ3nXPd/lRnjq
-bOYQ8UfWvjmrK3XLH8DwBzD/T8bAZqOk60nTwAS7IqebiATjdiAnsaXk0jSp
-Es2NJum2NmbUsdZKQgmrVbc64QtbZIXeCVNVA39WlqkXyCxnNvtF8HEHU77K
-Ie92KZcetuWCLjFE0TAqQuqxlrVHxRdFNtjCa6EMetndVwgSMoFQzFW3J0VD
-bzcDGcY1cK9inKnkEPSuXW4Np0Zj4gWbSzqe/q1v2p2W/Vg4hIvMT7r9gp6O
-IpLb8Z7UvJr5bamkNNwxulerO6ycab9KyeY2U6N9m221nng8h1hvCNodsP6U
-J5ECJJiuguDtgs3SzYsJiL0OzOpfI8rViYYqc8h6rmFLR+Br7TeQAJ6IMZ2A
-MgNY/wt6Sbgu/SpSAPGq2KRpaLGLx/KYAjj4bOvFYeR29zXbnK9EytXcjsU6
-QmKmjK39GvJDLHRk5imZu/CTCGWlzNTyWhklWH4WA2lJzsh5ZzpqOyNOMxe8
-H2LQjmn2V3//9TfpedchFqpBh5PAgH4lqi92vvNJEdAEPZvkMU4I7q8gfCXy
-7fCmpV2W+pbLxvw+lq20VVm1mkzqSVulidqFHssIYsQawALBnT5pIQga6pHw
-WcaeZS9ohYWxoMUXpxf82Arllt/8kVXO2a31rRkClgIEr4nZZSH/hhICYo/3
-2MgGCZmyfLvwNVtPvItoL33Jvh67s7ED5nZjpZZMJzCE0v9frVdz3+qEojhh
-2OmeMmbZ/RHUkbqBf84TVns0rC66ybQNggkQ7xnrbPsLW1D7l7XiKXCrKKzV
-yhKVPGMQgigznKnrfjgAyBTHAcV7r8W1cb1/52qXsFGJ0VUzbbW972uVpwBR
-sdDSFdYWUeF8CHSNuUmnyVQq15wjEb/dVWUk6JyA50QKs3CyOl40OkJ3hLxm
-ALYI3C/XJh2J0nnzThjzkqjjDd0yv/rVrymENGgdAFy/FF/j59cJ46q0Pzd7
-YdVOzGwX/e1ALvBuYLkBY3p3UjdJHUVKmu5phh6gpdyF1jlH6hl3mYxgZ5IZ
-/TTRkGG0x9DNH+SBLHJuz1bu99n/pYgXQlrFBPKTReZ7QP9OzVKmQRCmJwjC
-dZ6U8dX0nF2lJGHVx8l71n7fJXa72/Pna2jOpMkIAps+K7Jwv1ez6sYvZfqv
-OYAqIzvi4ySupsI0uTD3Mjccv68az8zof8m9bfM+JFMemkga+3OKE3IAiqAH
-vxuAq1s/a+o7q6OmPGO30xuu9pKQv5q+n/uqLuk/sZo1OeO1ACxB6FmDcosv
-QfEc+5MI6RmViDiGWqhA9xu945tAISiEmjs998gddsE4YrG3o1kfccMvwwo5
-yqM13KsWTOuXt5KofLK8AqEIPKIIBoyBhUswCsTBmhMYhFM9nks8SHo9Brm+
-6zs00qGe/yW7PSZku+zyPlF5OpEpIlM7N6WbjIwQgGPYQmpavy78p/aruXsB
-NhuatwnTkne5O2qLCSDqkhCKLg4zwe5TsxIqOt1zovK4nA3YF+SpkhPynAlw
-glOJAPSzOggUPR0UAgQgxOaLEd2ZDawArOQ6w51iJsNqQ92bLtwTQF4zhCcM
-pAggOBJoMs95kRiomkOphzT4wxwkpfYzPvYTgpR6ODAEFkTUKh6KpEZ0Ilzc
-gGsBuf3SxV8cQExkAKnJH2HsOJd4KwBjDUSBDwBAgvFqP/drP5oLtUJ0nHyR
-xSx5PQtTJ/VpLlxcop7SRUzcRV4swZBLGlDCN0/6JFZhFeyIx/8IMAQAuAC6
-SsX3E0Ro1DrP6CDiAid6Wxi4SCf+Sy1wxEXomcTtcsJMRMFrabs4nK6k6R/h
-cZ94/LVDiQBtAgBaULFolMZqfLjlwLnoI78wWzVWu7c0ZKaaVMKa3MXc6zAC
-VLMkkJ4aALrra7KdjJZu4QgmmEAKTMWhJMt8DLWjHMNBC7u3MLSpaC6MKsiX
-JLG6LLnGskpLa7vGYoAmCzd8Ip2iicivpB+C4QhBiDkIRL6/W0yPbEWQbD7Z
-cK9Oyb8boSQQzLCMekKs3L4mfMmElC410yB82Sk3WqGXU8ZDqYGN4Ag9KANA
-fD97dEzkg0BdEDwRQcqL08bbYEpOREP/56JLfbs0ytu+SuwXTCs6zpzJlJmf
-CTCzM1syt3KPEDiVAPoIKtjIaDzLgCrKmgsXnGuku5CUT8FM5gKr9sGWnjLO
-qszEfrPK20uCJKut3YCboZM1v1EZkpOJ64qFJkCCXSADZtBOs6TN2oQ/wQMA
-8GykQRs7jcsPzeQSqHSjvJRKfgPGcow8DXVCtouFZMI+Nlwyv0lHf3mfCDiG
-QrjB0Ws/BTBLQRyAtGS33GQ9SIqU8RBI9jHN+RTRkju6vHxPAXzCkGvJJPjQ
-aztIkSuxqUkHSbgHf1LRFy3QAp3AC8TN5msXh/EaW6EglRM3OmLJIW3CChXS
-7ns7HuVLdBRR/0NIpo+qUM90LDIwUC6czY78J8hMUADQHlzjE8Q4rgeVJLbQ
-UTuyUIbEy1+UPA4d0nRMTpShJzZcKzdtLfkEBgGFUqaSUkz9J2bA0444qIDT
-Rq5JkV4KHmYCq7SrSSGNz39BRyUTUprszEMtU5QBi3rSL6RrQwOAAxedU7M8
-ghaVUgUAqCpNUE9NxKDhGMz5Ks20o6kUTW17w+xKx6sEGEZlVBHFNLDYm8My
-U2oxgARghj6yVLJMRX5IxV/NVICiBU7lCOoKuMqUwp9jIgtCFrokMUZVMuI8
-Tmf1Pr6criCzy8jbDSewnyWklg24ByGYqzQQ19kcAH44grny1WAdgP8WVYCK
-vcE75dSDuorK1L91Wi5OytDIe9Ze9FdZDVPizJ/kpBaPktbs2gA0kAEEoKZT
-ulRoJFcIhFiIrViLpdhzvcH449TmgxP54sajoShSnb0O48v23LZWzR8AsDT3
-ZCL1pJa2OywWSqK3IwGEPaXFVFFgtVhfpVid7VmLPVvHTL9hFVr+4R4Fuakz
-NMIirKM4nFpKJDHpItGo3EVMiwUyHVJMY6EasBYDYAJ8uIc0WFiwvVmzRICz
-5VlfdVyfPdc6rSZBALV17QiDcL0KuxGO05wiVCKrtVvoWdmjs9YyTV38cbRm
-vRZBiQH5dAAhgIK5QgCOXFGz3AGH5dnHVQD/ybXdnv1a9wu8zPWI5iPPrmoL
-olnW9qk95nTP4iTHqAxTWrPap82u160HBEjcB8Rdhx0ABChX8O3dx3XcseVI
-7qQmZgjazDUI8aCLMaM2/ks0uq1b6O03E3RDTKTeulXZltyuezHFI0hf790B
-2z1g8B1f3XVcBdiBYD2CmWXM7bw6Hizej3DfLf0dzEzDJDhaZo1Vu5289oxW
-mgxTzlTZu8VQQygAAoCEAZBA3C1XBEBgx63hI9Bd3zXbtN3O4xsA77RgjhiI
-g+AlCwPBuJEJFULVqe1fvMzEqHU7a+1LYNxW690uQ7ADfihX3YLANFhgAwbf
-HbjhA+7ZGR7bjvza/2dEUCC+YOMJAXnaJVvkSrrk0SU2Om6dSjoewLZSU16T
-ImZY2C0egDQ4YASA4Bmm4TKW3ExFX78rBIdbY48ooGjJsplISfSMG9A8TgJM
-WfYk2SHVy5BD0/zZgAHAA8ADvOGtTX5wYAPOYdvV3TC+YV8d4OBlZO6EUUgO
-CfArkwgYApdLu0FFyJiEVg5VTxS20CpG4Uo0ADsoBFNW3O6tzUP2XVY+5Bn2
-XQh+4QHGVHv8O34ggxjN5Y6IhQl4JkTxZQdYor4UU7z8Wzf8UQzt1+xi2qhE
-RweggkKgJtsdNtGDQH4oZAR4gVcG40PeWW6m2Paz3WpKg3AWZ5EwmolwAv/V
-BJIhMCLJUucTzt9I3S5pFc09Ttl5zrbkJIFT+OOEndnb7TtBNuBDNmCWdmAE
-cGDw1dmDXsw0AOefdGjNYJaJLhNSS7J2TlKFrN4LVVOjtgNBVmkeJqUudmkE
-IIUBcGoDnmXfzVmI5WYhKAP21enjaBDq7OndIACEo4t+hWc3tV6UWU5lVmZD
-OAXw5QfG7WZ7/GenjukdcGmYTmDbnemr/lUEKAMkoIWn4mo1SYINiMF4/Omj
-o7UopkTJS1P8ESjdxWqyDOiYtuuobuAcrmoEfmHb9dUyuE3CNpjYnYBW2ckM
-GWsu4cVrfbuV/WgmgoNCOALxTcVTQljZVABS2AH/KsDru77rQ05gCNzrQh4A
-OUACzB3tAYoFB5DowoyApeNRe10yVhVRA0jgyfYj4f1afliCF7jrAehtu/5t
-v9Zr4S6DwVbugjIaBqSQr3SCLFOMTI685DQAfCgERZbS90MA8X6Cu+7t3wZu
-CPZd8d3rAUADdVVvKzOEUSxMJwPHSzNqA0hMgbZlaGTqJwhvKQhwDpdY8z2C
-F3hYgdpqBXcxiI4B547HIYBvyVIrJsIHa67pqF6CJ6ACAP/vALfmax7gHWSC
-9C5xPCWBZHRwJ6ACQQDv7X5hhI3q395w3q5x3l4CmIZgiYXYHfxxIC9el/AL
-wQkSKCiEVjbwVNxmJq/x/yd4ASpYAhp/giUAcB1HaSF45CznagbcF2awcQW4
-4ZregSfYcCl4AjZ/ckCHZQiucGpKAyyfc8KO3VqwcZd2UfTlcxpXc0qXAkr/
-7RneAUAegDJIbkUvcRungvDObkylAktP8yx4glTfgSXIgt8GY4784U9Xbj1A
-A0enAjGXUja39FT/c0tXc0z/YvFCg0SfdcIGAwWwcf7OdbPs81b38x1wdSlY
-9fHm8QM39iwvhjbnbVIvUARQ81639F+n8Rz/2rXFdsImgzQP8INW9T6XAnjP
-Ang/9XJPWFlHd67WBWB39IOmglSX9yzIgiWY9z+vd073dHwnbD+gAjYHcAjs
-dv/ejoOAl/Y4kAKJ928oV+gjWL6EV289kINBJwVcf+EXrm1VD/hWl/hWF3hA
-53doFO2OH20kWHP/XgIxz2Y+jwMqiIMn0Hkv8IIl4HlAr3GOJPGYh2Q9gHc2
-b/gB/uxUfAIvyIKol3iq5/k1X4IWJaVzP/pc1oVUH3r/juqcneyA94I4OPuJ
-l3eh7+1UJF6uV/h/H/gnKO5sLmR/P3u8zwK8//NtT8VCQPi3F2c0GPhoH/So
-pmEqMHu8X3x/b3yzLL3AJ2x5h/eBx3UqB+gjMHvF13yJ//cv9ufIJ2yvF/iB
-l3LznlkEiIOf1/yfv4KJ/3wINPrQL14kEHh5r/wZBl//gN6BK7gCL+j91Xd9
-0jfwMph9rgaDP+jz218CijVgVjRgReh96Zd+V4+DAm1o48/cqLd9wg/jGs70
-6Q//oJ/7700DmM9+SEYDi3d1vYdqL7bdYgj/6c8Chs/ZAXgC9HdoRdD7Z5eC
-PwAIBQgEDkQg5coVPgkXZsnihcqANAMQoAFg8SLGjBo3cuzo8SPIkCJHkixp
-8mRJPw0bPnkiZQeCIzsm7liCcOHNK1moPJmIYAAYlEKHEi1q9CjSk5GyLMki
-hSUCBDB3KNiRRaFCnA3jwPSZ9CvYsGLHGkXzJo4UtFx37JDJ1qoihFmvePGS
-Lw7En/zI8u3r929SMHGyoHX6/5JtVKn55N7k4yUOZJhHEAgCbPky5swXL3hZ
-mfbJVKlSs+Bk/HjtgB1UNLNu7RopYbUNQ7+92lihIshcByog8/o38OAe9ajU
-bfUtYrhY5So6vcRnReHSp/+OpJtwFuRvF5dGWDfOksRyqJMvf1mwbrXaazJO
-mFWRouwxo5uvbx+sruuQD7+lYjPrXFfEVUxittx3IIJFnbZfHKRoZ1N7pe2m
-AH0JWnghSEgsGNkOfyzBFim2LRTgG1LtMB6GKaqYkS4IpSdFSzGy11hOCE1V
-xoo5rshHc9fF2NISVMQFYHvZ1aQjkheCcUV6cfwIWlNxjVjjW7okeeV9LboI
-GVMtSf+xBJhDCticlFd8uEOFWKo5HV1tQvaEk09kFyZCiixRDJgNnbnDBWv6
-KR0S3p2WxRNLFMpUUzp9KcUfpLzw6Asd7qLHn5X+5h1dg1k12BJSOIroH39A
-+igeO4BGqaWpahYJpo/l2VCojy4x6gtAPArEl0ugqCqvgC3ZKqdZvDArpMQC
-YWutQIAJZp+9OsuXHjfV1dBTX976AqO04gGEh8QG9Sy4Yi05mBTllruEqI9W
-G2q6j8b6KBLhyvsVGG9QO6uH7/7xxpfp4urhqEBYOS/BRsWR77voqtsvpEBc
-ETAQuxQ8MVH5KHytudgyXOuwUshhy8fxUjzySWAQmyy2sf5pwaiotsZaDMkx
-CwWGHKSQsjK/7b6g8sVAyPzzzIq80fMLCOXcLtBJm1TvxTvbtDEQpCg99UhL
-8luuqCu/C4TIVHvtkdUsu5tuMV1/ffZGOoF5q9S6oIo23Bsp8u4LZsd9N0YX
-ECv1mgEBADs=
-}
-
-# Filter out the process serial number on Mac OS X
-if {[set idx [lsearch -glob $argv "-psn*"]] >= 0} {
-    set argv [lreplace $argv $idx $idx]
-}
-array set args {
-    -inline 1
-}
-array set args $argv
-
-if {$args(-inline)} {
-    Init .
-}
diff --git a/tclxml-3.2/include/tcldom-libxml2/nodeObj.h b/tclxml-3.2/include/tcldom-libxml2/nodeObj.h
deleted file mode 100644
index 37a7bcc..0000000
--- a/tclxml-3.2/include/tcldom-libxml2/nodeObj.h
+++ /dev/null
@@ -1,28 +0,0 @@
-/* nodeObj.h --
- *
- *	This module manages libxml2 xmlNodePtr and event node Tcl objects.
- *
- * Copyright (c) 2003 Zveno Pty Ltd
- * http://www.zveno.com/
- *
- * See the file "LICENSE" for information on usage and
- * redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
- *
- * $Id: nodeObj.h,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
- */
-
-#ifndef TCLDOM_LIBXML2_NODEOBJ_H
-#define TCLDOM_LIBXML2_NODEOBJ_H
-
-#include "tcl.h"
-#include <libxml/tree.h>
-#include "tcldom-libxml2.h"
-
-#define TCLDOM_LIBXML2_NODE_NODE 0
-#define TCLDOM_LIBXML2_NODE_EVENT 1
-
-typedef void (TclDOM_libxml2Node_FreeHookProc) _ANSI_ARGS_((ClientData clientData));
-
-int TclDOM_libxml2_NodeObjInit _ANSI_ARGS_((Tcl_Interp *interp));
-
-#endif /* TCLDOM_LIBXML2_NODEOBJ_H */
diff --git a/tclxml-3.2/include/tcldom-libxml2/tcldom-libxml2.h b/tclxml-3.2/include/tcldom-libxml2/tcldom-libxml2.h
deleted file mode 100644
index 98fd3c8..0000000
--- a/tclxml-3.2/include/tcldom-libxml2/tcldom-libxml2.h
+++ /dev/null
@@ -1,266 +0,0 @@
-
-/* tcldom-libxml2.h --
- *
- *	libxml2 wrapper for TclDOM.
- *
- * Copyright (c) 2005-2008 Explain
- * http://www.explain.com.au/
- * Copyright (c) 2002-2003 Zveno Pty Ltd
- * http://www.zveno.com/
- *
- * See the file "LICENSE" for information on usage and
- * redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
- *
- * $Id: tcldom-libxml2.h,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
- */
-
-#ifndef __TCLDOM_LIBXML2_H__
-#define __TCLDOM_LIBXML2_H__
-
-#include <tcldom/tcldom.h>
-#include <tclxml/tclxml.h>
-#include <tclxml-libxml2/docObj.h>
-#include <tclxml-libxml2/tclxml-libxml2Decls.h>
-#include <libxml/tree.h>
-#include <libxml/xmlschemas.h>
-
-/*
- * For C++ compilers, use extern "C"
- */
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/*
- * These macros are used to control whether functions are being declared for
- * import or export in Windows, 
- * They map to no-op declarations on non-Windows systems.
- * Assumes that tcl.h defines DLLEXPORT & DLLIMPORT correctly.
- * The default build on windows is for a DLL, which causes the DLLIMPORT
- * and DLLEXPORT macros to be nonempty. To build a static library, the
- * macro STATIC_BUILD should be defined before the inclusion of tcl.h
- *
- * If a function is being declared while it is being built
- * to be included in a shared library, then it should have the DLLEXPORT
- * storage class.  If is being declared for use by a module that is going to
- * link against the shared library, then it should have the DLLIMPORT storage
- * class.  If the symbol is beind declared for a static build or for use from a
- * stub library, then the storage class should be empty.
- *
- * The convention is that a macro called BUILD_xxxx, where xxxx is the
- * name of a library we are building, is set on the compile line for sources
- * that are to be placed in the library.  When this macro is set, the
- * storage class will be set to DLLEXPORT.  At the end of the header file, the
- * storage class will be reset to DLLIMPORt.
- */
-
-#undef TCL_STORAGE_CLASS
-#ifdef BUILD_Tcldom_libxml2
-# define TCL_STORAGE_CLASS DLLEXPORT
-#else
-# ifdef USE_TCL_STUBS
-#  define TCL_STORAGE_CLASS
-# else
-#  define TCL_STORAGE_CLASS DLLIMPORT
-# endif
-#endif
-
-/*
- * The following function is required to be defined in all stubs aware
- * extensions of TclDOM.  The function is actually implemented in the stub
- * library, not the main Tcldom library, although there is a trivial
- * implementation in the main library in case an extension is statically
- * linked into an application.
- */
-
-EXTERN CONST char *	Tcldom_libxml2_InitStubs _ANSI_ARGS_((Tcl_Interp *interp,
-			    CONST char *version, int exact));
-
-#ifndef USE_TCLDOMXML_STUBS
-
-/*
- * When not using stubs, make it a macro.
- */
-
-#define Tcldom_libxml2_InitStubs(interp, version, exact) \
-    Tcl_PkgRequire(interp, "dom::generic", version, exact)
-
-#endif
-
-/*
- * DOM-specific data structure to hook onto documents.
- */
-
-typedef struct TclDOM_libxml2_Document {
-  Tcl_Interp *interp;
-  TclXML_libxml2_Document *tDocPtr;	/* Pointer back to main document structure */
-  Tcl_Obj *objPtr;	/* An object to hold onto for this document */
-  Tcl_Command cmd;	/* Tcl command for this document */
-
-  Tcl_HashTable *nodes;
-  int nodeCntr;
-
-  /*
-   * Validation support
-   */
-
-  xmlSchemaPtr schema; /* XML Schemas */
-  /* xmlRelaxNGPtr relaxng; */
-
-  /*
-   * Event support.
-   *
-   * These tables are indexed by xmlNodePtr.
-   */
-
-  Tcl_HashTable *captureListeners;
-  Tcl_HashTable *bubbleListeners;
-
-  /*
-   * Optimisation: boolean flag to indicate whether an
-   * event listener is registered for an event type.
-   * If no event listeners are registered then there is
-   * no point in propagating the event.
-   */
-
-  int listening[TCLDOM_NUM_EVENT_TYPES];
-
-} TclDOM_libxml2_Document;
-
-/*
- * Node management
- */
-
-/*
- * "nodes" are overloaded: they can be either a libxml2 xmlNodePtr or 
- * an event, which is defined by this module.
- */
-
-typedef struct _TclDOM_libxml2_Node TclDOM_libxml2_Node;
-
-#define TCLDOM_LIBXML2_NODE_NODE 0
-#define TCLDOM_LIBXML2_NODE_EVENT 1
-
-/*
- * Data structure to support Events
- */
-
-typedef struct TclDOM_libxml2_Event {
-  TclDOM_libxml2_Node *tNodePtr;	/* Generic node structure for this event */
-  TclDOM_libxml2_Document *ownerDocument;	/* Toplevel Document for this event */
-
-  enum TclDOM_EventTypes type;	/* Enumerate rep of event type */
-  Tcl_Obj *typeObjPtr;		/* For user defined event type */
-
-  int stopPropagation;
-  int preventDefault;
-  int dispatched;
-
-  Tcl_Obj *altKey;
-  Tcl_Obj *attrName;
-  Tcl_Obj *attrChange;
-  Tcl_Obj *bubbles;
-  Tcl_Obj *button;
-  Tcl_Obj *cancelable;
-  Tcl_Obj *clientX;
-  Tcl_Obj *clientY;
-  Tcl_Obj *ctrlKey;
-  Tcl_Obj *currentNode;
-  Tcl_Obj *detail;
-  Tcl_Obj *eventPhase;
-  Tcl_Obj *metaKey;
-  Tcl_Obj *newValue;
-  Tcl_Obj *prevValue;
-  Tcl_Obj *relatedNode;
-  Tcl_Obj *screenX;
-  Tcl_Obj *screenY;
-  Tcl_Obj *shiftKey;
-  Tcl_Obj *target;
-  Tcl_Obj *timeStamp;
-  Tcl_Obj *view;
-} TclDOM_libxml2_Event;
-
-typedef void (TclDOM_libxml2_Node_FreeHookProc) _ANSI_ARGS_((ClientData clientData));
-
-struct _TclDOM_libxml2_Node {
-  union {
-    xmlNodePtr nodePtr;
-    TclDOM_libxml2_Event *eventPtr;
-  } ptr;
-
-  int type;			/* Distinguish between libxml2 nodes and events */
-
-  char *token;			/* string rep of this node */
-  Tcl_Command cmd;		/* Tcl command that access this structure */
-
-  void *objs;			/* Opaque object for tracking Tcl_Obj's that refer to this node */
-
-  ClientData apphook;		/* Application hook - not used by TclXML or TclDOM */
-  TclDOM_libxml2_Node_FreeHookProc *appfree;
-};
-
-/*
- * Public API
- */
-
-Tcl_Obj * TclDOM_libxml2_CreateObjFromDoc _ANSI_ARGS_((Tcl_Interp *interp, xmlDocPtr docPtr));
-Tcl_Obj * TclDOM_libxml2_CreateObjFromNode _ANSI_ARGS_((Tcl_Interp *interp, xmlNodePtr nodePtr));
-int TclDOM_libxml2_GetNodeFromObj _ANSI_ARGS_((Tcl_Interp *interp, Tcl_Obj *objPtr, xmlNodePtr *nodePtrPtr));
-int TclDOM_libxml2_GetTclNodeFromObj _ANSI_ARGS_((Tcl_Interp *interp, Tcl_Obj *objPtr, TclDOM_libxml2_Node **tNodePtrPtr));
-int TclDOM_libxml2_GetEventFromObj _ANSI_ARGS_((Tcl_Interp *interp, Tcl_Obj *objPtr, TclDOM_libxml2_Event **eventPtrPtr));
-int TclDOM_libxml2_GetTclEventFromObj _ANSI_ARGS_((Tcl_Interp *interp, Tcl_Obj *objPtr, TclDOM_libxml2_Node **tNodePtrPtr));
-
-int TclDOM_PostMutationEvent _ANSI_ARGS_((Tcl_Interp *interp,
-					  TclXML_libxml2_Document *tDocPtr,
-					  Tcl_Obj *nodeObjPtr,
-					  enum TclDOM_EventTypes type,
-					  Tcl_Obj *typeObjPtr,
-					  Tcl_Obj *bubblesPtr,
-					  Tcl_Obj *cancelablePtr,
-					  Tcl_Obj *relatedNodePtr,
-					  Tcl_Obj *prevValuePtr,
-					  Tcl_Obj *newValuePtr,
-					  Tcl_Obj *attrNamePtr,
-					  Tcl_Obj *attrChangePtr));
-int TclDOM_AddEventListener _ANSI_ARGS_((Tcl_Interp *interp,
-					 TclXML_libxml2_Document *tDocPtr,
-					 void *tokenPtr, /* xmlNodePtr or xmlDocPtr */
-					 enum TclDOM_EventTypes type,
-					 Tcl_Obj *typeObjPtr,
-					 Tcl_Obj *listenerPtr,
-					 int capturer));
-Tcl_Obj * TclDOM_GetEventListener _ANSI_ARGS_((Tcl_Interp *interp,
-					       TclXML_libxml2_Document *tDocPtr,
-					       void *tokenPtr,
-					       enum TclDOM_EventTypes type,
-					       Tcl_Obj *typeObjPtr,
-					       int capturer));
-int TclDOM_RemoveEventListener _ANSI_ARGS_((Tcl_Interp *interp,
-					    TclXML_libxml2_Document *tDocPtr,
-					    void *tokenPtr,
-					    enum TclDOM_EventTypes type,
-					    Tcl_Obj *typeObjPtr,
-					    Tcl_Obj *listenerPtr,
-					    int capturer));
-int TclDOM_DispatchEvent _ANSI_ARGS_((Tcl_Interp *interp,
-				      Tcl_Obj *nodeObjPtr,
-				      Tcl_Obj *eventObjPtr,
-				      TclDOM_libxml2_Event *eventPtr));
-
-/*
- * Accessor functions => Stubs
- */
-
-/*
-#include <tcldom-libxml2/tcldomlibxml2Decls.h>
-
-#undef  TCL_STORAGE_CLASS
-#define TCL_STORAGE_CLASS DLLIMPORT
-*/
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif /* TCLDOM_LIBXML2_H__ */
diff --git a/tclxml-3.2/include/tcldom/tcldom.h b/tclxml-3.2/include/tcldom/tcldom.h
deleted file mode 100644
index 08a016b..0000000
--- a/tclxml-3.2/include/tcldom/tcldom.h
+++ /dev/null
@@ -1,293 +0,0 @@
-/* tcldom.h --
- *
- *	Generic layer of TclDOM API.
- *
- * Copyright (c) 2006-2008 Explain
- * http://www.explain.com.au/
- * Copyright (c) 2002-2004 Zveno Pty Ltd
- * http://www.zveno.com/
- *
- * Zveno Pty Ltd makes this software and associated documentation
- * available free of charge for any purpose.  You may make copies
- * of the software but you must include all of this notice on any copy.
- *
- * Zveno Pty Ltd does not warrant that this software is error free
- * or fit for any purpose.  Zveno Pty Ltd disclaims any liability for
- * all claims, expenses, losses, damages and costs any user may incur
- * as a result of using, copying or modifying the software.
- *
- * $Id: tcldom.h,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
- */
-
-#ifndef __TCLDOM_H__
-#define __TCLDOM_H__
-
-#include <tcl.h>
-
-/*
- * For C++ compilers, use extern "C"
- */
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/*
-
- * These macros are used to control whether functions are being declared for
- * import or export in Windows, 
- * They map to no-op declarations on non-Windows systems.
- * Assumes that tcl.h defines DLLEXPORT & DLLIMPORT correctly.
- * The default build on windows is for a DLL, which causes the DLLIMPORT
- * and DLLEXPORT macros to be nonempty. To build a static library, the
- * macro STATIC_BUILD should be defined before the inclusion of tcl.h
- *
- * If a function is being declared while it is being built
- * to be included in a shared library, then it should have the DLLEXPORT
- * storage class.  If is being declared for use by a module that is going to
- * link against the shared library, then it should have the DLLIMPORT storage
- * class.  If the symbol is beind declared for a static build or for use from a
- * stub library, then the storage class should be empty.
- *
- * The convention is that a macro called BUILD_xxxx, where xxxx is the
- * name of a library we are building, is set on the compile line for sources
- * that are to be placed in the library.  When this macro is set, the
- * storage class will be set to DLLEXPORT.  At the end of the header file, the
- * storage class will be reset to DLLIMPORt.
- */
-
-#undef TCL_STORAGE_CLASS
-#ifdef BUILD_tcldom
-# define TCL_STORAGE_CLASS DLLEXPORT
-#else
-# ifdef USE_TCL_STUBS
-#  define TCL_STORAGE_CLASS
-# else
-#  define TCL_STORAGE_CLASS DLLIMPORT
-# endif
-#endif
-
-/*
- * The main purpose of this module is to provide common switch tables
- * for command methods and options.
- */
-
-enum TclDOM_DOMImplementationCommandMethods {
-  TCLDOM_IMPL_HASFEATURE,
-  TCLDOM_IMPL_CREATEDOCUMENT,
-  TCLDOM_IMPL_CREATE,
-  TCLDOM_IMPL_CREATEDOCUMENTTYPE,
-  TCLDOM_IMPL_CREATENODE,
-  TCLDOM_IMPL_DESTROY,
-  TCLDOM_IMPL_ISNODE,
-  TCLDOM_IMPL_PARSE,
-  TCLDOM_IMPL_SELECTNODE,
-  TCLDOM_IMPL_SERIALIZE,
-  TCLDOM_IMPL_TRIM
-};
-enum TclDOM_DocumentCommandMethods {
-  TCLDOM_DOCUMENT_CGET,
-  TCLDOM_DOCUMENT_CONFIGURE,
-  TCLDOM_DOCUMENT_CREATEELEMENT,
-  TCLDOM_DOCUMENT_CREATEDOCUMENTFRAGMENT,
-  TCLDOM_DOCUMENT_CREATETEXTNODE,
-  TCLDOM_DOCUMENT_CREATECOMMENT,
-  TCLDOM_DOCUMENT_CREATECDATASECTION,
-  TCLDOM_DOCUMENT_CREATEPI,
-  TCLDOM_DOCUMENT_CREATEATTRIBUTE,
-  TCLDOM_DOCUMENT_CREATEENTITY,
-  TCLDOM_DOCUMENT_CREATEENTITYREFERENCE,
-  TCLDOM_DOCUMENT_CREATEDOCTYPEDECL,
-  TCLDOM_DOCUMENT_IMPORTNODE,
-  TCLDOM_DOCUMENT_CREATEELEMENTNS,
-  TCLDOM_DOCUMENT_CREATEATTRIBUTENS,
-  TCLDOM_DOCUMENT_GETELEMENTSBYTAGNAMENS,
-  TCLDOM_DOCUMENT_GETELEMENTSBYID,
-  TCLDOM_DOCUMENT_CREATEEVENT,
-  TCLDOM_DOCUMENT_GETELEMENTSBYTAGNAME,
-  TCLDOM_DOCUMENT_DTD,
-  TCLDOM_DOCUMENT_SCHEMA
-};
-enum TclDOM_DocumentCommandOptions {
-  TCLDOM_DOCUMENT_DOCTYPE,
-  TCLDOM_DOCUMENT_IMPLEMENTATION,
-  TCLDOM_DOCUMENT_DOCELEMENT
-};
-enum TclDOM_DocumentDTDSubmethods {
-  TCLDOM_DOCUMENT_DTD_VALIDATE
-};
-enum TclDOM_DocumentSchemaSubmethods {
-  TCLDOM_DOCUMENT_SCHEMA_COMPILE,
-  TCLDOM_DOCUMENT_SCHEMA_VALIDATE
-};
-enum TclDOM_DocumentRelaxNGSubmethods {
-  TCLDOM_DOCUMENT_RELAXNG_COMPILE,
-  TCLDOM_DOCUMENT_RELAXNG_VALIDATE
-};
-enum TclDOM_NodeCommandMethods {
-  TCLDOM_NODE_CGET,
-  TCLDOM_NODE_CONFIGURE,
-  TCLDOM_NODE_INSERTBEFORE,
-  TCLDOM_NODE_REPLACECHILD,
-  TCLDOM_NODE_REMOVECHILD,
-  TCLDOM_NODE_APPENDCHILD,
-  TCLDOM_NODE_HASCHILDNODES,
-  TCLDOM_NODE_CLONENODE,
-  TCLDOM_NODE_CHILDREN,
-  TCLDOM_NODE_PARENT,
-  TCLDOM_NODE_PATH,
-  TCLDOM_NODE_CREATENODE,
-  TCLDOM_NODE_SELECTNODE,
-  TCLDOM_NODE_STRINGVALUE,
-  TCLDOM_NODE_ADDEVENTLISTENER,
-  TCLDOM_NODE_REMOVEEVENTLISTENER,
-  TCLDOM_NODE_DISPATCHEVENT,
-  TCLDOM_NODE_ISSAMENODE
-};
-enum TclDOM_NodeCommandOptions {
-  TCLDOM_NODE_NODETYPE,
-  TCLDOM_NODE_PARENTNODE,
-  TCLDOM_NODE_CHILDNODES,
-  TCLDOM_NODE_FIRSTCHILD,
-  TCLDOM_NODE_LASTCHILD,
-  TCLDOM_NODE_PREVIOUSSIBLING,
-  TCLDOM_NODE_NEXTSIBLING,
-  TCLDOM_NODE_ATTRIBUTES,
-  TCLDOM_NODE_NAMESPACEURI,
-  TCLDOM_NODE_PREFIX,
-  TCLDOM_NODE_LOCALNAME,
-  TCLDOM_NODE_NODEVALUE,
-  TCLDOM_NODE_CDATASECTION,
-  TCLDOM_NODE_NODENAME,
-  TCLDOM_NODE_OWNERDOCUMENT
-};
-enum TclDOM_NodeCommandAddEventListenerOptions {
-  TCLDOM_NODE_ADDEVENTLISTENER_USECAPTURE
-};
-enum TclDOM_ElementCommandMethods {
-  TCLDOM_ELEMENT_CGET,
-  TCLDOM_ELEMENT_CONFIGURE,
-  TCLDOM_ELEMENT_GETATTRIBUTE,
-  TCLDOM_ELEMENT_SETATTRIBUTE,
-  TCLDOM_ELEMENT_REMOVEATTRIBUTE,
-  TCLDOM_ELEMENT_GETATTRIBUTENS,
-  TCLDOM_ELEMENT_SETATTRIBUTENS,
-  TCLDOM_ELEMENT_REMOVEATTRIBUTENS,
-  TCLDOM_ELEMENT_GETATTRIBUTENODE,
-  TCLDOM_ELEMENT_SETATTRIBUTENODE,
-  TCLDOM_ELEMENT_REMOVEATTRIBUTENODE,
-  TCLDOM_ELEMENT_GETATTRIBUTENODENS,
-  TCLDOM_ELEMENT_SETATTRIBUTENODENS,
-  TCLDOM_ELEMENT_REMOVEATTRIBUTENODENS,
-  TCLDOM_ELEMENT_GETELEMENTSBYTAGNAME,
-  TCLDOM_ELEMENT_NORMALIZE
-};
-enum TclDOM_ElementCommandOptions {
-  TCLDOM_ELEMENT_TAGNAME,
-  TCLDOM_ELEMENT_EMPTY
-};
-enum TclDOM_EventCommandMethods {
-  TCLDOM_EVENT_CGET,
-  TCLDOM_EVENT_CONFIGURE,
-  TCLDOM_EVENT_STOPPROPAGATION,
-  TCLDOM_EVENT_PREVENTDEFAULT,
-  TCLDOM_EVENT_INITEVENT,
-  TCLDOM_EVENT_INITUIEVENT,
-  TCLDOM_EVENT_INITMOUSEEVENT,
-  TCLDOM_EVENT_INITMUTATIONEVENT,
-  TCLDOM_EVENT_POSTUIEVENT,
-  TCLDOM_EVENT_POSTMOUSEEVENT,
-  TCLDOM_EVENT_POSTMUTATIONEVENT
-};
-enum TclDOM_EventCommandOptions {
-  TCLDOM_EVENT_ALTKEY,
-  TCLDOM_EVENT_ATTRNAME,
-  TCLDOM_EVENT_ATTRCHANGE,
-  TCLDOM_EVENT_BUBBLES,
-  TCLDOM_EVENT_BUTTON,
-  TCLDOM_EVENT_CANCELABLE,
-  TCLDOM_EVENT_CLIENTX,
-  TCLDOM_EVENT_CLIENTY,
-  TCLDOM_EVENT_CTRLKEY,
-  TCLDOM_EVENT_CURRENTNODE,
-  TCLDOM_EVENT_DETAIL,
-  TCLDOM_EVENT_EVENTPHASE,
-  TCLDOM_EVENT_METAKEY,
-  TCLDOM_EVENT_NEWVALUE,
-  TCLDOM_EVENT_PREVVALUE,
-  TCLDOM_EVENT_RELATEDNODE,
-  TCLDOM_EVENT_SCREENX,
-  TCLDOM_EVENT_SCREENY,
-  TCLDOM_EVENT_SHIFTKEY,
-  TCLDOM_EVENT_TARGET,
-  TCLDOM_EVENT_TIMESTAMP,
-  TCLDOM_EVENT_TYPE,
-  TCLDOM_EVENT_VIEW
-};
-  /*
-   * NB. TCLDOM_EVENT_USERDEFINED does not have an entry in the string table.
-   */
-enum TclDOM_EventTypes {
-  TCLDOM_EVENT_DOMFOCUSIN,
-  TCLDOM_EVENT_DOMFOCUSOUT,
-  TCLDOM_EVENT_DOMACTIVATE,
-  TCLDOM_EVENT_CLICK,
-  TCLDOM_EVENT_MOUSEDOWN,
-  TCLDOM_EVENT_MOUSEUP,
-  TCLDOM_EVENT_MOUSEOVER,
-  TCLDOM_EVENT_MOUSEMOVE,
-  TCLDOM_EVENT_MOUSEOUT,
-  TCLDOM_EVENT_DOMSUBTREEMODIFIED,
-  TCLDOM_EVENT_DOMNODEINSERTED,
-  TCLDOM_EVENT_DOMNODEREMOVED,
-  TCLDOM_EVENT_DOMNODEINSERTEDINTODOCUMENT,
-  TCLDOM_EVENT_DOMNODEREMOVEDFROMDOCUMENT,
-  TCLDOM_EVENT_DOMATTRMODIFIED,
-  TCLDOM_EVENT_DOMCHARACTERDATAMODIFIED,
-  TCLDOM_EVENT_USERDEFINED
-};
-enum TclDOM_ParseCommandOptions {
-  TCLDOM_PARSE_BASEURI,
-  TCLDOM_PARSE_EXTERNALENTITYCOMMAND
-};
-enum TclDOM_SerializeCommandOptions {
-  TCLDOM_SERIALIZE_INDENT,
-  TCLDOM_SERIALIZE_METHOD,
-  TCLDOM_SERIALIZE_ENCODING,
-  TCLDOM_SERIALIZE_OMIT_XML_DECLARATION
-};
-enum TclDOM_SerializeMethods {
-  TCLDOM_SERIALIZE_METHOD_XML,
-  TCLDOM_SERIALIZE_METHOD_HTML,
-  TCLDOM_SERIALIZE_METHOD_TEXT
-};
-enum TclDOM_SelectNodeOptions {
-  TCLDOM_SELECTNODE_OPTION_NAMESPACES
-};
-
-/*
- * DOM Level 2 Event support
- */
-
-#define TCLDOM_NUM_EVENT_TYPES 17
-
-/*
- * The following function is required to be defined in all stubs aware
- * extensions of TclDOM.  The function is actually implemented in the stub
- * library, not the main Tcldom library, although there is a trivial
- * implementation in the main library in case an extension is statically
- * linked into an application.
- */
-
-#ifndef USE_TCLDOM_STUBS
-
-#undef TCL_STORAGE_CLASS
-#define TCL_STORAGE_CLASS DLLIMPORT
-
-#endif
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif /* __TCLDOM_H__ */
diff --git a/tclxml-3.2/include/tclxml-libxml2/docObj.h b/tclxml-3.2/include/tclxml-libxml2/docObj.h
deleted file mode 100644
index aaffb2e..0000000
--- a/tclxml-3.2/include/tclxml-libxml2/docObj.h
+++ /dev/null
@@ -1,60 +0,0 @@
-/* docObj.h --
- *
- *	This module manages libxml2 xmlDocPtr Tcl objects.
- *
- * Copyright (c) 2003 Zveno Pty Ltd
- * http://www.zveno.com/
- *
- * Zveno Pty Ltd makes this software and associated documentation
- * available free of charge for any purpose.  You may make copies
- * of the software but you must include all of this notice on any copy.
- *
- * Zveno Pty Ltd does not warrant that this software is error free
- * or fit for any purpose.  Zveno Pty Ltd disclaims any liability for
- * all claims, expenses, losses, damages and costs any user may incur
- * as a result of using, copying or modifying the software.
- *
- * $Id: docObj.h,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
- */
-
-#ifndef TCLXML_LIBXML2_DOCOBJ_H
-#define TCLXML_LIBXML2_DOCOBJ_H
-
-#ifdef TCLXML_BUILD_AS_FRAMEWORK
-#include <Tcl/tcl.h>
-#else
-#include <tcl.h>
-#endif /* TCLXML_BUILD_AS_FRAMEWORK */
-#include <libxml/tree.h>
-
-typedef void (TclXML_libxml2Doc_FreeHookProc) _ANSI_ARGS_((ClientData clientData));
-
-/*
- * Values that define how documents are handled:
- * KEEP means that documents must be explicitly destroyed,
- * IMPLICIT means that documents will be destroyed when there are no longer
- * any references to it.
- */
-
-typedef enum TclXML_libxml2_DocumentHandling {
-  TCLXML_LIBXML2_DOCUMENT_KEEP,
-  TCLXML_LIBXML2_DOCUMENT_IMPLICIT
-} TclXML_libxml2_DocumentHandling;
-
-typedef struct TclXML_libxml2_Document {
-  xmlDocPtr docPtr;
-
-  char *token;			/* string rep of this document */
-
-  TclXML_libxml2_DocumentHandling keep;
-				/* how to handle document destruction */
-
-  void *objs;			/* List of Tcl_Obj's that reference this document */
-
-  ClientData dom;		/* Hook for TclDOM data */
-  TclXML_libxml2Doc_FreeHookProc *domfree;
-  ClientData apphook;		/* Application hook - not used by TclXML or TclDOM */
-  TclXML_libxml2Doc_FreeHookProc *appfree;
-} TclXML_libxml2_Document;
-
-#endif /* TCLXML_LIBXML2_DOCOBJ_H */
diff --git a/tclxml-3.2/include/tclxml-libxml2/tclxml-libxml2.h b/tclxml-3.2/include/tclxml-libxml2/tclxml-libxml2.h
deleted file mode 100644
index 22050f4..0000000
--- a/tclxml-3.2/include/tclxml-libxml2/tclxml-libxml2.h
+++ /dev/null
@@ -1,100 +0,0 @@
-/* tcllibxml2.h --
- *
- *	This module provides an interface to libxml2.
- *
- * Copyright (c) 2005 Explain
- * http://www.explain.com.au/
- * Copyright (c) 2003 Zveno Pty Ltd
- * http://www.zveno.com/
- *
- * See the file "LICENSE" for information on usage and
- * redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
- *
- * $Id: tclxml-libxml2.h,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
- */
-
-#ifndef TCLXML_LIBXML2_H
-#define TCLXML_LIBXML2_H
-
-#include <tclxml/tclxml.h>
-#include <libxml/tree.h>
-#include "docObj.h"
-
-/*
- * For C++ compilers, use extern "C"
- */
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/*
- * These macros are used to control whether functions are being declared for
- * import or export in Windows, 
- * They map to no-op declarations on non-Windows systems.
- * Assumes that tcl.h defines DLLEXPORT & DLLIMPORT correctly.
- * The default build on windows is for a DLL, which causes the DLLIMPORT
- * and DLLEXPORT macros to be nonempty. To build a static library, the
- * macro STATIC_BUILD should be defined before the inclusion of tcl.h
- *
- * If a function is being declared while it is being built
- * to be included in a shared library, then it should have the DLLEXPORT
- * storage class.  If is being declared for use by a module that is going to
- * link against the shared library, then it should have the DLLIMPORT storage
- * class.  If the symbol is beind declared for a static build or for use from a
- * stub library, then the storage class should be empty.
- *
- * The convention is that a macro called BUILD_xxxx, where xxxx is the
- * name of a library we are building, is set on the compile line for sources
- * that are to be placed in the library.  When this macro is set, the
- * storage class will be set to DLLEXPORT.  At the end of the header file, the
- * storage class will be reset to DLLIMPORt.
- */
-
-#undef TCL_STORAGE_CLASS
-#ifdef BUILD_TclXML_libxml2
-# define TCL_STORAGE_CLASS DLLEXPORT
-#else
-# ifdef USE_TCL_STUBS
-#  define TCL_STORAGE_CLASS
-# else
-#  define TCL_STORAGE_CLASS DLLIMPORT
-# endif
-#endif
-
-/*
- * The following function is required to be defined in all stubs aware
- * extensions of TclXML/libxml2.  The function is actually implemented in the stub
- * library, not the main TclXML/libxml2 library, although there is a trivial
- * implementation in the main library in case an extension is statically
- * linked into an application.
- */
-
-EXTERN CONST char *     TclXML_libxml2_InitStubs _ANSI_ARGS_((Tcl_Interp *interp,
-                            CONST char *version, int exact));
-
-#ifndef USE_TCLXML_LIBXML2_STUBS
-
-/*
- * When not using stubs, make it a macro.
- */
-
-#define TclXML_libxml2_InitStubs(interp, version, exact) \
-    Tcl_PkgRequire(interp, "xml::libxml2", version, exact)
-
-#endif
-
-/*
- * Accessor functions => Stubs
- */
-
-#include <tclxml-libxml2/tclxml-libxml2Decls.h>
-
-#undef  TCL_STORAGE_CLASS
-#define TCL_STORAGE_CLASS DLLIMPORT
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif /* TCLXML_LIBXML2_H */
diff --git a/tclxml-3.2/include/tclxml-libxml2/tclxml-libxml2Decls.h b/tclxml-3.2/include/tclxml-libxml2/tclxml-libxml2Decls.h
deleted file mode 100644
index 187b159..0000000
--- a/tclxml-3.2/include/tclxml-libxml2/tclxml-libxml2Decls.h
+++ /dev/null
@@ -1,163 +0,0 @@
-/*
- * tclxml-libxml2Decls.h --
- *
- *      Declarations of functions in the platform independent public TCLXML/libxml2 API.
- *
- */
-
-#ifndef _TCLXMLLIBXML2DECLS
-#define _TCLXMLLIBXML2DECLS
-
-/*
- * WARNING: The contents of this file is automatically generated by the
- * genStubs.tcl script. Any modifications to the function declarations
- * below should be made in the tcllibxml2.decls script.
- */
-
-#include "docObj.h"
-#include <libxml/xmlerror.h>
-
-/* !BEGIN!: Do not edit below this line. */
-
-/*
- * Exported function declarations:
- */
-
-/* 0 */
-EXTERN int		Tclxml_libxml2_Init _ANSI_ARGS_((Tcl_Interp * interp));
-/* Slot 1 is reserved */
-/* 2 */
-EXTERN int		TclXML_libxml2_InitDocObj _ANSI_ARGS_((
-				Tcl_Interp * interp));
-/* 3 */
-EXTERN Tcl_Obj *	TclXML_libxml2_NewDocObj _ANSI_ARGS_((
-				Tcl_Interp * interp));
-/* 4 */
-EXTERN Tcl_Obj *	TclXML_libxml2_CreateObjFromDoc _ANSI_ARGS_((
-				xmlDocPtr docPtr));
-/* 5 */
-EXTERN int		TclXML_libxml2_GetDocFromObj _ANSI_ARGS_((
-				Tcl_Interp * interp, Tcl_Obj * objPtr, 
-				xmlDocPtr * docPtr));
-/* 6 */
-EXTERN int		TclXML_libxml2_GetTclDocFromObj _ANSI_ARGS_((
-				Tcl_Interp * interp, Tcl_Obj * objPtr, 
-				TclXML_libxml2_Document ** tDocPtrPtr));
-/* 7 */
-EXTERN int		TclXML_libxml2_GetTclDocFromNode _ANSI_ARGS_((
-				Tcl_Interp * interp, xmlNodePtr nodePtr, 
-				TclXML_libxml2_Document ** tDocPtrPtr));
-/* 8 */
-EXTERN void		TclXML_libxml2_DestroyDocument _ANSI_ARGS_((
-				TclXML_libxml2_Document * tDocPtr));
-/* 9 */
-EXTERN void		TclXML_libxml2_DocKeep _ANSI_ARGS_((Tcl_Obj * objPtr, 
-				TclXML_libxml2_DocumentHandling keep));
-/* 10 */
-EXTERN void		TclXML_libxml2_ErrorHandler _ANSI_ARGS_((void * ctx, 
-				xmlErrorPtr error));
-/* 11 */
-EXTERN void		TclXML_libxml2_ResetError _ANSI_ARGS_((
-				Tcl_Interp * interp));
-/* 12 */
-EXTERN Tcl_Obj *	TclXML_libxml2_GetErrorObj _ANSI_ARGS_((
-				Tcl_Interp * interp));
-/* 13 */
-EXTERN void		TclXML_libxml2_SetErrorNodeFunc _ANSI_ARGS_((
-				Tcl_Interp * interp, 
-				TclXML_ErrorNodeHandlerProc * proc));
-
-typedef struct Tclxml_libxml2Stubs {
-    int magic;
-    struct Tclxml_libxml2StubHooks *hooks;
-
-    int (*tclxml_libxml2_Init) _ANSI_ARGS_((Tcl_Interp * interp)); /* 0 */
-    void *reserved1;
-    int (*tclXML_libxml2_InitDocObj) _ANSI_ARGS_((Tcl_Interp * interp)); /* 2 */
-    Tcl_Obj * (*tclXML_libxml2_NewDocObj) _ANSI_ARGS_((Tcl_Interp * interp)); /* 3 */
-    Tcl_Obj * (*tclXML_libxml2_CreateObjFromDoc) _ANSI_ARGS_((xmlDocPtr docPtr)); /* 4 */
-    int (*tclXML_libxml2_GetDocFromObj) _ANSI_ARGS_((Tcl_Interp * interp, Tcl_Obj * objPtr, xmlDocPtr * docPtr)); /* 5 */
-    int (*tclXML_libxml2_GetTclDocFromObj) _ANSI_ARGS_((Tcl_Interp * interp, Tcl_Obj * objPtr, TclXML_libxml2_Document ** tDocPtrPtr)); /* 6 */
-    int (*tclXML_libxml2_GetTclDocFromNode) _ANSI_ARGS_((Tcl_Interp * interp, xmlNodePtr nodePtr, TclXML_libxml2_Document ** tDocPtrPtr)); /* 7 */
-    void (*tclXML_libxml2_DestroyDocument) _ANSI_ARGS_((TclXML_libxml2_Document * tDocPtr)); /* 8 */
-    void (*tclXML_libxml2_DocKeep) _ANSI_ARGS_((Tcl_Obj * objPtr, TclXML_libxml2_DocumentHandling keep)); /* 9 */
-    void (*tclXML_libxml2_ErrorHandler) _ANSI_ARGS_((void * ctx, xmlErrorPtr error)); /* 10 */
-    void (*tclXML_libxml2_ResetError) _ANSI_ARGS_((Tcl_Interp * interp)); /* 11 */
-    Tcl_Obj * (*tclXML_libxml2_GetErrorObj) _ANSI_ARGS_((Tcl_Interp * interp)); /* 12 */
-    void (*tclXML_libxml2_SetErrorNodeFunc) _ANSI_ARGS_((Tcl_Interp * interp, TclXML_ErrorNodeHandlerProc * proc)); /* 13 */
-} Tclxml_libxml2Stubs;
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-extern Tclxml_libxml2Stubs *tclxml_libxml2StubsPtr;
-#ifdef __cplusplus
-}
-#endif
-
-#if defined(USE_TCLXML_LIBXML2_STUBS) && !defined(USE_TCLXML_LIBXML2_STUB_PROCS)
-
-/*
- * Inline function declarations:
- */
-
-#ifndef Tclxml_libxml2_Init
-#define Tclxml_libxml2_Init \
-	(tclxml_libxml2StubsPtr->tclxml_libxml2_Init) /* 0 */
-#endif
-/* Slot 1 is reserved */
-#ifndef TclXML_libxml2_InitDocObj
-#define TclXML_libxml2_InitDocObj \
-	(tclxml_libxml2StubsPtr->tclXML_libxml2_InitDocObj) /* 2 */
-#endif
-#ifndef TclXML_libxml2_NewDocObj
-#define TclXML_libxml2_NewDocObj \
-	(tclxml_libxml2StubsPtr->tclXML_libxml2_NewDocObj) /* 3 */
-#endif
-#ifndef TclXML_libxml2_CreateObjFromDoc
-#define TclXML_libxml2_CreateObjFromDoc \
-	(tclxml_libxml2StubsPtr->tclXML_libxml2_CreateObjFromDoc) /* 4 */
-#endif
-#ifndef TclXML_libxml2_GetDocFromObj
-#define TclXML_libxml2_GetDocFromObj \
-	(tclxml_libxml2StubsPtr->tclXML_libxml2_GetDocFromObj) /* 5 */
-#endif
-#ifndef TclXML_libxml2_GetTclDocFromObj
-#define TclXML_libxml2_GetTclDocFromObj \
-	(tclxml_libxml2StubsPtr->tclXML_libxml2_GetTclDocFromObj) /* 6 */
-#endif
-#ifndef TclXML_libxml2_GetTclDocFromNode
-#define TclXML_libxml2_GetTclDocFromNode \
-	(tclxml_libxml2StubsPtr->tclXML_libxml2_GetTclDocFromNode) /* 7 */
-#endif
-#ifndef TclXML_libxml2_DestroyDocument
-#define TclXML_libxml2_DestroyDocument \
-	(tclxml_libxml2StubsPtr->tclXML_libxml2_DestroyDocument) /* 8 */
-#endif
-#ifndef TclXML_libxml2_DocKeep
-#define TclXML_libxml2_DocKeep \
-	(tclxml_libxml2StubsPtr->tclXML_libxml2_DocKeep) /* 9 */
-#endif
-#ifndef TclXML_libxml2_ErrorHandler
-#define TclXML_libxml2_ErrorHandler \
-	(tclxml_libxml2StubsPtr->tclXML_libxml2_ErrorHandler) /* 10 */
-#endif
-#ifndef TclXML_libxml2_ResetError
-#define TclXML_libxml2_ResetError \
-	(tclxml_libxml2StubsPtr->tclXML_libxml2_ResetError) /* 11 */
-#endif
-#ifndef TclXML_libxml2_GetErrorObj
-#define TclXML_libxml2_GetErrorObj \
-	(tclxml_libxml2StubsPtr->tclXML_libxml2_GetErrorObj) /* 12 */
-#endif
-#ifndef TclXML_libxml2_SetErrorNodeFunc
-#define TclXML_libxml2_SetErrorNodeFunc \
-	(tclxml_libxml2StubsPtr->tclXML_libxml2_SetErrorNodeFunc) /* 13 */
-#endif
-
-#endif /* defined(USE_TCLXML_LIBXML2_STUBS) && !defined(USE_TCLXML_LIBXML2_STUB_PROCS) */
-
-/* !END!: Do not edit above this line. */
-
-#endif /* _TCLXMLLLIBXML2DECLS */
-
diff --git a/tclxml-3.2/include/tclxml/tclxml.h.in b/tclxml-3.2/include/tclxml/tclxml.h.in
deleted file mode 100755
index c809fdc..0000000
--- a/tclxml-3.2/include/tclxml/tclxml.h.in
+++ /dev/null
@@ -1,299 +0,0 @@
-/*
- * tclxml.h --
- *
- *	Generic interface to XML parsers.
- *
- * Copyright (c) 2005-2007 by Explain.
- * Copyright (c) 1999-2004 Steve Ball, Zveno Pty Ltd
- *
- * See the file "LICENSE" for information on usage and
- * redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
- *
- * $Id: tclxml.h.in,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
- *
- */
-
-#ifndef __TCLXML_H__
-#define __TCLXML_H__
-
-#ifdef TCLXML_BUILD_AS_FRAMEWORK
-#include <Tcl/tcl.h>
-#else
-#include <tcl.h>
-#endif /* TCLXML_BUILD_AS_FRAMEWORK */
-
-#define TCLXML_VERSION		"@PACKAGE_VERSION@"
-
-/*
- * Used to block the rest of this header file from resource compilers so
- * we can just get the version info.
- */
-#ifndef RC_INVOKED
-
-/* TIP 27 update. If CONST84 is not defined we are compiling against a
- * core before 8.4 and have to disable some CONST'ness.
- */
-
-#ifndef CONST84
-#   define CONST84
-#endif
-
-/*
- * Fix the Borland bug that's in the EXTERN macro from tcl.h.
- */
-#ifndef TCL_EXTERN
-#   undef DLLIMPORT
-#   undef DLLEXPORT
-#   if defined(STATIC_BUILD)
-#	define DLLIMPORT
-#	define DLLEXPORT
-#   elif (defined(__WIN32__) && (defined(_MSC_VER) || (__BORLANDC__ >= 0x0550) || (defined(__GNUC__) && defined(__declspec)))) || (defined(MAC_TCL) && FUNCTION_DECLSPEC)
-#	define DLLIMPORT __declspec(dllimport)
-#	define DLLEXPORT __declspec(dllexport)
-#   elif defined(__BORLANDC__)
-#	define OLDBORLAND 1
-#	define DLLIMPORT __import
-#	define DLLEXPORT __export
-#   else
-#	define DLLIMPORT
-#	define DLLEXPORT
-#   endif
-    /* Avoid name mangling from C++ compilers. */
-#   ifdef __cplusplus
-#	define TCL_EXTRNC extern "C"
-#   else
-#	define TCL_EXTRNC extern
-#   endif
-    /* Pre-5.5 Borland requires the attributes be placed after the */
-    /* return type. */
-#   ifdef OLDBORLAND
-#	define TCL_EXTERN(RTYPE) TCL_EXTRNC RTYPE TCL_STORAGE_CLASS
-#   else
-#	define TCL_EXTERN(RTYPE) TCL_EXTRNC TCL_STORAGE_CLASS RTYPE
-#   endif
-#endif
-
-
-
-/*
- * These macros are used to control whether functions are being declared for
- * import or export in Windows, 
- * They map to no-op declarations on non-Windows systems.
- * Assumes that tcl.h defines DLLEXPORT & DLLIMPORT correctly.
- * The default build on windows is for a DLL, which causes the DLLIMPORT
- * and DLLEXPORT macros to be nonempty. To build a static library, the
- * macro STATIC_BUILD should be defined before the inclusion of tcl.h
- *
- * If a function is being declared while it is being built
- * to be included in a shared library, then it should have the DLLEXPORT
- * storage class.  If is being declared for use by a module that is going to
- * link against the shared library, then it should have the DLLIMPORT storage
- * class.  If the symbol is beind declared for a static build or for use from a
- * stub library, then the storage class should be empty.
- *
- * The convention is that a macro called BUILD_xxxx, where xxxx is the
- * name of a library we are building, is set on the compile line for sources
- * that are to be placed in the library.  When this macro is set, the
- * storage class will be set to DLLEXPORT.  At the end of the header file, the
- * storage class will be reset to DLLIMPORt.
- */
-
-#undef TCL_STORAGE_CLASS
-#ifdef BUILD_Tclxml
-# define TCL_STORAGE_CLASS DLLEXPORT
-#else
-# ifdef USE_TCLXML_STUBS
-#  define TCL_STORAGE_CLASS
-# else
-#  define TCL_STORAGE_CLASS DLLIMPORT
-# endif
-#endif
-
-
-/*
- * C API for TclXML generic layer
- *
- * C callback functions to application code and their registration functions.
- * These all mimic the Tcl callbacks.
- */
-
-typedef int (TclXML_ElementStartProc) _ANSI_ARGS_((Tcl_Interp *interp, ClientData clientData, Tcl_Obj *namePtr, Tcl_Obj *nsuri, Tcl_Obj *attListPtr, Tcl_Obj *nsDeclsPtr));
-typedef int (TclXML_ElementEndProc) _ANSI_ARGS_((Tcl_Interp *interp, ClientData clientData, Tcl_Obj *namePtr));
-typedef int (TclXML_CharacterDataProc) _ANSI_ARGS_((Tcl_Interp *interp, ClientData clientData, Tcl_Obj *dataPtr));
-typedef int (TclXML_PIProc) _ANSI_ARGS_((Tcl_Interp *interp, ClientData clientData, Tcl_Obj *targetPtr, Tcl_Obj *dataPtr));
-typedef int (TclXML_DefaultProc) _ANSI_ARGS_((Tcl_Interp *interp, ClientData clientData, Tcl_Obj *dataPtr));
-typedef int (TclXML_UnparsedProc) _ANSI_ARGS_((Tcl_Interp *interp, ClientData clientData, Tcl_Obj *entityPtr, Tcl_Obj *basePtr, Tcl_Obj *systemIdPtr, Tcl_Obj *publicIdPtr, Tcl_Obj *notationNamePtr));
-typedef int (TclXML_NotationDeclProc) _ANSI_ARGS_((Tcl_Interp *interp, ClientData clientData, Tcl_Obj *namePtr, Tcl_Obj *basePtr, Tcl_Obj *systemIdPtr, Tcl_Obj *publicIdPtr));
-typedef int (TclXML_EntityProc) _ANSI_ARGS_((Tcl_Interp *interp, ClientData clientData, Tcl_Obj *namePtr, Tcl_Obj *basePtr, Tcl_Obj *systemIdPtr, Tcl_Obj *publicIdPtr));
-typedef int (TclXML_UnknownEncodingProc) _ANSI_ARGS_((Tcl_Interp *interp, ClientData clientData, Tcl_Obj *dataPtr, void *info));
-typedef int (TclXML_CommentProc) _ANSI_ARGS_((Tcl_Interp *interp, ClientData clientData, Tcl_Obj *dataPtr));
-typedef int (TclXML_NotStandaloneProc) _ANSI_ARGS_((Tcl_Interp *interp, ClientData clientData));
-typedef int (TclXML_ElementDeclProc) _ANSI_ARGS_((Tcl_Interp *interp, ClientData clientData, Tcl_Obj *namePtr, Tcl_Obj *contentspecPtr));
-typedef int (TclXML_AttlistDeclProc) _ANSI_ARGS_((Tcl_Interp *interp, ClientData clientData, Tcl_Obj *elementnamePtr, Tcl_Obj *attrdefnsPtr));
-typedef int (TclXML_StartDoctypeDeclProc) _ANSI_ARGS_((Tcl_Interp *interp, ClientData clientData, Tcl_Obj *namePtr));
-typedef int (TclXML_EndDoctypeDeclProc) _ANSI_ARGS_((Tcl_Interp *interp, ClientData clientData));
-
-/*
- * The structure below is used to refer to a parser object.
- */
-
-typedef struct TclXML_Info {
-    Tcl_Interp *interp;		/* Interpreter for this instance */
-    Tcl_Obj *name;		/* name of this instance */
-
-    Tcl_Obj *base;		/* base URI for document entity */
-
-	Tcl_Obj *encoding;   /* character encoding */
-
-    void *parserClass;		/* Parser-specific functions
-				 * Actually of type TclXML_ParserClassInfo
-				 */
-    ClientData clientData;	/* Parser-specific data structure */
-    
-    int final;			/* input data complete? */
-    int validate;		/* Validate document? */
-    
-    int status;			/* application status */
-    Tcl_Obj *result;		/* application return result */
-    
-    int continueCount;		/* reference count for continue */
-    Tcl_Obj *context;           /* reference to the context pointer */
-
-    Tcl_Obj *cdata;		/* Accumulates character data */
-    int nowhitespace;		/* Whether to ignore white space */
-    int reportempty;		/* Whether to report empty elements */
-    int expandinternalentities;	/* Whether to expand internal entities */
-    int paramentities;		/* Whether to include parameter entities */
-
-    Tcl_Obj *elementstartcommand;	/* Script for element start */
-    TclXML_ElementStartProc *elementstart;	/* Callback for element start */
-    ClientData elementstartdata;
-    Tcl_Obj *elementendcommand;	        /* Script for element end */
-    TclXML_ElementEndProc *elementend;	/* Callback for element end */
-    ClientData elementenddata;
-    Tcl_Obj *datacommand;	        /* Script for character data */
-    TclXML_CharacterDataProc *cdatacb;	/* Callback for character data */
-    ClientData cdatacbdata;
-    Tcl_Obj *picommand;		        /* Script for processing instruction */
-    TclXML_PIProc *pi;			/* Callback for processing instruction */
-    ClientData pidata;
-    Tcl_Obj *defaultcommand;	        /* Script for default data */
-    TclXML_DefaultProc *defaultcb;		/* Callback for default data */
-    ClientData defaultdata;
-    Tcl_Obj *unparsedcommand;		/* Script for unparsed entity declaration */
-    TclXML_UnparsedProc *unparsed;	/* Callback for unparsed entity declaraion */
-    ClientData unparseddata;
-    Tcl_Obj *notationcommand;		/* Script for notation declaration */
-    TclXML_NotationDeclProc *notation;	/* Callback for notation declaraion */
-    ClientData notationdata;
-    Tcl_Obj *entitycommand;		/* Script for external entity */
-    TclXML_EntityProc *entity;		/* Callback for external entity */
-    ClientData entitydata;
-    Tcl_Obj *unknownencodingcommand;	/* Script for unknown encoding */
-    TclXML_UnknownEncodingProc *unknownencoding;	/* Callback for unknown encoding */
-    ClientData unknownencodingdata;
-    /* Following added by ericm at scriptics */
-    Tcl_Obj *commentCommand;		/* Script for comments */
-    TclXML_CommentProc *comment;		/* Callback for comments */
-    ClientData commentdata;
-    Tcl_Obj *notStandaloneCommand;	/* Script for "not standalone" docs */
-    TclXML_NotStandaloneProc *notStandalone;	/* Callback for "not standalone" docs */
-    ClientData notstandalonedata;
-
-    Tcl_Obj *elementDeclCommand;	/* Script for <!ELEMENT decl's */
-    TclXML_ElementDeclProc *elementDecl;	/* Callback for element declaration */
-    ClientData elementdecldata;
-    Tcl_Obj *attlistDeclCommand;	/* Script for <!ATTLIST decl's */
-    TclXML_AttlistDeclProc *attlistDecl;	/* Callback for attribute list declaration */
-    ClientData attlistdecldata;
-
-  /* Do we really need these? */
-    Tcl_Obj *startDoctypeDeclCommand;	/* Script for <!DOCTYPE decl's */
-    TclXML_StartDoctypeDeclProc *startDoctypeDecl;	/* Callback for document type declaration start */
-    ClientData startdoctypedecldata;
-    Tcl_Obj *endDoctypeDeclCommand;    /* Script for <!DOCTYPE decl ends */
-    TclXML_EndDoctypeDeclProc *endDoctypeDecl;	/* Callback for document type declaration start */
-    ClientData enddoctypedecldata;
-
-} TclXML_Info;
-
-/*
- * These function definitions are provided by a parser
- * implementation and registered with this module.
- */
-
-typedef ClientData (TclXML_CreateProc) _ANSI_ARGS_((Tcl_Interp *interp, TclXML_Info *xmlinfo));
-typedef ClientData (TclXML_CreateEntityParserProc) _ANSI_ARGS_((Tcl_Interp *interp, ClientData clientData));
-typedef int (TclXML_ParseProc) _ANSI_ARGS_((ClientData clientData, char *buffer, int len, int final));
-typedef int (TclXML_ConfigureProc) _ANSI_ARGS_((ClientData clientData, Tcl_Obj *CONST optionPtr, Tcl_Obj *CONST valuePtr));
-typedef int (TclXML_GetProc) _ANSI_ARGS_((ClientData clientData, int objc, Tcl_Obj *CONST objv[]));
-typedef int (TclXML_ResetProc) _ANSI_ARGS_((ClientData clientData));
-typedef int (TclXML_DeleteProc) _ANSI_ARGS_((ClientData clientData));
-
-/*
- * The structure below is used store function pointers 
- * for a parser implementation.
- */
-
-typedef struct TclXML_ParserClassInfo {
-  Tcl_Obj *name;
-
-  TclXML_CreateProc *create;	/* Direct-call creation proc */
-  Tcl_Obj *createCmd;	/* Tcl command creation script */
-
-  TclXML_CreateEntityParserProc *createEntity;
-  Tcl_Obj *createEntityCmd;
-
-  TclXML_ParseProc *parse;
-  Tcl_Obj *parseCmd;
-
-  TclXML_ConfigureProc *configure;
-  Tcl_Obj *configureCmd;
-
-  TclXML_GetProc *get;
-  Tcl_Obj *getCmd;
-  
-  TclXML_ResetProc *reset;
-  Tcl_Obj *resetCmd;
-
-  TclXML_DeleteProc *destroy;
-  Tcl_Obj *destroyCmd;
-
-} TclXML_ParserClassInfo;
-
-/*
- *----------------------------------------------------------------------------
- *
- * Support for error handling
- *
- *----------------------------------------------------------------------------
- */
-
-typedef Tcl_Obj * (TclXML_ErrorNodeHandlerProc) _ANSI_ARGS_((Tcl_Interp *interp, ClientData clientData));
-
-typedef struct TclXML_ErrorInfo {
-  Tcl_Interp *interp;
-  Tcl_Obj *listPtr;
-  TclXML_ErrorNodeHandlerProc *nodeHandlerProc;
-} TclXML_ErrorInfo;
-
-/*
- *----------------------------------------------------------------------------
- *
- * Function prototypes for publically accessible routines
- *
- *----------------------------------------------------------------------------
- */
-
-#include <tclxml/tclxmlDecls.h>
-
-#ifdef USE_TCLXML_STUBS
-TCL_EXTRNC CONST char *
-    TclXML_InitStubs _ANSI_ARGS_((Tcl_Interp *interp, CONST char *version, int exact));
-#endif
-
-#undef TCL_STORAGE_CLASS
-#define TCL_STORAGE_CLASS DLLIMPORT
-
-#endif /* RC_INVOKED */
-#endif /* __TCLXML_H__ */
diff --git a/tclxml-3.2/include/tclxml/tclxmlDecls.h b/tclxml-3.2/include/tclxml/tclxmlDecls.h
deleted file mode 100644
index 9576479..0000000
--- a/tclxml-3.2/include/tclxml/tclxmlDecls.h
+++ /dev/null
@@ -1,361 +0,0 @@
-/*
- * tclxmlDecls.h --
- *
- *	Declarations of functions in the platform independent public TCLXML API.
- *
- */
-
-#ifndef _TCLXMLDECLS
-#define _TCLXMLDECLS
-
-/*
- * WARNING: The contents of this file is automatically generated by the
- * genStubs.tcl script. Any modifications to the function declarations
- * below should be made in the tclxml.decls script.
- */
-
-/* !BEGIN!: Do not edit below this line. */
-
-/*
- * Exported function declarations:
- */
-
-/* 0 */
-EXTERN int		Tclxml_Init _ANSI_ARGS_((Tcl_Interp * interp));
-/* 1 */
-EXTERN int		Tclxml_SafeInit _ANSI_ARGS_((Tcl_Interp * interp));
-/* 2 */
-EXTERN int		TclXML_RegisterXMLParser _ANSI_ARGS_((
-				Tcl_Interp * interp, 
-				TclXML_ParserClassInfo * parser));
-/* 3 */
-EXTERN int		TclXML_RegisterElementStartProc _ANSI_ARGS_((
-				Tcl_Interp * interp, TclXML_Info * parser, 
-				ClientData clientData, 
-				TclXML_ElementStartProc * callback));
-/* 4 */
-EXTERN int		TclXML_RegisterElementEndProc _ANSI_ARGS_((
-				Tcl_Interp * interp, TclXML_Info * parser, 
-				ClientData clientData, 
-				TclXML_ElementEndProc * callback));
-/* 5 */
-EXTERN int		TclXML_RegisterCharacterDataProc _ANSI_ARGS_((
-				Tcl_Interp * interp, TclXML_Info * parser, 
-				ClientData clientData, 
-				TclXML_CharacterDataProc * callback));
-/* 6 */
-EXTERN int		TclXML_RegisterPIProc _ANSI_ARGS_((
-				Tcl_Interp * interp, TclXML_Info * parser, 
-				ClientData clientData, 
-				TclXML_PIProc * callback));
-/* 7 */
-EXTERN int		TclXML_RegisterDefaultProc _ANSI_ARGS_((
-				Tcl_Interp * interp, TclXML_Info * parser, 
-				ClientData clientData, 
-				TclXML_DefaultProc * callback));
-/* 8 */
-EXTERN int		TclXML_RegisterUnparsedProc _ANSI_ARGS_((
-				Tcl_Interp * interp, TclXML_Info * parser, 
-				ClientData clientData, 
-				TclXML_UnparsedProc * callback));
-/* 9 */
-EXTERN int		TclXML_RegisterNotationDeclProc _ANSI_ARGS_((
-				Tcl_Interp * interp, TclXML_Info * parser, 
-				ClientData clientData, 
-				TclXML_NotationDeclProc * callback));
-/* 10 */
-EXTERN int		TclXML_RegisterEntityProc _ANSI_ARGS_((
-				Tcl_Interp * interp, TclXML_Info * parser, 
-				ClientData clientData, 
-				TclXML_EntityProc * callback));
-/* 11 */
-EXTERN int		TclXML_RegisterUnknownEncodingProc _ANSI_ARGS_((
-				Tcl_Interp * interp, TclXML_Info * parser, 
-				ClientData clientData, 
-				TclXML_UnknownEncodingProc * callback));
-/* 12 */
-EXTERN int		TclXML_RegisterCommentProc _ANSI_ARGS_((
-				Tcl_Interp * interp, TclXML_Info * parser, 
-				ClientData clientData, 
-				TclXML_CommentProc * callback));
-/* 13 */
-EXTERN int		TclXML_RegisterNotStandaloneProc _ANSI_ARGS_((
-				Tcl_Interp * interp, TclXML_Info * parser, 
-				ClientData clientData, 
-				TclXML_NotStandaloneProc * callback));
-/* 14 */
-EXTERN int		TclXML_RegisterElementDeclProc _ANSI_ARGS_((
-				Tcl_Interp * interp, TclXML_Info * parser, 
-				ClientData clientData, 
-				TclXML_ElementDeclProc * callback));
-/* 15 */
-EXTERN int		TclXML_RegisterAttListDeclProc _ANSI_ARGS_((
-				Tcl_Interp * interp, TclXML_Info * parser, 
-				ClientData clientData, 
-				TclXML_AttlistDeclProc * callback));
-/* 16 */
-EXTERN int		TclXML_RegisterStartDoctypeDeclProc _ANSI_ARGS_((
-				Tcl_Interp * interp, TclXML_Info * parser, 
-				ClientData clientData, 
-				TclXML_StartDoctypeDeclProc * callback));
-/* 17 */
-EXTERN int		TclXML_RegisterEndDoctypeDeclProc _ANSI_ARGS_((
-				Tcl_Interp * interp, TclXML_Info * parser, 
-				ClientData clientData, 
-				TclXML_EndDoctypeDeclProc * callback));
-/* 18 */
-EXTERN void		TclXML_ElementStartHandler _ANSI_ARGS_((
-				void * userdata, Tcl_Obj * name, 
-				Tcl_Obj * nsuri, Tcl_Obj * atts, 
-				Tcl_Obj * nsDeclsObj));
-/* 19 */
-EXTERN void		TclXML_ElementEndHandler _ANSI_ARGS_((
-				void * userData, Tcl_Obj * name));
-/* 20 */
-EXTERN void		TclXML_CharacterDataHandler _ANSI_ARGS_((
-				void * userData, Tcl_Obj * s));
-/* 21 */
-EXTERN void		TclXML_ProcessingInstructionHandler _ANSI_ARGS_((
-				void * userData, Tcl_Obj * target, 
-				Tcl_Obj * data));
-/* 22 */
-EXTERN int		TclXML_ExternalEntityRefHandler _ANSI_ARGS_((
-				ClientData clientData, 
-				Tcl_Obj * openEntityNames, Tcl_Obj * base, 
-				Tcl_Obj * systemId, Tcl_Obj * publicId));
-/* 23 */
-EXTERN void		TclXML_DefaultHandler _ANSI_ARGS_((void * userData, 
-				Tcl_Obj * s));
-/* 24 */
-EXTERN void		TclXML_UnparsedDeclHandler _ANSI_ARGS_((
-				void * userData, Tcl_Obj * entityname, 
-				Tcl_Obj * base, Tcl_Obj * systemId, 
-				Tcl_Obj * publicId, Tcl_Obj * notationName));
-/* 25 */
-EXTERN void		TclXML_NotationDeclHandler _ANSI_ARGS_((
-				void * userData, Tcl_Obj * notationName, 
-				Tcl_Obj * base, Tcl_Obj * systemId, 
-				Tcl_Obj * publicId));
-/* 26 */
-EXTERN int		TclXML_UnknownEncodingHandler _ANSI_ARGS_((
-				void * encodingHandlerData, Tcl_Obj * name, 
-				void * info));
-/* 27 */
-EXTERN void		TclXML_CommentHandler _ANSI_ARGS_((void * userData, 
-				Tcl_Obj * data));
-/* 28 */
-EXTERN int		TclXML_NotStandaloneHandler _ANSI_ARGS_((
-				void * userData));
-/* Slot 29 is reserved */
-/* Slot 30 is reserved */
-/* 31 */
-EXTERN void		TclXML_ElementDeclHandler _ANSI_ARGS_((
-				void * userData, Tcl_Obj * name, 
-				Tcl_Obj * contentspec));
-/* 32 */
-EXTERN void		TclXML_AttlistDeclHandler _ANSI_ARGS_((
-				void * userData, Tcl_Obj * name, 
-				Tcl_Obj * attributes));
-/* 33 */
-EXTERN void		TclXML_StartDoctypeDeclHandler _ANSI_ARGS_((
-				void * userData, Tcl_Obj * name));
-/* 34 */
-EXTERN void		TclXML_EndDoctypeDeclHandler _ANSI_ARGS_((
-				void * userData));
-
-typedef struct TclxmlStubs {
-    int magic;
-    struct TclxmlStubHooks *hooks;
-
-    int (*tclxml_Init) _ANSI_ARGS_((Tcl_Interp * interp)); /* 0 */
-    int (*tclxml_SafeInit) _ANSI_ARGS_((Tcl_Interp * interp)); /* 1 */
-    int (*tclXML_RegisterXMLParser) _ANSI_ARGS_((Tcl_Interp * interp, TclXML_ParserClassInfo * parser)); /* 2 */
-    int (*tclXML_RegisterElementStartProc) _ANSI_ARGS_((Tcl_Interp * interp, TclXML_Info * parser, ClientData clientData, TclXML_ElementStartProc * callback)); /* 3 */
-    int (*tclXML_RegisterElementEndProc) _ANSI_ARGS_((Tcl_Interp * interp, TclXML_Info * parser, ClientData clientData, TclXML_ElementEndProc * callback)); /* 4 */
-    int (*tclXML_RegisterCharacterDataProc) _ANSI_ARGS_((Tcl_Interp * interp, TclXML_Info * parser, ClientData clientData, TclXML_CharacterDataProc * callback)); /* 5 */
-    int (*tclXML_RegisterPIProc) _ANSI_ARGS_((Tcl_Interp * interp, TclXML_Info * parser, ClientData clientData, TclXML_PIProc * callback)); /* 6 */
-    int (*tclXML_RegisterDefaultProc) _ANSI_ARGS_((Tcl_Interp * interp, TclXML_Info * parser, ClientData clientData, TclXML_DefaultProc * callback)); /* 7 */
-    int (*tclXML_RegisterUnparsedProc) _ANSI_ARGS_((Tcl_Interp * interp, TclXML_Info * parser, ClientData clientData, TclXML_UnparsedProc * callback)); /* 8 */
-    int (*tclXML_RegisterNotationDeclProc) _ANSI_ARGS_((Tcl_Interp * interp, TclXML_Info * parser, ClientData clientData, TclXML_NotationDeclProc * callback)); /* 9 */
-    int (*tclXML_RegisterEntityProc) _ANSI_ARGS_((Tcl_Interp * interp, TclXML_Info * parser, ClientData clientData, TclXML_EntityProc * callback)); /* 10 */
-    int (*tclXML_RegisterUnknownEncodingProc) _ANSI_ARGS_((Tcl_Interp * interp, TclXML_Info * parser, ClientData clientData, TclXML_UnknownEncodingProc * callback)); /* 11 */
-    int (*tclXML_RegisterCommentProc) _ANSI_ARGS_((Tcl_Interp * interp, TclXML_Info * parser, ClientData clientData, TclXML_CommentProc * callback)); /* 12 */
-    int (*tclXML_RegisterNotStandaloneProc) _ANSI_ARGS_((Tcl_Interp * interp, TclXML_Info * parser, ClientData clientData, TclXML_NotStandaloneProc * callback)); /* 13 */
-    int (*tclXML_RegisterElementDeclProc) _ANSI_ARGS_((Tcl_Interp * interp, TclXML_Info * parser, ClientData clientData, TclXML_ElementDeclProc * callback)); /* 14 */
-    int (*tclXML_RegisterAttListDeclProc) _ANSI_ARGS_((Tcl_Interp * interp, TclXML_Info * parser, ClientData clientData, TclXML_AttlistDeclProc * callback)); /* 15 */
-    int (*tclXML_RegisterStartDoctypeDeclProc) _ANSI_ARGS_((Tcl_Interp * interp, TclXML_Info * parser, ClientData clientData, TclXML_StartDoctypeDeclProc * callback)); /* 16 */
-    int (*tclXML_RegisterEndDoctypeDeclProc) _ANSI_ARGS_((Tcl_Interp * interp, TclXML_Info * parser, ClientData clientData, TclXML_EndDoctypeDeclProc * callback)); /* 17 */
-    void (*tclXML_ElementStartHandler) _ANSI_ARGS_((void * userdata, Tcl_Obj * name, Tcl_Obj * nsuri, Tcl_Obj * atts, Tcl_Obj * nsDeclsObj)); /* 18 */
-    void (*tclXML_ElementEndHandler) _ANSI_ARGS_((void * userData, Tcl_Obj * name)); /* 19 */
-    void (*tclXML_CharacterDataHandler) _ANSI_ARGS_((void * userData, Tcl_Obj * s)); /* 20 */
-    void (*tclXML_ProcessingInstructionHandler) _ANSI_ARGS_((void * userData, Tcl_Obj * target, Tcl_Obj * data)); /* 21 */
-    int (*tclXML_ExternalEntityRefHandler) _ANSI_ARGS_((ClientData clientData, Tcl_Obj * openEntityNames, Tcl_Obj * base, Tcl_Obj * systemId, Tcl_Obj * publicId)); /* 22 */
-    void (*tclXML_DefaultHandler) _ANSI_ARGS_((void * userData, Tcl_Obj * s)); /* 23 */
-    void (*tclXML_UnparsedDeclHandler) _ANSI_ARGS_((void * userData, Tcl_Obj * entityname, Tcl_Obj * base, Tcl_Obj * systemId, Tcl_Obj * publicId, Tcl_Obj * notationName)); /* 24 */
-    void (*tclXML_NotationDeclHandler) _ANSI_ARGS_((void * userData, Tcl_Obj * notationName, Tcl_Obj * base, Tcl_Obj * systemId, Tcl_Obj * publicId)); /* 25 */
-    int (*tclXML_UnknownEncodingHandler) _ANSI_ARGS_((void * encodingHandlerData, Tcl_Obj * name, void * info)); /* 26 */
-    void (*tclXML_CommentHandler) _ANSI_ARGS_((void * userData, Tcl_Obj * data)); /* 27 */
-    int (*tclXML_NotStandaloneHandler) _ANSI_ARGS_((void * userData)); /* 28 */
-    void *reserved29;
-    void *reserved30;
-    void (*tclXML_ElementDeclHandler) _ANSI_ARGS_((void * userData, Tcl_Obj * name, Tcl_Obj * contentspec)); /* 31 */
-    void (*tclXML_AttlistDeclHandler) _ANSI_ARGS_((void * userData, Tcl_Obj * name, Tcl_Obj * attributes)); /* 32 */
-    void (*tclXML_StartDoctypeDeclHandler) _ANSI_ARGS_((void * userData, Tcl_Obj * name)); /* 33 */
-    void (*tclXML_EndDoctypeDeclHandler) _ANSI_ARGS_((void * userData)); /* 34 */
-} TclxmlStubs;
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-extern TclxmlStubs *tclxmlStubsPtr;
-#ifdef __cplusplus
-}
-#endif
-
-#if defined(USE_TCLXML_STUBS) && !defined(USE_TCLXML_STUB_PROCS)
-
-/*
- * Inline function declarations:
- */
-
-#ifndef Tclxml_Init
-#define Tclxml_Init \
-	(tclxmlStubsPtr->tclxml_Init) /* 0 */
-#endif
-#ifndef Tclxml_SafeInit
-#define Tclxml_SafeInit \
-	(tclxmlStubsPtr->tclxml_SafeInit) /* 1 */
-#endif
-#ifndef TclXML_RegisterXMLParser
-#define TclXML_RegisterXMLParser \
-	(tclxmlStubsPtr->tclXML_RegisterXMLParser) /* 2 */
-#endif
-#ifndef TclXML_RegisterElementStartProc
-#define TclXML_RegisterElementStartProc \
-	(tclxmlStubsPtr->tclXML_RegisterElementStartProc) /* 3 */
-#endif
-#ifndef TclXML_RegisterElementEndProc
-#define TclXML_RegisterElementEndProc \
-	(tclxmlStubsPtr->tclXML_RegisterElementEndProc) /* 4 */
-#endif
-#ifndef TclXML_RegisterCharacterDataProc
-#define TclXML_RegisterCharacterDataProc \
-	(tclxmlStubsPtr->tclXML_RegisterCharacterDataProc) /* 5 */
-#endif
-#ifndef TclXML_RegisterPIProc
-#define TclXML_RegisterPIProc \
-	(tclxmlStubsPtr->tclXML_RegisterPIProc) /* 6 */
-#endif
-#ifndef TclXML_RegisterDefaultProc
-#define TclXML_RegisterDefaultProc \
-	(tclxmlStubsPtr->tclXML_RegisterDefaultProc) /* 7 */
-#endif
-#ifndef TclXML_RegisterUnparsedProc
-#define TclXML_RegisterUnparsedProc \
-	(tclxmlStubsPtr->tclXML_RegisterUnparsedProc) /* 8 */
-#endif
-#ifndef TclXML_RegisterNotationDeclProc
-#define TclXML_RegisterNotationDeclProc \
-	(tclxmlStubsPtr->tclXML_RegisterNotationDeclProc) /* 9 */
-#endif
-#ifndef TclXML_RegisterEntityProc
-#define TclXML_RegisterEntityProc \
-	(tclxmlStubsPtr->tclXML_RegisterEntityProc) /* 10 */
-#endif
-#ifndef TclXML_RegisterUnknownEncodingProc
-#define TclXML_RegisterUnknownEncodingProc \
-	(tclxmlStubsPtr->tclXML_RegisterUnknownEncodingProc) /* 11 */
-#endif
-#ifndef TclXML_RegisterCommentProc
-#define TclXML_RegisterCommentProc \
-	(tclxmlStubsPtr->tclXML_RegisterCommentProc) /* 12 */
-#endif
-#ifndef TclXML_RegisterNotStandaloneProc
-#define TclXML_RegisterNotStandaloneProc \
-	(tclxmlStubsPtr->tclXML_RegisterNotStandaloneProc) /* 13 */
-#endif
-#ifndef TclXML_RegisterElementDeclProc
-#define TclXML_RegisterElementDeclProc \
-	(tclxmlStubsPtr->tclXML_RegisterElementDeclProc) /* 14 */
-#endif
-#ifndef TclXML_RegisterAttListDeclProc
-#define TclXML_RegisterAttListDeclProc \
-	(tclxmlStubsPtr->tclXML_RegisterAttListDeclProc) /* 15 */
-#endif
-#ifndef TclXML_RegisterStartDoctypeDeclProc
-#define TclXML_RegisterStartDoctypeDeclProc \
-	(tclxmlStubsPtr->tclXML_RegisterStartDoctypeDeclProc) /* 16 */
-#endif
-#ifndef TclXML_RegisterEndDoctypeDeclProc
-#define TclXML_RegisterEndDoctypeDeclProc \
-	(tclxmlStubsPtr->tclXML_RegisterEndDoctypeDeclProc) /* 17 */
-#endif
-#ifndef TclXML_ElementStartHandler
-#define TclXML_ElementStartHandler \
-	(tclxmlStubsPtr->tclXML_ElementStartHandler) /* 18 */
-#endif
-#ifndef TclXML_ElementEndHandler
-#define TclXML_ElementEndHandler \
-	(tclxmlStubsPtr->tclXML_ElementEndHandler) /* 19 */
-#endif
-#ifndef TclXML_CharacterDataHandler
-#define TclXML_CharacterDataHandler \
-	(tclxmlStubsPtr->tclXML_CharacterDataHandler) /* 20 */
-#endif
-#ifndef TclXML_ProcessingInstructionHandler
-#define TclXML_ProcessingInstructionHandler \
-	(tclxmlStubsPtr->tclXML_ProcessingInstructionHandler) /* 21 */
-#endif
-#ifndef TclXML_ExternalEntityRefHandler
-#define TclXML_ExternalEntityRefHandler \
-	(tclxmlStubsPtr->tclXML_ExternalEntityRefHandler) /* 22 */
-#endif
-#ifndef TclXML_DefaultHandler
-#define TclXML_DefaultHandler \
-	(tclxmlStubsPtr->tclXML_DefaultHandler) /* 23 */
-#endif
-#ifndef TclXML_UnparsedDeclHandler
-#define TclXML_UnparsedDeclHandler \
-	(tclxmlStubsPtr->tclXML_UnparsedDeclHandler) /* 24 */
-#endif
-#ifndef TclXML_NotationDeclHandler
-#define TclXML_NotationDeclHandler \
-	(tclxmlStubsPtr->tclXML_NotationDeclHandler) /* 25 */
-#endif
-#ifndef TclXML_UnknownEncodingHandler
-#define TclXML_UnknownEncodingHandler \
-	(tclxmlStubsPtr->tclXML_UnknownEncodingHandler) /* 26 */
-#endif
-#ifndef TclXML_CommentHandler
-#define TclXML_CommentHandler \
-	(tclxmlStubsPtr->tclXML_CommentHandler) /* 27 */
-#endif
-#ifndef TclXML_NotStandaloneHandler
-#define TclXML_NotStandaloneHandler \
-	(tclxmlStubsPtr->tclXML_NotStandaloneHandler) /* 28 */
-#endif
-/* Slot 29 is reserved */
-/* Slot 30 is reserved */
-#ifndef TclXML_ElementDeclHandler
-#define TclXML_ElementDeclHandler \
-	(tclxmlStubsPtr->tclXML_ElementDeclHandler) /* 31 */
-#endif
-#ifndef TclXML_AttlistDeclHandler
-#define TclXML_AttlistDeclHandler \
-	(tclxmlStubsPtr->tclXML_AttlistDeclHandler) /* 32 */
-#endif
-#ifndef TclXML_StartDoctypeDeclHandler
-#define TclXML_StartDoctypeDeclHandler \
-	(tclxmlStubsPtr->tclXML_StartDoctypeDeclHandler) /* 33 */
-#endif
-#ifndef TclXML_EndDoctypeDeclHandler
-#define TclXML_EndDoctypeDeclHandler \
-	(tclxmlStubsPtr->tclXML_EndDoctypeDeclHandler) /* 34 */
-#endif
-
-#endif /* defined(USE_TCLXML_STUBS) && !defined(USE_TCLXML_STUB_PROCS) */
-
-/* !END!: Do not edit above this line. */
-
-#endif /* _TCLXMLDECLS */
-
diff --git a/tclxml-3.2/include/tclxslt/tclxslt.h b/tclxml-3.2/include/tclxslt/tclxslt.h
deleted file mode 100644
index 428b375..0000000
--- a/tclxml-3.2/include/tclxslt/tclxslt.h
+++ /dev/null
@@ -1,98 +0,0 @@
-/* tclxslt.h --
- *
- *	Public interfaces to TclXSLT package.
- *
- * Copyright (c) 2005-2007 Explain
- * http://www.explain.com.au/
- * Copyright (c) 2001-2004 Zveno Pty Ltd
- * http://www.zveno.com/
- *
- * See the file "LICENSE" for information on usage and
- * redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
- *
- * $Id: tclxslt.h,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
- */
-
-#ifndef __TCLXSLT_H__
-#define __TCLXSLT_H__
-
-#ifdef TCLXML_BUILD_AS_FRAMEWORK
-#include <Tcl/tcl.h>
-#else
-#include <tcl.h>
-#endif /* TCLXML_BUILD_AS_FRAMEWORK */
-
-#include <tcldom-libxml2/tcldom-libxml2.h>
-#include <tclxml-libxml2/docObj.h>
-#include <libxml/xpath.h>
-#include <libxml/xpathInternals.h>
-#include <libxslt/xsltutils.h>
-#include <libxslt/transform.h>
-#include <libxslt/extensions.h>
-#include <libexslt/exsltconfig.h>
-#include <libexslt/exslt.h>
-
-/*
- * For C++ compilers, use extern "C"
- */
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/*
- * These macros are used to control whether functions are being declared for
- * import or export in Windows, 
- * They map to no-op declarations on non-Windows systems.
- * Assumes that tcl.h defines DLLEXPORT & DLLIMPORT correctly.
- * The default build on windows is for a DLL, which causes the DLLIMPORT
- * and DLLEXPORT macros to be nonempty. To build a static library, the
- * macro STATIC_BUILD should be defined before the inclusion of tcl.h
- *
- * If a function is being declared while it is being built
- * to be included in a shared library, then it should have the DLLEXPORT
- * storage class.  If is being declared for use by a module that is going to
- * link against the shared library, then it should have the DLLIMPORT storage
- * class.  If the symbol is beind declared for a static build or for use from a
- * stub library, then the storage class should be empty.
- *
- * The convention is that a macro called BUILD_xxxx, where xxxx is the
- * name of a library we are building, is set on the compile line for sources
- * that are to be placed in the library.  When this macro is set, the
- * storage class will be set to DLLEXPORT.  At the end of the header file, the
- * storage class will be reset to DLLIMPORt.
- */
-
-#undef TCL_STORAGE_CLASS
-#ifdef BUILD_Tclxslt
-# define TCL_STORAGE_CLASS DLLEXPORT
-#else
-# ifdef USE_TCL_STUBS
-#  define TCL_STORAGE_CLASS
-# else
-#  define TCL_STORAGE_CLASS DLLIMPORT
-# endif
-#endif
-
-/*
- * Declarations for externally visible functions.
- */
-
-EXTERN int      Tclxslt_libxslt_Init _ANSI_ARGS_((Tcl_Interp *interp));
-EXTERN int      Tclxslt_libxslt_SafeInit _ANSI_ARGS_((Tcl_Interp *interp));
-
-/*
- * Class creation command for XSLT compiled stylesheet objects.
- */
-
-EXTERN Tcl_ObjCmdProc TclXSLTCompileStylesheet;
-
-
-#undef TCL_STORAGE_CLASS
-#define TCL_STORAGE_CLASS DLLIMPORT
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif /* __TCLXSLT_H__ */
diff --git a/tclxml-3.2/macosx/Info-expat__Upgraded_.plist b/tclxml-3.2/macosx/Info-expat__Upgraded_.plist
deleted file mode 100644
index 9386ade..0000000
--- a/tclxml-3.2/macosx/Info-expat__Upgraded_.plist
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
-<plist version="1.0">
-<dict>
-	<key>CFBundleDevelopmentRegion</key>
-	<string>English</string>
-	<key>CFBundleExecutable</key>
-	<string></string>
-	<key>CFBundleGetInfoString</key>
-	<string>TclXML/expat v3.0</string>
-	<key>CFBundleIconFile</key>
-	<string></string>
-	<key>CFBundleIdentifier</key>
-	<string>com.zveno.tclxml.expat</string>
-	<key>CFBundleInfoDictionaryVersion</key>
-	<string>6.0</string>
-	<key>CFBundleName</key>
-	<string>TclXML expat</string>
-	<key>CFBundlePackageType</key>
-	<string>FMWK</string>
-	<key>CFBundleShortVersionString</key>
-	<string>3.0</string>
-	<key>CFBundleSignature</key>
-	<string>????</string>
-	<key>CFBundleVersion</key>
-	<string>3.0</string>
-</dict>
-</plist>
diff --git a/tclxml-3.2/macosx/Info-tclxml__Upgraded_.plist b/tclxml-3.2/macosx/Info-tclxml__Upgraded_.plist
deleted file mode 100644
index 7dd63da..0000000
--- a/tclxml-3.2/macosx/Info-tclxml__Upgraded_.plist
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
-<plist version="1.0">
-<dict>
-	<key>CFBundleDevelopmentRegion</key>
-	<string>English</string>
-	<key>CFBundleExecutable</key>
-	<string></string>
-	<key>CFBundleGetInfoString</key>
-	<string>TclXML v3.0</string>
-	<key>CFBundleIconFile</key>
-	<string></string>
-	<key>CFBundleIdentifier</key>
-	<string>com.zveno.tclxml</string>
-	<key>CFBundleInfoDictionaryVersion</key>
-	<string>6.0</string>
-	<key>CFBundleName</key>
-	<string>TclXML</string>
-	<key>CFBundlePackageType</key>
-	<string>FMWK</string>
-	<key>CFBundleShortVersionString</key>
-	<string>3.0</string>
-	<key>CFBundleSignature</key>
-	<string>????</string>
-	<key>CFBundleVersion</key>
-	<string>3.1</string>
-</dict>
-</plist>
diff --git a/tclxml-3.2/macosx/Info-tclxml_libxml2__Upgraded_.plist b/tclxml-3.2/macosx/Info-tclxml_libxml2__Upgraded_.plist
deleted file mode 100644
index 13c2c80..0000000
--- a/tclxml-3.2/macosx/Info-tclxml_libxml2__Upgraded_.plist
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
-<plist version="1.0">
-<dict>
-	<key>CFBundleDevelopmentRegion</key>
-	<string>English</string>
-	<key>CFBundleExecutable</key>
-	<string>tclxml-libxml2</string>
-	<key>CFBundleGetInfoString</key>
-	<string>TclXML/libxml2 v3.0</string>
-	<key>CFBundleIconFile</key>
-	<string></string>
-	<key>CFBundleIdentifier</key>
-	<string>com.zveno.tclxml.libxml2</string>
-	<key>CFBundleInfoDictionaryVersion</key>
-	<string>6.0</string>
-	<key>CFBundleName</key>
-	<string>TclXML libxml2</string>
-	<key>CFBundlePackageType</key>
-	<string>FMWK</string>
-	<key>CFBundleShortVersionString</key>
-	<string>v3.0</string>
-	<key>CFBundleSignature</key>
-	<string>????</string>
-	<key>CFBundleVersion</key>
-	<string>3.0</string>
-</dict>
-</plist>
diff --git a/tclxml-3.2/macosx/Tclxml-Info.plist b/tclxml-3.2/macosx/Tclxml-Info.plist
deleted file mode 100644
index 936aec4..0000000
--- a/tclxml-3.2/macosx/Tclxml-Info.plist
+++ /dev/null
@@ -1,20 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
-<plist version="1.0">
-<dict>
-	<key>CFBundleDevelopmentRegion</key>
-	<string>English</string>
-	<key>CFBundleExecutable</key>
-	<string>${EXECUTABLE_NAME}</string>
-	<key>CFBundleIdentifier</key>
-	<string>net.sourceforge.tclxml</string>
-	<key>CFBundleInfoDictionaryVersion</key>
-	<string>6.0</string>
-	<key>CFBundlePackageType</key>
-	<string>FMWK</string>
-	<key>CFBundleSignature</key>
-	<string>????</string>
-	<key>CFBundleVersion</key>
-	<string>${PACKAGE_VERSION}</string>
-</dict>
-</plist>
diff --git a/tclxml-3.2/macosx/Tclxml.xcodeproj/project.pbxproj b/tclxml-3.2/macosx/Tclxml.xcodeproj/project.pbxproj
deleted file mode 100644
index 05a5efe..0000000
--- a/tclxml-3.2/macosx/Tclxml.xcodeproj/project.pbxproj
+++ /dev/null
@@ -1,675 +0,0 @@
-// !$*UTF8*$!
-{
-	archiveVersion = 1;
-	classes = {
-	};
-	objectVersion = 42;
-	objects = {
-
-/* Begin PBXAggregateTarget section */
-		AA68C6640C90EA8700D12438 /* configure */ = {
-			isa = PBXAggregateTarget;
-			buildConfigurationList = AA68C6670C90EAB000D12438 /* Build configuration list for PBXAggregateTarget "configure" */;
-			buildPhases = (
-				AA68C6630C90EA8700D12438 /* ShellScript */,
-			);
-			dependencies = (
-			);
-			name = configure;
-			productName = configure;
-		};
-/* End PBXAggregateTarget section */
-
-/* Begin PBXBuildFile section */
-		AA13408D0CACF8FA006C8E84 /* pkgIndex.tcl in Resources */ = {isa = PBXBuildFile; fileRef = AA13408C0CACF8FA006C8E84 /* pkgIndex.tcl */; };
-		AA1340B30CB49786006C8E84 /* tclxslt.tcl in Resources */ = {isa = PBXBuildFile; fileRef = AA1340B20CB49786006C8E84 /* tclxslt.tcl */; };
-		AA68C5CA0C90302900D12438 /* libxml.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = AA68C5C90C90302900D12438 /* libxml.framework */; };
-		AA68C5CD0C90304400D12438 /* libxslt.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = AA68C5CC0C90304400D12438 /* libxslt.framework */; };
-		AA68C5D00C90305E00D12438 /* libexslt.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = AA68C5CF0C90305E00D12438 /* libexslt.framework */; };
-		AA68C5D30C9031C400D12438 /* tclxml.c in Sources */ = {isa = PBXBuildFile; fileRef = AA68C5D20C9031C400D12438 /* tclxml.c */; };
-		AA68C5D50C9031EA00D12438 /* tclxml.h in Headers */ = {isa = PBXBuildFile; fileRef = AA68C5D40C9031EA00D12438 /* tclxml.h */; settings = {ATTRIBUTES = (Public, ); }; };
-		AA68C5E60C9032E400D12438 /* sgml-8.0.tcl in Resources */ = {isa = PBXBuildFile; fileRef = AA68C5DC0C9032E400D12438 /* sgml-8.0.tcl */; };
-		AA68C5E70C9032E400D12438 /* sgml-8.1.tcl in Resources */ = {isa = PBXBuildFile; fileRef = AA68C5DD0C9032E400D12438 /* sgml-8.1.tcl */; };
-		AA68C5E80C9032E400D12438 /* sgmlparser.tcl in Resources */ = {isa = PBXBuildFile; fileRef = AA68C5DE0C9032E400D12438 /* sgmlparser.tcl */; };
-		AA68C5E90C9032E400D12438 /* tclparser-8.0.tcl in Resources */ = {isa = PBXBuildFile; fileRef = AA68C5DF0C9032E400D12438 /* tclparser-8.0.tcl */; };
-		AA68C5EA0C9032E400D12438 /* tclparser-8.1.tcl in Resources */ = {isa = PBXBuildFile; fileRef = AA68C5E00C9032E400D12438 /* tclparser-8.1.tcl */; };
-		AA68C5EB0C9032E400D12438 /* xml__tcl.tcl in Resources */ = {isa = PBXBuildFile; fileRef = AA68C5E10C9032E400D12438 /* xml__tcl.tcl */; };
-		AA68C5EC0C9032E400D12438 /* xml-8.0.tcl in Resources */ = {isa = PBXBuildFile; fileRef = AA68C5E20C9032E400D12438 /* xml-8.0.tcl */; };
-		AA68C5ED0C9032E400D12438 /* xml-8.1.tcl in Resources */ = {isa = PBXBuildFile; fileRef = AA68C5E30C9032E400D12438 /* xml-8.1.tcl */; };
-		AA68C5EE0C9032E400D12438 /* xmldep.tcl in Resources */ = {isa = PBXBuildFile; fileRef = AA68C5E40C9032E400D12438 /* xmldep.tcl */; };
-		AA68C5EF0C9032E400D12438 /* xpath.tcl in Resources */ = {isa = PBXBuildFile; fileRef = AA68C5E50C9032E400D12438 /* xpath.tcl */; };
-		AA68C5F10C90331D00D12438 /* tclxml-libxml2.c in Sources */ = {isa = PBXBuildFile; fileRef = AA68C5F00C90331D00D12438 /* tclxml-libxml2.c */; };
-		AA68C5F30C90332A00D12438 /* docObj.c in Sources */ = {isa = PBXBuildFile; fileRef = AA68C5F20C90332A00D12438 /* docObj.c */; };
-		AA68C5F50C90333E00D12438 /* docObj.h in Headers */ = {isa = PBXBuildFile; fileRef = AA68C5F40C90333E00D12438 /* docObj.h */; settings = {ATTRIBUTES = (Public, ); }; };
-		AA68C5F70C90334D00D12438 /* tclxml-libxml2.h in Headers */ = {isa = PBXBuildFile; fileRef = AA68C5F60C90334D00D12438 /* tclxml-libxml2.h */; settings = {ATTRIBUTES = (Public, ); }; };
-		AA68C5F90C90336200D12438 /* tcldom.h in Headers */ = {isa = PBXBuildFile; fileRef = AA68C5F80C90336200D12438 /* tcldom.h */; settings = {ATTRIBUTES = (Public, ); }; };
-		AA68C5FB0C90337C00D12438 /* tcldom-libxml2.c in Sources */ = {isa = PBXBuildFile; fileRef = AA68C5FA0C90337C00D12438 /* tcldom-libxml2.c */; };
-		AA68C5FD0C90338B00D12438 /* nodeObj.c in Sources */ = {isa = PBXBuildFile; fileRef = AA68C5FC0C90338B00D12438 /* nodeObj.c */; };
-		AA68C6000C90339C00D12438 /* nodeObj.h in Headers */ = {isa = PBXBuildFile; fileRef = AA68C5FE0C90339C00D12438 /* nodeObj.h */; settings = {ATTRIBUTES = (Public, ); }; };
-		AA68C6010C90339C00D12438 /* tcldom-libxml2.h in Headers */ = {isa = PBXBuildFile; fileRef = AA68C5FF0C90339C00D12438 /* tcldom-libxml2.h */; settings = {ATTRIBUTES = (Public, ); }; };
-		AA68C6030C9033AC00D12438 /* tcldom-libxml2.tcl in Resources */ = {isa = PBXBuildFile; fileRef = AA68C6020C9033AC00D12438 /* tcldom-libxml2.tcl */; };
-		AA68C6050C9033C900D12438 /* tclxslt.h in Headers */ = {isa = PBXBuildFile; fileRef = AA68C6040C9033C900D12438 /* tclxslt.h */; settings = {ATTRIBUTES = (Public, ); }; };
-		AA68C6070C9033E300D12438 /* tclxslt-libxslt.c in Sources */ = {isa = PBXBuildFile; fileRef = AA68C6060C9033E300D12438 /* tclxslt-libxslt.c */; };
-		AA68C6090C9033F300D12438 /* tclxslt-libxslt.tcl in Resources */ = {isa = PBXBuildFile; fileRef = AA68C6080C9033F300D12438 /* tclxslt-libxslt.tcl */; };
-		AA68C60E0C90340D00D12438 /* process.tcl in Resources */ = {isa = PBXBuildFile; fileRef = AA68C60A0C90340D00D12438 /* process.tcl */; };
-		AA68C60F0C90340D00D12438 /* resources.tcl in Resources */ = {isa = PBXBuildFile; fileRef = AA68C60B0C90340D00D12438 /* resources.tcl */; };
-		AA68C6100C90340D00D12438 /* utilities.tcl in Resources */ = {isa = PBXBuildFile; fileRef = AA68C60C0C90340D00D12438 /* utilities.tcl */; };
-		AA68C6110C90340D00D12438 /* xsltcache.tcl in Resources */ = {isa = PBXBuildFile; fileRef = AA68C60D0C90340D00D12438 /* xsltcache.tcl */; };
-		AA68C6F60C91035400D12438 /* Tclxml-Info.plist in Resources */ = {isa = PBXBuildFile; fileRef = AA68C6F50C91035400D12438 /* Tclxml-Info.plist */; };
-		AAE9DF4E0DBFE1EB00A29434 /* Tcl.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = AAE9DF4D0DBFE1EB00A29434 /* Tcl.framework */; };
-/* End PBXBuildFile section */
-
-/* Begin PBXContainerItemProxy section */
-		AA68C6650C90EA9200D12438 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = 0867D690FE84028FC02AAC07 /* Project object */;
-			proxyType = 1;
-			remoteGlobalIDString = AA68C6640C90EA8700D12438;
-			remoteInfo = configure;
-		};
-/* End PBXContainerItemProxy section */
-
-/* Begin PBXFileReference section */
-		8DC2EF5B0486A6940098B216 /* Tclxml.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Tclxml.framework; sourceTree = BUILT_PRODUCTS_DIR; };
-		AA13408C0CACF8FA006C8E84 /* pkgIndex.tcl */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; name = pkgIndex.tcl; path = ../pkgIndex.tcl; sourceTree = SOURCE_ROOT; };
-		AA1340B20CB49786006C8E84 /* tclxslt.tcl */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; name = tclxslt.tcl; path = ../tclxslt/tclxslt.tcl; sourceTree = SOURCE_ROOT; };
-		AA68C5C90C90302900D12438 /* libxml.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = libxml.framework; path = ../Release/libxml.framework; sourceTree = BUILT_PRODUCTS_DIR; };
-		AA68C5CC0C90304400D12438 /* libxslt.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = libxslt.framework; path = ../Release/libxslt.framework; sourceTree = BUILT_PRODUCTS_DIR; };
-		AA68C5CF0C90305E00D12438 /* libexslt.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = libexslt.framework; path = ../Release/libexslt.framework; sourceTree = BUILT_PRODUCTS_DIR; };
-		AA68C5D20C9031C400D12438 /* tclxml.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = tclxml.c; path = ../tclxml.c; sourceTree = SOURCE_ROOT; };
-		AA68C5D40C9031EA00D12438 /* tclxml.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = tclxml.h; path = ../include/tclxml/tclxml.h; sourceTree = SOURCE_ROOT; };
-		AA68C5DC0C9032E400D12438 /* sgml-8.0.tcl */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; name = "sgml-8.0.tcl"; path = "../tclxml-tcl/sgml-8.0.tcl"; sourceTree = SOURCE_ROOT; };
-		AA68C5DD0C9032E400D12438 /* sgml-8.1.tcl */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; name = "sgml-8.1.tcl"; path = "../tclxml-tcl/sgml-8.1.tcl"; sourceTree = SOURCE_ROOT; };
-		AA68C5DE0C9032E400D12438 /* sgmlparser.tcl */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; name = sgmlparser.tcl; path = "../tclxml-tcl/sgmlparser.tcl"; sourceTree = SOURCE_ROOT; };
-		AA68C5DF0C9032E400D12438 /* tclparser-8.0.tcl */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; name = "tclparser-8.0.tcl"; path = "../tclxml-tcl/tclparser-8.0.tcl"; sourceTree = SOURCE_ROOT; };
-		AA68C5E00C9032E400D12438 /* tclparser-8.1.tcl */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; name = "tclparser-8.1.tcl"; path = "../tclxml-tcl/tclparser-8.1.tcl"; sourceTree = SOURCE_ROOT; };
-		AA68C5E10C9032E400D12438 /* xml__tcl.tcl */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; name = xml__tcl.tcl; path = "../tclxml-tcl/xml__tcl.tcl"; sourceTree = SOURCE_ROOT; };
-		AA68C5E20C9032E400D12438 /* xml-8.0.tcl */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; name = "xml-8.0.tcl"; path = "../tclxml-tcl/xml-8.0.tcl"; sourceTree = SOURCE_ROOT; };
-		AA68C5E30C9032E400D12438 /* xml-8.1.tcl */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; name = "xml-8.1.tcl"; path = "../tclxml-tcl/xml-8.1.tcl"; sourceTree = SOURCE_ROOT; };
-		AA68C5E40C9032E400D12438 /* xmldep.tcl */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; name = xmldep.tcl; path = "../tclxml-tcl/xmldep.tcl"; sourceTree = SOURCE_ROOT; };
-		AA68C5E50C9032E400D12438 /* xpath.tcl */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; name = xpath.tcl; path = "../tclxml-tcl/xpath.tcl"; sourceTree = SOURCE_ROOT; };
-		AA68C5F00C90331D00D12438 /* tclxml-libxml2.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = "tclxml-libxml2.c"; path = "../tclxml-libxml2.c"; sourceTree = SOURCE_ROOT; };
-		AA68C5F20C90332A00D12438 /* docObj.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = docObj.c; path = ../docObj.c; sourceTree = SOURCE_ROOT; };
-		AA68C5F40C90333E00D12438 /* docObj.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = docObj.h; path = "../include/tclxml-libxml2/docObj.h"; sourceTree = SOURCE_ROOT; };
-		AA68C5F60C90334D00D12438 /* tclxml-libxml2.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = "tclxml-libxml2.h"; path = "../include/tclxml-libxml2/tclxml-libxml2.h"; sourceTree = SOURCE_ROOT; };
-		AA68C5F80C90336200D12438 /* tcldom.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = tcldom.h; path = ../include/tcldom/tcldom.h; sourceTree = SOURCE_ROOT; };
-		AA68C5FA0C90337C00D12438 /* tcldom-libxml2.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = "tcldom-libxml2.c"; path = "../tcldom-libxml2.c"; sourceTree = SOURCE_ROOT; };
-		AA68C5FC0C90338B00D12438 /* nodeObj.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = nodeObj.c; path = ../nodeObj.c; sourceTree = SOURCE_ROOT; };
-		AA68C5FE0C90339C00D12438 /* nodeObj.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = nodeObj.h; path = "../include/tcldom-libxml2/nodeObj.h"; sourceTree = SOURCE_ROOT; };
-		AA68C5FF0C90339C00D12438 /* tcldom-libxml2.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = "tcldom-libxml2.h"; path = "../include/tcldom-libxml2/tcldom-libxml2.h"; sourceTree = SOURCE_ROOT; };
-		AA68C6020C9033AC00D12438 /* tcldom-libxml2.tcl */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; name = "tcldom-libxml2.tcl"; path = "../tcldom-libxml2.tcl"; sourceTree = SOURCE_ROOT; };
-		AA68C6040C9033C900D12438 /* tclxslt.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = tclxslt.h; path = ../include/tclxslt/tclxslt.h; sourceTree = SOURCE_ROOT; };
-		AA68C6060C9033E300D12438 /* tclxslt-libxslt.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = "tclxslt-libxslt.c"; path = "../tclxslt-libxslt.c"; sourceTree = SOURCE_ROOT; };
-		AA68C6080C9033F300D12438 /* tclxslt-libxslt.tcl */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; name = "tclxslt-libxslt.tcl"; path = "../tclxslt-libxslt.tcl"; sourceTree = SOURCE_ROOT; };
-		AA68C60A0C90340D00D12438 /* process.tcl */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; name = process.tcl; path = ../tclxslt/process.tcl; sourceTree = SOURCE_ROOT; };
-		AA68C60B0C90340D00D12438 /* resources.tcl */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; name = resources.tcl; path = ../tclxslt/resources.tcl; sourceTree = SOURCE_ROOT; };
-		AA68C60C0C90340D00D12438 /* utilities.tcl */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; name = utilities.tcl; path = ../tclxslt/utilities.tcl; sourceTree = SOURCE_ROOT; };
-		AA68C60D0C90340D00D12438 /* xsltcache.tcl */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; name = xsltcache.tcl; path = ../tclxslt/xsltcache.tcl; sourceTree = SOURCE_ROOT; };
-		AA68C6F50C91035400D12438 /* Tclxml-Info.plist */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text.xml; path = "Tclxml-Info.plist"; sourceTree = SOURCE_ROOT; };
-		AAE9DF4D0DBFE1EB00A29434 /* Tcl.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Tcl.framework; path = ../../../Library/Frameworks/Tcl.framework; sourceTree = SOURCE_ROOT; };
-/* End PBXFileReference section */
-
-/* Begin PBXFrameworksBuildPhase section */
-		8DC2EF560486A6940098B216 /* Frameworks */ = {
-			isa = PBXFrameworksBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				AA68C5CA0C90302900D12438 /* libxml.framework in Frameworks */,
-				AA68C5CD0C90304400D12438 /* libxslt.framework in Frameworks */,
-				AA68C5D00C90305E00D12438 /* libexslt.framework in Frameworks */,
-				AAE9DF4E0DBFE1EB00A29434 /* Tcl.framework in Frameworks */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXFrameworksBuildPhase section */
-
-/* Begin PBXGroup section */
-		034768DFFF38A50411DB9C8B /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				AA68C6F50C91035400D12438 /* Tclxml-Info.plist */,
-				8DC2EF5B0486A6940098B216 /* Tclxml.framework */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		0867D691FE84028FC02AAC07 /* Tclxml */ = {
-			isa = PBXGroup;
-			children = (
-				AA68C57F0C902A1700D12438 /* TclXML */,
-				AA68C58B0C902A4800D12438 /* TclXML-tcl */,
-				AA68C5880C902A3C00D12438 /* TclXML-libxml2 */,
-				AA68C5820C902A2000D12438 /* TclDOM */,
-				AA68C58E0C902A5500D12438 /* TclDOM-libxml2 */,
-				AA68C5850C902A2700D12438 /* TclXSLT */,
-				AA68C5920C902A6C00D12438 /* TclXSLT-libxslt */,
-				0867D69AFE84028FC02AAC07 /* External Frameworks and Libraries */,
-				034768DFFF38A50411DB9C8B /* Products */,
-			);
-			name = Tclxml;
-			sourceTree = "<group>";
-		};
-		0867D69AFE84028FC02AAC07 /* External Frameworks and Libraries */ = {
-			isa = PBXGroup;
-			children = (
-				1058C7B0FEA5585E11CA2CBB /* Linked Frameworks */,
-			);
-			name = "External Frameworks and Libraries";
-			sourceTree = "<group>";
-		};
-		1058C7B0FEA5585E11CA2CBB /* Linked Frameworks */ = {
-			isa = PBXGroup;
-			children = (
-				AAE9DF4D0DBFE1EB00A29434 /* Tcl.framework */,
-				AA68C5CF0C90305E00D12438 /* libexslt.framework */,
-				AA68C5CC0C90304400D12438 /* libxslt.framework */,
-				AA68C5C90C90302900D12438 /* libxml.framework */,
-			);
-			name = "Linked Frameworks";
-			sourceTree = "<group>";
-		};
-		AA68C57F0C902A1700D12438 /* TclXML */ = {
-			isa = PBXGroup;
-			children = (
-				AA68C5950C902D0A00D12438 /* Sources */,
-				AA68C5980C902D1300D12438 /* Headers */,
-				AA68C59B0C902D2D00D12438 /* Scripts */,
-			);
-			name = TclXML;
-			sourceTree = "<group>";
-		};
-		AA68C5820C902A2000D12438 /* TclDOM */ = {
-			isa = PBXGroup;
-			children = (
-				AA68C5B00C902F0200D12438 /* Headers */,
-				AA68C5AD0C902EF800D12438 /* Scripts */,
-			);
-			name = TclDOM;
-			sourceTree = "<group>";
-		};
-		AA68C5850C902A2700D12438 /* TclXSLT */ = {
-			isa = PBXGroup;
-			children = (
-				AA68C5BF0C902F3600D12438 /* Headers */,
-				AA68C5BC0C902F2D00D12438 /* Scripts */,
-			);
-			name = TclXSLT;
-			sourceTree = "<group>";
-		};
-		AA68C5880C902A3C00D12438 /* TclXML-libxml2 */ = {
-			isa = PBXGroup;
-			children = (
-				AA68C5A70C902D8C00D12438 /* Sources */,
-				AA68C5A40C902D8400D12438 /* Headers */,
-				AA68C5A10C902D7D00D12438 /* Scripts */,
-			);
-			name = "TclXML-libxml2";
-			sourceTree = "<group>";
-		};
-		AA68C58B0C902A4800D12438 /* TclXML-tcl */ = {
-			isa = PBXGroup;
-			children = (
-				AA68C59E0C902D3800D12438 /* Scripts */,
-			);
-			name = "TclXML-tcl";
-			sourceTree = "<group>";
-		};
-		AA68C58E0C902A5500D12438 /* TclDOM-libxml2 */ = {
-			isa = PBXGroup;
-			children = (
-				AA68C5B90C902F1D00D12438 /* Sources */,
-				AA68C5B60C902F1500D12438 /* Headers */,
-				AA68C5B30C902F0E00D12438 /* Scripts */,
-			);
-			name = "TclDOM-libxml2";
-			sourceTree = "<group>";
-		};
-		AA68C5920C902A6C00D12438 /* TclXSLT-libxslt */ = {
-			isa = PBXGroup;
-			children = (
-				AA68C5C80C902F5400D12438 /* Sources */,
-				AA68C5C50C902F4900D12438 /* Headers */,
-				AA68C5C20C902F4100D12438 /* Scripts */,
-			);
-			name = "TclXSLT-libxslt";
-			sourceTree = "<group>";
-		};
-		AA68C5950C902D0A00D12438 /* Sources */ = {
-			isa = PBXGroup;
-			children = (
-				AA68C5D20C9031C400D12438 /* tclxml.c */,
-			);
-			name = Sources;
-			sourceTree = "<group>";
-		};
-		AA68C5980C902D1300D12438 /* Headers */ = {
-			isa = PBXGroup;
-			children = (
-				AA68C5D40C9031EA00D12438 /* tclxml.h */,
-			);
-			name = Headers;
-			sourceTree = "<group>";
-		};
-		AA68C59B0C902D2D00D12438 /* Scripts */ = {
-			isa = PBXGroup;
-			children = (
-				AA13408C0CACF8FA006C8E84 /* pkgIndex.tcl */,
-			);
-			name = Scripts;
-			sourceTree = "<group>";
-		};
-		AA68C59E0C902D3800D12438 /* Scripts */ = {
-			isa = PBXGroup;
-			children = (
-				AA68C5DC0C9032E400D12438 /* sgml-8.0.tcl */,
-				AA68C5DD0C9032E400D12438 /* sgml-8.1.tcl */,
-				AA68C5DE0C9032E400D12438 /* sgmlparser.tcl */,
-				AA68C5DF0C9032E400D12438 /* tclparser-8.0.tcl */,
-				AA68C5E00C9032E400D12438 /* tclparser-8.1.tcl */,
-				AA68C5E10C9032E400D12438 /* xml__tcl.tcl */,
-				AA68C5E20C9032E400D12438 /* xml-8.0.tcl */,
-				AA68C5E30C9032E400D12438 /* xml-8.1.tcl */,
-				AA68C5E40C9032E400D12438 /* xmldep.tcl */,
-				AA68C5E50C9032E400D12438 /* xpath.tcl */,
-			);
-			name = Scripts;
-			sourceTree = "<group>";
-		};
-		AA68C5A10C902D7D00D12438 /* Scripts */ = {
-			isa = PBXGroup;
-			children = (
-			);
-			name = Scripts;
-			sourceTree = "<group>";
-		};
-		AA68C5A40C902D8400D12438 /* Headers */ = {
-			isa = PBXGroup;
-			children = (
-				AA68C5F60C90334D00D12438 /* tclxml-libxml2.h */,
-				AA68C5F40C90333E00D12438 /* docObj.h */,
-			);
-			name = Headers;
-			sourceTree = "<group>";
-		};
-		AA68C5A70C902D8C00D12438 /* Sources */ = {
-			isa = PBXGroup;
-			children = (
-				AA68C5F20C90332A00D12438 /* docObj.c */,
-				AA68C5F00C90331D00D12438 /* tclxml-libxml2.c */,
-			);
-			name = Sources;
-			sourceTree = "<group>";
-		};
-		AA68C5AD0C902EF800D12438 /* Scripts */ = {
-			isa = PBXGroup;
-			children = (
-			);
-			name = Scripts;
-			sourceTree = "<group>";
-		};
-		AA68C5B00C902F0200D12438 /* Headers */ = {
-			isa = PBXGroup;
-			children = (
-				AA68C5F80C90336200D12438 /* tcldom.h */,
-			);
-			name = Headers;
-			sourceTree = "<group>";
-		};
-		AA68C5B30C902F0E00D12438 /* Scripts */ = {
-			isa = PBXGroup;
-			children = (
-				AA68C6020C9033AC00D12438 /* tcldom-libxml2.tcl */,
-			);
-			name = Scripts;
-			sourceTree = "<group>";
-		};
-		AA68C5B60C902F1500D12438 /* Headers */ = {
-			isa = PBXGroup;
-			children = (
-				AA68C5FE0C90339C00D12438 /* nodeObj.h */,
-				AA68C5FF0C90339C00D12438 /* tcldom-libxml2.h */,
-			);
-			name = Headers;
-			sourceTree = "<group>";
-		};
-		AA68C5B90C902F1D00D12438 /* Sources */ = {
-			isa = PBXGroup;
-			children = (
-				AA68C5FC0C90338B00D12438 /* nodeObj.c */,
-				AA68C5FA0C90337C00D12438 /* tcldom-libxml2.c */,
-			);
-			name = Sources;
-			sourceTree = "<group>";
-		};
-		AA68C5BC0C902F2D00D12438 /* Scripts */ = {
-			isa = PBXGroup;
-			children = (
-				AA1340B20CB49786006C8E84 /* tclxslt.tcl */,
-				AA68C60A0C90340D00D12438 /* process.tcl */,
-				AA68C60B0C90340D00D12438 /* resources.tcl */,
-				AA68C60C0C90340D00D12438 /* utilities.tcl */,
-				AA68C60D0C90340D00D12438 /* xsltcache.tcl */,
-			);
-			name = Scripts;
-			sourceTree = "<group>";
-		};
-		AA68C5BF0C902F3600D12438 /* Headers */ = {
-			isa = PBXGroup;
-			children = (
-				AA68C6040C9033C900D12438 /* tclxslt.h */,
-			);
-			name = Headers;
-			sourceTree = "<group>";
-		};
-		AA68C5C20C902F4100D12438 /* Scripts */ = {
-			isa = PBXGroup;
-			children = (
-				AA68C6080C9033F300D12438 /* tclxslt-libxslt.tcl */,
-			);
-			name = Scripts;
-			sourceTree = "<group>";
-		};
-		AA68C5C50C902F4900D12438 /* Headers */ = {
-			isa = PBXGroup;
-			children = (
-			);
-			name = Headers;
-			sourceTree = "<group>";
-		};
-		AA68C5C80C902F5400D12438 /* Sources */ = {
-			isa = PBXGroup;
-			children = (
-				AA68C6060C9033E300D12438 /* tclxslt-libxslt.c */,
-			);
-			name = Sources;
-			sourceTree = "<group>";
-		};
-/* End PBXGroup section */
-
-/* Begin PBXHeadersBuildPhase section */
-		8DC2EF500486A6940098B216 /* Headers */ = {
-			isa = PBXHeadersBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				AA68C5D50C9031EA00D12438 /* tclxml.h in Headers */,
-				AA68C5F50C90333E00D12438 /* docObj.h in Headers */,
-				AA68C5F70C90334D00D12438 /* tclxml-libxml2.h in Headers */,
-				AA68C5F90C90336200D12438 /* tcldom.h in Headers */,
-				AA68C6000C90339C00D12438 /* nodeObj.h in Headers */,
-				AA68C6010C90339C00D12438 /* tcldom-libxml2.h in Headers */,
-				AA68C6050C9033C900D12438 /* tclxslt.h in Headers */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXHeadersBuildPhase section */
-
-/* Begin PBXNativeTarget section */
-		8DC2EF4F0486A6940098B216 /* Tclxml */ = {
-			isa = PBXNativeTarget;
-			buildConfigurationList = 1DEB91AD08733DA50010E9CD /* Build configuration list for PBXNativeTarget "Tclxml" */;
-			buildPhases = (
-				8DC2EF500486A6940098B216 /* Headers */,
-				8DC2EF520486A6940098B216 /* Resources */,
-				8DC2EF540486A6940098B216 /* Sources */,
-				8DC2EF560486A6940098B216 /* Frameworks */,
-				AA1340960CAE527B006C8E84 /* ShellScript */,
-			);
-			buildRules = (
-			);
-			dependencies = (
-				AA68C6660C90EA9200D12438 /* PBXTargetDependency */,
-			);
-			name = Tclxml;
-			productInstallPath = "$(HOME)/Library/Frameworks";
-			productName = Tclxml;
-			productReference = 8DC2EF5B0486A6940098B216 /* Tclxml.framework */;
-			productType = "com.apple.product-type.framework";
-		};
-/* End PBXNativeTarget section */
-
-/* Begin PBXProject section */
-		0867D690FE84028FC02AAC07 /* Project object */ = {
-			isa = PBXProject;
-			buildConfigurationList = 1DEB91B108733DA50010E9CD /* Build configuration list for PBXProject "Tclxml" */;
-			compatibilityVersion = "Xcode 2.4";
-			hasScannedForEncodings = 1;
-			mainGroup = 0867D691FE84028FC02AAC07 /* Tclxml */;
-			productRefGroup = 034768DFFF38A50411DB9C8B /* Products */;
-			projectDirPath = "";
-			projectRoot = "";
-			targets = (
-				AA68C6640C90EA8700D12438 /* configure */,
-				8DC2EF4F0486A6940098B216 /* Tclxml */,
-			);
-		};
-/* End PBXProject section */
-
-/* Begin PBXResourcesBuildPhase section */
-		8DC2EF520486A6940098B216 /* Resources */ = {
-			isa = PBXResourcesBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				AA68C5E60C9032E400D12438 /* sgml-8.0.tcl in Resources */,
-				AA68C5E70C9032E400D12438 /* sgml-8.1.tcl in Resources */,
-				AA68C5E80C9032E400D12438 /* sgmlparser.tcl in Resources */,
-				AA68C5E90C9032E400D12438 /* tclparser-8.0.tcl in Resources */,
-				AA68C5EA0C9032E400D12438 /* tclparser-8.1.tcl in Resources */,
-				AA68C5EB0C9032E400D12438 /* xml__tcl.tcl in Resources */,
-				AA68C5EC0C9032E400D12438 /* xml-8.0.tcl in Resources */,
-				AA68C5ED0C9032E400D12438 /* xml-8.1.tcl in Resources */,
-				AA68C5EE0C9032E400D12438 /* xmldep.tcl in Resources */,
-				AA68C5EF0C9032E400D12438 /* xpath.tcl in Resources */,
-				AA68C6030C9033AC00D12438 /* tcldom-libxml2.tcl in Resources */,
-				AA68C6090C9033F300D12438 /* tclxslt-libxslt.tcl in Resources */,
-				AA68C60E0C90340D00D12438 /* process.tcl in Resources */,
-				AA68C60F0C90340D00D12438 /* resources.tcl in Resources */,
-				AA68C6100C90340D00D12438 /* utilities.tcl in Resources */,
-				AA68C6110C90340D00D12438 /* xsltcache.tcl in Resources */,
-				AA68C6F60C91035400D12438 /* Tclxml-Info.plist in Resources */,
-				AA13408D0CACF8FA006C8E84 /* pkgIndex.tcl in Resources */,
-				AA1340B30CB49786006C8E84 /* tclxslt.tcl in Resources */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXResourcesBuildPhase section */
-
-/* Begin PBXShellScriptBuildPhase section */
-		AA1340960CAE527B006C8E84 /* ShellScript */ = {
-			isa = PBXShellScriptBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-			);
-			inputPaths = (
-			);
-			outputPaths = (
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-			shellPath = /bin/sh;
-			shellScript = "mkdir -p ${TARGET_BUILD_DIR}/${CONTENTS_FOLDER_PATH}/Resources/Scripts\nmv ${TARGET_BUILD_DIR}/${CONTENTS_FOLDER_PATH}/Resources/*.tcl ${TARGET_BUILD_DIR}/${CONTENTS_FOLDER_PATH}/Resources/Scripts\n";
-		};
-		AA68C6630C90EA8700D12438 /* ShellScript */ = {
-			isa = PBXShellScriptBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-			);
-			inputPaths = (
-			);
-			outputPaths = (
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-			shellPath = /bin/sh;
-			shellScript = "cd ${SRCROOT}/..; ./configure --with-xml2-config=${BUILD_DIR}/libxml.framework/Resources/Scripts/xml2-config --with-xslt-config=${BUILD_DIR}/libxslt.framework/Resources/Scripts/xslt-config --enable-framework";
-		};
-/* End PBXShellScriptBuildPhase section */
-
-/* Begin PBXSourcesBuildPhase section */
-		8DC2EF540486A6940098B216 /* Sources */ = {
-			isa = PBXSourcesBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				AA68C5D30C9031C400D12438 /* tclxml.c in Sources */,
-				AA68C5F10C90331D00D12438 /* tclxml-libxml2.c in Sources */,
-				AA68C5F30C90332A00D12438 /* docObj.c in Sources */,
-				AA68C5FB0C90337C00D12438 /* tcldom-libxml2.c in Sources */,
-				AA68C5FD0C90338B00D12438 /* nodeObj.c in Sources */,
-				AA68C6070C9033E300D12438 /* tclxslt-libxslt.c in Sources */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXSourcesBuildPhase section */
-
-/* Begin PBXTargetDependency section */
-		AA68C6660C90EA9200D12438 /* PBXTargetDependency */ = {
-			isa = PBXTargetDependency;
-			target = AA68C6640C90EA8700D12438 /* configure */;
-			targetProxy = AA68C6650C90EA9200D12438 /* PBXContainerItemProxy */;
-		};
-/* End PBXTargetDependency section */
-
-/* Begin XCBuildConfiguration section */
-		1DEB91AE08733DA50010E9CD /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				COPY_PHASE_STRIP = NO;
-				DEPLOYMENT_POSTPROCESSING = YES;
-				DYLIB_COMPATIBILITY_VERSION = 1;
-				DYLIB_CURRENT_VERSION = 1;
-				FRAMEWORK_SEARCH_PATHS = (
-					"$(inherited)",
-					"$(FRAMEWORK_SEARCH_PATHS_QUOTED_FOR_TARGET_1)",
-				);
-				FRAMEWORK_SEARCH_PATHS_QUOTED_FOR_TARGET_1 = "\"$(SRCROOT)/../../../Library/Frameworks\"";
-				FRAMEWORK_VERSION = 3.2;
-				GCC_DYNAMIC_NO_PIC = NO;
-				GCC_ENABLE_FIX_AND_CONTINUE = YES;
-				GCC_MODEL_TUNING = G5;
-				GCC_OPTIMIZATION_LEVEL = 0;
-				GCC_PRECOMPILE_PREFIX_HEADER = NO;
-				GCC_PREFIX_HEADER = "";
-				HEADER_SEARCH_PATHS = "$(SRCROOT)/../include";
-				INFOPLIST_FILE = "Tclxml-Info.plist";
-				INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks";
-				LIBXML2_VERSION = 2.6.30;
-				LIBXSLT_VERSION = 1.1.22;
-				PACKAGE_VERSION = 3.2;
-				PRECOMPS_INCLUDE_HEADERS_FROM_BUILT_PRODUCTS_DIR = NO;
-				PRODUCT_NAME = Tclxml;
-				WRAPPER_EXTENSION = framework;
-				ZERO_LINK = YES;
-			};
-			name = Debug;
-		};
-		1DEB91AF08733DA50010E9CD /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ARCHS = i386;
-				DEPLOYMENT_POSTPROCESSING = YES;
-				DYLIB_COMPATIBILITY_VERSION = 1;
-				DYLIB_CURRENT_VERSION = 1;
-				FRAMEWORK_SEARCH_PATHS = (
-					"$(inherited)",
-					"$(FRAMEWORK_SEARCH_PATHS_QUOTED_FOR_TARGET_1)",
-				);
-				FRAMEWORK_SEARCH_PATHS_QUOTED_FOR_TARGET_1 = "\"$(SRCROOT)/../../../Library/Frameworks\"";
-				FRAMEWORK_VERSION = 3.2;
-				GCC_GENERATE_DEBUGGING_SYMBOLS = NO;
-				GCC_MODEL_TUNING = G5;
-				GCC_PRECOMPILE_PREFIX_HEADER = NO;
-				GCC_PREFIX_HEADER = "";
-				HEADER_SEARCH_PATHS = "$(SRCROOT)/../include";
-				INFOPLIST_FILE = "Tclxml-Info.plist";
-				INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks";
-				LIBXML2_VERSION = 2.6.30;
-				LIBXSLT_VERSION = 1.1.22;
-				PACKAGE_VERSION = 3.2;
-				PRECOMPS_INCLUDE_HEADERS_FROM_BUILT_PRODUCTS_DIR = NO;
-				PRODUCT_NAME = Tclxml;
-				WRAPPER_EXTENSION = framework;
-			};
-			name = Release;
-		};
-		1DEB91B208733DA50010E9CD /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ARCHS = (
-					ppc,
-					i386,
-				);
-				FRAMEWORK_VERSION = 3.2;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				PREBINDING = NO;
-				SDKROOT = /Developer/SDKs/MacOSX10.4u.sdk;
-			};
-			name = Debug;
-		};
-		1DEB91B308733DA50010E9CD /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ARCHS = i386;
-				DEPLOYMENT_POSTPROCESSING = YES;
-				FRAMEWORK_VERSION = 3.2;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks";
-				PREBINDING = NO;
-				SDKROOT = /Developer/SDKs/MacOSX10.4u.sdk;
-			};
-			name = Release;
-		};
-		AA68C6680C90EAB000D12438 /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				COPY_PHASE_STRIP = NO;
-				GCC_DYNAMIC_NO_PIC = NO;
-				GCC_GENERATE_DEBUGGING_SYMBOLS = YES;
-				GCC_OPTIMIZATION_LEVEL = 0;
-				PRODUCT_NAME = configure;
-			};
-			name = Debug;
-		};
-		AA68C6690C90EAB000D12438 /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				COPY_PHASE_STRIP = YES;
-				GCC_ENABLE_FIX_AND_CONTINUE = NO;
-				GCC_GENERATE_DEBUGGING_SYMBOLS = NO;
-				PRODUCT_NAME = configure;
-				ZERO_LINK = NO;
-			};
-			name = Release;
-		};
-/* End XCBuildConfiguration section */
-
-/* Begin XCConfigurationList section */
-		1DEB91AD08733DA50010E9CD /* Build configuration list for PBXNativeTarget "Tclxml" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				1DEB91AE08733DA50010E9CD /* Debug */,
-				1DEB91AF08733DA50010E9CD /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-		1DEB91B108733DA50010E9CD /* Build configuration list for PBXProject "Tclxml" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				1DEB91B208733DA50010E9CD /* Debug */,
-				1DEB91B308733DA50010E9CD /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-		AA68C6670C90EAB000D12438 /* Build configuration list for PBXAggregateTarget "configure" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				AA68C6680C90EAB000D12438 /* Debug */,
-				AA68C6690C90EAB000D12438 /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-/* End XCConfigurationList section */
-	};
-	rootObject = 0867D690FE84028FC02AAC07 /* Project object */;
-}
diff --git a/tclxml-3.2/macosx/Tclxml.xcodeproj/steve.mode1 b/tclxml-3.2/macosx/Tclxml.xcodeproj/steve.mode1
deleted file mode 100644
index 379535a..0000000
--- a/tclxml-3.2/macosx/Tclxml.xcodeproj/steve.mode1
+++ /dev/null
@@ -1,1332 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
-<plist version="1.0">
-<dict>
-	<key>ActivePerspectiveName</key>
-	<string>Project</string>
-	<key>AllowedModules</key>
-	<array>
-		<dict>
-			<key>BundleLoadPath</key>
-			<string></string>
-			<key>MaxInstances</key>
-			<string>n</string>
-			<key>Module</key>
-			<string>PBXSmartGroupTreeModule</string>
-			<key>Name</key>
-			<string>Groups and Files Outline View</string>
-		</dict>
-		<dict>
-			<key>BundleLoadPath</key>
-			<string></string>
-			<key>MaxInstances</key>
-			<string>n</string>
-			<key>Module</key>
-			<string>PBXNavigatorGroup</string>
-			<key>Name</key>
-			<string>Editor</string>
-		</dict>
-		<dict>
-			<key>BundleLoadPath</key>
-			<string></string>
-			<key>MaxInstances</key>
-			<string>n</string>
-			<key>Module</key>
-			<string>XCTaskListModule</string>
-			<key>Name</key>
-			<string>Task List</string>
-		</dict>
-		<dict>
-			<key>BundleLoadPath</key>
-			<string></string>
-			<key>MaxInstances</key>
-			<string>n</string>
-			<key>Module</key>
-			<string>XCDetailModule</string>
-			<key>Name</key>
-			<string>File and Smart Group Detail Viewer</string>
-		</dict>
-		<dict>
-			<key>BundleLoadPath</key>
-			<string></string>
-			<key>MaxInstances</key>
-			<string>1</string>
-			<key>Module</key>
-			<string>PBXBuildResultsModule</string>
-			<key>Name</key>
-			<string>Detailed Build Results Viewer</string>
-		</dict>
-		<dict>
-			<key>BundleLoadPath</key>
-			<string></string>
-			<key>MaxInstances</key>
-			<string>1</string>
-			<key>Module</key>
-			<string>PBXProjectFindModule</string>
-			<key>Name</key>
-			<string>Project Batch Find Tool</string>
-		</dict>
-		<dict>
-			<key>BundleLoadPath</key>
-			<string></string>
-			<key>MaxInstances</key>
-			<string>n</string>
-			<key>Module</key>
-			<string>PBXRunSessionModule</string>
-			<key>Name</key>
-			<string>Run Log</string>
-		</dict>
-		<dict>
-			<key>BundleLoadPath</key>
-			<string></string>
-			<key>MaxInstances</key>
-			<string>n</string>
-			<key>Module</key>
-			<string>PBXBookmarksModule</string>
-			<key>Name</key>
-			<string>Bookmarks Tool</string>
-		</dict>
-		<dict>
-			<key>BundleLoadPath</key>
-			<string></string>
-			<key>MaxInstances</key>
-			<string>n</string>
-			<key>Module</key>
-			<string>PBXClassBrowserModule</string>
-			<key>Name</key>
-			<string>Class Browser</string>
-		</dict>
-		<dict>
-			<key>BundleLoadPath</key>
-			<string></string>
-			<key>MaxInstances</key>
-			<string>n</string>
-			<key>Module</key>
-			<string>PBXCVSModule</string>
-			<key>Name</key>
-			<string>Source Code Control Tool</string>
-		</dict>
-		<dict>
-			<key>BundleLoadPath</key>
-			<string></string>
-			<key>MaxInstances</key>
-			<string>n</string>
-			<key>Module</key>
-			<string>PBXDebugBreakpointsModule</string>
-			<key>Name</key>
-			<string>Debug Breakpoints Tool</string>
-		</dict>
-		<dict>
-			<key>BundleLoadPath</key>
-			<string></string>
-			<key>MaxInstances</key>
-			<string>n</string>
-			<key>Module</key>
-			<string>XCDockableInspector</string>
-			<key>Name</key>
-			<string>Inspector</string>
-		</dict>
-		<dict>
-			<key>BundleLoadPath</key>
-			<string></string>
-			<key>MaxInstances</key>
-			<string>n</string>
-			<key>Module</key>
-			<string>PBXOpenQuicklyModule</string>
-			<key>Name</key>
-			<string>Open Quickly Tool</string>
-		</dict>
-		<dict>
-			<key>BundleLoadPath</key>
-			<string></string>
-			<key>MaxInstances</key>
-			<string>1</string>
-			<key>Module</key>
-			<string>PBXDebugSessionModule</string>
-			<key>Name</key>
-			<string>Debugger</string>
-		</dict>
-		<dict>
-			<key>BundleLoadPath</key>
-			<string></string>
-			<key>MaxInstances</key>
-			<string>1</string>
-			<key>Module</key>
-			<string>PBXDebugCLIModule</string>
-			<key>Name</key>
-			<string>Debug Console</string>
-		</dict>
-	</array>
-	<key>Description</key>
-	<string>DefaultDescriptionKey</string>
-	<key>DockingSystemVisible</key>
-	<false/>
-	<key>Extension</key>
-	<string>mode1</string>
-	<key>FavBarConfig</key>
-	<dict>
-		<key>PBXProjectModuleGUID</key>
-		<string>AA68C5AA0C902DA500D12438</string>
-		<key>XCBarModuleItemNames</key>
-		<dict/>
-		<key>XCBarModuleItems</key>
-		<array/>
-	</dict>
-	<key>FirstTimeWindowDisplayed</key>
-	<false/>
-	<key>Identifier</key>
-	<string>com.apple.perspectives.project.mode1</string>
-	<key>MajorVersion</key>
-	<integer>31</integer>
-	<key>MinorVersion</key>
-	<integer>1</integer>
-	<key>Name</key>
-	<string>Default</string>
-	<key>Notifications</key>
-	<array/>
-	<key>OpenEditors</key>
-	<array/>
-	<key>PerspectiveWidths</key>
-	<array>
-		<integer>-1</integer>
-		<integer>-1</integer>
-	</array>
-	<key>Perspectives</key>
-	<array>
-		<dict>
-			<key>ChosenToolbarItems</key>
-			<array>
-				<string>active-target-popup</string>
-				<string>action</string>
-				<string>NSToolbarFlexibleSpaceItem</string>
-				<string>buildOrClean</string>
-				<string>build-and-runOrDebug</string>
-				<string>com.apple.ide.PBXToolbarStopButton</string>
-				<string>get-info</string>
-				<string>toggle-editor</string>
-				<string>NSToolbarFlexibleSpaceItem</string>
-				<string>com.apple.pbx.toolbar.searchfield</string>
-			</array>
-			<key>ControllerClassBaseName</key>
-			<string></string>
-			<key>IconName</key>
-			<string>WindowOfProjectWithEditor</string>
-			<key>Identifier</key>
-			<string>perspective.project</string>
-			<key>IsVertical</key>
-			<false/>
-			<key>Layout</key>
-			<array>
-				<dict>
-					<key>BecomeActive</key>
-					<true/>
-					<key>ContentConfiguration</key>
-					<dict>
-						<key>PBXBottomSmartGroupGIDs</key>
-						<array>
-							<string>1C37FBAC04509CD000000102</string>
-							<string>1C37FAAC04509CD000000102</string>
-							<string>1C08E77C0454961000C914BD</string>
-							<string>1C37FABC05509CD000000102</string>
-							<string>1C37FABC05539CD112110102</string>
-							<string>E2644B35053B69B200211256</string>
-							<string>1C37FABC04509CD000100104</string>
-							<string>1CC0EA4004350EF90044410B</string>
-							<string>1CC0EA4004350EF90041110B</string>
-						</array>
-						<key>PBXProjectModuleGUID</key>
-						<string>1CE0B1FE06471DED0097A5F4</string>
-						<key>PBXProjectModuleLabel</key>
-						<string>Files</string>
-						<key>PBXProjectStructureProvided</key>
-						<string>yes</string>
-						<key>PBXSmartGroupTreeModuleColumnData</key>
-						<dict>
-							<key>PBXSmartGroupTreeModuleColumnWidthsKey</key>
-							<array>
-								<real>212</real>
-							</array>
-							<key>PBXSmartGroupTreeModuleColumnsKey_v4</key>
-							<array>
-								<string>MainColumn</string>
-							</array>
-						</dict>
-						<key>PBXSmartGroupTreeModuleOutlineStateKey_v7</key>
-						<dict>
-							<key>PBXSmartGroupTreeModuleOutlineStateExpansionKey</key>
-							<array>
-								<string>0867D691FE84028FC02AAC07</string>
-								<string>1C37FBAC04509CD000000102</string>
-								<string>AAF4A0890CBA19EA00B05FEF</string>
-								<string>1C37FABC05509CD000000102</string>
-							</array>
-							<key>PBXSmartGroupTreeModuleOutlineStateSelectionKey</key>
-							<array>
-								<array>
-									<integer>18</integer>
-									<integer>12</integer>
-									<integer>10</integer>
-								</array>
-							</array>
-							<key>PBXSmartGroupTreeModuleOutlineStateVisibleRectKey</key>
-							<string>{{0, 0}, {212, 697}}</string>
-						</dict>
-						<key>PBXTopSmartGroupGIDs</key>
-						<array/>
-						<key>XCIncludePerspectivesSwitch</key>
-						<true/>
-						<key>XCSharingToken</key>
-						<string>com.apple.Xcode.GFSharingToken</string>
-					</dict>
-					<key>GeometryConfiguration</key>
-					<dict>
-						<key>Frame</key>
-						<string>{{0, 0}, {229, 715}}</string>
-						<key>GroupTreeTableConfiguration</key>
-						<array>
-							<string>MainColumn</string>
-							<real>212</real>
-						</array>
-						<key>RubberWindowFrame</key>
-						<string>1 66 771 756 0 0 1440 878 </string>
-					</dict>
-					<key>Module</key>
-					<string>PBXSmartGroupTreeModule</string>
-					<key>Proportion</key>
-					<string>229pt</string>
-				</dict>
-				<dict>
-					<key>Dock</key>
-					<array>
-						<dict>
-							<key>ContentConfiguration</key>
-							<dict>
-								<key>PBXProjectModuleGUID</key>
-								<string>1CE0B20306471E060097A5F4</string>
-								<key>PBXProjectModuleLabel</key>
-								<string>MyNewFile14.java</string>
-								<key>PBXSplitModuleInNavigatorKey</key>
-								<dict>
-									<key>Split0</key>
-									<dict>
-										<key>PBXProjectModuleGUID</key>
-										<string>1CE0B20406471E060097A5F4</string>
-										<key>PBXProjectModuleLabel</key>
-										<string>MyNewFile14.java</string>
-									</dict>
-									<key>SplitCount</key>
-									<string>1</string>
-								</dict>
-								<key>StatusBarVisibility</key>
-								<true/>
-							</dict>
-							<key>GeometryConfiguration</key>
-							<dict>
-								<key>Frame</key>
-								<string>{{0, 0}, {537, 0}}</string>
-								<key>RubberWindowFrame</key>
-								<string>1 66 771 756 0 0 1440 878 </string>
-							</dict>
-							<key>Module</key>
-							<string>PBXNavigatorGroup</string>
-							<key>Proportion</key>
-							<string>0pt</string>
-						</dict>
-						<dict>
-							<key>ContentConfiguration</key>
-							<dict>
-								<key>PBXProjectModuleGUID</key>
-								<string>1CE0B20506471E060097A5F4</string>
-								<key>PBXProjectModuleLabel</key>
-								<string>Detail</string>
-							</dict>
-							<key>GeometryConfiguration</key>
-							<dict>
-								<key>Frame</key>
-								<string>{{0, 5}, {537, 710}}</string>
-								<key>RubberWindowFrame</key>
-								<string>1 66 771 756 0 0 1440 878 </string>
-							</dict>
-							<key>Module</key>
-							<string>XCDetailModule</string>
-							<key>Proportion</key>
-							<string>710pt</string>
-						</dict>
-					</array>
-					<key>Proportion</key>
-					<string>537pt</string>
-				</dict>
-			</array>
-			<key>Name</key>
-			<string>Project</string>
-			<key>ServiceClasses</key>
-			<array>
-				<string>XCModuleDock</string>
-				<string>PBXSmartGroupTreeModule</string>
-				<string>XCModuleDock</string>
-				<string>PBXNavigatorGroup</string>
-				<string>XCDetailModule</string>
-			</array>
-			<key>TableOfContents</key>
-			<array>
-				<string>AAF4A08A0CBA1A0600B05FEF</string>
-				<string>1CE0B1FE06471DED0097A5F4</string>
-				<string>AAF4A08B0CBA1A0600B05FEF</string>
-				<string>1CE0B20306471E060097A5F4</string>
-				<string>1CE0B20506471E060097A5F4</string>
-			</array>
-			<key>ToolbarConfiguration</key>
-			<string>xcode.toolbar.config.default</string>
-		</dict>
-		<dict>
-			<key>ControllerClassBaseName</key>
-			<string></string>
-			<key>IconName</key>
-			<string>WindowOfProject</string>
-			<key>Identifier</key>
-			<string>perspective.morph</string>
-			<key>IsVertical</key>
-			<integer>0</integer>
-			<key>Layout</key>
-			<array>
-				<dict>
-					<key>BecomeActive</key>
-					<integer>1</integer>
-					<key>ContentConfiguration</key>
-					<dict>
-						<key>PBXBottomSmartGroupGIDs</key>
-						<array>
-							<string>1C37FBAC04509CD000000102</string>
-							<string>1C37FAAC04509CD000000102</string>
-							<string>1C08E77C0454961000C914BD</string>
-							<string>1C37FABC05509CD000000102</string>
-							<string>1C37FABC05539CD112110102</string>
-							<string>E2644B35053B69B200211256</string>
-							<string>1C37FABC04509CD000100104</string>
-							<string>1CC0EA4004350EF90044410B</string>
-							<string>1CC0EA4004350EF90041110B</string>
-						</array>
-						<key>PBXProjectModuleGUID</key>
-						<string>11E0B1FE06471DED0097A5F4</string>
-						<key>PBXProjectModuleLabel</key>
-						<string>Files</string>
-						<key>PBXProjectStructureProvided</key>
-						<string>yes</string>
-						<key>PBXSmartGroupTreeModuleColumnData</key>
-						<dict>
-							<key>PBXSmartGroupTreeModuleColumnWidthsKey</key>
-							<array>
-								<real>186</real>
-							</array>
-							<key>PBXSmartGroupTreeModuleColumnsKey_v4</key>
-							<array>
-								<string>MainColumn</string>
-							</array>
-						</dict>
-						<key>PBXSmartGroupTreeModuleOutlineStateKey_v7</key>
-						<dict>
-							<key>PBXSmartGroupTreeModuleOutlineStateExpansionKey</key>
-							<array>
-								<string>29B97314FDCFA39411CA2CEA</string>
-								<string>1C37FABC05509CD000000102</string>
-							</array>
-							<key>PBXSmartGroupTreeModuleOutlineStateSelectionKey</key>
-							<array>
-								<array>
-									<integer>0</integer>
-								</array>
-							</array>
-							<key>PBXSmartGroupTreeModuleOutlineStateVisibleRectKey</key>
-							<string>{{0, 0}, {186, 337}}</string>
-						</dict>
-						<key>PBXTopSmartGroupGIDs</key>
-						<array/>
-						<key>XCIncludePerspectivesSwitch</key>
-						<integer>1</integer>
-						<key>XCSharingToken</key>
-						<string>com.apple.Xcode.GFSharingToken</string>
-					</dict>
-					<key>GeometryConfiguration</key>
-					<dict>
-						<key>Frame</key>
-						<string>{{0, 0}, {203, 355}}</string>
-						<key>GroupTreeTableConfiguration</key>
-						<array>
-							<string>MainColumn</string>
-							<real>186</real>
-						</array>
-						<key>RubberWindowFrame</key>
-						<string>373 269 690 397 0 0 1440 878 </string>
-					</dict>
-					<key>Module</key>
-					<string>PBXSmartGroupTreeModule</string>
-					<key>Proportion</key>
-					<string>100%</string>
-				</dict>
-			</array>
-			<key>Name</key>
-			<string>Morph</string>
-			<key>PreferredWidth</key>
-			<integer>300</integer>
-			<key>ServiceClasses</key>
-			<array>
-				<string>XCModuleDock</string>
-				<string>PBXSmartGroupTreeModule</string>
-			</array>
-			<key>TableOfContents</key>
-			<array>
-				<string>11E0B1FE06471DED0097A5F4</string>
-			</array>
-			<key>ToolbarConfiguration</key>
-			<string>xcode.toolbar.config.default.short</string>
-		</dict>
-	</array>
-	<key>PerspectivesBarVisible</key>
-	<false/>
-	<key>ShelfIsVisible</key>
-	<false/>
-	<key>SourceDescription</key>
-	<string>file at '/System/Library/PrivateFrameworks/DevToolsInterface.framework/Versions/A/Resources/XCPerspectivesSpecificationMode1.xcperspec'</string>
-	<key>StatusbarIsVisible</key>
-	<true/>
-	<key>TimeStamp</key>
-	<real>0.0</real>
-	<key>ToolbarDisplayMode</key>
-	<integer>1</integer>
-	<key>ToolbarIsVisible</key>
-	<true/>
-	<key>ToolbarSizeMode</key>
-	<integer>1</integer>
-	<key>Type</key>
-	<string>Perspectives</string>
-	<key>UpdateMessage</key>
-	<string>The Default Workspace in this version of Xcode now includes support to hide and show the detail view (what has been referred to as the "Metro-Morph" feature).  You must discard your current Default Workspace settings and update to the latest Default Workspace in order to gain this feature.  Do you wish to update to the latest Workspace defaults for project '%@'?</string>
-	<key>WindowJustification</key>
-	<integer>5</integer>
-	<key>WindowOrderList</key>
-	<array>
-		<string>/Users/steve/Projects/tclxml-3.2/macosx/Tclxml.xcodeproj</string>
-		<string>AA68C7030C9103FD00D12438</string>
-	</array>
-	<key>WindowString</key>
-	<string>1 66 771 756 0 0 1440 878 </string>
-	<key>WindowTools</key>
-	<array>
-		<dict>
-			<key>FirstTimeWindowDisplayed</key>
-			<false/>
-			<key>Identifier</key>
-			<string>windowTool.build</string>
-			<key>IsVertical</key>
-			<true/>
-			<key>Layout</key>
-			<array>
-				<dict>
-					<key>Dock</key>
-					<array>
-						<dict>
-							<key>ContentConfiguration</key>
-							<dict>
-								<key>PBXProjectModuleGUID</key>
-								<string>1CD0528F0623707200166675</string>
-								<key>PBXProjectModuleLabel</key>
-								<string></string>
-								<key>StatusBarVisibility</key>
-								<true/>
-							</dict>
-							<key>GeometryConfiguration</key>
-							<dict>
-								<key>Frame</key>
-								<string>{{0, 0}, {586, 0}}</string>
-								<key>RubberWindowFrame</key>
-								<string>697 202 586 676 0 0 1440 878 </string>
-							</dict>
-							<key>Module</key>
-							<string>PBXNavigatorGroup</string>
-							<key>Proportion</key>
-							<string>0pt</string>
-						</dict>
-						<dict>
-							<key>BecomeActive</key>
-							<true/>
-							<key>ContentConfiguration</key>
-							<dict>
-								<key>PBXBuildLogShowsTranscriptDefaultKey</key>
-								<string>{{0, 102}, {586, 528}}</string>
-								<key>PBXProjectModuleGUID</key>
-								<string>XCMainBuildResultsModuleGUID</string>
-								<key>PBXProjectModuleLabel</key>
-								<string>Build</string>
-								<key>XCBuildResultsTrigger_Collapse</key>
-								<integer>1021</integer>
-								<key>XCBuildResultsTrigger_Open</key>
-								<integer>1011</integer>
-							</dict>
-							<key>GeometryConfiguration</key>
-							<dict>
-								<key>Frame</key>
-								<string>{{0, 5}, {586, 630}}</string>
-								<key>RubberWindowFrame</key>
-								<string>697 202 586 676 0 0 1440 878 </string>
-							</dict>
-							<key>Module</key>
-							<string>PBXBuildResultsModule</string>
-							<key>Proportion</key>
-							<string>630pt</string>
-						</dict>
-					</array>
-					<key>Proportion</key>
-					<string>635pt</string>
-				</dict>
-			</array>
-			<key>Name</key>
-			<string>Build Results</string>
-			<key>ServiceClasses</key>
-			<array>
-				<string>PBXBuildResultsModule</string>
-			</array>
-			<key>StatusbarIsVisible</key>
-			<true/>
-			<key>TableOfContents</key>
-			<array>
-				<string>AA68C7030C9103FD00D12438</string>
-				<string>AAF4A08E0CBA1A8B00B05FEF</string>
-				<string>1CD0528F0623707200166675</string>
-				<string>XCMainBuildResultsModuleGUID</string>
-			</array>
-			<key>ToolbarConfiguration</key>
-			<string>xcode.toolbar.config.build</string>
-			<key>WindowString</key>
-			<string>697 202 586 676 0 0 1440 878 </string>
-			<key>WindowToolGUID</key>
-			<string>AA68C7030C9103FD00D12438</string>
-			<key>WindowToolIsVisible</key>
-			<true/>
-		</dict>
-		<dict>
-			<key>Identifier</key>
-			<string>windowTool.debugger</string>
-			<key>Layout</key>
-			<array>
-				<dict>
-					<key>Dock</key>
-					<array>
-						<dict>
-							<key>ContentConfiguration</key>
-							<dict>
-								<key>Debugger</key>
-								<dict>
-									<key>HorizontalSplitView</key>
-									<dict>
-										<key>_collapsingFrameDimension</key>
-										<real>0.0</real>
-										<key>_indexOfCollapsedView</key>
-										<integer>0</integer>
-										<key>_percentageOfCollapsedView</key>
-										<real>0.0</real>
-										<key>isCollapsed</key>
-										<string>yes</string>
-										<key>sizes</key>
-										<array>
-											<string>{{0, 0}, {317, 164}}</string>
-											<string>{{317, 0}, {377, 164}}</string>
-										</array>
-									</dict>
-									<key>VerticalSplitView</key>
-									<dict>
-										<key>_collapsingFrameDimension</key>
-										<real>0.0</real>
-										<key>_indexOfCollapsedView</key>
-										<integer>0</integer>
-										<key>_percentageOfCollapsedView</key>
-										<real>0.0</real>
-										<key>isCollapsed</key>
-										<string>yes</string>
-										<key>sizes</key>
-										<array>
-											<string>{{0, 0}, {694, 164}}</string>
-											<string>{{0, 164}, {694, 216}}</string>
-										</array>
-									</dict>
-								</dict>
-								<key>LauncherConfigVersion</key>
-								<string>8</string>
-								<key>PBXProjectModuleGUID</key>
-								<string>1C162984064C10D400B95A72</string>
-								<key>PBXProjectModuleLabel</key>
-								<string>Debug - GLUTExamples (Underwater)</string>
-							</dict>
-							<key>GeometryConfiguration</key>
-							<dict>
-								<key>DebugConsoleDrawerSize</key>
-								<string>{100, 120}</string>
-								<key>DebugConsoleVisible</key>
-								<string>None</string>
-								<key>DebugConsoleWindowFrame</key>
-								<string>{{200, 200}, {500, 300}}</string>
-								<key>DebugSTDIOWindowFrame</key>
-								<string>{{200, 200}, {500, 300}}</string>
-								<key>Frame</key>
-								<string>{{0, 0}, {694, 380}}</string>
-								<key>RubberWindowFrame</key>
-								<string>321 238 694 422 0 0 1440 878 </string>
-							</dict>
-							<key>Module</key>
-							<string>PBXDebugSessionModule</string>
-							<key>Proportion</key>
-							<string>100%</string>
-						</dict>
-					</array>
-					<key>Proportion</key>
-					<string>100%</string>
-				</dict>
-			</array>
-			<key>Name</key>
-			<string>Debugger</string>
-			<key>ServiceClasses</key>
-			<array>
-				<string>PBXDebugSessionModule</string>
-			</array>
-			<key>StatusbarIsVisible</key>
-			<integer>1</integer>
-			<key>TableOfContents</key>
-			<array>
-				<string>1CD10A99069EF8BA00B06720</string>
-				<string>1C0AD2AB069F1E9B00FABCE6</string>
-				<string>1C162984064C10D400B95A72</string>
-				<string>1C0AD2AC069F1E9B00FABCE6</string>
-			</array>
-			<key>ToolbarConfiguration</key>
-			<string>xcode.toolbar.config.debug</string>
-			<key>WindowString</key>
-			<string>321 238 694 422 0 0 1440 878 </string>
-			<key>WindowToolGUID</key>
-			<string>1CD10A99069EF8BA00B06720</string>
-			<key>WindowToolIsVisible</key>
-			<integer>0</integer>
-		</dict>
-		<dict>
-			<key>Identifier</key>
-			<string>windowTool.find</string>
-			<key>Layout</key>
-			<array>
-				<dict>
-					<key>Dock</key>
-					<array>
-						<dict>
-							<key>Dock</key>
-							<array>
-								<dict>
-									<key>ContentConfiguration</key>
-									<dict>
-										<key>PBXProjectModuleGUID</key>
-										<string>1CDD528C0622207200134675</string>
-										<key>PBXProjectModuleLabel</key>
-										<string><No Editor></string>
-										<key>PBXSplitModuleInNavigatorKey</key>
-										<dict>
-											<key>Split0</key>
-											<dict>
-												<key>PBXProjectModuleGUID</key>
-												<string>1CD0528D0623707200166675</string>
-											</dict>
-											<key>SplitCount</key>
-											<string>1</string>
-										</dict>
-										<key>StatusBarVisibility</key>
-										<integer>1</integer>
-									</dict>
-									<key>GeometryConfiguration</key>
-									<dict>
-										<key>Frame</key>
-										<string>{{0, 0}, {781, 167}}</string>
-										<key>RubberWindowFrame</key>
-										<string>62 385 781 470 0 0 1440 878 </string>
-									</dict>
-									<key>Module</key>
-									<string>PBXNavigatorGroup</string>
-									<key>Proportion</key>
-									<string>781pt</string>
-								</dict>
-							</array>
-							<key>Proportion</key>
-							<string>50%</string>
-						</dict>
-						<dict>
-							<key>BecomeActive</key>
-							<integer>1</integer>
-							<key>ContentConfiguration</key>
-							<dict>
-								<key>PBXProjectModuleGUID</key>
-								<string>1CD0528E0623707200166675</string>
-								<key>PBXProjectModuleLabel</key>
-								<string>Project Find</string>
-							</dict>
-							<key>GeometryConfiguration</key>
-							<dict>
-								<key>Frame</key>
-								<string>{{8, 0}, {773, 254}}</string>
-								<key>RubberWindowFrame</key>
-								<string>62 385 781 470 0 0 1440 878 </string>
-							</dict>
-							<key>Module</key>
-							<string>PBXProjectFindModule</string>
-							<key>Proportion</key>
-							<string>50%</string>
-						</dict>
-					</array>
-					<key>Proportion</key>
-					<string>428pt</string>
-				</dict>
-			</array>
-			<key>Name</key>
-			<string>Project Find</string>
-			<key>ServiceClasses</key>
-			<array>
-				<string>PBXProjectFindModule</string>
-			</array>
-			<key>StatusbarIsVisible</key>
-			<integer>1</integer>
-			<key>TableOfContents</key>
-			<array>
-				<string>1C530D57069F1CE1000CFCEE</string>
-				<string>1C530D58069F1CE1000CFCEE</string>
-				<string>1C530D59069F1CE1000CFCEE</string>
-				<string>1CDD528C0622207200134675</string>
-				<string>1C530D5A069F1CE1000CFCEE</string>
-				<string>1CE0B1FE06471DED0097A5F4</string>
-				<string>1CD0528E0623707200166675</string>
-			</array>
-			<key>WindowString</key>
-			<string>62 385 781 470 0 0 1440 878 </string>
-			<key>WindowToolGUID</key>
-			<string>1C530D57069F1CE1000CFCEE</string>
-			<key>WindowToolIsVisible</key>
-			<integer>0</integer>
-		</dict>
-		<dict>
-			<key>Identifier</key>
-			<string>MENUSEPARATOR</string>
-		</dict>
-		<dict>
-			<key>Identifier</key>
-			<string>windowTool.debuggerConsole</string>
-			<key>Layout</key>
-			<array>
-				<dict>
-					<key>Dock</key>
-					<array>
-						<dict>
-							<key>BecomeActive</key>
-							<integer>1</integer>
-							<key>ContentConfiguration</key>
-							<dict>
-								<key>PBXProjectModuleGUID</key>
-								<string>1C78EAAC065D492600B07095</string>
-								<key>PBXProjectModuleLabel</key>
-								<string>Debugger Console</string>
-							</dict>
-							<key>GeometryConfiguration</key>
-							<dict>
-								<key>Frame</key>
-								<string>{{0, 0}, {440, 358}}</string>
-								<key>RubberWindowFrame</key>
-								<string>650 41 440 400 0 0 1280 1002 </string>
-							</dict>
-							<key>Module</key>
-							<string>PBXDebugCLIModule</string>
-							<key>Proportion</key>
-							<string>358pt</string>
-						</dict>
-					</array>
-					<key>Proportion</key>
-					<string>358pt</string>
-				</dict>
-			</array>
-			<key>Name</key>
-			<string>Debugger Console</string>
-			<key>ServiceClasses</key>
-			<array>
-				<string>PBXDebugCLIModule</string>
-			</array>
-			<key>StatusbarIsVisible</key>
-			<integer>1</integer>
-			<key>TableOfContents</key>
-			<array>
-				<string>1C78EAAD065D492600B07095</string>
-				<string>1C78EAAE065D492600B07095</string>
-				<string>1C78EAAC065D492600B07095</string>
-			</array>
-			<key>WindowString</key>
-			<string>650 41 440 400 0 0 1280 1002 </string>
-		</dict>
-		<dict>
-			<key>Identifier</key>
-			<string>windowTool.run</string>
-			<key>Layout</key>
-			<array>
-				<dict>
-					<key>Dock</key>
-					<array>
-						<dict>
-							<key>ContentConfiguration</key>
-							<dict>
-								<key>LauncherConfigVersion</key>
-								<string>3</string>
-								<key>PBXProjectModuleGUID</key>
-								<string>1CD0528B0623707200166675</string>
-								<key>PBXProjectModuleLabel</key>
-								<string>Run</string>
-								<key>Runner</key>
-								<dict>
-									<key>HorizontalSplitView</key>
-									<dict>
-										<key>_collapsingFrameDimension</key>
-										<real>0.0</real>
-										<key>_indexOfCollapsedView</key>
-										<integer>0</integer>
-										<key>_percentageOfCollapsedView</key>
-										<real>0.0</real>
-										<key>isCollapsed</key>
-										<string>yes</string>
-										<key>sizes</key>
-										<array>
-											<string>{{0, 0}, {493, 167}}</string>
-											<string>{{0, 176}, {493, 267}}</string>
-										</array>
-									</dict>
-									<key>VerticalSplitView</key>
-									<dict>
-										<key>_collapsingFrameDimension</key>
-										<real>0.0</real>
-										<key>_indexOfCollapsedView</key>
-										<integer>0</integer>
-										<key>_percentageOfCollapsedView</key>
-										<real>0.0</real>
-										<key>isCollapsed</key>
-										<string>yes</string>
-										<key>sizes</key>
-										<array>
-											<string>{{0, 0}, {405, 443}}</string>
-											<string>{{414, 0}, {514, 443}}</string>
-										</array>
-									</dict>
-								</dict>
-							</dict>
-							<key>GeometryConfiguration</key>
-							<dict>
-								<key>Frame</key>
-								<string>{{0, 0}, {460, 159}}</string>
-								<key>RubberWindowFrame</key>
-								<string>316 696 459 200 0 0 1280 1002 </string>
-							</dict>
-							<key>Module</key>
-							<string>PBXRunSessionModule</string>
-							<key>Proportion</key>
-							<string>159pt</string>
-						</dict>
-					</array>
-					<key>Proportion</key>
-					<string>159pt</string>
-				</dict>
-			</array>
-			<key>Name</key>
-			<string>Run Log</string>
-			<key>ServiceClasses</key>
-			<array>
-				<string>PBXRunSessionModule</string>
-			</array>
-			<key>StatusbarIsVisible</key>
-			<integer>1</integer>
-			<key>TableOfContents</key>
-			<array>
-				<string>1C0AD2B3069F1EA900FABCE6</string>
-				<string>1C0AD2B4069F1EA900FABCE6</string>
-				<string>1CD0528B0623707200166675</string>
-				<string>1C0AD2B5069F1EA900FABCE6</string>
-			</array>
-			<key>ToolbarConfiguration</key>
-			<string>xcode.toolbar.config.run</string>
-			<key>WindowString</key>
-			<string>316 696 459 200 0 0 1280 1002 </string>
-			<key>WindowToolGUID</key>
-			<string>1C0AD2B3069F1EA900FABCE6</string>
-			<key>WindowToolIsVisible</key>
-			<integer>0</integer>
-		</dict>
-		<dict>
-			<key>Identifier</key>
-			<string>windowTool.scm</string>
-			<key>Layout</key>
-			<array>
-				<dict>
-					<key>Dock</key>
-					<array>
-						<dict>
-							<key>ContentConfiguration</key>
-							<dict>
-								<key>PBXProjectModuleGUID</key>
-								<string>1C78EAB2065D492600B07095</string>
-								<key>PBXProjectModuleLabel</key>
-								<string><No Editor></string>
-								<key>PBXSplitModuleInNavigatorKey</key>
-								<dict>
-									<key>Split0</key>
-									<dict>
-										<key>PBXProjectModuleGUID</key>
-										<string>1C78EAB3065D492600B07095</string>
-									</dict>
-									<key>SplitCount</key>
-									<string>1</string>
-								</dict>
-								<key>StatusBarVisibility</key>
-								<integer>1</integer>
-							</dict>
-							<key>GeometryConfiguration</key>
-							<dict>
-								<key>Frame</key>
-								<string>{{0, 0}, {452, 0}}</string>
-								<key>RubberWindowFrame</key>
-								<string>743 379 452 308 0 0 1280 1002 </string>
-							</dict>
-							<key>Module</key>
-							<string>PBXNavigatorGroup</string>
-							<key>Proportion</key>
-							<string>0pt</string>
-						</dict>
-						<dict>
-							<key>BecomeActive</key>
-							<integer>1</integer>
-							<key>ContentConfiguration</key>
-							<dict>
-								<key>PBXProjectModuleGUID</key>
-								<string>1CD052920623707200166675</string>
-								<key>PBXProjectModuleLabel</key>
-								<string>SCM</string>
-							</dict>
-							<key>GeometryConfiguration</key>
-							<dict>
-								<key>ConsoleFrame</key>
-								<string>{{0, 259}, {452, 0}}</string>
-								<key>Frame</key>
-								<string>{{0, 7}, {452, 259}}</string>
-								<key>RubberWindowFrame</key>
-								<string>743 379 452 308 0 0 1280 1002 </string>
-								<key>TableConfiguration</key>
-								<array>
-									<string>Status</string>
-									<real>30</real>
-									<string>FileName</string>
-									<real>199</real>
-									<string>Path</string>
-									<real>197.09500122070312</real>
-								</array>
-								<key>TableFrame</key>
-								<string>{{0, 0}, {452, 250}}</string>
-							</dict>
-							<key>Module</key>
-							<string>PBXCVSModule</string>
-							<key>Proportion</key>
-							<string>262pt</string>
-						</dict>
-					</array>
-					<key>Proportion</key>
-					<string>266pt</string>
-				</dict>
-			</array>
-			<key>Name</key>
-			<string>SCM</string>
-			<key>ServiceClasses</key>
-			<array>
-				<string>PBXCVSModule</string>
-			</array>
-			<key>StatusbarIsVisible</key>
-			<integer>1</integer>
-			<key>TableOfContents</key>
-			<array>
-				<string>1C78EAB4065D492600B07095</string>
-				<string>1C78EAB5065D492600B07095</string>
-				<string>1C78EAB2065D492600B07095</string>
-				<string>1CD052920623707200166675</string>
-			</array>
-			<key>ToolbarConfiguration</key>
-			<string>xcode.toolbar.config.scm</string>
-			<key>WindowString</key>
-			<string>743 379 452 308 0 0 1280 1002 </string>
-		</dict>
-		<dict>
-			<key>Identifier</key>
-			<string>windowTool.breakpoints</string>
-			<key>IsVertical</key>
-			<integer>0</integer>
-			<key>Layout</key>
-			<array>
-				<dict>
-					<key>Dock</key>
-					<array>
-						<dict>
-							<key>BecomeActive</key>
-							<integer>1</integer>
-							<key>ContentConfiguration</key>
-							<dict>
-								<key>PBXBottomSmartGroupGIDs</key>
-								<array>
-									<string>1C77FABC04509CD000000102</string>
-								</array>
-								<key>PBXProjectModuleGUID</key>
-								<string>1CE0B1FE06471DED0097A5F4</string>
-								<key>PBXProjectModuleLabel</key>
-								<string>Files</string>
-								<key>PBXProjectStructureProvided</key>
-								<string>no</string>
-								<key>PBXSmartGroupTreeModuleColumnData</key>
-								<dict>
-									<key>PBXSmartGroupTreeModuleColumnWidthsKey</key>
-									<array>
-										<real>168</real>
-									</array>
-									<key>PBXSmartGroupTreeModuleColumnsKey_v4</key>
-									<array>
-										<string>MainColumn</string>
-									</array>
-								</dict>
-								<key>PBXSmartGroupTreeModuleOutlineStateKey_v7</key>
-								<dict>
-									<key>PBXSmartGroupTreeModuleOutlineStateExpansionKey</key>
-									<array>
-										<string>1C77FABC04509CD000000102</string>
-									</array>
-									<key>PBXSmartGroupTreeModuleOutlineStateSelectionKey</key>
-									<array>
-										<array>
-											<integer>0</integer>
-										</array>
-									</array>
-									<key>PBXSmartGroupTreeModuleOutlineStateVisibleRectKey</key>
-									<string>{{0, 0}, {168, 350}}</string>
-								</dict>
-								<key>PBXTopSmartGroupGIDs</key>
-								<array/>
-								<key>XCIncludePerspectivesSwitch</key>
-								<integer>0</integer>
-							</dict>
-							<key>GeometryConfiguration</key>
-							<dict>
-								<key>Frame</key>
-								<string>{{0, 0}, {185, 368}}</string>
-								<key>GroupTreeTableConfiguration</key>
-								<array>
-									<string>MainColumn</string>
-									<real>168</real>
-								</array>
-								<key>RubberWindowFrame</key>
-								<string>315 424 744 409 0 0 1440 878 </string>
-							</dict>
-							<key>Module</key>
-							<string>PBXSmartGroupTreeModule</string>
-							<key>Proportion</key>
-							<string>185pt</string>
-						</dict>
-						<dict>
-							<key>ContentConfiguration</key>
-							<dict>
-								<key>PBXProjectModuleGUID</key>
-								<string>1CA1AED706398EBD00589147</string>
-								<key>PBXProjectModuleLabel</key>
-								<string>Detail</string>
-							</dict>
-							<key>GeometryConfiguration</key>
-							<dict>
-								<key>Frame</key>
-								<string>{{190, 0}, {554, 368}}</string>
-								<key>RubberWindowFrame</key>
-								<string>315 424 744 409 0 0 1440 878 </string>
-							</dict>
-							<key>Module</key>
-							<string>XCDetailModule</string>
-							<key>Proportion</key>
-							<string>554pt</string>
-						</dict>
-					</array>
-					<key>Proportion</key>
-					<string>368pt</string>
-				</dict>
-			</array>
-			<key>MajorVersion</key>
-			<integer>2</integer>
-			<key>MinorVersion</key>
-			<integer>0</integer>
-			<key>Name</key>
-			<string>Breakpoints</string>
-			<key>ServiceClasses</key>
-			<array>
-				<string>PBXSmartGroupTreeModule</string>
-				<string>XCDetailModule</string>
-			</array>
-			<key>StatusbarIsVisible</key>
-			<integer>1</integer>
-			<key>TableOfContents</key>
-			<array>
-				<string>1CDDB66807F98D9800BB5817</string>
-				<string>1CDDB66907F98D9800BB5817</string>
-				<string>1CE0B1FE06471DED0097A5F4</string>
-				<string>1CA1AED706398EBD00589147</string>
-			</array>
-			<key>ToolbarConfiguration</key>
-			<string>xcode.toolbar.config.breakpoints</string>
-			<key>WindowString</key>
-			<string>315 424 744 409 0 0 1440 878 </string>
-			<key>WindowToolGUID</key>
-			<string>1CDDB66807F98D9800BB5817</string>
-			<key>WindowToolIsVisible</key>
-			<integer>1</integer>
-		</dict>
-		<dict>
-			<key>Identifier</key>
-			<string>windowTool.debugAnimator</string>
-			<key>Layout</key>
-			<array>
-				<dict>
-					<key>Dock</key>
-					<array>
-						<dict>
-							<key>Module</key>
-							<string>PBXNavigatorGroup</string>
-							<key>Proportion</key>
-							<string>100%</string>
-						</dict>
-					</array>
-					<key>Proportion</key>
-					<string>100%</string>
-				</dict>
-			</array>
-			<key>Name</key>
-			<string>Debug Visualizer</string>
-			<key>ServiceClasses</key>
-			<array>
-				<string>PBXNavigatorGroup</string>
-			</array>
-			<key>StatusbarIsVisible</key>
-			<integer>1</integer>
-			<key>ToolbarConfiguration</key>
-			<string>xcode.toolbar.config.debugAnimator</string>
-			<key>WindowString</key>
-			<string>100 100 700 500 0 0 1280 1002 </string>
-		</dict>
-		<dict>
-			<key>Identifier</key>
-			<string>windowTool.bookmarks</string>
-			<key>Layout</key>
-			<array>
-				<dict>
-					<key>Dock</key>
-					<array>
-						<dict>
-							<key>Module</key>
-							<string>PBXBookmarksModule</string>
-							<key>Proportion</key>
-							<string>100%</string>
-						</dict>
-					</array>
-					<key>Proportion</key>
-					<string>100%</string>
-				</dict>
-			</array>
-			<key>Name</key>
-			<string>Bookmarks</string>
-			<key>ServiceClasses</key>
-			<array>
-				<string>PBXBookmarksModule</string>
-			</array>
-			<key>StatusbarIsVisible</key>
-			<integer>0</integer>
-			<key>WindowString</key>
-			<string>538 42 401 187 0 0 1280 1002 </string>
-		</dict>
-		<dict>
-			<key>Identifier</key>
-			<string>windowTool.classBrowser</string>
-			<key>Layout</key>
-			<array>
-				<dict>
-					<key>Dock</key>
-					<array>
-						<dict>
-							<key>BecomeActive</key>
-							<integer>1</integer>
-							<key>ContentConfiguration</key>
-							<dict>
-								<key>OptionsSetName</key>
-								<string>Hierarchy, all classes</string>
-								<key>PBXProjectModuleGUID</key>
-								<string>1CA6456E063B45B4001379D8</string>
-								<key>PBXProjectModuleLabel</key>
-								<string>Class Browser - NSObject</string>
-							</dict>
-							<key>GeometryConfiguration</key>
-							<dict>
-								<key>ClassesFrame</key>
-								<string>{{0, 0}, {374, 96}}</string>
-								<key>ClassesTreeTableConfiguration</key>
-								<array>
-									<string>PBXClassNameColumnIdentifier</string>
-									<real>208</real>
-									<string>PBXClassBookColumnIdentifier</string>
-									<real>22</real>
-								</array>
-								<key>Frame</key>
-								<string>{{0, 0}, {630, 331}}</string>
-								<key>MembersFrame</key>
-								<string>{{0, 105}, {374, 395}}</string>
-								<key>MembersTreeTableConfiguration</key>
-								<array>
-									<string>PBXMemberTypeIconColumnIdentifier</string>
-									<real>22</real>
-									<string>PBXMemberNameColumnIdentifier</string>
-									<real>216</real>
-									<string>PBXMemberTypeColumnIdentifier</string>
-									<real>97</real>
-									<string>PBXMemberBookColumnIdentifier</string>
-									<real>22</real>
-								</array>
-								<key>PBXModuleWindowStatusBarHidden2</key>
-								<integer>1</integer>
-								<key>RubberWindowFrame</key>
-								<string>385 179 630 352 0 0 1440 878 </string>
-							</dict>
-							<key>Module</key>
-							<string>PBXClassBrowserModule</string>
-							<key>Proportion</key>
-							<string>332pt</string>
-						</dict>
-					</array>
-					<key>Proportion</key>
-					<string>332pt</string>
-				</dict>
-			</array>
-			<key>Name</key>
-			<string>Class Browser</string>
-			<key>ServiceClasses</key>
-			<array>
-				<string>PBXClassBrowserModule</string>
-			</array>
-			<key>StatusbarIsVisible</key>
-			<integer>0</integer>
-			<key>TableOfContents</key>
-			<array>
-				<string>1C0AD2AF069F1E9B00FABCE6</string>
-				<string>1C0AD2B0069F1E9B00FABCE6</string>
-				<string>1CA6456E063B45B4001379D8</string>
-			</array>
-			<key>ToolbarConfiguration</key>
-			<string>xcode.toolbar.config.classbrowser</string>
-			<key>WindowString</key>
-			<string>385 179 630 352 0 0 1440 878 </string>
-			<key>WindowToolGUID</key>
-			<string>1C0AD2AF069F1E9B00FABCE6</string>
-			<key>WindowToolIsVisible</key>
-			<integer>0</integer>
-		</dict>
-	</array>
-</dict>
-</plist>
diff --git a/tclxml-3.2/macosx/Tclxml.xcodeproj/steve.mode1v3 b/tclxml-3.2/macosx/Tclxml.xcodeproj/steve.mode1v3
deleted file mode 100644
index 1961331..0000000
--- a/tclxml-3.2/macosx/Tclxml.xcodeproj/steve.mode1v3
+++ /dev/null
@@ -1,1376 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
-<plist version="1.0">
-<dict>
-	<key>ActivePerspectiveName</key>
-	<string>Project</string>
-	<key>AllowedModules</key>
-	<array>
-		<dict>
-			<key>BundleLoadPath</key>
-			<string></string>
-			<key>MaxInstances</key>
-			<string>n</string>
-			<key>Module</key>
-			<string>PBXSmartGroupTreeModule</string>
-			<key>Name</key>
-			<string>Groups and Files Outline View</string>
-		</dict>
-		<dict>
-			<key>BundleLoadPath</key>
-			<string></string>
-			<key>MaxInstances</key>
-			<string>n</string>
-			<key>Module</key>
-			<string>PBXNavigatorGroup</string>
-			<key>Name</key>
-			<string>Editor</string>
-		</dict>
-		<dict>
-			<key>BundleLoadPath</key>
-			<string></string>
-			<key>MaxInstances</key>
-			<string>n</string>
-			<key>Module</key>
-			<string>XCTaskListModule</string>
-			<key>Name</key>
-			<string>Task List</string>
-		</dict>
-		<dict>
-			<key>BundleLoadPath</key>
-			<string></string>
-			<key>MaxInstances</key>
-			<string>n</string>
-			<key>Module</key>
-			<string>XCDetailModule</string>
-			<key>Name</key>
-			<string>File and Smart Group Detail Viewer</string>
-		</dict>
-		<dict>
-			<key>BundleLoadPath</key>
-			<string></string>
-			<key>MaxInstances</key>
-			<string>1</string>
-			<key>Module</key>
-			<string>PBXBuildResultsModule</string>
-			<key>Name</key>
-			<string>Detailed Build Results Viewer</string>
-		</dict>
-		<dict>
-			<key>BundleLoadPath</key>
-			<string></string>
-			<key>MaxInstances</key>
-			<string>1</string>
-			<key>Module</key>
-			<string>PBXProjectFindModule</string>
-			<key>Name</key>
-			<string>Project Batch Find Tool</string>
-		</dict>
-		<dict>
-			<key>BundleLoadPath</key>
-			<string></string>
-			<key>MaxInstances</key>
-			<string>n</string>
-			<key>Module</key>
-			<string>XCProjectFormatConflictsModule</string>
-			<key>Name</key>
-			<string>Project Format Conflicts List</string>
-		</dict>
-		<dict>
-			<key>BundleLoadPath</key>
-			<string></string>
-			<key>MaxInstances</key>
-			<string>n</string>
-			<key>Module</key>
-			<string>PBXBookmarksModule</string>
-			<key>Name</key>
-			<string>Bookmarks Tool</string>
-		</dict>
-		<dict>
-			<key>BundleLoadPath</key>
-			<string></string>
-			<key>MaxInstances</key>
-			<string>n</string>
-			<key>Module</key>
-			<string>PBXClassBrowserModule</string>
-			<key>Name</key>
-			<string>Class Browser</string>
-		</dict>
-		<dict>
-			<key>BundleLoadPath</key>
-			<string></string>
-			<key>MaxInstances</key>
-			<string>n</string>
-			<key>Module</key>
-			<string>PBXCVSModule</string>
-			<key>Name</key>
-			<string>Source Code Control Tool</string>
-		</dict>
-		<dict>
-			<key>BundleLoadPath</key>
-			<string></string>
-			<key>MaxInstances</key>
-			<string>n</string>
-			<key>Module</key>
-			<string>PBXDebugBreakpointsModule</string>
-			<key>Name</key>
-			<string>Debug Breakpoints Tool</string>
-		</dict>
-		<dict>
-			<key>BundleLoadPath</key>
-			<string></string>
-			<key>MaxInstances</key>
-			<string>n</string>
-			<key>Module</key>
-			<string>XCDockableInspector</string>
-			<key>Name</key>
-			<string>Inspector</string>
-		</dict>
-		<dict>
-			<key>BundleLoadPath</key>
-			<string></string>
-			<key>MaxInstances</key>
-			<string>n</string>
-			<key>Module</key>
-			<string>PBXOpenQuicklyModule</string>
-			<key>Name</key>
-			<string>Open Quickly Tool</string>
-		</dict>
-		<dict>
-			<key>BundleLoadPath</key>
-			<string></string>
-			<key>MaxInstances</key>
-			<string>1</string>
-			<key>Module</key>
-			<string>PBXDebugSessionModule</string>
-			<key>Name</key>
-			<string>Debugger</string>
-		</dict>
-		<dict>
-			<key>BundleLoadPath</key>
-			<string></string>
-			<key>MaxInstances</key>
-			<string>1</string>
-			<key>Module</key>
-			<string>PBXDebugCLIModule</string>
-			<key>Name</key>
-			<string>Debug Console</string>
-		</dict>
-		<dict>
-			<key>BundleLoadPath</key>
-			<string></string>
-			<key>MaxInstances</key>
-			<string>n</string>
-			<key>Module</key>
-			<string>XCSnapshotModule</string>
-			<key>Name</key>
-			<string>Snapshots Tool</string>
-		</dict>
-	</array>
-	<key>Description</key>
-	<string>DefaultDescriptionKey</string>
-	<key>DockingSystemVisible</key>
-	<false/>
-	<key>Extension</key>
-	<string>mode1v3</string>
-	<key>FavBarConfig</key>
-	<dict>
-		<key>PBXProjectModuleGUID</key>
-		<string>AA3A6C2E0DBBE97E0042AA78</string>
-		<key>XCBarModuleItemNames</key>
-		<dict/>
-		<key>XCBarModuleItems</key>
-		<array/>
-	</dict>
-	<key>FirstTimeWindowDisplayed</key>
-	<false/>
-	<key>Identifier</key>
-	<string>com.apple.perspectives.project.mode1v3</string>
-	<key>MajorVersion</key>
-	<integer>33</integer>
-	<key>MinorVersion</key>
-	<integer>0</integer>
-	<key>Name</key>
-	<string>Default</string>
-	<key>Notifications</key>
-	<array/>
-	<key>OpenEditors</key>
-	<array/>
-	<key>PerspectiveWidths</key>
-	<array>
-		<integer>-1</integer>
-		<integer>-1</integer>
-	</array>
-	<key>Perspectives</key>
-	<array>
-		<dict>
-			<key>ChosenToolbarItems</key>
-			<array>
-				<string>active-target-popup</string>
-				<string>active-buildstyle-popup</string>
-				<string>action</string>
-				<string>NSToolbarFlexibleSpaceItem</string>
-				<string>buildOrClean</string>
-				<string>build-and-goOrGo</string>
-				<string>com.apple.ide.PBXToolbarStopButton</string>
-				<string>get-info</string>
-				<string>toggle-editor</string>
-				<string>NSToolbarFlexibleSpaceItem</string>
-				<string>com.apple.pbx.toolbar.searchfield</string>
-			</array>
-			<key>ControllerClassBaseName</key>
-			<string></string>
-			<key>IconName</key>
-			<string>WindowOfProjectWithEditor</string>
-			<key>Identifier</key>
-			<string>perspective.project</string>
-			<key>IsVertical</key>
-			<false/>
-			<key>Layout</key>
-			<array>
-				<dict>
-					<key>BecomeActive</key>
-					<true/>
-					<key>ContentConfiguration</key>
-					<dict>
-						<key>PBXBottomSmartGroupGIDs</key>
-						<array>
-							<string>1C37FBAC04509CD000000102</string>
-							<string>1C37FAAC04509CD000000102</string>
-							<string>1C08E77C0454961000C914BD</string>
-							<string>1C37FABC05509CD000000102</string>
-							<string>1C37FABC05539CD112110102</string>
-							<string>E2644B35053B69B200211256</string>
-							<string>1C37FABC04509CD000100104</string>
-							<string>1CC0EA4004350EF90044410B</string>
-							<string>1CC0EA4004350EF90041110B</string>
-						</array>
-						<key>PBXProjectModuleGUID</key>
-						<string>1CE0B1FE06471DED0097A5F4</string>
-						<key>PBXProjectModuleLabel</key>
-						<string>Files</string>
-						<key>PBXProjectStructureProvided</key>
-						<string>yes</string>
-						<key>PBXSmartGroupTreeModuleColumnData</key>
-						<dict>
-							<key>PBXSmartGroupTreeModuleColumnWidthsKey</key>
-							<array>
-								<real>212</real>
-							</array>
-							<key>PBXSmartGroupTreeModuleColumnsKey_v4</key>
-							<array>
-								<string>MainColumn</string>
-							</array>
-						</dict>
-						<key>PBXSmartGroupTreeModuleOutlineStateKey_v7</key>
-						<dict>
-							<key>PBXSmartGroupTreeModuleOutlineStateExpansionKey</key>
-							<array>
-								<string>0867D691FE84028FC02AAC07</string>
-								<string>1C37FBAC04509CD000000102</string>
-								<string>AAE7C6180EDA71940093ECDD</string>
-								<string>1C37FABC05509CD000000102</string>
-							</array>
-							<key>PBXSmartGroupTreeModuleOutlineStateSelectionKey</key>
-							<array>
-								<array>
-									<integer>12</integer>
-									<integer>11</integer>
-									<integer>10</integer>
-								</array>
-							</array>
-							<key>PBXSmartGroupTreeModuleOutlineStateVisibleRectKey</key>
-							<string>{{0, 0}, {212, 697}}</string>
-						</dict>
-						<key>PBXTopSmartGroupGIDs</key>
-						<array/>
-						<key>XCIncludePerspectivesSwitch</key>
-						<true/>
-						<key>XCSharingToken</key>
-						<string>com.apple.Xcode.GFSharingToken</string>
-					</dict>
-					<key>GeometryConfiguration</key>
-					<dict>
-						<key>Frame</key>
-						<string>{{0, 0}, {229, 715}}</string>
-						<key>GroupTreeTableConfiguration</key>
-						<array>
-							<string>MainColumn</string>
-							<real>212</real>
-						</array>
-						<key>RubberWindowFrame</key>
-						<string>2 122 771 756 0 0 1440 878 </string>
-					</dict>
-					<key>Module</key>
-					<string>PBXSmartGroupTreeModule</string>
-					<key>Proportion</key>
-					<string>229pt</string>
-				</dict>
-				<dict>
-					<key>Dock</key>
-					<array>
-						<dict>
-							<key>ContentConfiguration</key>
-							<dict>
-								<key>PBXProjectModuleGUID</key>
-								<string>1CE0B20306471E060097A5F4</string>
-								<key>PBXProjectModuleLabel</key>
-								<string>MyNewFile14.java</string>
-								<key>PBXSplitModuleInNavigatorKey</key>
-								<dict>
-									<key>Split0</key>
-									<dict>
-										<key>PBXProjectModuleGUID</key>
-										<string>1CE0B20406471E060097A5F4</string>
-										<key>PBXProjectModuleLabel</key>
-										<string>MyNewFile14.java</string>
-									</dict>
-									<key>SplitCount</key>
-									<string>1</string>
-								</dict>
-								<key>StatusBarVisibility</key>
-								<true/>
-							</dict>
-							<key>GeometryConfiguration</key>
-							<dict>
-								<key>Frame</key>
-								<string>{{0, 0}, {537, 0}}</string>
-								<key>RubberWindowFrame</key>
-								<string>2 122 771 756 0 0 1440 878 </string>
-							</dict>
-							<key>Module</key>
-							<string>PBXNavigatorGroup</string>
-							<key>Proportion</key>
-							<string>0pt</string>
-						</dict>
-						<dict>
-							<key>ContentConfiguration</key>
-							<dict>
-								<key>PBXProjectModuleGUID</key>
-								<string>1CE0B20506471E060097A5F4</string>
-								<key>PBXProjectModuleLabel</key>
-								<string>Detail</string>
-							</dict>
-							<key>GeometryConfiguration</key>
-							<dict>
-								<key>Frame</key>
-								<string>{{0, 5}, {537, 710}}</string>
-								<key>RubberWindowFrame</key>
-								<string>2 122 771 756 0 0 1440 878 </string>
-							</dict>
-							<key>Module</key>
-							<string>XCDetailModule</string>
-							<key>Proportion</key>
-							<string>710pt</string>
-						</dict>
-					</array>
-					<key>Proportion</key>
-					<string>537pt</string>
-				</dict>
-			</array>
-			<key>Name</key>
-			<string>Project</string>
-			<key>ServiceClasses</key>
-			<array>
-				<string>XCModuleDock</string>
-				<string>PBXSmartGroupTreeModule</string>
-				<string>XCModuleDock</string>
-				<string>PBXNavigatorGroup</string>
-				<string>XCDetailModule</string>
-			</array>
-			<key>TableOfContents</key>
-			<array>
-				<string>AAE7C6190EDA71940093ECDD</string>
-				<string>1CE0B1FE06471DED0097A5F4</string>
-				<string>AAE7C61A0EDA71940093ECDD</string>
-				<string>1CE0B20306471E060097A5F4</string>
-				<string>1CE0B20506471E060097A5F4</string>
-			</array>
-			<key>ToolbarConfiguration</key>
-			<string>xcode.toolbar.config.defaultV3</string>
-		</dict>
-		<dict>
-			<key>ControllerClassBaseName</key>
-			<string></string>
-			<key>IconName</key>
-			<string>WindowOfProject</string>
-			<key>Identifier</key>
-			<string>perspective.morph</string>
-			<key>IsVertical</key>
-			<false/>
-			<key>Layout</key>
-			<array>
-				<dict>
-					<key>BecomeActive</key>
-					<integer>1</integer>
-					<key>ContentConfiguration</key>
-					<dict>
-						<key>PBXBottomSmartGroupGIDs</key>
-						<array>
-							<string>1C37FBAC04509CD000000102</string>
-							<string>1C37FAAC04509CD000000102</string>
-							<string>1C08E77C0454961000C914BD</string>
-							<string>1C37FABC05509CD000000102</string>
-							<string>1C37FABC05539CD112110102</string>
-							<string>E2644B35053B69B200211256</string>
-							<string>1C37FABC04509CD000100104</string>
-							<string>1CC0EA4004350EF90044410B</string>
-							<string>1CC0EA4004350EF90041110B</string>
-						</array>
-						<key>PBXProjectModuleGUID</key>
-						<string>11E0B1FE06471DED0097A5F4</string>
-						<key>PBXProjectModuleLabel</key>
-						<string>Files</string>
-						<key>PBXProjectStructureProvided</key>
-						<string>yes</string>
-						<key>PBXSmartGroupTreeModuleColumnData</key>
-						<dict>
-							<key>PBXSmartGroupTreeModuleColumnWidthsKey</key>
-							<array>
-								<real>186</real>
-							</array>
-							<key>PBXSmartGroupTreeModuleColumnsKey_v4</key>
-							<array>
-								<string>MainColumn</string>
-							</array>
-						</dict>
-						<key>PBXSmartGroupTreeModuleOutlineStateKey_v7</key>
-						<dict>
-							<key>PBXSmartGroupTreeModuleOutlineStateExpansionKey</key>
-							<array>
-								<string>29B97314FDCFA39411CA2CEA</string>
-								<string>1C37FABC05509CD000000102</string>
-							</array>
-							<key>PBXSmartGroupTreeModuleOutlineStateSelectionKey</key>
-							<array>
-								<array>
-									<integer>0</integer>
-								</array>
-							</array>
-							<key>PBXSmartGroupTreeModuleOutlineStateVisibleRectKey</key>
-							<string>{{0, 0}, {186, 337}}</string>
-						</dict>
-						<key>PBXTopSmartGroupGIDs</key>
-						<array/>
-						<key>XCIncludePerspectivesSwitch</key>
-						<integer>1</integer>
-						<key>XCSharingToken</key>
-						<string>com.apple.Xcode.GFSharingToken</string>
-					</dict>
-					<key>GeometryConfiguration</key>
-					<dict>
-						<key>Frame</key>
-						<string>{{0, 0}, {203, 355}}</string>
-						<key>GroupTreeTableConfiguration</key>
-						<array>
-							<string>MainColumn</string>
-							<real>186</real>
-						</array>
-						<key>RubberWindowFrame</key>
-						<string>373 269 690 397 0 0 1440 878 </string>
-					</dict>
-					<key>Module</key>
-					<string>PBXSmartGroupTreeModule</string>
-					<key>Proportion</key>
-					<string>100%</string>
-				</dict>
-			</array>
-			<key>Name</key>
-			<string>Morph</string>
-			<key>PreferredWidth</key>
-			<integer>300</integer>
-			<key>ServiceClasses</key>
-			<array>
-				<string>XCModuleDock</string>
-				<string>PBXSmartGroupTreeModule</string>
-			</array>
-			<key>TableOfContents</key>
-			<array>
-				<string>11E0B1FE06471DED0097A5F4</string>
-			</array>
-			<key>ToolbarConfiguration</key>
-			<string>xcode.toolbar.config.default.shortV3</string>
-		</dict>
-	</array>
-	<key>PerspectivesBarVisible</key>
-	<false/>
-	<key>ShelfIsVisible</key>
-	<false/>
-	<key>StatusbarIsVisible</key>
-	<true/>
-	<key>TimeStamp</key>
-	<real>0.0</real>
-	<key>ToolbarDisplayMode</key>
-	<integer>1</integer>
-	<key>ToolbarIsVisible</key>
-	<true/>
-	<key>ToolbarSizeMode</key>
-	<integer>1</integer>
-	<key>Type</key>
-	<string>Perspectives</string>
-	<key>UpdateMessage</key>
-	<string>The Default Workspace in this version of Xcode now includes support to hide and show the detail view (what has been referred to as the "Metro-Morph" feature).  You must discard your current Default Workspace settings and update to the latest Default Workspace in order to gain this feature.  Do you wish to update to the latest Workspace defaults for project '%@'?</string>
-	<key>WindowJustification</key>
-	<integer>5</integer>
-	<key>WindowOrderList</key>
-	<array>
-		<string>AAE9E0620DC0626100A29434</string>
-		<string>/Users/steve/Projects/tclxml-3.2/macosx/Tclxml.xcodeproj</string>
-	</array>
-	<key>WindowString</key>
-	<string>2 122 771 756 0 0 1440 878 </string>
-	<key>WindowToolsV3</key>
-	<array>
-		<dict>
-			<key>FirstTimeWindowDisplayed</key>
-			<false/>
-			<key>Identifier</key>
-			<string>windowTool.build</string>
-			<key>IsVertical</key>
-			<true/>
-			<key>Layout</key>
-			<array>
-				<dict>
-					<key>Dock</key>
-					<array>
-						<dict>
-							<key>ContentConfiguration</key>
-							<dict>
-								<key>PBXProjectModuleGUID</key>
-								<string>1CD0528F0623707200166675</string>
-								<key>PBXProjectModuleLabel</key>
-								<string></string>
-								<key>StatusBarVisibility</key>
-								<true/>
-							</dict>
-							<key>GeometryConfiguration</key>
-							<dict>
-								<key>Frame</key>
-								<string>{{0, 0}, {622, 0}}</string>
-								<key>RubberWindowFrame</key>
-								<string>681 139 622 739 0 0 1440 878 </string>
-							</dict>
-							<key>Module</key>
-							<string>PBXNavigatorGroup</string>
-							<key>Proportion</key>
-							<string>0pt</string>
-						</dict>
-						<dict>
-							<key>BecomeActive</key>
-							<true/>
-							<key>ContentConfiguration</key>
-							<dict>
-								<key>PBXBuildLogShowsTranscriptDefaultKey</key>
-								<string>{{0, 127}, {622, 566}}</string>
-								<key>PBXProjectModuleGUID</key>
-								<string>XCMainBuildResultsModuleGUID</string>
-								<key>PBXProjectModuleLabel</key>
-								<string>Build</string>
-								<key>XCBuildResultsTrigger_Collapse</key>
-								<integer>1021</integer>
-								<key>XCBuildResultsTrigger_Open</key>
-								<integer>1011</integer>
-							</dict>
-							<key>GeometryConfiguration</key>
-							<dict>
-								<key>Frame</key>
-								<string>{{0, 5}, {622, 693}}</string>
-								<key>RubberWindowFrame</key>
-								<string>681 139 622 739 0 0 1440 878 </string>
-							</dict>
-							<key>Module</key>
-							<string>PBXBuildResultsModule</string>
-							<key>Proportion</key>
-							<string>693pt</string>
-						</dict>
-					</array>
-					<key>Proportion</key>
-					<string>698pt</string>
-				</dict>
-			</array>
-			<key>Name</key>
-			<string>Build Results</string>
-			<key>ServiceClasses</key>
-			<array>
-				<string>PBXBuildResultsModule</string>
-			</array>
-			<key>StatusbarIsVisible</key>
-			<true/>
-			<key>TableOfContents</key>
-			<array>
-				<string>AAE9E0620DC0626100A29434</string>
-				<string>AAE7C61F0EDA727D0093ECDD</string>
-				<string>1CD0528F0623707200166675</string>
-				<string>XCMainBuildResultsModuleGUID</string>
-			</array>
-			<key>ToolbarConfiguration</key>
-			<string>xcode.toolbar.config.buildV3</string>
-			<key>WindowString</key>
-			<string>681 139 622 739 0 0 1440 878 </string>
-			<key>WindowToolGUID</key>
-			<string>AAE9E0620DC0626100A29434</string>
-			<key>WindowToolIsVisible</key>
-			<false/>
-		</dict>
-		<dict>
-			<key>FirstTimeWindowDisplayed</key>
-			<false/>
-			<key>Identifier</key>
-			<string>windowTool.debugger</string>
-			<key>Layout</key>
-			<array>
-				<dict>
-					<key>Dock</key>
-					<array>
-						<dict>
-							<key>ContentConfiguration</key>
-							<dict>
-								<key>Debugger</key>
-								<dict>
-									<key>HorizontalSplitView</key>
-									<dict>
-										<key>_collapsingFrameDimension</key>
-										<real>0.0</real>
-										<key>_indexOfCollapsedView</key>
-										<integer>0</integer>
-										<key>_percentageOfCollapsedView</key>
-										<real>0.0</real>
-										<key>isCollapsed</key>
-										<string>yes</string>
-										<key>sizes</key>
-										<array>
-											<string>{{0, 0}, {317, 164}}</string>
-											<string>{{317, 0}, {377, 164}}</string>
-										</array>
-									</dict>
-									<key>VerticalSplitView</key>
-									<dict>
-										<key>_collapsingFrameDimension</key>
-										<real>0.0</real>
-										<key>_indexOfCollapsedView</key>
-										<integer>0</integer>
-										<key>_percentageOfCollapsedView</key>
-										<real>0.0</real>
-										<key>isCollapsed</key>
-										<string>yes</string>
-										<key>sizes</key>
-										<array>
-											<string>{{0, 0}, {694, 164}}</string>
-											<string>{{0, 164}, {694, 216}}</string>
-										</array>
-									</dict>
-								</dict>
-								<key>LauncherConfigVersion</key>
-								<string>8</string>
-								<key>PBXProjectModuleGUID</key>
-								<string>1C162984064C10D400B95A72</string>
-								<key>PBXProjectModuleLabel</key>
-								<string>Debug - GLUTExamples (Underwater)</string>
-							</dict>
-							<key>GeometryConfiguration</key>
-							<dict>
-								<key>DebugConsoleDrawerSize</key>
-								<string>{100, 120}</string>
-								<key>DebugConsoleVisible</key>
-								<string>None</string>
-								<key>DebugConsoleWindowFrame</key>
-								<string>{{200, 200}, {500, 300}}</string>
-								<key>DebugSTDIOWindowFrame</key>
-								<string>{{200, 200}, {500, 300}}</string>
-								<key>Frame</key>
-								<string>{{0, 0}, {694, 380}}</string>
-								<key>RubberWindowFrame</key>
-								<string>321 238 694 422 0 0 1440 878 </string>
-							</dict>
-							<key>Module</key>
-							<string>PBXDebugSessionModule</string>
-							<key>Proportion</key>
-							<string>100%</string>
-						</dict>
-					</array>
-					<key>Proportion</key>
-					<string>100%</string>
-				</dict>
-			</array>
-			<key>Name</key>
-			<string>Debugger</string>
-			<key>ServiceClasses</key>
-			<array>
-				<string>PBXDebugSessionModule</string>
-			</array>
-			<key>StatusbarIsVisible</key>
-			<true/>
-			<key>TableOfContents</key>
-			<array>
-				<string>1CD10A99069EF8BA00B06720</string>
-				<string>1C0AD2AB069F1E9B00FABCE6</string>
-				<string>1C162984064C10D400B95A72</string>
-				<string>1C0AD2AC069F1E9B00FABCE6</string>
-			</array>
-			<key>ToolbarConfiguration</key>
-			<string>xcode.toolbar.config.debugV3</string>
-			<key>WindowString</key>
-			<string>321 238 694 422 0 0 1440 878 </string>
-			<key>WindowToolGUID</key>
-			<string>1CD10A99069EF8BA00B06720</string>
-			<key>WindowToolIsVisible</key>
-			<false/>
-		</dict>
-		<dict>
-			<key>FirstTimeWindowDisplayed</key>
-			<false/>
-			<key>Identifier</key>
-			<string>windowTool.find</string>
-			<key>Layout</key>
-			<array>
-				<dict>
-					<key>Dock</key>
-					<array>
-						<dict>
-							<key>Dock</key>
-							<array>
-								<dict>
-									<key>ContentConfiguration</key>
-									<dict>
-										<key>PBXProjectModuleGUID</key>
-										<string>1CDD528C0622207200134675</string>
-										<key>PBXProjectModuleLabel</key>
-										<string><No Editor></string>
-										<key>PBXSplitModuleInNavigatorKey</key>
-										<dict>
-											<key>Split0</key>
-											<dict>
-												<key>PBXProjectModuleGUID</key>
-												<string>1CD0528D0623707200166675</string>
-											</dict>
-											<key>SplitCount</key>
-											<string>1</string>
-										</dict>
-										<key>StatusBarVisibility</key>
-										<integer>1</integer>
-									</dict>
-									<key>GeometryConfiguration</key>
-									<dict>
-										<key>Frame</key>
-										<string>{{0, 0}, {781, 167}}</string>
-										<key>RubberWindowFrame</key>
-										<string>62 385 781 470 0 0 1440 878 </string>
-									</dict>
-									<key>Module</key>
-									<string>PBXNavigatorGroup</string>
-									<key>Proportion</key>
-									<string>781pt</string>
-								</dict>
-							</array>
-							<key>Proportion</key>
-							<string>50%</string>
-						</dict>
-						<dict>
-							<key>BecomeActive</key>
-							<integer>1</integer>
-							<key>ContentConfiguration</key>
-							<dict>
-								<key>PBXProjectModuleGUID</key>
-								<string>1CD0528E0623707200166675</string>
-								<key>PBXProjectModuleLabel</key>
-								<string>Project Find</string>
-							</dict>
-							<key>GeometryConfiguration</key>
-							<dict>
-								<key>Frame</key>
-								<string>{{8, 0}, {773, 254}}</string>
-								<key>RubberWindowFrame</key>
-								<string>62 385 781 470 0 0 1440 878 </string>
-							</dict>
-							<key>Module</key>
-							<string>PBXProjectFindModule</string>
-							<key>Proportion</key>
-							<string>50%</string>
-						</dict>
-					</array>
-					<key>Proportion</key>
-					<string>428pt</string>
-				</dict>
-			</array>
-			<key>Name</key>
-			<string>Project Find</string>
-			<key>ServiceClasses</key>
-			<array>
-				<string>PBXProjectFindModule</string>
-			</array>
-			<key>StatusbarIsVisible</key>
-			<true/>
-			<key>TableOfContents</key>
-			<array>
-				<string>1C530D57069F1CE1000CFCEE</string>
-				<string>1C530D58069F1CE1000CFCEE</string>
-				<string>1C530D59069F1CE1000CFCEE</string>
-				<string>1CDD528C0622207200134675</string>
-				<string>1C530D5A069F1CE1000CFCEE</string>
-				<string>1CE0B1FE06471DED0097A5F4</string>
-				<string>1CD0528E0623707200166675</string>
-			</array>
-			<key>WindowString</key>
-			<string>62 385 781 470 0 0 1440 878 </string>
-			<key>WindowToolGUID</key>
-			<string>1C530D57069F1CE1000CFCEE</string>
-			<key>WindowToolIsVisible</key>
-			<false/>
-		</dict>
-		<dict>
-			<key>FirstTimeWindowDisplayed</key>
-			<false/>
-			<key>Identifier</key>
-			<string>MENUSEPARATOR</string>
-		</dict>
-		<dict>
-			<key>FirstTimeWindowDisplayed</key>
-			<false/>
-			<key>Identifier</key>
-			<string>windowTool.debuggerConsole</string>
-			<key>Layout</key>
-			<array>
-				<dict>
-					<key>Dock</key>
-					<array>
-						<dict>
-							<key>BecomeActive</key>
-							<integer>1</integer>
-							<key>ContentConfiguration</key>
-							<dict>
-								<key>PBXProjectModuleGUID</key>
-								<string>1C78EAAC065D492600B07095</string>
-								<key>PBXProjectModuleLabel</key>
-								<string>Debugger Console</string>
-							</dict>
-							<key>GeometryConfiguration</key>
-							<dict>
-								<key>Frame</key>
-								<string>{{0, 0}, {440, 358}}</string>
-								<key>RubberWindowFrame</key>
-								<string>650 41 440 400 0 0 1280 1002 </string>
-							</dict>
-							<key>Module</key>
-							<string>PBXDebugCLIModule</string>
-							<key>Proportion</key>
-							<string>358pt</string>
-						</dict>
-					</array>
-					<key>Proportion</key>
-					<string>358pt</string>
-				</dict>
-			</array>
-			<key>Name</key>
-			<string>Debugger Console</string>
-			<key>ServiceClasses</key>
-			<array>
-				<string>PBXDebugCLIModule</string>
-			</array>
-			<key>StatusbarIsVisible</key>
-			<true/>
-			<key>TableOfContents</key>
-			<array>
-				<string>1C78EAAD065D492600B07095</string>
-				<string>1C78EAAE065D492600B07095</string>
-				<string>1C78EAAC065D492600B07095</string>
-			</array>
-			<key>ToolbarConfiguration</key>
-			<string>xcode.toolbar.config.consoleV3</string>
-			<key>WindowString</key>
-			<string>650 41 440 400 0 0 1280 1002 </string>
-			<key>WindowToolGUID</key>
-			<string>1C78EAAD065D492600B07095</string>
-			<key>WindowToolIsVisible</key>
-			<false/>
-		</dict>
-		<dict>
-			<key>Identifier</key>
-			<string>windowTool.snapshots</string>
-			<key>Layout</key>
-			<array>
-				<dict>
-					<key>Dock</key>
-					<array>
-						<dict>
-							<key>Module</key>
-							<string>XCSnapshotModule</string>
-							<key>Proportion</key>
-							<string>100%</string>
-						</dict>
-					</array>
-					<key>Proportion</key>
-					<string>100%</string>
-				</dict>
-			</array>
-			<key>Name</key>
-			<string>Snapshots</string>
-			<key>ServiceClasses</key>
-			<array>
-				<string>XCSnapshotModule</string>
-			</array>
-			<key>StatusbarIsVisible</key>
-			<string>Yes</string>
-			<key>ToolbarConfiguration</key>
-			<string>xcode.toolbar.config.snapshots</string>
-			<key>WindowString</key>
-			<string>315 824 300 550 0 0 1440 878 </string>
-			<key>WindowToolIsVisible</key>
-			<string>Yes</string>
-		</dict>
-		<dict>
-			<key>FirstTimeWindowDisplayed</key>
-			<false/>
-			<key>Identifier</key>
-			<string>windowTool.scm</string>
-			<key>Layout</key>
-			<array>
-				<dict>
-					<key>Dock</key>
-					<array>
-						<dict>
-							<key>ContentConfiguration</key>
-							<dict>
-								<key>PBXProjectModuleGUID</key>
-								<string>1C78EAB2065D492600B07095</string>
-								<key>PBXProjectModuleLabel</key>
-								<string><No Editor></string>
-								<key>PBXSplitModuleInNavigatorKey</key>
-								<dict>
-									<key>Split0</key>
-									<dict>
-										<key>PBXProjectModuleGUID</key>
-										<string>1C78EAB3065D492600B07095</string>
-									</dict>
-									<key>SplitCount</key>
-									<string>1</string>
-								</dict>
-								<key>StatusBarVisibility</key>
-								<integer>1</integer>
-							</dict>
-							<key>GeometryConfiguration</key>
-							<dict>
-								<key>Frame</key>
-								<string>{{0, 0}, {452, 0}}</string>
-								<key>RubberWindowFrame</key>
-								<string>743 379 452 308 0 0 1280 1002 </string>
-							</dict>
-							<key>Module</key>
-							<string>PBXNavigatorGroup</string>
-							<key>Proportion</key>
-							<string>0pt</string>
-						</dict>
-						<dict>
-							<key>BecomeActive</key>
-							<integer>1</integer>
-							<key>ContentConfiguration</key>
-							<dict>
-								<key>PBXProjectModuleGUID</key>
-								<string>1CD052920623707200166675</string>
-								<key>PBXProjectModuleLabel</key>
-								<string>SCM</string>
-							</dict>
-							<key>GeometryConfiguration</key>
-							<dict>
-								<key>ConsoleFrame</key>
-								<string>{{0, 259}, {452, 0}}</string>
-								<key>Frame</key>
-								<string>{{0, 7}, {452, 259}}</string>
-								<key>RubberWindowFrame</key>
-								<string>743 379 452 308 0 0 1280 1002 </string>
-								<key>TableConfiguration</key>
-								<array>
-									<string>Status</string>
-									<real>30</real>
-									<string>FileName</string>
-									<real>199</real>
-									<string>Path</string>
-									<real>197.09500122070312</real>
-								</array>
-								<key>TableFrame</key>
-								<string>{{0, 0}, {452, 250}}</string>
-							</dict>
-							<key>Module</key>
-							<string>PBXCVSModule</string>
-							<key>Proportion</key>
-							<string>262pt</string>
-						</dict>
-					</array>
-					<key>Proportion</key>
-					<string>266pt</string>
-				</dict>
-			</array>
-			<key>Name</key>
-			<string>SCM</string>
-			<key>ServiceClasses</key>
-			<array>
-				<string>PBXCVSModule</string>
-			</array>
-			<key>StatusbarIsVisible</key>
-			<true/>
-			<key>TableOfContents</key>
-			<array>
-				<string>1C78EAB4065D492600B07095</string>
-				<string>1C78EAB5065D492600B07095</string>
-				<string>1C78EAB2065D492600B07095</string>
-				<string>1CD052920623707200166675</string>
-			</array>
-			<key>ToolbarConfiguration</key>
-			<string>xcode.toolbar.config.scm</string>
-			<key>WindowString</key>
-			<string>743 379 452 308 0 0 1280 1002 </string>
-		</dict>
-		<dict>
-			<key>FirstTimeWindowDisplayed</key>
-			<false/>
-			<key>Identifier</key>
-			<string>windowTool.breakpoints</string>
-			<key>IsVertical</key>
-			<false/>
-			<key>Layout</key>
-			<array>
-				<dict>
-					<key>Dock</key>
-					<array>
-						<dict>
-							<key>BecomeActive</key>
-							<integer>1</integer>
-							<key>ContentConfiguration</key>
-							<dict>
-								<key>PBXBottomSmartGroupGIDs</key>
-								<array>
-									<string>1C77FABC04509CD000000102</string>
-								</array>
-								<key>PBXProjectModuleGUID</key>
-								<string>1CE0B1FE06471DED0097A5F4</string>
-								<key>PBXProjectModuleLabel</key>
-								<string>Files</string>
-								<key>PBXProjectStructureProvided</key>
-								<string>no</string>
-								<key>PBXSmartGroupTreeModuleColumnData</key>
-								<dict>
-									<key>PBXSmartGroupTreeModuleColumnWidthsKey</key>
-									<array>
-										<real>168</real>
-									</array>
-									<key>PBXSmartGroupTreeModuleColumnsKey_v4</key>
-									<array>
-										<string>MainColumn</string>
-									</array>
-								</dict>
-								<key>PBXSmartGroupTreeModuleOutlineStateKey_v7</key>
-								<dict>
-									<key>PBXSmartGroupTreeModuleOutlineStateExpansionKey</key>
-									<array>
-										<string>1C77FABC04509CD000000102</string>
-									</array>
-									<key>PBXSmartGroupTreeModuleOutlineStateSelectionKey</key>
-									<array>
-										<array>
-											<integer>0</integer>
-										</array>
-									</array>
-									<key>PBXSmartGroupTreeModuleOutlineStateVisibleRectKey</key>
-									<string>{{0, 0}, {168, 350}}</string>
-								</dict>
-								<key>PBXTopSmartGroupGIDs</key>
-								<array/>
-								<key>XCIncludePerspectivesSwitch</key>
-								<integer>0</integer>
-							</dict>
-							<key>GeometryConfiguration</key>
-							<dict>
-								<key>Frame</key>
-								<string>{{0, 0}, {185, 368}}</string>
-								<key>GroupTreeTableConfiguration</key>
-								<array>
-									<string>MainColumn</string>
-									<real>168</real>
-								</array>
-								<key>RubberWindowFrame</key>
-								<string>315 424 744 409 0 0 1440 878 </string>
-							</dict>
-							<key>Module</key>
-							<string>PBXSmartGroupTreeModule</string>
-							<key>Proportion</key>
-							<string>185pt</string>
-						</dict>
-						<dict>
-							<key>ContentConfiguration</key>
-							<dict>
-								<key>PBXProjectModuleGUID</key>
-								<string>1CA1AED706398EBD00589147</string>
-								<key>PBXProjectModuleLabel</key>
-								<string>Detail</string>
-							</dict>
-							<key>GeometryConfiguration</key>
-							<dict>
-								<key>Frame</key>
-								<string>{{190, 0}, {554, 368}}</string>
-								<key>RubberWindowFrame</key>
-								<string>315 424 744 409 0 0 1440 878 </string>
-							</dict>
-							<key>Module</key>
-							<string>XCDetailModule</string>
-							<key>Proportion</key>
-							<string>554pt</string>
-						</dict>
-					</array>
-					<key>Proportion</key>
-					<string>368pt</string>
-				</dict>
-			</array>
-			<key>MajorVersion</key>
-			<integer>3</integer>
-			<key>MinorVersion</key>
-			<integer>0</integer>
-			<key>Name</key>
-			<string>Breakpoints</string>
-			<key>ServiceClasses</key>
-			<array>
-				<string>PBXSmartGroupTreeModule</string>
-				<string>XCDetailModule</string>
-			</array>
-			<key>StatusbarIsVisible</key>
-			<true/>
-			<key>TableOfContents</key>
-			<array>
-				<string>1CDDB66807F98D9800BB5817</string>
-				<string>1CDDB66907F98D9800BB5817</string>
-				<string>1CE0B1FE06471DED0097A5F4</string>
-				<string>1CA1AED706398EBD00589147</string>
-			</array>
-			<key>ToolbarConfiguration</key>
-			<string>xcode.toolbar.config.breakpointsV3</string>
-			<key>WindowString</key>
-			<string>315 424 744 409 0 0 1440 878 </string>
-			<key>WindowToolGUID</key>
-			<string>1CDDB66807F98D9800BB5817</string>
-			<key>WindowToolIsVisible</key>
-			<true/>
-		</dict>
-		<dict>
-			<key>FirstTimeWindowDisplayed</key>
-			<false/>
-			<key>Identifier</key>
-			<string>windowTool.debugAnimator</string>
-			<key>Layout</key>
-			<array>
-				<dict>
-					<key>Dock</key>
-					<array>
-						<dict>
-							<key>Module</key>
-							<string>PBXNavigatorGroup</string>
-							<key>Proportion</key>
-							<string>100%</string>
-						</dict>
-					</array>
-					<key>Proportion</key>
-					<string>100%</string>
-				</dict>
-			</array>
-			<key>Name</key>
-			<string>Debug Visualizer</string>
-			<key>ServiceClasses</key>
-			<array>
-				<string>PBXNavigatorGroup</string>
-			</array>
-			<key>StatusbarIsVisible</key>
-			<true/>
-			<key>ToolbarConfiguration</key>
-			<string>xcode.toolbar.config.debugAnimatorV3</string>
-			<key>WindowString</key>
-			<string>100 100 700 500 0 0 1280 1002 </string>
-		</dict>
-		<dict>
-			<key>FirstTimeWindowDisplayed</key>
-			<false/>
-			<key>Identifier</key>
-			<string>windowTool.bookmarks</string>
-			<key>Layout</key>
-			<array>
-				<dict>
-					<key>Dock</key>
-					<array>
-						<dict>
-							<key>Module</key>
-							<string>PBXBookmarksModule</string>
-							<key>Proportion</key>
-							<string>100%</string>
-						</dict>
-					</array>
-					<key>Proportion</key>
-					<string>100%</string>
-				</dict>
-			</array>
-			<key>Name</key>
-			<string>Bookmarks</string>
-			<key>ServiceClasses</key>
-			<array>
-				<string>PBXBookmarksModule</string>
-			</array>
-			<key>StatusbarIsVisible</key>
-			<false/>
-			<key>WindowString</key>
-			<string>538 42 401 187 0 0 1280 1002 </string>
-		</dict>
-		<dict>
-			<key>Identifier</key>
-			<string>windowTool.projectFormatConflicts</string>
-			<key>Layout</key>
-			<array>
-				<dict>
-					<key>Dock</key>
-					<array>
-						<dict>
-							<key>Module</key>
-							<string>XCProjectFormatConflictsModule</string>
-							<key>Proportion</key>
-							<string>100%</string>
-						</dict>
-					</array>
-					<key>Proportion</key>
-					<string>100%</string>
-				</dict>
-			</array>
-			<key>Name</key>
-			<string>Project Format Conflicts</string>
-			<key>ServiceClasses</key>
-			<array>
-				<string>XCProjectFormatConflictsModule</string>
-			</array>
-			<key>StatusbarIsVisible</key>
-			<false/>
-			<key>WindowContentMinSize</key>
-			<string>450 300</string>
-			<key>WindowString</key>
-			<string>50 850 472 307 0 0 1440 877</string>
-		</dict>
-		<dict>
-			<key>FirstTimeWindowDisplayed</key>
-			<false/>
-			<key>Identifier</key>
-			<string>windowTool.classBrowser</string>
-			<key>Layout</key>
-			<array>
-				<dict>
-					<key>Dock</key>
-					<array>
-						<dict>
-							<key>BecomeActive</key>
-							<integer>1</integer>
-							<key>ContentConfiguration</key>
-							<dict>
-								<key>OptionsSetName</key>
-								<string>Hierarchy, all classes</string>
-								<key>PBXProjectModuleGUID</key>
-								<string>1CA6456E063B45B4001379D8</string>
-								<key>PBXProjectModuleLabel</key>
-								<string>Class Browser - NSObject</string>
-							</dict>
-							<key>GeometryConfiguration</key>
-							<dict>
-								<key>ClassesFrame</key>
-								<string>{{0, 0}, {374, 96}}</string>
-								<key>ClassesTreeTableConfiguration</key>
-								<array>
-									<string>PBXClassNameColumnIdentifier</string>
-									<real>208</real>
-									<string>PBXClassBookColumnIdentifier</string>
-									<real>22</real>
-								</array>
-								<key>Frame</key>
-								<string>{{0, 0}, {630, 331}}</string>
-								<key>MembersFrame</key>
-								<string>{{0, 105}, {374, 395}}</string>
-								<key>MembersTreeTableConfiguration</key>
-								<array>
-									<string>PBXMemberTypeIconColumnIdentifier</string>
-									<real>22</real>
-									<string>PBXMemberNameColumnIdentifier</string>
-									<real>216</real>
-									<string>PBXMemberTypeColumnIdentifier</string>
-									<real>97</real>
-									<string>PBXMemberBookColumnIdentifier</string>
-									<real>22</real>
-								</array>
-								<key>PBXModuleWindowStatusBarHidden2</key>
-								<integer>1</integer>
-								<key>RubberWindowFrame</key>
-								<string>385 179 630 352 0 0 1440 878 </string>
-							</dict>
-							<key>Module</key>
-							<string>PBXClassBrowserModule</string>
-							<key>Proportion</key>
-							<string>332pt</string>
-						</dict>
-					</array>
-					<key>Proportion</key>
-					<string>332pt</string>
-				</dict>
-			</array>
-			<key>Name</key>
-			<string>Class Browser</string>
-			<key>ServiceClasses</key>
-			<array>
-				<string>PBXClassBrowserModule</string>
-			</array>
-			<key>StatusbarIsVisible</key>
-			<false/>
-			<key>TableOfContents</key>
-			<array>
-				<string>1C0AD2AF069F1E9B00FABCE6</string>
-				<string>1C0AD2B0069F1E9B00FABCE6</string>
-				<string>1CA6456E063B45B4001379D8</string>
-			</array>
-			<key>ToolbarConfiguration</key>
-			<string>xcode.toolbar.config.classbrowser</string>
-			<key>WindowString</key>
-			<string>385 179 630 352 0 0 1440 878 </string>
-			<key>WindowToolGUID</key>
-			<string>1C0AD2AF069F1E9B00FABCE6</string>
-			<key>WindowToolIsVisible</key>
-			<false/>
-		</dict>
-		<dict>
-			<key>Identifier</key>
-			<string>windowTool.refactoring</string>
-			<key>IncludeInToolsMenu</key>
-			<false/>
-			<key>Layout</key>
-			<array>
-				<dict>
-					<key>Dock</key>
-					<array>
-						<dict>
-							<key>BecomeActive</key>
-							<true/>
-							<key>GeometryConfiguration</key>
-							<dict>
-								<key>Frame</key>
-								<string>{0, 0}, {500, 335}</string>
-								<key>RubberWindowFrame</key>
-								<string>{0, 0}, {500, 335}</string>
-							</dict>
-							<key>Module</key>
-							<string>XCRefactoringModule</string>
-							<key>Proportion</key>
-							<string>100%</string>
-						</dict>
-					</array>
-					<key>Proportion</key>
-					<string>100%</string>
-				</dict>
-			</array>
-			<key>Name</key>
-			<string>Refactoring</string>
-			<key>ServiceClasses</key>
-			<array>
-				<string>XCRefactoringModule</string>
-			</array>
-			<key>WindowString</key>
-			<string>200 200 500 356 0 0 1920 1200 </string>
-		</dict>
-	</array>
-</dict>
-</plist>
diff --git a/tclxml-3.2/macosx/Tclxml.xcodeproj/steve.pbxuser b/tclxml-3.2/macosx/Tclxml.xcodeproj/steve.pbxuser
deleted file mode 100644
index e76dbc3..0000000
--- a/tclxml-3.2/macosx/Tclxml.xcodeproj/steve.pbxuser
+++ /dev/null
@@ -1,215 +0,0 @@
-// !$*UTF8*$!
-{
-	0867D690FE84028FC02AAC07 /* Project object */ = {
-		activeArchitecture = i386;
-		activeBuildConfigurationName = Release;
-		activeTarget = 8DC2EF4F0486A6940098B216 /* Tclxml */;
-		addToTargets = (
-			8DC2EF4F0486A6940098B216 /* Tclxml */,
-		);
-		codeSenseManager = AA68C5710C8FA6C900D12438 /* Code sense */;
-		perUserDictionary = {
-			PBXConfiguration.PBXFileTableDataSource3.PBXExecutablesDataSource = {
-				PBXFileTableDataSourceColumnSortingDirectionKey = "-1";
-				PBXFileTableDataSourceColumnSortingKey = PBXExecutablesDataSource_NameID;
-				PBXFileTableDataSourceColumnWidthsKey = (
-					22,
-					300,
-					259.5835,
-				);
-				PBXFileTableDataSourceColumnsKey = (
-					PBXExecutablesDataSource_ActiveFlagID,
-					PBXExecutablesDataSource_NameID,
-					PBXExecutablesDataSource_CommentsID,
-				);
-			};
-			PBXConfiguration.PBXFileTableDataSource3.PBXFileTableDataSource = {
-				PBXFileTableDataSourceColumnSortingDirectionKey = "-1";
-				PBXFileTableDataSourceColumnSortingKey = PBXFileDataSource_Filename_ColumnID;
-				PBXFileTableDataSourceColumnWidthsKey = (
-					20,
-					298,
-					20,
-					48,
-					43,
-					43,
-					20,
-				);
-				PBXFileTableDataSourceColumnsKey = (
-					PBXFileDataSource_FiletypeID,
-					PBXFileDataSource_Filename_ColumnID,
-					PBXFileDataSource_Built_ColumnID,
-					PBXFileDataSource_ObjectSize_ColumnID,
-					PBXFileDataSource_Errors_ColumnID,
-					PBXFileDataSource_Warnings_ColumnID,
-					PBXFileDataSource_Target_ColumnID,
-				);
-			};
-			PBXConfiguration.PBXFileTableDataSource3.PBXSymbolsDataSource = {
-				PBXFileTableDataSourceColumnSortingDirectionKey = "-1";
-				PBXFileTableDataSourceColumnSortingKey = PBXSymbolsDataSource_SymbolNameID;
-				PBXFileTableDataSourceColumnWidthsKey = (
-					16,
-					200,
-					50,
-					238,
-				);
-				PBXFileTableDataSourceColumnsKey = (
-					PBXSymbolsDataSource_SymbolTypeIconID,
-					PBXSymbolsDataSource_SymbolNameID,
-					PBXSymbolsDataSource_SymbolTypeID,
-					PBXSymbolsDataSource_ReferenceNameID,
-				);
-			};
-			PBXConfiguration.PBXTargetDataSource.PBXTargetDataSource = {
-				PBXFileTableDataSourceColumnSortingDirectionKey = "-1";
-				PBXFileTableDataSourceColumnSortingKey = PBXFileDataSource_Filename_ColumnID;
-				PBXFileTableDataSourceColumnWidthsKey = (
-					20,
-					258,
-					60,
-					20,
-					48,
-					43,
-					43,
-				);
-				PBXFileTableDataSourceColumnsKey = (
-					PBXFileDataSource_FiletypeID,
-					PBXFileDataSource_Filename_ColumnID,
-					PBXTargetDataSource_PrimaryAttribute,
-					PBXFileDataSource_Built_ColumnID,
-					PBXFileDataSource_ObjectSize_ColumnID,
-					PBXFileDataSource_Errors_ColumnID,
-					PBXFileDataSource_Warnings_ColumnID,
-				);
-			};
-			PBXPerProjectTemplateStateSaveDate = 249196867;
-			PBXWorkspaceStateSaveDate = 249196867;
-		};
-		sourceControlManager = AA68C5700C8FA6C900D12438 /* Source Control */;
-		userBuildSettings = {
-		};
-	};
-	8DC2EF4F0486A6940098B216 /* Tclxml */ = {
-		activeExec = 0;
-	};
-	AA68C5700C8FA6C900D12438 /* Source Control */ = {
-		isa = PBXSourceControlManager;
-		fallbackIsa = XCSourceControlManager;
-		isSCMEnabled = 0;
-		scmConfiguration = {
-		};
-		scmType = "";
-	};
-	AA68C5710C8FA6C900D12438 /* Code sense */ = {
-		isa = PBXCodeSenseManager;
-		indexTemplatePath = "";
-	};
-	AA68C5D20C9031C400D12438 /* tclxml.c */ = {
-		uiCtxt = {
-			sepNavIntBoundsRect = "{{0, 0}, {848, 51870}}";
-			sepNavSelRange = "{8172, 0}";
-			sepNavVisRect = "{{0, 3464}, {738, 647}}";
-			sepNavWindowFrame = "{{67, 8}, {777, 776}}";
-		};
-	};
-	AA68C5E20C9032E400D12438 /* xml-8.0.tcl */ = {
-		uiCtxt = {
-			sepNavIntBoundsRect = "{{0, 0}, {738, 1302}}";
-			sepNavSelRange = "{0, 0}";
-			sepNavVisRect = "{{0, 0}, {738, 647}}";
-			sepNavWindowFrame = "{{-1356, 180}, {777, 776}}";
-		};
-	};
-	AA68C5E30C9032E400D12438 /* xml-8.1.tcl */ = {
-		uiCtxt = {
-			sepNavIntBoundsRect = "{{0, 0}, {738, 1904}}";
-			sepNavSelRange = "{0, 0}";
-			sepNavVisRect = "{{0, 0}, {738, 647}}";
-			sepNavWindowFrame = "{{126, 102}, {777, 776}}";
-		};
-	};
-	AA68C5F00C90331D00D12438 /* tclxml-libxml2.c */ = {
-		uiCtxt = {
-			sepNavIntBoundsRect = "{{0, 0}, {788, 13762}}";
-			sepNavSelRange = "{18, 0}";
-			sepNavVisRect = "{{0, 0}, {738, 647}}";
-			sepNavWindowFrame = "{{10, 32}, {777, 776}}";
-		};
-	};
-	AA68C5F20C90332A00D12438 /* docObj.c */ = {
-		uiCtxt = {
-			sepNavIntBoundsRect = "{{0, 0}, {738, 25662}}";
-			sepNavSelRange = "{6609, 0}";
-			sepNavVisRect = "{{0, 3240}, {738, 647}}";
-			sepNavWindowFrame = "{{28, 28}, {777, 776}}";
-		};
-	};
-	AA68C5F60C90334D00D12438 /* tclxml-libxml2.h */ = {
-		uiCtxt = {
-			sepNavIntBoundsRect = "{{0, 0}, {738, 1414}}";
-			sepNavSelRange = "{2529, 0}";
-			sepNavVisRect = "{{0, 767}, {738, 647}}";
-			sepNavWindowFrame = "{{471, 30}, {777, 776}}";
-		};
-	};
-	AA68C5F80C90336200D12438 /* tcldom.h */ = {
-		uiCtxt = {
-			sepNavIntBoundsRect = "{{0, 0}, {738, 4116}}";
-			sepNavSelRange = "{0, 0}";
-			sepNavVisRect = "{{0, 0}, {738, 647}}";
-			sepNavWindowFrame = "{{66, 61}, {777, 776}}";
-		};
-	};
-	AA68C5FA0C90337C00D12438 /* tcldom-libxml2.c */ = {
-		uiCtxt = {
-			sepNavIntBoundsRect = "{{0, 0}, {1664, 100394}}";
-			sepNavSelRange = "{182528, 7}";
-			sepNavVisRect = "{{0, 96312}, {738, 647}}";
-			sepNavWindowFrame = "{{40, 30}, {777, 776}}";
-		};
-	};
-	AA68C5FC0C90338B00D12438 /* nodeObj.c */ = {
-		uiCtxt = {
-			sepNavIntBoundsRect = "{{0, 0}, {738, 826}}";
-			sepNavSelRange = "{0, 0}";
-			sepNavVisRect = "{{0, 0}, {738, 647}}";
-			sepNavWindowFrame = "{{35, 11}, {777, 776}}";
-		};
-	};
-	AA68C5FF0C90339C00D12438 /* tcldom-libxml2.h */ = {
-		uiCtxt = {
-			sepNavIntBoundsRect = "{{0, 0}, {738, 3164}}";
-			sepNavSelRange = "{5523, 0}";
-			sepNavVisRect = "{{0, 2419}, {738, 647}}";
-			sepNavWindowFrame = "{{501, 4}, {777, 776}}";
-		};
-	};
-	AA68C6020C9033AC00D12438 /* tcldom-libxml2.tcl */ = {
-		uiCtxt = {
-			sepNavIntBoundsRect = "{{0, 0}, {738, 647}}";
-			sepNavSelRange = "{137, 0}";
-			sepNavVisRect = "{{0, 0}, {738, 647}}";
-			sepNavWindowFrame = "{{-1310, 138}, {777, 776}}";
-		};
-	};
-	AA68C6060C9033E300D12438 /* tclxslt-libxslt.c */ = {
-		uiCtxt = {
-			sepNavIntBoundsRect = "{{0, 0}, {1274, 26222}}";
-			sepNavSelRange = "{28375, 7}";
-			sepNavVisRect = "{{0, 13978}, {738, 647}}";
-			sepNavWindowFrame = "{{54, 33}, {777, 776}}";
-		};
-	};
-	AA68C6640C90EA8700D12438 /* configure */ = {
-		activeExec = 0;
-	};
-	AA68C6F50C91035400D12438 /* Tclxml-Info.plist */ = {
-		uiCtxt = {
-			sepNavIntBoundsRect = "{{0, 0}, {738, 647}}";
-			sepNavSelRange = "{555, 0}";
-			sepNavVisRect = "{{0, 0}, {738, 647}}";
-			sepNavWindowFrame = "{{-1425, 243}, {777, 776}}";
-		};
-	};
-}
diff --git a/tclxml-3.2/nodeObj.c b/tclxml-3.2/nodeObj.c
deleted file mode 100644
index 10f1420..0000000
--- a/tclxml-3.2/nodeObj.c
+++ /dev/null
@@ -1,58 +0,0 @@
-/* nodeObj.c --
- *
- *	This module manages libxml2 xmlNodePtr Tcl objects.
- *
- * Copyright (c) 2007 Explain
- * http://www.explain.com.au/
- * Copyright (c) 2003 Zveno Pty Ltd
- * http://www.zveno.com/
- *
- * See the file "LICENSE" for information on usage and
- * redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
- *
- * $Id: nodeObj.c,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
- */
-
-#include <tcldom-libxml2/nodeObj.h>
-
-#define TCL_DOES_STUBS \
-    (TCL_MAJOR_VERSION > 8 || TCL_MAJOR_VERSION == 8 && (TCL_MINOR_VERSION > 1 || \
-    (TCL_MINOR_VERSION == 1 && TCL_RELEASE_LEVEL == TCL_FINAL_RELEASE)))
-
-#undef TCL_STORAGE_CLASS
-#define TCL_STORAGE_CLASS DLLEXPORT
-
-extern Tcl_ObjType NodeObjType;
-
-/*
- * For debugging
- */
-
-extern Tcl_Channel stderrChan;
-extern char dbgbuf[200];
-
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclDOM_libxml2_NodeObjInit --
- *
- *  Initialise node obj module.
- *
- * Results:
- *  None.
- *
- * Side effects:
- *  Registers new object type.
- *
- *----------------------------------------------------------------------------
- */
-
-int
-TclDOM_libxml2_NodeObjInit(interp)
-     Tcl_Interp *interp;
-{
-  Tcl_RegisterObjType(&NodeObjType);
-
-  return TCL_OK;
-}
diff --git a/tclxml-3.2/pkgIndex.tcl.in b/tclxml-3.2/pkgIndex.tcl.in
deleted file mode 100644
index dc90a23..0000000
--- a/tclxml-3.2/pkgIndex.tcl.in
+++ /dev/null
@@ -1,134 +0,0 @@
-# TclXML combo package index file - handcrafted
-#
-# $Id: pkgIndex.tcl.in,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-namespace eval ::xml {
-    variable _init 0
-}
-namespace eval ::xml::libxml2 {
-    variable _init 0
-}
-namespace eval ::dom {
-    variable _init 0
-}
-namespace eval ::dom::libxml2 {
-    variable _init 0
-}
-namespace eval ::xslt {
-    variable _init 0
-}
-
-namespace eval ::xml {
-    variable pkginit
-
-    if {![info exists pkginit]} {
-	set pkginit 0
-    }
-
-    proc pkgload {dir {binary 0}} {
-	variable pkginit
-
-	if {$pkginit} {return {}}
-
-	namespace eval :: "
-	    package require xmldefs @PACKAGE_VERSION@
-	    package require xml::tcl @PACKAGE_VERSION@
-	    if {\[catch {load \[file join $dir @PKG_LIB_FILE@\] Tclxml}\]} {
-	        # Mac OS X frameworks are different
-	        if {\[catch {load \[file join $dir .. .. Tclxml\] Tclxml}\]} {
-		    # Unable to load binary implmentation,
-		    # just use pure-Tcl implmentation instead
-		    if {$binary} {
-			return -code error \"unable to load shared library\"
-		    }
-	        } else {
-		    set ::xml::libxml2::_init 1
-		    set ::dom::libxml2::_init 1
-		    set ::xslt::_init 1
-		    source \[file join $dir tcldom-libxml2.tcl\]
-		    source \[file join $dir tclxslt-libxslt.tcl\]
-	        }
-	    } else {
-		set ::xml::libxml2::_init 1
-		set ::dom::libxml2::_init 1
-		set ::xslt::_init 1
-		source \[file join $dir tcldom-libxml2.tcl\]
-		source \[file join $dir tclxslt-libxslt.tcl\]
-	    }
-	    package require xml::tclparser @PACKAGE_VERSION@
-	    package provide tclparser @PACKAGE_VERSION@
-	    package provide xml::libxml2 @PACKAGE_VERSION@
-	    package provide xml @PACKAGE_VERSION@
-	    package provide dom @PACKAGE_VERSION@
-	    package provide dom::libxml2 @PACKAGE_VERSION@
-	    package provide xslt @PACKAGE_VERSION@
-	    package provide xslt::libxslt @PACKAGE_VERSION@
-
-	    set pkginit 1
-	"
-    }
-}
-
-package ifneeded xml::tcl     @PACKAGE_VERSION@ [list source [file join $dir xml__tcl.tcl]]
-package ifneeded sgmlparser   1.1       [list source [file join $dir sgmlparser.tcl]]
-package ifneeded xpath        1.0       [list source [file join $dir xpath.tcl]]
-package ifneeded xmldep       1.0       [list source [file join $dir xmldep.tcl]]
-
-# Requesting a specific package means we want it to be the default parser class.
-
-package ifneeded xml::libxml2 @PACKAGE_VERSION@ "
-    ::xml::pkgload $dir 1
-    ::xml::parser default libxml2
-"
-
-# tclparser works with either xml::c or xml::tcl
-package ifneeded tclparser @PACKAGE_VERSION@ "
-    ::xml::pkgload $dir 0
-    ::xml::parser default tclparser
-    package provide tclparser @PACKAGE_VERSION@
-"
-
-# use tcl only (mainly for testing)
-package ifneeded puretclparser @PACKAGE_VERSION@ "
-    package require xml::tcl       @PACKAGE_VERSION@
-    package require xmldefs
-    package require xml::tclparser @PACKAGE_VERSION@
-    package provide puretclparser  @PACKAGE_VERSION@
-"
-
-# Requesting the generic package leaves the choice of default parser automatic
-
-package ifneeded xml @PACKAGE_VERSION@ "
-    ::xml::pkgload $dir 0
-"
-package ifneeded dom @PACKAGE_VERSION@ "
-    ::xml::pkgload $dir 0
-"
-package ifneeded dom::libxml2 @PACKAGE_VERSION@ "
-    ::xml::pkgload $dir 1
-"
-package ifneeded xslt @PACKAGE_VERSION@ "
-    ::xml::pkgload $dir 1
-"
-package ifneeded xslt::libxslt @PACKAGE_VERSION@ "
-    ::xml::pkgload $dir 1
-"
-
-package ifneeded xmlswitch @PACKAGE_VERSION@ [list source [file join $dir xmlswitch.tcl]]
-
-package ifneeded xslt::cache @PACKAGE_VERSION@ [list source [file join $dir xsltcache.tcl]]
-package ifneeded xslt::utilities @PACKAGE_VERSION@ [list source [file join $dir utilities.tcl]]
-package ifneeded xslt::process 1.1 [list source [file join $dir process.tcl]]
-package ifneeded xslt::resources 1.3 [list source [file join $dir resources.tcl]]
-
-if {[info tclversion] <= 8.0} {
-    package ifneeded sgml           1.9       [list source [file join $dir sgml-8.0.tcl]]
-    package ifneeded xmldefs        @PACKAGE_VERSION@ [list source [file join $dir xml-8.0.tcl]]
-    package ifneeded xml::tclparser @PACKAGE_VERSION@ [list source [file join $dir tclparser-8.0.tcl]]
-} else {
-    package ifneeded sgml           1.9       [list source [file join $dir sgml-8.1.tcl]]
-    package ifneeded xmldefs        @PACKAGE_VERSION@ [list source [file join $dir xml-8.1.tcl]]
-    package ifneeded xml::tclparser @PACKAGE_VERSION@ [list source [file join $dir tclparser-8.1.tcl]]
-}
-
-
diff --git a/tclxml-3.2/tclconfig/ChangeLog b/tclxml-3.2/tclconfig/ChangeLog
deleted file mode 100644
index 4d4fdcb..0000000
--- a/tclxml-3.2/tclconfig/ChangeLog
+++ /dev/null
@@ -1,142 +0,0 @@
-2002-07-20  Zoran Vasiljevic  <zoran at archiware.com>
-
-	* tcl.m4: Added MINGW32 to list of systems checked for Windows build.
-	Also, fixes some indentation issues with "--with-XXX" options.
-
-2002-04-23  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tcl.m4 (TEA_ENABLE_THREADS): added USE_THREAD_ALLOC define to
-	use new threaded allocatory by default on Unix for Tcl 8.4.
-	(TEA_CONFIG_CFLAGS): corrected LD_SEARCH_FLAGS for FreeBSD-3+.
-
-2002-04-22  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tcl.m4 (TEA_SETUP_COMPILER): removed call to AC_CYGWIN so that
-	we can use autoconf 2.5x as well as 2.13.  This prevents us from
-	being able to warn against the use of cygwin gcc at configure
-	time, but allows autoconf 2.5x, which is what is shipped with most
-	newer systems.
-
-2002-04-11  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tcl.m4: Enabled COFF as well as CV style debug info with
-	--enable-symbols to allow Dr. Watson users to see function info.
-	More info on debugging levels can be obtained at:
-	http://msdn.microsoft.com/library/en-us/dnvc60/html/gendepdebug.asp
-
-2002-04-03  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tcl.m4: change all SC_* macros to TEA_*.  The SC_ was for
-	Scriptics, which is no more.  TEA represents a better, independent
-	prefix that won't need changing.
-	Added preliminary mingw gcc support. [Patch #538772]
-	Added TEA_PREFIX macro that handles defaulting the prefix and
-	exec_prefix vars to those used by Tcl if none were specified.
-	Added TEA_SETUP_COMPILER macro that encompasses the AC_PROG_CC
-	check and several other basic AC_PROG checks needed for making
-	executables.  This greatly simplifies user's configure.in files.
-	Collapsed AIX-5 defines into AIX-* with extra checks for doing the
-	ELF stuff on AIX-5-ia64.
-	Updated TEA_ENABLE_THREADS to take an optional arg to allow
-	switching it on by default (for Thread) and add sanity checking to
-	warn the user if configuring threads incompatibly.
-
-2002-03-29  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tcl.m4: made sure that SHLIB_LDFLAGS was set to LDFLAGS_DEFAULT.
-	Removed --enable-64bit support for AIX-4 because it wasn't correct.
-	Added -MT or -MD Windows linker switches to properly support
-	symbols-enabled builds.
-
-2002-03-28  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tcl.m4: called AC_MSG_ERROR when SC_TEA_INIT wasn't called first
-	instead of calling it as that inlines it each time in shell code.
-	Changed Windows CFLAGS_OPTIMIZE to use -O2 instead of -Oti.
-	Noted TCL_LIB_VERSIONS_OK=nodots for Windows builds.
-	A few changes to support itcl (and perhaps others):
-	Added support for making your own stub libraries to SC_MAKE_LIB.
-	New SC_PATH_CONFIG and SC_LOAD_CONFIG that take a package name arg
-	and find that ${pkg}Config.sh file.  itk uses this for itcl.
-
-2002-03-27  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tcl.m4: made SC_LOAD_TKCONFIG recognize when working with a Tk
-	build dir setup.
-	Added EXTRA_CFLAGS and SHLIB_LD_LIBS substs to SC_CONFIG_CFLAGS.
-	Added XLIBSW onto LIBS when it is defined.
-	Remove TCL_LIBS from MAKE_LIB and correctly use SHLIB_LD_LIBS
-	instead to not rely as much on tclConfig.sh cached info.
-	Add TK_BIN_DIR to paths to find wish in SC_PROG_WISH.
-	These move towards making TEA much more independent of *Config.sh.
-
-2002-03-19  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tcl.m4: corrected forgotten (UN)SHARED_LIB_SUFFIX and
-	SHLIB_SUFFIX defines for Win.
-	(SC_PATH_X): made this only do the check on unix platforms. 
-
-2002-03-12  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* README.txt: updated to reflect fewer files
-
-2002-03-06  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* config.guess (removed):
-	* config.sub (removed): removed unnecessary files
-
-	* installFile.tcl (removed):
-	* mkinstalldirs (removed): these aren't really necessary for
-	making TEA work
-
-	* tcl.m4 (SC_PUBLIC_TCL_HEADERS, SC_PUBLIC_TK_HEADERS): don't
-	check /usr(/local)/include for includes on Windows when not using
-	gcc
-
-2002-03-05  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tcl.m4: added warnings on Windows, removed RELPATH define and
-	added TCL_LIBS to MAKE_LIB macro.
-
-	This import represents 2.0.0, or a new start at attempting to
-	make TEA much easier for C extension developers.
-
-	**** moved from tclpro project to core tcl project, ****
-	**** renamed to 'tclconfig'                         ****
-
-2001-03-15    Karl Lehenbauer <karl at procplace.com>
-
-	* installFile.tcl: Added updating of the modification time of
-	  the target file whether we overwrote it or decided that it
-	  hadn't changed.  This was necessary for us to be able to
-	  determine whether or not a module install touched the file.
-
-2001-03-08    Karl Lehenbauer <karl at procplace.com>
-
-	* installFile.tcl: Added support for converting new-style (1.1+) 
-	  Cygnus drive paths to Tcl-style.
-
-2001-01-15    <brent.welch at interwoven.com>
-
-	* tcl.m4: Added FreeBSD clause.
-
-2001-01-03    <brent.welch at interwoven.com>
-
-	* tcl.m4: Fixed typo in SC_LIB_SPEC where it is checking
-	for exec-prefix.
-
-2000-12-01    <brent.welch at interwoven.com>
-
-	* tcl.m4: Concatenated most of the Ajuba acsite.m4 file
-	so we don't need to modify the autoconf installation.
-	* config.guess:
-	* config.sub:
-	* installFile.tcl:
-	Added files from the itcl config subdirectory,
-	which should go away.
-
-2000-7-29    <welch at ajubasolutions.com>
-
-	* Fixed the use of TCL_SRC_DIR and TK_SRC_DIR within
-	TCL_PRIVATE_INCLUDES and TK_PRIVATE_INCLUDES to match their recent
-	change from $(srcdir) to $(srcdir)/..
diff --git a/tclxml-3.2/tclconfig/README.txt b/tclxml-3.2/tclconfig/README.txt
deleted file mode 100644
index 9055a58..0000000
--- a/tclxml-3.2/tclconfig/README.txt
+++ /dev/null
@@ -1,26 +0,0 @@
-These files comprise the basic building blocks for a Tcl Extension
-Architecture (TEA) extension.  For more information on TEA see:
-
-	http://www.tcl.tk/doc/tea/
-
-This package is part of the Tcl project at SourceForge, and latest
-sources should be available there:
-
-	http://tcl.sourceforge.net/
-
-This package is a freely available open source package.  You can do
-virtually anything you like with it, such as modifying it, redistributing
-it, and selling it either in whole or in part.
-
-CONTENTS
-========
-The following is a short description of the files you will find in
-the sample extension.
-
-README.txt	This file
-
-install-sh	Program used for copying binaries and script files
-		to their install locations.
-
-tcl.m4		Collection of Tcl autoconf macros.  Included by a package's
-		aclocal.m4 to define SC_* macros.
diff --git a/tclxml-3.2/tclconfig/install-sh b/tclxml-3.2/tclconfig/install-sh
deleted file mode 100755
index 0ff4b6a..0000000
--- a/tclxml-3.2/tclconfig/install-sh
+++ /dev/null
@@ -1,119 +0,0 @@
-#!/bin/sh
-
-#
-# install - install a program, script, or datafile
-# This comes from X11R5; it is not part of GNU.
-#
-# $XConsortium: install.sh,v 1.2 89/12/18 14:47:22 jim Exp $
-#
-# This script is compatible with the BSD install script, but was written
-# from scratch.
-#
-
-
-# set DOITPROG to echo to test this script
-
-# Don't use :- since 4.3BSD and earlier shells don't like it.
-doit="${DOITPROG-}"
-
-
-# put in absolute paths if you don't have them in your path; or use env. vars.
-
-mvprog="${MVPROG-mv}"
-cpprog="${CPPROG-cp}"
-chmodprog="${CHMODPROG-chmod}"
-chownprog="${CHOWNPROG-chown}"
-chgrpprog="${CHGRPPROG-chgrp}"
-stripprog="${STRIPPROG-strip}"
-rmprog="${RMPROG-rm}"
-
-instcmd="$mvprog"
-chmodcmd=""
-chowncmd=""
-chgrpcmd=""
-stripcmd=""
-rmcmd="$rmprog -f"
-mvcmd="$mvprog"
-src=""
-dst=""
-
-while [ x"$1" != x ]; do
-    case $1 in
-	-c) instcmd="$cpprog"
-	    shift
-	    continue;;
-
-	-m) chmodcmd="$chmodprog $2"
-	    shift
-	    shift
-	    continue;;
-
-	-o) chowncmd="$chownprog $2"
-	    shift
-	    shift
-	    continue;;
-
-	-g) chgrpcmd="$chgrpprog $2"
-	    shift
-	    shift
-	    continue;;
-
-	-s) stripcmd="$stripprog"
-	    shift
-	    continue;;
-
-	*)  if [ x"$src" = x ]
-	    then
-		src=$1
-	    else
-		dst=$1
-	    fi
-	    shift
-	    continue;;
-    esac
-done
-
-if [ x"$src" = x ]
-then
-	echo "install:  no input file specified"
-	exit 1
-fi
-
-if [ x"$dst" = x ]
-then
-	echo "install:  no destination specified"
-	exit 1
-fi
-
-
-# If destination is a directory, append the input filename; if your system
-# does not like double slashes in filenames, you may need to add some logic
-
-if [ -d $dst ]
-then
-	dst="$dst"/`basename $src`
-fi
-
-# Make a temp file name in the proper directory.
-
-dstdir=`dirname $dst`
-dsttmp=$dstdir/#inst.$$#
-
-# Move or copy the file name to the temp name
-
-$doit $instcmd $src $dsttmp
-
-# and set any options; do chmod last to preserve setuid bits
-
-if [ x"$chowncmd" != x ]; then $doit $chowncmd $dsttmp; fi
-if [ x"$chgrpcmd" != x ]; then $doit $chgrpcmd $dsttmp; fi
-if [ x"$stripcmd" != x ]; then $doit $stripcmd $dsttmp; fi
-if [ x"$chmodcmd" != x ]; then $doit $chmodcmd $dsttmp; fi
-
-# Now rename the file to the real destination.
-
-$doit $rmcmd $dst
-$doit $mvcmd $dsttmp $dst
-
-
-exit 0
diff --git a/tclxml-3.2/tclconfig/tcl.m4 b/tclxml-3.2/tclconfig/tcl.m4
deleted file mode 100644
index 70cbd3c..0000000
--- a/tclxml-3.2/tclconfig/tcl.m4
+++ /dev/null
@@ -1,4033 +0,0 @@
-# tcl.m4 --
-#
-#	This file provides a set of autoconf macros to help TEA-enable
-#	a Tcl extension.
-#
-# Copyright (c) 1999-2000 Ajuba Solutions.
-# Copyright (c) 2002-2005 ActiveState Corporation.
-#
-# See the file "license.terms" for information on usage and redistribution
-# of this file, and for a DISCLAIMER OF ALL WARRANTIES.
-#
-# RCS: @(#) $Id: tcl.m4,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-AC_PREREQ(2.57)
-
-dnl TEA extensions pass us the version of TEA they think they
-dnl are compatible with (must be set in TEA_INIT below)
-dnl TEA_VERSION="3.6"
-
-# Possible values for key variables defined:
-#
-# TEA_WINDOWINGSYSTEM - win32 aqua x11 (mirrors 'tk windowingsystem')
-# TEA_PLATFORM        - windows unix
-#
-
-#------------------------------------------------------------------------
-# TEA_PATH_TCLCONFIG --
-#
-#	Locate the tclConfig.sh file and perform a sanity check on
-#	the Tcl compile flags
-#
-# Arguments:
-#	none
-#
-# Results:
-#
-#	Adds the following arguments to configure:
-#		--with-tcl=...
-#
-#	Defines the following vars:
-#		TCL_BIN_DIR	Full path to the directory containing
-#				the tclConfig.sh file
-#------------------------------------------------------------------------
-
-AC_DEFUN([TEA_PATH_TCLCONFIG], [
-    dnl Make sure we are initialized
-    AC_REQUIRE([TEA_INIT])
-    #
-    # Ok, lets find the tcl configuration
-    # First, look for one uninstalled.
-    # the alternative search directory is invoked by --with-tcl
-    #
-
-    if test x"${no_tcl}" = x ; then
-	# we reset no_tcl in case something fails here
-	no_tcl=true
-	AC_ARG_WITH(tcl,
-	    AC_HELP_STRING([--with-tcl],
-		[directory containing tcl configuration (tclConfig.sh)]),
-	    with_tclconfig=${withval})
-	AC_MSG_CHECKING([for Tcl configuration])
-	AC_CACHE_VAL(ac_cv_c_tclconfig,[
-
-	    # First check to see if --with-tcl was specified.
-	    if test x"${with_tclconfig}" != x ; then
-		case ${with_tclconfig} in
-		    */tclConfig.sh )
-			if test -f ${with_tclconfig}; then
-			    AC_MSG_WARN([--with-tcl argument should refer to directory containing tclConfig.sh, not to tclConfig.sh itself])
-			    with_tclconfig=`echo ${with_tclconfig} | sed 's!/tclConfig\.sh$!!'`
-			fi ;;
-		esac
-		if test -f "${with_tclconfig}/tclConfig.sh" ; then
-		    ac_cv_c_tclconfig=`(cd ${with_tclconfig}; pwd)`
-		else
-		    AC_MSG_ERROR([${with_tclconfig} directory doesn't contain tclConfig.sh])
-		fi
-	    fi
-
-	    # then check for a private Tcl installation
-	    if test x"${ac_cv_c_tclconfig}" = x ; then
-		for i in \
-			../tcl \
-			`ls -dr ../tcl[[8-9]].[[0-9]].[[0-9]]* 2>/dev/null` \
-			`ls -dr ../tcl[[8-9]].[[0-9]] 2>/dev/null` \
-			`ls -dr ../tcl[[8-9]].[[0-9]]* 2>/dev/null` \
-			../../tcl \
-			`ls -dr ../../tcl[[8-9]].[[0-9]].[[0-9]]* 2>/dev/null` \
-			`ls -dr ../../tcl[[8-9]].[[0-9]] 2>/dev/null` \
-			`ls -dr ../../tcl[[8-9]].[[0-9]]* 2>/dev/null` \
-			../../../tcl \
-			`ls -dr ../../../tcl[[8-9]].[[0-9]].[[0-9]]* 2>/dev/null` \
-			`ls -dr ../../../tcl[[8-9]].[[0-9]] 2>/dev/null` \
-			`ls -dr ../../../tcl[[8-9]].[[0-9]]* 2>/dev/null` ; do
-		    if test -f "$i/unix/tclConfig.sh" ; then
-			ac_cv_c_tclconfig=`(cd $i/unix; pwd)`
-			break
-		    fi
-		done
-	    fi
-
-	    # on Darwin, check in Framework installation locations
-	    if test "`uname -s`" = "Darwin" -a x"${ac_cv_c_tclconfig}" = x ; then
-		for i in `ls -d ~/Library/Frameworks 2>/dev/null` \
-			`ls -d /Library/Frameworks 2>/dev/null` \
-			`ls -d /Network/Library/Frameworks 2>/dev/null` \
-			`ls -d /System/Library/Frameworks 2>/dev/null` \
-			; do
-		    if test -f "$i/Tcl.framework/tclConfig.sh" ; then
-			ac_cv_c_tclconfig=`(cd $i/Tcl.framework; pwd)`
-			break
-		    fi
-		done
-	    fi
-
-	    # on Windows, check in common installation locations
-	    if test "${TEA_PLATFORM}" = "windows" \
-		-a x"${ac_cv_c_tclconfig}" = x ; then
-		for i in `ls -d C:/Tcl/lib 2>/dev/null` \
-			`ls -d C:/Progra~1/Tcl/lib 2>/dev/null` \
-			; do
-		    if test -f "$i/tclConfig.sh" ; then
-			ac_cv_c_tclconfig=`(cd $i; pwd)`
-			break
-		    fi
-		done
-	    fi
-
-	    # check in a few common install locations
-	    # Bug fix #1367779 (by Wart)
-	    if test x"${ac_cv_c_tclconfig}" = x ; then
-		for i in `ls -d ${libdir} 2>/dev/null` \
-			`ls -d ${exec_prefix}/lib 2>/dev/null` \
-			`ls -d ${prefix}/lib 2>/dev/null` \
-			`ls -d /usr/local/lib 2>/dev/null` \
-			`ls -d /usr/contrib/lib 2>/dev/null` \
-			`ls -d /usr/lib64 2>/dev/null` \
-			`ls -d /usr/lib 2>/dev/null` \
-			; do
-		    if test -f "$i/tclConfig.sh" ; then
-			ac_cv_c_tclconfig=`(cd $i; pwd)`
-			break
-		    fi
-		done
-	    fi
-
-	    # check in a few other private locations
-	    if test x"${ac_cv_c_tclconfig}" = x ; then
-		for i in \
-			${srcdir}/../tcl \
-			`ls -dr ${srcdir}/../tcl[[8-9]].[[0-9]].[[0-9]]* 2>/dev/null` \
-			`ls -dr ${srcdir}/../tcl[[8-9]].[[0-9]] 2>/dev/null` \
-			`ls -dr ${srcdir}/../tcl[[8-9]].[[0-9]]* 2>/dev/null` ; do
-		    if test -f "$i/unix/tclConfig.sh" ; then
-		    ac_cv_c_tclconfig=`(cd $i/unix; pwd)`
-		    break
-		fi
-		done
-	    fi
-	])
-
-	if test x"${ac_cv_c_tclconfig}" = x ; then
-	    TCL_BIN_DIR="# no Tcl configs found"
-	    AC_MSG_WARN([Can't find Tcl configuration definitions])
-	    exit 0
-	else
-	    no_tcl=
-	    TCL_BIN_DIR=${ac_cv_c_tclconfig}
-	    AC_MSG_RESULT([found ${TCL_BIN_DIR}/tclConfig.sh])
-	fi
-    fi
-])
-
-#------------------------------------------------------------------------
-# TEA_PATH_TKCONFIG --
-#
-#	Locate the tkConfig.sh file
-#
-# Arguments:
-#	none
-#
-# Results:
-#
-#	Adds the following arguments to configure:
-#		--with-tk=...
-#
-#	Defines the following vars:
-#		TK_BIN_DIR	Full path to the directory containing
-#				the tkConfig.sh file
-#------------------------------------------------------------------------
-
-AC_DEFUN([TEA_PATH_TKCONFIG], [
-    #
-    # Ok, lets find the tk configuration
-    # First, look for one uninstalled.
-    # the alternative search directory is invoked by --with-tk
-    #
-
-    if test x"${no_tk}" = x ; then
-	# we reset no_tk in case something fails here
-	no_tk=true
-	AC_ARG_WITH(tk,
-	    AC_HELP_STRING([--with-tk],
-		[directory containing tk configuration (tkConfig.sh)]),
-	    with_tkconfig=${withval})
-	AC_MSG_CHECKING([for Tk configuration])
-	AC_CACHE_VAL(ac_cv_c_tkconfig,[
-
-	    # First check to see if --with-tkconfig was specified.
-	    if test x"${with_tkconfig}" != x ; then
-		case ${with_tkconfig} in
-		    */tkConfig.sh )
-			if test -f ${with_tkconfig}; then
-			    AC_MSG_WARN([--with-tk argument should refer to directory containing tkConfig.sh, not to tkConfig.sh itself])
-			    with_tkconfig=`echo ${with_tkconfig} | sed 's!/tkConfig\.sh$!!'`
-			fi ;;
-		esac
-		if test -f "${with_tkconfig}/tkConfig.sh" ; then
-		    ac_cv_c_tkconfig=`(cd ${with_tkconfig}; pwd)`
-		else
-		    AC_MSG_ERROR([${with_tkconfig} directory doesn't contain tkConfig.sh])
-		fi
-	    fi
-
-	    # then check for a private Tk library
-	    if test x"${ac_cv_c_tkconfig}" = x ; then
-		for i in \
-			../tk \
-			`ls -dr ../tk[[8-9]].[[0-9]].[[0-9]]* 2>/dev/null` \
-			`ls -dr ../tk[[8-9]].[[0-9]] 2>/dev/null` \
-			`ls -dr ../tk[[8-9]].[[0-9]]* 2>/dev/null` \
-			../../tk \
-			`ls -dr ../../tk[[8-9]].[[0-9]].[[0-9]]* 2>/dev/null` \
-			`ls -dr ../../tk[[8-9]].[[0-9]] 2>/dev/null` \
-			`ls -dr ../../tk[[8-9]].[[0-9]]* 2>/dev/null` \
-			../../../tk \
-			`ls -dr ../../../tk[[8-9]].[[0-9]].[[0-9]]* 2>/dev/null` \
-			`ls -dr ../../../tk[[8-9]].[[0-9]] 2>/dev/null` \
-			`ls -dr ../../../tk[[8-9]].[[0-9]]* 2>/dev/null` ; do
-		    if test -f "$i/unix/tkConfig.sh" ; then
-			ac_cv_c_tkconfig=`(cd $i/unix; pwd)`
-			break
-		    fi
-		done
-	    fi
-
-	    # on Darwin, check in Framework installation locations
-	    if test "`uname -s`" = "Darwin" -a x"${ac_cv_c_tkconfig}" = x ; then
-		for i in `ls -d ~/Library/Frameworks 2>/dev/null` \
-			`ls -d /Library/Frameworks 2>/dev/null` \
-			`ls -d /Network/Library/Frameworks 2>/dev/null` \
-			`ls -d /System/Library/Frameworks 2>/dev/null` \
-			; do
-		    if test -f "$i/Tk.framework/tkConfig.sh" ; then
-			ac_cv_c_tkconfig=`(cd $i/Tk.framework; pwd)`
-			break
-		    fi
-		done
-	    fi
-
-	    # check in a few common install locations
-	    if test x"${ac_cv_c_tkconfig}" = x ; then
-		for i in `ls -d ${libdir} 2>/dev/null` \
-			`ls -d ${exec_prefix}/lib 2>/dev/null` \
-			`ls -d ${prefix}/lib 2>/dev/null` \
-			`ls -d /usr/local/lib 2>/dev/null` \
-			`ls -d /usr/contrib/lib 2>/dev/null` \
-			`ls -d /usr/lib 2>/dev/null` \
-			; do
-		    if test -f "$i/tkConfig.sh" ; then
-			ac_cv_c_tkconfig=`(cd $i; pwd)`
-			break
-		    fi
-		done
-	    fi
-
-	    # on Windows, check in common installation locations
-	    if test "${TEA_PLATFORM}" = "windows" \
-		-a x"${ac_cv_c_tkconfig}" = x ; then
-		for i in `ls -d C:/Tcl/lib 2>/dev/null` \
-			`ls -d C:/Progra~1/Tcl/lib 2>/dev/null` \
-			; do
-		    if test -f "$i/tkConfig.sh" ; then
-			ac_cv_c_tkconfig=`(cd $i; pwd)`
-			break
-		    fi
-		done
-	    fi
-
-	    # check in a few other private locations
-	    if test x"${ac_cv_c_tkconfig}" = x ; then
-		for i in \
-			${srcdir}/../tk \
-			`ls -dr ${srcdir}/../tk[[8-9]].[[0-9]].[[0-9]]* 2>/dev/null` \
-			`ls -dr ${srcdir}/../tk[[8-9]].[[0-9]] 2>/dev/null` \
-			`ls -dr ${srcdir}/../tk[[8-9]].[[0-9]]* 2>/dev/null` ; do
-		    if test -f "$i/unix/tkConfig.sh" ; then
-			ac_cv_c_tkconfig=`(cd $i/unix; pwd)`
-			break
-		    fi
-		done
-	    fi
-	])
-
-	if test x"${ac_cv_c_tkconfig}" = x ; then
-	    TK_BIN_DIR="# no Tk configs found"
-	    AC_MSG_WARN([Can't find Tk configuration definitions])
-	    exit 0
-	else
-	    no_tk=
-	    TK_BIN_DIR=${ac_cv_c_tkconfig}
-	    AC_MSG_RESULT([found ${TK_BIN_DIR}/tkConfig.sh])
-	fi
-    fi
-])
-
-#------------------------------------------------------------------------
-# TEA_LOAD_TCLCONFIG --
-#
-#	Load the tclConfig.sh file
-#
-# Arguments:
-#	
-#	Requires the following vars to be set:
-#		TCL_BIN_DIR
-#
-# Results:
-#
-#	Subst the following vars:
-#		TCL_BIN_DIR
-#		TCL_SRC_DIR
-#		TCL_LIB_FILE
-#
-#------------------------------------------------------------------------
-
-AC_DEFUN([TEA_LOAD_TCLCONFIG], [
-    AC_MSG_CHECKING([for existence of ${TCL_BIN_DIR}/tclConfig.sh])
-
-    if test -f "${TCL_BIN_DIR}/tclConfig.sh" ; then
-        AC_MSG_RESULT([loading])
-	. "${TCL_BIN_DIR}/tclConfig.sh"
-    else
-        AC_MSG_RESULT([could not find ${TCL_BIN_DIR}/tclConfig.sh])
-    fi
-
-    # eval is required to do the TCL_DBGX substitution
-    eval "TCL_LIB_FILE=\"${TCL_LIB_FILE}\""
-    eval "TCL_STUB_LIB_FILE=\"${TCL_STUB_LIB_FILE}\""
-
-    # If the TCL_BIN_DIR is the build directory (not the install directory),
-    # then set the common variable name to the value of the build variables.
-    # For example, the variable TCL_LIB_SPEC will be set to the value
-    # of TCL_BUILD_LIB_SPEC. An extension should make use of TCL_LIB_SPEC
-    # instead of TCL_BUILD_LIB_SPEC since it will work with both an
-    # installed and uninstalled version of Tcl.
-    if test -f "${TCL_BIN_DIR}/Makefile" ; then
-        TCL_LIB_SPEC=${TCL_BUILD_LIB_SPEC}
-        TCL_STUB_LIB_SPEC=${TCL_BUILD_STUB_LIB_SPEC}
-        TCL_STUB_LIB_PATH=${TCL_BUILD_STUB_LIB_PATH}
-    elif test "`uname -s`" = "Darwin"; then
-	# If Tcl was built as a framework, attempt to use the libraries
-	# from the framework at the given location so that linking works
-	# against Tcl.framework installed in an arbitary location.
-	case ${TCL_DEFS} in
-	    *TCL_FRAMEWORK*)
-		if test -f "${TCL_BIN_DIR}/${TCL_LIB_FILE}"; then
-		    for i in "`cd ${TCL_BIN_DIR}; pwd`" \
-			     "`cd ${TCL_BIN_DIR}/../..; pwd`"; do
-			if test "`basename "$i"`" = "${TCL_LIB_FILE}.framework"; then
-			    TCL_LIB_SPEC="-F`dirname "$i"` -framework ${TCL_LIB_FILE}"
-			    break
-			fi
-		    done
-		fi
-		if test -f "${TCL_BIN_DIR}/${TCL_STUB_LIB_FILE}"; then
-		    TCL_STUB_LIB_SPEC="-L${TCL_BIN_DIR} ${TCL_STUB_LIB_FLAG}"
-		    TCL_STUB_LIB_PATH="${TCL_BIN_DIR}/${TCL_STUB_LIB_FILE}"
-		fi
-		;;
-	esac
-    fi
-
-    # eval is required to do the TCL_DBGX substitution
-    eval "TCL_LIB_FLAG=\"${TCL_LIB_FLAG}\""
-    eval "TCL_LIB_SPEC=\"${TCL_LIB_SPEC}\""
-    eval "TCL_STUB_LIB_FLAG=\"${TCL_STUB_LIB_FLAG}\""
-    eval "TCL_STUB_LIB_SPEC=\"${TCL_STUB_LIB_SPEC}\""
-
-    AC_SUBST(TCL_VERSION)
-    AC_SUBST(TCL_BIN_DIR)
-    AC_SUBST(TCL_SRC_DIR)
-
-    AC_SUBST(TCL_LIB_FILE)
-    AC_SUBST(TCL_LIB_FLAG)
-    AC_SUBST(TCL_LIB_SPEC)
-
-    AC_SUBST(TCL_STUB_LIB_FILE)
-    AC_SUBST(TCL_STUB_LIB_FLAG)
-    AC_SUBST(TCL_STUB_LIB_SPEC)
-
-    AC_SUBST(TCL_LIBS)
-    AC_SUBST(TCL_DEFS)
-    AC_SUBST(TCL_EXTRA_CFLAGS)
-    AC_SUBST(TCL_LD_FLAGS)
-    AC_SUBST(TCL_SHLIB_LD_LIBS)
-])
-
-#------------------------------------------------------------------------
-# TEA_LOAD_TKCONFIG --
-#
-#	Load the tkConfig.sh file
-#
-# Arguments:
-#	
-#	Requires the following vars to be set:
-#		TK_BIN_DIR
-#
-# Results:
-#
-#	Sets the following vars that should be in tkConfig.sh:
-#		TK_BIN_DIR
-#------------------------------------------------------------------------
-
-AC_DEFUN([TEA_LOAD_TKCONFIG], [
-    AC_MSG_CHECKING([for existence of ${TK_BIN_DIR}/tkConfig.sh])
-
-    if test -f "${TK_BIN_DIR}/tkConfig.sh" ; then
-        AC_MSG_RESULT([loading])
-	. "${TK_BIN_DIR}/tkConfig.sh"
-    else
-        AC_MSG_RESULT([could not find ${TK_BIN_DIR}/tkConfig.sh])
-    fi
-
-    # eval is required to do the TK_DBGX substitution
-    eval "TK_LIB_FILE=\"${TK_LIB_FILE}\""
-    eval "TK_STUB_LIB_FILE=\"${TK_STUB_LIB_FILE}\""
-
-    # If the TK_BIN_DIR is the build directory (not the install directory),
-    # then set the common variable name to the value of the build variables.
-    # For example, the variable TK_LIB_SPEC will be set to the value
-    # of TK_BUILD_LIB_SPEC. An extension should make use of TK_LIB_SPEC
-    # instead of TK_BUILD_LIB_SPEC since it will work with both an
-    # installed and uninstalled version of Tcl.
-    if test -f "${TK_BIN_DIR}/Makefile" ; then
-        TK_LIB_SPEC=${TK_BUILD_LIB_SPEC}
-        TK_STUB_LIB_SPEC=${TK_BUILD_STUB_LIB_SPEC}
-        TK_STUB_LIB_PATH=${TK_BUILD_STUB_LIB_PATH}
-    elif test "`uname -s`" = "Darwin"; then
-	# If Tk was built as a framework, attempt to use the libraries
-	# from the framework at the given location so that linking works
-	# against Tk.framework installed in an arbitary location.
-	case ${TK_DEFS} in
-	    *TK_FRAMEWORK*)
-		if test -f "${TK_BIN_DIR}/${TK_LIB_FILE}"; then
-		    for i in "`cd ${TK_BIN_DIR}; pwd`" \
-			     "`cd ${TK_BIN_DIR}/../..; pwd`"; do
-			if test "`basename "$i"`" = "${TK_LIB_FILE}.framework"; then
-			    TK_LIB_SPEC="-F`dirname "$i"` -framework ${TK_LIB_FILE}"
-			    break
-			fi
-		    done
-		fi
-		if test -f "${TK_BIN_DIR}/${TK_STUB_LIB_FILE}"; then
-		    TK_STUB_LIB_SPEC="-L${TK_BIN_DIR} ${TK_STUB_LIB_FLAG}"
-		    TK_STUB_LIB_PATH="${TK_BIN_DIR}/${TK_STUB_LIB_FILE}"
-		fi
-		;;
-	esac
-    fi
-
-    # eval is required to do the TK_DBGX substitution
-    eval "TK_LIB_FLAG=\"${TK_LIB_FLAG}\""
-    eval "TK_LIB_SPEC=\"${TK_LIB_SPEC}\""
-    eval "TK_STUB_LIB_FLAG=\"${TK_STUB_LIB_FLAG}\""
-    eval "TK_STUB_LIB_SPEC=\"${TK_STUB_LIB_SPEC}\""
-
-    # Ensure windowingsystem is defined
-    if test "${TEA_PLATFORM}" = "unix" ; then
-	case ${TK_DEFS} in
-	    *MAC_OSX_TK*)
-		AC_DEFINE(MAC_OSX_TK, 1, [Are we building against Mac OS X TkAqua?])
-		TEA_WINDOWINGSYSTEM="aqua"
-		;;
-	    *)
-		TEA_WINDOWINGSYSTEM="x11"
-		;;
-	esac
-    elif test "${TEA_PLATFORM}" = "windows" ; then
-	TEA_WINDOWINGSYSTEM="win32"
-    fi
-
-    AC_SUBST(TK_VERSION)
-    AC_SUBST(TK_BIN_DIR)
-    AC_SUBST(TK_SRC_DIR)
-
-    AC_SUBST(TK_LIB_FILE)
-    AC_SUBST(TK_LIB_FLAG)
-    AC_SUBST(TK_LIB_SPEC)
-
-    AC_SUBST(TK_STUB_LIB_FILE)
-    AC_SUBST(TK_STUB_LIB_FLAG)
-    AC_SUBST(TK_STUB_LIB_SPEC)
-
-    AC_SUBST(TK_LIBS)
-    AC_SUBST(TK_XINCLUDES)
-])
-
-#------------------------------------------------------------------------
-# TEA_ENABLE_SHARED --
-#
-#	Allows the building of shared libraries
-#
-# Arguments:
-#	none
-#	
-# Results:
-#
-#	Adds the following arguments to configure:
-#		--enable-shared=yes|no
-#
-#	Defines the following vars:
-#		STATIC_BUILD	Used for building import/export libraries
-#				on Windows.
-#
-#	Sets the following vars:
-#		SHARED_BUILD	Value of 1 or 0
-#------------------------------------------------------------------------
-
-AC_DEFUN([TEA_ENABLE_SHARED], [
-    AC_MSG_CHECKING([how to build libraries])
-    AC_ARG_ENABLE(shared,
-	AC_HELP_STRING([--enable-shared],
-	    [build and link with shared libraries (default: on)]),
-	[tcl_ok=$enableval], [tcl_ok=yes])
-
-    if test "${enable_shared+set}" = set; then
-	enableval="$enable_shared"
-	tcl_ok=$enableval
-    else
-	tcl_ok=yes
-    fi
-
-    if test "$tcl_ok" = "yes" ; then
-	AC_MSG_RESULT([shared])
-	SHARED_BUILD=1
-    else
-	AC_MSG_RESULT([static])
-	SHARED_BUILD=0
-	AC_DEFINE(STATIC_BUILD, 1, [Is this a static build?])
-    fi
-    AC_SUBST(SHARED_BUILD)
-])
-
-#------------------------------------------------------------------------
-# TEA_ENABLE_THREADS --
-#
-#	Specify if thread support should be enabled.  If "yes" is specified
-#	as an arg (optional), threads are enabled by default, "no" means
-#	threads are disabled.  "yes" is the default.
-#
-#	TCL_THREADS is checked so that if you are compiling an extension
-#	against a threaded core, your extension must be compiled threaded
-#	as well.
-#
-#	Note that it is legal to have a thread enabled extension run in a
-#	threaded or non-threaded Tcl core, but a non-threaded extension may
-#	only run in a non-threaded Tcl core.
-#
-# Arguments:
-#	none
-#	
-# Results:
-#
-#	Adds the following arguments to configure:
-#		--enable-threads
-#
-#	Sets the following vars:
-#		THREADS_LIBS	Thread library(s)
-#
-#	Defines the following vars:
-#		TCL_THREADS
-#		_REENTRANT
-#		_THREAD_SAFE
-#
-#------------------------------------------------------------------------
-
-AC_DEFUN([TEA_ENABLE_THREADS], [
-    AC_ARG_ENABLE(threads,
-	AC_HELP_STRING([--enable-threads],
-	    [build with threads]),
-	[tcl_ok=$enableval], [tcl_ok=yes])
-
-    if test "${enable_threads+set}" = set; then
-	enableval="$enable_threads"
-	tcl_ok=$enableval
-    else
-	tcl_ok=yes
-    fi
-
-    if test "$tcl_ok" = "yes" -o "${TCL_THREADS}" = 1; then
-	TCL_THREADS=1
-
-	if test "${TEA_PLATFORM}" != "windows" ; then
-	    # We are always OK on Windows, so check what this platform wants:
-    
-	    # USE_THREAD_ALLOC tells us to try the special thread-based
-	    # allocator that significantly reduces lock contention
-	    AC_DEFINE(USE_THREAD_ALLOC, 1,
-		[Do we want to use the threaded memory allocator?])
-	    AC_DEFINE(_REENTRANT, 1, [Do we want the reentrant OS API?])
-	    if test "`uname -s`" = "SunOS" ; then
-		AC_DEFINE(_POSIX_PTHREAD_SEMANTICS, 1,
-			[Do we really want to follow the standard? Yes we do!])
-	    fi
-	    AC_DEFINE(_THREAD_SAFE, 1, [Do we want the thread-safe OS API?])
-	    AC_CHECK_LIB(pthread,pthread_mutex_init,tcl_ok=yes,tcl_ok=no)
-	    if test "$tcl_ok" = "no"; then
-		# Check a little harder for __pthread_mutex_init in the same
-		# library, as some systems hide it there until pthread.h is
-		# defined.  We could alternatively do an AC_TRY_COMPILE with
-		# pthread.h, but that will work with libpthread really doesn't
-		# exist, like AIX 4.2.  [Bug: 4359]
-		AC_CHECK_LIB(pthread, __pthread_mutex_init,
-		    tcl_ok=yes, tcl_ok=no)
-	    fi
-
-	    if test "$tcl_ok" = "yes"; then
-		# The space is needed
-		THREADS_LIBS=" -lpthread"
-	    else
-		AC_CHECK_LIB(pthreads, pthread_mutex_init,
-		    tcl_ok=yes, tcl_ok=no)
-		if test "$tcl_ok" = "yes"; then
-		    # The space is needed
-		    THREADS_LIBS=" -lpthreads"
-		else
-		    AC_CHECK_LIB(c, pthread_mutex_init,
-			tcl_ok=yes, tcl_ok=no)
-		    if test "$tcl_ok" = "no"; then
-			AC_CHECK_LIB(c_r, pthread_mutex_init,
-			    tcl_ok=yes, tcl_ok=no)
-			if test "$tcl_ok" = "yes"; then
-			    # The space is needed
-			    THREADS_LIBS=" -pthread"
-			else
-			    TCL_THREADS=0
-			    AC_MSG_WARN([Do not know how to find pthread lib on your system - thread support disabled])
-			fi
-		    fi
-		fi
-	    fi
-	fi
-    else
-	TCL_THREADS=0
-    fi
-    # Do checking message here to not mess up interleaved configure output
-    AC_MSG_CHECKING([for building with threads])
-    if test "${TCL_THREADS}" = 1; then
-	AC_DEFINE(TCL_THREADS, 1, [Are we building with threads enabled?])
-	AC_MSG_RESULT([yes (default)])
-    else
-	AC_MSG_RESULT([no])
-    fi
-    # TCL_THREADS sanity checking.  See if our request for building with
-    # threads is the same as the way Tcl was built.  If not, warn the user.
-    case ${TCL_DEFS} in
-	*THREADS=1*)
-	    if test "${TCL_THREADS}" = "0"; then
-		AC_MSG_WARN([
-    Building ${PACKAGE_NAME} without threads enabled, but building against Tcl
-    that IS thread-enabled.  It is recommended to use --enable-threads.])
-	    fi
-	    ;;
-	*)
-	    if test "${TCL_THREADS}" = "1"; then
-		AC_MSG_WARN([
-    --enable-threads requested, but building against a Tcl that is NOT
-    thread-enabled.  This is an OK configuration that will also run in
-    a thread-enabled core.])
-	    fi
-	    ;;
-    esac
-    AC_SUBST(TCL_THREADS)
-])
-
-#------------------------------------------------------------------------
-# TEA_ENABLE_SYMBOLS --
-#
-#	Specify if debugging symbols should be used.
-#	Memory (TCL_MEM_DEBUG) debugging can also be enabled.
-#
-# Arguments:
-#	none
-#	
-#	TEA varies from core Tcl in that C|LDFLAGS_DEFAULT receives
-#	the value of C|LDFLAGS_OPTIMIZE|DEBUG already substituted.
-#	Requires the following vars to be set in the Makefile:
-#		CFLAGS_DEFAULT
-#		LDFLAGS_DEFAULT
-#	
-# Results:
-#
-#	Adds the following arguments to configure:
-#		--enable-symbols
-#
-#	Defines the following vars:
-#		CFLAGS_DEFAULT	Sets to $(CFLAGS_DEBUG) if true
-#				Sets to $(CFLAGS_OPTIMIZE) if false
-#		LDFLAGS_DEFAULT	Sets to $(LDFLAGS_DEBUG) if true
-#				Sets to $(LDFLAGS_OPTIMIZE) if false
-#		DBGX		Formerly used as debug library extension;
-#				always blank now.
-#
-#------------------------------------------------------------------------
-
-AC_DEFUN([TEA_ENABLE_SYMBOLS], [
-    dnl Make sure we are initialized
-    AC_REQUIRE([TEA_CONFIG_CFLAGS])
-    AC_MSG_CHECKING([for build with symbols])
-    AC_ARG_ENABLE(symbols,
-	AC_HELP_STRING([--enable-symbols],
-	    [build with debugging symbols (default: off)]),
-	[tcl_ok=$enableval], [tcl_ok=no])
-    DBGX=""
-    if test "$tcl_ok" = "no"; then
-	CFLAGS_DEFAULT="${CFLAGS_OPTIMIZE}"
-	LDFLAGS_DEFAULT="${LDFLAGS_OPTIMIZE}"
-	AC_MSG_RESULT([no])
-    else
-	CFLAGS_DEFAULT="${CFLAGS_DEBUG}"
-	LDFLAGS_DEFAULT="${LDFLAGS_DEBUG}"
-	if test "$tcl_ok" = "yes"; then
-	    AC_MSG_RESULT([yes (standard debugging)])
-	fi
-    fi
-    if test "${TEA_PLATFORM}" != "windows" ; then
-	LDFLAGS_DEFAULT="${LDFLAGS}"
-    fi
-
-    AC_SUBST(TCL_DBGX)
-    AC_SUBST(CFLAGS_DEFAULT)
-    AC_SUBST(LDFLAGS_DEFAULT)
-
-    if test "$tcl_ok" = "mem" -o "$tcl_ok" = "all"; then
-	AC_DEFINE(TCL_MEM_DEBUG, 1, [Is memory debugging enabled?])
-    fi
-
-    if test "$tcl_ok" != "yes" -a "$tcl_ok" != "no"; then
-	if test "$tcl_ok" = "all"; then
-	    AC_MSG_RESULT([enabled symbols mem debugging])
-	else
-	    AC_MSG_RESULT([enabled $tcl_ok debugging])
-	fi
-    fi
-])
-
-#------------------------------------------------------------------------
-# TEA_ENABLE_LANGINFO --
-#
-#	Allows use of modern nl_langinfo check for better l10n.
-#	This is only relevant for Unix.
-#
-# Arguments:
-#	none
-#	
-# Results:
-#
-#	Adds the following arguments to configure:
-#		--enable-langinfo=yes|no (default is yes)
-#
-#	Defines the following vars:
-#		HAVE_LANGINFO	Triggers use of nl_langinfo if defined.
-#
-#------------------------------------------------------------------------
-
-AC_DEFUN([TEA_ENABLE_LANGINFO], [
-    AC_ARG_ENABLE(langinfo,
-	AC_HELP_STRING([--enable-langinfo],
-	    [use nl_langinfo if possible to determine encoding at startup, otherwise use old heuristic (default: on)]),
-	[langinfo_ok=$enableval], [langinfo_ok=yes])
-
-    HAVE_LANGINFO=0
-    if test "$langinfo_ok" = "yes"; then
-	AC_CHECK_HEADER(langinfo.h,[langinfo_ok=yes],[langinfo_ok=no])
-    fi
-    AC_MSG_CHECKING([whether to use nl_langinfo])
-    if test "$langinfo_ok" = "yes"; then
-	AC_CACHE_VAL(tcl_cv_langinfo_h, [
-	    AC_TRY_COMPILE([#include <langinfo.h>], [nl_langinfo(CODESET);],
-		    [tcl_cv_langinfo_h=yes],[tcl_cv_langinfo_h=no])])
-	AC_MSG_RESULT([$tcl_cv_langinfo_h])
-	if test $tcl_cv_langinfo_h = yes; then
-	    AC_DEFINE(HAVE_LANGINFO, 1, [Do we have nl_langinfo()?])
-	fi
-    else 
-	AC_MSG_RESULT([$langinfo_ok])
-    fi
-])
-
-#--------------------------------------------------------------------
-# TEA_CONFIG_SYSTEM
-#
-#	Determine what the system is (some things cannot be easily checked
-#	on a feature-driven basis, alas). This can usually be done via the
-#	"uname" command, but there are a few systems, like Next, where
-#	this doesn't work.
-#
-# Arguments:
-#	none
-#
-# Results:
-#	Defines the following var:
-#
-#	system -	System/platform/version identification code.
-#
-#--------------------------------------------------------------------
-
-AC_DEFUN([TEA_CONFIG_SYSTEM], [
-    AC_CACHE_CHECK([system version], tcl_cv_sys_version, [
-	if test "${TEA_PLATFORM}" = "windows" ; then
-	    tcl_cv_sys_version=windows
-	elif test -f /usr/lib/NextStep/software_version; then
-	    tcl_cv_sys_version=NEXTSTEP-`awk '/3/,/3/' /usr/lib/NextStep/software_version`
-	else
-	    tcl_cv_sys_version=`uname -s`-`uname -r`
-	    if test "$?" -ne 0 ; then
-		AC_MSG_WARN([can't find uname command])
-		tcl_cv_sys_version=unknown
-	    else
-		# Special check for weird MP-RAS system (uname returns weird
-		# results, and the version is kept in special file).
-
-		if test -r /etc/.relid -a "X`uname -n`" = "X`uname -s`" ; then
-		    tcl_cv_sys_version=MP-RAS-`awk '{print $[3]}' /etc/.relid`
-		fi
-		if test "`uname -s`" = "AIX" ; then
-		    tcl_cv_sys_version=AIX-`uname -v`.`uname -r`
-		fi
-	    fi
-	fi
-    ])
-    system=$tcl_cv_sys_version
-])
-
-#--------------------------------------------------------------------
-# TEA_CONFIG_CFLAGS
-#
-#	Try to determine the proper flags to pass to the compiler
-#	for building shared libraries and other such nonsense.
-#
-# Arguments:
-#	none
-#
-# Results:
-#
-#	Defines and substitutes the following vars:
-#
-#       DL_OBJS -       Name of the object file that implements dynamic
-#                       loading for Tcl on this system.
-#       DL_LIBS -       Library file(s) to include in tclsh and other base
-#                       applications in order for the "load" command to work.
-#       LDFLAGS -      Flags to pass to the compiler when linking object
-#                       files into an executable application binary such
-#                       as tclsh.
-#       LD_SEARCH_FLAGS-Flags to pass to ld, such as "-R /usr/local/tcl/lib",
-#                       that tell the run-time dynamic linker where to look
-#                       for shared libraries such as libtcl.so.  Depends on
-#                       the variable LIB_RUNTIME_DIR in the Makefile. Could
-#                       be the same as CC_SEARCH_FLAGS if ${CC} is used to link.
-#       CC_SEARCH_FLAGS-Flags to pass to ${CC}, such as "-Wl,-rpath,/usr/local/tcl/lib",
-#                       that tell the run-time dynamic linker where to look
-#                       for shared libraries such as libtcl.so.  Depends on
-#                       the variable LIB_RUNTIME_DIR in the Makefile.
-#       SHLIB_CFLAGS -  Flags to pass to cc when compiling the components
-#                       of a shared library (may request position-independent
-#                       code, among other things).
-#       SHLIB_LD -      Base command to use for combining object files
-#                       into a shared library.
-#       SHLIB_LD_LIBS - Dependent libraries for the linker to scan when
-#                       creating shared libraries.  This symbol typically
-#                       goes at the end of the "ld" commands that build
-#                       shared libraries. The value of the symbol is
-#                       "${LIBS}" if all of the dependent libraries should
-#                       be specified when creating a shared library.  If
-#                       dependent libraries should not be specified (as on
-#                       SunOS 4.x, where they cause the link to fail, or in
-#                       general if Tcl and Tk aren't themselves shared
-#                       libraries), then this symbol has an empty string
-#                       as its value.
-#       SHLIB_SUFFIX -  Suffix to use for the names of dynamically loadable
-#                       extensions.  An empty string means we don't know how
-#                       to use shared libraries on this platform.
-#       LIB_SUFFIX -    Specifies everything that comes after the "libfoo"
-#                       in a static or shared library name, using the $VERSION variable
-#                       to put the version in the right place.  This is used
-#                       by platforms that need non-standard library names.
-#                       Examples:  ${VERSION}.so.1.1 on NetBSD, since it needs
-#                       to have a version after the .so, and ${VERSION}.a
-#                       on AIX, since a shared library needs to have
-#                       a .a extension whereas shared objects for loadable
-#                       extensions have a .so extension.  Defaults to
-#                       ${VERSION}${SHLIB_SUFFIX}.
-#       TCL_NEEDS_EXP_FILE -
-#                       1 means that an export file is needed to link to a
-#                       shared library.
-#       TCL_EXP_FILE -  The name of the installed export / import file which
-#                       should be used to link to the Tcl shared library.
-#                       Empty if Tcl is unshared.
-#       TCL_BUILD_EXP_FILE -
-#                       The name of the built export / import file which
-#                       should be used to link to the Tcl shared library.
-#                       Empty if Tcl is unshared.
-#	CFLAGS_DEBUG -
-#			Flags used when running the compiler in debug mode
-#	CFLAGS_OPTIMIZE -
-#			Flags used when running the compiler in optimize mode
-#	CFLAGS -	Additional CFLAGS added as necessary (usually 64-bit)
-#
-#--------------------------------------------------------------------
-
-AC_DEFUN([TEA_CONFIG_CFLAGS], [
-    dnl Make sure we are initialized
-    AC_REQUIRE([TEA_INIT])
-
-    # Step 0.a: Enable 64 bit support?
-
-    AC_MSG_CHECKING([if 64bit support is requested])
-    AC_ARG_ENABLE(64bit,
-	AC_HELP_STRING([--enable-64bit],
-	    [enable 64bit support (default: off)]),
-	[do64bit=$enableval], [do64bit=no])
-    AC_MSG_RESULT([$do64bit])
-
-    # Step 0.b: Enable Solaris 64 bit VIS support?
-
-    AC_MSG_CHECKING([if 64bit Sparc VIS support is requested])
-    AC_ARG_ENABLE(64bit-vis,
-	AC_HELP_STRING([--enable-64bit-vis],
-	    [enable 64bit Sparc VIS support (default: off)]),
-	[do64bitVIS=$enableval], [do64bitVIS=no])
-    AC_MSG_RESULT([$do64bitVIS])
-
-    if test "$do64bitVIS" = "yes"; then
-	# Force 64bit on with VIS
-	do64bit=yes
-    fi
-
-    # Step 0.c: Cross-compiling options for Windows/CE builds?
-
-    if test "${TEA_PLATFORM}" = "windows" ; then
-	AC_MSG_CHECKING([if Windows/CE build is requested])
-	AC_ARG_ENABLE(wince,[  --enable-wince          enable Win/CE support (where applicable)], [doWince=$enableval], [doWince=no])
-	AC_MSG_RESULT([$doWince])
-    fi
-
-    # Step 1: set the variable "system" to hold the name and version number
-    # for the system.
-
-    TEA_CONFIG_SYSTEM
-
-    # Step 2: check for existence of -ldl library.  This is needed because
-    # Linux can use either -ldl or -ldld for dynamic loading.
-
-    AC_CHECK_LIB(dl, dlopen, have_dl=yes, have_dl=no)
-
-    # Require ranlib early so we can override it in special cases below.
-
-    AC_REQUIRE([AC_PROG_RANLIB])
-
-    # Step 3: set configuration options based on system name and version.
-    # This is similar to Tcl's unix/tcl.m4 except that we've added a
-    # "windows" case.
-
-    do64bit_ok=no
-    LDFLAGS_ORIG="$LDFLAGS"
-    # When ld needs options to work in 64-bit mode, put them in
-    # LDFLAGS_ARCH so they eventually end up in LDFLAGS even if [load]
-    # is disabled by the user. [Bug 1016796]
-    LDFLAGS_ARCH=""
-    TCL_EXPORT_FILE_SUFFIX=""
-    UNSHARED_LIB_SUFFIX=""
-    TCL_TRIM_DOTS='`echo ${PACKAGE_VERSION} | tr -d .`'
-    ECHO_VERSION='`echo ${PACKAGE_VERSION}`'
-    TCL_LIB_VERSIONS_OK=ok
-    CFLAGS_DEBUG=-g
-    CFLAGS_OPTIMIZE=-O
-    if test "$GCC" = "yes" ; then
-	CFLAGS_OPTIMIZE=-O2
-	CFLAGS_WARNING="-Wall -Wno-implicit-int"
-    else
-	CFLAGS_WARNING=""
-    fi
-    TCL_NEEDS_EXP_FILE=0
-    TCL_BUILD_EXP_FILE=""
-    TCL_EXP_FILE=""
-dnl FIXME: Replace AC_CHECK_PROG with AC_CHECK_TOOL once cross compiling is fixed.
-dnl AC_CHECK_TOOL(AR, ar)
-    AC_CHECK_PROG(AR, ar, ar)
-    STLIB_LD='${AR} cr'
-    LD_LIBRARY_PATH_VAR="LD_LIBRARY_PATH"
-    case $system in
-	windows)
-	    # This is a 2-stage check to make sure we have the 64-bit SDK
-	    # We have to know where the SDK is installed.
-	    # This magic is based on MS Platform SDK for Win2003 SP1 - hobbs
-	    # MACHINE is IX86 for LINK, but this is used by the manifest,
-	    # which requires x86|amd64|ia64.
-	    MACHINE="X86"
-	    if test "$do64bit" != "no" ; then
-		if test "x${MSSDK}x" = "xx" ; then
-		    MSSDK="C:/Progra~1/Microsoft Platform SDK"
-		fi
-		MSSDK=`echo "$MSSDK" | sed -e  's!\\\!/!g'`
-		PATH64=""
-		case "$do64bit" in
-		    amd64|x64|yes)
-			MACHINE="AMD64" ; # default to AMD64 64-bit build
-			PATH64="${MSSDK}/Bin/Win64/x86/AMD64"
-			;;
-		    ia64)
-			MACHINE="IA64"
-			PATH64="${MSSDK}/Bin/Win64"
-			;;
-		esac
-		if test ! -d "${PATH64}" ; then
-		    AC_MSG_WARN([Could not find 64-bit $MACHINE SDK to enable 64bit mode])
-		    AC_MSG_WARN([Ensure latest Platform SDK is installed])
-		    do64bit="no"
-		else
-		    AC_MSG_RESULT([   Using 64-bit $MACHINE mode])
-		    do64bit_ok="yes"
-		fi
-	    fi
-
-	    if test "$doWince" != "no" ; then
-		if test "$do64bit" != "no" ; then
-		    AC_MSG_ERROR([Windows/CE and 64-bit builds incompatible])
-		fi
-		if test "$GCC" = "yes" ; then
-		    AC_MSG_ERROR([Windows/CE and GCC builds incompatible])
-		fi
-		TEA_PATH_CELIB
-		# Set defaults for common evc4/PPC2003 setup
-		# Currently Tcl requires 300+, possibly 420+ for sockets
-		CEVERSION=420; 		# could be 211 300 301 400 420 ...
-		TARGETCPU=ARMV4;	# could be ARMV4 ARM MIPS SH3 X86 ...
-		ARCH=ARM;		# could be ARM MIPS X86EM ...
-		PLATFORM="Pocket PC 2003"; # or "Pocket PC 2002"
-		if test "$doWince" != "yes"; then
-		    # If !yes then the user specified something
-		    # Reset ARCH to allow user to skip specifying it
-		    ARCH=
-		    eval `echo $doWince | awk -F, '{ \
-	    if (length([$]1)) { printf "CEVERSION=\"%s\"\n", [$]1; \
-	    if ([$]1 < 400)   { printf "PLATFORM=\"Pocket PC 2002\"\n" } }; \
-	    if (length([$]2)) { printf "TARGETCPU=\"%s\"\n", toupper([$]2) }; \
-	    if (length([$]3)) { printf "ARCH=\"%s\"\n", toupper([$]3) }; \
-	    if (length([$]4)) { printf "PLATFORM=\"%s\"\n", [$]4 }; \
-		    }'`
-		    if test "x${ARCH}" = "x" ; then
-			ARCH=$TARGETCPU;
-		    fi
-		fi
-		OSVERSION=WCE$CEVERSION;
-	    	if test "x${WCEROOT}" = "x" ; then
-			WCEROOT="C:/Program Files/Microsoft eMbedded C++ 4.0"
-		    if test ! -d "${WCEROOT}" ; then
-			WCEROOT="C:/Program Files/Microsoft eMbedded Tools"
-		    fi
-		fi
-		if test "x${SDKROOT}" = "x" ; then
-		    SDKROOT="C:/Program Files/Windows CE Tools"
-		    if test ! -d "${SDKROOT}" ; then
-			SDKROOT="C:/Windows CE Tools"
-		    fi
-		fi
-		WCEROOT=`echo "$WCEROOT" | sed -e 's!\\\!/!g'`
-		SDKROOT=`echo "$SDKROOT" | sed -e 's!\\\!/!g'`
-		if test ! -d "${SDKROOT}/${OSVERSION}/${PLATFORM}/Lib/${TARGETCPU}" \
-		    -o ! -d "${WCEROOT}/EVC/${OSVERSION}/bin"; then
-		    AC_MSG_ERROR([could not find PocketPC SDK or target compiler to enable WinCE mode [$CEVERSION,$TARGETCPU,$ARCH,$PLATFORM]])
-		    doWince="no"
-		else
-		    # We could PATH_NOSPACE these, but that's not important,
-		    # as long as we quote them when used.
-		    CEINCLUDE="${SDKROOT}/${OSVERSION}/${PLATFORM}/include"
-		    if test -d "${CEINCLUDE}/${TARGETCPU}" ; then
-			CEINCLUDE="${CEINCLUDE}/${TARGETCPU}"
-		    fi
-		    CELIBPATH="${SDKROOT}/${OSVERSION}/${PLATFORM}/Lib/${TARGETCPU}"
-    		fi
-	    fi
-
-	    if test "$GCC" != "yes" ; then
-	        if test "${SHARED_BUILD}" = "0" ; then
-		    runtime=-MT
-	        else
-		    runtime=-MD
-	        fi
-
-                if test "$do64bit" != "no" ; then
-		    # All this magic is necessary for the Win64 SDK RC1 - hobbs
-		    CC="\"${PATH64}/cl.exe\""
-		    CFLAGS="${CFLAGS} -I\"${MSSDK}/Include\" -I\"${MSSDK}/Include/crt\" -I\"${MSSDK}/Include/crt/sys\""
-		    RC="\"${MSSDK}/bin/rc.exe\""
-		    lflags="-nologo -MACHINE:${MACHINE} -LIBPATH:\"${MSSDK}/Lib/${MACHINE}\""
-		    LINKBIN="\"${PATH64}/link.exe\""
-		    CFLAGS_DEBUG="-nologo -Zi -Od -W3 ${runtime}d"
-		    CFLAGS_OPTIMIZE="-nologo -O2 -W2 ${runtime}"
-		    # Avoid 'unresolved external symbol __security_cookie'
-		    # errors, c.f. http://support.microsoft.com/?id=894573
-		    TEA_ADD_LIBS([bufferoverflowU.lib])
-		elif test "$doWince" != "no" ; then
-		    CEBINROOT="${WCEROOT}/EVC/${OSVERSION}/bin"
-		    if test "${TARGETCPU}" = "X86"; then
-			CC="\"${CEBINROOT}/cl.exe\""
-		    else
-			CC="\"${CEBINROOT}/cl${ARCH}.exe\""
-		    fi
-		    CFLAGS="$CFLAGS -I\"${CELIB_DIR}/inc\" -I\"${CEINCLUDE}\""
-		    RC="\"${WCEROOT}/Common/EVC/bin/rc.exe\""
-		    arch=`echo ${ARCH} | awk '{print tolower([$]0)}'`
-		    defs="${ARCH} _${ARCH}_ ${arch} PALM_SIZE _MT _WINDOWS"
-		    if test "${SHARED_BUILD}" = "1" ; then
-			# Static CE builds require static celib as well
-		    	defs="${defs} _DLL"
-		    fi
-		    for i in $defs ; do
-			AC_DEFINE_UNQUOTED($i, 1, [WinCE def ]$i)
-		    done
-		    AC_DEFINE_UNQUOTED(_WIN32_WCE, $CEVERSION, [_WIN32_WCE version])
-		    AC_DEFINE_UNQUOTED(UNDER_CE, $CEVERSION, [UNDER_CE version])
-		    CFLAGS_DEBUG="-nologo -Zi -Od"
-		    CFLAGS_OPTIMIZE="-nologo -Ox"
-		    lversion=`echo ${CEVERSION} | sed -e 's/\(.\)\(..\)/\1\.\2/'`
-		    lflags="-MACHINE:${ARCH} -LIBPATH:\"${CELIBPATH}\" -subsystem:windowsce,${lversion} -nologo"
-		    LINKBIN="\"${CEBINROOT}/link.exe\""
-		    AC_SUBST(CELIB_DIR)
-		else
-		    RC="rc"
-		    lflags="-nologo"
-    		    LINKBIN="link"
-		    CFLAGS_DEBUG="-nologo -Z7 -Od -W3 -WX ${runtime}d"
-		    CFLAGS_OPTIMIZE="-nologo -O2 -W2 ${runtime}"
-		fi
-	    fi
-
-	    if test "$GCC" = "yes"; then
-		# mingw gcc mode
-		RC="windres"
-		CFLAGS_DEBUG="-g"
-		CFLAGS_OPTIMIZE="-O2 -fomit-frame-pointer"
-		SHLIB_LD="$CC -shared"
-		UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.a'
-		LDFLAGS_CONSOLE="-wl,--subsystem,console ${lflags}"
-		LDFLAGS_WINDOW="-wl,--subsystem,windows ${lflags}"
-	    else
-		SHLIB_LD="${LINKBIN} -dll ${lflags}"
-		# link -lib only works when -lib is the first arg
-		STLIB_LD="${LINKBIN} -lib ${lflags}"
-		UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.lib'
-		PATHTYPE=-w
-		# For information on what debugtype is most useful, see:
-		# http://msdn.microsoft.com/library/en-us/dnvc60/html/gendepdebug.asp
-		# This essentially turns it all on.
-		LDFLAGS_DEBUG="-debug:full -debugtype:both -warn:2"
-		LDFLAGS_OPTIMIZE="-release"
-		if test "$doWince" != "no" ; then
-		    LDFLAGS_CONSOLE="-link ${lflags}"
-		    LDFLAGS_WINDOW=${LDFLAGS_CONSOLE}
-		else
-		    LDFLAGS_CONSOLE="-link -subsystem:console ${lflags}"
-		    LDFLAGS_WINDOW="-link -subsystem:windows ${lflags}"
-		fi
-	    fi
-
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".dll"
-	    SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.dll'
-
-	    TCL_LIB_VERSIONS_OK=nodots
-	    # Bogus to avoid getting this turned off
-	    DL_OBJS="tclLoadNone.obj"
-    	    ;;
-	AIX-*)
-	    if test "${TCL_THREADS}" = "1" -a "$GCC" != "yes" ; then
-		# AIX requires the _r compiler when gcc isn't being used
-		case "${CC}" in
-		    *_r)
-			# ok ...
-			;;
-		    *)
-			CC=${CC}_r
-			;;
-		esac
-		AC_MSG_RESULT([Using $CC for compiling with threads])
-	    fi
-	    LIBS="$LIBS -lc"
-	    SHLIB_CFLAGS=""
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-
-	    DL_OBJS="tclLoadDl.o"
-	    LD_LIBRARY_PATH_VAR="LIBPATH"
-
-	    # Check to enable 64-bit flags for compiler/linker on AIX 4+
-	    if test "$do64bit" = "yes" -a "`uname -v`" -gt "3" ; then
-		if test "$GCC" = "yes" ; then
-		    AC_MSG_WARN([64bit mode not supported with GCC on $system])
-		else 
-		    do64bit_ok=yes
-		    CFLAGS="$CFLAGS -q64"
-		    LDFLAGS_ARCH="-q64"
-		    RANLIB="${RANLIB} -X64"
-		    AR="${AR} -X64"
-		    SHLIB_LD_FLAGS="-b64"
-		fi
-	    fi
-
-	    if test "`uname -m`" = "ia64" ; then
-		# AIX-5 uses ELF style dynamic libraries on IA-64, but not PPC
-		SHLIB_LD="/usr/ccs/bin/ld -G -z text"
-		# AIX-5 has dl* in libc.so
-		DL_LIBS=""
-		if test "$GCC" = "yes" ; then
-		    CC_SEARCH_FLAGS='-Wl,-R,${LIB_RUNTIME_DIR}'
-		else
-		    CC_SEARCH_FLAGS='-R${LIB_RUNTIME_DIR}'
-		fi
-		LD_SEARCH_FLAGS='-R ${LIB_RUNTIME_DIR}'
-	    else
-		if test "$GCC" = "yes" ; then
-		    SHLIB_LD="gcc -shared"
-		else
-		    SHLIB_LD="/bin/ld -bhalt:4 -bM:SRE -bE:lib.exp -H512 -T512 -bnoentry"
-		fi
-		SHLIB_LD="${TCL_SRC_DIR}/unix/ldAix ${SHLIB_LD} ${SHLIB_LD_FLAGS}"
-		DL_LIBS="-ldl"
-		CC_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}'
-		LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
-		TCL_NEEDS_EXP_FILE=1
-		TCL_EXPORT_FILE_SUFFIX='${PACKAGE_VERSION}.exp'
-	    fi
-
-	    # AIX v<=4.1 has some different flags than 4.2+
-	    if test "$system" = "AIX-4.1" -o "`uname -v`" -lt "4" ; then
-		AC_LIBOBJ([tclLoadAix])
-		DL_LIBS="-lld"
-	    fi
-
-	    # On AIX <=v4 systems, libbsd.a has to be linked in to support
-	    # non-blocking file IO.  This library has to be linked in after
-	    # the MATH_LIBS or it breaks the pow() function.  The way to
-	    # insure proper sequencing, is to add it to the tail of MATH_LIBS.
-	    # This library also supplies gettimeofday.
-	    #
-	    # AIX does not have a timezone field in struct tm. When the AIX
-	    # bsd library is used, the timezone global and the gettimeofday
-	    # methods are to be avoided for timezone deduction instead, we
-	    # deduce the timezone by comparing the localtime result on a
-	    # known GMT value.
-
-	    AC_CHECK_LIB(bsd, gettimeofday, libbsd=yes, libbsd=no)
-	    if test $libbsd = yes; then
-	    	MATH_LIBS="$MATH_LIBS -lbsd"
-	    	AC_DEFINE(USE_DELTA_FOR_TZ, 1, [Do we need a special AIX hack for timezones?])
-	    fi
-	    ;;
-	BeOS*)
-	    SHLIB_CFLAGS="-fPIC"
-	    SHLIB_LD="${CC} -nostart"
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS="-ldl"
-
-	    #-----------------------------------------------------------
-	    # Check for inet_ntoa in -lbind, for BeOS (which also needs
-	    # -lsocket, even if the network functions are in -lnet which
-	    # is always linked to, for compatibility.
-	    #-----------------------------------------------------------
-	    AC_CHECK_LIB(bind, inet_ntoa, [LIBS="$LIBS -lbind -lsocket"])
-	    ;;
-	BSD/OS-2.1*|BSD/OS-3*)
-	    SHLIB_CFLAGS=""
-	    SHLIB_LD="shlicc -r"
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS="-ldl"
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    ;;
-	BSD/OS-4.*)
-	    SHLIB_CFLAGS="-export-dynamic -fPIC"
-	    SHLIB_LD="cc -shared"
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS="-ldl"
-	    LDFLAGS="$LDFLAGS -export-dynamic"
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    ;;
-	dgux*)
-	    SHLIB_CFLAGS="-K PIC"
-	    SHLIB_LD="cc -G"
-	    SHLIB_LD_LIBS=""
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS="-ldl"
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    ;;
-	HP-UX-*.11.*)
-	    # Use updated header definitions where possible
-	    AC_DEFINE(_XOPEN_SOURCE_EXTENDED, 1, [Do we want to use the XOPEN network library?])
-	    # Needed by Tcl, but not most extensions
-	    #AC_DEFINE(_XOPEN_SOURCE, 1, [Do we want to use the XOPEN network library?])
-	    #LIBS="$LIBS -lxnet"               # Use the XOPEN network library
-
-	    if test "`uname -m`" = "ia64" ; then
-		SHLIB_SUFFIX=".so"
-	    else
-		SHLIB_SUFFIX=".sl"
-	    fi
-	    AC_CHECK_LIB(dld, shl_load, tcl_ok=yes, tcl_ok=no)
-	    if test "$tcl_ok" = yes; then
-		SHLIB_CFLAGS="+z"
-		SHLIB_LD="ld -b"
-		SHLIB_LD_LIBS='${LIBS}'
-		DL_OBJS="tclLoadShl.o"
-		DL_LIBS="-ldld"
-		LDFLAGS="$LDFLAGS -Wl,-E"
-		CC_SEARCH_FLAGS='-Wl,+s,+b,${LIB_RUNTIME_DIR}:.'
-		LD_SEARCH_FLAGS='+s +b ${LIB_RUNTIME_DIR}:.'
-		LD_LIBRARY_PATH_VAR="SHLIB_PATH"
-	    fi
-	    if test "$GCC" = "yes" ; then
-		SHLIB_LD="gcc -shared"
-		SHLIB_LD_LIBS='${LIBS}'
-		LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
-	    fi
-
-	    # Users may want PA-RISC 1.1/2.0 portable code - needs HP cc
-	    #CFLAGS="$CFLAGS +DAportable"
-
-	    # Check to enable 64-bit flags for compiler/linker
-	    if test "$do64bit" = "yes" ; then
-		if test "$GCC" = "yes" ; then
-		    hpux_arch=`${CC} -dumpmachine`
-		    case $hpux_arch in
-			hppa64*)
-			    # 64-bit gcc in use.  Fix flags for GNU ld.
-			    do64bit_ok=yes
-			    SHLIB_LD="${CC} -shared"
-			    SHLIB_LD_LIBS='${LIBS}'
-			    CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
-			    LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
-			    ;;
-			*)
-			    AC_MSG_WARN([64bit mode not supported with GCC on $system])
-			    ;;
-		    esac
-		else
-		    do64bit_ok=yes
-		    CFLAGS="$CFLAGS +DD64"
-		    LDFLAGS_ARCH="+DD64"
-		fi
-	    fi
-	    ;;
-	HP-UX-*.08.*|HP-UX-*.09.*|HP-UX-*.10.*)
-	    SHLIB_SUFFIX=".sl"
-	    AC_CHECK_LIB(dld, shl_load, tcl_ok=yes, tcl_ok=no)
-	    if test "$tcl_ok" = yes; then
-		SHLIB_CFLAGS="+z"
-		SHLIB_LD="ld -b"
-		SHLIB_LD_LIBS=""
-		DL_OBJS="tclLoadShl.o"
-		DL_LIBS="-ldld"
-		LDFLAGS="$LDFLAGS -Wl,-E"
-		CC_SEARCH_FLAGS='-Wl,+s,+b,${LIB_RUNTIME_DIR}:.'
-		LD_SEARCH_FLAGS='+s +b ${LIB_RUNTIME_DIR}:.'
-		LD_LIBRARY_PATH_VAR="SHLIB_PATH"
-	    fi
-	    ;;
-	IRIX-5.*)
-	    SHLIB_CFLAGS=""
-	    SHLIB_LD="ld -shared -rdata_shared"
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS=""
-	    CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
-	    LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}'
-	    ;;
-	IRIX-6.*)
-	    SHLIB_CFLAGS=""
-	    SHLIB_LD="ld -n32 -shared -rdata_shared"
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS=""
-	    CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
-	    LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}'
-	    if test "$GCC" = "yes" ; then
-		CFLAGS="$CFLAGS -mabi=n32"
-		LDFLAGS="$LDFLAGS -mabi=n32"
-	    else
-		case $system in
-		    IRIX-6.3)
-			# Use to build 6.2 compatible binaries on 6.3.
-			CFLAGS="$CFLAGS -n32 -D_OLD_TERMIOS"
-			;;
-		    *)
-			CFLAGS="$CFLAGS -n32"
-			;;
-		esac
-		LDFLAGS="$LDFLAGS -n32"
-	    fi
-	    ;;
-	IRIX64-6.*)
-	    SHLIB_CFLAGS=""
-	    SHLIB_LD="ld -n32 -shared -rdata_shared"
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS=""
-	    CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
-	    LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}'
-
-	    # Check to enable 64-bit flags for compiler/linker
-
-	    if test "$do64bit" = "yes" ; then
-	        if test "$GCC" = "yes" ; then
-	            AC_MSG_WARN([64bit mode not supported by gcc])
-	        else
-	            do64bit_ok=yes
-	            SHLIB_LD="ld -64 -shared -rdata_shared"
-	            CFLAGS="$CFLAGS -64"
-	            LDFLAGS_ARCH="-64"
-	        fi
-	    fi
-	    ;;
-	Linux*)
-	    SHLIB_CFLAGS="-fPIC"
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-
-	    CFLAGS_OPTIMIZE="-O2 -fomit-frame-pointer"
-	    # egcs-2.91.66 on Redhat Linux 6.0 generates lots of warnings 
-	    # when you inline the string and math operations.  Turn this off to
-	    # get rid of the warnings.
-	    #CFLAGS_OPTIMIZE="${CFLAGS_OPTIMIZE} -D__NO_STRING_INLINES -D__NO_MATH_INLINES"
-
-	    # TEA specific: use LDFLAGS_DEFAULT instead of LDFLAGS here:
-	    SHLIB_LD='${CC} -shared ${CFLAGS} ${LDFLAGS_DEFAULT}'
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS="-ldl"
-	    LDFLAGS="$LDFLAGS -Wl,--export-dynamic"
-	    CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
-	    LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
-	    if test "`uname -m`" = "alpha" ; then
-		CFLAGS="$CFLAGS -mieee"
-	    fi
-	    if test $do64bit = yes; then
-		AC_CACHE_CHECK([if compiler accepts -m64 flag], tcl_cv_cc_m64, [
-		    hold_cflags=$CFLAGS
-		    CFLAGS="$CFLAGS -m64"
-		    AC_TRY_LINK(,, tcl_cv_cc_m64=yes, tcl_cv_cc_m64=no)
-		    CFLAGS=$hold_cflags])
-		if test $tcl_cv_cc_m64 = yes; then
-		    CFLAGS="$CFLAGS -m64"
-		    do64bit_ok=yes
-		fi
-	    fi
-
-	    # The combo of gcc + glibc has a bug related
-	    # to inlining of functions like strtod(). The
-	    # -fno-builtin flag should address this problem
-	    # but it does not work. The -fno-inline flag
-	    # is kind of overkill but it works.
-	    # Disable inlining only when one of the
-	    # files in compat/*.c is being linked in.
-	    if test x"${USE_COMPAT}" != x ; then
-	        CFLAGS="$CFLAGS -fno-inline"
-	    fi
-
-	    ;;
-	GNU*)
-	    SHLIB_CFLAGS="-fPIC"
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-
-	    SHLIB_LD="${CC} -shared"
-	    DL_OBJS=""
-	    DL_LIBS="-ldl"
-	    LDFLAGS="$LDFLAGS -Wl,--export-dynamic"
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    if test "`uname -m`" = "alpha" ; then
-		CFLAGS="$CFLAGS -mieee"
-	    fi
-	    ;;
-	Lynx*)
-	    SHLIB_CFLAGS="-fPIC"
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-	    CFLAGS_OPTIMIZE=-02
-	    SHLIB_LD="${CC} -shared "
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS="-mshared -ldl"
-	    LD_FLAGS="-Wl,--export-dynamic"
-	    CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
-	    LD_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
-	    ;;
-	MP-RAS-02*)
-	    SHLIB_CFLAGS="-K PIC"
-	    SHLIB_LD="cc -G"
-	    SHLIB_LD_LIBS=""
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS="-ldl"
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    ;;
-	MP-RAS-*)
-	    SHLIB_CFLAGS="-K PIC"
-	    SHLIB_LD="cc -G"
-	    SHLIB_LD_LIBS=""
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS="-ldl"
-	    LDFLAGS="$LDFLAGS -Wl,-Bexport"
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    ;;
-	NetBSD-*|FreeBSD-[[1-2]].*)
-	    # NetBSD/SPARC needs -fPIC, -fpic will not do.
-	    SHLIB_CFLAGS="-fPIC"
-	    SHLIB_LD="ld -Bshareable -x"
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS=""
-	    CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
-	    LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}'
-	    AC_CACHE_CHECK([for ELF], tcl_cv_ld_elf, [
-		AC_EGREP_CPP(yes, [
-#ifdef __ELF__
-	yes
-#endif
-		], tcl_cv_ld_elf=yes, tcl_cv_ld_elf=no)])
-	    if test $tcl_cv_ld_elf = yes; then
-		SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.so'
-	    else
-		SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.so.1.0'
-	    fi
-
-	    # Ancient FreeBSD doesn't handle version numbers with dots.
-
-	    UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.a'
-	    TCL_LIB_VERSIONS_OK=nodots
-	    ;;
-	OpenBSD-*)
-	    # OpenBSD/SPARC[64] needs -fPIC, -fpic will not do.
-	    case `machine` in
-	    sparc|sparc64)
-		SHLIB_CFLAGS="-fPIC";;
-	    *)
-		SHLIB_CFLAGS="-fpic";;
-	    esac
-	    SHLIB_LD="${CC} -shared ${SHLIB_CFLAGS}"
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS=""
-	    CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
-	    LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
-	    SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.so.1.0'
-	    AC_CACHE_CHECK([for ELF], tcl_cv_ld_elf, [
-		AC_EGREP_CPP(yes, [
-#ifdef __ELF__
-	yes
-#endif
-		], tcl_cv_ld_elf=yes, tcl_cv_ld_elf=no)])
-	    if test $tcl_cv_ld_elf = yes; then
-		LDFLAGS=-Wl,-export-dynamic
-	    else
-		LDFLAGS=""
-	    fi
-
-	    # OpenBSD doesn't do version numbers with dots.
-	    UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.a'
-	    TCL_LIB_VERSIONS_OK=nodots
-	    ;;
-	FreeBSD-*)
-	    # FreeBSD 3.* and greater have ELF.
-	    SHLIB_CFLAGS="-fPIC"
-	    SHLIB_LD="ld -Bshareable -x"
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS=""
-	    LDFLAGS="$LDFLAGS -export-dynamic"
-	    CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
-	    LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}'
-	    if test "${TCL_THREADS}" = "1" ; then
-		# The -pthread needs to go in the CFLAGS, not LIBS
-		LIBS=`echo $LIBS | sed s/-pthread//`
-		CFLAGS="$CFLAGS -pthread"
-	    	LDFLAGS="$LDFLAGS -pthread"
-	    fi
-	    case $system in
-	    FreeBSD-3.*)
-	    	# FreeBSD-3 doesn't handle version numbers with dots.
-	    	UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.a'
-	    	SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.so'
-	    	TCL_LIB_VERSIONS_OK=nodots
-		;;
-	    esac
-	    ;;
-	Darwin-*)
-	    CFLAGS_OPTIMIZE="-Os"
-	    SHLIB_CFLAGS="-fno-common"
-	    # To avoid discrepancies between what headers configure sees during
-	    # preprocessing tests and compiling tests, move any -isysroot and
-	    # -mmacosx-version-min flags from CFLAGS to CPPFLAGS:
-	    CPPFLAGS="${CPPFLAGS} `echo " ${CFLAGS}" | \
-		awk 'BEGIN {FS=" +-";ORS=" "}; {for (i=2;i<=NF;i++) \
-		if ([$]i~/^(isysroot|mmacosx-version-min)/) print "-"[$]i}'`"
-	    CFLAGS="`echo " ${CFLAGS}" | \
-		awk 'BEGIN {FS=" +-";ORS=" "}; {for (i=2;i<=NF;i++) \
-		if (!([$]i~/^(isysroot|mmacosx-version-min)/)) print "-"[$]i}'`"
-	    if test $do64bit = yes; then
-		case `arch` in
-		    ppc)
-			AC_CACHE_CHECK([if compiler accepts -arch ppc64 flag],
-				tcl_cv_cc_arch_ppc64, [
-			    hold_cflags=$CFLAGS
-			    CFLAGS="$CFLAGS -arch ppc64 -mpowerpc64 -mcpu=G5"
-			    AC_TRY_LINK(,, tcl_cv_cc_arch_ppc64=yes,
-				    tcl_cv_cc_arch_ppc64=no)
-			    CFLAGS=$hold_cflags])
-			if test $tcl_cv_cc_arch_ppc64 = yes; then
-			    CFLAGS="$CFLAGS -arch ppc64 -mpowerpc64 -mcpu=G5"
-			    do64bit_ok=yes
-			fi;;
-		    i386)
-			AC_CACHE_CHECK([if compiler accepts -arch x86_64 flag],
-				tcl_cv_cc_arch_x86_64, [
-			    hold_cflags=$CFLAGS
-			    CFLAGS="$CFLAGS -arch x86_64"
-			    AC_TRY_LINK(,, tcl_cv_cc_arch_x86_64=yes,
-				    tcl_cv_cc_arch_x86_64=no)
-			    CFLAGS=$hold_cflags])
-			if test $tcl_cv_cc_arch_x86_64 = yes; then
-			    CFLAGS="$CFLAGS -arch x86_64"
-			    do64bit_ok=yes
-			fi;;
-		    *)
-			AC_MSG_WARN([Don't know how enable 64-bit on architecture `arch`]);;
-		esac
-	    else
-		# Check for combined 32-bit and 64-bit fat build
-		echo "$CFLAGS " | grep -E -q -- '-arch (ppc64|x86_64) ' && \
-		    echo "$CFLAGS " | grep -E -q -- '-arch (ppc|i386) ' && \
-		    fat_32_64=yes
-	    fi
-	    # TEA specific: use LDFLAGS_DEFAULT instead of LDFLAGS here:
-	    SHLIB_LD='${CC} -dynamiclib ${CFLAGS} ${LDFLAGS_DEFAULT}'
-	    AC_CACHE_CHECK([if ld accepts -single_module flag], tcl_cv_ld_single_module, [
-		hold_ldflags=$LDFLAGS
-		LDFLAGS="$LDFLAGS -dynamiclib -Wl,-single_module"
-		AC_TRY_LINK(, [int i;], tcl_cv_ld_single_module=yes, tcl_cv_ld_single_module=no)
-		LDFLAGS=$hold_ldflags])
-	    if test $tcl_cv_ld_single_module = yes; then
-		SHLIB_LD="${SHLIB_LD} -Wl,-single_module"
-	    fi
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".dylib"
-	    DL_OBJS="tclLoadDyld.o"
-	    DL_LIBS=""
-	    # Don't use -prebind when building for Mac OS X 10.4 or later only:
-	    test "`echo "${MACOSX_DEPLOYMENT_TARGET}" | awk -F '10\\.' '{print int([$]2)}'`" -lt 4 -a \
-		"`echo "${CPPFLAGS}" | awk -F '-mmacosx-version-min=10\\.' '{print int([$]2)}'`" -lt 4 && \
-		LDFLAGS="$LDFLAGS -prebind"
-	    LDFLAGS="$LDFLAGS -headerpad_max_install_names"
-	    AC_CACHE_CHECK([if ld accepts -search_paths_first flag], tcl_cv_ld_search_paths_first, [
-		hold_ldflags=$LDFLAGS
-		LDFLAGS="$LDFLAGS -Wl,-search_paths_first"
-		AC_TRY_LINK(, [int i;], tcl_cv_ld_search_paths_first=yes, tcl_cv_ld_search_paths_first=no)
-		LDFLAGS=$hold_ldflags])
-	    if test $tcl_cv_ld_search_paths_first = yes; then
-		LDFLAGS="$LDFLAGS -Wl,-search_paths_first"
-	    fi
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    LD_LIBRARY_PATH_VAR="DYLD_LIBRARY_PATH"
-
-	    # TEA specific: for Tk extensions, remove 64-bit arch flags from
-	    # CFLAGS et al. for combined 32 & 64 bit fat builds as neither
-	    # TkAqua nor TkX11 can be built for 64-bit at present.
-	    test "$fat_32_64" = yes && test -n "${TK_BIN_DIR}" && for v in CFLAGS CPPFLAGS LDFLAGS; do
-		eval $v'="`echo "$'$v' "|sed -e "s/-arch ppc64 / /g" -e "s/-arch x86_64 / /g"`"'; done
-	    ;;
-	NEXTSTEP-*)
-	    SHLIB_CFLAGS=""
-	    SHLIB_LD="cc -nostdlib -r"
-	    SHLIB_LD_LIBS=""
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadNext.o"
-	    DL_LIBS=""
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    ;;
-	OS/390-*)
-	    CFLAGS_OPTIMIZE=""		# Optimizer is buggy
-	    AC_DEFINE(_OE_SOCKETS, 1,	# needed in sys/socket.h
-		[Should OS/390 do the right thing with sockets?])
-	    ;;      
-	OSF1-1.0|OSF1-1.1|OSF1-1.2)
-	    # OSF/1 1.[012] from OSF, and derivatives, including Paragon OSF/1
-	    SHLIB_CFLAGS=""
-	    # Hack: make package name same as library name
-	    SHLIB_LD='ld -R -export $@:'
-	    SHLIB_LD_LIBS=""
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadOSF.o"
-	    DL_LIBS=""
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    ;;
-	OSF1-1.*)
-	    # OSF/1 1.3 from OSF using ELF, and derivatives, including AD2
-	    SHLIB_CFLAGS="-fPIC"
-	    if test "$SHARED_BUILD" = "1" ; then
-	        SHLIB_LD="ld -shared"
-	    else
-	        SHLIB_LD="ld -non_shared"
-	    fi
-	    SHLIB_LD_LIBS=""
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS=""
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    ;;
-	OSF1-V*)
-	    # Digital OSF/1
-	    SHLIB_CFLAGS=""
-	    if test "$SHARED_BUILD" = "1" ; then
-	        SHLIB_LD='ld -shared -expect_unresolved "*"'
-	    else
-	        SHLIB_LD='ld -non_shared -expect_unresolved "*"'
-	    fi
-	    SHLIB_LD_LIBS=""
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS=""
-	    CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
-	    LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}'
-	    if test "$GCC" = "yes" ; then
-		CFLAGS="$CFLAGS -mieee"
-            else
-		CFLAGS="$CFLAGS -DHAVE_TZSET -std1 -ieee"
-	    fi
-	    # see pthread_intro(3) for pthread support on osf1, k.furukawa
-	    if test "${TCL_THREADS}" = "1" ; then
-		CFLAGS="$CFLAGS -DHAVE_PTHREAD_ATTR_SETSTACKSIZE"
-		CFLAGS="$CFLAGS -DTCL_THREAD_STACK_MIN=PTHREAD_STACK_MIN*64"
-		LIBS=`echo $LIBS | sed s/-lpthreads//`
-		if test "$GCC" = "yes" ; then
-		    LIBS="$LIBS -lpthread -lmach -lexc"
-		else
-		    CFLAGS="$CFLAGS -pthread"
-		    LDFLAGS="$LDFLAGS -pthread"
-		fi
-	    fi
-
-	    ;;
-	QNX-6*)
-	    # QNX RTP
-	    # This may work for all QNX, but it was only reported for v6.
-	    SHLIB_CFLAGS="-fPIC"
-	    SHLIB_LD="ld -Bshareable -x"
-	    SHLIB_LD_LIBS=""
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    # dlopen is in -lc on QNX
-	    DL_LIBS=""
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    ;;
-	SCO_SV-3.2*)
-	    # Note, dlopen is available only on SCO 3.2.5 and greater. However,
-	    # this test works, since "uname -s" was non-standard in 3.2.4 and
-	    # below.
-	    if test "$GCC" = "yes" ; then
-	    	SHLIB_CFLAGS="-fPIC -melf"
-	    	LDFLAGS="$LDFLAGS -melf -Wl,-Bexport"
-	    else
-	    	SHLIB_CFLAGS="-Kpic -belf"
-	    	LDFLAGS="$LDFLAGS -belf -Wl,-Bexport"
-	    fi
-	    SHLIB_LD="ld -G"
-	    SHLIB_LD_LIBS=""
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS=""
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    ;;
-	SINIX*5.4*)
-	    SHLIB_CFLAGS="-K PIC"
-	    SHLIB_LD="cc -G"
-	    SHLIB_LD_LIBS=""
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS="-ldl"
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    ;;
-	SunOS-4*)
-	    SHLIB_CFLAGS="-PIC"
-	    SHLIB_LD="ld"
-	    SHLIB_LD_LIBS=""
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS="-ldl"
-	    CC_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}'
-	    LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
-
-	    # SunOS can't handle version numbers with dots in them in library
-	    # specs, like -ltcl7.5, so use -ltcl75 instead.  Also, it
-	    # requires an extra version number at the end of .so file names.
-	    # So, the library has to have a name like libtcl75.so.1.0
-
-	    SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.so.1.0'
-	    UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.a'
-	    TCL_LIB_VERSIONS_OK=nodots
-	    ;;
-	SunOS-5.[[0-6]])
-	    # Careful to not let 5.10+ fall into this case
-
-	    # Note: If _REENTRANT isn't defined, then Solaris
-	    # won't define thread-safe library routines.
-
-	    AC_DEFINE(_REENTRANT, 1, [Do we want the reentrant OS API?])
-	    AC_DEFINE(_POSIX_PTHREAD_SEMANTICS, 1,
-		[Do we really want to follow the standard? Yes we do!])
-
-	    SHLIB_CFLAGS="-KPIC"
-
-	    # Note: need the LIBS below, otherwise Tk won't find Tcl's
-	    # symbols when dynamically loaded into tclsh.
-
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS="-ldl"
-	    if test "$GCC" = "yes" ; then
-		SHLIB_LD="$CC -shared"
-		CC_SEARCH_FLAGS='-Wl,-R,${LIB_RUNTIME_DIR}'
-		LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
-	    else
-		SHLIB_LD="/usr/ccs/bin/ld -G -z text"
-		CC_SEARCH_FLAGS='-R ${LIB_RUNTIME_DIR}'
-		LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
-	    fi
-	    ;;
-	SunOS-5*)
-	    # Note: If _REENTRANT isn't defined, then Solaris
-	    # won't define thread-safe library routines.
-
-	    AC_DEFINE(_REENTRANT, 1, [Do we want the reentrant OS API?])
-	    AC_DEFINE(_POSIX_PTHREAD_SEMANTICS, 1,
-		[Do we really want to follow the standard? Yes we do!])
-
-	    SHLIB_CFLAGS="-KPIC"
-
-	    # Check to enable 64-bit flags for compiler/linker
-	    if test "$do64bit" = "yes" ; then
-		arch=`isainfo`
-		if test "$arch" = "sparcv9 sparc" ; then
-			if test "$GCC" = "yes" ; then
-			    if test "`gcc -dumpversion | awk -F. '{print [$]1}'`" -lt "3" ; then
-				AC_MSG_WARN([64bit mode not supported with GCC < 3.2 on $system])
-			    else
-				do64bit_ok=yes
-				CFLAGS="$CFLAGS -m64 -mcpu=v9"
-				LDFLAGS="$LDFLAGS -m64 -mcpu=v9"
-				SHLIB_CFLAGS="-fPIC"
-			    fi
-			else
-			    do64bit_ok=yes
-			    if test "$do64bitVIS" = "yes" ; then
-				CFLAGS="$CFLAGS -xarch=v9a"
-			    	LDFLAGS_ARCH="-xarch=v9a"
-			    else
-				CFLAGS="$CFLAGS -xarch=v9"
-			    	LDFLAGS_ARCH="-xarch=v9"
-			    fi
-			    # Solaris 64 uses this as well
-			    #LD_LIBRARY_PATH_VAR="LD_LIBRARY_PATH_64"
-			fi
-		elif test "$arch" = "amd64 i386" ; then
-		    if test "$GCC" = "yes" ; then
-			AC_MSG_WARN([64bit mode not supported with GCC on $system])
-		    else
-			do64bit_ok=yes
-			CFLAGS="$CFLAGS -xarch=amd64"
-			LDFLAGS="$LDFLAGS -xarch=amd64"
-		    fi
-		else
-		    AC_MSG_WARN([64bit mode not supported for $arch])
-		fi
-	    fi
-	    
-	    # Note: need the LIBS below, otherwise Tk won't find Tcl's
-	    # symbols when dynamically loaded into tclsh.
-
-	    SHLIB_LD_LIBS='${LIBS}'
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS="-ldl"
-	    if test "$GCC" = "yes" ; then
-		SHLIB_LD="$CC -shared"
-		CC_SEARCH_FLAGS='-Wl,-R,${LIB_RUNTIME_DIR}'
-		LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
-		if test "$do64bit_ok" = "yes" ; then
-		    # We need to specify -static-libgcc or we need to
-		    # add the path to the sparv9 libgcc.
-		    # JH: static-libgcc is necessary for core Tcl, but may
-		    # not be necessary for extensions.
-		    SHLIB_LD="$SHLIB_LD -m64 -mcpu=v9 -static-libgcc"
-		    # for finding sparcv9 libgcc, get the regular libgcc
-		    # path, remove so name and append 'sparcv9'
-		    #v9gcclibdir="`gcc -print-file-name=libgcc_s.so` | ..."
-		    #CC_SEARCH_FLAGS="${CC_SEARCH_FLAGS},-R,$v9gcclibdir"
-		fi
-	    else
-		SHLIB_LD="/usr/ccs/bin/ld -G -z text"
-		CC_SEARCH_FLAGS='-Wl,-R,${LIB_RUNTIME_DIR}'
-		LD_SEARCH_FLAGS='-R ${LIB_RUNTIME_DIR}'
-	    fi
-	    ;;
-	UNIX_SV* | UnixWare-5*)
-	    SHLIB_CFLAGS="-KPIC"
-	    SHLIB_LD="cc -G"
-	    SHLIB_LD_LIBS=""
-	    SHLIB_SUFFIX=".so"
-	    DL_OBJS="tclLoadDl.o"
-	    DL_LIBS="-ldl"
-	    # Some UNIX_SV* systems (unixware 1.1.2 for example) have linkers
-	    # that don't grok the -Bexport option.  Test that it does.
-	    AC_CACHE_CHECK([for ld accepts -Bexport flag], tcl_cv_ld_Bexport, [
-		hold_ldflags=$LDFLAGS
-		LDFLAGS="$LDFLAGS -Wl,-Bexport"
-		AC_TRY_LINK(, [int i;], tcl_cv_ld_Bexport=yes, tcl_cv_ld_Bexport=no)
-	        LDFLAGS=$hold_ldflags])
-	    if test $tcl_cv_ld_Bexport = yes; then
-		LDFLAGS="$LDFLAGS -Wl,-Bexport"
-	    fi
-	    CC_SEARCH_FLAGS=""
-	    LD_SEARCH_FLAGS=""
-	    ;;
-    esac
-
-    if test "$do64bit" = "yes" -a "$do64bit_ok" = "no" ; then
-	AC_MSG_WARN([64bit support being disabled -- don't know magic for this platform])
-    fi
-
-dnl # Add any CPPFLAGS set in the environment to our CFLAGS, but delay doing so
-dnl # until the end of configure, as configure's compile and link tests use
-dnl # both CPPFLAGS and CFLAGS (unlike our compile and link) but configure's
-dnl # preprocessing tests use only CPPFLAGS.
-    AC_CONFIG_COMMANDS_PRE([CFLAGS="${CFLAGS} ${CPPFLAGS}"; CPPFLAGS=""])
-
-    # Step 4: disable dynamic loading if requested via a command-line switch.
-
-    AC_ARG_ENABLE(load,
-	AC_HELP_STRING([--enable-load],
-	    [allow dynamic loading and "load" command (default: on)]),
-	[tcl_ok=$enableval], [tcl_ok=yes])
-    if test "$tcl_ok" = "no"; then
-	DL_OBJS=""
-    fi
-
-    if test "x$DL_OBJS" != "x" ; then
-	BUILD_DLTEST="\$(DLTEST_TARGETS)"
-    else
-	echo "Can't figure out how to do dynamic loading or shared libraries"
-	echo "on this system."
-	SHLIB_CFLAGS=""
-	SHLIB_LD=""
-	SHLIB_SUFFIX=""
-	DL_OBJS="tclLoadNone.o"
-	DL_LIBS=""
-	LDFLAGS="$LDFLAGS_ORIG"
-	CC_SEARCH_FLAGS=""
-	LD_SEARCH_FLAGS=""
-	BUILD_DLTEST=""
-    fi
-    LDFLAGS="$LDFLAGS $LDFLAGS_ARCH"
-
-    # If we're running gcc, then change the C flags for compiling shared
-    # libraries to the right flags for gcc, instead of those for the
-    # standard manufacturer compiler.
-
-    if test "$DL_OBJS" != "tclLoadNone.o" ; then
-	if test "$GCC" = "yes" ; then
-	    case $system in
-		AIX-*)
-		    ;;
-		BSD/OS*)
-		    ;;
-		IRIX*)
-		    ;;
-		NetBSD-*|FreeBSD-*)
-		    ;;
-		Darwin-*)
-		    ;;
-		SCO_SV-3.2*)
-		    ;;
-		windows)
-		    ;;
-		*)
-		    SHLIB_CFLAGS="-fPIC"
-		    ;;
-	    esac
-	fi
-    fi
-
-    if test "$SHARED_LIB_SUFFIX" = "" ; then
-	SHARED_LIB_SUFFIX='${PACKAGE_VERSION}${SHLIB_SUFFIX}'
-    fi
-    if test "$UNSHARED_LIB_SUFFIX" = "" ; then
-	UNSHARED_LIB_SUFFIX='${PACKAGE_VERSION}.a'
-    fi
-
-    AC_SUBST(DL_LIBS)
-
-    AC_SUBST(CFLAGS_DEBUG)
-    AC_SUBST(CFLAGS_OPTIMIZE)
-    AC_SUBST(CFLAGS_WARNING)
-
-    AC_SUBST(STLIB_LD)
-    AC_SUBST(SHLIB_LD)
-
-    AC_SUBST(SHLIB_LD_LIBS)
-    AC_SUBST(SHLIB_CFLAGS)
-
-    AC_SUBST(LD_LIBRARY_PATH_VAR)
-
-    # These must be called after we do the basic CFLAGS checks and
-    # verify any possible 64-bit or similar switches are necessary
-    TEA_TCL_EARLY_FLAGS
-    TEA_TCL_64BIT_FLAGS
-])
-
-#--------------------------------------------------------------------
-# TEA_SERIAL_PORT
-#
-#	Determine which interface to use to talk to the serial port.
-#	Note that #include lines must begin in leftmost column for
-#	some compilers to recognize them as preprocessor directives,
-#	and some build environments have stdin not pointing at a
-#	pseudo-terminal (usually /dev/null instead.)
-#
-# Arguments:
-#	none
-#	
-# Results:
-#
-#	Defines only one of the following vars:
-#		HAVE_SYS_MODEM_H
-#		USE_TERMIOS
-#		USE_TERMIO
-#		USE_SGTTY
-#
-#--------------------------------------------------------------------
-
-AC_DEFUN([TEA_SERIAL_PORT], [
-    AC_CHECK_HEADERS(sys/modem.h)
-    AC_CACHE_CHECK([termios vs. termio vs. sgtty], tcl_cv_api_serial, [
-    AC_TRY_RUN([
-#include <termios.h>
-
-int main() {
-    struct termios t;
-    if (tcgetattr(0, &t) == 0) {
-	cfsetospeed(&t, 0);
-	t.c_cflag |= PARENB | PARODD | CSIZE | CSTOPB;
-	return 0;
-    }
-    return 1;
-}], tcl_cv_api_serial=termios, tcl_cv_api_serial=no, tcl_cv_api_serial=no)
-    if test $tcl_cv_api_serial = no ; then
-	AC_TRY_RUN([
-#include <termio.h>
-
-int main() {
-    struct termio t;
-    if (ioctl(0, TCGETA, &t) == 0) {
-	t.c_cflag |= CBAUD | PARENB | PARODD | CSIZE | CSTOPB;
-	return 0;
-    }
-    return 1;
-}], tcl_cv_api_serial=termio, tcl_cv_api_serial=no, tcl_cv_api_serial=no)
-    fi
-    if test $tcl_cv_api_serial = no ; then
-	AC_TRY_RUN([
-#include <sgtty.h>
-
-int main() {
-    struct sgttyb t;
-    if (ioctl(0, TIOCGETP, &t) == 0) {
-	t.sg_ospeed = 0;
-	t.sg_flags |= ODDP | EVENP | RAW;
-	return 0;
-    }
-    return 1;
-}], tcl_cv_api_serial=sgtty, tcl_cv_api_serial=no, tcl_cv_api_serial=no)
-    fi
-    if test $tcl_cv_api_serial = no ; then
-	AC_TRY_RUN([
-#include <termios.h>
-#include <errno.h>
-
-int main() {
-    struct termios t;
-    if (tcgetattr(0, &t) == 0
-	|| errno == ENOTTY || errno == ENXIO || errno == EINVAL) {
-	cfsetospeed(&t, 0);
-	t.c_cflag |= PARENB | PARODD | CSIZE | CSTOPB;
-	return 0;
-    }
-    return 1;
-}], tcl_cv_api_serial=termios, tcl_cv_api_serial=no, tcl_cv_api_serial=no)
-    fi
-    if test $tcl_cv_api_serial = no; then
-	AC_TRY_RUN([
-#include <termio.h>
-#include <errno.h>
-
-int main() {
-    struct termio t;
-    if (ioctl(0, TCGETA, &t) == 0
-	|| errno == ENOTTY || errno == ENXIO || errno == EINVAL) {
-	t.c_cflag |= CBAUD | PARENB | PARODD | CSIZE | CSTOPB;
-	return 0;
-    }
-    return 1;
-    }], tcl_cv_api_serial=termio, tcl_cv_api_serial=no, tcl_cv_api_serial=no)
-    fi
-    if test $tcl_cv_api_serial = no; then
-	AC_TRY_RUN([
-#include <sgtty.h>
-#include <errno.h>
-
-int main() {
-    struct sgttyb t;
-    if (ioctl(0, TIOCGETP, &t) == 0
-	|| errno == ENOTTY || errno == ENXIO || errno == EINVAL) {
-	t.sg_ospeed = 0;
-	t.sg_flags |= ODDP | EVENP | RAW;
-	return 0;
-    }
-    return 1;
-}], tcl_cv_api_serial=sgtty, tcl_cv_api_serial=none, tcl_cv_api_serial=none)
-    fi])
-    case $tcl_cv_api_serial in
-	termios) AC_DEFINE(USE_TERMIOS, 1, [Use the termios API for serial lines]);;
-	termio)  AC_DEFINE(USE_TERMIO, 1, [Use the termio API for serial lines]);;
-	sgtty)   AC_DEFINE(USE_SGTTY, 1, [Use the sgtty API for serial lines]);;
-    esac
-])
-
-#--------------------------------------------------------------------
-# TEA_MISSING_POSIX_HEADERS
-#
-#	Supply substitutes for missing POSIX header files.  Special
-#	notes:
-#	    - stdlib.h doesn't define strtol, strtoul, or
-#	      strtod insome versions of SunOS
-#	    - some versions of string.h don't declare procedures such
-#	      as strstr
-#
-# Arguments:
-#	none
-#	
-# Results:
-#
-#	Defines some of the following vars:
-#		NO_DIRENT_H
-#		NO_ERRNO_H
-#		NO_VALUES_H
-#		HAVE_LIMITS_H or NO_LIMITS_H
-#		NO_STDLIB_H
-#		NO_STRING_H
-#		NO_SYS_WAIT_H
-#		NO_DLFCN_H
-#		HAVE_SYS_PARAM_H
-#
-#		HAVE_STRING_H ?
-#
-# tkUnixPort.h checks for HAVE_LIMITS_H, so do both HAVE and
-# CHECK on limits.h
-#--------------------------------------------------------------------
-
-AC_DEFUN([TEA_MISSING_POSIX_HEADERS], [
-    AC_CACHE_CHECK([dirent.h], tcl_cv_dirent_h, [
-    AC_TRY_LINK([#include <sys/types.h>
-#include <dirent.h>], [
-#ifndef _POSIX_SOURCE
-#   ifdef __Lynx__
-	/*
-	 * Generate compilation error to make the test fail:  Lynx headers
-	 * are only valid if really in the POSIX environment.
-	 */
-
-	missing_procedure();
-#   endif
-#endif
-DIR *d;
-struct dirent *entryPtr;
-char *p;
-d = opendir("foobar");
-entryPtr = readdir(d);
-p = entryPtr->d_name;
-closedir(d);
-], tcl_cv_dirent_h=yes, tcl_cv_dirent_h=no)])
-
-    if test $tcl_cv_dirent_h = no; then
-	AC_DEFINE(NO_DIRENT_H, 1, [Do we have <dirent.h>?])
-    fi
-
-    AC_CHECK_HEADER(errno.h, , [AC_DEFINE(NO_ERRNO_H, 1, [Do we have <errno.h>?])])
-    AC_CHECK_HEADER(float.h, , [AC_DEFINE(NO_FLOAT_H, 1, [Do we have <float.h>?])])
-    AC_CHECK_HEADER(values.h, , [AC_DEFINE(NO_VALUES_H, 1, [Do we have <values.h>?])])
-    AC_CHECK_HEADER(limits.h,
-	[AC_DEFINE(HAVE_LIMITS_H, 1, [Do we have <limits.h>?])],
-	[AC_DEFINE(NO_LIMITS_H, 1, [Do we have <limits.h>?])])
-    AC_CHECK_HEADER(stdlib.h, tcl_ok=1, tcl_ok=0)
-    AC_EGREP_HEADER(strtol, stdlib.h, , tcl_ok=0)
-    AC_EGREP_HEADER(strtoul, stdlib.h, , tcl_ok=0)
-    AC_EGREP_HEADER(strtod, stdlib.h, , tcl_ok=0)
-    if test $tcl_ok = 0; then
-	AC_DEFINE(NO_STDLIB_H, 1, [Do we have <stdlib.h>?])
-    fi
-    AC_CHECK_HEADER(string.h, tcl_ok=1, tcl_ok=0)
-    AC_EGREP_HEADER(strstr, string.h, , tcl_ok=0)
-    AC_EGREP_HEADER(strerror, string.h, , tcl_ok=0)
-
-    # See also memmove check below for a place where NO_STRING_H can be
-    # set and why.
-
-    if test $tcl_ok = 0; then
-	AC_DEFINE(NO_STRING_H, 1, [Do we have <string.h>?])
-    fi
-
-    AC_CHECK_HEADER(sys/wait.h, , [AC_DEFINE(NO_SYS_WAIT_H, 1, [Do we have <sys/wait.h>?])])
-    AC_CHECK_HEADER(dlfcn.h, , [AC_DEFINE(NO_DLFCN_H, 1, [Do we have <dlfcn.h>?])])
-
-    # OS/390 lacks sys/param.h (and doesn't need it, by chance).
-    AC_HAVE_HEADERS(sys/param.h)
-])
-
-#--------------------------------------------------------------------
-# TEA_PATH_X
-#
-#	Locate the X11 header files and the X11 library archive.  Try
-#	the ac_path_x macro first, but if it doesn't find the X stuff
-#	(e.g. because there's no xmkmf program) then check through
-#	a list of possible directories.  Under some conditions the
-#	autoconf macro will return an include directory that contains
-#	no include files, so double-check its result just to be safe.
-#
-#	This should be called after TEA_CONFIG_CFLAGS as setting the
-#	LIBS line can confuse some configure macro magic.
-#
-# Arguments:
-#	none
-#	
-# Results:
-#
-#	Sets the following vars:
-#		XINCLUDES
-#		XLIBSW
-#		PKG_LIBS (appends to)
-#
-#--------------------------------------------------------------------
-
-AC_DEFUN([TEA_PATH_X], [
-    if test "${TEA_WINDOWINGSYSTEM}" = "x11" ; then
-	TEA_PATH_UNIX_X
-    fi
-])
-
-AC_DEFUN([TEA_PATH_UNIX_X], [
-    AC_PATH_X
-    not_really_there=""
-    if test "$no_x" = ""; then
-	if test "$x_includes" = ""; then
-	    AC_TRY_CPP([#include <X11/XIntrinsic.h>], , not_really_there="yes")
-	else
-	    if test ! -r $x_includes/X11/Intrinsic.h; then
-		not_really_there="yes"
-	    fi
-	fi
-    fi
-    if test "$no_x" = "yes" -o "$not_really_there" = "yes"; then
-	AC_MSG_CHECKING([for X11 header files])
-	found_xincludes="no"
-	AC_TRY_CPP([#include <X11/Intrinsic.h>], found_xincludes="yes", found_xincludes="no")
-	if test "$found_xincludes" = "no"; then
-	    dirs="/usr/unsupported/include /usr/local/include /usr/X386/include /usr/X11R6/include /usr/X11R5/include /usr/include/X11R5 /usr/include/X11R4 /usr/openwin/include /usr/X11/include /usr/sww/include"
-	    for i in $dirs ; do
-		if test -r $i/X11/Intrinsic.h; then
-		    AC_MSG_RESULT([$i])
-		    XINCLUDES=" -I$i"
-		    found_xincludes="yes"
-		    break
-		fi
-	    done
-	fi
-    else
-	if test "$x_includes" != ""; then
-	    XINCLUDES="-I$x_includes"
-	    found_xincludes="yes"
-	fi
-    fi
-    if test found_xincludes = "no"; then
-	AC_MSG_RESULT([couldn't find any!])
-    fi
-
-    if test "$no_x" = yes; then
-	AC_MSG_CHECKING([for X11 libraries])
-	XLIBSW=nope
-	dirs="/usr/unsupported/lib /usr/local/lib /usr/X386/lib /usr/X11R6/lib /usr/X11R5/lib /usr/lib/X11R5 /usr/lib/X11R4 /usr/openwin/lib /usr/X11/lib /usr/sww/X11/lib"
-	for i in $dirs ; do
-	    if test -r $i/libX11.a -o -r $i/libX11.so -o -r $i/libX11.sl; then
-		AC_MSG_RESULT([$i])
-		XLIBSW="-L$i -lX11"
-		x_libraries="$i"
-		break
-	    fi
-	done
-    else
-	if test "$x_libraries" = ""; then
-	    XLIBSW=-lX11
-	else
-	    XLIBSW="-L$x_libraries -lX11"
-	fi
-    fi
-    if test "$XLIBSW" = nope ; then
-	AC_CHECK_LIB(Xwindow, XCreateWindow, XLIBSW=-lXwindow)
-    fi
-    if test "$XLIBSW" = nope ; then
-	AC_MSG_RESULT([could not find any!  Using -lX11.])
-	XLIBSW=-lX11
-    fi
-    if test x"${XLIBSW}" != x ; then
-	PKG_LIBS="${PKG_LIBS} ${XLIBSW}"
-    fi
-])
-
-#--------------------------------------------------------------------
-# TEA_BLOCKING_STYLE
-#
-#	The statements below check for systems where POSIX-style
-#	non-blocking I/O (O_NONBLOCK) doesn't work or is unimplemented. 
-#	On these systems (mostly older ones), use the old BSD-style
-#	FIONBIO approach instead.
-#
-# Arguments:
-#	none
-#	
-# Results:
-#
-#	Defines some of the following vars:
-#		HAVE_SYS_IOCTL_H
-#		HAVE_SYS_FILIO_H
-#		USE_FIONBIO
-#		O_NONBLOCK
-#
-#--------------------------------------------------------------------
-
-AC_DEFUN([TEA_BLOCKING_STYLE], [
-    AC_CHECK_HEADERS(sys/ioctl.h)
-    AC_CHECK_HEADERS(sys/filio.h)
-    TEA_CONFIG_SYSTEM
-    AC_MSG_CHECKING([FIONBIO vs. O_NONBLOCK for nonblocking I/O])
-    case $system in
-	# There used to be code here to use FIONBIO under AIX.  However, it
-	# was reported that FIONBIO doesn't work under AIX 3.2.5.  Since
-	# using O_NONBLOCK seems fine under AIX 4.*, I removed the FIONBIO
-	# code (JO, 5/31/97).
-
-	OSF*)
-	    AC_DEFINE(USE_FIONBIO, 1, [Should we use FIONBIO?])
-	    AC_MSG_RESULT([FIONBIO])
-	    ;;
-	SunOS-4*)
-	    AC_DEFINE(USE_FIONBIO, 1, [Should we use FIONBIO?])
-	    AC_MSG_RESULT([FIONBIO])
-	    ;;
-	*)
-	    AC_MSG_RESULT([O_NONBLOCK])
-	    ;;
-    esac
-])
-
-#--------------------------------------------------------------------
-# TEA_TIME_HANLDER
-#
-#	Checks how the system deals with time.h, what time structures
-#	are used on the system, and what fields the structures have.
-#
-# Arguments:
-#	none
-#	
-# Results:
-#
-#	Defines some of the following vars:
-#		USE_DELTA_FOR_TZ
-#		HAVE_TM_GMTOFF
-#		HAVE_TM_TZADJ
-#		HAVE_TIMEZONE_VAR
-#
-#--------------------------------------------------------------------
-
-AC_DEFUN([TEA_TIME_HANDLER], [
-    AC_CHECK_HEADERS(sys/time.h)
-    AC_HEADER_TIME
-    AC_STRUCT_TIMEZONE
-
-    AC_CHECK_FUNCS(gmtime_r localtime_r)
-
-    AC_CACHE_CHECK([tm_tzadj in struct tm], tcl_cv_member_tm_tzadj, [
-	AC_TRY_COMPILE([#include <time.h>], [struct tm tm; tm.tm_tzadj;],
-	    tcl_cv_member_tm_tzadj=yes, tcl_cv_member_tm_tzadj=no)])
-    if test $tcl_cv_member_tm_tzadj = yes ; then
-	AC_DEFINE(HAVE_TM_TZADJ, 1, [Should we use the tm_tzadj field of struct tm?])
-    fi
-
-    AC_CACHE_CHECK([tm_gmtoff in struct tm], tcl_cv_member_tm_gmtoff, [
-	AC_TRY_COMPILE([#include <time.h>], [struct tm tm; tm.tm_gmtoff;],
-	    tcl_cv_member_tm_gmtoff=yes, tcl_cv_member_tm_gmtoff=no)])
-    if test $tcl_cv_member_tm_gmtoff = yes ; then
-	AC_DEFINE(HAVE_TM_GMTOFF, 1, [Should we use the tm_gmtoff field of struct tm?])
-    fi
-
-    #
-    # Its important to include time.h in this check, as some systems
-    # (like convex) have timezone functions, etc.
-    #
-    AC_CACHE_CHECK([long timezone variable], tcl_cv_timezone_long, [
-	AC_TRY_COMPILE([#include <time.h>],
-	    [extern long timezone;
-	    timezone += 1;
-	    exit (0);],
-	    tcl_cv_timezone_long=yes, tcl_cv_timezone_long=no)])
-    if test $tcl_cv_timezone_long = yes ; then
-	AC_DEFINE(HAVE_TIMEZONE_VAR, 1, [Should we use the global timezone variable?])
-    else
-	#
-	# On some systems (eg IRIX 6.2), timezone is a time_t and not a long.
-	#
-	AC_CACHE_CHECK([time_t timezone variable], tcl_cv_timezone_time, [
-	    AC_TRY_COMPILE([#include <time.h>],
-		[extern time_t timezone;
-		timezone += 1;
-		exit (0);],
-		tcl_cv_timezone_time=yes, tcl_cv_timezone_time=no)])
-	if test $tcl_cv_timezone_time = yes ; then
-	    AC_DEFINE(HAVE_TIMEZONE_VAR, 1, [Should we use the global timezone variable?])
-	fi
-    fi
-])
-
-#--------------------------------------------------------------------
-# TEA_BUGGY_STRTOD
-#
-#	Under Solaris 2.4, strtod returns the wrong value for the
-#	terminating character under some conditions.  Check for this
-#	and if the problem exists use a substitute procedure
-#	"fixstrtod" (provided by Tcl) that corrects the error.
-#	Also, on Compaq's Tru64 Unix 5.0,
-#	strtod(" ") returns 0.0 instead of a failure to convert.
-#
-# Arguments:
-#	none
-#	
-# Results:
-#
-#	Might defines some of the following vars:
-#		strtod (=fixstrtod)
-#
-#--------------------------------------------------------------------
-
-AC_DEFUN([TEA_BUGGY_STRTOD], [
-    AC_CHECK_FUNC(strtod, tcl_strtod=1, tcl_strtod=0)
-    if test "$tcl_strtod" = 1; then
-	AC_CACHE_CHECK([for Solaris2.4/Tru64 strtod bugs], tcl_cv_strtod_buggy,[
-	    AC_TRY_RUN([
-		extern double strtod();
-		int main() {
-		    char *infString="Inf", *nanString="NaN", *spaceString=" ";
-		    char *term;
-		    double value;
-		    value = strtod(infString, &term);
-		    if ((term != infString) && (term[-1] == 0)) {
-			exit(1);
-		    }
-		    value = strtod(nanString, &term);
-		    if ((term != nanString) && (term[-1] == 0)) {
-			exit(1);
-		    }
-		    value = strtod(spaceString, &term);
-		    if (term == (spaceString+1)) {
-			exit(1);
-		    }
-		    exit(0);
-		}], tcl_cv_strtod_buggy=ok, tcl_cv_strtod_buggy=buggy,
-		    tcl_cv_strtod_buggy=buggy)])
-	if test "$tcl_cv_strtod_buggy" = buggy; then
-	    AC_LIBOBJ([fixstrtod])
-	    USE_COMPAT=1
-	    AC_DEFINE(strtod, fixstrtod, [Do we want to use the strtod() in compat?])
-	fi
-    fi
-])
-
-#--------------------------------------------------------------------
-# TEA_TCL_LINK_LIBS
-#
-#	Search for the libraries needed to link the Tcl shell.
-#	Things like the math library (-lm) and socket stuff (-lsocket vs.
-#	-lnsl) are dealt with here.
-#
-# Arguments:
-#	Requires the following vars to be set in the Makefile:
-#		DL_LIBS
-#		LIBS
-#		MATH_LIBS
-#	
-# Results:
-#
-#	Subst's the following var:
-#		TCL_LIBS
-#		MATH_LIBS
-#
-#	Might append to the following vars:
-#		LIBS
-#
-#	Might define the following vars:
-#		HAVE_NET_ERRNO_H
-#
-#--------------------------------------------------------------------
-
-AC_DEFUN([TEA_TCL_LINK_LIBS], [
-    #--------------------------------------------------------------------
-    # On a few very rare systems, all of the libm.a stuff is
-    # already in libc.a.  Set compiler flags accordingly.
-    # Also, Linux requires the "ieee" library for math to work
-    # right (and it must appear before "-lm").
-    #--------------------------------------------------------------------
-
-    AC_CHECK_FUNC(sin, MATH_LIBS="", MATH_LIBS="-lm")
-    AC_CHECK_LIB(ieee, main, [MATH_LIBS="-lieee $MATH_LIBS"])
-
-    #--------------------------------------------------------------------
-    # Interactive UNIX requires -linet instead of -lsocket, plus it
-    # needs net/errno.h to define the socket-related error codes.
-    #--------------------------------------------------------------------
-
-    AC_CHECK_LIB(inet, main, [LIBS="$LIBS -linet"])
-    AC_CHECK_HEADER(net/errno.h, [
-	AC_DEFINE(HAVE_NET_ERRNO_H, 1, [Do we have <net/errno.h>?])])
-
-    #--------------------------------------------------------------------
-    #	Check for the existence of the -lsocket and -lnsl libraries.
-    #	The order here is important, so that they end up in the right
-    #	order in the command line generated by make.  Here are some
-    #	special considerations:
-    #	1. Use "connect" and "accept" to check for -lsocket, and
-    #	   "gethostbyname" to check for -lnsl.
-    #	2. Use each function name only once:  can't redo a check because
-    #	   autoconf caches the results of the last check and won't redo it.
-    #	3. Use -lnsl and -lsocket only if they supply procedures that
-    #	   aren't already present in the normal libraries.  This is because
-    #	   IRIX 5.2 has libraries, but they aren't needed and they're
-    #	   bogus:  they goof up name resolution if used.
-    #	4. On some SVR4 systems, can't use -lsocket without -lnsl too.
-    #	   To get around this problem, check for both libraries together
-    #	   if -lsocket doesn't work by itself.
-    #--------------------------------------------------------------------
-
-    tcl_checkBoth=0
-    AC_CHECK_FUNC(connect, tcl_checkSocket=0, tcl_checkSocket=1)
-    if test "$tcl_checkSocket" = 1; then
-	AC_CHECK_FUNC(setsockopt, , [AC_CHECK_LIB(socket, setsockopt,
-	    LIBS="$LIBS -lsocket", tcl_checkBoth=1)])
-    fi
-    if test "$tcl_checkBoth" = 1; then
-	tk_oldLibs=$LIBS
-	LIBS="$LIBS -lsocket -lnsl"
-	AC_CHECK_FUNC(accept, tcl_checkNsl=0, [LIBS=$tk_oldLibs])
-    fi
-    AC_CHECK_FUNC(gethostbyname, , [AC_CHECK_LIB(nsl, gethostbyname,
-	    [LIBS="$LIBS -lnsl"])])
-    
-    # Don't perform the eval of the libraries here because DL_LIBS
-    # won't be set until we call TEA_CONFIG_CFLAGS
-
-    TCL_LIBS='${DL_LIBS} ${LIBS} ${MATH_LIBS}'
-    AC_SUBST(TCL_LIBS)
-    AC_SUBST(MATH_LIBS)
-])
-
-#--------------------------------------------------------------------
-# TEA_TCL_EARLY_FLAGS
-#
-#	Check for what flags are needed to be passed so the correct OS
-#	features are available.
-#
-# Arguments:
-#	None
-#	
-# Results:
-#
-#	Might define the following vars:
-#		_ISOC99_SOURCE
-#		_LARGEFILE64_SOURCE
-#		_LARGEFILE_SOURCE64
-#
-#--------------------------------------------------------------------
-
-AC_DEFUN([TEA_TCL_EARLY_FLAG],[
-    AC_CACHE_VAL([tcl_cv_flag_]translit($1,[A-Z],[a-z]),
-	AC_TRY_COMPILE([$2], $3, [tcl_cv_flag_]translit($1,[A-Z],[a-z])=no,
-	    AC_TRY_COMPILE([[#define ]$1[ 1
-]$2], $3,
-		[tcl_cv_flag_]translit($1,[A-Z],[a-z])=yes,
-		[tcl_cv_flag_]translit($1,[A-Z],[a-z])=no)))
-    if test ["x${tcl_cv_flag_]translit($1,[A-Z],[a-z])[}" = "xyes"] ; then
-	AC_DEFINE($1, 1, [Add the ]$1[ flag when building])
-	tcl_flags="$tcl_flags $1"
-    fi
-])
-
-AC_DEFUN([TEA_TCL_EARLY_FLAGS],[
-    AC_MSG_CHECKING([for required early compiler flags])
-    tcl_flags=""
-    TEA_TCL_EARLY_FLAG(_ISOC99_SOURCE,[#include <stdlib.h>],
-	[char *p = (char *)strtoll; char *q = (char *)strtoull;])
-    TEA_TCL_EARLY_FLAG(_LARGEFILE64_SOURCE,[#include <sys/stat.h>],
-	[struct stat64 buf; int i = stat64("/", &buf);])
-    TEA_TCL_EARLY_FLAG(_LARGEFILE_SOURCE64,[#include <sys/stat.h>],
-	[char *p = (char *)open64;])
-    if test "x${tcl_flags}" = "x" ; then
-	AC_MSG_RESULT([none])
-    else
-	AC_MSG_RESULT([${tcl_flags}])
-    fi
-])
-
-#--------------------------------------------------------------------
-# TEA_TCL_64BIT_FLAGS
-#
-#	Check for what is defined in the way of 64-bit features.
-#
-# Arguments:
-#	None
-#	
-# Results:
-#
-#	Might define the following vars:
-#		TCL_WIDE_INT_IS_LONG
-#		TCL_WIDE_INT_TYPE
-#		HAVE_STRUCT_DIRENT64
-#		HAVE_STRUCT_STAT64
-#		HAVE_TYPE_OFF64_T
-#
-#--------------------------------------------------------------------
-
-AC_DEFUN([TEA_TCL_64BIT_FLAGS], [
-    AC_MSG_CHECKING([for 64-bit integer type])
-    AC_CACHE_VAL(tcl_cv_type_64bit,[
-	tcl_cv_type_64bit=none
-	# See if the compiler knows natively about __int64
-	AC_TRY_COMPILE(,[__int64 value = (__int64) 0;],
-	    tcl_type_64bit=__int64, tcl_type_64bit="long long")
-	# See if we should use long anyway  Note that we substitute in the
-	# type that is our current guess for a 64-bit type inside this check
-	# program, so it should be modified only carefully...
-        AC_TRY_COMPILE(,[switch (0) { 
-            case 1: case (sizeof(]${tcl_type_64bit}[)==sizeof(long)): ; 
-        }],tcl_cv_type_64bit=${tcl_type_64bit})])
-    if test "${tcl_cv_type_64bit}" = none ; then
-	AC_DEFINE(TCL_WIDE_INT_IS_LONG, 1, [Are wide integers to be implemented with C 'long's?])
-	AC_MSG_RESULT([using long])
-    elif test "${tcl_cv_type_64bit}" = "__int64" \
-		-a "${TEA_PLATFORM}" = "windows" ; then
-	# We actually want to use the default tcl.h checks in this
-	# case to handle both TCL_WIDE_INT_TYPE and TCL_LL_MODIFIER*
-	AC_MSG_RESULT([using Tcl header defaults])
-    else
-	AC_DEFINE_UNQUOTED(TCL_WIDE_INT_TYPE,${tcl_cv_type_64bit},
-	    [What type should be used to define wide integers?])
-	AC_MSG_RESULT([${tcl_cv_type_64bit}])
-
-	# Now check for auxiliary declarations
-	AC_CACHE_CHECK([for struct dirent64], tcl_cv_struct_dirent64,[
-	    AC_TRY_COMPILE([#include <sys/types.h>
-#include <sys/dirent.h>],[struct dirent64 p;],
-		tcl_cv_struct_dirent64=yes,tcl_cv_struct_dirent64=no)])
-	if test "x${tcl_cv_struct_dirent64}" = "xyes" ; then
-	    AC_DEFINE(HAVE_STRUCT_DIRENT64, 1, [Is 'struct dirent64' in <sys/types.h>?])
-	fi
-
-	AC_CACHE_CHECK([for struct stat64], tcl_cv_struct_stat64,[
-	    AC_TRY_COMPILE([#include <sys/stat.h>],[struct stat64 p;
-],
-		tcl_cv_struct_stat64=yes,tcl_cv_struct_stat64=no)])
-	if test "x${tcl_cv_struct_stat64}" = "xyes" ; then
-	    AC_DEFINE(HAVE_STRUCT_STAT64, 1, [Is 'struct stat64' in <sys/stat.h>?])
-	fi
-
-	AC_CHECK_FUNCS(open64 lseek64)
-	AC_MSG_CHECKING([for off64_t])
-	AC_CACHE_VAL(tcl_cv_type_off64_t,[
-	    AC_TRY_COMPILE([#include <sys/types.h>],[off64_t offset;
-],
-		tcl_cv_type_off64_t=yes,tcl_cv_type_off64_t=no)])
-	dnl Define HAVE_TYPE_OFF64_T only when the off64_t type and the
-	dnl functions lseek64 and open64 are defined.
-	if test "x${tcl_cv_type_off64_t}" = "xyes" && \
-	        test "x${ac_cv_func_lseek64}" = "xyes" && \
-	        test "x${ac_cv_func_open64}" = "xyes" ; then
-	    AC_DEFINE(HAVE_TYPE_OFF64_T, 1, [Is off64_t in <sys/types.h>?])
-	    AC_MSG_RESULT([yes])
-	else
-	    AC_MSG_RESULT([no])
-	fi
-    fi
-])
-
-##
-## Here ends the standard Tcl configuration bits and starts the
-## TEA specific functions
-##
-
-#------------------------------------------------------------------------
-# TEA_INIT --
-#
-#	Init various Tcl Extension Architecture (TEA) variables.
-#	This should be the first called TEA_* macro.
-#
-# Arguments:
-#	none
-#
-# Results:
-#
-#	Defines and substs the following vars:
-#		CYGPATH
-#		EXEEXT
-#	Defines only:
-#		TEA_VERSION
-#		TEA_INITED
-#		TEA_PLATFORM (windows or unix)
-#
-# "cygpath" is used on windows to generate native path names for include
-# files. These variables should only be used with the compiler and linker
-# since they generate native path names.
-#
-# EXEEXT
-#	Select the executable extension based on the host type.  This
-#	is a lightweight replacement for AC_EXEEXT that doesn't require
-#	a compiler.
-#------------------------------------------------------------------------
-
-AC_DEFUN([TEA_INIT], [
-    # TEA extensions pass this us the version of TEA they think they
-    # are compatible with.
-    TEA_VERSION="3.6"
-
-    AC_MSG_CHECKING([for correct TEA configuration])
-    if test x"${PACKAGE_NAME}" = x ; then
-	AC_MSG_ERROR([
-The PACKAGE_NAME variable must be defined by your TEA configure.in])
-    fi
-    if test x"$1" = x ; then
-	AC_MSG_ERROR([
-TEA version not specified.])
-    elif test "$1" != "${TEA_VERSION}" ; then
-	AC_MSG_RESULT([warning: requested TEA version "$1", have "${TEA_VERSION}"])
-    else
-	AC_MSG_RESULT([ok (TEA ${TEA_VERSION})])
-    fi
-    case "`uname -s`" in
-	*win32*|*WIN32*|*CYGWIN_NT*|*CYGWIN_9*|*CYGWIN_ME*|*MINGW32_*)
-	    AC_CHECK_PROG(CYGPATH, cygpath, cygpath -w, echo)
-	    EXEEXT=".exe"
-	    TEA_PLATFORM="windows"
-	    ;;
-	*)
-	    CYGPATH=echo
-	    EXEEXT=""
-	    TEA_PLATFORM="unix"
-	    ;;
-    esac
-
-    # Check if exec_prefix is set. If not use fall back to prefix.
-    # Note when adjusted, so that TEA_PREFIX can correct for this.
-    # This is needed for recursive configures, since autoconf propagates
-    # $prefix, but not $exec_prefix (doh!).
-    if test x$exec_prefix = xNONE ; then
-	exec_prefix_default=yes
-	exec_prefix=$prefix
-    fi
-
-    AC_SUBST(EXEEXT)
-    AC_SUBST(CYGPATH)
-
-    # This package name must be replaced statically for AC_SUBST to work
-    AC_SUBST(PKG_LIB_FILE)
-    # Substitute STUB_LIB_FILE in case package creates a stub library too.
-    AC_SUBST(PKG_STUB_LIB_FILE)
-
-    # We AC_SUBST these here to ensure they are subst'ed,
-    # in case the user doesn't call TEA_ADD_...
-    AC_SUBST(PKG_STUB_SOURCES)
-    AC_SUBST(PKG_STUB_OBJECTS)
-    AC_SUBST(PKG_TCL_SOURCES)
-    AC_SUBST(PKG_HEADERS)
-    AC_SUBST(PKG_INCLUDES)
-    AC_SUBST(PKG_LIBS)
-    AC_SUBST(PKG_CFLAGS)
-])
-
-#------------------------------------------------------------------------
-# TEA_ADD_SOURCES --
-#
-#	Specify one or more source files.  Users should check for
-#	the right platform before adding to their list.
-#	It is not important to specify the directory, as long as it is
-#	in the generic, win or unix subdirectory of $(srcdir).
-#
-# Arguments:
-#	one or more file names
-#
-# Results:
-#
-#	Defines and substs the following vars:
-#		PKG_SOURCES
-#		PKG_OBJECTS
-#------------------------------------------------------------------------
-AC_DEFUN([TEA_ADD_SOURCES], [
-    vars="$@"
-    for i in $vars; do
-	case $i in
-	    [\$]*)
-		# allow $-var names
-		PKG_SOURCES="$PKG_SOURCES $i"
-		PKG_OBJECTS="$PKG_OBJECTS $i"
-		;;
-	    *)
-		# check for existence - allows for generic/win/unix VPATH
-		if test ! -f "${srcdir}/$i" -a ! -f "${srcdir}/generic/$i" \
-		    -a ! -f "${srcdir}/win/$i" -a ! -f "${srcdir}/unix/$i" \
-		    ; then
-		    AC_MSG_ERROR([could not find source file '$i'])
-		fi
-		PKG_SOURCES="$PKG_SOURCES $i"
-		# this assumes it is in a VPATH dir
-		i=`basename $i`
-		# handle user calling this before or after TEA_SETUP_COMPILER
-		if test x"${OBJEXT}" != x ; then
-		    j="`echo $i | sed -e 's/\.[[^.]]*$//'`.${OBJEXT}"
-		else
-		    j="`echo $i | sed -e 's/\.[[^.]]*$//'`.\${OBJEXT}"
-		fi
-		PKG_OBJECTS="$PKG_OBJECTS $j"
-		;;
-	esac
-    done
-    AC_SUBST(PKG_SOURCES)
-    AC_SUBST(PKG_OBJECTS)
-])
-
-#------------------------------------------------------------------------
-# TEA_ADD_STUB_SOURCES --
-#
-#	Specify one or more source files.  Users should check for
-#	the right platform before adding to their list.
-#	It is not important to specify the directory, as long as it is
-#	in the generic, win or unix subdirectory of $(srcdir).
-#
-# Arguments:
-#	one or more file names
-#
-# Results:
-#
-#	Defines and substs the following vars:
-#		PKG_STUB_SOURCES
-#		PKG_STUB_OBJECTS
-#------------------------------------------------------------------------
-AC_DEFUN([TEA_ADD_STUB_SOURCES], [
-    vars="$@"
-    for i in $vars; do
-	# check for existence - allows for generic/win/unix VPATH
-	if test ! -f "${srcdir}/$i" -a ! -f "${srcdir}/generic/$i" \
-	    -a ! -f "${srcdir}/win/$i" -a ! -f "${srcdir}/unix/$i" \
-	    ; then
-	    AC_MSG_ERROR([could not find stub source file '$i'])
-	fi
-	PKG_STUB_SOURCES="$PKG_STUB_SOURCES $i"
-	# this assumes it is in a VPATH dir
-	i=`basename $i`
-	# handle user calling this before or after TEA_SETUP_COMPILER
-	if test x"${OBJEXT}" != x ; then
-	    j="`echo $i | sed -e 's/\.[[^.]]*$//'`.${OBJEXT}"
-	else
-	    j="`echo $i | sed -e 's/\.[[^.]]*$//'`.\${OBJEXT}"
-	fi
-	PKG_STUB_OBJECTS="$PKG_STUB_OBJECTS $j"
-    done
-    AC_SUBST(PKG_STUB_SOURCES)
-    AC_SUBST(PKG_STUB_OBJECTS)
-])
-
-#------------------------------------------------------------------------
-# TEA_ADD_TCL_SOURCES --
-#
-#	Specify one or more Tcl source files.  These should be platform
-#	independent runtime files.
-#
-# Arguments:
-#	one or more file names
-#
-# Results:
-#
-#	Defines and substs the following vars:
-#		PKG_TCL_SOURCES
-#------------------------------------------------------------------------
-AC_DEFUN([TEA_ADD_TCL_SOURCES], [
-    vars="$@"
-    for i in $vars; do
-	# check for existence, be strict because it is installed
-	if test ! -f "${srcdir}/$i" ; then
-	    AC_MSG_ERROR([could not find tcl source file '${srcdir}/$i'])
-	fi
-	PKG_TCL_SOURCES="$PKG_TCL_SOURCES $i"
-    done
-    AC_SUBST(PKG_TCL_SOURCES)
-])
-
-#------------------------------------------------------------------------
-# TEA_ADD_HEADERS --
-#
-#	Specify one or more source headers.  Users should check for
-#	the right platform before adding to their list.
-#
-# Arguments:
-#	one or more file names
-#
-# Results:
-#
-#	Defines and substs the following vars:
-#		PKG_HEADERS
-#------------------------------------------------------------------------
-AC_DEFUN([TEA_ADD_HEADERS], [
-    vars="$@"
-    for i in $vars; do
-	# check for existence, be strict because it is installed
-	if test ! -f "${srcdir}/$i" ; then
-	    AC_MSG_ERROR([could not find header file '${srcdir}/$i'])
-	fi
-	PKG_HEADERS="$PKG_HEADERS $i"
-    done
-    AC_SUBST(PKG_HEADERS)
-])
-
-#------------------------------------------------------------------------
-# TEA_ADD_INCLUDES --
-#
-#	Specify one or more include dirs.  Users should check for
-#	the right platform before adding to their list.
-#
-# Arguments:
-#	one or more file names
-#
-# Results:
-#
-#	Defines and substs the following vars:
-#		PKG_INCLUDES
-#------------------------------------------------------------------------
-AC_DEFUN([TEA_ADD_INCLUDES], [
-    vars="$@"
-    for i in $vars; do
-	PKG_INCLUDES="$PKG_INCLUDES $i"
-    done
-    AC_SUBST(PKG_INCLUDES)
-])
-
-#------------------------------------------------------------------------
-# TEA_ADD_LIBS --
-#
-#	Specify one or more libraries.  Users should check for
-#	the right platform before adding to their list.  For Windows,
-#	libraries provided in "foo.lib" format will be converted to
-#	"-lfoo" when using GCC (mingw).
-#
-# Arguments:
-#	one or more file names
-#
-# Results:
-#
-#	Defines and substs the following vars:
-#		PKG_LIBS
-#------------------------------------------------------------------------
-AC_DEFUN([TEA_ADD_LIBS], [
-    vars="$@"
-    for i in $vars; do
-	if test "${TEA_PLATFORM}" = "windows" -a "$GCC" = "yes" ; then
-	    # Convert foo.lib to -lfoo for GCC.  No-op if not *.lib
-	    i=`echo "$i" | sed -e 's/^\([[^-]].*\)\.lib[$]/-l\1/i'`
-	fi
-	PKG_LIBS="$PKG_LIBS $i"
-    done
-    AC_SUBST(PKG_LIBS)
-])
-
-#------------------------------------------------------------------------
-# TEA_ADD_CFLAGS --
-#
-#	Specify one or more CFLAGS.  Users should check for
-#	the right platform before adding to their list.
-#
-# Arguments:
-#	one or more file names
-#
-# Results:
-#
-#	Defines and substs the following vars:
-#		PKG_CFLAGS
-#------------------------------------------------------------------------
-AC_DEFUN([TEA_ADD_CFLAGS], [
-    PKG_CFLAGS="$PKG_CFLAGS $@"
-    AC_SUBST(PKG_CFLAGS)
-])
-
-#------------------------------------------------------------------------
-# TEA_PREFIX --
-#
-#	Handle the --prefix=... option by defaulting to what Tcl gave
-#
-# Arguments:
-#	none
-#
-# Results:
-#
-#	If --prefix or --exec-prefix was not specified, $prefix and
-#	$exec_prefix will be set to the values given to Tcl when it was
-#	configured.
-#------------------------------------------------------------------------
-AC_DEFUN([TEA_PREFIX], [
-    if test "${prefix}" = "NONE"; then
-	prefix_default=yes
-	if test x"${TCL_PREFIX}" != x; then
-	    AC_MSG_NOTICE([--prefix defaulting to TCL_PREFIX ${TCL_PREFIX}])
-	    prefix=${TCL_PREFIX}
-	else
-	    AC_MSG_NOTICE([--prefix defaulting to /usr/local])
-	    prefix=/usr/local
-	fi
-    fi
-    if test "${exec_prefix}" = "NONE" -a x"${prefix_default}" = x"yes" \
-	-o x"${exec_prefix_default}" = x"yes" ; then
-	if test x"${TCL_EXEC_PREFIX}" != x; then
-	    AC_MSG_NOTICE([--exec-prefix defaulting to TCL_EXEC_PREFIX ${TCL_EXEC_PREFIX}])
-	    exec_prefix=${TCL_EXEC_PREFIX}
-	else
-	    AC_MSG_NOTICE([--exec-prefix defaulting to ${prefix}])
-	    exec_prefix=$prefix
-	fi
-    fi
-])
-
-#------------------------------------------------------------------------
-# TEA_SETUP_COMPILER_CC --
-#
-#	Do compiler checks the way we want.  This is just a replacement
-#	for AC_PROG_CC in TEA configure.in files to make them cleaner.
-#
-# Arguments:
-#	none
-#
-# Results:
-#
-#	Sets up CC var and other standard bits we need to make executables.
-#------------------------------------------------------------------------
-AC_DEFUN([TEA_SETUP_COMPILER_CC], [
-    # Don't put any macros that use the compiler (e.g. AC_TRY_COMPILE)
-    # in this macro, they need to go into TEA_SETUP_COMPILER instead.
-
-    # If the user did not set CFLAGS, set it now to keep
-    # the AC_PROG_CC macro from adding "-g -O2".
-    if test "${CFLAGS+set}" != "set" ; then
-	CFLAGS=""
-    fi
-
-    AC_PROG_CC
-    AC_PROG_CPP
-
-    AC_PROG_INSTALL
-
-    #--------------------------------------------------------------------
-    # Checks to see if the make program sets the $MAKE variable.
-    #--------------------------------------------------------------------
-
-    AC_PROG_MAKE_SET
-
-    #--------------------------------------------------------------------
-    # Find ranlib
-    #--------------------------------------------------------------------
-
-    AC_PROG_RANLIB
-
-    #--------------------------------------------------------------------
-    # Determines the correct binary file extension (.o, .obj, .exe etc.)
-    #--------------------------------------------------------------------
-
-    AC_OBJEXT
-    AC_EXEEXT
-])
-
-#------------------------------------------------------------------------
-# TEA_SETUP_COMPILER --
-#
-#	Do compiler checks that use the compiler.  This must go after
-#	TEA_SETUP_COMPILER_CC, which does the actual compiler check.
-#
-# Arguments:
-#	none
-#
-# Results:
-#
-#	Sets up CC var and other standard bits we need to make executables.
-#------------------------------------------------------------------------
-AC_DEFUN([TEA_SETUP_COMPILER], [
-    # Any macros that use the compiler (e.g. AC_TRY_COMPILE) have to go here.
-    AC_REQUIRE([TEA_SETUP_COMPILER_CC])
-
-    #------------------------------------------------------------------------
-    # If we're using GCC, see if the compiler understands -pipe. If so, use it.
-    # It makes compiling go faster.  (This is only a performance feature.)
-    #------------------------------------------------------------------------
-
-    if test -z "$no_pipe" -a -n "$GCC"; then
-	AC_CACHE_CHECK([if the compiler understands -pipe],
-	    tcl_cv_cc_pipe, [
-	    hold_cflags=$CFLAGS; CFLAGS="$CFLAGS -pipe"
-	    AC_TRY_COMPILE(,, tcl_cv_cc_pipe=yes, tcl_cv_cc_pipe=no)
-	    CFLAGS=$hold_cflags])
-	if test $tcl_cv_cc_pipe = yes; then
-	    CFLAGS="$CFLAGS -pipe"
-	fi
-    fi
-
-    #--------------------------------------------------------------------
-    # Common compiler flag setup
-    #--------------------------------------------------------------------
-
-    AC_C_BIGENDIAN
-    if test "${TEA_PLATFORM}" = "unix" ; then
-	TEA_TCL_LINK_LIBS
-	TEA_MISSING_POSIX_HEADERS
-	# Let the user call this, because if it triggers, they will
-	# need a compat/strtod.c that is correct.  Users can also
-	# use Tcl_GetDouble(FromObj) instead.
-	#TEA_BUGGY_STRTOD
-    fi
-])
-
-#------------------------------------------------------------------------
-# TEA_MAKE_LIB --
-#
-#	Generate a line that can be used to build a shared/unshared library
-#	in a platform independent manner.
-#
-# Arguments:
-#	none
-#
-#	Requires:
-#
-# Results:
-#
-#	Defines the following vars:
-#	CFLAGS -	Done late here to note disturb other AC macros
-#       MAKE_LIB -      Command to execute to build the Tcl library;
-#                       differs depending on whether or not Tcl is being
-#                       compiled as a shared library.
-#	MAKE_SHARED_LIB	Makefile rule for building a shared library
-#	MAKE_STATIC_LIB	Makefile rule for building a static library
-#	MAKE_STUB_LIB	Makefile rule for building a stub library
-#------------------------------------------------------------------------
-
-AC_DEFUN([TEA_MAKE_LIB], [
-    if test "${TEA_PLATFORM}" = "windows" -a "$GCC" != "yes"; then
-	MAKE_STATIC_LIB="\${STLIB_LD} -out:\[$]@ \$(PKG_OBJECTS)"
-	MAKE_SHARED_LIB="\${SHLIB_LD} \${SHLIB_LD_LIBS} \${LDFLAGS_DEFAULT} -out:\[$]@ \$(PKG_OBJECTS)"
-	MAKE_STUB_LIB="\${STLIB_LD} -out:\[$]@ \$(PKG_STUB_OBJECTS)"
-    else
-	MAKE_STATIC_LIB="\${STLIB_LD} \[$]@ \$(PKG_OBJECTS)"
-	MAKE_SHARED_LIB="\${SHLIB_LD} -o \[$]@ \$(PKG_OBJECTS) \${SHLIB_LD_LIBS}"
-	MAKE_STUB_LIB="\${STLIB_LD} \[$]@ \$(PKG_STUB_OBJECTS)"
-    fi
-
-    if test "${SHARED_BUILD}" = "1" ; then
-	MAKE_LIB="${MAKE_SHARED_LIB} "
-    else
-	MAKE_LIB="${MAKE_STATIC_LIB} "
-    fi
-
-    #--------------------------------------------------------------------
-    # Shared libraries and static libraries have different names.
-    # Use the double eval to make sure any variables in the suffix is
-    # substituted. (@@@ Might not be necessary anymore)
-    #--------------------------------------------------------------------
-
-    if test "${TEA_PLATFORM}" = "windows" ; then
-	if test "${SHARED_BUILD}" = "1" ; then
-	    # We force the unresolved linking of symbols that are really in
-	    # the private libraries of Tcl and Tk.
-	    SHLIB_LD_LIBS="${SHLIB_LD_LIBS} \"`${CYGPATH} ${TCL_BIN_DIR}/${TCL_STUB_LIB_FILE}`\""
-	    if test x"${TK_BIN_DIR}" != x ; then
-		SHLIB_LD_LIBS="${SHLIB_LD_LIBS} \"`${CYGPATH} ${TK_BIN_DIR}/${TK_STUB_LIB_FILE}`\""
-	    fi
-	    eval eval "PKG_LIB_FILE=${PACKAGE_NAME}${SHARED_LIB_SUFFIX}"
-	else
-	    eval eval "PKG_LIB_FILE=${PACKAGE_NAME}${UNSHARED_LIB_SUFFIX}"
-	fi
-	# Some packages build their own stubs libraries
-	eval eval "PKG_STUB_LIB_FILE=${PACKAGE_NAME}stub${UNSHARED_LIB_SUFFIX}"
-	if test "$GCC" = "yes"; then
-	    PKG_STUB_LIB_FILE=lib${PKG_STUB_LIB_FILE}
-	fi
-	# These aren't needed on Windows (either MSVC or gcc)
-	RANLIB=:
-	RANLIB_STUB=:
-    else
-	RANLIB_STUB="${RANLIB}"
-	if test "${SHARED_BUILD}" = "1" ; then
-	    SHLIB_LD_LIBS="${SHLIB_LD_LIBS} ${TCL_STUB_LIB_SPEC}"
-	    if test x"${TK_BIN_DIR}" != x ; then
-		SHLIB_LD_LIBS="${SHLIB_LD_LIBS} ${TK_STUB_LIB_SPEC}"
-	    fi
-	    eval eval "PKG_LIB_FILE=lib${PACKAGE_NAME}${SHARED_LIB_SUFFIX}"
-	    RANLIB=:
-	else
-	    eval eval "PKG_LIB_FILE=lib${PACKAGE_NAME}${UNSHARED_LIB_SUFFIX}"
-	fi
-	# Some packages build their own stubs libraries
-	eval eval "PKG_STUB_LIB_FILE=lib${PACKAGE_NAME}stub${UNSHARED_LIB_SUFFIX}"
-    fi
-
-    # These are escaped so that only CFLAGS is picked up at configure time.
-    # The other values will be substituted at make time.
-    CFLAGS="${CFLAGS} \${CFLAGS_DEFAULT} \${CFLAGS_WARNING}"
-    if test "${SHARED_BUILD}" = "1" ; then
-	CFLAGS="${CFLAGS} \${SHLIB_CFLAGS}"
-    fi
-
-    AC_SUBST(MAKE_LIB)
-    AC_SUBST(MAKE_SHARED_LIB)
-    AC_SUBST(MAKE_STATIC_LIB)
-    AC_SUBST(MAKE_STUB_LIB)
-    AC_SUBST(RANLIB_STUB)
-])
-
-#------------------------------------------------------------------------
-# TEA_LIB_SPEC --
-#
-#	Compute the name of an existing object library located in libdir
-#	from the given base name and produce the appropriate linker flags.
-#
-# Arguments:
-#	basename	The base name of the library without version
-#			numbers, extensions, or "lib" prefixes.
-#	extra_dir	Extra directory in which to search for the
-#			library.  This location is used first, then
-#			$prefix/$exec-prefix, then some defaults.
-#
-# Requires:
-#	TEA_INIT and TEA_PREFIX must be called first.
-#
-# Results:
-#
-#	Defines the following vars:
-#		${basename}_LIB_NAME	The computed library name.
-#		${basename}_LIB_SPEC	The computed linker flags.
-#------------------------------------------------------------------------
-
-AC_DEFUN([TEA_LIB_SPEC], [
-    AC_MSG_CHECKING([for $1 library])
-
-    # Look in exec-prefix for the library (defined by TEA_PREFIX).
-
-    tea_lib_name_dir="${exec_prefix}/lib"
-
-    # Or in a user-specified location.
-
-    if test x"$2" != x ; then
-	tea_extra_lib_dir=$2
-    else
-	tea_extra_lib_dir=NONE
-    fi
-
-    for i in \
-	    `ls -dr ${tea_extra_lib_dir}/$1[[0-9]]*.lib 2>/dev/null ` \
-	    `ls -dr ${tea_extra_lib_dir}/lib$1[[0-9]]* 2>/dev/null ` \
-	    `ls -dr ${tea_lib_name_dir}/$1[[0-9]]*.lib 2>/dev/null ` \
-	    `ls -dr ${tea_lib_name_dir}/lib$1[[0-9]]* 2>/dev/null ` \
-	    `ls -dr /usr/lib/$1[[0-9]]*.lib 2>/dev/null ` \
-	    `ls -dr /usr/lib/lib$1[[0-9]]* 2>/dev/null ` \
-	    `ls -dr /usr/local/lib/$1[[0-9]]*.lib 2>/dev/null ` \
-	    `ls -dr /usr/local/lib/lib$1[[0-9]]* 2>/dev/null ` ; do
-	if test -f "$i" ; then
-	    tea_lib_name_dir=`dirname $i`
-	    $1_LIB_NAME=`basename $i`
-	    $1_LIB_PATH_NAME=$i
-	    break
-	fi
-    done
-
-    if test "${TEA_PLATFORM}" = "windows"; then
-	$1_LIB_SPEC=\"`${CYGPATH} ${$1_LIB_PATH_NAME} 2>/dev/null`\"
-    else
-	# Strip off the leading "lib" and trailing ".a" or ".so"
-
-	tea_lib_name_lib=`echo ${$1_LIB_NAME}|sed -e 's/^lib//' -e 's/\.[[^.]]*$//' -e 's/\.so.*//'`
-	$1_LIB_SPEC="-L${tea_lib_name_dir} -l${tea_lib_name_lib}"
-    fi
-
-    if test "x${$1_LIB_NAME}" = x ; then
-	AC_MSG_ERROR([not found])
-    else
-	AC_MSG_RESULT([${$1_LIB_SPEC}])
-    fi
-])
-
-#------------------------------------------------------------------------
-# TEA_PRIVATE_TCL_HEADERS --
-#
-#	Locate the private Tcl include files
-#
-# Arguments:
-#
-#	Requires:
-#		TCL_SRC_DIR	Assumes that TEA_LOAD_TCLCONFIG has
-#				 already been called.
-#
-# Results:
-#
-#	Substs the following vars:
-#		TCL_TOP_DIR_NATIVE
-#		TCL_GENERIC_DIR_NATIVE
-#		TCL_UNIX_DIR_NATIVE
-#		TCL_WIN_DIR_NATIVE
-#		TCL_BMAP_DIR_NATIVE
-#		TCL_TOOL_DIR_NATIVE
-#		TCL_PLATFORM_DIR_NATIVE
-#		TCL_BIN_DIR_NATIVE
-#		TCL_INCLUDES
-#------------------------------------------------------------------------
-
-AC_DEFUN([TEA_PRIVATE_TCL_HEADERS], [
-    AC_MSG_CHECKING([for Tcl private include files])
-
-    TCL_SRC_DIR_NATIVE=`${CYGPATH} ${TCL_SRC_DIR}`
-    TCL_TOP_DIR_NATIVE=\"${TCL_SRC_DIR_NATIVE}\"
-    TCL_GENERIC_DIR_NATIVE=\"${TCL_SRC_DIR_NATIVE}/generic\"
-    TCL_UNIX_DIR_NATIVE=\"${TCL_SRC_DIR_NATIVE}/unix\"
-    TCL_WIN_DIR_NATIVE=\"${TCL_SRC_DIR_NATIVE}/win\"
-    TCL_BMAP_DIR_NATIVE=\"${TCL_SRC_DIR_NATIVE}/bitmaps\"
-    TCL_TOOL_DIR_NATIVE=\"${TCL_SRC_DIR_NATIVE}/tools\"
-    TCL_COMPAT_DIR_NATIVE=\"${TCL_SRC_DIR_NATIVE}/compat\"
-
-    if test "${TEA_PLATFORM}" = "windows"; then
-	TCL_PLATFORM_DIR_NATIVE=${TCL_WIN_DIR_NATIVE}
-    else
-	TCL_PLATFORM_DIR_NATIVE=${TCL_UNIX_DIR_NATIVE}
-    fi
-    # We want to ensure these are substituted so as not to require
-    # any *_NATIVE vars be defined in the Makefile
-    TCL_INCLUDES="-I${TCL_GENERIC_DIR_NATIVE} -I${TCL_PLATFORM_DIR_NATIVE}"
-    if test "`uname -s`" = "Darwin"; then
-        # If Tcl was built as a framework, attempt to use
-        # the framework's Headers and PrivateHeaders directories
-        case ${TCL_DEFS} in
-	    *TCL_FRAMEWORK*)
-	        if test -d "${TCL_BIN_DIR}/Headers" -a -d "${TCL_BIN_DIR}/PrivateHeaders"; then
-	        TCL_INCLUDES="-I\"${TCL_BIN_DIR}/Headers\" -I\"${TCL_BIN_DIR}/PrivateHeaders\" ${TCL_INCLUDES}"; else
-	        TCL_INCLUDES="${TCL_INCLUDES} ${TCL_INCLUDE_SPEC} `echo "${TCL_INCLUDE_SPEC}" | sed -e 's/Headers/PrivateHeaders/'`"; fi
-	        ;;
-	esac
-    else
-	if test ! -f "${TCL_SRC_DIR}/generic/tclInt.h" ; then
-	    AC_MSG_ERROR([Cannot find private header tclInt.h in ${TCL_SRC_DIR}])
-	fi
-    fi
-
-
-    AC_SUBST(TCL_TOP_DIR_NATIVE)
-    AC_SUBST(TCL_GENERIC_DIR_NATIVE)
-    AC_SUBST(TCL_UNIX_DIR_NATIVE)
-    AC_SUBST(TCL_WIN_DIR_NATIVE)
-    AC_SUBST(TCL_BMAP_DIR_NATIVE)
-    AC_SUBST(TCL_TOOL_DIR_NATIVE)
-    AC_SUBST(TCL_PLATFORM_DIR_NATIVE)
-
-    AC_SUBST(TCL_INCLUDES)
-    AC_MSG_RESULT([Using srcdir found in tclConfig.sh: ${TCL_SRC_DIR}])
-])
-
-#------------------------------------------------------------------------
-# TEA_PUBLIC_TCL_HEADERS --
-#
-#	Locate the installed public Tcl header files
-#
-# Arguments:
-#	None.
-#
-# Requires:
-#	CYGPATH must be set
-#
-# Results:
-#
-#	Adds a --with-tclinclude switch to configure.
-#	Result is cached.
-#
-#	Substs the following vars:
-#		TCL_INCLUDES
-#------------------------------------------------------------------------
-
-AC_DEFUN([TEA_PUBLIC_TCL_HEADERS], [
-    AC_MSG_CHECKING([for Tcl public headers])
-
-    AC_ARG_WITH(tclinclude, [  --with-tclinclude       directory containing the public Tcl header files], with_tclinclude=${withval})
-
-    AC_CACHE_VAL(ac_cv_c_tclh, [
-	# Use the value from --with-tclinclude, if it was given
-
-	if test x"${with_tclinclude}" != x ; then
-	    if test -f "${with_tclinclude}/tcl.h" ; then
-		ac_cv_c_tclh=${with_tclinclude}
-	    else
-		AC_MSG_ERROR([${with_tclinclude} directory does not contain tcl.h])
-	    fi
-	else
-	    if test "`uname -s`" = "Darwin"; then
-		# If Tcl was built as a framework, attempt to use
-		# the framework's Headers directory
-		case ${TCL_DEFS} in
-		    *TCL_FRAMEWORK*)
-			list="`ls -d ${TCL_BIN_DIR}/Headers 2>/dev/null`"
-			;;
-		esac
-	    fi
-
-	    # Look in the source dir only if Tcl is not installed,
-	    # and in that situation, look there before installed locations.
-	    if test -f "${TCL_BIN_DIR}/Makefile" ; then
-		list="$list `ls -d ${TCL_SRC_DIR}/generic 2>/dev/null`"
-	    fi
-
-	    # Check order: pkg --prefix location, Tcl's --prefix location,
-	    # relative to directory of tclConfig.sh.
-
-	    eval "temp_includedir=${includedir}"
-	    list="$list \
-		`ls -d ${temp_includedir}        2>/dev/null` \
-		`ls -d ${TCL_PREFIX}/include     2>/dev/null` \
-		`ls -d ${TCL_BIN_DIR}/../include 2>/dev/null`"
-	    if test "${TEA_PLATFORM}" != "windows" -o "$GCC" = "yes"; then
-		list="$list /usr/local/include /usr/include"
-		if test x"${TCL_INCLUDE_SPEC}" != x ; then
-		    d=`echo "${TCL_INCLUDE_SPEC}" | sed -e 's/^-I//'`
-		    list="$list `ls -d ${d} 2>/dev/null`"
-		fi
-	    fi
-	    for i in $list ; do
-		if test -f "$i/tcl.h" ; then
-		    ac_cv_c_tclh=$i
-		    break
-		fi
-	    done
-	fi
-    ])
-
-    # Print a message based on how we determined the include path
-
-    if test x"${ac_cv_c_tclh}" = x ; then
-	AC_MSG_ERROR([tcl.h not found.  Please specify its location with --with-tclinclude])
-    else
-	AC_MSG_RESULT([${ac_cv_c_tclh}])
-    fi
-
-    # Convert to a native path and substitute into the output files.
-
-    INCLUDE_DIR_NATIVE=`${CYGPATH} ${ac_cv_c_tclh}`
-
-    TCL_INCLUDES=-I\"${INCLUDE_DIR_NATIVE}\"
-
-    AC_SUBST(TCL_INCLUDES)
-])
-
-#------------------------------------------------------------------------
-# TEA_PRIVATE_TK_HEADERS --
-#
-#	Locate the private Tk include files
-#
-# Arguments:
-#
-#	Requires:
-#		TK_SRC_DIR	Assumes that TEA_LOAD_TKCONFIG has
-#				 already been called.
-#
-# Results:
-#
-#	Substs the following vars:
-#		TK_INCLUDES
-#------------------------------------------------------------------------
-
-AC_DEFUN([TEA_PRIVATE_TK_HEADERS], [
-    AC_MSG_CHECKING([for Tk private include files])
-
-    TK_SRC_DIR_NATIVE=`${CYGPATH} ${TK_SRC_DIR}`
-    TK_TOP_DIR_NATIVE=\"${TK_SRC_DIR_NATIVE}\"
-    TK_UNIX_DIR_NATIVE=\"${TK_SRC_DIR_NATIVE}/unix\"
-    TK_WIN_DIR_NATIVE=\"${TK_SRC_DIR_NATIVE}/win\"
-    TK_GENERIC_DIR_NATIVE=\"${TK_SRC_DIR_NATIVE}/generic\"
-    TK_XLIB_DIR_NATIVE=\"${TK_SRC_DIR_NATIVE}/xlib\"
-    if test "${TEA_PLATFORM}" = "windows"; then
-	TK_PLATFORM_DIR_NATIVE=${TK_WIN_DIR_NATIVE}
-    else
-	TK_PLATFORM_DIR_NATIVE=${TK_UNIX_DIR_NATIVE}
-    fi
-    # We want to ensure these are substituted so as not to require
-    # any *_NATIVE vars be defined in the Makefile
-    TK_INCLUDES="-I${TK_GENERIC_DIR_NATIVE} -I${TK_PLATFORM_DIR_NATIVE}"
-    if test "${TEA_WINDOWINGSYSTEM}" = "win32" \
-	-o "${TEA_WINDOWINGSYSTEM}" = "aqua"; then
-	TK_INCLUDES="${TK_INCLUDES} -I${TK_XLIB_DIR_NATIVE}"
-    fi
-    if test "${TEA_WINDOWINGSYSTEM}" = "aqua"; then
-	TK_INCLUDES="${TK_INCLUDES} -I${TK_SRC_DIR_NATIVE}/macosx"
-    fi
-    if test "`uname -s`" = "Darwin"; then
-        # If Tk was built as a framework, attempt to use
-        # the framework's Headers and PrivateHeaders directories
-        case ${TK_DEFS} in
-	    *TK_FRAMEWORK*)
-	        if test -d "${TK_BIN_DIR}/Headers" -a -d "${TK_BIN_DIR}/PrivateHeaders"; then
-	        TK_INCLUDES="-I\"${TK_BIN_DIR}/Headers\" -I\"${TK_BIN_DIR}/PrivateHeaders\" ${TK_INCLUDES}"; fi
-	        ;;
-	esac
-    else
-	if test ! -f "${TK_SRC_DIR}/generic/tkInt.h" ; then
-	    AC_MSG_ERROR([Cannot find private header tkInt.h in ${TK_SRC_DIR}])
-	fi
-    fi
-
-    AC_SUBST(TK_TOP_DIR_NATIVE)
-    AC_SUBST(TK_UNIX_DIR_NATIVE)
-    AC_SUBST(TK_WIN_DIR_NATIVE)
-    AC_SUBST(TK_GENERIC_DIR_NATIVE)
-    AC_SUBST(TK_XLIB_DIR_NATIVE)
-    AC_SUBST(TK_PLATFORM_DIR_NATIVE)
-
-    AC_SUBST(TK_INCLUDES)
-    AC_MSG_RESULT([Using srcdir found in tkConfig.sh: ${TK_SRC_DIR}])
-])
-
-#------------------------------------------------------------------------
-# TEA_PUBLIC_TK_HEADERS --
-#
-#	Locate the installed public Tk header files
-#
-# Arguments:
-#	None.
-#
-# Requires:
-#	CYGPATH must be set
-#
-# Results:
-#
-#	Adds a --with-tkinclude switch to configure.
-#	Result is cached.
-#
-#	Substs the following vars:
-#		TK_INCLUDES
-#------------------------------------------------------------------------
-
-AC_DEFUN([TEA_PUBLIC_TK_HEADERS], [
-    AC_MSG_CHECKING([for Tk public headers])
-
-    AC_ARG_WITH(tkinclude, [  --with-tkinclude        directory containing the public Tk header files], with_tkinclude=${withval})
-
-    AC_CACHE_VAL(ac_cv_c_tkh, [
-	# Use the value from --with-tkinclude, if it was given
-
-	if test x"${with_tkinclude}" != x ; then
-	    if test -f "${with_tkinclude}/tk.h" ; then
-		ac_cv_c_tkh=${with_tkinclude}
-	    else
-		AC_MSG_ERROR([${with_tkinclude} directory does not contain tk.h])
-	    fi
-	else
-	    if test "`uname -s`" = "Darwin"; then
-		# If Tk was built as a framework, attempt to use
-		# the framework's Headers directory.
-		case ${TK_DEFS} in
-		    *TK_FRAMEWORK*)
-			list="`ls -d ${TK_BIN_DIR}/Headers 2>/dev/null`"
-			;;
-		esac
-	    fi
-
-	    # Look in the source dir only if Tk is not installed,
-	    # and in that situation, look there before installed locations.
-	    if test -f "${TK_BIN_DIR}/Makefile" ; then
-		list="$list `ls -d ${TK_SRC_DIR}/generic 2>/dev/null`"
-	    fi
-
-	    # Check order: pkg --prefix location, Tk's --prefix location,
-	    # relative to directory of tkConfig.sh, Tcl's --prefix location, 
-	    # relative to directory of tclConfig.sh.
-
-	    eval "temp_includedir=${includedir}"
-	    list="$list \
-		`ls -d ${temp_includedir}        2>/dev/null` \
-		`ls -d ${TK_PREFIX}/include      2>/dev/null` \
-		`ls -d ${TK_BIN_DIR}/../include  2>/dev/null` \
-		`ls -d ${TCL_PREFIX}/include     2>/dev/null` \
-		`ls -d ${TCL_BIN_DIR}/../include 2>/dev/null`"
-	    if test "${TEA_PLATFORM}" != "windows" -o "$GCC" = "yes"; then
-		list="$list /usr/local/include /usr/include"
-	    fi
-	    for i in $list ; do
-		if test -f "$i/tk.h" ; then
-		    ac_cv_c_tkh=$i
-		    break
-		fi
-	    done
-	fi
-    ])
-
-    # Print a message based on how we determined the include path
-
-    if test x"${ac_cv_c_tkh}" = x ; then
-	AC_MSG_ERROR([tk.h not found.  Please specify its location with --with-tkinclude])
-    else
-	AC_MSG_RESULT([${ac_cv_c_tkh}])
-    fi
-
-    # Convert to a native path and substitute into the output files.
-
-    INCLUDE_DIR_NATIVE=`${CYGPATH} ${ac_cv_c_tkh}`
-
-    TK_INCLUDES=-I\"${INCLUDE_DIR_NATIVE}\"
-
-    AC_SUBST(TK_INCLUDES)
-
-    if test "${TEA_WINDOWINGSYSTEM}" = "win32" \
-	-o "${TEA_WINDOWINGSYSTEM}" = "aqua"; then
-	# On Windows and Aqua, we need the X compat headers
-	AC_MSG_CHECKING([for X11 header files])
-	if test ! -r "${INCLUDE_DIR_NATIVE}/X11/Xlib.h"; then
-	    INCLUDE_DIR_NATIVE="`${CYGPATH} ${TK_SRC_DIR}/xlib`"
-	    TK_XINCLUDES=-I\"${INCLUDE_DIR_NATIVE}\"
-	    AC_SUBST(TK_XINCLUDES)
-	fi
-	AC_MSG_RESULT([${INCLUDE_DIR_NATIVE}])
-    fi
-])
-
-#------------------------------------------------------------------------
-# TEA_PROG_TCLSH
-#	Determine the fully qualified path name of the tclsh executable
-#	in the Tcl build directory or the tclsh installed in a bin
-#	directory. This macro will correctly determine the name
-#	of the tclsh executable even if tclsh has not yet been
-#	built in the build directory. The tclsh found is always
-#	associated with a tclConfig.sh file. This tclsh should be used
-#	only for running extension test cases. It should never be
-#	or generation of files (like pkgIndex.tcl) at build time.
-#
-# Arguments
-#	none
-#
-# Results
-#	Subst's the following values:
-#		TCLSH_PROG
-#------------------------------------------------------------------------
-
-AC_DEFUN([TEA_PROG_TCLSH], [
-    AC_MSG_CHECKING([for tclsh])
-    if test -f "${TCL_BIN_DIR}/Makefile" ; then
-        # tclConfig.sh is in Tcl build directory
-        if test "${TEA_PLATFORM}" = "windows"; then
-            TCLSH_PROG="${TCL_BIN_DIR}/tclsh${TCL_MAJOR_VERSION}${TCL_MINOR_VERSION}${TCL_DBGX}${EXEEXT}"
-        else
-            TCLSH_PROG="${TCL_BIN_DIR}/tclsh"
-        fi
-    else
-        # tclConfig.sh is in install location
-        if test "${TEA_PLATFORM}" = "windows"; then
-            TCLSH_PROG="tclsh${TCL_MAJOR_VERSION}${TCL_MINOR_VERSION}${TCL_DBGX}${EXEEXT}"
-        else
-            TCLSH_PROG="tclsh${TCL_MAJOR_VERSION}.${TCL_MINOR_VERSION}${TCL_DBGX}"
-        fi
-        list="`ls -d ${TCL_BIN_DIR}/../bin 2>/dev/null` \
-              `ls -d ${TCL_BIN_DIR}/..     2>/dev/null` \
-              `ls -d ${TCL_PREFIX}/bin     2>/dev/null`"
-        for i in $list ; do
-            if test -f "$i/${TCLSH_PROG}" ; then
-                REAL_TCL_BIN_DIR="`cd "$i"; pwd`/"
-                break
-            fi
-        done
-        TCLSH_PROG="${REAL_TCL_BIN_DIR}${TCLSH_PROG}"
-    fi
-    AC_MSG_RESULT([${TCLSH_PROG}])
-    AC_SUBST(TCLSH_PROG)
-])
-
-#------------------------------------------------------------------------
-# TEA_PROG_WISH
-#	Determine the fully qualified path name of the wish executable
-#	in the Tk build directory or the wish installed in a bin
-#	directory. This macro will correctly determine the name
-#	of the wish executable even if wish has not yet been
-#	built in the build directory. The wish found is always
-#	associated with a tkConfig.sh file. This wish should be used
-#	only for running extension test cases. It should never be
-#	or generation of files (like pkgIndex.tcl) at build time.
-#
-# Arguments
-#	none
-#
-# Results
-#	Subst's the following values:
-#		WISH_PROG
-#------------------------------------------------------------------------
-
-AC_DEFUN([TEA_PROG_WISH], [
-    AC_MSG_CHECKING([for wish])
-    if test -f "${TK_BIN_DIR}/Makefile" ; then
-        # tkConfig.sh is in Tk build directory
-        if test "${TEA_PLATFORM}" = "windows"; then
-            WISH_PROG="${TK_BIN_DIR}/wish${TK_MAJOR_VERSION}${TK_MINOR_VERSION}${TK_DBGX}${EXEEXT}"
-        else
-            WISH_PROG="${TK_BIN_DIR}/wish"
-        fi
-    else
-        # tkConfig.sh is in install location
-        if test "${TEA_PLATFORM}" = "windows"; then
-            WISH_PROG="wish${TK_MAJOR_VERSION}${TK_MINOR_VERSION}${TK_DBGX}${EXEEXT}"
-        else
-            WISH_PROG="wish${TK_MAJOR_VERSION}.${TK_MINOR_VERSION}${TK_DBGX}"
-        fi
-        list="`ls -d ${TK_BIN_DIR}/../bin 2>/dev/null` \
-              `ls -d ${TK_BIN_DIR}/..     2>/dev/null` \
-              `ls -d ${TK_PREFIX}/bin     2>/dev/null`"
-        for i in $list ; do
-            if test -f "$i/${WISH_PROG}" ; then
-                REAL_TK_BIN_DIR="`cd "$i"; pwd`/"
-                break
-            fi
-        done
-        WISH_PROG="${REAL_TK_BIN_DIR}${WISH_PROG}"
-    fi
-    AC_MSG_RESULT([${WISH_PROG}])
-    AC_SUBST(WISH_PROG)
-])
-
-#------------------------------------------------------------------------
-# TEA_PATH_CONFIG --
-#
-#	Locate the ${1}Config.sh file and perform a sanity check on
-#	the ${1} compile flags.  These are used by packages like
-#	[incr Tk] that load *Config.sh files from more than Tcl and Tk.
-#
-# Arguments:
-#	none
-#
-# Results:
-#
-#	Adds the following arguments to configure:
-#		--with-$1=...
-#
-#	Defines the following vars:
-#		$1_BIN_DIR	Full path to the directory containing
-#				the $1Config.sh file
-#------------------------------------------------------------------------
-
-AC_DEFUN([TEA_PATH_CONFIG], [
-    #
-    # Ok, lets find the $1 configuration
-    # First, look for one uninstalled.
-    # the alternative search directory is invoked by --with-$1
-    #
-
-    if test x"${no_$1}" = x ; then
-	# we reset no_$1 in case something fails here
-	no_$1=true
-	AC_ARG_WITH($1, [  --with-$1              directory containing $1 configuration ($1Config.sh)], with_$1config=${withval})
-	AC_MSG_CHECKING([for $1 configuration])
-	AC_CACHE_VAL(ac_cv_c_$1config,[
-
-	    # First check to see if --with-$1 was specified.
-	    if test x"${with_$1config}" != x ; then
-		case ${with_$1config} in
-		    */$1Config.sh )
-			if test -f ${with_$1config}; then
-			    AC_MSG_WARN([--with-$1 argument should refer to directory containing $1Config.sh, not to $1Config.sh itself])
-			    with_$1config=`echo ${with_$1config} | sed 's!/$1Config\.sh$!!'`
-			fi;;
-		esac
-		if test -f "${with_$1config}/$1Config.sh" ; then
-		    ac_cv_c_$1config=`(cd ${with_$1config}; pwd)`
-		else
-		    AC_MSG_ERROR([${with_$1config} directory doesn't contain $1Config.sh])
-		fi
-	    fi
-
-	    # then check for a private $1 installation
-	    if test x"${ac_cv_c_$1config}" = x ; then
-		for i in \
-			../$1 \
-			`ls -dr ../$1*[[0-9]].[[0-9]]*.[[0-9]]* 2>/dev/null` \
-			`ls -dr ../$1*[[0-9]].[[0-9]][[0-9]] 2>/dev/null` \
-			`ls -dr ../$1*[[0-9]].[[0-9]] 2>/dev/null` \
-			`ls -dr ../$1*[[0-9]].[[0-9]]* 2>/dev/null` \
-			../../$1 \
-			`ls -dr ../../$1*[[0-9]].[[0-9]]*.[[0-9]]* 2>/dev/null` \
-			`ls -dr ../../$1*[[0-9]].[[0-9]][[0-9]] 2>/dev/null` \
-			`ls -dr ../../$1*[[0-9]].[[0-9]] 2>/dev/null` \
-			`ls -dr ../../$1*[[0-9]].[[0-9]]* 2>/dev/null` \
-			../../../$1 \
-			`ls -dr ../../../$1*[[0-9]].[[0-9]]*.[[0-9]]* 2>/dev/null` \
-			`ls -dr ../../../$1*[[0-9]].[[0-9]][[0-9]] 2>/dev/null` \
-			`ls -dr ../../../$1*[[0-9]].[[0-9]] 2>/dev/null` \
-			`ls -dr ../../../$1*[[0-9]].[[0-9]]* 2>/dev/null` \
-			${srcdir}/../$1 \
-			`ls -dr ${srcdir}/../$1*[[0-9]].[[0-9]]*.[[0-9]]* 2>/dev/null` \
-			`ls -dr ${srcdir}/../$1*[[0-9]].[[0-9]][[0-9]] 2>/dev/null` \
-			`ls -dr ${srcdir}/../$1*[[0-9]].[[0-9]] 2>/dev/null` \
-			`ls -dr ${srcdir}/../$1*[[0-9]].[[0-9]]* 2>/dev/null` \
-			; do
-		    if test -f "$i/$1Config.sh" ; then
-			ac_cv_c_$1config=`(cd $i; pwd)`
-			break
-		    fi
-		    if test -f "$i/unix/$1Config.sh" ; then
-			ac_cv_c_$1config=`(cd $i/unix; pwd)`
-			break
-		    fi
-		done
-	    fi
-
-	    # check in a few common install locations
-	    if test x"${ac_cv_c_$1config}" = x ; then
-		for i in `ls -d ${libdir} 2>/dev/null` \
-			`ls -d ${exec_prefix}/lib 2>/dev/null` \
-			`ls -d ${prefix}/lib 2>/dev/null` \
-			`ls -d /usr/local/lib 2>/dev/null` \
-			`ls -d /usr/contrib/lib 2>/dev/null` \
-			`ls -d /usr/lib 2>/dev/null` \
-			; do
-		    if test -f "$i/$1Config.sh" ; then
-			ac_cv_c_$1config=`(cd $i; pwd)`
-			break
-		    fi
-		done
-	    fi
-	])
-
-	if test x"${ac_cv_c_$1config}" = x ; then
-	    $1_BIN_DIR="# no $1 configs found"
-	    AC_MSG_WARN([Cannot find $1 configuration definitions])
-	    exit 0
-	else
-	    no_$1=
-	    $1_BIN_DIR=${ac_cv_c_$1config}
-	    AC_MSG_RESULT([found $$1_BIN_DIR/$1Config.sh])
-	fi
-    fi
-])
-
-#------------------------------------------------------------------------
-# TEA_LOAD_CONFIG --
-#
-#	Load the $1Config.sh file
-#
-# Arguments:
-#	
-#	Requires the following vars to be set:
-#		$1_BIN_DIR
-#
-# Results:
-#
-#	Subst the following vars:
-#		$1_SRC_DIR
-#		$1_LIB_FILE
-#		$1_LIB_SPEC
-#
-#------------------------------------------------------------------------
-
-AC_DEFUN([TEA_LOAD_CONFIG], [
-    AC_MSG_CHECKING([for existence of ${$1_BIN_DIR}/$1Config.sh])
-
-    if test -f "${$1_BIN_DIR}/$1Config.sh" ; then
-        AC_MSG_RESULT([loading])
-	. "${$1_BIN_DIR}/$1Config.sh"
-    else
-        AC_MSG_RESULT([file not found])
-    fi
-
-    #
-    # If the $1_BIN_DIR is the build directory (not the install directory),
-    # then set the common variable name to the value of the build variables.
-    # For example, the variable $1_LIB_SPEC will be set to the value
-    # of $1_BUILD_LIB_SPEC. An extension should make use of $1_LIB_SPEC
-    # instead of $1_BUILD_LIB_SPEC since it will work with both an
-    # installed and uninstalled version of Tcl.
-    #
-
-    if test -f "${$1_BIN_DIR}/Makefile" ; then
-	AC_MSG_WARN([Found Makefile - using build library specs for $1])
-        $1_LIB_SPEC=${$1_BUILD_LIB_SPEC}
-        $1_STUB_LIB_SPEC=${$1_BUILD_STUB_LIB_SPEC}
-        $1_STUB_LIB_PATH=${$1_BUILD_STUB_LIB_PATH}
-    fi
-
-    AC_SUBST($1_VERSION)
-    AC_SUBST($1_BIN_DIR)
-    AC_SUBST($1_SRC_DIR)
-
-    AC_SUBST($1_LIB_FILE)
-    AC_SUBST($1_LIB_SPEC)
-
-    AC_SUBST($1_STUB_LIB_FILE)
-    AC_SUBST($1_STUB_LIB_SPEC)
-    AC_SUBST($1_STUB_LIB_PATH)
-])
-
-#------------------------------------------------------------------------
-# TEA_PATH_CELIB --
-#
-#	Locate Keuchel's celib emulation layer for targeting Win/CE
-#
-# Arguments:
-#	none
-#
-# Results:
-#
-#	Adds the following arguments to configure:
-#		--with-celib=...
-#
-#	Defines the following vars:
-#		CELIB_DIR	Full path to the directory containing
-#				the include and platform lib files
-#------------------------------------------------------------------------
-
-AC_DEFUN([TEA_PATH_CELIB], [
-    # First, look for one uninstalled.
-    # the alternative search directory is invoked by --with-celib
-
-    if test x"${no_celib}" = x ; then
-	# we reset no_celib in case something fails here
-	no_celib=true
-	AC_ARG_WITH(celib,[  --with-celib=DIR        use Windows/CE support library from DIR], with_celibconfig=${withval})
-	AC_MSG_CHECKING([for Windows/CE celib directory])
-	AC_CACHE_VAL(ac_cv_c_celibconfig,[
-	    # First check to see if --with-celibconfig was specified.
-	    if test x"${with_celibconfig}" != x ; then
-		if test -d "${with_celibconfig}/inc" ; then
-		    ac_cv_c_celibconfig=`(cd ${with_celibconfig}; pwd)`
-		else
-		    AC_MSG_ERROR([${with_celibconfig} directory doesn't contain inc directory])
-		fi
-	    fi
-
-	    # then check for a celib library
-	    if test x"${ac_cv_c_celibconfig}" = x ; then
-		for i in \
-			../celib-palm-3.0 \
-			../celib \
-			../../celib-palm-3.0 \
-			../../celib \
-			`ls -dr ../celib-*3.[[0-9]]* 2>/dev/null` \
-			${srcdir}/../celib-palm-3.0 \
-			${srcdir}/../celib \
-			`ls -dr ${srcdir}/../celib-*3.[[0-9]]* 2>/dev/null` \
-			; do
-		    if test -d "$i/inc" ; then
-			ac_cv_c_celibconfig=`(cd $i; pwd)`
-			break
-		    fi
-		done
-	    fi
-	])
-	if test x"${ac_cv_c_celibconfig}" = x ; then
-	    AC_MSG_ERROR([Cannot find celib support library directory])
-	else
-	    no_celib=
-	    CELIB_DIR=${ac_cv_c_celibconfig}
-	    CELIB_DIR=`echo "$CELIB_DIR" | sed -e 's!\\\!/!g'`
-	    AC_MSG_RESULT([found $CELIB_DIR])
-	fi
-    fi
-])
-
-
-# Local Variables:
-# mode: autoconf
-# End:
diff --git a/tclxml-3.2/tcldom-libxml2.c b/tclxml-3.2/tcldom-libxml2.c
deleted file mode 100644
index 79960d0..0000000
--- a/tclxml-3.2/tcldom-libxml2.c
+++ /dev/null
@@ -1,7178 +0,0 @@
-/* tcldom-libxml2.c --
- *
- *	A Tcl wrapper for libxml's node tree API,
- *	conformant to the TclDOM API.
- *
- * Copyright (c) 2005-2008 by Explain.
- * http://www.explain.com.au/
- * Copyright (c) 2001-2004 Zveno Pty Ltd
- * http://www.zveno.com/
- *
- * See the file "LICENSE" for information on usage and
- * redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
- *
- * $Id: tcldom-libxml2.c,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
- */
-
-#include <tcldom/tcldom.h>
-#include <tcldom-libxml2/tcldom-libxml2.h>
-#include <libxml/xpath.h>
-#include <libxml/xpathInternals.h>
-#include <libxml/xmlIO.h>
-#include <libxml/HTMLtree.h>
-#include <libxml/globals.h>
-#include <libxml/xinclude.h>
-#include <libxml/parserInternals.h>
-#include <libxml/xmlschemas.h>
-#include <libxml/xmlschemastypes.h>
-#include <libxml/xmlsave.h>
-#include <string.h>
-
-#define TCL_DOES_STUBS \
-    (TCL_MAJOR_VERSION > 8 || TCL_MAJOR_VERSION == 8 && (TCL_MINOR_VERSION > 1 || \
-     (TCL_MINOR_VERSION == 1 && TCL_RELEASE_LEVEL == TCL_FINAL_RELEASE)))
-
-#undef TCL_STORAGE_CLASS
-#define TCL_STORAGE_CLASS DLLEXPORT
-
-/*
- * Manage lists of Tcl_Obj's
- */
-
-typedef struct ObjList {
-  Tcl_Obj *objPtr;
-  struct ObjList *next;
-} ObjList;
-
-/*
- * Forward declarations for private functions.
- */
-
-static void FreeDocument _ANSI_ARGS_((ClientData clientData));
-static TclDOM_libxml2_Document * GetDOMDocument _ANSI_ARGS_((Tcl_Interp *interp,
-							     TclXML_libxml2_Document *tDocPtr));
-
-static void TclDOM_libxml2_DestroyNode _ANSI_ARGS_((Tcl_Interp *interp, TclDOM_libxml2_Node *tNodePtr));
-static void TclDOM_libxml2_InvalidateNode _ANSI_ARGS_((TclDOM_libxml2_Node *tNodePtr));
-
-static char * TclDOMLiveNodeListNode _ANSI_ARGS_((ClientData clientData,
-						  Tcl_Interp *interp,
-						  char *name1,
-						  char *name2,
-						  int flags));
-static char * TclDOMLiveNodeListDoc _ANSI_ARGS_((ClientData clientData,
-						  Tcl_Interp *interp,
-						  char *name1,
-						  char *name2,
-						  int flags));
-static char * TclDOMLiveNamedNodeMap _ANSI_ARGS_((ClientData clientData,
-						  Tcl_Interp *interp,
-						  char *name1,
-						  char *name2,
-						  int flags));
-static int TclDOMSetLiveNodeListNode _ANSI_ARGS_((Tcl_Interp *interp,
-						  char *varname,
-						  xmlNodePtr nodePtr));
-static int TclDOMSetLiveNodeListDoc _ANSI_ARGS_((Tcl_Interp *interp,
-						  char *varname,
-						  xmlDocPtr docPtr));
-static int TclDOMSetLiveNamedNodeMap _ANSI_ARGS_((Tcl_Interp *interp,
-						  char *varname,
-						  xmlNodePtr nodePtr));
-
-/*
- * Forward declarations of commands
- */
-
-static int TclDOMDOMImplementationCommand _ANSI_ARGS_((ClientData dummy,
-						       Tcl_Interp *interp,
-						       int objc,
-						       Tcl_Obj *CONST objv[]));
-static int TclDOMDocumentCommand _ANSI_ARGS_((ClientData dummy,
-					      Tcl_Interp *interp,
-					      int objc,
-					      Tcl_Obj *CONST objv[]));
-static void DocumentNodeCmdDelete _ANSI_ARGS_((ClientData clientdata));
-static int TclDOMNodeCommand _ANSI_ARGS_((ClientData dummy,
-					  Tcl_Interp *interp,
-					  int objc,
-					  Tcl_Obj *CONST objv[]));
-static void TclDOMNodeCommandDelete _ANSI_ARGS_((ClientData clientdata));
-static int TclDOMElementCommand _ANSI_ARGS_((ClientData dummy,
-					     Tcl_Interp *interp,
-					     int objc,
-					     Tcl_Obj *CONST objv[]));
-static int TclDOMEventCommand _ANSI_ARGS_((ClientData dummy,
-					   Tcl_Interp *interp,
-					   int objc,
-					   Tcl_Obj *CONST objv[]));
-static void TclDOMEventCommandDelete _ANSI_ARGS_((ClientData clientdata));
-static Tcl_Obj * TclDOM_libxml2_NewEventObj _ANSI_ARGS_((Tcl_Interp *interp, 
-	xmlDocPtr docPtr, 
-	enum TclDOM_EventTypes type, 
-	Tcl_Obj *typeObjPtr));
-
-/*
- * Functions that implement the TclDOM_Implementation interface
- */
-
-static int TclDOM_HasFeatureCommand _ANSI_ARGS_((ClientData dummy,
-					    Tcl_Interp *interp,
-					    int objc,
-					    Tcl_Obj *CONST objv[]));
-static int TclDOMCreateCommand _ANSI_ARGS_((ClientData dummy,
-					    Tcl_Interp *interp,
-					    int objc,
-					    Tcl_Obj *CONST objv[]));
-static int TclDOMDestroyCommand _ANSI_ARGS_((ClientData dummy,
-					    Tcl_Interp *interp,
-					    int objc,
-					    Tcl_Obj *CONST objv[]));
-static int TclDOMParseCommand _ANSI_ARGS_((ClientData dummy,
-					    Tcl_Interp *interp,
-					    int objc,
-					    Tcl_Obj *CONST objv[]));
-static int TclDOMSerializeCommand _ANSI_ARGS_((ClientData dummy,
-					    Tcl_Interp *interp,
-					    int objc,
-					    Tcl_Obj *CONST objv[]));
-static int TclDOMSelectNodeCommand _ANSI_ARGS_((ClientData dummy,
-					    Tcl_Interp *interp,
-					    int objc,
-					    Tcl_Obj *CONST objv[]));
-static int TclDOMIsNodeCommand _ANSI_ARGS_((ClientData dummy,
-					    Tcl_Interp *interp,
-					    int objc,
-					    Tcl_Obj *CONST objv[]));
-static int TclDOMAdoptCommand _ANSI_ARGS_((ClientData dummy,
-					    Tcl_Interp *interp,
-					    int objc,
-					    Tcl_Obj *CONST objv[]));
-
-/*
- * Additional features
- */
-
-static int TclDOMXIncludeCommand _ANSI_ARGS_((ClientData dummy,
-					      Tcl_Interp *interp,
-					      int objc,
-					      Tcl_Obj *CONST objv[]));
-
-static int TclDOMPrefix2NSCommand _ANSI_ARGS_((ClientData dummy,
-					       Tcl_Interp *interp,
-					       int objc,
-					       Tcl_Obj *CONST objv[]));
-static int TclDOMTrimCommand _ANSI_ARGS_((ClientData dummy,
-					    Tcl_Interp *interp,
-					    int objc,
-					    Tcl_Obj *CONST objv[]));
-
-static void TrimDocument _ANSI_ARGS_((Tcl_Interp *interp, xmlDocPtr docPtr));
-static int AdoptDocument _ANSI_ARGS_((Tcl_Interp *interp, Tcl_Obj *objPtr));
-
-static int DocumentCget _ANSI_ARGS_((Tcl_Interp *interp, 
-				     xmlDocPtr docPtr, 
-				     Tcl_Obj *CONST objPtr));
-static int NodeCget _ANSI_ARGS_((Tcl_Interp *interp, 
-				 xmlDocPtr docPtr, 
-				 xmlNodePtr nodePtr, 
-				 Tcl_Obj *CONST objPtr));
-static int NodeConfigure _ANSI_ARGS_((Tcl_Interp *interp, 
-				      xmlNodePtr nodePtr,
-				      int objc,
-				      Tcl_Obj *CONST objPtr[]));
-static int ElementCget _ANSI_ARGS_((Tcl_Interp *interp,
-				    xmlNodePtr nodePtr,
-				    Tcl_Obj *CONST objPtr));
-
-static int TclDOM_NodeAppendChild _ANSI_ARGS_((Tcl_Interp *interp,
-					       xmlNodePtr nodePtr,
-					       xmlNodePtr newPtr));
-static int TclDOM_NodeInsertBefore _ANSI_ARGS_((Tcl_Interp *interp,
-						xmlNodePtr refPtr,
-						xmlNodePtr newPtr));
-
-static void PostMutationEvents _ANSI_ARGS_((Tcl_Interp *interp,
-					    TclXML_libxml2_Document *tDocPtr,
-					    xmlNodePtr nodePtr,
-					    xmlNodePtr refPtr,
-					    xmlNodePtr newPtr,
-					    xmlNodePtr oldParent,
-					    xmlNodePtr newParent));
-
-static int DTDValidate _ANSI_ARGS_((Tcl_Interp *interp,
-									TclDOM_libxml2_Document *domDocPtr));
-static int SchemaCompile _ANSI_ARGS_((Tcl_Interp *interp,
-				      TclDOM_libxml2_Document *domDocPtr));
-static int SchemaValidate _ANSI_ARGS_((Tcl_Interp *interp,
-				       TclDOM_libxml2_Document *domDocPtr,
-				       xmlDocPtr instancePtr));
-/*
-static int RelaxNGCompile _ANSI_ARGS_((Tcl_Interp *interp,
-				    xmlDocPtr doc));
-static int RelaxNGValidate _ANSI_ARGS_((Tcl_Interp *interp,
-				       xmlRelaxNGPtr schema,
-				       xmlDocPtr instance));
-*/
-
-static void NodeAddObjRef _ANSI_ARGS_((TclDOM_libxml2_Node *tNodePtr,
-									   Tcl_Obj *objPtr));
-#if 0
-static void DumpNode _ANSI_ARGS_((TclDOM_libxml2_Node *tNodePtr));
-#endif
-
-/*
- * Other utilities
- */
-
-static Tcl_Obj * GetPath _ANSI_ARGS_((Tcl_Interp *interp,
-					    xmlNodePtr nodePtr));
-
-/*
- * MS VC++ oddities
- */
-
-#ifdef WIN32
-#if !defined (__CYGWIN__)
-#define vsnprintf _vsnprintf
-#define snprintf _snprintf
-#endif /* __CYGWIN__ */
-#endif /* WIN32 */
-
-/*
- * Nodes as Tcl Objects (overloaded to also support event nodes).
- */
-
-Tcl_FreeInternalRepProc	NodeTypeFree;
-Tcl_DupInternalRepProc	NodeTypeDup;
-Tcl_UpdateStringProc	NodeTypeUpdate;
-Tcl_SetFromAnyProc      NodeTypeSetFromAny;
-
-Tcl_ObjType NodeObjType = {
-  "libxml2-node",
-  NodeTypeFree,
-  NodeTypeDup,
-  NodeTypeUpdate,
-  NodeTypeSetFromAny
-};
-
-/*
- * For additional checks when creating nodes.
- * These are setup at initialisation-time, but thereafter are read-only.
- */
-
-static Tcl_Obj *checkName;
-static Tcl_Obj *checkQName;
-
-/*
- * libxml2 is mostly thread-safe, but there are issues with error callbacks
- */
-
-TCL_DECLARE_MUTEX(libxml2)
-
-/*
- * Statically include the definitions of option tables:
- * Due to linking problems on Windows, using MS VC++.
- */
-
-#include "tcldom.c"
-
-/*
- *----------------------------------------------------------------------------
- *
- * Tcldom_libxml2_Init --
- *
- *  Initialisation routine for module.
- *  This is no longer loaded as a separate module.
- *
- * Results:
- *  None.
- *
- * Side effects:
- *  Creates commands in the interpreter,
- *
- *----------------------------------------------------------------------------
- */
-
-int
-Tcldom_libxml2_Init (interp)
-     Tcl_Interp *interp;	/* Interpreter to initialise */
-{
-
-  Tcl_MutexLock(&libxml2);
-  xmlXPathInit();
-  Tcl_MutexUnlock(&libxml2);
-
-  /*
-   * Provide a handler for nodes for structured error reporting
-   */
-
-  TclXML_libxml2_SetErrorNodeFunc(interp, 
-				  (TclXML_ErrorNodeHandlerProc *) TclDOM_libxml2_CreateObjFromNode);
-
-  /*
-   * For each of the standard commands, register the command
-   * in both the ::dom and ::dom::libxml2 Tcl namespaces -
-   * they are equivalent.
-   */
-
-  Tcl_CreateObjCommand(interp, "dom::libxml2::DOMImplementation",
-		       TclDOMDOMImplementationCommand, NULL, NULL);
-  Tcl_CreateObjCommand(interp, "dom::DOMImplementation",
-		       TclDOMDOMImplementationCommand, NULL, NULL);
-  Tcl_CreateObjCommand(interp, "dom::libxml2::hasfeature",
-		       TclDOM_HasFeatureCommand, NULL, NULL);
-  Tcl_CreateObjCommand(interp, "dom::hasfeature",
-		       TclDOM_HasFeatureCommand, NULL, NULL);
-  Tcl_CreateObjCommand(interp, "dom::libxml2::document",
-		       TclDOMDocumentCommand, NULL, NULL);
-  Tcl_CreateObjCommand(interp, "dom::document",
-		       TclDOMDocumentCommand, NULL, NULL);
-  Tcl_CreateObjCommand(interp, "dom::libxml2::node",
-		       TclDOMNodeCommand, NULL, NULL);
-  Tcl_CreateObjCommand(interp, "dom::node",
-		       TclDOMNodeCommand, NULL, NULL);
-  Tcl_CreateObjCommand(interp, "dom::libxml2::create",
-		       TclDOMCreateCommand, NULL, NULL);
-  Tcl_CreateObjCommand(interp, "dom::create",
-		       TclDOMCreateCommand, NULL, NULL);
-
-  /*
-   * Implemented in Tcl (for the moment)
-  Tcl_CreateObjCommand(interp, "dom::libxml2::parse",
-		       TclDOMParseCommand, NULL, NULL);
-  Tcl_CreateObjCommand(interp, "dom::parse",
-		       TclDOMParseCommand, NULL, NULL);
-  */
-  Tcl_CreateObjCommand(interp, "dom::libxml2::adoptdocument",
-		       TclDOMAdoptCommand, NULL, NULL);
-
-  Tcl_CreateObjCommand(interp, "dom::libxml2::serialize",
-		       TclDOMSerializeCommand, NULL, NULL);
-  Tcl_CreateObjCommand(interp, "dom::serialize",
-		       TclDOMSerializeCommand, NULL, NULL);
-  Tcl_CreateObjCommand(interp, "dom::libxml2::selectnode",
-		       TclDOMSelectNodeCommand, NULL, NULL);
-  Tcl_CreateObjCommand(interp, "dom::selectNode",
-		       TclDOMSelectNodeCommand, NULL, NULL);
-  Tcl_CreateObjCommand(interp, "dom::libxml2::isNode",
-		       TclDOMIsNodeCommand, NULL, NULL);
-  Tcl_CreateObjCommand(interp, "dom::isNode",
-		       TclDOMIsNodeCommand, NULL, NULL);
-  Tcl_CreateObjCommand(interp, "dom::libxml2::element",
-		       TclDOMElementCommand, NULL, NULL);
-  Tcl_CreateObjCommand(interp, "dom::element",
-		       TclDOMElementCommand, NULL, NULL);
-  Tcl_CreateObjCommand(interp, "dom::libxml2::event",
-		       TclDOMEventCommand, NULL, NULL);
-  Tcl_CreateObjCommand(interp, "dom::event",
-		       TclDOMEventCommand, NULL, NULL);
-  Tcl_CreateObjCommand(interp, "dom::libxml2::xinclude",
-		       TclDOMXIncludeCommand, NULL, NULL);
-  Tcl_CreateObjCommand(interp, "dom::xinclude",
-		       TclDOMXIncludeCommand, NULL, NULL);
-  Tcl_CreateObjCommand(interp, "dom::libxml2::prefix2namespaceURI",
-		       TclDOMPrefix2NSCommand, NULL, NULL);
-  Tcl_CreateObjCommand(interp, "dom::prefix2namespaceURI",
-		       TclDOMPrefix2NSCommand, NULL, NULL);
-  Tcl_CreateObjCommand(interp, "dom::libxml2::destroy",
-		       TclDOMDestroyCommand, NULL, NULL);
-  Tcl_CreateObjCommand(interp, "dom::destroy",
-		       TclDOMDestroyCommand, NULL, NULL);
-  Tcl_CreateObjCommand(interp, "dom::libxml2::trim",
-		       TclDOMTrimCommand, NULL, NULL);
-  Tcl_CreateObjCommand(interp, "dom::trim",
-		       TclDOMTrimCommand, NULL, NULL);
-
-  /* Setup name checking REs */
-  checkName = Tcl_NewStringObj("^", -1);
-  Tcl_AppendObjToObj(checkName, Tcl_GetVar2Ex(interp, "::xml::Name", NULL, 0));
-  Tcl_AppendToObj(checkName, "$", -1);
-  Tcl_IncrRefCount(checkName);
-  checkQName = Tcl_NewStringObj("^", -1);
-  Tcl_AppendObjToObj(checkQName, Tcl_GetVar2Ex(interp, "::xml::QName", NULL, 0));
-  Tcl_AppendToObj(checkQName, "$", -1);
-  Tcl_IncrRefCount(checkQName);
-
-  TclDOM_SetVars(interp);
-
-  Tcl_RegisterObjType(&NodeObjType);
-
-  return TCL_OK;
-}
-
-/*
- * DOM is safe, since it is merely an in-memory representation of the document tree.
- * However, XInclude is not safe.  This is still OK because XInclude uses the external
- * entity mechanism to load remote documents and TclXML/libxml2 intercepts those calls.
- */
-int
-Tcldom_libxml2_SafeInit (interp)
-     Tcl_Interp *interp;	/* Interpreter to initialise */
-{
-  return Tcldom_libxml2_Init(interp);
-}
-
-#if 0
-void
-DumpDocNodeTable(domDocPtr)
-     TclDOM_libxml2_Document *domDocPtr;
-{
-  return;
-
-  /*
-  TclDOM_libxml2_Node *tNodePtr;
-  Tcl_HashEntry *entryPtr;
-  Tcl_HashSearch search;
-
-  sprintf(dbgbuf, "  Nodes in doc \"%s\":\n", domDocPtr->tDocPtr->token);
-  Tcl_WriteChars(stderrChan, dbgbuf, -1);
-
-  for (entryPtr = Tcl_FirstHashEntry(domDocPtr->nodes, &search);
-       entryPtr;
-       entryPtr = Tcl_NextHashEntry(&search)) {
-    tNodePtr = (TclDOM_libxml2_Node *) Tcl_GetHashValue(entryPtr);
-    sprintf(dbgbuf, "    Hash entry \"%s\" (x%x)\n", Tcl_GetHashKey(domDocPtr->nodes, entryPtr), tNodePtr);
-    Tcl_WriteChars(stderrChan, dbgbuf, -1);
-    sprintf(dbgbuf, "    Node \"%s\"\n", tNodePtr->token);
-    Tcl_WriteChars(stderrChan, dbgbuf, -1);
-  }
-  */
-}
-#endif
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclDOM_HasFeatureCommand --
- *
- *  Implements dom::libxml2::hasfeature command
- *
- * Results:
- *  Returns boolean.
- *
- * Side effects:
- *  None.
- *
- *----------------------------------------------------------------------------
- */
-
-int
-TclDOM_HasFeatureCommand (dummy, interp, objc, objv)
-     ClientData dummy;
-     Tcl_Interp *interp;
-     int objc;
-     Tcl_Obj *CONST objv[];
-{
-  if (objc != 3) {
-    Tcl_WrongNumArgs(interp, 0, objv, "hasfeature feature version");
-    return TCL_ERROR;
-  }
-
-  if (Tcl_RegExpMatchObj(interp, objv[1], Tcl_NewStringObj("create|destroy|parse|query|serialize|trim|Events|UIEvents|isNode", -1)) == 1) {
-    if (Tcl_StringMatch(Tcl_GetStringFromObj(objv[2], NULL), "1.0") == 1) {
-      Tcl_SetObjResult(interp, Tcl_NewBooleanObj(1));
-    } else {
-      Tcl_SetObjResult(interp, Tcl_NewBooleanObj(0));
-    }
-  } else {
-    Tcl_SetObjResult(interp, Tcl_NewBooleanObj(0));
-  }
-
-  return TCL_OK;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclDOMCreateCommand --
- *
- *  Implements dom::libxml2::create command
- *
- * Results:
- *  Creates a new document.
- *
- * Side effects:
- *  Allocates memory.
- *
- *----------------------------------------------------------------------------
- */
-
-int
-TclDOMCreateCommand (dummy, interp, objc, objv)
-     ClientData dummy;
-     Tcl_Interp *interp;
-     int objc;
-     Tcl_Obj *CONST objv[];
-{
-  Tcl_Obj *objPtr;
-
-  if (objc != 1) {
-    Tcl_WrongNumArgs(interp, 1, objv, "");
-    return TCL_ERROR;
-  }
-
-  objPtr = TclXML_libxml2_NewDocObj(interp);
-  if (!objPtr) {
-    return TCL_ERROR;
-  }
-  TclXML_libxml2_DocKeep(objPtr, TCLXML_LIBXML2_DOCUMENT_KEEP);
-
-  if (AdoptDocument(interp, objPtr) != TCL_OK) {
-    return TCL_ERROR;
-  }
-
-  return TCL_OK;
-}
-int
-AdoptDocument(interp, objPtr)
-     Tcl_Interp *interp;
-     Tcl_Obj *objPtr;
-{
-  TclXML_libxml2_Document *tDocPtr;
-  TclDOM_libxml2_Document *domDocPtr;
-
-  /*
-   * Claim this object so the document will not be destroyed
-   * underneath us.
-   */
-  Tcl_IncrRefCount(objPtr);
-
-  if (TclXML_libxml2_GetTclDocFromObj(interp, objPtr, &tDocPtr) != TCL_OK) {
-    return TCL_ERROR;
-  }
-
-  domDocPtr = (TclDOM_libxml2_Document *) Tcl_Alloc(sizeof(TclDOM_libxml2_Document));
-  domDocPtr->interp = interp;
-  domDocPtr->tDocPtr = tDocPtr;
-  domDocPtr->objPtr = objPtr;
-
-  domDocPtr->schema = NULL;
-
-  domDocPtr->nodes = (Tcl_HashTable *) Tcl_Alloc(sizeof(Tcl_HashTable));
-  Tcl_InitHashTable(domDocPtr->nodes, TCL_STRING_KEYS);
-  domDocPtr->nodeCntr = 0;
-
-  domDocPtr->captureListeners = (Tcl_HashTable *) Tcl_Alloc(sizeof(Tcl_HashTable));
-  Tcl_InitHashTable(domDocPtr->captureListeners, TCL_ONE_WORD_KEYS);
-  domDocPtr->bubbleListeners = (Tcl_HashTable *) Tcl_Alloc(sizeof(Tcl_HashTable));
-  Tcl_InitHashTable(domDocPtr->bubbleListeners, TCL_ONE_WORD_KEYS);
-  memset(domDocPtr->listening, 0, TCLDOM_NUM_EVENT_TYPES * sizeof(int));
-
-  /*
-   * When the document is eventually destroyed,
-   * make sure all memory is freed.
-   */
-  tDocPtr->dom = (ClientData) domDocPtr;
-  tDocPtr->domfree = FreeDocument;
-
-  /*
-   * Create a Tcl namespace for this document
-   */
-
-  Tcl_VarEval(interp, "namespace eval ::dom::", tDocPtr->token, " {}\n", NULL);
-
-  /*
-   * Create a DOM command to control the document.
-   */
-
-  domDocPtr->cmd = Tcl_CreateObjCommand(interp, tDocPtr->token, TclDOMDocumentCommand, (ClientData) domDocPtr, DocumentNodeCmdDelete);
-
-  Tcl_SetObjResult(interp, objPtr);
-
-  return TCL_OK;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclDOM_libxml2_CreateObjFromDoc --
- *
- *  Wrapper for TclXML_libxml2_CreateObjFromDoc
- *
- * Results:
- *  Returns Tcl_Obj.
- *
- * Side effects:
- *  Allocates memory.
- *
- *----------------------------------------------------------------------------
- */
-
-Tcl_Obj *
-TclDOM_libxml2_CreateObjFromDoc (interp, docPtr)
-     Tcl_Interp *interp;
-     xmlDocPtr docPtr;
-{
-  Tcl_Obj *newPtr;
-
-  newPtr = TclXML_libxml2_CreateObjFromDoc(docPtr);
-
-  if (AdoptDocument(interp, newPtr) != TCL_OK) {
-    Tcl_DecrRefCount(newPtr);
-    return NULL;
-  }
-
-  return newPtr;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclDOMDestroyCommand --
- *
- *  Implements dom::libxml2::destroy command
- *
- * Results:
- *  Frees document or node.
- *
- * Side effects:
- *  Deallocates memory.
- *
- *----------------------------------------------------------------------------
- */
-
-int
-TclDOMDestroyCommand (dummy, interp, objc, objv)
-     ClientData dummy;
-     Tcl_Interp *interp;
-     int objc;
-     Tcl_Obj *CONST objv[];
-{
-  TclXML_libxml2_Document *tDocPtr;
-  TclDOM_libxml2_Node *tNodePtr;
-  
-  if (objc != 2) {
-    Tcl_WrongNumArgs(interp, 1, objv, "token");
-    return TCL_ERROR;
-  }
-
-  if (TclXML_libxml2_GetTclDocFromObj(interp, objv[1], &tDocPtr) == TCL_OK) {
-    TclDOM_libxml2_Document *domDocPtr = GetDOMDocument(interp, tDocPtr);
-
-    if (domDocPtr == NULL) {
-      /* This is an error! */
-      TclXML_libxml2_DestroyDocument(tDocPtr);
-    } else {
-      Tcl_DeleteCommandFromToken(interp, domDocPtr->cmd);
-    }
-
-  } else if (TclDOM_libxml2_GetTclNodeFromObj(interp, objv[1], &tNodePtr) == TCL_OK) {
-    TclDOM_libxml2_DestroyNode(interp, tNodePtr);
-  } else if (TclDOM_libxml2_GetTclEventFromObj(interp, objv[1], &tNodePtr) == TCL_OK) {
-    TclDOM_libxml2_DestroyNode(interp, tNodePtr);
-  } else {
-    Tcl_SetResult(interp, "not a DOM node", NULL);
-    return TCL_ERROR;
-  }
-
-  return TCL_OK;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * DocumentNodeCmdDelete --
- *
- *  Invoked when a DOM document's command is deleted.
- *
- * Results:
- *  Frees document.
- *
- * Side effects:
- *  Deallocates memory.
- *
- *----------------------------------------------------------------------------
- */
-
-void
-DocumentNodeCmdDelete (clientData)
-     ClientData clientData;
-{
-  TclDOM_libxml2_Document *domDocPtr = (TclDOM_libxml2_Document *) clientData;
-
-#ifndef WIN32
-  TclXML_libxml2_DestroyDocument(domDocPtr->tDocPtr);
-#endif /* not WIN32 */
-#ifdef WIN32
-  /*
-   * Workaround bug in TclXML/libxml2.
-   * This will, of course, leak memory.
-   */
-
-  /* FreeDocument((ClientData) domDocPtr); */
-#endif /* WIN32 */
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * FreeDocument --
- *
- *  Frees resources associated with a document.
- *
- * Results:
- *  None.
- *
- * Side effects:
- *  Deallocates memory.
- *
- *----------------------------------------------------------------------------
- */
-
-#ifdef WIN32
-/*
- * Using Tcl internal functions appears to cause linking problems
- * when using MS VC++, so avoid the problem by invoking a script instead.
- */
-
-void DeleteNamespace (interp, ns)
-     Tcl_Interp *interp;
-     char *ns;
-{
-  Tcl_Obj *cmdPtr = Tcl_NewObj();
-
-  Tcl_AppendStringsToObj(cmdPtr, "namespace delete ", ns, NULL);
-  Tcl_EvalObjEx(interp, cmdPtr, TCL_EVAL_GLOBAL);
-  Tcl_DecrRefCount(cmdPtr);
-}
-#else /* not WIN32 */
-/*
- * Internal Tcl functions
- */
-
-#if (TCL_MAJOR_VERSION < 8 || (TCL_MAJOR_VERSION == 8 && TCL_MINOR_VERSION < 5))
-
-/*
- * SRB: 2005-12-29: This should use #include <tclInt.h>, but private sources may not be available.
- */
-
-EXTERN Tcl_Namespace * Tcl_FindNamespace _ANSI_ARGS_((Tcl_Interp * interp,
-						      CONST char * name,
-						      Tcl_Namespace * contextNsPtr,
-						      int flags));
-EXTERN void Tcl_DeleteNamespace _ANSI_ARGS_((Tcl_Namespace * nsPtr));
-
-#endif /* Tcl < 8.5 */
-
-void DeleteNamespace (interp, ns)
-     Tcl_Interp *interp;
-     char *ns;
-{
-  Tcl_Namespace *namespacePtr;
-  namespacePtr = Tcl_FindNamespace(interp, ns,
-				   (Tcl_Namespace *) NULL, 0);
-  if (namespacePtr) {
-    Tcl_DeleteNamespace(namespacePtr);
-  } /* else internal error */
-}
-#endif /* WIN32 */
-
-void
-FreeDocument (clientData)
-     ClientData clientData;
-{
-  TclDOM_libxml2_Document *domDocPtr = (TclDOM_libxml2_Document *) clientData;
-  char buf[1024];
-
-  snprintf(buf, 1023, "::dom::%s", domDocPtr->tDocPtr->token);
-  DeleteNamespace(domDocPtr->interp, buf);
-
-  /*
-   * Deleting the namespace deletes all of the node commands,
-   * which in turn invalidates the node references.
-   * So no need to do it again here.
-   *
-  entry = Tcl_FirstHashEntry(domDocPtr->nodes, &search);
-  while (entry) {
-    tNodePtr = (TclDOM_libxml2_Node *) Tcl_GetHashValue(entry);
-    TclDOM_libxml2_InvalidateNode(tNodePtr);
-    entry = Tcl_NextHashEntry(&search);
-  }
-  */
-  Tcl_DeleteHashTable(domDocPtr->nodes);
-  Tcl_Free((char *) domDocPtr->nodes);
-
-  if (domDocPtr->schema) {
-    Tcl_MutexLock(&libxml2);
-    /* This also frees the copy of the document used by the schema context */
-    xmlSchemaFree(domDocPtr->schema);
-    Tcl_MutexUnlock(&libxml2);
-  }
-
-  Tcl_Free((char *) domDocPtr->captureListeners);
-  Tcl_Free((char *) domDocPtr->bubbleListeners);
-
-  /* Workaround win32 destroy bug, see above */
-#ifndef WIN32
-  Tcl_DecrRefCount(domDocPtr->objPtr);
-#endif /* not WIN32 */
-
-  Tcl_Free((char *) domDocPtr);
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * GetDOMDocument --
- *
- *  Retrieves the DOM document structure associated with a libxml2 document.
- *  libxslt synthesizes documents, so it is often the case that a node
- *  must be processed that has not had its document "adopted".
- *
- * Results:
- *  Returns pointer to DOM structure.
- *
- * Side effects:
- *  Document is "adopted" if necessary.
- *
- *----------------------------------------------------------------------------
- */
-
-TclDOM_libxml2_Document *
-GetDOMDocument(interp, tDocPtr)
-     Tcl_Interp *interp;
-     TclXML_libxml2_Document *tDocPtr;
-{
-  if (tDocPtr->dom != NULL) {
-    return (TclDOM_libxml2_Document *) tDocPtr->dom;
-  } else if (interp == NULL) {
-    return NULL;
-  } else {
-    Tcl_Obj *objPtr;
-
-    objPtr = TclXML_libxml2_CreateObjFromDoc(tDocPtr->docPtr);
-    if (AdoptDocument(interp, objPtr) != TCL_OK) {
-      Tcl_DecrRefCount(objPtr);
-      return NULL;
-    } else {
-      return (TclDOM_libxml2_Document *) tDocPtr->dom;
-    }
-  }
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclDOMParseCommand --
- *
- *  Implements dom::libxml2::parse command
- *
- *  Not implemented here at present - calls Tcl script
- *
- * Results:
- *  Depends on method.
- *
- * Side effects:
- *  Depends on method.
- *
- *----------------------------------------------------------------------------
- */
-
-int
-TclDOMParseCommand (dummy, interp, objc, objv)
-     ClientData dummy;
-     Tcl_Interp *interp;
-     int objc;
-     Tcl_Obj *CONST objv[];
-{
-  /* Tcl_Obj *objPtr; */
-  Tcl_Obj **newobjv;
-  int i;
-
-  if (objc < 2) {
-    Tcl_WrongNumArgs(interp, 1, objv, "xml ?args ...?");
-    return TCL_ERROR;
-  }
-
-  newobjv = (Tcl_Obj **) Tcl_Alloc((objc + 1) * sizeof(Tcl_Obj *));
-  newobjv[0] = Tcl_NewStringObj("::dom::libxml2::parse", -1);
-  for (i = 1; i < objc; i++) {
-    newobjv[i] = objv[i];
-  }
-  newobjv[i] = NULL;
-
-  return Tcl_EvalObjv(interp, objc, newobjv, 0);
-
-  /*
-  if (TclXML_CreateParser(interp, objc, objv) != TCL_OK) {
-    return TCL_ERROR;
-  }
-  parserObj = Tcl_GetObjResult(interp);
-  if (TclXML_Parse(interp, parserObj, objc, objv) != TCL_OK) {
-    return TCL_ERROR;
-  }
-
-  if (TclXML_Get(interp, parserObj, "document") != TCL_OK) {
-    return TCL_ERROR;
-  }
-
-  Tcl_SetObjResult(interp, objPtr);
-  */
-
-  return TCL_OK;
-}
-int
-TclDOMAdoptCommand (dummy, interp, objc, objv)
-     ClientData dummy;
-     Tcl_Interp *interp;
-     int objc;
-     Tcl_Obj *CONST objv[];
-{
-  if (objc != 2) {
-    Tcl_WrongNumArgs(interp, 1, objv, "doc");
-    return TCL_ERROR;
-  }
-
-  return AdoptDocument(interp, objv[1]);
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclDOMSerializeCommand --
- *
- *  Implements dom::libxml2::serialize command
- *
- * Results:
- *  Depends on method.
- *
- * Side effects:
- *  Depends on method.
- *
- *----------------------------------------------------------------------------
- */
-
-int
-TclDOMSerializeCommand (dummy, interp, objc, objv)
-     ClientData dummy;
-     Tcl_Interp *interp;
-     int objc;
-     Tcl_Obj *CONST objv[];
-{
-  xmlDocPtr docPtr;
-  xmlNodePtr nodePtr;
-  xmlBufferPtr bufptr = NULL;
-  xmlSaveCtxtPtr savectxtptr = NULL;
-  xmlChar *result = NULL;
-  Tcl_Obj *encodingPtr = NULL;
-  int option, method = TCLDOM_SERIALIZE_METHOD_XML, indent = 0, len = 0, omitXMLDeclaration = 0, saveoptions = 0;
-  char *buf, *encoding;
-  Tcl_Encoding tclencoding;
-  Tcl_DString *serialized;
-
-  if (objc < 2) {
-    Tcl_WrongNumArgs(interp, 1, objv, "node ?option value ...?");
-    return TCL_ERROR;
-  }
-
-  if (TclXML_libxml2_GetDocFromObj(interp, objv[1], &docPtr) != TCL_OK) {
-    if (TclDOM_libxml2_GetNodeFromObj(interp, objv[1], &nodePtr) == TCL_OK) {
-      /* Serialize just the node */
-      Tcl_SetResult(interp, "not yet implemented - serialize whole document", NULL);
-      return TCL_ERROR;
-    } else {
-      Tcl_SetResult(interp, "not a libxml2 node", NULL);
-      return TCL_ERROR;
-    }
-  }
-
-  if (objc > 2) {
-    objc -= 2;
-    objv += 2;
-
-    while (objc) {
-
-      if (objc == 1) {
-	Tcl_Obj *msgPtr;
-
-	msgPtr = Tcl_NewStringObj("missing value for configuration option \"", -1);
-	Tcl_AppendObjToObj(msgPtr, objv[0]);
-	Tcl_AppendStringsToObj(msgPtr, "\"", (char *) NULL);
-	Tcl_SetObjResult(interp, msgPtr);
-	return TCL_ERROR;
-      }
-
-      if (Tcl_GetIndexFromObj(interp, objv[0], TclDOM_SerializeCommandOptions,
-			    "option", 0, &option) != TCL_OK) {
-	return TCL_ERROR;
-      }
-
-      switch ((enum TclDOM_SerializeCommandOptions) option) {
-      case TCLDOM_SERIALIZE_METHOD:
-
-	buf = Tcl_GetStringFromObj(objv[1], &len);
-	if (len == 0) {
-	  method = TCLDOM_SERIALIZE_METHOD_XML;
-	} else if (Tcl_GetIndexFromObj(interp, objv[1], TclDOM_SerializeMethods,
-				       "method", 0, &method) != TCL_OK) {
-	  return TCL_ERROR;
-	}
-
-	break;
-
-      case TCLDOM_SERIALIZE_INDENT:
-
-	if (Tcl_GetBooleanFromObj(interp, objv[1], &indent) != TCL_OK) {
-	  return TCL_ERROR;
-	}
-
-	break;
-
-      case TCLDOM_SERIALIZE_OMIT_XML_DECLARATION:
-
-	if (Tcl_GetBooleanFromObj(interp, objv[1], &omitXMLDeclaration) != TCL_OK) {
-	  return TCL_ERROR;
-	}
-
-	break;
-
-      case TCLDOM_SERIALIZE_ENCODING:
-	encodingPtr = objv[1];
-
-	break;
-
-      default:
-	Tcl_SetResult(interp, "unknown option", NULL);
-	return TCL_ERROR;
-      }
-
-      objc -= 2;
-      objv += 2;
-    }
-  }
-
-  switch ((enum TclDOM_SerializeMethods) method) {
-
-  case TCLDOM_SERIALIZE_METHOD_XML:
-
-    serialized = (Tcl_DString *) Tcl_Alloc(sizeof(Tcl_DString));
-    Tcl_DStringInit(serialized);
-
-    if (encodingPtr) {
-      encoding = Tcl_GetStringFromObj(encodingPtr, NULL);
-    } else {
-      encoding = "utf-8";
-    }
-    tclencoding = Tcl_GetEncoding(interp, encoding);
-
-    Tcl_MutexLock(&libxml2);
-
-    if ((bufptr = xmlBufferCreate()) == NULL) {
-      Tcl_MutexUnlock(&libxml2);
-      Tcl_Free((void *)serialized);
-      Tcl_SetResult(interp, "unable to allocate output buffer", NULL);
-      return TCL_ERROR;
-    }
-
-    if (indent) {
-      saveoptions |= XML_SAVE_FORMAT;
-    }
-    if (omitXMLDeclaration) {
-      saveoptions |= XML_SAVE_NO_DECL;
-    }
-    if ((savectxtptr = xmlSaveToBuffer(bufptr, encoding, saveoptions)) == NULL) {
-      Tcl_MutexUnlock(&libxml2);
-      Tcl_Free((void *)serialized);
-      xmlBufferFree(bufptr);
-      Tcl_SetResult(interp, "unable to create save context", NULL);
-      return TCL_ERROR;
-    }
-
-    xmlSaveDoc(savectxtptr, docPtr);
-    xmlSaveClose(savectxtptr);
-
-    Tcl_MutexUnlock(&libxml2);
-
-    Tcl_ExternalToUtfDString(tclencoding, (CONST char *) xmlBufferContent(bufptr), xmlBufferLength(bufptr), serialized);
-    Tcl_DStringResult(interp, serialized);
-
-    Tcl_MutexLock(&libxml2);
-    xmlBufferFree(bufptr);
-    Tcl_MutexUnlock(&libxml2);
-
-    break;
-
-  case TCLDOM_SERIALIZE_METHOD_HTML:
-
-    Tcl_MutexLock(&libxml2);
-    htmlSetMetaEncoding(docPtr, (const xmlChar *) "UTF-8");
-    htmlDocDumpMemory(docPtr, &result, &len);
-    Tcl_MutexUnlock(&libxml2);
-    Tcl_SetObjResult(interp, Tcl_NewStringObj((CONST char *) result, len));
-    xmlFree(result);
-
-    break;
-
-  case TCLDOM_SERIALIZE_METHOD_TEXT:
-
-    nodePtr = docPtr->children;
-
-    while (nodePtr != NULL) {
-      if (nodePtr->type == XML_TEXT_NODE)
-	Tcl_AppendResult(interp, (char *) nodePtr->content, NULL);
-
-      if (nodePtr->children != NULL) {
-	if ((nodePtr->children->type != XML_ENTITY_DECL) &&
-	    (nodePtr->children->type != XML_ENTITY_REF_NODE) &&
-	    (nodePtr->children->type != XML_ENTITY_NODE)) {
-	  nodePtr = nodePtr->children;
-	  continue;
-	}
-      }
-
-      if (nodePtr->next != NULL) {
-	nodePtr = nodePtr->next;
-	continue;
-      }
-
-      do {
-	nodePtr = nodePtr->parent;
-	if (nodePtr == NULL)
-	  break;
-	if (nodePtr == (xmlNodePtr) docPtr) {
-	  nodePtr = NULL;
-	  break;
-	}
-	if (nodePtr->next != NULL) {
-	  nodePtr = nodePtr->next;
-	  break;
-	}
-      } while (nodePtr != NULL);
-    }
-
-    break;
-
-  default:
-    Tcl_SetResult(interp, "internal error", NULL);
-    return TCL_ERROR;
-  }
-
-  return TCL_OK;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclDOMDOMImplementationCommand --
- *
- *  Implements dom::libxml2::DOMImplementation command
- *
- * Results:
- *  Depends on method.
- *
- * Side effects:
- *  Depends on method.
- *
- *----------------------------------------------------------------------------
- */
-
-int
-TclDOMDOMImplementationCommand (dummy, interp, objc, objv)
-     ClientData dummy;
-     Tcl_Interp *interp;
-     int objc;
-     Tcl_Obj *CONST objv[];
-{
-  int method;
-
-  if (objc < 2) {
-    Tcl_WrongNumArgs(interp, 1, objv, "method ?args...?");
-    return TCL_ERROR;
-  }
-
-  if (Tcl_GetIndexFromObj(interp, objv[1], TclDOM_DOMImplementationCommandMethods,
-			  "method", 0, &method) != TCL_OK) {
-    return TCL_ERROR;
-  }
-
-  switch ((enum TclDOM_DOMImplementationCommandMethods) method) {
-  case TCLDOM_IMPL_HASFEATURE:
-    return TclDOM_HasFeatureCommand(dummy, interp, objc - 1, objv + 1);
-  case TCLDOM_IMPL_CREATE:
-    if (objc == 2) {
-      return TclDOMCreateCommand(dummy, interp, 1, objv);
-    } else if (objc == 3) {
-      Tcl_Obj *objPtr;
-      xmlDocPtr docPtr;
-      xmlNodePtr nodePtr;
-
-      if (TclDOMCreateCommand(dummy, interp, 0, NULL) != TCL_OK) {
-	return TCL_ERROR;
-      }
-      objPtr = Tcl_GetObjResult(interp);
-      TclXML_libxml2_GetDocFromObj(interp, objPtr, &docPtr);
-      Tcl_MutexLock(&libxml2);
-      nodePtr = xmlNewDocNode(docPtr, NULL, (const xmlChar *) Tcl_GetStringFromObj(objv[2], NULL), NULL);
-      Tcl_MutexUnlock(&libxml2);
-      if (nodePtr == NULL) {
-	Tcl_SetResult(interp, "unable to create document element", NULL);
-	return TCL_ERROR;
-      }
-
-      Tcl_SetObjResult(interp, objPtr);
-    } else {
-      Tcl_WrongNumArgs(interp, 1, objv, "create ?doc?");
-      return TCL_ERROR;
-    }
-
-    break;
-
-  case TCLDOM_IMPL_PARSE:
-    return TclDOMParseCommand(dummy, interp, objc - 1, objv + 1);
-
-  case TCLDOM_IMPL_SERIALIZE:
-    return TclDOMSerializeCommand(dummy, interp, objc - 1, objv + 1);
-
-  case TCLDOM_IMPL_SELECTNODE:
-    return TclDOMSelectNodeCommand(dummy, interp, objc - 1, objv + 1);
-
-  case TCLDOM_IMPL_DESTROY:
-    return TclDOMDestroyCommand(dummy, interp, objc - 1, objv + 1);
-
-  case TCLDOM_IMPL_ISNODE:
-    return TclDOMIsNodeCommand(dummy, interp, objc - 1, objv + 1);
-
-  default:
-    Tcl_SetResult(interp, "method \"", NULL);
-    Tcl_AppendResult(interp, Tcl_GetStringFromObj(objv[1], NULL));
-    Tcl_AppendResult(interp, "\" not yet implemented", NULL);
-    return TCL_ERROR;
-  }
-
-  return TCL_OK;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * [Schema|RNG][Compile|Validate] --
- *
- *  Implements DTD, XML Schema and RelaxNG parsing and validation
- *
- * Results:
- *  Depends on method.
- *
- * Side effects:
- *  May create or destroy validation contexts.
- *
- *----------------------------------------------------------------------------
- */
-
-int
-DTDValidate (interp, domDocPtr)
-     Tcl_Interp *interp;
-     TclDOM_libxml2_Document *domDocPtr;
-{
-  xmlValidCtxtPtr ctxt;
-
-  TclXML_libxml2_ResetError(interp);
-  
-  Tcl_MutexLock(&libxml2);
-
-  ctxt = xmlNewValidCtxt();
-  if (ctxt == NULL) {
-    Tcl_MutexUnlock(&libxml2);
-
-    Tcl_SetResult(interp, "unable to prepare validation context", NULL);
-    return TCL_ERROR;
-  }
-
-  Tcl_SetResult(interp, "document is not valid", NULL);
-
-  if (xmlValidateDocument(ctxt, domDocPtr->tDocPtr->docPtr) == 0) {
-    Tcl_Obj *errObjPtr;
-
-    Tcl_MutexUnlock(&libxml2);
-
-    errObjPtr = TclXML_libxml2_GetErrorObj(interp);
-
-    if (errObjPtr) {
-      Tcl_IncrRefCount(errObjPtr);
-      Tcl_SetObjResult(interp, errObjPtr);
-    }
-    return TCL_ERROR;
-  }
-
-  Tcl_MutexUnlock(&libxml2);
-
-  Tcl_ResetResult(interp);
-
-  return TCL_OK;
-}
-
-int
-SchemaCompile (interp, domDocPtr)
-     Tcl_Interp *interp;
-     TclDOM_libxml2_Document *domDocPtr;
-{
-  xmlDocPtr schemaDocPtr;
-  xmlSchemaParserCtxtPtr ctxt = NULL;
-
-  if (domDocPtr->schema) {
-    /* Re-compile */
-    Tcl_MutexLock(&libxml2);
-    xmlSchemaFree(domDocPtr->schema);
-    Tcl_MutexUnlock(&libxml2);
-    domDocPtr->schema = NULL;
-  }
-
-  Tcl_MutexLock(&libxml2);
-
-  schemaDocPtr = xmlCopyDoc(domDocPtr->tDocPtr->docPtr, 1);
-
-  if (schemaDocPtr == NULL) {
-    Tcl_MutexUnlock(&libxml2);
-    Tcl_SetResult(interp, "unable to prepare schema document", NULL);
-    return TCL_ERROR;
-  }
-
-  ctxt = xmlSchemaNewDocParserCtxt(schemaDocPtr);
-  if (ctxt == NULL) {
-    xmlFreeDoc(schemaDocPtr);
-    Tcl_MutexUnlock(&libxml2);
-    Tcl_SetResult(interp, "unable to create schema context", NULL);
-    return TCL_ERROR;
-  }
-
-  TclXML_libxml2_ResetError(interp);
-
-  Tcl_SetResult(interp, "unable to parse schema document", NULL);
-  domDocPtr->schema = xmlSchemaParse(ctxt);
-#if 0
-  xmlSchemaFreeParserCtxt(ctxt); /* This frees the doc */
-#endif
-  Tcl_MutexUnlock(&libxml2);
-  
-  if (domDocPtr->schema == NULL) {
-	Tcl_Obj * errObjPtr = TclXML_libxml2_GetErrorObj(interp);
-
-    if (errObjPtr) {
-      Tcl_SetObjResult(interp, errObjPtr);
-    }
-
-    return TCL_ERROR;
-  }
-
-  Tcl_ResetResult(interp);
-
-  return TCL_OK;
-}
-
-int
-SchemaValidate (interp, domDocPtr, instancePtr)
-     Tcl_Interp *interp;
-     TclDOM_libxml2_Document *domDocPtr;
-     xmlDocPtr instancePtr;
-{
-  xmlSchemaValidCtxtPtr ctxt = NULL;
-  Tcl_Obj *errObjPtr;
-  int ret;
-
-  if (domDocPtr->schema == NULL) {
-    Tcl_SetResult(interp, "schema not compiled", NULL);
-    return TCL_ERROR;
-  }
-
-  TclXML_libxml2_ResetError(interp);
-
-  Tcl_MutexLock(&libxml2);
-
-  ctxt = xmlSchemaNewValidCtxt(domDocPtr->schema);
-
-  Tcl_SetResult(interp, "document is not valid", NULL);
-
-  ret = xmlSchemaValidateDoc(ctxt, instancePtr);
-  errObjPtr = TclXML_libxml2_GetErrorObj(interp);
-  if (ret > 0) {
-    if (errObjPtr) {
-      Tcl_SetObjResult(interp, errObjPtr);
-    }
-    goto error;
-  } else if (ret < 0) {
-    Tcl_SetResult(interp, "schema processor internal error", NULL);
-
-    if (errObjPtr) {
-      Tcl_SetObjResult(interp, errObjPtr);
-    }
-    goto error;
-  }
-
-  xmlSchemaFreeValidCtxt(ctxt);
-
-  Tcl_MutexUnlock(&libxml2);
-
-  /* There may be warnings */
-
-  if (errObjPtr) {
-    Tcl_SetObjResult(interp, errObjPtr);
-  } else {
-    Tcl_ResetResult(interp);
-  }
-
-  return TCL_OK;
-
- error:
-  if (ctxt) {
-    xmlSchemaFreeValidCtxt(ctxt);
-  }
-
-  Tcl_MutexUnlock(&libxml2);
-
-  return TCL_ERROR;
-}
-/*
- * TODO: RelaxNG validation.
- */
-
-int
-TclDOMTrimCommand (dummy, interp, objc, objv)
-     ClientData dummy;
-     Tcl_Interp *interp;
-     int objc;
-     Tcl_Obj *CONST objv[];
-{
-  xmlDocPtr docPtr;
-
-  if (objc != 2) {
-    Tcl_WrongNumArgs(interp, 1, objv, "doc");
-  }
-
-  if (TclXML_libxml2_GetDocFromObj(interp, objv[1], &docPtr) != TCL_OK) {
-    return TCL_ERROR;
-  }
-
-  TrimDocument(interp, docPtr);
-
-  return TCL_OK;
-}
-
-/*
- *	Remove all blank text nodes
- *
- * NB. This code mostly copied from xmlschemas.c
- */
-
-/** Copied directly from xmlschemas.c:
- *
- * xmlSchemaIsBlank:
- * @str:  a string
- *
- * Check if a string is ignorable
- *
- * Returns 1 if the string is NULL or made of blanks chars, 0 otherwise
- */
-/* SRB: 2008-11-24: Updated against libxml2 2.7.2.
- */
-#define IS_BLANK_NODE(n)                                                \
-  (((n)->type == XML_TEXT_NODE) && (xmlSchemaIsBlank((n)->content, -1)))
-
-/*
- * SRB: 2008-06-12: Updated against libxml2 2.6.32.
- * See also SF bug 1943963.
- */
-
-static int
-xmlSchemaIsBlank(xmlChar *str, int len) {
-    if (str == NULL)
-        return(1);
-    if (len < 0) {
-      while (*str != 0) {
-        if (!(IS_BLANK_CH(*str))) return(0);
-        str++;
-      }
-    } else {
-      while ((*str != 0) && (len != 0)) {
-	if (!(IS_BLANK_CH(*str))) return (0);
-	str++;
-	len--;
-      }
-    }
-    return(1);
-}
-
-static void
-TrimDocument(interp, docPtr)
-     Tcl_Interp *interp;
-     xmlDocPtr docPtr;
-{
-  xmlNodePtr root, cur, delete;
-  Tcl_Obj *nodeObjPtr;
-  TclDOM_libxml2_Node *tNodePtr = NULL;
-
-  delete = NULL;
-  root = xmlDocGetRootElement(docPtr);
-  if (root == NULL) {
-    return;
-  }
-  cur = root;
-
-  while (cur != NULL) {
-    if (delete != NULL) {
-      nodeObjPtr = TclDOM_libxml2_CreateObjFromNode(interp, delete);
-      TclDOM_libxml2_GetTclNodeFromObj(interp, nodeObjPtr, &tNodePtr);
-      TclDOM_libxml2_InvalidateNode(tNodePtr);
-      Tcl_DecrRefCount(nodeObjPtr);
-      xmlUnlinkNode(delete);
-      xmlFreeNode(delete);
-      delete = NULL;
-    }
-    if (cur->type == XML_TEXT_NODE) {
-      if (IS_BLANK_NODE(cur)) {
-	if (xmlNodeGetSpacePreserve(cur) != 1) {
-	  delete = cur;
-	}
-      }
-    } else if ((cur->type != XML_ELEMENT_NODE) &&
-	       (cur->type != XML_CDATA_SECTION_NODE)) {
-      delete = cur;
-      goto skip_children;
-    }
-
-    /*
-     * Skip to next node
-     */
-    if (cur->children != NULL) {
-      if ((cur->children->type != XML_ENTITY_DECL) &&
-	  (cur->children->type != XML_ENTITY_REF_NODE) &&
-	  (cur->children->type != XML_ENTITY_NODE)) {
-	cur = cur->children;
-	continue;
-      }
-    }
-  skip_children:
-    if (cur->next != NULL) {
-      cur = cur->next;
-      continue;
-    }
-
-    do {
-      cur = cur->parent;
-      if (cur == NULL)
-	break;
-      if (cur == root) {
-	cur = NULL;
-	break;
-      }
-      if (cur->next != NULL) {
-	cur = cur->next;
-	break;
-      }
-    } while (cur != NULL);
-  }
-  if (delete != NULL) {
-    nodeObjPtr = TclDOM_libxml2_CreateObjFromNode(interp, delete);
-    TclDOM_libxml2_GetTclNodeFromObj(interp, nodeObjPtr, &tNodePtr);
-    TclDOM_libxml2_InvalidateNode(tNodePtr);
-    Tcl_DecrRefCount(nodeObjPtr);
-    xmlUnlinkNode(delete);
-    xmlFreeNode(delete);
-    delete = NULL;
-  }
-
-  return;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclDOMXIncludeCommand --
- *
- *  Implements dom::libxml2::xinclude command.
- *
- * Results:
- *  Performs XInclude processing on a document.
- *
- * Side effects:
- *  The supplied DOM tree may be modified.
- *
- *----------------------------------------------------------------------------
- */
-int
-TclDOMXIncludeCommand (dummy, interp, objc, objv)
-     ClientData dummy;
-     Tcl_Interp *interp;
-     int objc;
-     Tcl_Obj *CONST objv[];
-{
-  xmlDocPtr docPtr;
-  int subs;
-
-  if (objc != 2) {
-    Tcl_WrongNumArgs(interp, 1, objv, "doc");
-    return TCL_ERROR;
-  }
-
-  if (TclXML_libxml2_GetDocFromObj(interp, objv[1], &docPtr) != TCL_OK) {
-    return TCL_ERROR;
-  }
-
-  Tcl_MutexLock(&libxml2);
-  subs = xmlXIncludeProcess(docPtr);
-  Tcl_MutexUnlock(&libxml2);
-
-  if (subs < 0) {
-    Tcl_SetResult(interp, "unable to complete XInclude processing", NULL);
-    return TCL_ERROR;
-  }
-
-  Tcl_SetObjResult(interp, Tcl_NewIntObj(subs));
-  return TCL_OK;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclDOMPrefix2NSCommand --
- *
- *  Implements dom::libxml2::prefix2namespaceURI command.
- *
- * Results:
- *  Returns namespace URI for a given prefix.
- *
- * Side effects:
- *  None.
- *
- *----------------------------------------------------------------------------
- */
-int
-TclDOMPrefix2NSCommand (dummy, interp, objc, objv)
-     ClientData dummy;
-     Tcl_Interp *interp;
-     int objc;
-     Tcl_Obj *CONST objv[];
-{
-  xmlNodePtr nodePtr;
-  xmlNsPtr nsPtr;
-
-  if (objc != 3) {
-    Tcl_WrongNumArgs(interp, 1, objv, "node prefix");
-    return TCL_ERROR;
-  }
-
-  if (TclDOM_libxml2_GetNodeFromObj(interp, objv[1], &nodePtr) != TCL_OK) {
-    return TCL_ERROR;
-  }
-
-  nsPtr = xmlSearchNs(nodePtr->doc, nodePtr, (const xmlChar *) Tcl_GetStringFromObj(objv[2], NULL));
-
-  if (!nsPtr) {
-    Tcl_SetResult(interp, "no XML Namespace declaration", NULL);
-    return TCL_ERROR;
-  }
-
-  Tcl_SetObjResult(interp, Tcl_NewStringObj((CONST char *) nsPtr->href, -1));
-  return TCL_OK;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclDOMIsNodeCommand --
- *
- *  Implements dom::libxml2::isNode command.
- *
- * Results:
- *  Returns boolean.
- *
- * Side effects:
- *  Tcl object may be converted to internal rep.
- *
- *----------------------------------------------------------------------------
- */
-
-int
-TclDOMIsNodeCommand (dummy, interp, objc, objv)
-     ClientData dummy;
-     Tcl_Interp *interp;
-     int objc;
-     Tcl_Obj *CONST objv[];
-{
-  xmlDocPtr docPtr;
-  xmlNodePtr nodePtr;
-  TclDOM_libxml2_Node *tNodePtr;
-
-  if (objc != 2) {
-    Tcl_WrongNumArgs(interp, 1, objv, "token");
-    return TCL_ERROR;
-  }
-
-  if (TclDOM_libxml2_GetNodeFromObj(interp, objv[1], &nodePtr) != TCL_OK) {
-    if (TclXML_libxml2_GetDocFromObj(interp, objv[1], &docPtr) != TCL_OK) {
-	  if (TclDOM_libxml2_GetTclEventFromObj(interp, objv[1], &tNodePtr) != TCL_OK) {
-        Tcl_SetObjResult(interp, Tcl_NewBooleanObj(0));
-	  } else {
-		Tcl_SetObjResult(interp, Tcl_NewBooleanObj(1));
-	  }
-    } else {
-      Tcl_SetObjResult(interp, Tcl_NewBooleanObj(1));
-    }
-  } else {
-    Tcl_SetObjResult(interp, Tcl_NewBooleanObj(1));
-  }
-
-  return TCL_OK;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclDOMSelectNodeCommand --
- *
- *  Implements dom::libxml2::selectnode command.
- *
- * Results:
- *  Returns result of XPath expression evaluation.
- *
- * Side effects:
- *  Memory is allocated for Tcl object to return result.
- *
- *----------------------------------------------------------------------------
- */
-
-int
-TclDOMSelectNodeCommand (dummy, interp, objc, objv)
-     ClientData dummy;
-     Tcl_Interp *interp;
-     int objc;
-     Tcl_Obj *CONST objv[];
-{
-  int i, len, option;
-  char *path;
-  Tcl_Obj *objPtr, *nsOptPtr = NULL, *nodeObjPtr;
-  xmlDocPtr docPtr;
-  xmlNodePtr nodePtr = NULL;
-  xmlXPathContextPtr ctxt = NULL;
-  xmlXPathObjectPtr xpathObj = NULL;
-
-  if (objc < 3) {
-    Tcl_WrongNumArgs(interp, 1, objv, "doc location-path ?option value...?");
-    return TCL_ERROR;
-  }
-
-  path = Tcl_GetStringFromObj(objv[2], &len);
-  if (len == 0) {
-    return TCL_OK;
-  }
-
-  if (TclXML_libxml2_GetDocFromObj(interp, objv[1], &docPtr) != TCL_OK) {
-    if (TclDOM_libxml2_GetNodeFromObj(interp, objv[1], &nodePtr) == TCL_OK) {
-      docPtr = nodePtr->doc;
-    } else {
-      return TCL_ERROR;
-    }
-  }
-
-  for (i = 3; i < objc; i += 2) {
-    if (i == objc - 1) {
-      Tcl_AppendResult(interp, "missing value for option \"", Tcl_GetStringFromObj(objv[i], NULL), "\"", NULL);
-      return TCL_ERROR;
-    }
-    if (Tcl_GetIndexFromObj(interp, objv[i], TclDOM_SelectNodeOptions,
-			  "option", 0, &option) != TCL_OK) {
-      goto opt_error;
-    }
-    switch ((enum TclDOM_SelectNodeOptions) option) {
-
-    case TCLDOM_SELECTNODE_OPTION_NAMESPACES:
-      if (nsOptPtr) {
-        if (Tcl_ListObjAppendList(interp, nsOptPtr, objv[i + 1]) != TCL_OK) {
-          Tcl_SetResult(interp, "-namespaces option value must be a list", NULL);
-          goto opt_error;
-        }
-      } else {
-        nsOptPtr = Tcl_DuplicateObj(objv[i + 1]);
-      }
-      if (Tcl_ListObjLength(interp, nsOptPtr, &len) != TCL_OK) {
-        Tcl_SetResult(interp, "-namespaces option value must be a list", NULL);
-        goto opt_error;
-      } else if (len % 2 != 0) {
-        Tcl_SetResult(interp, "value missing from namespaces list", NULL);
-        goto opt_error;
-      }
-
-      break;
-
-    default:
-      Tcl_AppendResult(interp, "unknown option \"", Tcl_GetStringFromObj(objv[i], NULL), "\"", NULL);
-      goto opt_error;
-    }
-  }
-
-  Tcl_MutexLock(&libxml2);
-  ctxt = xmlXPathNewContext(docPtr);
-  if (ctxt == NULL) {
-    Tcl_SetResult(interp, "unable to create XPath context", NULL);
-    return TCL_ERROR;
-  }
-
-  if (nodePtr) {
-    ctxt->node = nodePtr;
-  }
-
-  TclXML_libxml2_ResetError(interp);
-
-  /*
-   * Setup any XML Namespace prefixes given as arguments
-   */
-  if (nsOptPtr) {
-    Tcl_ListObjLength(interp, nsOptPtr, &len);
-    for (i = 0; i < len; i += 2) {
-      Tcl_Obj *prefixPtr, *nsURIPtr;
-
-      Tcl_ListObjIndex(interp, nsOptPtr, i, &prefixPtr);
-      Tcl_ListObjIndex(interp, nsOptPtr, i + 1, &nsURIPtr);
-      if (xmlXPathRegisterNs(ctxt,
-			     (const xmlChar *) Tcl_GetStringFromObj(prefixPtr, NULL),
-			     (const xmlChar *) Tcl_GetStringFromObj(nsURIPtr, NULL))) {
-        Tcl_ResetResult(interp);
-        Tcl_AppendResult(interp, "unable to register XML Namespace \"", Tcl_GetStringFromObj(nsURIPtr, NULL), "\"", NULL);
-        goto error;
-      }
-    }
-  }
-
-  xpathObj = xmlXPathEval((const xmlChar *) path, ctxt);
-
-  if (xpathObj == NULL) {
-    Tcl_Obj *errObjPtr = TclXML_libxml2_GetErrorObj(interp);
-
-    if (errObjPtr) {
-      Tcl_SetObjResult(interp, errObjPtr);
-      goto error;
-    } else {
-      Tcl_SetResult(interp, "error evaluating XPath location path", NULL);
-      goto error;
-    }
-  }
-
-  objPtr = Tcl_NewObj();
-  switch (xpathObj->type) {
-
-  case XPATH_NODESET:
-    len = xmlXPathNodeSetGetLength(xpathObj->nodesetval);
-    for (i = 0; i < len; i++) {
-      nodePtr = xmlXPathNodeSetItem(xpathObj->nodesetval, i);
-      nodeObjPtr = TclDOM_libxml2_CreateObjFromNode(interp, nodePtr);
-      if (nodeObjPtr != NULL) {
-	Tcl_ListObjAppendElement(interp, objPtr, nodeObjPtr);
-      } else {
-	Tcl_MutexUnlock(&libxml2);
-	Tcl_DecrRefCount(objPtr);
-	return TCL_ERROR;
-      }
-    }
-    break;
-
-  case XPATH_BOOLEAN:
-    Tcl_SetBooleanObj(objPtr, xpathObj->boolval);
-    break;
-
-  case XPATH_NUMBER:
-    Tcl_SetDoubleObj(objPtr, xpathObj->floatval);
-    break;
-
-  case XPATH_STRING:
-    Tcl_SetStringObj(objPtr,
-		     (CONST char *) xpathObj->stringval,
-		     strlen((char *) xpathObj->stringval));
-    break;
-
-  default:
-    Tcl_SetResult(interp, "bad XPath object type", NULL);
-    goto error2;
-  }
-
-  if (nsOptPtr) {
-    Tcl_DecrRefCount(nsOptPtr);
-  }
-  xmlXPathFreeObject(xpathObj);
-  xmlXPathFreeContext(ctxt);
-
-  Tcl_MutexUnlock(&libxml2);
-
-  Tcl_SetObjResult(interp, objPtr);
-  return TCL_OK;
-
- opt_error:
-
-  Tcl_MutexUnlock(&libxml2);
-
-  if (nsOptPtr) {
-    Tcl_DecrRefCount(nsOptPtr);
-    return TCL_ERROR;
-  }
-
- error2:
-  if (nsOptPtr) {
-    Tcl_DecrRefCount(nsOptPtr);
-  }
-  xmlXPathFreeObject(xpathObj);
-  xmlXPathFreeContext(ctxt);
-
-  Tcl_MutexUnlock(&libxml2);
-
-  return TCL_ERROR;
-
- error:
-  if (nsOptPtr) {
-    Tcl_DecrRefCount(nsOptPtr);
-  }
-  xmlXPathFreeContext(ctxt);
-
-  Tcl_MutexUnlock(&libxml2);
-
-  return TCL_ERROR;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclDOMDocumentCommand --
- *
- *  Implements dom::libxml2::document command.
- *
- * Results:
- *  Depends on method.
- *
- * Side effects:
- *  Depends on method.
- *
- *----------------------------------------------------------------------------
- */
-
-int
-TclDOMDocumentCommand (clientData, interp, objc, objv)
-     ClientData clientData;
-     Tcl_Interp *interp;
-     int objc;
-     Tcl_Obj *CONST objv[];
-{
-  TclXML_libxml2_Document *tDocPtr;
-  TclDOM_libxml2_Document *domDocPtr = NULL;
-  enum TclDOM_EventTypes type;
-  int method, optobjc, wrongidx = 1, postMutationEvent = 0, idx, len;
-  xmlDocPtr docPtr = NULL;
-  xmlNodePtr nodePtr = NULL, newNodePtr = NULL;
-  xmlNsPtr nsPtr = NULL;
-  Tcl_Obj *nodeObjPtr = NULL, *newNodeObjPtr = NULL;
-  Tcl_Obj *CONST *optobjv;
-  char *buf, *bufptr, *prefix;
-
-  if (clientData == NULL) {
-    if (objc < 3) {
-      Tcl_WrongNumArgs(interp, 2, objv, "method token ?args...?");
-      return TCL_ERROR;
-    }
-
-    if (TclXML_libxml2_GetTclDocFromObj(interp, objv[2], &tDocPtr) != TCL_OK) {
-      tDocPtr = NULL;
-      docPtr = NULL;
-      if (TclDOM_libxml2_GetNodeFromObj(interp, objv[2], &nodePtr) != TCL_OK) {
-	return TCL_ERROR;
-      } else {
-	nodeObjPtr = objv[2];
-	if (TclXML_libxml2_GetTclDocFromNode(interp, nodePtr, &tDocPtr) != TCL_OK) {
-	  return TCL_ERROR;
-	}
-      }
-    } else {
-      docPtr = tDocPtr->docPtr;
-      domDocPtr = GetDOMDocument(interp, tDocPtr);
-      if (domDocPtr == NULL) {
-	Tcl_SetResult(interp, "internal error", NULL);
-	return TCL_ERROR;
-      }
-    }
-
-    optobjv = objv + 3;
-    optobjc = objc - 3;
-    wrongidx = 3;
-
-  } else {
-    if (objc < 2) {
-      Tcl_WrongNumArgs(interp, 1, objv, "method ?args...?");
-      return TCL_ERROR;
-    }
-
-    domDocPtr = (TclDOM_libxml2_Document *) clientData;
-    tDocPtr = domDocPtr->tDocPtr;
-    docPtr = tDocPtr->docPtr;
-
-    optobjv = objv + 2;
-    optobjc = objc - 2;
-    wrongidx = 2;
-  }
-
-  if (Tcl_GetIndexFromObj(interp, objv[1], TclDOM_DocumentCommandMethods,
-			  "method", 0, &method) != TCL_OK) {
-    return TCL_ERROR;
-  }
-
-  Tcl_ResetResult(interp);
-
-  switch ((enum TclDOM_DocumentCommandMethods) method) {
-
-  case TCLDOM_DOCUMENT_CGET:
-
-    if (optobjc != 1) {
-      Tcl_WrongNumArgs(interp, wrongidx, objv, "option");
-      return TCL_ERROR;
-    }
-
-    if (!docPtr) {
-      Tcl_SetResult(interp, "not a document", NULL);
-      return TCL_ERROR;
-    }
-
-    return DocumentCget(interp, docPtr, optobjv[0]);
-
-    break;
-
-  case TCLDOM_DOCUMENT_CONFIGURE:
-
-    if (!docPtr) {
-      Tcl_SetResult(interp, "not a document", NULL);
-      return TCL_ERROR;
-    }
-
-    if (optobjc == 1) {
-      return DocumentCget(interp, docPtr, optobjv[0]);
-    } else {
-      Tcl_AppendResult(interp, "attribute \"", Tcl_GetStringFromObj(optobjv[0], NULL), "\" is read-only", NULL);
-      return TCL_ERROR;
-    }
-
-    break;
-
-  case TCLDOM_DOCUMENT_CREATEELEMENTNS:
-    if (optobjc != 2) {
-      Tcl_WrongNumArgs(interp, wrongidx, objv, "nsuri qualname");
-      return TCL_ERROR;
-    }
-
-    /*
-     * libxml2 doesn't check for invalid element name,
-     * so must do that here.
-     */
-    if (Tcl_RegExpMatchObj(interp, optobjv[1], checkQName) == 0) {
-      Tcl_SetResult(interp, "invalid element name", NULL);
-      return TCL_ERROR;
-    }
-
-    /* Find localName of element */
-    buf = Tcl_GetStringFromObj(optobjv[1], &len);
-    for (idx = 0; buf[idx] != ':' && idx < len; idx++) ;
-    if (idx == len) {
-      /* no prefix was given */
-      bufptr = buf;
-    } else {
-      /* NB. name must have a local part, since it is a valid QName */
-      bufptr = &buf[idx + 1];
-    }
-
-    if (docPtr && clientData == NULL) {
-      /* We're creating the document element, so must create the namespace too */
-      xmlNodePtr old;
-
-      Tcl_MutexLock(&libxml2);
-      newNodePtr = xmlNewDocNode(docPtr, NULL, (const xmlChar *) bufptr, NULL);
-      if (newNodePtr == NULL) {
-        Tcl_SetResult(interp, "unable to create element node", NULL);
-	Tcl_MutexUnlock(&libxml2);
-        return TCL_ERROR;
-      }
-      old = xmlDocSetRootElement(docPtr, newNodePtr);
-      if (old) {
-	xmlDocSetRootElement(docPtr, old);
-	xmlFreeNode(newNodePtr);
-	Tcl_SetResult(interp, "document element already exists", NULL);
-	Tcl_MutexUnlock(&libxml2);
-	return TCL_ERROR;
-      }
-
-      if (idx < len) {
-	prefix = Tcl_Alloc(bufptr - buf);
-	strncpy(prefix, buf, bufptr - buf - 1);
-	prefix[bufptr - buf - 1] = '\0';
-      } else {
-	/* synthesize prefix for this XML Namespace */
-	prefix = Tcl_Alloc(20);
-	sprintf(prefix, "ns%d", domDocPtr->nodeCntr++);
-      }
-
-      nsPtr = xmlNewNs(newNodePtr, (const xmlChar *) Tcl_GetStringFromObj(optobjv[0], NULL), (const xmlChar *) prefix);
-      if (nsPtr == NULL) {
-	Tcl_SetResult(interp, "unable to create XML Namespace", NULL);
-	Tcl_Free(prefix);
-	xmlUnlinkNode(newNodePtr);
-	xmlFreeNode(newNodePtr);
-	Tcl_MutexUnlock(&libxml2);
-	return TCL_ERROR;
-      }
-
-      xmlSetNs(newNodePtr, nsPtr);
-
-      Tcl_MutexUnlock(&libxml2);
-
-      newNodeObjPtr = TclDOM_libxml2_CreateObjFromNode(interp, newNodePtr);
-      if (newNodeObjPtr == NULL) {
-	Tcl_MutexLock(&libxml2);
-	xmlFreeNode(newNodePtr);
-	Tcl_MutexUnlock(&libxml2);
-
-	return TCL_ERROR;
-      }
-
-      postMutationEvent = 1;
-
-    } else if (docPtr && clientData != NULL) {
-      /* Create an unattached element node */
-      Tcl_MutexLock(&libxml2);
-      newNodePtr = xmlNewDocNode(docPtr, NULL, (const xmlChar *) bufptr, NULL);
-
-      if (idx < len) {
-	prefix = Tcl_Alloc(bufptr - buf);
-	strncpy(prefix, buf, bufptr - buf - 1);
-	prefix[bufptr - buf - 1] = '\0';
-      } else {
-	/* synthesize prefix for this XML Namespace */
-	prefix = Tcl_Alloc(20);
-	sprintf(prefix, "ns%d", domDocPtr->nodeCntr);
-      }
-
-      nsPtr = xmlNewNs(newNodePtr, (const xmlChar *) Tcl_GetStringFromObj(optobjv[0], NULL), (const xmlChar *) prefix);
-      if (nsPtr == NULL) {
-	Tcl_SetResult(interp, "unable to create XML Namespace", NULL);
-	Tcl_Free(prefix);
-	xmlUnlinkNode(newNodePtr);
-	xmlFreeNode(newNodePtr);
-	Tcl_MutexUnlock(&libxml2);
-	return TCL_ERROR;
-      }
-
-      xmlSetNs(newNodePtr, nsPtr);
-
-      Tcl_MutexUnlock(&libxml2);
-
-      if (newNodePtr == NULL) {
-        Tcl_SetResult(interp, "unable to create element node", NULL);
-        return TCL_ERROR;
-      }
-
-      newNodeObjPtr = TclDOM_libxml2_CreateObjFromNode(interp, newNodePtr);
-      if (newNodeObjPtr == NULL) {
-	Tcl_MutexLock(&libxml2);
-	xmlFreeNode(newNodePtr);
-	Tcl_MutexUnlock(&libxml2);
-	return TCL_ERROR;
-      } else {
-	Tcl_SetObjResult(interp, newNodeObjPtr);
-      }
-
-      /*
-       * The tree hasn't changed yet, so no events need to be fired.
-       */
-      postMutationEvent = 0;
-
-    } else {
-
-      Tcl_MutexLock(&libxml2);
-      /* Find XML Namespace */
-      nsPtr = xmlSearchNsByHref(nodePtr->doc,
-				nodePtr,
-				(const xmlChar *) Tcl_GetStringFromObj(optobjv[0], NULL));
-      if (nsPtr == NULL) {
-	if (idx < len) {
-	  prefix = Tcl_Alloc(bufptr - buf);
-	  strncpy(prefix, buf, bufptr - buf - 1);
-	  prefix[bufptr - buf - 1] = '\0';
-	} else {
-	  prefix = Tcl_Alloc(20);
-	  sprintf(prefix, "ns%d", domDocPtr->nodeCntr++);
-	}
-
-	newNodePtr = xmlNewChild(nodePtr, NULL, (const xmlChar *) bufptr, NULL);
-	nsPtr = xmlNewNs(newNodePtr,
-			 (const xmlChar *) Tcl_GetStringFromObj(optobjv[0], NULL),
-			 (const xmlChar *) prefix);
-	if (nsPtr == NULL) {
-	  Tcl_SetResult(interp, "unable to create XML Namespace", NULL);
-	  Tcl_MutexUnlock(&libxml2);
-	  return TCL_ERROR;
-	}
-	xmlSetNs(newNodePtr, nsPtr);
-
-      } else {
-	newNodePtr = xmlNewChild(nodePtr, nsPtr, (const xmlChar *) bufptr, NULL);
-	if (newNodePtr == NULL) {
-	  Tcl_SetResult(interp, "unable to create element node", NULL);
-	  Tcl_MutexUnlock(&libxml2);
-	  return TCL_ERROR;
-	}
-      }
-
-      Tcl_MutexUnlock(&libxml2);
-
-      newNodeObjPtr = TclDOM_libxml2_CreateObjFromNode(interp, newNodePtr);
-      if (newNodeObjPtr == NULL) {
-	Tcl_MutexLock(&libxml2);
-	xmlFreeNode(newNodePtr);
-	Tcl_MutexUnlock(&libxml2);
-	return TCL_ERROR;
-      }
-
-      postMutationEvent = 1;
-    }
-
-    break;
-
-  case TCLDOM_DOCUMENT_CREATEELEMENT:
-
-    if (optobjc != 1) {
-      Tcl_WrongNumArgs(interp, wrongidx, objv, "name");
-      return TCL_ERROR;
-    }
-
-    /*
-     * libxml2 doesn't check for invalid element name,
-     * so must do that here.
-     */
-    if (Tcl_RegExpMatchObj(interp, optobjv[0], checkName) == 0) {
-      Tcl_AppendResult(interp, "invalid element name \"", Tcl_GetStringFromObj(optobjv[0], NULL), "\"", NULL);
-      return TCL_ERROR;
-    }
-
-    Tcl_MutexLock(&libxml2);
-
-    if (docPtr && clientData == NULL) {
-      xmlNodePtr old;
-      newNodePtr = xmlNewDocNode(docPtr,
-				 NULL,
-				 (const xmlChar *) Tcl_GetStringFromObj(optobjv[0], NULL),
-				 NULL);
-      if (newNodePtr == NULL) {
-        Tcl_SetResult(interp, "unable to create element node", NULL);
-	Tcl_MutexUnlock(&libxml2);
-        return TCL_ERROR;
-      }
-      old = xmlDocSetRootElement(docPtr, newNodePtr);
-      if (old) {
-	xmlDocSetRootElement(docPtr, old);
-	xmlFreeNode(newNodePtr);
-	Tcl_SetResult(interp, "document element already exists", NULL);
-	Tcl_MutexUnlock(&libxml2);
-	return TCL_ERROR;
-      }
-
-      newNodeObjPtr = TclDOM_libxml2_CreateObjFromNode(interp, newNodePtr);
-      if (newNodeObjPtr == NULL) {
-	xmlFreeNode(newNodePtr);
-	Tcl_MutexUnlock(&libxml2);
-	return TCL_ERROR;
-      }
-
-      postMutationEvent = 1;
-    } else if (docPtr && clientData != NULL) {
-      /* Create an unattached element node */
-      newNodePtr = xmlNewDocNode(docPtr,
-				 NULL,
-				 (const xmlChar *) Tcl_GetStringFromObj(optobjv[0], NULL),
-				 NULL);
-      if (newNodePtr == NULL) {
-        Tcl_SetResult(interp, "unable to create element node", NULL);
-	Tcl_MutexUnlock(&libxml2);
-        return TCL_ERROR;
-      }
-
-      newNodeObjPtr = TclDOM_libxml2_CreateObjFromNode(interp, newNodePtr);
-      if (newNodeObjPtr == NULL) {
-	xmlFreeNode(newNodePtr);
-	Tcl_MutexUnlock(&libxml2);
-        return TCL_ERROR;
-      } else {
-	Tcl_SetObjResult(interp, newNodeObjPtr);
-      }
-
-      /*
-       * The tree hasn't changed yet, so no events need to be fired.
-       */
-      postMutationEvent = 0;
-    } else {
-      newNodePtr = xmlNewChild(nodePtr,
-			       NULL,
-			       (const xmlChar *) Tcl_GetStringFromObj(optobjv[0], NULL),
-			       NULL);
-      if (newNodePtr == NULL) {
-        Tcl_SetResult(interp, "unable to create element node", NULL);
-	Tcl_MutexUnlock(&libxml2);
-        return TCL_ERROR;
-      }
-      newNodeObjPtr = TclDOM_libxml2_CreateObjFromNode(interp, newNodePtr);
-      if (newNodeObjPtr == NULL) {
-	xmlFreeNode(newNodePtr);
-	Tcl_MutexUnlock(&libxml2);
-        return TCL_ERROR;
-      }
-      postMutationEvent = 1;
-    }
-
-    Tcl_MutexUnlock(&libxml2);
-
-    break;
-
-  case TCLDOM_DOCUMENT_CREATEDOCUMENTFRAGMENT:
-
-    if (optobjc != 0) {
-      Tcl_WrongNumArgs(interp, wrongidx, objv, "");
-      return TCL_ERROR;
-    }
-
-    Tcl_MutexLock(&libxml2);
-
-    if (docPtr) {
-      newNodePtr = xmlNewDocFragment(docPtr);
-    } else {
-      newNodePtr = xmlNewDocFragment(nodePtr->doc);
-    }
-    if (newNodePtr == NULL) {
-      Tcl_SetResult(interp, "unable to create document fragment", NULL);
-      Tcl_MutexUnlock(&libxml2);
-      return TCL_ERROR;
-    }
-
-    newNodeObjPtr = TclDOM_libxml2_CreateObjFromNode(interp, newNodePtr);
-    if (newNodeObjPtr == NULL) {
-      xmlFreeNode(newNodePtr);
-      Tcl_MutexUnlock(&libxml2);
-      return TCL_ERROR;
-    } else {
-      Tcl_SetObjResult(interp, newNodeObjPtr);
-    }
-
-    Tcl_MutexUnlock(&libxml2);
-
-    /* The node hasn't been inserted into the tree yet */
-    postMutationEvent = 0;
-
-    break;
-
-  case TCLDOM_DOCUMENT_CREATETEXTNODE:
-
-    if (optobjc != 1) {
-      Tcl_WrongNumArgs(interp, wrongidx, objv, "text");
-      return TCL_ERROR;
-    }
-
-    Tcl_MutexLock(&libxml2);
-
-    if (docPtr) {
-      char *content;
-      int len;
-
-      content = Tcl_GetStringFromObj(optobjv[0], &len);
-      newNodePtr = xmlNewDocTextLen(docPtr, (const xmlChar *) content, len);
-      if (newNodePtr == NULL) {
-        Tcl_SetResult(interp, "unable to create text node", NULL);
-	Tcl_MutexUnlock(&libxml2);
-        return TCL_ERROR;
-      }
-
-      newNodeObjPtr = TclDOM_libxml2_CreateObjFromNode(interp, newNodePtr);
-      if (newNodeObjPtr == NULL) {
-	xmlFreeNode(newNodePtr);
-	Tcl_MutexUnlock(&libxml2);
-	return TCL_ERROR;
-      } else {
-	Tcl_SetObjResult(interp, newNodeObjPtr);
-      }
-
-      Tcl_MutexUnlock(&libxml2);
-
-      postMutationEvent = 0;
-
-    } else {
-      xmlNodePtr returnNode;
-      char *content;
-      int len;
-
-      content = Tcl_GetStringFromObj(optobjv[0], &len);
-      newNodePtr = xmlNewTextLen((const xmlChar *) content, len);
-      if (newNodePtr == NULL) {
-	Tcl_SetResult(interp, "creating text node failed", NULL);
-	Tcl_MutexUnlock(&libxml2);
-	return TCL_ERROR;
-      }
-      returnNode = xmlAddChild(nodePtr, newNodePtr);
-      if (returnNode == NULL) {
-	xmlFreeNode(newNodePtr);
-	Tcl_SetResult(interp, "add child failed", NULL);
-	Tcl_MutexUnlock(&libxml2);
-	return TCL_ERROR;
-      }
-
-      newNodeObjPtr = TclDOM_libxml2_CreateObjFromNode(interp, newNodePtr);
-      if (newNodeObjPtr == NULL) {
-	xmlFreeNode(newNodePtr);
-	Tcl_MutexUnlock(&libxml2);
-	return TCL_ERROR;
-      }
-
-      Tcl_MutexUnlock(&libxml2);
-
-      postMutationEvent = 1;
-    }
-
-    break;
-
-  case TCLDOM_DOCUMENT_CREATECOMMENT:
-
-    if (optobjc != 1) {
-      Tcl_WrongNumArgs(interp, wrongidx, objv, "data");
-      return TCL_ERROR;
-    }
-
-    Tcl_MutexLock(&libxml2);
-
-    if (docPtr) {
-      newNodePtr = xmlNewDocComment(docPtr, (const xmlChar *) Tcl_GetStringFromObj(optobjv[0], NULL));
-      if (newNodePtr == NULL) {
-        Tcl_SetResult(interp, "unable to create comment node", NULL);
-	Tcl_MutexUnlock(&libxml2);
-        return TCL_ERROR;
-      }
-      newNodeObjPtr = TclDOM_libxml2_CreateObjFromNode(interp, newNodePtr);
-      if (newNodeObjPtr == NULL) {
-	xmlFreeNode(newNodePtr);
-	Tcl_MutexUnlock(&libxml2);
-	return TCL_ERROR;
-      } else {
-	Tcl_SetObjResult(interp, newNodeObjPtr);
-      }
-
-      postMutationEvent = 0;
-
-    } else {
-      newNodePtr = xmlNewDocComment(nodePtr->doc, (const xmlChar *) Tcl_GetStringFromObj(optobjv[0], NULL));
-      if (newNodePtr == NULL) {
-        Tcl_SetResult(interp, "unable to create comment node", NULL);
-	Tcl_MutexUnlock(&libxml2);
-        return TCL_ERROR;
-      }
-      xmlAddChild(nodePtr, newNodePtr);
-
-      newNodeObjPtr = TclDOM_libxml2_CreateObjFromNode(interp, newNodePtr);
-      if (newNodeObjPtr == NULL) {
-	xmlFreeNode(newNodePtr);
-	Tcl_MutexUnlock(&libxml2);
-	return TCL_ERROR;
-      }
-
-      postMutationEvent = 1;
-    }
-
-    Tcl_MutexUnlock(&libxml2);
-
-    break;
-
-  case TCLDOM_DOCUMENT_CREATECDATASECTION:
-
-    if (optobjc != 1) {
-      Tcl_WrongNumArgs(interp, wrongidx, objv, "text");
-      return TCL_ERROR;
-    }
-
-    Tcl_MutexLock(&libxml2);
-
-    if (docPtr) {
-      char *content;
-      int len;
-
-      content = Tcl_GetStringFromObj(optobjv[0], &len);
-      newNodePtr = xmlNewDocTextLen(docPtr, (const xmlChar *) content, len);
-      if (newNodePtr == NULL) {
-        Tcl_SetResult(interp, "unable to create text node", NULL);
-	Tcl_MutexUnlock(&libxml2);
-        return TCL_ERROR;
-      }
-      newNodeObjPtr = TclDOM_libxml2_CreateObjFromNode(interp, newNodePtr);
-      if (newNodeObjPtr == NULL) {
-	xmlFreeNode(newNodePtr);
-	Tcl_MutexUnlock(&libxml2);
-	return TCL_ERROR;
-      } else {
-	Tcl_SetObjResult(interp, newNodeObjPtr);
-      }
-
-      postMutationEvent = 0;
-
-    } else {
-      char *content;
-      int len;
-
-      content = Tcl_GetStringFromObj(optobjv[0], &len);
-      newNodePtr = xmlNewTextLen((const xmlChar *) content, len);
-      if (newNodePtr == NULL) {
-        Tcl_SetResult(interp, "unable to create text node", NULL);
-	Tcl_MutexUnlock(&libxml2);
-        return TCL_ERROR;
-      }
-      xmlAddChild(nodePtr, newNodePtr);
-
-      newNodeObjPtr = TclDOM_libxml2_CreateObjFromNode(interp, newNodePtr);
-      if (newNodeObjPtr == NULL) {
-	xmlFreeNode(newNodePtr);
-	Tcl_MutexUnlock(&libxml2);
-	return TCL_ERROR;
-      }
-
-      postMutationEvent = 1;
-    }
-
-    Tcl_MutexUnlock(&libxml2);
-
-    break;
-
-  case TCLDOM_DOCUMENT_CREATEPI:
-    if (optobjc != 2) {
-      Tcl_WrongNumArgs(interp, wrongidx, objv, "target data");
-      return TCL_ERROR;
-    }
-
-    Tcl_MutexLock(&libxml2);
-
-    newNodePtr = xmlNewPI((const xmlChar *) Tcl_GetStringFromObj(optobjv[0], NULL),
-			  (const xmlChar *) Tcl_GetStringFromObj(optobjv[1], NULL));
-    if (newNodePtr == NULL) {
-      Tcl_SetResult(interp, "unable to create processing instruction node", NULL);
-      Tcl_MutexUnlock(&libxml2);
-      return TCL_ERROR;
-    }
-
-    if (docPtr) {
-      /*
-       * libxml2 does not provide 'xmlNewDocPI' so the PI must be added to the tree
-       * before we wrap it in an object.  We'll use the document element as a placeholder
-       * for the PI node; the user may move it from there.
-       */
-      xmlNodePtr docElPtr = xmlDocGetRootElement(docPtr);
-
-      if (docElPtr == NULL) {
-	xmlFreeNode(newNodePtr);
-	Tcl_MutexUnlock(&libxml2);
-	Tcl_SetResult(interp, "document element must exist before adding a PI", NULL);
-	return TCL_ERROR;
-      }
-      xmlAddNextSibling(docElPtr, newNodePtr);
-
-      newNodeObjPtr = TclDOM_libxml2_CreateObjFromNode(interp, newNodePtr);
-      if (newNodeObjPtr == NULL) {
-	xmlFreeNode(newNodePtr);
-	Tcl_MutexUnlock(&libxml2);
-	return TCL_ERROR;
-      } else {
-	Tcl_SetObjResult(interp, newNodeObjPtr);
-      }
-
-      postMutationEvent = 0;
-
-    } else {
-      xmlAddChild(nodePtr, newNodePtr);
-
-      newNodeObjPtr = TclDOM_libxml2_CreateObjFromNode(interp, newNodePtr);
-      if (newNodeObjPtr == NULL) {
-	xmlFreeNode(newNodePtr);
-	Tcl_MutexUnlock(&libxml2);
-	return TCL_ERROR;
-      }
-
-      postMutationEvent = 1;
-    }
-
-    Tcl_MutexUnlock(&libxml2);
-
-    break;
-
-  case TCLDOM_DOCUMENT_CREATEEVENT:
-
-    if (optobjc != 1) {
-      Tcl_WrongNumArgs(interp, wrongidx, objv, "type");
-      return TCL_ERROR;
-    }
-
-    if (!docPtr) {
-      docPtr = nodePtr->doc;
-    }
-
-    if (Tcl_GetIndexFromObj(interp, optobjv[0], TclDOM_EventTypes,
-			    "type", TCL_EXACT, &method) == TCL_OK) {
-      type = (enum TclDOM_EventTypes) method;
-    } else {
-      type = TCLDOM_EVENT_USERDEFINED;
-    }
-
-    newNodeObjPtr = TclDOM_libxml2_NewEventObj(interp, docPtr, type, optobjv[0]);
-    if (newNodeObjPtr == NULL) {
-      return TCL_ERROR;
-    } else {
-      Tcl_SetObjResult(interp, newNodeObjPtr);
-    }
-
-    postMutationEvent = 0;
-
-    break;
-
-  case TCLDOM_DOCUMENT_SCHEMA:
-
-    if (optobjc < 1) {
-      Tcl_WrongNumArgs(interp, wrongidx, objv, "submethod ?args ...?");
-      return TCL_ERROR;
-    }
-
-    if (Tcl_GetIndexFromObj(interp, optobjv[0], TclDOM_DocumentSchemaSubmethods,
-			    "submethod", 0, &method) != TCL_OK) {
-      return TCL_ERROR;
-    }
-
-    switch ((enum TclDOM_DocumentSchemaSubmethods) method) {
-    case TCLDOM_DOCUMENT_SCHEMA_COMPILE:
-	  if (optobjc != 1) {
-		Tcl_WrongNumArgs(interp, wrongidx, objv, "compile");
-		return TCL_ERROR;
-	  }
-      return SchemaCompile(interp, domDocPtr);
-
-    case TCLDOM_DOCUMENT_SCHEMA_VALIDATE:
-      if (optobjc != 2) {
-		Tcl_WrongNumArgs(interp, wrongidx, objv, "validate instance");
-		return TCL_ERROR;
-      } else {
-		xmlDocPtr instancePtr;
-
-		if (TclXML_libxml2_GetDocFromObj(interp, optobjv[1], &instancePtr) != TCL_OK) {
-		  return TCL_ERROR;
-		}
-
-		return SchemaValidate(interp, domDocPtr, instancePtr);
-      }
-
-      break;
-
-    default:
-      Tcl_ResetResult(interp);
-      Tcl_AppendResult(interp, "unknown submethod \"", 
-		       Tcl_GetStringFromObj(optobjv[0], NULL), "\"", NULL);
-      return TCL_ERROR;
-    }
-
-    break;
-
-  case TCLDOM_DOCUMENT_DTD:
-
-	if (optobjc < 1) {
-	  Tcl_WrongNumArgs(interp, wrongidx, objv, "submethod ?args...?");
-	  return TCL_ERROR;
-	}
-	
-    if (Tcl_GetIndexFromObj(interp, optobjv[0], TclDOM_DocumentDTDSubmethods,
-							"submethod", 0, &method) != TCL_OK) {
-      return TCL_ERROR;
-    }
-
-    switch ((enum TclDOM_DocumentDTDSubmethods) method) {
-    case TCLDOM_DOCUMENT_DTD_VALIDATE:
-      if (optobjc != 1) {
-	Tcl_WrongNumArgs(interp, wrongidx, objv, "validate");
-	return TCL_ERROR;
-      } else {
-	return DTDValidate(interp, domDocPtr);
-      }
-    default:
-      Tcl_SetResult(interp, "unknown submethod", NULL);
-      return TCL_ERROR;
-    }
-
-    break;
-	
-  case TCLDOM_DOCUMENT_CREATEATTRIBUTE:
-  case TCLDOM_DOCUMENT_CREATEENTITY:
-  case TCLDOM_DOCUMENT_CREATEENTITYREFERENCE:
-  case TCLDOM_DOCUMENT_CREATEDOCTYPEDECL:
-  default:
-    Tcl_SetResult(interp, "method \"", NULL);
-    Tcl_AppendResult(interp, Tcl_GetStringFromObj(objv[1], NULL), "\" not yet implemented", NULL);
-    return TCL_ERROR;
-  }
-
-  if (postMutationEvent) {
-
-    TclDOM_PostMutationEvent(interp, tDocPtr, newNodeObjPtr, TCLDOM_EVENT_DOMNODEINSERTED, NULL, Tcl_NewIntObj(1), Tcl_NewIntObj(0), objv[2], NULL, NULL, NULL, NULL);
-    TclDOM_PostMutationEvent(interp, tDocPtr, newNodeObjPtr, TCLDOM_EVENT_DOMNODEINSERTEDINTODOCUMENT, NULL, Tcl_NewIntObj(0), Tcl_NewIntObj(0), NULL, NULL, NULL, NULL, NULL);
-
-    if (nodePtr) {
-      TclDOM_PostMutationEvent(interp, tDocPtr, nodeObjPtr, TCLDOM_EVENT_DOMSUBTREEMODIFIED, NULL, Tcl_NewIntObj(1), Tcl_NewIntObj(0), NULL, NULL, NULL, NULL, NULL);
-    } else {
-      /*
-       * We just added the document element.
-       */
-    }
-
-    Tcl_SetObjResult(interp, newNodeObjPtr);
-  }
-
-  return TCL_OK;
-}
-
-int
-DocumentCget(interp, docPtr, optObj)
-     Tcl_Interp *interp;
-     xmlDocPtr docPtr;
-     Tcl_Obj *CONST optObj;
-{
-  xmlNodePtr nodePtr;
-  int option;
-
-  if (Tcl_GetIndexFromObj(interp, optObj, TclDOM_DocumentCommandOptions,
-			  "option", 0, &option) != TCL_OK) {
-    return TCL_ERROR;
-  }
-
-  switch ((enum TclDOM_DocumentCommandOptions) option) {
-
-  case TCLDOM_DOCUMENT_DOCTYPE:
-    Tcl_SetResult(interp, "cget option \"", NULL);
-    Tcl_AppendResult(interp, Tcl_GetStringFromObj(optObj, NULL), NULL);
-    Tcl_AppendResult(interp, "\" not yet implemented", NULL);
-    return TCL_ERROR;
-    
-  case TCLDOM_DOCUMENT_IMPLEMENTATION:
-    Tcl_SetResult(interp, "::dom::libxml2::DOMImplementation", NULL);
-    break;
-
-  case TCLDOM_DOCUMENT_DOCELEMENT:
-
-    Tcl_MutexLock(&libxml2);
-    nodePtr = xmlDocGetRootElement(docPtr);
-    Tcl_MutexUnlock(&libxml2);
-
-    if (nodePtr) {
-      Tcl_SetObjResult(interp, TclDOM_libxml2_CreateObjFromNode(interp, nodePtr));
-    } else {
-      Tcl_ResetResult(interp);
-      return TCL_OK;
-    }
-
-    break;
-
-  default:
-    Tcl_SetResult(interp, "unknown option", NULL);
-    return TCL_ERROR;
-  }
-
-  return TCL_OK;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TriggerEventListeners --
- *
- *  Iterates through the list of event listeners for
- *  a node or document and fires events.
- *
- * Results:
- *  Depends on listeners.
- *
- * Side effects:
- *  Depends on listeners.
- *
- *----------------------------------------------------------------------------
- */
-
-static int
-TriggerEventListeners(interp, type, tokenPtr, eventObjPtr, eventPtr)
-     Tcl_Interp *interp;
-     Tcl_HashTable *type;
-     void *tokenPtr;
-     Tcl_Obj *eventObjPtr;
-     TclDOM_libxml2_Event *eventPtr;
-{
-  Tcl_HashEntry *entryPtr;
-  Tcl_HashTable *tablePtr;
-  Tcl_Obj *listenerListPtr;
-  int listenerLen, listenerIdx;
-  char *eventType;
-
-  entryPtr = Tcl_FindHashEntry(type, tokenPtr);
-  if (!entryPtr) {
-    return TCL_OK;
-  }
-  tablePtr = (Tcl_HashTable *) Tcl_GetHashValue(entryPtr);
-
-  if (eventPtr->type != TCLDOM_EVENT_USERDEFINED) {
-	eventType = (char *) TclDOM_EventTypes[eventPtr->type];
-  } else {
-	eventType = Tcl_GetStringFromObj(eventPtr->typeObjPtr, NULL);
-  }
-  entryPtr = Tcl_FindHashEntry(tablePtr, eventType);
-  if (!entryPtr) {
-    return TCL_OK;
-  }
-  listenerListPtr = (Tcl_Obj *) Tcl_GetHashValue(entryPtr);
-
-  /*
-   * DOM L2 specifies that the ancestors are determined
-   * at the moment of event dispatch, so using a static
-   * list is the correct thing to do.
-   */
-
-  Tcl_ListObjLength(interp, listenerListPtr, &listenerLen);
-  for (listenerIdx = 0; listenerIdx < listenerLen; listenerIdx++) {
-    Tcl_Obj *listenerObj, *cmdPtr;
-
-    Tcl_ListObjIndex(interp, listenerListPtr, listenerIdx, &listenerObj);
-
-    cmdPtr = Tcl_DuplicateObj(listenerObj);
-	Tcl_IncrRefCount(cmdPtr);
-    if (Tcl_ListObjAppendElement(interp, cmdPtr, eventObjPtr) != TCL_OK) {
-	  Tcl_DecrRefCount(cmdPtr);
-      return TCL_ERROR;
-    }
-	Tcl_Preserve((ClientData) interp);
-    if (Tcl_GlobalEvalObj(interp, cmdPtr) != TCL_OK) {
-      Tcl_BackgroundError(interp);
-    }
-	Tcl_DecrRefCount(cmdPtr);
-	Tcl_Release((ClientData) interp);
-  }
-
-  return TCL_OK;
-}
-
-static int
-TclDOMSetLiveNodeListNode(interp, varName, nodePtr)
-    Tcl_Interp *interp;
-    char *varName;
-    xmlNodePtr nodePtr;
-{
-  Tcl_Obj *valuePtr = Tcl_NewListObj(0, NULL);
-  xmlNodePtr childPtr;
-
-  for (childPtr = nodePtr->children; childPtr; childPtr = childPtr->next) {
-    Tcl_ListObjAppendElement(interp, valuePtr, TclDOM_libxml2_CreateObjFromNode(interp, childPtr));
-  }
-
-  Tcl_SetVar2Ex(interp, varName, NULL, valuePtr, TCL_GLOBAL_ONLY);
-
-  return TCL_OK;
-}
-
-static int
-TclDOMSetLiveNodeListDoc(interp, varName, docPtr)
-    Tcl_Interp *interp;
-    char *varName;
-    xmlDocPtr docPtr;
-{
-  Tcl_Obj *valuePtr = Tcl_NewListObj(0, NULL);
-  xmlNodePtr childPtr;
-
-  for (childPtr = docPtr->children; childPtr; childPtr = childPtr->next) {
-    Tcl_ListObjAppendElement(interp, valuePtr, TclDOM_libxml2_CreateObjFromNode(interp, childPtr));
-  }
-
-  Tcl_SetVar2Ex(interp, varName, NULL, valuePtr, TCL_GLOBAL_ONLY);
-
-  return TCL_OK;
-}
-
-static char *
-TclDOMLiveNodeListNode(clientData, interp, name1, name2, flags)
-    ClientData clientData;
-    Tcl_Interp *interp;
-    char *name1;
-    char *name2;
-    int flags;
-{
-  xmlNodePtr nodePtr = (xmlNodePtr) clientData;
-
-  if (flags & (TCL_INTERP_DESTROYED | TCL_TRACE_DESTROYED)) {
-    return NULL;
-  } else if (flags & TCL_TRACE_READS) {
-    TclDOMSetLiveNodeListNode(interp, name1, nodePtr);
-  } else if (flags & TCL_TRACE_WRITES) {
-    TclDOMSetLiveNodeListNode(interp, name1, nodePtr);
-    return "variable is read-only";
-  } else if (flags & TCL_TRACE_UNSETS) {
-  }
-
-  return NULL;
-}
-static char *
-TclDOMLiveNodeListDoc(clientData, interp, name1, name2, flags)
-    ClientData clientData;
-    Tcl_Interp *interp;
-    char *name1;
-    char *name2;
-    int flags;
-{
-  xmlDocPtr docPtr = (xmlDocPtr) clientData;
-
-  if (flags & (TCL_INTERP_DESTROYED | TCL_TRACE_DESTROYED)) {
-    return NULL;
-  } else if (flags & TCL_TRACE_READS) {
-    TclDOMSetLiveNodeListDoc(interp, name1, docPtr);
-  } else if (flags & TCL_TRACE_WRITES) {
-    TclDOMSetLiveNodeListDoc(interp, name1, docPtr);
-    return "variable is read-only";
-  } else if (flags & TCL_TRACE_UNSETS) {
-  }
-
-  return NULL;
-}
-
-static int
-TclDOMSetLiveNamedNodeMap(interp, varName, nodePtr)
-    Tcl_Interp *interp;
-    char *varName;
-    xmlNodePtr nodePtr;
-{
-  xmlAttrPtr attrPtr;
-
-  Tcl_UnsetVar(interp, varName, TCL_GLOBAL_ONLY);
-
-  for (attrPtr = nodePtr->properties; attrPtr; attrPtr = attrPtr->next) {
-
-    if (Tcl_SetVar2Ex(interp, varName, (char *) attrPtr->name, Tcl_NewStringObj((CONST char *) xmlGetProp(nodePtr, attrPtr->name), -1), TCL_GLOBAL_ONLY) == NULL) {
-      Tcl_ResetResult(interp);
-      Tcl_AppendResult(interp, "unable to set attribute \"", attrPtr->name, "\"", NULL);
-      return TCL_ERROR;
-    }
-
-    if (Tcl_TraceVar2(interp, varName, (char *) attrPtr->name, TCL_TRACE_READS|TCL_TRACE_WRITES|TCL_TRACE_UNSETS|TCL_GLOBAL_ONLY, (Tcl_VarTraceProc *) TclDOMLiveNamedNodeMap, (ClientData) nodePtr) != TCL_OK) {
-      return TCL_ERROR;
-    }
-  }
-
-  return TCL_OK;
-}
-
-static char *
-TclDOMLiveNamedNodeMap(clientData, interp, name1, name2, flags)
-    ClientData clientData;
-    Tcl_Interp *interp;
-    char *name1;
-    char *name2;
-    int flags;
-{
-  xmlNodePtr nodePtr = (xmlNodePtr) clientData;
-
-  if (flags & (TCL_INTERP_DESTROYED | TCL_TRACE_DESTROYED)) {
-    return NULL;
-  } else if (flags & TCL_TRACE_READS && name2 == NULL) {
-    TclDOMSetLiveNamedNodeMap(interp, name1, nodePtr);
-  } else if (flags & TCL_TRACE_READS && name2 != NULL) {
-    if (Tcl_SetVar2Ex(interp, name1, name2, Tcl_NewStringObj((CONST char *) xmlGetProp(nodePtr, (const xmlChar *) name2), -1), TCL_GLOBAL_ONLY) == NULL) {
-      return "unable to set attribute";
-    }
-  } else if (flags & TCL_TRACE_WRITES) {
-    TclDOMSetLiveNamedNodeMap(interp, name1, nodePtr);
-    return "variable is read-only";
-  } else if (flags & TCL_TRACE_UNSETS) {
-  }
-
-  return NULL;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclDOMNodeCommand --
- *
- *  Implements dom::libxml2::node command.
- *
- * Results:
- *  Depends on method.
- *
- * Side effects:
- *  Depends on method.
- *
- *----------------------------------------------------------------------------
- */
-
-int
-TclDOMNodeCommand (clientData, interp, objc, objv)
-     ClientData clientData;
-     Tcl_Interp *interp;
-     int objc;
-     Tcl_Obj *CONST objv[];
-{
-  TclXML_libxml2_Document *tDocPtr;
-  TclDOM_libxml2_Node *tNodePtr;
-  int method, optobjc, option, wrongidx, usecapture = 0;
-  char *buf;
-  xmlNodePtr nodePtr = NULL, childNodePtr, refPtr, newPtr, oldParent;
-  xmlDocPtr docPtr = NULL;
-  Tcl_Obj *nodeObjPtr = NULL;
-  Tcl_Obj *docObjPtr = NULL;
-  Tcl_Obj *resultPtr;
-  Tcl_Obj *CONST *optobjv;
-
-  if (clientData == NULL) {
-
-    if (objc < 3) {
-      Tcl_WrongNumArgs(interp, 1, objv, "method token ?arg ...?");
-      return TCL_ERROR;
-    }
-
-    if (TclDOM_libxml2_GetTclNodeFromObj(interp, objv[2], &tNodePtr) != TCL_OK) {
-      if (TclXML_libxml2_GetTclDocFromObj(interp, objv[2], &tDocPtr) != TCL_OK) {
-		Tcl_ResetResult(interp);
-		Tcl_AppendResult(interp, "\"", Tcl_GetStringFromObj(objv[2], NULL), "\" is neither a DOM document nor a DOM node", NULL);
-		return TCL_ERROR;
-      } else {
-		Tcl_ResetResult(interp);
-		docObjPtr = objv[2];
-		docPtr = tDocPtr->docPtr;
-		nodeObjPtr = NULL;
-		nodePtr = NULL;
-      }
-    } else {
-      nodePtr = tNodePtr->ptr.nodePtr;
-      nodeObjPtr = objv[2];
-      docPtr = NULL;
-      docObjPtr = NULL;
-      if (TclXML_libxml2_GetTclDocFromNode(interp, nodePtr, &tDocPtr) != TCL_OK) {
-		return TCL_ERROR;
-      }
-    }
-
-    optobjc = objc - 3;
-    optobjv = objv + 3;
-    wrongidx = 3;
-
-  } else {
-    if (objc < 2) {
-      Tcl_WrongNumArgs(interp, 1, objv, "method ?arg ...?");
-      return TCL_ERROR;
-    }
-
-    tNodePtr = (TclDOM_libxml2_Node *) clientData;
-    nodePtr = tNodePtr->ptr.nodePtr;
-    nodeObjPtr = NULL;
-    docPtr = NULL;
-    docObjPtr = NULL;
-    if (TclXML_libxml2_GetTclDocFromNode(interp, nodePtr, &tDocPtr) != TCL_OK) {
-      return TCL_ERROR;
-    }
-
-    optobjc = objc - 2;
-    optobjv = objv + 2;
-    wrongidx = 2;
-
-  }
-
-  if (Tcl_GetIndexFromObj(interp, objv[1], TclDOM_NodeCommandMethods,
-			  "method", 0, &method) != TCL_OK) {
-    return TCL_ERROR;
-  }
-
-  switch ((enum TclDOM_NodeCommandMethods) method) {
-
-  case TCLDOM_NODE_CGET:
-
-    if (optobjc != 1) {
-      Tcl_WrongNumArgs(interp, wrongidx, objv, "option");
-      return TCL_ERROR;
-    }
-
-    NodeCget(interp, docPtr, nodePtr, optobjv[0]);
-
-    break;
-
-  case TCLDOM_NODE_PATH:
-
-    if (docPtr) {
-      Tcl_Obj *newobjv[2];
-
-      newobjv[0] = TclXML_libxml2_CreateObjFromDoc(docPtr);
-      newobjv[1] = NULL;
-      Tcl_SetObjResult(interp, Tcl_NewListObj(1, newobjv));
-    } else {
-      Tcl_SetObjResult(interp, GetPath(interp, nodePtr));
-    }
-
-    break;
-
-  case TCLDOM_NODE_CONFIGURE:
-
-    if (optobjc < 1) {
-      Tcl_WrongNumArgs(interp, wrongidx, objv, "option ?value? ?option value ...?");
-      return TCL_ERROR;
-    }
-
-    if (optobjc == 1) {
-      return NodeCget(interp, docPtr, nodePtr, optobjv[0]);
-    }
-
-    if (optobjc % 2 == 1) {
-      Tcl_WrongNumArgs(interp, wrongidx, objv, "option ?value? ?option value ...?");
-      return TCL_ERROR;
-    }
-
-    return NodeConfigure(interp, nodePtr, optobjc, optobjv);
-    break;
-
-  case TCLDOM_NODE_INSERTBEFORE:
-    if (optobjc < 1 || optobjc > 2) {
-      Tcl_WrongNumArgs(interp, wrongidx, objv, "ref ?new?");
-      return TCL_ERROR;
-    } else if (docPtr) {
-      /* TODO: allow comments & PIs in document prologue */
-      Tcl_SetResult(interp, "document already has document element", NULL);
-      return TCL_ERROR;
-    } else if (optobjc == 1) {
-      /* No reference child specified - new appended to child list */
-      if (TclDOM_libxml2_GetNodeFromObj(interp, optobjv[0], &newPtr) != TCL_OK) {
-        return TCL_ERROR;
-      }
-      return TclDOM_NodeAppendChild(interp, nodePtr, newPtr);
-    } else if (optobjc == 2) {
-      if (TclDOM_libxml2_GetNodeFromObj(interp, optobjv[0], &newPtr) != TCL_OK) {
-        return TCL_ERROR;
-      }
-      if (TclDOM_libxml2_GetNodeFromObj(interp, optobjv[1], &refPtr) != TCL_OK) {
-        return TCL_ERROR;
-      }
-      return TclDOM_NodeInsertBefore(interp, refPtr, newPtr);
-    }
-
-    break;
-
-  case TCLDOM_NODE_REPLACECHILD:
-    if (optobjc !=  2) {
-      Tcl_WrongNumArgs(interp, wrongidx, objv, "new old");
-      return TCL_ERROR;
-    } else if (docPtr) {
-      /* TODO: allow replacing comments & PIs */
-      Tcl_SetResult(interp, "document already has document element", NULL);
-      return TCL_ERROR;
-    } else {
-      if (TclDOM_libxml2_GetNodeFromObj(interp, optobjv[0], &newPtr) != TCL_OK) {
-        return TCL_ERROR;
-      }
-      if (TclDOM_libxml2_GetNodeFromObj(interp, optobjv[1], &refPtr) != TCL_OK) {
-        return TCL_ERROR;
-      }
-      oldParent = newPtr->parent;
-      if (oldParent != refPtr->parent) {
-        TclDOM_PostMutationEvent(interp, 
-				 tDocPtr, 
-				 TclDOM_libxml2_CreateObjFromNode(interp, newPtr), 
-				 TCLDOM_EVENT_DOMNODEREMOVED,
-				 NULL,
-				 Tcl_NewIntObj(1), Tcl_NewIntObj(0), 
-				 TclDOM_libxml2_CreateObjFromNode(interp, newPtr->parent), 
-				 NULL, NULL, NULL, NULL);
-      }
-
-      Tcl_MutexLock(&libxml2);
-
-      if (xmlReplaceNode(refPtr, newPtr) == NULL) {
-        Tcl_SetResult(interp, "unable to replace node", NULL);
-	Tcl_MutexUnlock(&libxml2);
-        return TCL_ERROR;
-      }
-
-      Tcl_MutexUnlock(&libxml2);
-
-    }
-
-    PostMutationEvents(interp, tDocPtr, nodePtr, refPtr, newPtr, oldParent, refPtr->parent);
-
-    Tcl_SetObjResult(interp, TclDOM_libxml2_CreateObjFromNode(interp, refPtr));
-
-    break;
-
-  case TCLDOM_NODE_REMOVECHILD:
-    if (optobjc !=  1) {
-      Tcl_WrongNumArgs(interp, wrongidx, objv, "child");
-      return TCL_ERROR;
-    } else if (docPtr) {
-      /* TODO: allow removing comments & PIs */
-      Tcl_SetResult(interp, "document must have document element", NULL);
-      return TCL_ERROR;
-    } else {
-      xmlNodePtr childPtr;
-      if (TclDOM_libxml2_GetNodeFromObj(interp, optobjv[0], &childPtr) != TCL_OK) {
-        return TCL_ERROR;
-      }
-      if (nodePtr != childPtr->parent) {
-	Tcl_SetResult(interp, "not found: \"", NULL);
-	Tcl_AppendResult(interp, Tcl_GetStringFromObj(optobjv[0], NULL), 
-			 "\" is not a child", NULL);
-	if (nodeObjPtr) {
-	  Tcl_AppendResult(interp, " of \"",
-			 Tcl_GetStringFromObj(nodeObjPtr, NULL), "\"", NULL);
-	}
-	return TCL_ERROR;
-      }
-      oldParent = childPtr->parent;
-      TclDOM_PostMutationEvent(interp, 
-			       tDocPtr, optobjv[0], 
-			       TCLDOM_EVENT_DOMNODEREMOVED,
-			       NULL,
-			       Tcl_NewIntObj(1), Tcl_NewIntObj(0), 
-			       TclDOM_libxml2_CreateObjFromNode(interp, oldParent), 
-			       NULL, NULL, NULL, NULL);
-      TclDOM_PostMutationEvent(interp, 
-			       tDocPtr, optobjv[0], 
-			       TCLDOM_EVENT_DOMNODEREMOVEDFROMDOCUMENT,
-			       NULL,
-			       Tcl_NewIntObj(0), Tcl_NewIntObj(0), 
-			       NULL, NULL, NULL, NULL, NULL);
-
-      Tcl_MutexLock(&libxml2);
-      xmlUnlinkNode(childPtr);
-      Tcl_MutexUnlock(&libxml2);
-
-      Tcl_SetObjResult(interp, optobjv[0]);
-      TclDOM_PostMutationEvent(interp, 
-			       tDocPtr, 
-			       TclDOM_libxml2_CreateObjFromNode(interp, oldParent), 
-			       TCLDOM_EVENT_DOMSUBTREEMODIFIED,
-			       NULL,
-			       Tcl_NewIntObj(1), Tcl_NewIntObj(0), NULL, NULL, NULL, NULL, NULL);
-    }
-
-    break;
-
-  case TCLDOM_NODE_APPENDCHILD:
-    if (optobjc !=  1) {
-      Tcl_WrongNumArgs(interp, wrongidx, objv, "child");
-      return TCL_ERROR;
-    } else if (docPtr) {
-      xmlNodePtr oldPtr;
-
-      if (TclDOM_libxml2_GetNodeFromObj(interp, optobjv[0], &childNodePtr) != TCL_OK) {
-        return TCL_ERROR;
-      }
-
-      Tcl_MutexLock(&libxml2);
-
-      /* TODO: allow appending comments & PIs */
-      oldPtr = xmlDocSetRootElement(docPtr, childNodePtr);
-      if (oldPtr) {
-        xmlDocSetRootElement(docPtr, oldPtr);
-        Tcl_SetResult(interp, "document element already exists", NULL);
-	Tcl_MutexUnlock(&libxml2);
-        return TCL_ERROR;
-      }
-
-      Tcl_MutexUnlock(&libxml2);
-
-      Tcl_SetObjResult(interp, optobjv[0]);
-
-    } else {
-      if (TclDOM_libxml2_GetNodeFromObj(interp, optobjv[0], &childNodePtr) != TCL_OK) {
-        return TCL_ERROR;
-      }
-
-      return TclDOM_NodeAppendChild(interp, nodePtr, childNodePtr);
-    }
-
-    break;
-
-  case TCLDOM_NODE_HASCHILDNODES:
-    if (docPtr) {
-      if (docPtr->children) {
-       Tcl_SetObjResult(interp, Tcl_NewBooleanObj(1));
-      } else {
-       Tcl_SetObjResult(interp, Tcl_NewBooleanObj(0));
-      }
-    } else {
-      if (nodePtr->children) {
-       Tcl_SetObjResult(interp, Tcl_NewBooleanObj(1));
-      } else {
-       Tcl_SetObjResult(interp, Tcl_NewBooleanObj(0));
-      }
-    }
-
-    break;
-
-  case TCLDOM_NODE_ISSAMENODE:
-    /* DOM Level 3 method */
-
-    if (optobjc != 1) {
-      Tcl_WrongNumArgs(interp, wrongidx, objv, "ref");
-      return TCL_ERROR;
-    }
-
-    if (docPtr) {
-      xmlDocPtr docRefPtr;
-
-      if (TclXML_libxml2_GetDocFromObj(interp, optobjv[0], &docRefPtr) != TCL_OK) {
-	Tcl_SetObjResult(interp, Tcl_NewBooleanObj(0));
-	return TCL_OK;
-      }
-
-      Tcl_SetObjResult(interp, Tcl_NewBooleanObj(docPtr == docRefPtr));
-
-    } else {
-      if (TclDOM_libxml2_GetNodeFromObj(interp, optobjv[0], &refPtr) != TCL_OK) {
-	Tcl_SetObjResult(interp, Tcl_NewBooleanObj(0));
-	return TCL_OK;
-      }
-
-      Tcl_SetObjResult(interp, Tcl_NewBooleanObj(nodePtr == refPtr));
-    }
-
-    break;
-
-  case TCLDOM_NODE_CLONENODE:
-    if (optobjc != 0 && optobjc != 2) {
-      Tcl_WrongNumArgs(interp, wrongidx, objv, "?-deep boolean?");
-      return TCL_ERROR;
-    } else if (docPtr) {
-      Tcl_SetResult(interp, "documents cannot be cloned", NULL);
-      return TCL_ERROR;
-    } else {
-      int deep = 0;
-      xmlNodePtr copyPtr;
-
-      if (optobjc == 2) {
-	if (Tcl_RegExpMatchObj(interp, optobjv[0], Tcl_NewStringObj("-de?e?p?", -1)) == 0) {
-	  Tcl_ResetResult(interp);
-	  Tcl_AppendResult(interp, "invalid option \"", Tcl_GetStringFromObj(optobjv[0], NULL), "\", must be \"-deep\"", NULL);
-	  return TCL_ERROR;
-	}
-        if (Tcl_GetBooleanFromObj(interp, optobjv[1], &deep) != TCL_OK) {
-          return TCL_ERROR;
-        }
-      }
-
-      Tcl_MutexLock(&libxml2);
-      copyPtr = xmlDocCopyNode(nodePtr, nodePtr->doc, deep);
-      Tcl_MutexUnlock(&libxml2);
-
-      if (copyPtr == NULL) {
-        Tcl_SetResult(interp, "unable to copy node", NULL);
-        return TCL_ERROR;
-      }
-      Tcl_SetObjResult(interp, TclDOM_libxml2_CreateObjFromNode(interp, copyPtr));
-    }
-    break;
-
-  case TCLDOM_NODE_PARENT:
-
-    if (docPtr) {
-      break;
-    }
-
-    if (nodePtr->parent) {
-      Tcl_SetObjResult(interp, TclDOM_libxml2_CreateObjFromNode(interp, nodePtr->parent));
-    } else {
-      Tcl_SetObjResult(interp, TclXML_libxml2_CreateObjFromDoc(nodePtr->doc));
-    }
-
-    break;
-
-  case TCLDOM_NODE_CHILDREN:
-
-    resultPtr = Tcl_NewListObj(0, NULL);
-
-    if (docPtr) {
-      childNodePtr = docPtr->children;
-    } else {
-      childNodePtr = nodePtr->children;
-    }
-
-    while (childNodePtr) {
-      Tcl_ListObjAppendElement(interp, resultPtr, TclDOM_libxml2_CreateObjFromNode(interp, childNodePtr));
-      childNodePtr = childNodePtr->next;
-    }
-
-    Tcl_SetObjResult(interp, resultPtr);
-
-    break;
-
-  case TCLDOM_NODE_ADDEVENTLISTENER:
-
-	/* TODO: type optional, missing type returns all types that have a listener */
-
-    if (optobjc < 1) {
-	  Tcl_WrongNumArgs(interp, wrongidx, objv, "type ?listener? ?-usecapture boolean?");
-      return TCL_ERROR;
-    } else {
-      enum TclDOM_EventTypes type;
-      Tcl_Obj *typeObjPtr, *listenerPtr = NULL;
-      void *tokenPtr = NULL;
-
-      if (nodePtr) {
-		tokenPtr = (void *) nodePtr;
-      } else {
-		tokenPtr = (void *) docPtr;
-      }
-
-      if (Tcl_GetIndexFromObj(interp, optobjv[0], TclDOM_EventTypes,
-							  "type", TCL_EXACT, &option) == TCL_OK) {
-		type = (enum TclDOM_EventTypes) option;
-      } else {
-		type = TCLDOM_EVENT_USERDEFINED;
-      }
-      typeObjPtr = optobjv[0];
-	  Tcl_ResetResult(interp);
-      optobjc -= 1;
-      optobjv += 1;
-
-	  if (optobjc > 0 && *Tcl_GetStringFromObj(optobjv[0], NULL) != '-') {
-		listenerPtr = optobjv[0];
-		optobjc -= 1;
-		optobjv += 1;
-	  } /* else we will return the registered listener */
-
-	  while (optobjc) {
-		if (optobjc == 1) {
-		  Tcl_SetResult(interp, "missing value", NULL);
-		  return TCL_ERROR;
-		}
-		if (Tcl_GetIndexFromObj(interp, optobjv[0], TclDOM_NodeCommandAddEventListenerOptions,
-								"option", 0, &option) != TCL_OK) {
-		  return TCL_ERROR;
-		}
-		switch ((enum TclDOM_NodeCommandAddEventListenerOptions) option) {
-		  case TCLDOM_NODE_ADDEVENTLISTENER_USECAPTURE:
-
-			if (Tcl_GetBooleanFromObj(interp, optobjv[1], &usecapture) != TCL_OK) {
-			  return TCL_ERROR;
-			}
-
-			break;
-
-		  default:
-			Tcl_SetResult(interp, "unknown option", NULL);
-			return TCL_ERROR;
-		}
-
-		optobjc -= 2;
-		optobjv += 2;
-	  }
-
-	  if (nodePtr) {
-		docObjPtr = TclXML_libxml2_CreateObjFromDoc(nodePtr->doc);
-	  } else {
-		docObjPtr = TclXML_libxml2_CreateObjFromDoc(docPtr);
-	  }
-	  TclXML_libxml2_GetTclDocFromObj(interp, docObjPtr, &tDocPtr);
-
-	  if (listenerPtr == NULL) {
-		listenerPtr = TclDOM_GetEventListener(interp, tDocPtr, tokenPtr, type, typeObjPtr, usecapture);
-		if (listenerPtr) {
-		  Tcl_SetObjResult(interp, listenerPtr);
-		} else {
-		  Tcl_SetResult(interp, "unable to find listeners", NULL);
-		  return TCL_ERROR;
-		}
-	  } else {
-		return TclDOM_AddEventListener(interp, tDocPtr, tokenPtr, type, typeObjPtr, listenerPtr, usecapture);
-	  }
-	}
-
-  break;
-
-
-  case TCLDOM_NODE_REMOVEEVENTLISTENER:
-
-    if (optobjc < 2) {
-      Tcl_WrongNumArgs(interp, wrongidx, objv, "type listener ?-usecapture boolean?");
-      return TCL_ERROR;
-    } else {
-      Tcl_Obj *typeObjPtr, *listenerPtr;
-      void *tokenPtr = NULL;
-      TclXML_libxml2_Document *tDocPtr;
-      enum TclDOM_EventTypes type;
-
-      if (nodePtr) {
-        tokenPtr = (void *) nodePtr;
-      } else {
-        tokenPtr = (void *) docPtr;
-      }
-
-      typeObjPtr = optobjv[0];
-      if (Tcl_GetIndexFromObj(interp, optobjv[0], TclDOM_EventTypes,
-			      "type", TCL_EXACT, &option) == TCL_OK) {
-		type = (enum TclDOM_EventTypes) option;
-      } else {
-		type = TCLDOM_EVENT_USERDEFINED;
-      }
-      listenerPtr = optobjv[1];
-
-      optobjc -= 2;
-      optobjv += 2;
-      while (optobjc) {
-		if (Tcl_GetIndexFromObj(interp, optobjv[0], TclDOM_NodeCommandAddEventListenerOptions,
-				"option", 0, &option) != TCL_OK) {
-		  return TCL_ERROR;
-		}
-		switch ((enum TclDOM_NodeCommandAddEventListenerOptions) option) {
-		  case TCLDOM_NODE_ADDEVENTLISTENER_USECAPTURE:
-
-			if (Tcl_GetBooleanFromObj(interp, optobjv[1], &usecapture) != TCL_OK) {
-			  return TCL_ERROR;
-			}
-
-			break;
-
-		  default:
-			Tcl_SetResult(interp, "unknown option", NULL);
-			return TCL_ERROR;
-		}
-
-		optobjc -= 2;
-		optobjv += 2;
-		}
-
-		if (nodePtr) {
-		  if (TclXML_libxml2_GetTclDocFromNode(interp, nodePtr, &tDocPtr) != TCL_OK) {
-			return TCL_ERROR;
-		  }
-		} else {
-		  docObjPtr = TclXML_libxml2_CreateObjFromDoc(docPtr);
-		  if (TclXML_libxml2_GetTclDocFromObj(interp, docObjPtr, &tDocPtr) != TCL_OK) {
-			return TCL_ERROR;
-		  }
-		}
-
-		return TclDOM_RemoveEventListener(interp, tDocPtr, tokenPtr, type, typeObjPtr, listenerPtr, usecapture);
-	  }
-
-    break;
-
-  case TCLDOM_NODE_DISPATCHEVENT:
-
-    if (optobjc != 1) {
-      Tcl_WrongNumArgs(interp, wrongidx, objv, "event");
-      return TCL_ERROR;
-    } else {
-      TclDOM_libxml2_Event *eventPtr;
-
-      if (TclDOM_libxml2_GetEventFromObj(interp, optobjv[0], &eventPtr) != TCL_OK) {
-		return TCL_ERROR;
-      }
-
-      if (nodeObjPtr) {
-		return TclDOM_DispatchEvent(interp, nodeObjPtr, optobjv[0], eventPtr);
-	  } else if (nodePtr) {
-		return TclDOM_DispatchEvent(interp, TclDOM_libxml2_CreateObjFromNode(interp, nodePtr), optobjv[0], eventPtr);
-	  } else if (docObjPtr) {
-		return TclDOM_DispatchEvent(interp, docObjPtr, optobjv[0], eventPtr);
-	  } else {
-		Tcl_SetResult(interp, "unable to dispatch event", NULL);
-		return TCL_ERROR;
-	  }
-    }
-
-    break;
-
-  case TCLDOM_NODE_STRINGVALUE:
-
-    if (optobjc != 0) {
-      Tcl_WrongNumArgs(interp, wrongidx, objv, "");
-      return TCL_ERROR;
-    }
-
-    Tcl_ResetResult(interp);
-
-    Tcl_MutexLock(&libxml2);
-
-    if (nodePtr) {
-      buf = (char *) xmlNodeGetContent(nodePtr);
-      Tcl_SetObjResult(interp, Tcl_NewStringObj(buf, -1));
-      xmlFree (buf);
-    } else if (docPtr) {
-      nodePtr = xmlDocGetRootElement(docPtr);
-      if (nodePtr) {
-        buf = (char *) xmlNodeGetContent(nodePtr);
-        Tcl_SetObjResult(interp, Tcl_NewStringObj(buf, -1));
-        xmlFree (buf);
-      } else {
-	nodePtr = docPtr->children;
-	while (nodePtr != NULL) {
-	  if (nodePtr->type == XML_TEXT_NODE) {
-	    Tcl_AppendResult(interp, (char *) nodePtr->content, NULL);
-	  }
-	  nodePtr = nodePtr->next;
-	}
-      }
-    } else {
-      Tcl_SetResult(interp, "cannot determine string value: internal error", NULL);
-      Tcl_MutexUnlock(&libxml2);
-      return TCL_ERROR;
-    }
-
-    Tcl_MutexUnlock(&libxml2);
-
-    break;
-
-  case TCLDOM_NODE_SELECTNODE:
-
-    Tcl_ResetResult(interp);
-
-    return TclDOMSelectNodeCommand(clientData, interp, objc - 1, objv + 1);
-
-    break;
-
-  default:
-    Tcl_SetResult(interp, "method \"", NULL);
-    Tcl_AppendResult(interp, Tcl_GetStringFromObj(objv[1], NULL), "\" not yet implemented", NULL);
-    return TCL_ERROR;
-  }
-
-  return TCL_OK;
-}
-int
-NodeCget(interp, docPtr, nodePtr, optPtr)
-     Tcl_Interp *interp;
-     xmlDocPtr docPtr;
-     xmlNodePtr nodePtr;
-     Tcl_Obj *CONST optPtr;
-{
-  TclXML_libxml2_Document *tDocPtr;
-  TclDOM_libxml2_Document *domDocPtr;
-  Tcl_Obj *objPtr;
-  xmlNodePtr childNodePtr;
-  int option;
-  char varname[100];
-  Tcl_Obj *livePtr;
-
-  if (Tcl_GetIndexFromObj(interp, optPtr, TclDOM_NodeCommandOptions,
-			  "option", 0, &option) != TCL_OK) {
-    return TCL_ERROR;
-  }
-
-  switch ((enum TclDOM_NodeCommandOptions) option) {
-
-  case TCLDOM_NODE_NODETYPE:
-
-    if (docPtr) {
-      Tcl_SetResult(interp, "document", NULL);
-      break;
-    }
-
-    switch (nodePtr->type) {
-    case XML_ELEMENT_NODE:
-      Tcl_SetResult(interp, "element", NULL);
-      break;
-    case XML_ATTRIBUTE_NODE:
-      Tcl_SetResult(interp, "attribute", NULL);
-      break;
-    case XML_TEXT_NODE:
-    case XML_CDATA_SECTION_NODE:
-      Tcl_SetResult(interp, "textNode", NULL);
-      break;
-    case XML_ENTITY_REF_NODE:
-      Tcl_SetResult(interp, "entityReference", NULL);
-      break;
-    case XML_ENTITY_NODE:
-      Tcl_SetResult(interp, "entity", NULL);
-      break;
-    case XML_PI_NODE:
-      Tcl_SetResult(interp, "processingInstruction", NULL);
-      break;
-    case XML_COMMENT_NODE:
-      Tcl_SetResult(interp, "comment", NULL);
-      break;
-    case XML_DOCUMENT_NODE:
-      Tcl_SetResult(interp, "document", NULL);
-      break;
-    case XML_DOCUMENT_TYPE_NODE:
-      Tcl_SetResult(interp, "docType", NULL);
-      break;
-    case XML_DOCUMENT_FRAG_NODE:
-      Tcl_SetResult(interp, "documentFragment", NULL);
-      break;
-    case XML_NOTATION_NODE:
-      Tcl_SetResult(interp, "notation", NULL);
-      break;
-    case XML_HTML_DOCUMENT_NODE:
-      Tcl_SetResult(interp, "HTMLdocument", NULL);
-      break;
-    case XML_DTD_NODE:
-      Tcl_SetResult(interp, "dtd", NULL);
-      break;
-    case XML_ELEMENT_DECL:
-      Tcl_SetResult(interp, "elementDecl", NULL);
-      break;
-    case XML_ATTRIBUTE_DECL:
-      Tcl_SetResult(interp, "attributeDecl", NULL);
-      break;
-    case XML_ENTITY_DECL:
-      Tcl_SetResult(interp, "entityDecl", NULL);
-      break;
-    case XML_NAMESPACE_DECL:
-      Tcl_SetResult(interp, "namespaceDecl", NULL);
-      break;
-    case XML_XINCLUDE_START:
-      Tcl_SetResult(interp, "xincludeStart", NULL);
-      break;
-    case XML_XINCLUDE_END:
-      Tcl_SetResult(interp, "xincludeEnd", NULL);
-      break;
-    default:
-      Tcl_SetResult(interp, "unknown", NULL);
-    }
-
-    break;
-
-  case TCLDOM_NODE_LOCALNAME:
-  case TCLDOM_NODE_NODENAME:
-
-    /* This isn't quite right: nodeName should return the expanded name */
-
-    if (docPtr) {
-      Tcl_SetResult(interp, "#document", NULL);
-      break;
-    }
-    /* libxml2 doesn't maintain the correct DOM node name */
-    switch (nodePtr->type) {
-    case XML_ELEMENT_NODE:
-    case XML_ATTRIBUTE_NODE:
-    case XML_ENTITY_REF_NODE:
-    case XML_ENTITY_NODE:
-    case XML_PI_NODE:
-    case XML_DOCUMENT_TYPE_NODE:
-    case XML_NOTATION_NODE:
-      Tcl_SetObjResult(interp, Tcl_NewStringObj((CONST char *) nodePtr->name, -1));
-      break;
-    case XML_TEXT_NODE:
-      Tcl_SetResult(interp, "#text", NULL);
-      break;
-    case XML_CDATA_SECTION_NODE:
-      Tcl_SetResult(interp, "#cdata-section", NULL);
-      break;
-    case XML_COMMENT_NODE:
-      Tcl_SetResult(interp, "#comment", NULL);
-      break;
-    case XML_DOCUMENT_NODE:
-      /* Already handled above */
-      Tcl_SetResult(interp, "#document", NULL);
-      break;
-    case XML_DOCUMENT_FRAG_NODE:
-      Tcl_SetResult(interp, "#document-fragment", NULL);
-      break;
-    case XML_HTML_DOCUMENT_NODE:
-      /* Not standard DOM */
-      Tcl_SetResult(interp, "#HTML-document", NULL);
-      break;
-    case XML_DTD_NODE:
-      /* Not standard DOM */
-      Tcl_SetResult(interp, "#dtd", NULL);
-      break;
-    case XML_ELEMENT_DECL:
-      /* Not standard DOM */
-      Tcl_SetResult(interp, "#element-declaration", NULL);
-      break;
-    case XML_ATTRIBUTE_DECL:
-      /* Not standard DOM */
-      Tcl_SetResult(interp, "#attribute-declaration", NULL);
-      break;
-    case XML_ENTITY_DECL:
-      /* Not standard DOM */
-      Tcl_SetResult(interp, "#entity-declaration", NULL);
-      break;
-    case XML_NAMESPACE_DECL:
-      /* Not standard DOM */
-      Tcl_SetResult(interp, "#namespace-declaration", NULL);
-      break;
-    case XML_XINCLUDE_START:
-      /* Not standard DOM */
-      Tcl_SetResult(interp, "#xinclude-start", NULL);
-      break;
-    case XML_XINCLUDE_END:
-      /* Not standard DOM */
-      Tcl_SetResult(interp, "#xinclude-end", NULL);
-      break;
-    default:
-      Tcl_SetResult(interp, "#unknown", NULL);
-    }
-
-    break;
-
-  case TCLDOM_NODE_NODEVALUE:
-
-    if (docPtr) {
-      break;
-    }
-
-    Tcl_MutexLock(&libxml2);
-
-    if (XML_GET_CONTENT(nodePtr) != NULL) {
-      Tcl_SetObjResult(interp, Tcl_NewStringObj((CONST char *) XML_GET_CONTENT(nodePtr), -1));
-    }
-
-    Tcl_MutexUnlock(&libxml2);
-
-    break;
-
-  case TCLDOM_NODE_OWNERDOCUMENT:
-
-    if (docPtr) {
-      Tcl_SetObjResult(interp, TclXML_libxml2_CreateObjFromDoc(docPtr));
-      break;
-    }
-
-    Tcl_SetObjResult(interp, TclXML_libxml2_CreateObjFromDoc(nodePtr->doc));
-
-    break;
-
-  case TCLDOM_NODE_PARENTNODE:
-
-    if (docPtr) {
-      Tcl_ResetResult(interp);
-      break;
-    }
-
-    if (nodePtr->parent) {
-      if (nodePtr->parent->type == XML_DOCUMENT_NODE ||
-	  nodePtr->parent->type == XML_HTML_DOCUMENT_NODE) {
-	Tcl_SetObjResult(interp, TclXML_libxml2_CreateObjFromDoc(nodePtr->doc));
-      } else {
-	Tcl_SetObjResult(interp, TclDOM_libxml2_CreateObjFromNode(interp, nodePtr->parent));
-      }
-    } else {
-      Tcl_SetObjResult(interp, TclXML_libxml2_CreateObjFromDoc(nodePtr->doc));
-    }
-
-    break;
-
-  case TCLDOM_NODE_CHILDNODES:
-
-    /* Set up live NodeList variable */
-
-    if (docPtr) {
-      objPtr = TclXML_libxml2_CreateObjFromDoc(docPtr);
-      if (TclXML_libxml2_GetTclDocFromObj(interp, objPtr, &tDocPtr) != TCL_OK) {
-	return TCL_ERROR;
-      }
-    } else {
-      if (TclXML_libxml2_GetTclDocFromNode(interp, nodePtr, &tDocPtr) != TCL_OK) {
-	return TCL_ERROR;
-      }
-    }
-    domDocPtr = GetDOMDocument(interp, tDocPtr);
-    if (domDocPtr == NULL) {
-      Tcl_SetResult(interp, "internal error", NULL);
-      return TCL_ERROR;
-    }
-    sprintf(varname, "::dom::%s::nodelist.%d", tDocPtr->token, domDocPtr->nodeCntr++);
-    livePtr = Tcl_GetVar2Ex(interp, varname, NULL, TCL_GLOBAL_ONLY);
-    if (!livePtr) {
-      Tcl_Obj *nodelistPtr = Tcl_NewListObj(0, NULL);
-
-      Tcl_SetVar2Ex(interp, varname, NULL, nodelistPtr, TCL_GLOBAL_ONLY);
-      Tcl_IncrRefCount(nodelistPtr);
-
-      if (docPtr) {
-	if (Tcl_TraceVar(interp, varname, TCL_TRACE_READS|TCL_TRACE_WRITES|TCL_TRACE_UNSETS|TCL_GLOBAL_ONLY, (Tcl_VarTraceProc *) TclDOMLiveNodeListDoc, (ClientData) docPtr) != TCL_OK) {
-	  Tcl_DecrRefCount(nodelistPtr);
-	  return TCL_ERROR;
-	} else {
-	  TclDOMLiveNodeListDoc((ClientData) tDocPtr->docPtr, interp, varname, NULL, TCL_TRACE_READS);
-	}
-      } else {
-	if (Tcl_TraceVar(interp, varname, TCL_TRACE_READS|TCL_TRACE_WRITES|TCL_TRACE_UNSETS|TCL_GLOBAL_ONLY, (Tcl_VarTraceProc *) TclDOMLiveNodeListNode, (ClientData) nodePtr) != TCL_OK) {
-	  Tcl_DecrRefCount(nodelistPtr);
-	  return TCL_ERROR;
-	} else {
-	  TclDOMLiveNodeListNode((ClientData) nodePtr, interp, varname, NULL, TCL_TRACE_READS);
-	}
-      }
-    }
-
-    Tcl_SetObjResult(interp, Tcl_NewStringObj(varname, -1));
-
-    break;
-
-  case TCLDOM_NODE_FIRSTCHILD:
-
-    /*
-     * Handle case where no children are present
-     * Bug #1089114 w/- patch by dwcollins
-     */
-
-    if (docPtr) {
-      childNodePtr = docPtr->children;
-    } else {
-      childNodePtr = nodePtr->children;
-    }
-
-    if (childNodePtr != NULL) {
-      Tcl_SetObjResult(interp, 
-		       TclDOM_libxml2_CreateObjFromNode(interp, childNodePtr));
-    }
-
-    break;
-
-  case TCLDOM_NODE_LASTCHILD:
-
-    if (docPtr) {
-      childNodePtr = docPtr->last;
-    } else {
-      Tcl_MutexLock(&libxml2);
-      childNodePtr = xmlGetLastChild(nodePtr);
-      Tcl_MutexUnlock(&libxml2);
-    }
-    if (childNodePtr != NULL) {
-      Tcl_SetObjResult(interp, TclDOM_libxml2_CreateObjFromNode(interp, childNodePtr));
-    }
-
-    break;
-
-  case TCLDOM_NODE_NEXTSIBLING:
-    if (!docPtr && nodePtr->next) {
-      Tcl_SetObjResult(interp, TclDOM_libxml2_CreateObjFromNode(interp, nodePtr->next));
-    }
-
-    break;
-      
-  case TCLDOM_NODE_PREVIOUSSIBLING:
-    if (!docPtr && nodePtr->prev) {
-      Tcl_SetObjResult(interp, TclDOM_libxml2_CreateObjFromNode(interp, nodePtr->prev));
-    }
-
-    break;
-
-  case TCLDOM_NODE_ATTRIBUTES:
-
-    if (docPtr) {
-      Tcl_ResetResult(interp);
-      return TCL_OK;
-    } else if (nodePtr->type != XML_ELEMENT_NODE) {
-      Tcl_SetResult(interp, "wrong object type", NULL);
-      return TCL_ERROR;
-    } else {
-      /* Set up live NamedNodeMap variable */
-
-      /* If there's already a variable, return it */
-      objPtr = TclXML_libxml2_CreateObjFromDoc(nodePtr->doc);
-      TclXML_libxml2_GetTclDocFromObj(interp, objPtr, &tDocPtr);
-      domDocPtr = GetDOMDocument(interp, tDocPtr);
-      if (domDocPtr == NULL) {
-	Tcl_SetResult(interp, "internal error", NULL);
-	return TCL_ERROR;
-      }
-      sprintf(varname, "::dom::%s::att%d", tDocPtr->token, domDocPtr->nodeCntr++);
-      livePtr = Tcl_GetVar2Ex(interp, varname, NULL, TCL_GLOBAL_ONLY);
-      if (!livePtr) {
-	if (TclDOMSetLiveNamedNodeMap(interp, varname, (ClientData) nodePtr) != TCL_OK) {
-	  Tcl_UnsetVar(interp, varname, TCL_GLOBAL_ONLY);
-	  return TCL_ERROR;
-	}
-
-	if (Tcl_TraceVar(interp, varname, TCL_TRACE_ARRAY|TCL_TRACE_READS|TCL_TRACE_WRITES|TCL_TRACE_UNSETS|TCL_GLOBAL_ONLY, (Tcl_VarTraceProc *) TclDOMLiveNamedNodeMap, (ClientData) nodePtr) != TCL_OK) {
-	  Tcl_UnsetVar(interp, varname, TCL_GLOBAL_ONLY);
-	  return TCL_ERROR;
-	}
-      }
-
-      Tcl_SetObjResult(interp, Tcl_NewStringObj(varname, -1));
-
-    }
-
-    break;
-
-  case TCLDOM_NODE_NAMESPACEURI:
-
-    if (!docPtr && nodePtr->ns) {
-      if (nodePtr->ns->href) {
-	Tcl_SetObjResult(interp, Tcl_NewStringObj((CONST char *) nodePtr->ns->href, -1));
-      }
-    }
-
-    break;
-
-  case TCLDOM_NODE_PREFIX:
-
-    if (!docPtr && nodePtr->ns) {
-      if (nodePtr->ns->prefix) {
-	Tcl_SetObjResult(interp, Tcl_NewStringObj((CONST char *) nodePtr->ns->prefix, -1));
-      }
-    }
-
-    break;
-
-  default:
-    Tcl_SetResult(interp, "unknown option or not yet implemented", NULL);
-    return TCL_ERROR;
-  }
-
-  return TCL_OK;
-}
-int
-NodeConfigure(interp, nodePtr, objc, objv)
-     Tcl_Interp *interp;
-     xmlNodePtr nodePtr;
-     int objc;
-     Tcl_Obj *CONST objv[];
-{
-  TclXML_libxml2_Document *tDocPtr;
-  Tcl_Obj *objPtr;
-  char *buf;
-  int option, len;
-
-  while (objc) {
-    if (objc == 1) {
-      Tcl_SetResult(interp, "missing value", NULL);
-      return TCL_ERROR;
-    }
-
-    if (Tcl_GetIndexFromObj(interp, objv[0], TclDOM_NodeCommandOptions,
-			    "option", 0, &option) != TCL_OK) {
-      return TCL_ERROR;
-    }
-
-    switch ((enum TclDOM_NodeCommandOptions) option) {
-    case TCLDOM_NODE_NODETYPE:
-    case TCLDOM_NODE_NODENAME:
-    case TCLDOM_NODE_PARENTNODE:
-    case TCLDOM_NODE_CHILDNODES:
-    case TCLDOM_NODE_FIRSTCHILD:
-    case TCLDOM_NODE_LASTCHILD:
-    case TCLDOM_NODE_PREVIOUSSIBLING:
-    case TCLDOM_NODE_NEXTSIBLING:
-    case TCLDOM_NODE_ATTRIBUTES:
-    case TCLDOM_NODE_NAMESPACEURI:
-    case TCLDOM_NODE_PREFIX:
-    case TCLDOM_NODE_LOCALNAME:
-    case TCLDOM_NODE_OWNERDOCUMENT:
-
-      Tcl_ResetResult(interp);
-      Tcl_AppendResult(interp, "attribute \"", Tcl_GetStringFromObj(objv[0], NULL), "\" is read-only", NULL);
-      return TCL_ERROR;
-
-    case TCLDOM_NODE_NODEVALUE:
-
-      if (!nodePtr) {
-	Tcl_ResetResult(interp);
-	return TCL_OK;
-      }
-
-      switch (nodePtr->type) {
-      case XML_ELEMENT_NODE:
-      case XML_DOCUMENT_NODE:
-      case XML_DOCUMENT_FRAG_NODE:
-      case XML_DOCUMENT_TYPE_NODE:
-      case XML_ENTITY_NODE:
-      case XML_ENTITY_REF_NODE:
-      case XML_NOTATION_NODE:
-      case XML_HTML_DOCUMENT_NODE:
-      case XML_DTD_NODE:
-      case XML_ELEMENT_DECL:
-      case XML_ATTRIBUTE_DECL:
-      case XML_ENTITY_DECL:
-      case XML_NAMESPACE_DECL:
-      case XML_XINCLUDE_START:
-      case XML_XINCLUDE_END:
-	/*
-	 * DOM defines these nodes as not having a node value.
-	 * libxml2 clobbers existing content if the value is set,
-	 * so don't do it!
-	 */
-	Tcl_ResetResult(interp);
-	return TCL_OK;
-
-      default:
-	/* fall-through */
-	break;
-      }
-
-      if (TclXML_libxml2_GetTclDocFromNode(interp, nodePtr, &tDocPtr) != TCL_OK) {
-	return TCL_ERROR;
-      }
-
-      Tcl_MutexLock(&libxml2);
-
-      objPtr = Tcl_NewStringObj((CONST char *) xmlNodeGetContent(nodePtr), -1);
-
-      buf = Tcl_GetStringFromObj(objv[1], &len);
-      xmlNodeSetContentLen(nodePtr, (const xmlChar *) buf, len);
-
-      Tcl_MutexUnlock(&libxml2);
-
-      TclDOM_PostMutationEvent(interp, 
-			       tDocPtr, TclDOM_libxml2_CreateObjFromNode(interp, nodePtr), 
-			       TCLDOM_EVENT_DOMCHARACTERDATAMODIFIED, NULL,
-			       Tcl_NewIntObj(1), Tcl_NewIntObj(0), NULL, objPtr, objv[1], NULL, NULL);
-
-      Tcl_DecrRefCount(objPtr);
-
-      break;
-
-    case TCLDOM_NODE_CDATASECTION:
-
-      break;
-    }
-
-    objc -= 2;
-    objv += 2;
-
-  }
-
-  return TCL_OK;
-}
-
-int
-TclDOM_NodeAppendChild(interp, nodePtr, childPtr)
-     Tcl_Interp *interp;
-     xmlNodePtr nodePtr;
-     xmlNodePtr childPtr;
-{
-  TclXML_libxml2_Document *tDocPtr;
-  xmlNodePtr oldParent;
-  xmlNodePtr oldSibling;
-
-  if (TclXML_libxml2_GetTclDocFromNode(interp, nodePtr, &tDocPtr) != TCL_OK) {
-    return TCL_ERROR;
-  }
-
-  oldParent = childPtr->parent;
-  oldSibling = childPtr->next;
-
-  if (oldParent && oldParent != nodePtr) {
-    TclDOM_PostMutationEvent(interp, 
-			     tDocPtr,
-			     TclDOM_libxml2_CreateObjFromNode(interp, childPtr), 
-			     TCLDOM_EVENT_DOMNODEREMOVED, NULL,
-			     Tcl_NewIntObj(1), Tcl_NewIntObj(0), 
-			     TclDOM_libxml2_CreateObjFromNode(interp, oldParent), 
-			     NULL, NULL, NULL, NULL);
-  }
-
-  Tcl_MutexLock(&libxml2);
-
-  /* Although xmlAddChild claims to release the child from its previous context,
-   * that doesn't appear to actually happen.
-   */
-  xmlUnlinkNode(childPtr);
-  if (xmlAddChild(nodePtr, childPtr) == NULL) {
-    if (oldSibling) {
-      xmlAddPrevSibling(oldSibling, childPtr);
-    } else {
-      xmlAddChild(oldParent, childPtr);
-    }
-
-    Tcl_SetResult(interp, "unable to insert node", NULL);
-    Tcl_MutexUnlock(&libxml2);
-    return TCL_ERROR;
-  }
-
-  Tcl_MutexUnlock(&libxml2);
-
-  PostMutationEvents(interp, tDocPtr, nodePtr, childPtr, childPtr, oldParent, childPtr->parent);
-
-  Tcl_SetObjResult(interp, TclDOM_libxml2_CreateObjFromNode(interp, childPtr));
-
-  return TCL_OK;
-}
-
-int
-TclDOM_NodeInsertBefore(interp, refPtr, newPtr)
-     Tcl_Interp *interp;
-     xmlNodePtr refPtr;
-     xmlNodePtr newPtr;
-{
-  TclXML_libxml2_Document *tDocPtr;
-  xmlNodePtr oldParent;
-
-  if (TclXML_libxml2_GetTclDocFromNode(interp, refPtr, &tDocPtr) != TCL_OK) {
-    return TCL_ERROR;
-  }
-
-  oldParent = newPtr->parent;
-  if (oldParent != refPtr->parent) {
-    TclDOM_PostMutationEvent(interp, 
-			     tDocPtr,
-			     TclDOM_libxml2_CreateObjFromNode(interp, refPtr), 
-			     TCLDOM_EVENT_DOMNODEREMOVED, NULL,
-			     Tcl_NewIntObj(1), Tcl_NewIntObj(0), 
-			     TclDOM_libxml2_CreateObjFromNode(interp, newPtr->parent), 
-			     NULL, NULL, NULL, NULL);
-  }
-
-  Tcl_MutexLock(&libxml2);
-
-  if (xmlAddPrevSibling(refPtr, newPtr) == NULL) {
-    Tcl_SetResult(interp, "unable to insert node", NULL);
-    Tcl_MutexUnlock(&libxml2);
-    return TCL_ERROR;
-  }
-
-  Tcl_MutexUnlock(&libxml2);
-
-  PostMutationEvents(interp, tDocPtr, refPtr, refPtr, newPtr, oldParent, refPtr->parent);
-
-  return TCL_OK;
-}
-
-void PostMutationEvents(interp, tDocPtr, nodePtr, refPtr, newPtr, oldParent, newParent)
-     Tcl_Interp *interp;
-     TclXML_libxml2_Document *tDocPtr;
-     xmlNodePtr nodePtr;
-     xmlNodePtr refPtr;
-     xmlNodePtr newPtr;
-     xmlNodePtr oldParent;
-     xmlNodePtr newParent;
-{
-  /* If parent has changed, notify old parent */
-  if (oldParent != NULL && oldParent != newParent) {
-    TclDOM_PostMutationEvent(interp, 
-			     tDocPtr, 
-			     TclDOM_libxml2_CreateObjFromNode(interp, oldParent), 
-			     TCLDOM_EVENT_DOMSUBTREEMODIFIED, NULL,
-			     Tcl_NewIntObj(1), Tcl_NewIntObj(0), 
-			     NULL, NULL, NULL, NULL, NULL);
-  }
-  /* Notify new parent */
-  if (newParent != NULL) {
-    TclDOM_PostMutationEvent(interp, 
-			   tDocPtr, 
-			   TclDOM_libxml2_CreateObjFromNode(interp, newParent), 
-			   TCLDOM_EVENT_DOMSUBTREEMODIFIED, NULL,
-			   Tcl_NewIntObj(1), Tcl_NewIntObj(0), 
-			   NULL, NULL, NULL, NULL, NULL);
-  }
-
-  /* Inserted event */
-  if (newPtr != NULL) {
-    TclDOM_PostMutationEvent(interp, 
-			   tDocPtr, 
-			   TclDOM_libxml2_CreateObjFromNode(interp, newPtr), 
-			   TCLDOM_EVENT_DOMNODEINSERTED, NULL,
-			   Tcl_NewIntObj(1), Tcl_NewIntObj(0), 
-			   NULL, NULL, NULL, NULL, NULL);
-  }
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclDOM_AddEventListener --
- *
- *  Register an event listener.
- *
- * Results:
- *  Success code.
- *
- * Side effects:
- *  Event listener stored.
- *
- *----------------------------------------------------------------------------
- */
-
-int
-TclDOM_AddEventListener(interp, tDocPtr, tokenPtr, type, typeObjPtr, listenerPtr, capturer)
-    Tcl_Interp *interp;
-    TclXML_libxml2_Document *tDocPtr;
-    void *tokenPtr; /* xmlNodePtr or xmlDocPtr */
-    enum TclDOM_EventTypes type;
-    Tcl_Obj *typeObjPtr;
-    Tcl_Obj *listenerPtr;
-    int capturer;
-{
-  TclDOM_libxml2_Document *domDocPtr;
-  Tcl_HashTable *tablePtr;
-  Tcl_HashEntry *entryPtr;
-  int new;
-
-  domDocPtr = GetDOMDocument(interp, tDocPtr);
-  if (domDocPtr == NULL) {
-    Tcl_SetResult(interp, "internal error", NULL);
-    return TCL_ERROR;
-  }
-
-  if (capturer) {
-    tablePtr = domDocPtr->captureListeners;
-  } else {
-    tablePtr = domDocPtr->bubbleListeners;
-  }
-
-  entryPtr = Tcl_CreateHashEntry(tablePtr, tokenPtr, &new);
-  if (new) {
-    tablePtr = (Tcl_HashTable *) Tcl_Alloc(sizeof(Tcl_HashTable));
-    Tcl_InitHashTable(tablePtr, TCL_STRING_KEYS);
-    Tcl_SetHashValue(entryPtr, (char *) tablePtr);
-  } else {
-    tablePtr = (Tcl_HashTable *) Tcl_GetHashValue(entryPtr);
-  }
-
-  if (type == TCLDOM_EVENT_USERDEFINED) {
-    entryPtr = Tcl_CreateHashEntry(tablePtr, Tcl_GetStringFromObj(typeObjPtr, NULL), &new);
-  } else {
-    entryPtr = Tcl_CreateHashEntry(tablePtr, TclDOM_EventTypes[type], &new);
-  }
-  if (new) {
-    Tcl_Obj *listPtr = Tcl_NewListObj(0, NULL);
-
-    Tcl_IncrRefCount(listenerPtr);
-    Tcl_IncrRefCount(listPtr);
-    Tcl_ListObjAppendElement(interp, listPtr, listenerPtr);
-    Tcl_SetHashValue(entryPtr, (char *) listPtr);
-
-  } else {
-    Tcl_Obj *listPtr = (Tcl_Obj *) Tcl_GetHashValue(entryPtr);
-    Tcl_Obj *curPtr;
-    int idx, len, listenerLen, len2, listlen;
-    char *listenerBuf, *buf2;
-
-    if (Tcl_ListObjLength(interp, listPtr, &len) != TCL_OK) {
-      Tcl_SetResult(interp, "internal error - bad list", NULL);
-      return TCL_ERROR;
-    }
-    listenerBuf = Tcl_GetStringFromObj(listenerPtr, &listenerLen);
-
-    new = 0;
-    for (idx = 0; idx < len; idx++) {
-      Tcl_ListObjIndex(interp, listPtr, idx, &curPtr);
-      buf2 = Tcl_GetStringFromObj(curPtr, &len2);
-
-      if (listenerLen == len2 && 
-          !strncmp(listenerBuf, buf2, listenerLen)) {
-        new = 1;
-        break;
-      }
-    }
-
-    if (Tcl_ListObjLength(interp, listPtr, &listlen) != TCL_OK) {
-      return TCL_ERROR;
-    }
-
-    Tcl_ListObjReplace(interp, listPtr, idx, new, 1, &listenerPtr);
-
-  }
-
-  /*
-   * Performance optimization:
-   * Keep track of which event types have listeners registered.
-   * If there are no listeners for an event type, then there's
-   * no point in dispatching that type of event.
-   * NB. This does not keep track of user-defined events types.
-   */
-
-  if (type != TCLDOM_EVENT_USERDEFINED) {
-    domDocPtr->listening[type]++;
-  } /* else this is a user-defined event type - it won't be tracked */
-
-  return TCL_OK;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclDOM_GetEventListener --
- *
- *  Find the listener registered for an event type.
- *
- * Results:
- *  Event listener returned.
- *
- * Side effects:
- *  None.
- *
- *----------------------------------------------------------------------------
- */
-
-Tcl_Obj *
-TclDOM_GetEventListener(interp,tDocPtr, tokenPtr, type, typeObjPtr, capturer)
-  Tcl_Interp *interp;
-  TclXML_libxml2_Document *tDocPtr;
-  void *tokenPtr;
-  enum TclDOM_EventTypes type;
-  Tcl_Obj *typeObjPtr;
-  int capturer;
-{
-  TclDOM_libxml2_Document *domDocPtr;
-  Tcl_HashTable *tablePtr;
-  Tcl_HashEntry *entryPtr;
-  
-  domDocPtr = GetDOMDocument(interp, tDocPtr);
-  if (domDocPtr == NULL) {
-    Tcl_SetResult(interp, "internal error", NULL);
-    return NULL;
-  }
-  
-  if (capturer) {
-    tablePtr = domDocPtr->captureListeners;
-  } else {
-    tablePtr = domDocPtr->bubbleListeners;
-  }
-  
-  entryPtr = Tcl_FindHashEntry(tablePtr, tokenPtr);
-  if (entryPtr) {
-    tablePtr = (Tcl_HashTable *) Tcl_GetHashValue(entryPtr);
-	
-    if (type == TCLDOM_EVENT_USERDEFINED) {
-      entryPtr = Tcl_FindHashEntry(tablePtr, Tcl_GetStringFromObj(typeObjPtr, NULL));
-    } else {
-      entryPtr = Tcl_FindHashEntry(tablePtr, TclDOM_EventTypes[type]);
-    }
-    if (entryPtr) {
-      return (Tcl_Obj *) Tcl_GetHashValue(entryPtr);
-	}
-  }
-
-  return Tcl_NewObj();
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclDOM_RemoveEventListener --
- *
- *  Deregister an event listener.
- *
- * Results:
- *  Success code.
- *
- * Side effects:
- *  May free Tcl objects.
- *
- *----------------------------------------------------------------------------
- */
-
-int
-TclDOM_RemoveEventListener(interp, tDocPtr, tokenPtr, type, typeObjPtr, listenerPtr, capturer)
-    Tcl_Interp *interp;
-    TclXML_libxml2_Document *tDocPtr;
-    void *tokenPtr;
-    enum TclDOM_EventTypes type;
-    Tcl_Obj *typeObjPtr;
-    Tcl_Obj *listenerPtr;
-    int capturer;
-{
-  TclDOM_libxml2_Document *domDocPtr;
-  Tcl_HashTable *tablePtr;
-  Tcl_HashEntry *entryPtr;
-
-  domDocPtr = GetDOMDocument(interp, tDocPtr);
-  if (domDocPtr == NULL) {
-    Tcl_SetResult(interp, "internal error", NULL);
-    return TCL_ERROR;
-  }
-
-  if (capturer) {
-    tablePtr = domDocPtr->captureListeners;
-  } else {
-    tablePtr = domDocPtr->bubbleListeners;
-  }
-
-  entryPtr = Tcl_FindHashEntry(tablePtr, tokenPtr);
-  if (entryPtr) {
-    tablePtr = (Tcl_HashTable *) Tcl_GetHashValue(entryPtr);
-
-    if (type == TCLDOM_EVENT_USERDEFINED) {
-      entryPtr = Tcl_FindHashEntry(tablePtr, Tcl_GetStringFromObj(typeObjPtr, NULL));
-    } else {
-      entryPtr = Tcl_FindHashEntry(tablePtr, TclDOM_EventTypes[type]);
-    }
-    if (entryPtr) {
-      Tcl_Obj *listPtr = (Tcl_Obj *) Tcl_GetHashValue(entryPtr);
-      Tcl_Obj *curPtr;
-      int idx, listenerLen, len, len2, found;
-      char *listenerBuf, *buf2;
-
-      if (Tcl_ListObjLength(interp, listPtr, &len) != TCL_OK) {
-        Tcl_SetResult(interp, "internal error - bad list", NULL);
-        return TCL_ERROR;
-      }
-      listenerBuf = Tcl_GetStringFromObj(listenerPtr, &listenerLen);
-	  found = 0;
-      for (idx = 0; idx < len; idx++) {
-        Tcl_ListObjIndex(interp, listPtr, idx, &curPtr);
-        buf2 = Tcl_GetStringFromObj(curPtr, &len2);
-        if (listenerLen == len2 && 
-            !strncmp(listenerBuf, buf2, listenerLen)) {
-          found = 1;
-		  break;
-        }
-      }
-
-      if (!found) {
-        Tcl_SetResult(interp, "listener not found", NULL);
-        return TCL_ERROR;
-      } else {
-        Tcl_ListObjReplace(interp, listPtr, idx, 1, 0, NULL);
-
-        /*
-         * Keep track of which event types have listeners registered.
-         */
-
-        if (type != TCLDOM_EVENT_USERDEFINED) {
-		  domDocPtr->listening[type]--;
-		} /* else user-defined event type - not being tracked */
-	  }
-	} else {
-	  Tcl_SetResult(interp, "no listeners registered", NULL);
-	  return TCL_ERROR;
-	}
-  } else {
-	Tcl_SetResult(interp, "no listeners registered", NULL);
-	return TCL_ERROR;
-  }
-
-  return TCL_OK;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * HasListener --
- *
- *  Check whether an event listener is registered for an event type.
- *
- * Results:
- *  Returns boolean.
- *
- * Side effects:
- *  None.
- *
- *----------------------------------------------------------------------------
- */
-
-int
-HasListener(interp, tDocPtr, eventType)
-     Tcl_Interp *interp;
-     TclXML_libxml2_Document *tDocPtr;
-     enum TclDOM_EventTypes eventType;
-{
-  TclDOM_libxml2_Document *domDocPtr = GetDOMDocument(interp, tDocPtr);
-
-  if (domDocPtr == NULL) {
-    return 0;
-  }
-
-  if (eventType == TCLDOM_EVENT_USERDEFINED) {
-	/*
-	 * We don't know whether there is a listener or not,
-	 * so play it safe.
-	 */
-    return 1;
-  }
-
-  if (domDocPtr->listening[eventType] > 0) {
-    return 1;
-  }
-
-  return 0;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclDOM_DispatchEvent --
- *
- *  Dispatch an event object.
- *
- * Results:
- *  Event propagates through the DOM tree.
- *
- * Side effects:
- *  Depends on event listeners.
- *
- *----------------------------------------------------------------------------
- */
-
-int
-TclDOM_DispatchEvent(interp, nodeObjPtr, eventObjPtr, eventPtr)
-    Tcl_Interp *interp;
-    Tcl_Obj *nodeObjPtr;
-    Tcl_Obj *eventObjPtr;
-    TclDOM_libxml2_Event *eventPtr;
-{
-  xmlNodePtr nodePtr;
-  xmlDocPtr docPtr;
-  TclXML_libxml2_Document *tDocPtr;
-  TclDOM_libxml2_Document *domDocPtr;
-  char *phase;
-  Tcl_Obj *docObjPtr, *pathPtr = NULL;
-  int idx, len, cancelable;
-  void *tokenPtr;
-
-  if (TclDOM_libxml2_GetNodeFromObj(interp, nodeObjPtr, &nodePtr) != TCL_OK) {
-    if (TclXML_libxml2_GetTclDocFromObj(interp, nodeObjPtr, &tDocPtr) != TCL_OK) {
-      Tcl_SetResult(interp, "unrecognised token", NULL);
-      return TCL_ERROR;
-    } else {
-      docObjPtr = nodeObjPtr;
-	  docPtr = tDocPtr->docPtr;
-      nodeObjPtr = NULL;
-      nodePtr = NULL;
-	  tokenPtr = (void *) docPtr;
-    }
-  } else {
-    docPtr = nodePtr->doc;
-    docObjPtr = TclXML_libxml2_CreateObjFromDoc(docPtr);
-    if (TclXML_libxml2_GetTclDocFromObj(interp, docObjPtr, &tDocPtr) != TCL_OK) {
-      Tcl_SetResult(interp, "unknown document", NULL);
-      return TCL_ERROR;
-    }
-	tokenPtr = (void *) nodePtr;
-  }
-  Tcl_ResetResult(interp);
-
-  /*
-   * Performance optimization:
-   * If there are no listeners registered for this event type,
-   * then there is no point in propagating the event.
-   */
-  if (!HasListener(interp, tDocPtr, eventPtr->type)) {
-    return TCL_OK;
-  }
-
-  domDocPtr = GetDOMDocument(interp, tDocPtr);
-  if (domDocPtr == NULL) {
-    Tcl_SetResult(interp, "internal error", NULL);
-    return TCL_ERROR;
-  }
-
-  phase = Tcl_GetStringFromObj(eventPtr->eventPhase, &len);
-
-  if (!len) {
-    /*
-     * This is the initial dispatch of the event.
-     * First trigger any capturing event listeners
-     * Starting from the root, proceed downward
-     */
-
-    Tcl_SetStringObj(eventPtr->eventPhase, "capturing_phase", -1);
-    eventPtr->target = nodeObjPtr;
-	Tcl_IncrRefCount(nodeObjPtr);
-
-    if (nodePtr) {
-      pathPtr = GetPath(interp, nodePtr);
-    } else {
-      pathPtr = Tcl_NewObj();
-    }
-	if (eventPtr->currentNode) {
-	  Tcl_DecrRefCount(eventPtr->currentNode);
-	}
-	eventPtr->currentNode = docObjPtr;
-	Tcl_IncrRefCount(docObjPtr);
-    if (TriggerEventListeners(interp, domDocPtr->captureListeners, (void *) docPtr, eventObjPtr, eventPtr) != TCL_OK) {
-      Tcl_DecrRefCount(pathPtr);
-      return TCL_ERROR;
-    }
-
-    if (Tcl_GetBooleanFromObj(interp, eventPtr->cancelable, &cancelable) != TCL_OK) {
-      Tcl_DecrRefCount(pathPtr);
-      return TCL_ERROR;
-    }
-    if (cancelable && eventPtr->stopPropagation) {
-      goto stop_propagation;
-    }
-
-    Tcl_ListObjLength(interp, pathPtr, &len);
-    Tcl_ListObjReplace(interp, pathPtr, len - 1, 1, 0, NULL);
-    Tcl_ListObjReplace(interp, pathPtr, 0, 1, 0, NULL);
-    Tcl_ListObjLength(interp, pathPtr, &len);
-    for (idx = 0; idx < len; idx++) {
-      Tcl_Obj *ancestorObjPtr;
-      xmlNodePtr ancestorPtr;
-
-      Tcl_ListObjIndex(interp, pathPtr, idx, &ancestorObjPtr);
-	  if (eventPtr->currentNode) {
-		Tcl_DecrRefCount(eventPtr->currentNode);
-	  }
-      eventPtr->currentNode = ancestorObjPtr;
-      Tcl_IncrRefCount(ancestorObjPtr);
-      if (TclDOM_libxml2_GetNodeFromObj(interp, ancestorObjPtr, &ancestorPtr) != TCL_OK) {
-        Tcl_SetResult(interp, "cannot find ancestor node \"", NULL);
-        Tcl_AppendResult(interp, Tcl_GetStringFromObj(ancestorObjPtr, NULL), "\"", NULL);
-        return TCL_ERROR;
-      }
-
-      if (TriggerEventListeners(interp, domDocPtr->captureListeners, (void *) ancestorPtr, eventObjPtr, eventPtr) != TCL_OK) {
-        return TCL_ERROR;
-      }
-
-      /*
-       * A listener may stop propagation,
-       * but we check here to let all of the
-       * listeners at that level complete.
-       */
-
-      if (Tcl_GetBooleanFromObj(interp, eventPtr->cancelable, &cancelable) != TCL_OK) {
-        Tcl_DecrRefCount(ancestorObjPtr);
-        return TCL_ERROR;
-      }
-      if (cancelable && eventPtr->stopPropagation) {
-        Tcl_DecrRefCount(ancestorObjPtr);
-        goto stop_propagation;
-      }
-
-      Tcl_DecrRefCount(ancestorObjPtr);
-
-    }
-
-    /* Prepare for the next phase */
-
-    if (Tcl_IsShared(eventPtr->eventPhase)) {
-      Tcl_DecrRefCount(eventPtr->eventPhase);
-      eventPtr->eventPhase = Tcl_NewStringObj("at_target", -1);
-      Tcl_IncrRefCount(eventPtr->eventPhase);
-    } else {
-      Tcl_SetStringObj(eventPtr->eventPhase, "at_target", -1);
-    }
-  }
-
-  if (eventPtr->currentNode) {
-	Tcl_DecrRefCount(eventPtr->currentNode);
-  }
-  if (nodePtr) {
-    eventPtr->currentNode = nodeObjPtr;
-    tokenPtr = (void *) nodePtr;
-  } else {
-    eventPtr->currentNode = docObjPtr;
-    tokenPtr = (void *) docPtr;
-  }
-  Tcl_IncrRefCount(eventPtr->currentNode);
-
-  if (TriggerEventListeners(interp, domDocPtr->bubbleListeners, tokenPtr, eventObjPtr, eventPtr) != TCL_OK) {
-    return TCL_ERROR;
-  }
-
-  if (Tcl_IsShared(eventPtr->eventPhase)) {
-    Tcl_DecrRefCount(eventPtr->eventPhase);
-    eventPtr->eventPhase = Tcl_NewStringObj("bubbling_phase", -1);
-    Tcl_IncrRefCount(eventPtr->eventPhase);
-  } else {
-    Tcl_SetStringObj(eventPtr->eventPhase, "bubbling_phase", -1);
-  }
-
-  if (Tcl_GetBooleanFromObj(interp, eventPtr->cancelable, &cancelable) != TCL_OK) {
-    return TCL_ERROR;
-  }
-  if (cancelable && eventPtr->stopPropagation) {
-    /* Do no more */
-  } else if (nodePtr && nodePtr->parent && nodePtr->parent != (xmlNodePtr) nodePtr->doc) {
-	Tcl_Obj *objPtr;
-
-	objPtr = TclDOM_libxml2_CreateObjFromNode(interp, nodePtr->parent);
-	if (objPtr == NULL) {
-	  return TCL_ERROR;
-	}
-    return TclDOM_DispatchEvent(interp, 
-				objPtr, 
-				eventObjPtr, eventPtr);
-  } else if (nodePtr && nodePtr->parent) {
-	Tcl_Obj *objPtr;
-
-	objPtr = TclXML_libxml2_CreateObjFromDoc(nodePtr->doc);
-	if (objPtr == NULL) {
-	  return TCL_ERROR;
-	}
-    return TclDOM_DispatchEvent(interp, 
-				objPtr, 
-				eventObjPtr, eventPtr);
-  }
-
-stop_propagation:
-  eventPtr->dispatched = 1;
-
-  if (pathPtr) {
-    Tcl_DecrRefCount(pathPtr);
-  }
-
-  return TCL_OK;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclDOMElementCommand --
- *
- *  Implements dom::libxml2::element command.
- *
- * Results:
- *  Depends on method.
- *
- * Side effects:
- *  Depends on method.
- *
- *----------------------------------------------------------------------------
- */
-
-int
-TclDOMElementCommand (clientData, interp, objc, objv)
-     ClientData clientData;
-     Tcl_Interp *interp;
-     int objc;
-     Tcl_Obj *CONST objv[];
-{
-  int method, optobjc;
-  Tcl_Obj *CONST *optobjv;
-  xmlNodePtr nodePtr;
-  TclXML_libxml2_Document *tDocPtr;
-  char *value;
-  xmlAttrPtr attrPtr;
-  xmlNsPtr nsPtr;
-
-  if (clientData == NULL) {
-    if (objc < 3) {
-      Tcl_WrongNumArgs(interp, 1, objv, "method ?args...?");
-      return TCL_ERROR;
-    }
-
-    if (TclDOM_libxml2_GetNodeFromObj(interp, objv[2], &nodePtr) != TCL_OK) {
-      return TCL_ERROR;
-    }
-
-    optobjv = objv + 3;
-    optobjc = objc - 3;
-
-  } else {
-
-    nodePtr = (xmlNodePtr) clientData;
-
-    optobjv = objv + 2;
-    optobjc = objc - 2;
-  }
-
-  if (Tcl_GetIndexFromObj(interp, objv[1], TclDOM_ElementCommandMethods,
-			  "method", 0, &method) != TCL_OK) {
-    return TCL_ERROR;
-  }
-
-  /* Should check that the node is of element type */
-
-  Tcl_ResetResult(interp);
-
-  switch ((enum TclDOM_ElementCommandMethods) method) {
-
-  case TCLDOM_ELEMENT_CGET:
-    if (optobjc != 1) {
-      Tcl_WrongNumArgs(interp, 1, objv, "option");
-      return TCL_ERROR;
-    }
-
-    return ElementCget(interp, nodePtr, optobjv[0]);
-
-    break;
-
-  case TCLDOM_ELEMENT_CONFIGURE:
-
-    if (optobjc == 1) {
-      return ElementCget(interp, nodePtr, optobjv[0]);
-    } else {
-      Tcl_AppendResult(interp, "option \"", Tcl_GetStringFromObj(optobjv[0], NULL), "\" cannot be modified", NULL);
-      return TCL_ERROR;
-    }
-
-    break;
-
-  case TCLDOM_ELEMENT_GETATTRIBUTE:
-    if (optobjc != 1) {
-      Tcl_WrongNumArgs(interp, 1, objv, "attr");
-      return TCL_ERROR;
-    }
-
-    Tcl_MutexLock(&libxml2);
-    value = (char *) xmlGetProp(nodePtr, (const xmlChar *) Tcl_GetStringFromObj(optobjv[0], NULL));
-    Tcl_MutexUnlock(&libxml2);
-
-    if (value) {
-      Tcl_SetObjResult(interp, Tcl_NewStringObj(value, -1));
-    }
-
-    break;
-
-  case TCLDOM_ELEMENT_GETATTRIBUTENS:
-    if (optobjc != 2) {
-      Tcl_WrongNumArgs(interp, 1, objv, "ns attr");
-      return TCL_ERROR;
-    }
-
-    Tcl_MutexLock(&libxml2);
-    value = (char *) xmlGetNsProp(nodePtr,
-			 (const xmlChar *) Tcl_GetStringFromObj(optobjv[1], NULL),
-			 (const xmlChar *) Tcl_GetStringFromObj(optobjv[0], NULL));
-    Tcl_MutexUnlock(&libxml2);
-
-    if (value) {
-      Tcl_SetObjResult(interp, Tcl_NewStringObj(value, -1));
-    }
-
-    break;
-
-  case TCLDOM_ELEMENT_SETATTRIBUTE:
-    if (optobjc != 2) {
-      Tcl_WrongNumArgs(interp, 1, objv, "attr value");
-      return TCL_ERROR;
-    }
-
-    if (TclXML_libxml2_GetTclDocFromNode(interp, nodePtr, &tDocPtr) != TCL_OK) {
-      return TCL_ERROR;
-    }
-
-    Tcl_MutexLock(&libxml2);
-    value = (char *) xmlGetProp(nodePtr, (const xmlChar *) Tcl_GetStringFromObj(optobjv[0], NULL));
-    attrPtr = xmlSetProp(nodePtr,
-			 (const xmlChar *) Tcl_GetStringFromObj(optobjv[0], NULL),
-			 (const xmlChar *) Tcl_GetStringFromObj(optobjv[1], NULL));
-    Tcl_MutexUnlock(&libxml2);
-
-    if (!attrPtr) {
-      Tcl_SetResult(interp, "unable to set attribute", NULL);
-      return TCL_ERROR;
-    }
-
-    TclDOM_PostMutationEvent(interp, tDocPtr, objv[2], TCLDOM_EVENT_DOMATTRMODIFIED, NULL, Tcl_NewIntObj(1), Tcl_NewIntObj(0), NULL, Tcl_NewStringObj(value, -1), optobjv[1], optobjv[0], value == NULL? Tcl_NewStringObj("modification", -1) : Tcl_NewStringObj("addition", -1));
-
-    Tcl_SetObjResult(interp, optobjv[1]);
-
-    break;
-
-  case TCLDOM_ELEMENT_SETATTRIBUTENS:
-    if (optobjc != 3) {
-      Tcl_WrongNumArgs(interp, 1, objv, "ns attr value");
-      return TCL_ERROR;
-    }
-
-    if (TclXML_libxml2_GetTclDocFromNode(interp, nodePtr, &tDocPtr) != TCL_OK) {
-      return TCL_ERROR;
-    }
-
-    Tcl_MutexLock(&libxml2);
-
-    nsPtr = xmlSearchNsByHref(nodePtr->doc, nodePtr, (const xmlChar *) Tcl_GetStringFromObj(optobjv[0], NULL));
-    if (!nsPtr) {
-      Tcl_SetResult(interp, "no XML Namespace declaration for namespace", NULL);
-      Tcl_MutexUnlock(&libxml2);
-      return TCL_ERROR;
-    }
-
-    value = (char *) xmlGetNsProp(nodePtr,
-			 (const xmlChar *) Tcl_GetStringFromObj(optobjv[1], NULL),
-			 (const xmlChar *) Tcl_GetStringFromObj(optobjv[2], NULL));
-    attrPtr = xmlSetNsProp(nodePtr,
-			   nsPtr,
-			   (const xmlChar *) Tcl_GetStringFromObj(optobjv[1], NULL),
-			   (const xmlChar *) Tcl_GetStringFromObj(optobjv[3], NULL));
-
-    Tcl_MutexUnlock(&libxml2);
-
-    if (!attrPtr) {
-      Tcl_SetResult(interp, "unable to set attribute", NULL);
-      return TCL_ERROR;
-    }
-
-    TclDOM_PostMutationEvent(interp, tDocPtr, objv[2], TCLDOM_EVENT_DOMATTRMODIFIED, NULL, Tcl_NewIntObj(1), Tcl_NewIntObj(0), NULL, Tcl_NewStringObj(value, -1), optobjv[3], optobjv[2], value == NULL? Tcl_NewStringObj("modification", -1) : Tcl_NewStringObj("addition", -1));
-
-    break;
-
-  case TCLDOM_ELEMENT_REMOVEATTRIBUTE:
-
-    if (optobjc != 1) {
-      Tcl_WrongNumArgs(interp, 1, objv, "attr");
-      return TCL_ERROR;
-    }
-
-    if (TclXML_libxml2_GetTclDocFromNode(interp, nodePtr, &tDocPtr) != TCL_OK) {
-      return TCL_ERROR;
-    }
-
-    /* It doesn't matter if this fails due to a non-existant attribute */
-    Tcl_MutexLock(&libxml2);
-    xmlUnsetProp(nodePtr, (const xmlChar *) Tcl_GetStringFromObj(optobjv[0], NULL));
-    Tcl_MutexUnlock(&libxml2);
-
-    TclDOM_PostMutationEvent(interp, tDocPtr, objv[2], TCLDOM_EVENT_DOMATTRMODIFIED, NULL, Tcl_NewIntObj(1), Tcl_NewIntObj(0), NULL, NULL, NULL, optobjv[2], Tcl_NewStringObj("removed", -1));
-
-    break;
-
-  default:
-    Tcl_SetResult(interp, "method \"", NULL);
-    Tcl_AppendResult(interp, Tcl_GetStringFromObj(objv[1], NULL), "\" not yet implemented", NULL);
-    return TCL_ERROR;
-  }
-
-  return TCL_OK;
-}
-
-int
-ElementCget(interp, nodePtr, optObj)
-     Tcl_Interp *interp;
-     xmlNodePtr nodePtr;
-     Tcl_Obj *CONST optObj;
-{
-  int option;
-
-  if (Tcl_GetIndexFromObj(interp, optObj, TclDOM_ElementCommandOptions,
-			  "option", 0, &option) != TCL_OK) {
-    return TCL_ERROR;
-  }
-
-  switch ((enum TclDOM_ElementCommandOptions) option) {
-  case TCLDOM_ELEMENT_TAGNAME:
-    Tcl_SetObjResult(interp, Tcl_NewStringObj((CONST char *) nodePtr->name, -1));
-    break;
-
-  case TCLDOM_ELEMENT_EMPTY:
-    Tcl_SetObjResult(interp, Tcl_NewBooleanObj(0));
-    break;
-
-  default:
-    Tcl_SetResult(interp, "unknown option", NULL);
-    return TCL_ERROR;
-  }
-
-  return TCL_OK;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclDOM_InitEvent --
- *
- *  Initializes an event object.
- *
- * Results:
- *  Tcl_Obj references stored.
- *
- * Side effects:
- *  Tcl_Obj's reference count changed.
- *
- *----------------------------------------------------------------------------
- */
-
-void
-TclDOM_InitEvent(eventPtr, type, typeObjPtr, bubblesPtr, cancelablePtr)
-    TclDOM_libxml2_Event *eventPtr;
-    enum TclDOM_EventTypes type;
-    Tcl_Obj *typeObjPtr;
-    Tcl_Obj *bubblesPtr;
-    Tcl_Obj *cancelablePtr;
-{
-  if (type != TCLDOM_EVENT_USERDEFINED) {
-    if (eventPtr->type != type) {
-      if (eventPtr->typeObjPtr) {
-	Tcl_DecrRefCount(eventPtr->typeObjPtr);
-	eventPtr->typeObjPtr = NULL;
-      }
-      eventPtr->type = type;
-    }
-  } else {
-    char *oldType, *newType;
-    int oldLen, newLen;
-
-    oldType = Tcl_GetStringFromObj(eventPtr->typeObjPtr, &oldLen);
-    newType = Tcl_GetStringFromObj(typeObjPtr, &newLen);
-    if (oldLen != newLen ||
-	strncmp(oldType, newType, oldLen)) {
-      Tcl_DecrRefCount(eventPtr->typeObjPtr);
-      eventPtr->typeObjPtr = typeObjPtr;
-      Tcl_IncrRefCount(typeObjPtr);
-      eventPtr->type = TCLDOM_EVENT_USERDEFINED;
-    }
-  }
-
-  if (bubblesPtr && eventPtr->bubbles != bubblesPtr) {
-    Tcl_DecrRefCount(eventPtr->bubbles);
-    eventPtr->bubbles = bubblesPtr;
-    Tcl_IncrRefCount(eventPtr->bubbles);
-  }
-  if (cancelablePtr && eventPtr->cancelable != cancelablePtr) {
-    Tcl_DecrRefCount(eventPtr->cancelable);
-    eventPtr->cancelable = cancelablePtr;
-    Tcl_IncrRefCount(eventPtr->cancelable);
-  }
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclDOM_InitUIEvent --
- *
- *  Initializes an event object.
- *
- * Results:
- *  Tcl_Obj references stored.
- *
- * Side effects:
- *  Tcl_Obj's reference count changed.
- *
- *----------------------------------------------------------------------------
- */
-
-void
-TclDOM_InitUIEvent(eventPtr, type, typeObjPtr, bubblesPtr, cancelablePtr, viewPtr, detailPtr)
-    TclDOM_libxml2_Event *eventPtr;
-    enum TclDOM_EventTypes type;
-    Tcl_Obj *typeObjPtr;
-    Tcl_Obj *bubblesPtr;
-    Tcl_Obj *cancelablePtr;
-    Tcl_Obj *viewPtr;
-    Tcl_Obj *detailPtr;
-{
-  TclDOM_InitEvent(eventPtr, type, typeObjPtr, bubblesPtr, cancelablePtr);
-
-  if (viewPtr && eventPtr->view != viewPtr) {
-    Tcl_DecrRefCount(eventPtr->view);
-    eventPtr->view = viewPtr;
-    Tcl_IncrRefCount(eventPtr->view);
-  }
-  if (detailPtr && eventPtr->detail != detailPtr) {
-    Tcl_DecrRefCount(eventPtr->detail);
-    eventPtr->detail = detailPtr;
-    Tcl_IncrRefCount(eventPtr->detail);
-  } else if (detailPtr == NULL) {
-    Tcl_DecrRefCount(eventPtr->detail);
-    eventPtr->detail = Tcl_NewObj();
-  }
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclDOM_InitMouseEvent --
- *
- *  Initializes an event object.
- *
- * Results:
- *  Tcl_Obj references stored.
- *
- * Side effects:
- *  Tcl_Obj's reference count changed.
- *
- *----------------------------------------------------------------------------
- */
-
-void
-TclDOM_InitMouseEvent(eventPtr, type, typeObjPtr, bubblesPtr, cancelablePtr, viewPtr, detailPtr, screenXPtr, screenYPtr, clientXPtr, clientYPtr, ctrlKeyPtr, altKeyPtr, shiftKeyPtr, metaKeyPtr, buttonPtr, relatedNodePtr)
-    TclDOM_libxml2_Event *eventPtr;
-    enum TclDOM_EventTypes type;
-    Tcl_Obj *typeObjPtr;
-    Tcl_Obj *bubblesPtr;
-    Tcl_Obj *cancelablePtr;
-    Tcl_Obj *viewPtr;
-    Tcl_Obj *detailPtr;
-    Tcl_Obj *screenXPtr;
-    Tcl_Obj *screenYPtr;
-    Tcl_Obj *clientXPtr;
-    Tcl_Obj *clientYPtr;
-    Tcl_Obj *ctrlKeyPtr;
-    Tcl_Obj *altKeyPtr;
-    Tcl_Obj *shiftKeyPtr;
-	Tcl_Obj *metaKeyPtr;
-	Tcl_Obj *buttonPtr;
-    Tcl_Obj *relatedNodePtr;
-{
-  TclDOM_InitUIEvent(eventPtr, type, typeObjPtr, bubblesPtr, cancelablePtr, viewPtr, detailPtr);
-
-  if (screenXPtr && eventPtr->screenX != screenXPtr) {
-    Tcl_DecrRefCount(eventPtr->screenX);
-    eventPtr->screenX = screenXPtr;
-    Tcl_IncrRefCount(eventPtr->screenX);
-  }
-  if (screenYPtr && eventPtr->screenY != screenYPtr) {
-    Tcl_DecrRefCount(eventPtr->screenY);
-    eventPtr->screenY = screenYPtr;
-    Tcl_IncrRefCount(eventPtr->screenY);
-  }
-
-  if (clientXPtr && eventPtr->clientX != clientXPtr) {
-    Tcl_DecrRefCount(eventPtr->clientX);
-    eventPtr->clientX = clientXPtr;
-    Tcl_IncrRefCount(eventPtr->clientX);
-  }
-  if (clientYPtr && eventPtr->clientY != clientYPtr) {
-    Tcl_DecrRefCount(eventPtr->clientY);
-    eventPtr->clientY = clientYPtr;
-    Tcl_IncrRefCount(eventPtr->clientY);
-  }
-
-  if (ctrlKeyPtr && eventPtr->ctrlKey != ctrlKeyPtr) {
-    Tcl_DecrRefCount(eventPtr->ctrlKey);
-    eventPtr->ctrlKey = ctrlKeyPtr;
-    Tcl_IncrRefCount(eventPtr->ctrlKey);
-  }
-  if (altKeyPtr && eventPtr->altKey != altKeyPtr) {
-    Tcl_DecrRefCount(eventPtr->altKey);
-    eventPtr->altKey = altKeyPtr;
-    Tcl_IncrRefCount(eventPtr->altKey);
-  }
-  if (shiftKeyPtr && eventPtr->shiftKey != shiftKeyPtr) {
-    Tcl_DecrRefCount(eventPtr->shiftKey);
-    eventPtr->shiftKey = shiftKeyPtr;
-    Tcl_IncrRefCount(eventPtr->shiftKey);
-  }
-  if (metaKeyPtr && eventPtr->metaKey != metaKeyPtr) {
-    Tcl_DecrRefCount(eventPtr->metaKey);
-    eventPtr->metaKey = metaKeyPtr;
-    Tcl_IncrRefCount(eventPtr->metaKey);
-  }
-  if (buttonPtr && eventPtr->button != buttonPtr) {
-    Tcl_DecrRefCount(eventPtr->button);
-    eventPtr->button = buttonPtr;
-    Tcl_IncrRefCount(eventPtr->button);
-  }
-  
-  if (relatedNodePtr && eventPtr->relatedNode != relatedNodePtr) {
-    Tcl_DecrRefCount(eventPtr->relatedNode);
-    eventPtr->relatedNode = relatedNodePtr;
-    Tcl_IncrRefCount(eventPtr->relatedNode);
-  }
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclDOM_InitMutationEvent --
- *
- *  Initializes an event object.
- *
- * Results:
- *  Tcl_Obj references stored.
- *
- * Side effects:
- *  Tcl_Obj's reference count changed.
- *
- *----------------------------------------------------------------------------
- */
-
-void
-TclDOM_InitMutationEvent(eventPtr, type, typeObjPtr, bubblesPtr, cancelablePtr, relatedNodePtr, prevValuePtr, newValuePtr, attrNamePtr, attrChangePtr)
-    TclDOM_libxml2_Event *eventPtr;
-    enum TclDOM_EventTypes type;
-    Tcl_Obj *typeObjPtr;
-    Tcl_Obj *bubblesPtr;
-    Tcl_Obj *cancelablePtr;
-    Tcl_Obj *relatedNodePtr;
-    Tcl_Obj *prevValuePtr;
-    Tcl_Obj *newValuePtr;
-    Tcl_Obj *attrNamePtr;
-    Tcl_Obj *attrChangePtr;
-{
-  TclDOM_InitEvent(eventPtr, type, typeObjPtr, bubblesPtr, cancelablePtr);
-
-  if (relatedNodePtr && eventPtr->relatedNode != relatedNodePtr) {
-    Tcl_DecrRefCount(eventPtr->relatedNode);
-    eventPtr->relatedNode = relatedNodePtr;
-    Tcl_IncrRefCount(eventPtr->relatedNode);
-  }
-
-  if (prevValuePtr && eventPtr->prevValue != prevValuePtr) {
-    Tcl_DecrRefCount(eventPtr->prevValue);
-    eventPtr->prevValue = prevValuePtr;
-    Tcl_IncrRefCount(eventPtr->prevValue);
-  }
-  if (newValuePtr && eventPtr->newValue != newValuePtr) {
-    Tcl_DecrRefCount(eventPtr->newValue);
-    eventPtr->newValue = newValuePtr;
-    Tcl_IncrRefCount(eventPtr->newValue);
-  }
-  if (attrNamePtr && eventPtr->attrName != attrNamePtr) {
-    Tcl_DecrRefCount(eventPtr->attrName);
-    eventPtr->attrName = attrNamePtr;
-    Tcl_IncrRefCount(eventPtr->attrName);
-  }
-  if (attrChangePtr && eventPtr->attrChange != attrChangePtr) {
-    Tcl_DecrRefCount(eventPtr->attrChange);
-    eventPtr->attrChange = attrChangePtr;
-    Tcl_IncrRefCount(eventPtr->attrChange);
-  }
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclDOM_PostUIEvent --
- *
- *  Post an event and cleanup afterward.
- *
- * Results:
- *  Event created and propagated.
- *
- * Side effects:
- *  Depends on event listeners.
- *
- *----------------------------------------------------------------------------
- */
-
-int
-TclDOM_PostUIEvent(interp, tDocPtr, nodeObjPtr, type, typeObjPtr, bubblesPtr, cancelablePtr, viewPtr, detailPtr)
-     Tcl_Interp *interp;
-     TclXML_libxml2_Document *tDocPtr;
-     Tcl_Obj *nodeObjPtr;
-     enum TclDOM_EventTypes type;
-     Tcl_Obj *typeObjPtr;
-     Tcl_Obj *bubblesPtr;
-     Tcl_Obj *cancelablePtr;
-     Tcl_Obj *viewPtr;
-     Tcl_Obj *detailPtr;
-{
-  Tcl_Obj *eventObj;
-  TclDOM_libxml2_Event *eventPtr = NULL;
-  int result;
-
-  /*
-   * Performance optimisation: if there are no event listeners for this
-   * event type then don't bother creating an event.
-   */
-  if (!HasListener(interp, tDocPtr, type)) {
-    return TCL_OK;
-  }
-
-  eventObj = TclDOM_libxml2_NewEventObj(interp, tDocPtr->docPtr, type, typeObjPtr);
-  if (eventObj == NULL) {
-    Tcl_SetResult(interp, "unable to create event", NULL);
-    return TCL_ERROR;
-  }
-
-  TclDOM_libxml2_GetEventFromObj(interp, eventObj, &eventPtr);
-
-  TclDOM_InitUIEvent(eventPtr, type, typeObjPtr, bubblesPtr, cancelablePtr, viewPtr, detailPtr);
-
-  Tcl_ResetResult(interp);
-  result = TclDOM_DispatchEvent(interp, nodeObjPtr, eventObj, eventPtr);
-
-  TclDOM_libxml2_DestroyNode(interp, eventPtr->tNodePtr);
-
-  return result;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclDOM_PostMouseEvent --
- *
- *  Post an event and cleanup afterward.
- *
- * Results:
- *  Event created and propagated.
- *
- * Side effects:
- *  Depends on event listeners.
- *
- *----------------------------------------------------------------------------
- */
-
-int
-TclDOM_PostMouseEvent(interp, tDocPtr, nodeObjPtr, type, typeObjPtr, bubblesPtr, cancelablePtr, relatedNodePtr, viewPtr, detailPtr, screenXPtr, screenYPtr, clientXPtr, clientYPtr, ctrlKeyPtr, altKeyPtr, shiftKeyPtr, metaKeyPtr, buttonPtr)
-     Tcl_Interp *interp;
-     TclXML_libxml2_Document *tDocPtr;
-     Tcl_Obj *nodeObjPtr;
-     enum TclDOM_EventTypes type;
-     Tcl_Obj *typeObjPtr;
-     Tcl_Obj *bubblesPtr;
-     Tcl_Obj *cancelablePtr;
-     Tcl_Obj *relatedNodePtr;
-     Tcl_Obj *viewPtr;
-     Tcl_Obj *detailPtr;
-     Tcl_Obj *screenXPtr;
-     Tcl_Obj *screenYPtr;
-     Tcl_Obj *clientXPtr;
-     Tcl_Obj *clientYPtr;
-     Tcl_Obj *ctrlKeyPtr;
-     Tcl_Obj *altKeyPtr;
-     Tcl_Obj *shiftKeyPtr;
-     Tcl_Obj *metaKeyPtr;
-     Tcl_Obj *buttonPtr;
-{
-  Tcl_Obj *eventObj;
-  TclDOM_libxml2_Event *eventPtr = NULL;
-  int result;
-
-  /*
-   * Performance optimisation: if there are no event listeners for this
-   * event type then don't bother creating an event.
-   */
-  if (!HasListener(interp, tDocPtr, type)) {
-    return TCL_OK;
-  }
-
-  eventObj = TclDOM_libxml2_NewEventObj(interp, tDocPtr->docPtr, type, typeObjPtr);
-  if (eventObj == NULL) {
-    Tcl_SetResult(interp, "unable to create event", NULL);
-    return TCL_ERROR;
-  }
-
-  TclDOM_libxml2_GetEventFromObj(interp, eventObj, &eventPtr);
-
-  TclDOM_InitMouseEvent(eventPtr, type, typeObjPtr, bubblesPtr, cancelablePtr, 
-						viewPtr, detailPtr, 
-						screenXPtr, screenYPtr, clientXPtr, clientYPtr, 
-						ctrlKeyPtr, altKeyPtr, shiftKeyPtr, metaKeyPtr, 
-						buttonPtr, relatedNodePtr);
-
-  Tcl_ResetResult(interp);
-  result = TclDOM_DispatchEvent(interp, nodeObjPtr, eventObj, eventPtr);
-
-  TclDOM_libxml2_DestroyNode(interp, eventPtr->tNodePtr);
-
-  return result;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclDOM_PostMutationEvent --
- *
- *  Post an event and cleanup afterward.
- *
- * Results:
- *  Event created and propagated.
- *
- * Side effects:
- *  Depends on event listeners.
- *
- *----------------------------------------------------------------------------
- */
-
-int
-TclDOM_PostMutationEvent(interp, tDocPtr, nodeObjPtr, type, typeObjPtr, bubblesPtr, cancelablePtr, relatedNodePtr, prevValuePtr, newValuePtr, attrNamePtr, attrChangePtr)
-     Tcl_Interp *interp;
-     TclXML_libxml2_Document *tDocPtr;
-     Tcl_Obj *nodeObjPtr;
-     enum TclDOM_EventTypes type;
-     Tcl_Obj *typeObjPtr;
-     Tcl_Obj *bubblesPtr;
-     Tcl_Obj *cancelablePtr;
-     Tcl_Obj *relatedNodePtr;
-     Tcl_Obj *prevValuePtr;
-     Tcl_Obj *newValuePtr;
-     Tcl_Obj *attrNamePtr;
-     Tcl_Obj *attrChangePtr;
-{
-  Tcl_Obj *eventObj;
-  TclDOM_libxml2_Event *eventPtr = NULL;
-  int result;
-
-  /*
-   * Performance optimisation: if there are no event listeners for this
-   * event type then don't bother creating an event.
-   */
-  if (!HasListener(interp, tDocPtr, type)) {
-    return TCL_OK;
-  }
-
-  eventObj = TclDOM_libxml2_NewEventObj(interp, tDocPtr->docPtr, type, typeObjPtr);
-  if (eventObj == NULL) {
-    Tcl_SetResult(interp, "unable to create event", NULL);
-    return TCL_ERROR;
-  }
-
-  TclDOM_libxml2_GetEventFromObj(interp, eventObj, &eventPtr);
-
-  TclDOM_InitMutationEvent(eventPtr, type, typeObjPtr, bubblesPtr, cancelablePtr, relatedNodePtr, prevValuePtr, newValuePtr, attrNamePtr, attrChangePtr);
-
-  Tcl_ResetResult(interp);
-  result = TclDOM_DispatchEvent(interp, nodeObjPtr, eventObj, eventPtr);
-
-  TclDOM_libxml2_DestroyNode(interp, eventPtr->tNodePtr);
-
-  return result;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclDOMEventCommand --
- *
- *  Implements dom::libxml2::event command.
- *
- * Results:
- *  Depends on method.
- *
- * Side effects:
- *  Depends on method.
- *
- *----------------------------------------------------------------------------
- */
-
-int
-TclDOMEventCommand (clientData, interp, objc, objv)
-     ClientData clientData;
-     Tcl_Interp *interp;
-     int objc;
-     Tcl_Obj *CONST objv[];
-{
-  int method, option;
-  TclXML_libxml2_Document *tDocPtr;
-  TclDOM_libxml2_Node *tNodePtr;
-  TclDOM_libxml2_Event *eventPtr;
-  xmlNodePtr nodePtr;
-  enum TclDOM_EventTypes type;
-  Tcl_Obj *typeObjPtr = NULL;
-  Tcl_Obj *nodeObj;
-  Tcl_Obj *bubblesPtr, *cancelablePtr, *viewPtr, *detailPtr;
-  Tcl_Obj *relatedNodePtr, *screenXPtr, *screenYPtr, *clientXPtr, *clientYPtr;
-  Tcl_Obj *ctrlKeyPtr, *shiftKeyPtr, *metaKeyPtr, *buttonPtr;
-  Tcl_Obj *prevValuePtr, *newValuePtr, *attrNamePtr, *attrChangePtr;
-
-  if (objc < 2) {
-	if (clientData == NULL) {
-	  Tcl_WrongNumArgs(interp, 1, objv, "method token ?args...?");
-	} else {
-	  Tcl_WrongNumArgs(interp, 1, objv, "method ?args...?");
-	}
-	return TCL_ERROR;
-  }
-
-  if (Tcl_GetIndexFromObj(interp, objv[1], TclDOM_EventCommandMethods,
-			  "method", 0, &method) != TCL_OK) {
-    return TCL_ERROR;
-  }
-
-  switch ((enum TclDOM_EventCommandMethods) method) {
-
-  case TCLDOM_EVENT_CGET:
-
-    if (clientData) {
-	  if (objc != 3) {
-		Tcl_WrongNumArgs(interp, 1, objv, "cget option");
-		return TCL_ERROR;
-	  }
-      tNodePtr = (TclDOM_libxml2_Node *) clientData;
-	  if (tNodePtr->type != TCLDOM_LIBXML2_NODE_EVENT) {
-		Tcl_SetResult(interp, "bad event node", NULL);
-		return TCL_ERROR;
-	  }
-      eventPtr = tNodePtr->ptr.eventPtr;
-	  objc -= 2;
-	  objv += 2;
-    } else {
-	  if (objc != 4) {
-		Tcl_WrongNumArgs(interp, 3, objv, "cget event option");
-		return TCL_ERROR;
-	  }
-      if (TclDOM_libxml2_GetEventFromObj(interp, objv[2], &eventPtr) != TCL_OK) {
-		return TCL_ERROR;
-      }
-	  objc -= 3;
-	  objv += 3;
-    }
-
-    if (Tcl_GetIndexFromObj(interp, objv[0], TclDOM_EventCommandOptions,
-							"option", 0, &option) != TCL_OK) {
-      return TCL_ERROR;
-    }
-	
-    switch ((enum TclDOM_EventCommandOptions) option) {
-    case TCLDOM_EVENT_ALTKEY:
-      Tcl_SetObjResult(interp, eventPtr->altKey);
-      break;
-    case TCLDOM_EVENT_ATTRNAME:
-      Tcl_SetObjResult(interp, eventPtr->attrName);
-      break;
-    case TCLDOM_EVENT_ATTRCHANGE:
-      Tcl_SetObjResult(interp, eventPtr->attrChange);
-      break;
-    case TCLDOM_EVENT_BUBBLES:
-      Tcl_SetObjResult(interp, eventPtr->bubbles);
-      break;
-    case TCLDOM_EVENT_BUTTON:
-      Tcl_SetObjResult(interp, eventPtr->button);
-      break;
-    case TCLDOM_EVENT_CANCELABLE:
-      Tcl_SetObjResult(interp, eventPtr->cancelable);
-      break;
-    case TCLDOM_EVENT_CLIENTX:
-      Tcl_SetObjResult(interp, eventPtr->clientX);
-      break;
-    case TCLDOM_EVENT_CLIENTY:
-      Tcl_SetObjResult(interp, eventPtr->clientY);
-      break;
-    case TCLDOM_EVENT_CTRLKEY:
-      Tcl_SetObjResult(interp, eventPtr->ctrlKey);
-      break;
-    case TCLDOM_EVENT_CURRENTNODE:
-      Tcl_SetObjResult(interp, eventPtr->currentNode);
-      break;
-    case TCLDOM_EVENT_DETAIL:
-      Tcl_SetObjResult(interp, eventPtr->detail);
-      break;
-    case TCLDOM_EVENT_EVENTPHASE:
-      Tcl_SetObjResult(interp, eventPtr->eventPhase);
-      break;
-    case TCLDOM_EVENT_METAKEY:
-      Tcl_SetObjResult(interp, eventPtr->metaKey);
-      break;
-    case TCLDOM_EVENT_NEWVALUE:
-      Tcl_SetObjResult(interp, eventPtr->newValue);
-      break;
-    case TCLDOM_EVENT_PREVVALUE:
-      Tcl_SetObjResult(interp, eventPtr->prevValue);
-      break;
-    case TCLDOM_EVENT_RELATEDNODE:
-      Tcl_SetObjResult(interp, eventPtr->relatedNode);
-      break;
-    case TCLDOM_EVENT_SCREENX:
-      Tcl_SetObjResult(interp, eventPtr->screenX);
-      break;
-    case TCLDOM_EVENT_SCREENY:
-      Tcl_SetObjResult(interp, eventPtr->screenY);
-      break;
-    case TCLDOM_EVENT_SHIFTKEY:
-      Tcl_SetObjResult(interp, eventPtr->shiftKey);
-      break;
-    case TCLDOM_EVENT_TARGET:
-      Tcl_SetObjResult(interp, eventPtr->target);
-      break;
-    case TCLDOM_EVENT_TIMESTAMP:
-      Tcl_SetObjResult(interp, eventPtr->timeStamp);
-      break;
-    case TCLDOM_EVENT_TYPE:
-      if (eventPtr->type == TCLDOM_EVENT_USERDEFINED) {
-	Tcl_SetObjResult(interp, eventPtr->typeObjPtr);
-      } else {
-	Tcl_SetObjResult(interp, Tcl_NewStringObj(TclDOM_EventTypes[eventPtr->type], -1));
-      }
-      break;
-    case TCLDOM_EVENT_VIEW:
-      Tcl_SetObjResult(interp, eventPtr->view);
-      break;
-    default:
-      Tcl_SetResult(interp, "unknown option", NULL);
-      return TCL_ERROR;
-    }
-
-    break;
-
-  case TCLDOM_EVENT_CONFIGURE:
-    if (objc < 2) {
-      Tcl_WrongNumArgs(interp, 3, objv, "configure option ?value?");
-      return TCL_ERROR;
-    }
-
-    /* No event options are writable */
-    Tcl_SetResult(interp, "option cannot be modified", NULL);
-    return TCL_ERROR;
-
-    break;
-
-  case TCLDOM_EVENT_STOPPROPAGATION:
-
-    if (clientData) {
-	  if (objc != 2) {
-		Tcl_WrongNumArgs(interp, 2, objv, "");
-		return TCL_ERROR;
-	  }
-	  
-      tNodePtr = (TclDOM_libxml2_Node *) clientData;
-	  if (tNodePtr->type != TCLDOM_LIBXML2_NODE_EVENT) {
-		Tcl_SetResult(interp, "bad event node", NULL);
-		return TCL_ERROR;
-	  }
-      eventPtr = tNodePtr->ptr.eventPtr;
-    } else {
-	  if (objc != 3) {
-		Tcl_WrongNumArgs(interp, 3, objv, "");
-		return TCL_ERROR;
-	  }
-	  
-      if (TclDOM_libxml2_GetEventFromObj(interp, objv[2], &eventPtr) != TCL_OK) {
-		return TCL_ERROR;
-      }
-    }
-
-    eventPtr->stopPropagation = 1;
-
-    break;
-
-  case TCLDOM_EVENT_PREVENTDEFAULT:
-
-    if (clientData) {
-	  if (objc != 2) {
-		Tcl_WrongNumArgs(interp, 2, objv, "");
-		return TCL_ERROR;
-	  }
-	  
-      tNodePtr = (TclDOM_libxml2_Node *) clientData;
-	  if (tNodePtr->type != TCLDOM_LIBXML2_NODE_EVENT) {
-		Tcl_SetResult(interp, "bad event node", NULL);
-		return TCL_ERROR;
-	  }
-      eventPtr = tNodePtr->ptr.eventPtr;
-    } else {
-	  if (objc != 3) {
-		Tcl_WrongNumArgs(interp, 3, objv, "");
-		return TCL_ERROR;
-	  }
-	  
-      if (TclDOM_libxml2_GetEventFromObj(interp, objv[2], &eventPtr) != TCL_OK) {
-		return TCL_ERROR;
-      }
-    }
-
-    eventPtr->preventDefault = 1;
-
-    break;
-
-  case TCLDOM_EVENT_INITEVENT:
-
-    if (clientData) {
-	  if (objc != 5) {
-		Tcl_WrongNumArgs(interp, 2, objv, "type bubbles cancelable");
-		return TCL_ERROR;
-	  }
-	  
-      tNodePtr = (TclDOM_libxml2_Node *) clientData;
-	  if (tNodePtr->type != TCLDOM_LIBXML2_NODE_EVENT) {
-		Tcl_SetResult(interp, "bad event node", NULL);
-		return TCL_ERROR;
-	  }
-      eventPtr = tNodePtr->ptr.eventPtr;
-      objc -= 2;
-	  objv += 2;
-    } else {
-	  if (objc != 6) {
-		Tcl_WrongNumArgs(interp, 3, objv, "type bubbles cancelable");
-		return TCL_ERROR;
-	  }
-	  
-      if (TclDOM_libxml2_GetEventFromObj(interp, objv[2], &eventPtr) != TCL_OK) {
-		return TCL_ERROR;
-      }
-      objc -= 3;
-	  objv += 3;
-    }
-
-    if (eventPtr->dispatched) {
-      Tcl_SetResult(interp, "event has been dispatched", NULL);
-      return TCL_ERROR;
-    }
-
-    if (Tcl_GetIndexFromObj(interp, objv[0], TclDOM_EventTypes,
-			    "type", TCL_EXACT, &option) == TCL_OK) {
-      type = (enum TclDOM_EventTypes) option;
-    } else {
-      type = TCLDOM_EVENT_USERDEFINED;
-    }
-	Tcl_ResetResult(interp);
-
-    TclDOM_InitEvent(eventPtr, type, objv[0], objv[1], objv[2]);
-
-    break;
-
-  case TCLDOM_EVENT_INITUIEVENT:
-
-    if (clientData) {
-	  if (objc < 6 || objc > 7) {
-		Tcl_WrongNumArgs(interp, 2, objv, "type bubbles cancelable view ?detail?");
-		return TCL_ERROR;
-	  }
-	  
-      tNodePtr = (TclDOM_libxml2_Node *) clientData;
-	  if (tNodePtr->type != TCLDOM_LIBXML2_NODE_EVENT) {
-		Tcl_SetResult(interp, "bad event node", NULL);
-		return TCL_ERROR;
-	  }
-      eventPtr = tNodePtr->ptr.eventPtr;
-	  
-      objc -= 2;
-	  objv += 2;
-    } else {
-	  if (objc < 7 || objc > 8) {
-		Tcl_WrongNumArgs(interp, 3, objv, "type bubbles cancelable view ?detail?");
-		return TCL_ERROR;
-	  }
-	  
-      if (TclDOM_libxml2_GetEventFromObj(interp, objv[2], &eventPtr) != TCL_OK) {
-		return TCL_ERROR;
-      }
-
-      objc -= 3;
-	  objv += 3;
-    }
-
-    if (eventPtr->dispatched) {
-      Tcl_SetResult(interp, "event has been dispatched", NULL);
-      return TCL_ERROR;
-    }
-
-    if (Tcl_GetIndexFromObj(interp, objv[0], TclDOM_EventTypes,
-			    "type", TCL_EXACT, &option) == TCL_OK) {
-      type = (enum TclDOM_EventTypes) option;
-    } else {
-      type = TCLDOM_EVENT_USERDEFINED;
-    }
-	Tcl_ResetResult(interp);
-
-    TclDOM_InitUIEvent(eventPtr, type, objv[0], objv[1], objv[2], objv[3], objc == 5 ? objv[4] : NULL);
-
-    break;
-
-  case TCLDOM_EVENT_INITMOUSEEVENT:
-
-    if (clientData) {
-	  if (objc != 17) {
-		Tcl_WrongNumArgs(interp, 2, objv, "type bubbles cancelable view detail screenX screenY clientX clientY ctrlKey altKey shiftKey metaKey button relatedNode");
-		return TCL_ERROR;
-	  }
-	  
-      tNodePtr = (TclDOM_libxml2_Node *) clientData;
-	  if (tNodePtr->type != TCLDOM_LIBXML2_NODE_EVENT) {
-		Tcl_SetResult(interp, "bad event node", NULL);
-		return TCL_ERROR;
-	  }
-      eventPtr = tNodePtr->ptr.eventPtr;
-	  
-      objc -= 2;
-	  objv += 2;
-    } else {
-	  if (objc != 18) {
-		Tcl_WrongNumArgs(interp, 3, objv, "type bubbles cancelable view detail screenX screenY clientX clientY ctrlKey altKey shiftKey metaKey button relatedNode");
-		return TCL_ERROR;
-	  }
-	  
-      if (TclDOM_libxml2_GetEventFromObj(interp, objv[2], &eventPtr) != TCL_OK) {
-		return TCL_ERROR;
-      }
-
-      objc -= 3;
-	  objv += 3;
-    }
-
-    if (eventPtr->dispatched) {
-      Tcl_SetResult(interp, "event has been dispatched", NULL);
-      return TCL_ERROR;
-    }
-
-    if (Tcl_GetIndexFromObj(interp, objv[0], TclDOM_EventTypes,
-			    "type", TCL_EXACT, &option) == TCL_OK) {
-      type = (enum TclDOM_EventTypes) option;
-    } else {
-      type = TCLDOM_EVENT_USERDEFINED;
-    }
-	Tcl_ResetResult(interp);
-
-    TclDOM_InitMouseEvent(eventPtr, type, objv[0], objv[1], objv[2], objv[3], objv[4], objv[5], objv[6], objv[7], objv[8], objv[9], objv[10], objv[11], objv[12], objv[13], objv[14]);
-
-    break;
-
-  case TCLDOM_EVENT_INITMUTATIONEVENT:
-
-    if (clientData) {
-	  if (objc != 10) {
-		Tcl_WrongNumArgs(interp, 2, objv, "type bubbles cancelable relatedNode prevValue newValue attrName attrChange");
-		return TCL_ERROR;
-	  }
-	  
-      tNodePtr = (TclDOM_libxml2_Node *) clientData;
-	  if (tNodePtr->type != TCLDOM_LIBXML2_NODE_EVENT) {
-		Tcl_SetResult(interp, "bad event node", NULL);
-		return TCL_ERROR;
-	  }
-      eventPtr = tNodePtr->ptr.eventPtr;
-	  
-      objc -= 2;
-	  objv += 2;
-    } else {
-	  if (objc != 11) {
-		Tcl_WrongNumArgs(interp, 3, objv, "type bubbles cancelable relatedNode prevValue newValue attrName attrChange");
-		return TCL_ERROR;
-	  }
-	  
-      if (TclDOM_libxml2_GetEventFromObj(interp, objv[2], &eventPtr) != TCL_OK) {
-		return TCL_ERROR;
-      }
-
-      objc -= 3;
-	  objv += 3;
-    }
-
-    if (eventPtr->dispatched) {
-      Tcl_SetResult(interp, "event has been dispatched", NULL);
-      return TCL_ERROR;
-    }
-
-    if (Tcl_GetIndexFromObj(interp, objv[0], TclDOM_EventTypes,
-			    "type", TCL_EXACT, &option) == TCL_OK) {
-      type = (enum TclDOM_EventTypes) option;
-    } else {
-      type = TCLDOM_EVENT_USERDEFINED;
-    }
-	Tcl_ResetResult(interp);
-
-    TclDOM_InitMutationEvent(eventPtr, type, objv[0], objv[1], objv[2], objv[3], objv[4], objv[5], objv[6], objv[7]);
-
-    break;
-
-  case TCLDOM_EVENT_POSTUIEVENT:
-
-	if (clientData) {
-	  Tcl_SetResult(interp, "bad method for event", NULL);
-	  return TCL_ERROR;
-	}
-	
-    if (objc < 4) {
-      Tcl_WrongNumArgs(interp, 1, objv, "postUIEvent node type ?args ...?");
-      return TCL_ERROR;
-    }
-
-    if (TclDOM_libxml2_GetNodeFromObj(interp, objv[2], &nodePtr) != TCL_OK) {
-      return TCL_ERROR;
-    }
-    nodeObj = objv[2];
-
-    if (TclXML_libxml2_GetTclDocFromNode(interp, nodePtr, &tDocPtr) != TCL_OK) {
-      return TCL_ERROR;
-    }
-
-    if (Tcl_GetIndexFromObj(interp, objv[3], TclDOM_EventTypes,
-			    "type", TCL_EXACT, &option) == TCL_OK) {
-      type = (enum TclDOM_EventTypes) option;
-    } else {
-      type = TCLDOM_EVENT_USERDEFINED;
-    }
-    typeObjPtr = objv[3];
-	Tcl_ResetResult(interp);
-
-    bubblesPtr = Tcl_GetVar2Ex(interp, "::dom::bubbles", Tcl_GetStringFromObj(objv[3], NULL), TCL_GLOBAL_ONLY|TCL_LEAVE_ERR_MSG);
-    if (!bubblesPtr) {
-      return TCL_ERROR;
-    }
-    Tcl_IncrRefCount(bubblesPtr);
-    cancelablePtr = Tcl_GetVar2Ex(interp, "::dom::cancelable", Tcl_GetStringFromObj(objv[3], NULL), TCL_GLOBAL_ONLY|TCL_LEAVE_ERR_MSG);
-    if (!cancelablePtr) {
-      Tcl_DecrRefCount(bubblesPtr);
-      return TCL_ERROR;
-    }
-    Tcl_IncrRefCount(cancelablePtr);
-
-    viewPtr = Tcl_NewObj();
-    detailPtr = Tcl_NewObj();
-
-    objc -= 4;
-    objv += 4;
-    while (objc) {
-
-      if (objc == 1) {
-	Tcl_SetResult(interp, "value missing", NULL);
-        Tcl_DecrRefCount(bubblesPtr);
-        Tcl_DecrRefCount(cancelablePtr);
-        Tcl_DecrRefCount(viewPtr);
-        Tcl_DecrRefCount(detailPtr);
-	return TCL_ERROR;
-      }
-
-      if (Tcl_GetIndexFromObj(interp, objv[0], TclDOM_EventCommandOptions,
-			      "option", 0, &option) != TCL_OK) {
-        Tcl_DecrRefCount(bubblesPtr);
-        Tcl_DecrRefCount(cancelablePtr);
-        Tcl_DecrRefCount(viewPtr);
-        Tcl_DecrRefCount(detailPtr);
-	return TCL_ERROR;
-      }
-      switch ((enum TclDOM_EventCommandOptions) option) {
-      case TCLDOM_EVENT_BUBBLES:
-	Tcl_DecrRefCount(bubblesPtr);
-	bubblesPtr = objv[1];
-	Tcl_IncrRefCount(bubblesPtr);
-	break;
-      case TCLDOM_EVENT_CANCELABLE:
-	Tcl_DecrRefCount(cancelablePtr);
-	cancelablePtr = objv[1];
-	Tcl_IncrRefCount(cancelablePtr);
-	break;
-      case TCLDOM_EVENT_VIEW:
-	Tcl_DecrRefCount(viewPtr);
-	viewPtr = objv[1];
-	Tcl_IncrRefCount(viewPtr);
-	break;
-      case TCLDOM_EVENT_DETAIL:
-	Tcl_DecrRefCount(detailPtr);
-	detailPtr = objv[1];
-	Tcl_IncrRefCount(detailPtr);
-	break;
-      default:
-	Tcl_SetResult(interp, "bad option", NULL);
-        Tcl_DecrRefCount(bubblesPtr);
-        Tcl_DecrRefCount(cancelablePtr);
-        Tcl_DecrRefCount(viewPtr);
-        Tcl_DecrRefCount(detailPtr);
-	return TCL_ERROR;
-      }
-
-      objc -= 2;
-      objv += 2;
-    }
-
-    if (TclDOM_PostUIEvent(interp, tDocPtr, nodeObj, type, typeObjPtr, bubblesPtr, cancelablePtr, viewPtr, detailPtr) != TCL_OK) {
-      Tcl_DecrRefCount(bubblesPtr);
-      Tcl_DecrRefCount(cancelablePtr);
-      Tcl_DecrRefCount(viewPtr);
-      Tcl_DecrRefCount(detailPtr);
-      return TCL_ERROR;
-    }
-
-    break;
-
-  case TCLDOM_EVENT_POSTMOUSEEVENT:
-
-	if (clientData) {
-	  Tcl_SetResult(interp, "bad method for event", NULL);
-	  return TCL_ERROR;
-	}
-
-    if (objc < 4) {
-      Tcl_WrongNumArgs(interp, 1, objv, "postMouseEvent node type ?args ...?");
-      return TCL_ERROR;
-    }
-
-    if (TclDOM_libxml2_GetNodeFromObj(interp, objv[2], &nodePtr) != TCL_OK) {
-      return TCL_ERROR;
-    }
-    nodeObj = objv[2];
-
-    if (TclXML_libxml2_GetTclDocFromNode(interp, nodePtr, &tDocPtr) != TCL_OK) {
-      return TCL_ERROR;
-    }
-
-    if (Tcl_GetIndexFromObj(interp, objv[3], TclDOM_EventTypes,
-			    "type", TCL_EXACT, &option) == TCL_OK) {
-      type = (enum TclDOM_EventTypes) option;
-    } else {
-      type = TCLDOM_EVENT_USERDEFINED;
-    }
-    typeObjPtr = objv[3];
-	Tcl_ResetResult(interp);
-
-    bubblesPtr = Tcl_GetVar2Ex(interp, "::dom::bubbles", Tcl_GetStringFromObj(objv[3], NULL), TCL_GLOBAL_ONLY|TCL_LEAVE_ERR_MSG);
-    if (!bubblesPtr) {
-      return TCL_ERROR;
-    }
-    Tcl_IncrRefCount(bubblesPtr);
-    cancelablePtr = Tcl_GetVar2Ex(interp, "::dom::cancelable", Tcl_GetStringFromObj(objv[3], NULL), TCL_GLOBAL_ONLY|TCL_LEAVE_ERR_MSG);
-    if (!cancelablePtr) {
-      Tcl_DecrRefCount(bubblesPtr);
-      return TCL_ERROR;
-    }
-    Tcl_IncrRefCount(cancelablePtr);
-
-    viewPtr = Tcl_NewObj();
-    detailPtr = Tcl_NewObj();
-    relatedNodePtr = Tcl_NewObj();
-    screenXPtr = Tcl_NewObj();
-    screenYPtr = Tcl_NewObj();
-    clientXPtr = Tcl_NewObj();
-    clientYPtr = Tcl_NewObj();
-    ctrlKeyPtr = Tcl_NewObj();
-    shiftKeyPtr = Tcl_NewObj();
-    metaKeyPtr = Tcl_NewObj();
-    buttonPtr = Tcl_NewObj();
-
-    objc -= 4;
-    objv += 4;
-    while (objc) {
-
-      if (objc == 1) {
-	Tcl_SetResult(interp, "value missing", NULL);
-        goto mouse_error;
-      }
-
-      if (Tcl_GetIndexFromObj(interp, objv[0], TclDOM_EventCommandOptions,
-			      "option", 0, &option) != TCL_OK) {
-        goto mouse_error;
-      }
-      switch ((enum TclDOM_EventCommandOptions) option) {
-      case TCLDOM_EVENT_BUBBLES:
-	Tcl_DecrRefCount(bubblesPtr);
-	bubblesPtr = objv[1];
-	Tcl_IncrRefCount(bubblesPtr);
-	break;
-      case TCLDOM_EVENT_CANCELABLE:
-	Tcl_DecrRefCount(cancelablePtr);
-	cancelablePtr = objv[1];
-	Tcl_IncrRefCount(cancelablePtr);
-	break;
-      case TCLDOM_EVENT_RELATEDNODE:
-	Tcl_DecrRefCount(relatedNodePtr);
-	relatedNodePtr = objv[1];
-	Tcl_IncrRefCount(relatedNodePtr);
-	break;
-      case TCLDOM_EVENT_VIEW:
-	Tcl_DecrRefCount(viewPtr);
-	viewPtr = objv[1];
-	Tcl_IncrRefCount(viewPtr);
-	break;
-      case TCLDOM_EVENT_DETAIL:
-	Tcl_DecrRefCount(detailPtr);
-	detailPtr = objv[1];
-	Tcl_IncrRefCount(detailPtr);
-	break;
-      case TCLDOM_EVENT_SCREENX:
-	Tcl_DecrRefCount(screenXPtr);
-	screenXPtr = objv[1];
-	Tcl_IncrRefCount(screenXPtr);
-	break;
-      case TCLDOM_EVENT_SCREENY:
-	Tcl_DecrRefCount(screenYPtr);
-	screenYPtr = objv[1];
-	Tcl_IncrRefCount(screenYPtr);
-	break;
-      case TCLDOM_EVENT_CLIENTX:
-	Tcl_DecrRefCount(clientXPtr);
-	clientXPtr = objv[1];
-	Tcl_IncrRefCount(clientXPtr);
-	break;
-      case TCLDOM_EVENT_CLIENTY:
-	Tcl_DecrRefCount(clientYPtr);
-	clientYPtr = objv[1];
-	Tcl_IncrRefCount(clientYPtr);
-	break;
-      case TCLDOM_EVENT_CTRLKEY:
-	Tcl_DecrRefCount(ctrlKeyPtr);
-	ctrlKeyPtr = objv[1];
-	Tcl_IncrRefCount(ctrlKeyPtr);
-	break;
-      case TCLDOM_EVENT_SHIFTKEY:
-	Tcl_DecrRefCount(shiftKeyPtr);
-	shiftKeyPtr = objv[1];
-	Tcl_IncrRefCount(shiftKeyPtr);
-	break;
-      case TCLDOM_EVENT_METAKEY:
-	Tcl_DecrRefCount(metaKeyPtr);
-	metaKeyPtr = objv[1];
-	Tcl_IncrRefCount(metaKeyPtr);
-	break;
-      case TCLDOM_EVENT_BUTTON:
-	Tcl_DecrRefCount(buttonPtr);
-	buttonPtr = objv[1];
-	Tcl_IncrRefCount(buttonPtr);
-	break;
-      default:
-	Tcl_SetResult(interp, "bad option", NULL);
-	goto mouse_error;
-      }
-
-      objc -= 2;
-      objv += 2;
-    }
-
-    if (TclDOM_PostMouseEvent(interp, tDocPtr, nodeObj, type, typeObjPtr, bubblesPtr, cancelablePtr, relatedNodePtr, viewPtr, detailPtr, screenXPtr, screenYPtr, clientXPtr, clientYPtr, ctrlKeyPtr, shiftKeyPtr, metaKeyPtr, buttonPtr, relatedNodePtr) != TCL_OK) {
-      goto mouse_error;
-    }
-
-    break;
-
-mouse_error:
-    Tcl_DecrRefCount(bubblesPtr);
-    Tcl_DecrRefCount(cancelablePtr);
-    Tcl_DecrRefCount(viewPtr);
-    Tcl_DecrRefCount(detailPtr);
-    Tcl_DecrRefCount(relatedNodePtr);
-    Tcl_DecrRefCount(screenXPtr);
-    Tcl_DecrRefCount(screenYPtr);
-    Tcl_DecrRefCount(clientXPtr);
-    Tcl_DecrRefCount(clientYPtr);
-    Tcl_DecrRefCount(ctrlKeyPtr);
-    Tcl_DecrRefCount(shiftKeyPtr);
-    Tcl_DecrRefCount(metaKeyPtr);
-    Tcl_DecrRefCount(buttonPtr);
-
-    return TCL_ERROR;
-
-  case TCLDOM_EVENT_POSTMUTATIONEVENT:
-
-	if (clientData) {
-	  Tcl_SetResult(interp, "bad method for event", NULL);
-	  return TCL_ERROR;
-	}
-	
-    if (objc < 4) {
-      Tcl_WrongNumArgs(interp, 1, objv, "postMutationEvent node type ?args ...?");
-      return TCL_ERROR;
-    }
-
-    if (TclDOM_libxml2_GetNodeFromObj(interp, objv[2], &nodePtr) != TCL_OK) {
-      return TCL_ERROR;
-    }
-    nodeObj = objv[2];
-
-    if (TclXML_libxml2_GetTclDocFromNode(interp, nodePtr, &tDocPtr) != TCL_OK) {
-      return TCL_ERROR;
-    }
-
-    if (Tcl_GetIndexFromObj(interp, objv[3], TclDOM_EventTypes,
-			    "type", TCL_EXACT, &option) == TCL_OK) {
-      type = (enum TclDOM_EventTypes) option;
-    } else {
-      type = TCLDOM_EVENT_USERDEFINED;
-    }
-    typeObjPtr = objv[3];
-	Tcl_ResetResult(interp);
-
-    bubblesPtr = Tcl_GetVar2Ex(interp, "::dom::bubbles", Tcl_GetStringFromObj(objv[3], NULL), TCL_GLOBAL_ONLY|TCL_LEAVE_ERR_MSG);
-    if (!bubblesPtr) {
-      return TCL_ERROR;
-    }
-    Tcl_IncrRefCount(bubblesPtr);
-    cancelablePtr = Tcl_GetVar2Ex(interp, "::dom::cancelable", Tcl_GetStringFromObj(objv[3], NULL), TCL_GLOBAL_ONLY|TCL_LEAVE_ERR_MSG);
-    if (!cancelablePtr) {
-      Tcl_DecrRefCount(bubblesPtr);
-      return TCL_ERROR;
-    }
-    Tcl_IncrRefCount(cancelablePtr);
-
-    relatedNodePtr = Tcl_NewObj();
-    prevValuePtr = Tcl_NewObj();
-    newValuePtr = Tcl_NewObj();
-    attrNamePtr = Tcl_NewObj();
-    attrChangePtr = Tcl_NewObj();
-
-    objc -= 4;
-    objv += 4;
-    while (objc) {
-
-      if (objc == 1) {
-	Tcl_SetResult(interp, "value missing", NULL);
-        goto mutation_error;
-      }
-
-      if (Tcl_GetIndexFromObj(interp, objv[0], TclDOM_EventCommandOptions,
-			      "option", 0, &option) != TCL_OK) {
-        goto mutation_error;
-      }
-      switch ((enum TclDOM_EventCommandOptions) option) {
-      case TCLDOM_EVENT_BUBBLES:
-	Tcl_DecrRefCount(bubblesPtr);
-	bubblesPtr = objv[1];
-	Tcl_IncrRefCount(bubblesPtr);
-	break;
-      case TCLDOM_EVENT_CANCELABLE:
-	Tcl_DecrRefCount(cancelablePtr);
-	cancelablePtr = objv[1];
-	Tcl_IncrRefCount(cancelablePtr);
-	break;
-      case TCLDOM_EVENT_RELATEDNODE:
-	Tcl_DecrRefCount(relatedNodePtr);
-	relatedNodePtr = objv[1];
-	Tcl_IncrRefCount(relatedNodePtr);
-	break;
-      case TCLDOM_EVENT_PREVVALUE:
-	Tcl_DecrRefCount(prevValuePtr);
-	prevValuePtr = objv[1];
-	Tcl_IncrRefCount(prevValuePtr);
-	break;
-      case TCLDOM_EVENT_NEWVALUE:
-	Tcl_DecrRefCount(newValuePtr);
-	newValuePtr = objv[1];
-	Tcl_IncrRefCount(newValuePtr);
-	break;
-      case TCLDOM_EVENT_ATTRNAME:
-	Tcl_DecrRefCount(attrNamePtr);
-	attrNamePtr = objv[1];
-	Tcl_IncrRefCount(attrNamePtr);
-	break;
-      case TCLDOM_EVENT_ATTRCHANGE:
-	Tcl_DecrRefCount(attrChangePtr);
-	attrChangePtr = objv[1];
-	Tcl_IncrRefCount(attrChangePtr);
-	break;
-      default:
-	Tcl_SetResult(interp, "bad option", NULL);
-        goto mutation_error;
-      }
-
-      objc -= 2;
-      objv += 2;
-    }
-
-    if (TclDOM_PostMutationEvent(interp, tDocPtr, nodeObj, type, typeObjPtr, bubblesPtr, cancelablePtr, relatedNodePtr, prevValuePtr, newValuePtr, attrNamePtr, attrChangePtr) != TCL_OK) {
-      goto mutation_error;
-    }
-
-    break;
-
-mutation_error:
-    Tcl_DecrRefCount(bubblesPtr);
-    Tcl_DecrRefCount(cancelablePtr);
-    Tcl_DecrRefCount(relatedNodePtr);
-    Tcl_DecrRefCount(prevValuePtr);
-    Tcl_DecrRefCount(newValuePtr);
-    Tcl_DecrRefCount(attrNamePtr);
-    Tcl_DecrRefCount(attrChangePtr);
-
-    return TCL_ERROR;
-
-  default:
-
-    Tcl_SetResult(interp, "unknown method", NULL);
-    return TCL_ERROR;
-
-  }
-
-  return TCL_OK;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * GetPath --
- *
- *  Constructs a list of ancestor nodes.
- *
- * Results:
- *  Returns list as a Tcl_Obj.
- *
- * Side effects:
- *  Allocates Tcl_Obj structures.
- *
- *----------------------------------------------------------------------------
- */
-
-static Tcl_Obj *
-GetPath (interp, nodePtr)
-     Tcl_Interp *interp;
-     xmlNodePtr nodePtr;
-{
-  Tcl_Obj *listPtr, *resultPtr;
-  Tcl_Obj *objv[2];
-
-  if (nodePtr) {
-    if (nodePtr->type == XML_DOCUMENT_NODE) {
-	  objv[0] = TclXML_libxml2_CreateObjFromDoc((xmlDocPtr) nodePtr);
-	} else {
-	  objv[0] = TclDOM_libxml2_CreateObjFromNode(interp, nodePtr);
-	}
-    objv[1] = NULL;
-
-    listPtr = Tcl_NewListObj(1, objv);
-    if (nodePtr->parent) {
-      resultPtr = GetPath(interp, nodePtr->parent);
-      Tcl_ListObjAppendList(interp, resultPtr, listPtr);
-    } else {
-      resultPtr = listPtr;
-    }
-    return resultPtr;
-  } else {
-    return Tcl_NewObj();
-  }
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * Node (and event) Tcl Object management
- *
- *----------------------------------------------------------------------------
- */
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclDOM_libxml2_CreateObjFromNode --
- *
- *  Create a Tcl_Obj to wrap a tree node.
- *
- * Results:
- *  Returns Tcl_Obj*.
- *
- * Side effects:
- *  Allocates object.  Creates node command.
- *
- *----------------------------------------------------------------------------
- */
-
-Tcl_Obj *
-TclDOM_libxml2_CreateObjFromNode (interp, nodePtr)
-     Tcl_Interp *interp;
-     xmlNodePtr nodePtr;
-{
-  TclDOM_libxml2_Node *tNodePtr;
-  TclXML_libxml2_Document *tDocPtr;
-  TclDOM_libxml2_Document *domDocPtr;
-  Tcl_Obj *objPtr;
-  Tcl_HashEntry *entry;
-  int new;
-
-  if (TclXML_libxml2_GetTclDocFromNode(interp, nodePtr, &tDocPtr) != TCL_OK) {
-    Tcl_SetResult(interp, "unable to find document for node", NULL);
-    return NULL;
-  }
-  if ((domDocPtr = GetDOMDocument(interp, tDocPtr)) == NULL) {
-    Tcl_SetResult(interp, "internal error", NULL);
-    return NULL;
-  }
-
-  tNodePtr = (TclDOM_libxml2_Node *) Tcl_Alloc(sizeof(TclDOM_libxml2_Node));
-  tNodePtr->ptr.nodePtr = nodePtr;
-  tNodePtr->type = TCLDOM_LIBXML2_NODE_NODE;
-  tNodePtr->objs = NULL;
-  tNodePtr->token = Tcl_Alloc(30);
-  sprintf(tNodePtr->token, "::dom::%s::node%d", tDocPtr->token, domDocPtr->nodeCntr++);
-
-  entry = Tcl_CreateHashEntry(domDocPtr->nodes, tNodePtr->token, &new);
-  if (!new) {
-    Tcl_Free((char *) tNodePtr->token);
-    Tcl_Free((char *) tNodePtr);
-    Tcl_SetResult(interp, "internal error", NULL);
-    return NULL;
-  }
-  Tcl_SetHashValue(entry, (void *) tNodePtr);
-
-  tNodePtr->cmd = Tcl_CreateObjCommand(interp, tNodePtr->token, TclDOMNodeCommand, (ClientData) tNodePtr, TclDOMNodeCommandDelete);
-
-  objPtr = Tcl_NewObj();
-  objPtr->internalRep.otherValuePtr = (VOID *) tNodePtr;
-  objPtr->typePtr = &NodeObjType;
-
-  objPtr->bytes = Tcl_Alloc(strlen(tNodePtr->token) + 1);
-  strcpy(objPtr->bytes, tNodePtr->token);
-  objPtr->length = strlen(objPtr->bytes);
-
-  NodeAddObjRef(tNodePtr, objPtr);
-
-  return objPtr;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * NodeAddObjRef --
- *
- *  Add an object reference to a node wrapper.
- *
- * Results:
- *  Adds a reference to the Tcl_Obj for the node.
- *
- * Side effects:
- *  Allocates memory.
- *
- *----------------------------------------------------------------------------
- */
-
-static void
-NodeAddObjRef(tNodePtr, objPtr)
-  TclDOM_libxml2_Node *tNodePtr;
-  Tcl_Obj *objPtr;
-{
-  ObjList *listPtr;
-
-  listPtr = (ObjList *) Tcl_Alloc(sizeof(ObjList));
-  listPtr->next = tNodePtr->objs;
-  listPtr->objPtr = objPtr;
-
-  tNodePtr->objs = (void *) listPtr;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclDOMNodeCommandDelete --
- *
- *  Invoked when a DOM node's Tcl command is deleted.
- *
- * Results:
- *  Invalidates the Tcl_Obj for the node, but doesn't actually destroy the node.
- *
- * Side effects:
- *  Frees memory.
- *
- *----------------------------------------------------------------------------
- */
-
-void
-TclDOMNodeCommandDelete (clientData)
-     ClientData clientData;
-{
-  TclDOM_libxml2_Node *tNodePtr = (TclDOM_libxml2_Node *) clientData;
-
-  TclDOM_libxml2_InvalidateNode(tNodePtr);
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclDOM_libxml2_GetNodeFromObj --
- *
- *  Gets an xmlNodePtr from a Tcl_Obj.
- *
- * Results:
- *  Returns success code.
- *
- * Side effects:
- *  None.
- *
- *----------------------------------------------------------------------------
- */
-
-int
-TclDOM_libxml2_GetNodeFromObj (interp, objPtr, nodePtrPtr)
-     Tcl_Interp *interp;
-     Tcl_Obj *objPtr;
-     xmlNodePtr *nodePtrPtr;
-{
-  TclDOM_libxml2_Node *tNodePtr;
-
-  if (TclDOM_libxml2_GetTclNodeFromObj(interp, objPtr, &tNodePtr) != TCL_OK) {
-    return TCL_ERROR;
-  }
-
-  *nodePtrPtr = tNodePtr->ptr.nodePtr;
-
-  return TCL_OK;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclDOM_libxml2_GetTclNodeFromObj --
- *
- *  Gets the TclDOM node structure from a Tcl_Obj.
- *
- * Results:
- *  Returns success code.
- *
- * Side effects:
- *  None.
- *
- *----------------------------------------------------------------------------
- */
-
-int
-TclDOM_libxml2_GetTclNodeFromObj (interp, objPtr, tNodePtrPtr)
-     Tcl_Interp *interp;
-     Tcl_Obj *objPtr;
-     TclDOM_libxml2_Node **tNodePtrPtr;
-{
-  TclDOM_libxml2_Node *tNodePtr;
-
-  if (objPtr->typePtr == &NodeObjType) {
-    tNodePtr = (TclDOM_libxml2_Node *) objPtr->internalRep.otherValuePtr;
-  } else if (NodeTypeSetFromAny(interp, objPtr) == TCL_OK) {
-    tNodePtr = (TclDOM_libxml2_Node *) objPtr->internalRep.otherValuePtr;
-  } else {
-    return TCL_ERROR;
-  }
-
-  if (tNodePtr->type != TCLDOM_LIBXML2_NODE_NODE) {
-    return TCL_ERROR;
-  }
-
-  *tNodePtrPtr = tNodePtr;
-
-  return TCL_OK;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclDOM_libxml2_GetEventFromObj --
- *
- *  Gets an eventPtr from a Tcl_Obj.
- *
- * Results:
- *  Returns success code.
- *
- * Side effects:
- *  None.
- *
- *----------------------------------------------------------------------------
- */
-
-int
-TclDOM_libxml2_GetEventFromObj (interp, objPtr, eventPtrPtr)
-     Tcl_Interp *interp;
-     Tcl_Obj *objPtr;
-     TclDOM_libxml2_Event **eventPtrPtr;
-{
-  TclDOM_libxml2_Node *tNodePtr;
-
-  if (TclDOM_libxml2_GetTclEventFromObj(interp, objPtr, &tNodePtr) != TCL_OK) {
-    return TCL_ERROR;
-  }
-
-  *eventPtrPtr = tNodePtr->ptr.eventPtr;
-
-  return TCL_OK;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclDOM_libxml2_GetTclEventFromObj --
- *
- *  Gets the node structure for an event from a Tcl_Obj.
- *
- * Results:
- *  Returns success code.
- *
- * Side effects:
- *  None.
- *
- *----------------------------------------------------------------------------
- */
-
-int
-TclDOM_libxml2_GetTclEventFromObj (interp, objPtr, nodePtrPtr)
-     Tcl_Interp *interp;
-     Tcl_Obj *objPtr;
-     TclDOM_libxml2_Node **nodePtrPtr;
-{
-  TclDOM_libxml2_Node *tNodePtr;
-
-  if (objPtr->typePtr == &NodeObjType) {
-    tNodePtr = (TclDOM_libxml2_Node *) objPtr->internalRep.otherValuePtr;
-  } else if (NodeTypeSetFromAny(interp, objPtr) == TCL_OK) {
-    tNodePtr = (TclDOM_libxml2_Node *) objPtr->internalRep.otherValuePtr;
-  } else {
-    return TCL_ERROR;
-  }
-
-  if (tNodePtr->type != TCLDOM_LIBXML2_NODE_EVENT) {
-    return TCL_ERROR;
-  }
-
-  *nodePtrPtr = tNodePtr;
-
-  return TCL_OK;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclDOM_libxml2_DestroyNode --
- *
- *  Destroys a node
- *
- * Results:
- *  Frees node.
- *
- * Side effects:
- *  Deallocates memory.
- *
- *----------------------------------------------------------------------------
- */
-
-static void
-TclDOM_libxml2_DeleteNode(clientData)
-    ClientData clientData;
-{
-  TclDOM_libxml2_Node *tNodePtr = (TclDOM_libxml2_Node *) clientData;
-  TclDOM_libxml2_Event *eventPtr;
-  TclXML_libxml2_Document *tDocPtr;
-  TclDOM_libxml2_Document *domDocPtr;
-  Tcl_Obj *objPtr;
-  xmlNodePtr nodePtr;
-  Tcl_HashEntry *entry;
-
-  if (tNodePtr->type == TCLDOM_LIBXML2_NODE_NODE) {
-    nodePtr = tNodePtr->ptr.nodePtr;
-    objPtr = TclXML_libxml2_CreateObjFromDoc(nodePtr->doc);
-    TclXML_libxml2_GetTclDocFromObj(NULL, objPtr, &tDocPtr);
-    domDocPtr = GetDOMDocument(NULL, tDocPtr);
-    if (domDocPtr == NULL) {
-      /* internal error */
-      return;
-    }
-  } else {
-    eventPtr = tNodePtr->ptr.eventPtr;
-    domDocPtr = eventPtr->ownerDocument;
-    Tcl_Free((char *) eventPtr);
-  }
-
-  entry = Tcl_FindHashEntry(domDocPtr->nodes, tNodePtr->token);
-  if (entry) {
-    Tcl_DeleteHashEntry(entry);
-  } else {
-    fprintf(stderr, "cannot delete node hash entry!\n");
-  }
-
-  TclDOM_libxml2_InvalidateNode(tNodePtr);
-
-  if (tNodePtr->appfree) {
-    (tNodePtr->appfree)(tNodePtr->apphook);
-  }
-
-  Tcl_Free((char *) tNodePtr);
-}
-
-void
-TclDOM_libxml2_DestroyNode (interp, tNodePtr)
-     Tcl_Interp *interp;
-     TclDOM_libxml2_Node *tNodePtr;
-{
-  Tcl_DeleteCommandFromToken(interp, tNodePtr->cmd);
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclDOM_libxml2_InvalidateNode --
- *
- *  Invalidates the internal representation of any Tcl_obj that refers to
- *  this node.  NB. This does not destroy the node, or delete the node command.
- *
- * Results:
- *  Tcl_Obj internal reps changed.
- *
- * Side effects:
- *  None.
- *
- *----------------------------------------------------------------------------
- */
-
-void
-TclDOM_libxml2_InvalidateNode (tNodePtr)
-     TclDOM_libxml2_Node *tNodePtr;
-{
-  ObjList *listPtr, *nextPtr;
-
-  for (listPtr = (ObjList *) tNodePtr->objs; listPtr;) {
-
-    listPtr->objPtr->internalRep.otherValuePtr = NULL;
-    listPtr->objPtr->typePtr = NULL;
-
-    nextPtr = listPtr->next;
-    Tcl_Free((char *) listPtr);
-    listPtr = nextPtr;
-  }
-
-  tNodePtr->objs = NULL;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * Node object type management
- *
- *----------------------------------------------------------------------------
- */
-
-/*
- * NodeTypeSetFromAny --
- *
- *  Sets the internal representation from the string rep.
- *
- * Results:
- *  Success code.
- *
- * Side effects:
- *  Changes internal rep.
- *
- *----------------------------------------------------------------------------
- */
-
-int
-NodeTypeSetFromAny(interp, objPtr)
-     Tcl_Interp *interp;
-     Tcl_Obj *objPtr;
-{
-  Tcl_Obj *docObjPtr;
-  TclXML_libxml2_Document *tDocPtr;
-  TclDOM_libxml2_Document *domDocPtr;
-  Tcl_HashEntry *entry;
-  char *id, doc[21], node[21];
-  int i, idlen, len;
-
-  /* Parse string rep for doc and node ids */
-  id = Tcl_GetStringFromObj(objPtr, &idlen);
-  /* node tokens are prefixed with "::dom::" */
-  if (idlen < 7 || strncmp("::dom::", id, 7) != 0) {
-    Tcl_ResetResult(interp);
-    Tcl_AppendResult(interp, "malformed node token \"", id, "\"", NULL);
-    return TCL_ERROR;
-  }
-  for (i = 0; i < idlen && id[i + 7] != ':' && i < 21; i++) {
-    if (!((id[i + 7] >= 'a' && id[i + 7] <= 'z') || (id[i + 7] >= '0' && id[i + 7] <= '9'))) {
-      /* only lowercase chars and digits are found in a token */
-      Tcl_ResetResult(interp);
-      Tcl_AppendResult(interp, "malformed node token \"", id, "\"", NULL);
-      return TCL_ERROR;
-    }
-    doc[i] = id[i + 7];
-  }
-  if (i == idlen || id[i + 7] != ':') {
-    Tcl_ResetResult(interp);
-    Tcl_AppendResult(interp, "malformed node token \"", id, "\"", NULL);
-    return TCL_ERROR;
-  }
-  doc[i] = '\0';
-  i++;
-
-  if (i == idlen || id[i + 7] != ':') {
-    Tcl_ResetResult(interp);
-    Tcl_AppendResult(interp, "malformed node token \"", id, "\"", NULL);
-    return TCL_ERROR;
-  }
-  i++;
-  for (len = i + 7, i = 0; i + len < idlen && i < 21; i++) {
-    node[i] = id[len + i];
-  }
-  node[i] = '\0';
-
-  docObjPtr = Tcl_NewStringObj(doc, -1);
-  if (TclXML_libxml2_GetTclDocFromObj(interp, docObjPtr, &tDocPtr) != TCL_OK) {
-    Tcl_DecrRefCount(docObjPtr);
-    Tcl_SetResult(interp, "invalid node token", NULL);
-    return TCL_ERROR;
-  }
-  domDocPtr = GetDOMDocument(interp, tDocPtr);
-  if (domDocPtr == NULL) {
-    Tcl_SetResult(interp, "internal error", NULL);
-    return TCL_ERROR;
-  }
-
-  entry = Tcl_FindHashEntry(domDocPtr->nodes, id);
-  if (entry) {
-	TclDOM_libxml2_Node *tNodePtr;
-
-    if (objPtr->typePtr != NULL && objPtr->typePtr->freeIntRepProc != NULL) {
-      objPtr->typePtr->freeIntRepProc(objPtr);
-    }
-
-	tNodePtr = (TclDOM_libxml2_Node *) Tcl_GetHashValue(entry);
-    objPtr->internalRep.otherValuePtr = (void *) tNodePtr;
-    objPtr->typePtr = &NodeObjType;
-	NodeAddObjRef(tNodePtr, objPtr);
-
-  } else {
-    Tcl_DecrRefCount(docObjPtr);
-    Tcl_SetResult(interp, "not a DOM node", NULL);
-    return TCL_ERROR;
-  }
-
-  Tcl_DecrRefCount(docObjPtr);
-
-  return TCL_OK;
-}
-
-void
-NodeTypeUpdate(objPtr)
-     Tcl_Obj *objPtr;
-{
-  TclDOM_libxml2_Node *tNodePtr = (TclDOM_libxml2_Node *) objPtr->internalRep.otherValuePtr;
-
-  objPtr->bytes = Tcl_Alloc(strlen(tNodePtr->token) + 1);
-  strcpy(objPtr->bytes, tNodePtr->token);
-  objPtr->length = strlen(objPtr->bytes);
-}
-
-void
-NodeTypeDup(srcPtr, dstPtr)
-     Tcl_Obj *srcPtr;
-     Tcl_Obj *dstPtr;
-{
-  TclDOM_libxml2_Node *tNodePtr = (TclDOM_libxml2_Node *) srcPtr->internalRep.otherValuePtr;
-
-  if (dstPtr->typePtr != NULL && dstPtr->typePtr->freeIntRepProc != NULL) {
-    dstPtr->typePtr->freeIntRepProc(dstPtr);
-  }
-
-  Tcl_InvalidateStringRep(dstPtr);
-
-  dstPtr->internalRep.otherValuePtr = (ClientData) tNodePtr;
-  dstPtr->typePtr = srcPtr->typePtr;
-  
-  NodeAddObjRef(tNodePtr, dstPtr);
-}
-
-/*
- * Unlike documents, nodes are not destroyed just because they have no Tcl_Obj's
- * referring to them.
- */
-
-void
-NodeTypeFree(objPtr)
-     Tcl_Obj *objPtr;
-{
-  TclDOM_libxml2_Node *tNodePtr = (TclDOM_libxml2_Node *) objPtr->internalRep.otherValuePtr;
-  ObjList *listPtr = tNodePtr->objs;
-  ObjList *prevPtr = NULL;
-
-  while (listPtr) {
-    if (listPtr->objPtr == objPtr) {
-      break;
-    }
-    prevPtr = listPtr;
-    listPtr = listPtr->next;
-  }
-
-  if (listPtr == NULL) {
-    /* internal error */
-  } else if (prevPtr == NULL) {
-    tNodePtr->objs = listPtr->next;
-  } else {
-    prevPtr->next = listPtr->next;
-  }
-  Tcl_Free((char *) listPtr);
-
-  objPtr->internalRep.otherValuePtr = NULL;
-  objPtr->typePtr = NULL;
-}
-#if 0
-static void
-DumpNode(tNodePtr)
-TclDOM_libxml2_Node *tNodePtr;
-{
-  ObjList *listPtr;
-  
-  fprintf(stderr, "    node token \"%s\" type %d ptr x%x\n", 
-		  tNodePtr->token, tNodePtr->type, 
-		  tNodePtr->ptr.nodePtr);
-  listPtr = (ObjList *) tNodePtr->objs;
-  if (listPtr) {
-	fprintf(stderr, "        objects:");
-	while (listPtr) {
-	  fprintf(stderr, " objPtr x%x", listPtr->objPtr);
-	  listPtr = listPtr->next;
-	  fprintf(stderr, "\n");
-	}
-  } else {
-	fprintf(stderr, "        no objects\n");
-  }
-}
-#endif
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclDOM_libxml2_NewEventObj --
- *
- *  Create a Tcl_Obj for an event.
- *
- * Results:
- *  Returns Tcl_Obj*.
- *
- * Side effects:
- *  Allocates object.
- *
- *----------------------------------------------------------------------------
- */
-
-Tcl_Obj *
-TclDOM_libxml2_NewEventObj (interp, docPtr, type, typeObjPtr)
-     Tcl_Interp *interp;
-     xmlDocPtr docPtr;
-     enum TclDOM_EventTypes type;
-     Tcl_Obj *typeObjPtr;	/* NULL for standard types */
-{
-  Tcl_Obj *objPtr, *docObjPtr;
-  TclDOM_libxml2_Node *tNodePtr;
-  TclDOM_libxml2_Event *eventPtr;
-  TclXML_libxml2_Document *tDocPtr;
-  TclDOM_libxml2_Document *domDocPtr;
-  Tcl_HashEntry *entry;
-  int new;
-
-  docObjPtr = TclXML_libxml2_CreateObjFromDoc(docPtr);
-  TclXML_libxml2_GetTclDocFromObj(interp, docObjPtr, &tDocPtr);
-  domDocPtr = GetDOMDocument(interp, tDocPtr);
-  if (domDocPtr == NULL) {
-    Tcl_SetResult(interp, "internal error", NULL);
-    return NULL;
-  }
-
-  tNodePtr = (TclDOM_libxml2_Node *) Tcl_Alloc(sizeof(TclDOM_libxml2_Node));
-  tNodePtr->token = Tcl_Alloc(30);
-  sprintf(tNodePtr->token, "::dom::%s::event%d", tDocPtr->token, domDocPtr->nodeCntr++);
-  tNodePtr->type = TCLDOM_LIBXML2_NODE_EVENT;
-  tNodePtr->objs = NULL;
-  tNodePtr->apphook = NULL;
-  tNodePtr->appfree = NULL;
-
-  entry = Tcl_CreateHashEntry(domDocPtr->nodes, tNodePtr->token, &new);
-  if (!new) {
-    Tcl_Free((char *) tNodePtr->token);
-    Tcl_Free((char *) tNodePtr);
-    return NULL;
-  }
-  Tcl_SetHashValue(entry, (void *) tNodePtr);
-
-  tNodePtr->cmd = Tcl_CreateObjCommand(interp, tNodePtr->token, TclDOMEventCommand, (ClientData) tNodePtr, TclDOMEventCommandDelete);
-
-  eventPtr = (TclDOM_libxml2_Event *) Tcl_Alloc(sizeof(TclDOM_libxml2_Event));
-  eventPtr->ownerDocument = domDocPtr;
-  eventPtr->tNodePtr = tNodePtr;
-
-  /*
-   * Overload the node pointer to refer to the event structure.
-   */
-  tNodePtr->ptr.eventPtr = eventPtr;
-
-  objPtr = Tcl_NewObj();
-  objPtr->internalRep.otherValuePtr = (VOID *) tNodePtr;
-  objPtr->typePtr = &NodeObjType;
-
-  objPtr->bytes = Tcl_Alloc(strlen(tNodePtr->token) + 1);
-  strcpy(objPtr->bytes, tNodePtr->token);
-  objPtr->length = strlen(objPtr->bytes);
-
-  NodeAddObjRef(tNodePtr, objPtr);
-
-  eventPtr->type = type;
-  if (type == TCLDOM_EVENT_USERDEFINED) {
-    eventPtr->typeObjPtr = typeObjPtr;
-    Tcl_IncrRefCount(eventPtr->typeObjPtr);
-  } else {
-    eventPtr->typeObjPtr = NULL;
-  }
-
-  eventPtr->stopPropagation = 0;
-  eventPtr->preventDefault = 0;
-  eventPtr->dispatched = 0;
-
-  eventPtr->altKey = Tcl_NewObj();
-  Tcl_IncrRefCount(eventPtr->altKey);
-  eventPtr->attrName = Tcl_NewObj();
-  Tcl_IncrRefCount(eventPtr->attrName);
-  eventPtr->attrChange = Tcl_NewObj();
-  Tcl_IncrRefCount(eventPtr->attrChange);
-  eventPtr->bubbles = Tcl_NewIntObj(1);
-  Tcl_IncrRefCount(eventPtr->bubbles);
-  eventPtr->button = Tcl_NewObj();
-  Tcl_IncrRefCount(eventPtr->button);
-  eventPtr->cancelable = Tcl_NewIntObj(1);
-  Tcl_IncrRefCount(eventPtr->cancelable);
-  eventPtr->clientX = Tcl_NewObj();
-  Tcl_IncrRefCount(eventPtr->clientX);
-  eventPtr->clientY = Tcl_NewObj();
-  Tcl_IncrRefCount(eventPtr->clientY);
-  eventPtr->ctrlKey = Tcl_NewObj();
-  Tcl_IncrRefCount(eventPtr->ctrlKey);
-  eventPtr->currentNode = Tcl_NewObj();
-  Tcl_IncrRefCount(eventPtr->currentNode);
-  eventPtr->detail = Tcl_NewObj();
-  Tcl_IncrRefCount(eventPtr->detail);
-  eventPtr->eventPhase = Tcl_NewObj();
-  Tcl_IncrRefCount(eventPtr->eventPhase);
-  eventPtr->metaKey = Tcl_NewObj();
-  Tcl_IncrRefCount(eventPtr->metaKey);
-  eventPtr->newValue = Tcl_NewObj();
-  Tcl_IncrRefCount(eventPtr->newValue);
-  eventPtr->prevValue = Tcl_NewObj();
-  Tcl_IncrRefCount(eventPtr->prevValue);
-  eventPtr->relatedNode = Tcl_NewObj();
-  Tcl_IncrRefCount(eventPtr->relatedNode);
-  eventPtr->screenX = Tcl_NewObj();
-  Tcl_IncrRefCount(eventPtr->screenX);
-  eventPtr->screenY = Tcl_NewObj();
-  Tcl_IncrRefCount(eventPtr->screenY);
-  eventPtr->shiftKey = Tcl_NewObj();
-  Tcl_IncrRefCount(eventPtr->shiftKey);
-  eventPtr->target = Tcl_NewObj();
-  Tcl_IncrRefCount(eventPtr->target);
-
-  /* Timestamping of DOM events is not available in Tcl 8.3.x.
-   * The required API (Tcl_GetTime) is public only since 8.4.0.
-   */
-
-  eventPtr->timeStamp = Tcl_NewLongObj(0);
-#if (TCL_MAJOR_VERSION > 8) || ((TCL_MAJOR_VERSION == 8) && (TCL_MINOR_VERSION > 3))
-  {
-    Tcl_Time time;
-
-    Tcl_GetTime(&time);
-    Tcl_SetLongObj(eventPtr->timeStamp, time.sec*1000 + time.usec/1000);
-  }
-#endif
-  Tcl_IncrRefCount(eventPtr->timeStamp);
-
-  eventPtr->view = Tcl_NewObj();
-  Tcl_IncrRefCount(eventPtr->view);
-
-  return objPtr;
-}
-/*
- *----------------------------------------------------------------------------
- *
- * TclDOMEventCommandDelete --
- *
- *  Invoked when a DOM event node's Tcl command is deleted.
- *
- * Results:
- *  Destroy the node.
- *
- * Side effects:
- *  Frees memory.
- *
- *----------------------------------------------------------------------------
- */
-
-void
-TclDOMEventCommandDelete (clientData)
-ClientData clientData;
-{
-  TclDOM_libxml2_Node *tNodePtr = (TclDOM_libxml2_Node *) clientData;
-  TclDOM_libxml2_Event *eventPtr;
-
-  if (tNodePtr->type != TCLDOM_LIBXML2_NODE_EVENT) {
-	return; /* internal error. should this panic? */
-  }
-  eventPtr = tNodePtr->ptr.eventPtr;
-
-  if (eventPtr->typeObjPtr) {
-	Tcl_DecrRefCount(eventPtr->typeObjPtr);
-  }
-  if (eventPtr->altKey) {
-	Tcl_DecrRefCount(eventPtr->altKey);
-  }
-  if (eventPtr->attrName) {
-	Tcl_DecrRefCount(eventPtr->attrName);
-  }
-  if (eventPtr->attrChange) {
-	Tcl_DecrRefCount(eventPtr->attrChange);
-  }
-  if (eventPtr->bubbles) {
-	Tcl_DecrRefCount(eventPtr->bubbles);
-  }
-  if (eventPtr->button) {
-	Tcl_DecrRefCount(eventPtr->button);
-  }
-  if (eventPtr->cancelable) {
-	Tcl_DecrRefCount(eventPtr->cancelable);
-  }
-  if (eventPtr->clientX) {
-	Tcl_DecrRefCount(eventPtr->clientX);
-  }
-  if (eventPtr->clientY) {
-	Tcl_DecrRefCount(eventPtr->clientY);
-  }
-  if (eventPtr->ctrlKey) {
-	Tcl_DecrRefCount(eventPtr->ctrlKey);
-  }
-  if (eventPtr->currentNode) {
-	Tcl_DecrRefCount(eventPtr->currentNode);
-  }
-  if (eventPtr->detail) {
-	Tcl_DecrRefCount(eventPtr->detail);
-  }
-  if (eventPtr->eventPhase) {
-	Tcl_DecrRefCount(eventPtr->eventPhase);
-  }
-  if (eventPtr->metaKey) {
-	Tcl_DecrRefCount(eventPtr->metaKey);
-  }
-  if (eventPtr->newValue) {
-	Tcl_DecrRefCount(eventPtr->newValue);
-  }
-  if (eventPtr->prevValue) {
-	Tcl_DecrRefCount(eventPtr->prevValue);
-  }
-  if (eventPtr->relatedNode) {
-	Tcl_DecrRefCount(eventPtr->relatedNode);
-  }
-  if (eventPtr->screenX) {
-	Tcl_DecrRefCount(eventPtr->screenX);
-  }
-  if (eventPtr->screenY) {
-	Tcl_DecrRefCount(eventPtr->screenY);
-  }
-  if (eventPtr->shiftKey) {
-	Tcl_DecrRefCount(eventPtr->shiftKey);
-  }
-  if (eventPtr->target) {
-	Tcl_DecrRefCount(eventPtr->target);
-  }
-  if (eventPtr->timeStamp) {
-	Tcl_DecrRefCount(eventPtr->timeStamp);
-  }
-  if (eventPtr->view) {
-	Tcl_DecrRefCount(eventPtr->view);
-  }
-
-  /* Invalidates all referring objects and frees all data structures */
-  TclDOM_libxml2_DeleteNode((ClientData) tNodePtr);
-}
-
diff --git a/tclxml-3.2/tcldom-libxml2.tcl b/tclxml-3.2/tcldom-libxml2.tcl
deleted file mode 100644
index d5ef415..0000000
--- a/tclxml-3.2/tcldom-libxml2.tcl
+++ /dev/null
@@ -1,37 +0,0 @@
-# impl.tcl --
-#
-#	Support script for libxml2 implementation.
-#
-# Std disclaimer
-#
-# $Id: tcldom-libxml2.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-namespace eval ::dom {
-    variable strictDOM 1
-}
-
-proc dom::libxml2::parse {xml args} {
-
-    array set options {
-	-keep normal
-	-retainpath /*
-    }
-    array set options $args
-
-    if {[catch {eval ::xml::parser -parser libxml2 [array get options]} parser]} {
-	return -code error "unable to create XML parser due to \"$parser\""
-    }
-
-    if {[catch {$parser parse $xml} msg]} {
-	return -code error $msg
-    }
-
-    set doc [$parser get document]
-    set dom [dom::libxml2::adoptdocument $doc]
-    $parser free
-
-    return $dom
-}
-proc dom::parse {xml args} {
-    return [eval ::dom::libxml2::parse [list $xml] $args]
-}
diff --git a/tclxml-3.2/tcldom-tcl/dom.tcl b/tclxml-3.2/tcldom-tcl/dom.tcl
deleted file mode 100644
index b3edc99..0000000
--- a/tclxml-3.2/tcldom-tcl/dom.tcl
+++ /dev/null
@@ -1,4291 +0,0 @@
-# dom.tcl --
-#
-#	This file implements the Tcl language binding for the DOM -
-#	the Document Object Model.  Support for the core specification
-#	is given here.  Layered support for specific languages, 
-#	such as HTML, will be in separate modules.
-#
-# Copyright (c) 1998-2004 Zveno Pty Ltd
-# http://www.zveno.com/
-#
-# See the file "LICENSE" in this distribution for information on usage and
-# redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
-#
-# $Id: dom.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-# We need the xml package, so that we get Name defined
-
-package require xml 3.0
-
-package provide dom::tcl 3.0
-
-# Define generic constants
-
-namespace eval dom {
-    namespace export DOMImplementation
-    namespace export hasFeature createDocument create createDocumentType
-    namespace export createNode destroy isNode parse selectNode serialize
-    namespace export trim
-
-    namespace export document documentFragment node
-    namespace export element textNode attribute
-    namespace export processingInstruction
-    namespace export documenttype
-    namespace export event
-
-    variable maxSpecials
-    if {![info exists maxSpecials]} {
-	set maxSpecials 10
-    }
-
-    variable strictDOM 0
-
-    # Default -indentspec value
-    #	spaces-per-indent-level {collapse-re collapse-value}
-    variable indentspec [list 2 [list {        } \t]]
-
-    # The Namespace URI for XML Namespace declarations
-    variable xmlnsURI http://www.w3.org/2000/xmlns/
-
-    # DOM Level 2 Event defaults
-    variable bubbles
-    array set bubbles {
-	DOMFocusIn 1
-	DOMFocusOut 1
-	DOMActivate 1
-	click 1
-	mousedown 1
-	mouseup 1
-	mouseover 1
-	mousemove 1
-	mouseout 1
-	DOMSubtreeModified 1
-	DOMNodeInserted 1
-	DOMNodeRemoved 1
-	DOMNodeInsertedIntoDocument 0
-	DOMNodeRemovedFromDocument 0
-	DOMAttrModified 1
-	DOMAttrRemoved 1
-	DOMCharacterDataModified 1
-    }
-    variable cancelable
-    array set cancelable {
-	DOMFocusIn 0
-	DOMFocusOut 0
-	DOMActivate 1
-	click 1
-	mousedown 1
-	mouseup 1
-	mouseover 1
-	mousemove 0
-	mouseout 1
-	DOMSubtreeModified 0
-	DOMNodeInserted 0
-	DOMNodeRemoved 0
-	DOMNodeInsertedIntoDocument 0
-	DOMNodeRemovedFromDocument 0
-	DOMAttrModified 0
-	DOMAttrRemoved 0
-	DOMCharacterDataModified 0
-    }
-}
-
-namespace eval dom::tcl {
-    namespace export DOMImplementation
-    namespace export hasFeature createDocument create createDocumentType
-    namespace export createNode destroy isNode parse selectNode serialize
-    namespace export trim
-
-    namespace export document documentFragment node
-    namespace export element textNode attribute
-    namespace export processingInstruction
-    namespace export event
-}
-
-foreach p {DOMImplementation hasFeature createDocument create createDocumentType createNode destroy isNode parse selectNode serialize trim document documentFragment node element textNode attribute processingInstruction event documenttype} {
-
-    proc dom::$p args "return \[eval tcl::$p \$args\]"
-
-}
-
-# Data structures
-#
-# Documents are stored in a Tcl namespace within the ::dom namespace.
-# The Document array variable stores data for the document itself.
-# Each node has an array variable for its data.
-#
-# "Live" data objects are stored as a separate Tcl variable.
-# Lists, such as child node lists, are Tcl list variables (ie scalar)
-# and keyed-value lists, such as attribute lists, are Tcl array
-# variables.  The accessor function returns the variable name,
-# which the application should treat as a read-only object.
-#
-# A token is a FQ Tcl variable name.
-
-# dom::tcl::DOMImplementation --
-#
-#	Implementation-dependent functions.
-#	Most importantly, this command provides a function to
-#	create a document instance.
-#
-# Arguments:
-#	method	method to invoke
-#	token	token for node
-#	args	arguments for method
-#
-# Results:
-#	Depends on method used.
-
-namespace eval dom::tcl {
-    variable DOMImplementationOptions {}
-    variable DOMImplementationCounter
-    if {![info exists DOMImplementationCounter]} {
-	set DOMImplementationCounter 0
-    }
-}
-
-proc dom::tcl::DOMImplementation {method args} {
-    variable DOMImplementationOptions
-    variable DOMImplementationCounter
-
-    switch -- $method {
-
-	hasFeature {
-
-	    if {[llength $args] != 2} {
-		return -code error "wrong # args: should be dom::DOMImplementation method args..."
-	    }
-
-	    # Later on, could use Tcl package facility
-	    if {[regexp {create|destroy|parse|query|serialize|trim|Events|UIEvents|isNode} [lindex $args 0]]} {
-		if {![string compare [lindex $args 1] "1.0"]} {
-		    return 1
-		} else {
-		    return 0
-		}
-	    } else {
-		return 0
-	    }
-
-	}
-
-	createDocument {
-	    # createDocument introduced in DOM Level 2
-
-	    if {[llength $args] != 3} {
-		return -code error "wrong # args: should be DOMImplementation nsURI name doctype"
-	    }
-
-	    set doc [DOMImplementation create]
-
-	    if {[string length [lindex $args 2]]} {
-		array set $doc [list document:doctype [lindex $args 2]]
-	    }
-
-	    document createElementNS $doc [lindex $args 0] [lindex $args 1]
-
-	    return $doc
-	}
-
-	create {
-
-	    # Non-standard method (see createDocument)
-	    # Bootstrap a document instance
-
-	    if {[llength $args] > 0} {
-		return -code error "wrong # args: should be DOMImplementation create"
-	    }
-
-	    # Allocate unique document array name
-	    set ns [namespace current]::document[incr DOMImplementationCounter]
-	    set name ${ns}::Document
-
-	    # Create the Tcl namespace for this document
-	    namespace eval $ns {
-		namespace export Document
-	    }
-
-	    set varPrefix ${name}var
-	    set arrayPrefix ${name}arr
-
-	    array set $name [list counter 1 \
-		node:nodeType document			\
-		node:parentNode {}			\
-		node:nodeName #document			\
-		node:nodeValue {}			\
-		node:childNodes ${varPrefix}1		\
-		documentFragment:masterDoc $name	\
-		document:implementation [namespace current]::DOMImplementation		\
-		document:xmldecl {version 1.0}		\
-		document:documentElement {}		\
-		document:doctype {}			\
-		]
-
-	    # Initialise child node list
-	    set $varPrefix {}
-
-	    # Create a Tcl command for the document
-	    proc $name {method args} "return \[eval [namespace current]::document \[list \$method\] $name \$args\]"
-
-	    # Capture destruction of the document
-	    trace add command $name delete [namespace code [list Document:Delete $name]]
-
-	    # Return the new toplevel node
-	    return $name
-	}
-
-	createDocumentType {
-	    # Introduced in DOM Level 2
-
-	    # Patch from c.l.t., Richard Calmbach (rc at hnc.com )
-
-	    if {[llength $args] < 3 || [llength $args] > 4} {
-		return -code error "wrong # args: should be: DOMImplementation createDocumentType qname publicid systemid ?internaldtd?"
-	    }
-
-	    return [eval CreateDocType $args]
-	}
-
-	createNode {
-	    # Non-standard method
-	    # Creates node(s) in the given document given an XPath expression
-
-	    if {[llength $args] != 2} {
-		return -code error "wrong # args: should be dom::DOMImplementation createNode xpath"
-	    }
-
-	    package require xpath
-
-	    return [XPath:CreateNode [lindex $args 0] [lindex $args 1]]
-	}
-
-	destroy {
-
-	    # Free all memory associated with a node
-
-	    if {[llength $args] != 1} {
-		return -code error "wrong # args: should be dom::DOMImplementation destroy token"
-	    }
-
-	    if {[catch {upvar #0 [lindex $args 0] node}]} {
-		# If the document is being destroyed then the Tcl namespace no longer exists
-		return {}
-	    }
-
-	    switch $node(node:nodeType) {
-
-		document -
-		documentFragment {
-
-		    if {[string length $node(node:parentNode)]} {
-			unset $node(node:childNodes)
-
-			# Dispatch events
-			event postMutationEvent $node(node:parentNode) DOMSubtreeModified
-
-			return {}
-		    }
-
-		    # else this is the root document node,
-		    # and we can optimize the cleanup.
-		    # No need to dispatch events.
-
-		    # First remove all command traces
-		    foreach nodecmd [info commands [namespace qualifiers [lindex $args 0]]::*] {
-			trace remove command $nodecmd delete [namespace code [list Node:Delete $nodecmd]]
-		    }
-
-		    namespace delete [namespace qualifiers [lindex $args 0]]
-		}
-
-		documentType {
-		    trace remove command [lindex $args 0] delete [namespace code [list DocumentType:Delete [lindex $args 0]]]
-		    rename [lindex $args 0] {}
-		    unset [lindex $args 0]
-		}
-
-		element {
-		    # First make sure the node is removed from the tree
-		    if {[string length $node(node:parentNode)]} {
-			node removeChild $node(node:parentNode) [lindex $args 0]
-		    }
-		    unset $node(node:childNodes)
-		    unset $node(element:attributeList)
-		    unset node
-		    set name [lindex $args 0]
-		    trace remove command $name delete [namespace code [list Node:Delete $name]]
-		    rename $name {}
-
-		    # Don't dispatch events here -
-		    # already done by removeChild
-		}
-
-		event {
-		    set name [lindex $args 0]
-		    trace remove command $name delete [namespace code [list Node:Delete $name]]
-		    rename $name {}
-		    unset node
-		}
-
-		default {
-		    # Store the parent for later
-		    set parent $node(node:parentNode)
-
-		    # First make sure the node is removed from the tree
-		    if {[string length $node(node:parentNode)]} {
-			node removeChild $node(node:parentNode) [lindex $args 0]
-		    }
-		    unset node
-		    set name [lindex $args 0]
-		    trace remove command $name delete [namespace code [list Node:Delete $name]]
-		    rename $name {}
-
-		    # Dispatch events
-		    event postMutationEvent $parent DOMSubtreeModified
-
-		}
-
-	    }
-
-	    return {}
-
-	}
-
-	isNode {
-	    # isNode - non-standard method
-	    # Sometimes it is useful to check if an arbitrary string
-	    # refers to a DOM node
-
-	    upvar #0 [lindex $args 0] node
-
-	    if {![info exists node]} {
-		return 0
-	    } elseif {[info exists node(node:nodeType)]} {
-		return 1
-	    } else {
-		return 0
-	    }
-	}
-
-	parse {
-
-	    # This implementation uses TclXML version 2.0.
-	    # TclXML can choose the best installed parser.
-
-	    if {[llength $args] < 1} {
-		return -code error "wrong # args: should be dom::DOMImplementation parse xml ?args...?"
-	    }
-
-	    array set opts {-parser {} -progresscommand {} -chunksize 8196}
-	    if {[catch {array set opts [lrange $args 1 end]}]} {
-		return -code error "bad configuration options"
-	    }
-
-	    # Create a state array for this parse session
-	    set state [namespace current]::parse[incr DOMImplementationCounter]
-	    array set $state [array get opts -*]
-	    array set $state [list progCounter 0]
-	    set errorCleanup {}
-
-	    if {[string length $opts(-parser)]} {
-		set parserOpt [list -parser $opts(-parser)]
-	    } else {
-		set parserOpt {}
-	    }
-	    if {[catch {package require xml} version]} {
-		eval $errorCleanup
-		return -code error "unable to load XML parsing package"
-	    }
-	    set parser [eval xml::parser $parserOpt]
-
-	    $parser configure \
-		-elementstartcommand [namespace code [list ParseElementStart $state]]	\
-		-elementendcommand [namespace code [list ParseElementEnd $state]]	\
-		-characterdatacommand [namespace code [list ParseCharacterData $state]] \
-		-processinginstructioncommand [namespace code [list ParseProcessingInstruction $state]] \
-		-commentcommand [namespace code [list ParseComment $state]] \
-		-entityreferencecommand [namespace code [list ParseEntityReference $state]] \
-		-xmldeclcommand [namespace code [list ParseXMLDeclaration $state]] \
-		-doctypecommand [namespace code [list ParseDocType $state]] \
-		-final 1
-
-	    # Create top-level document
-	    array set $state [list docNode [DOMImplementation create]]
-	    array set $state [list current [lindex [array get $state docNode] 1]]
-
-	    # Parse data
-	    # Bug in TclExpat - doesn't handle non-final inputs
-	    if {0 && [string length $opts(-progresscommand)]} {
-		$parser configure -final false
-		while {[string length [lindex $args 0]]} {
-		    $parser parse [string range [lindex $args 0] 0 $opts(-chunksize)]
-		    set args [lreplace $args 0 0 \
-			[string range [lindex $args 0] $opts(-chunksize) end]]
-		    uplevel #0 $opts(-progresscommand)
-		}
-		$parser configure -final true
-	    } elseif {[catch {$parser parse [lindex $args 0]} err]} {
-		catch {rename $parser {}}
-		catch {unset $state}
-		return -code error $err
-	    }
-
-	    # Free data structures which are no longer required
-	    $parser free
-	    catch {rename $parser {}}
-
-	    set doc [lindex [array get $state docNode] 1]
-	    unset $state
-	    return $doc
-
-	}
-
-	selectNode {
-	    # Non-standard method
-	    # Returns nodeset in the given document matching an XPath expression
-
-	    if {[llength $args] != 2} {
-		return -code error "wrong # args: should be dom::DOMImplementation selectNode token xpath"
-	    }
-
-	    package require xpath
-
-	    return [XPath:SelectNode [lindex $args 0] [lindex $args 1]]
-	}
-
-	serialize {
-
-	    if {[llength $args] < 1} {
-		return -code error "wrong # args: should be dom::DOMImplementation serialize token"
-	    }
-
-	    upvar #0 [lindex $args 0] node
-
-	    return [eval [list Serialize:$node(node:nodeType)] $args]
-
-	}
-
-	trim {
-
-	    # Removes textNodes that only contain white space
-
-	    if {[llength $args] != 1} {
-		return -code error "wrong # args: should be dom::DOMImplementation trim token"
-	    }
-
-	    Trim [lindex $args 0]
-
-	    # Dispatch DOMSubtreeModified event once here?
-
-	    return {}
-
-	}
-
-	default {
-	    return -code error "unknown method \"$method\""
-	}
-
-    }
-
-    return {}
-}
-
-namespace eval dom::tcl {
-    foreach method {hasFeature createDocument create createDocumentType createNode destroy isNode parse selectNode serialize trim} {
-	proc $method args "eval [namespace current]::DOMImplementation $method \$args"
-    }
-}
-
-# dom::tcl::Document:Delete --
-#
-#	Handle destruction of a document
-#
-# Arguments:
-#	name	document token
-#	old	)
-#	new	) args added by trace command
-#	op	)
-
-proc dom::tcl::Document:Delete {name old new op} {
-    DOMImplementation destroy $name
-    return {}
-}
-
-# dom::tcl::document --
-#
-#	Functions for a document node.
-#
-# Arguments:
-#	method	method to invoke
-#	token	token for node
-#	args	arguments for method
-#
-# Results:
-#	Depends on method used.
-
-namespace eval dom::tcl {
-    variable documentOptionsRO doctype|implementation|documentElement
-    variable documentOptionsRW actualEncoding|encoding|standalone|version
-}
-
-proc dom::tcl::document {method token args} {
-    variable documentOptionsRO
-    variable documentOptionsRW
-
-    upvar #0 $token node
-
-    set result {}
-
-    switch -- $method {
-	cget {
-	    if {[llength $args] != 1} {
-		return -code error "wrong # args: should be \"dom::document method token ?args ...?\""
-	    }
-	    if {[regexp [format {^-(%s)$} $documentOptionsRO] [lindex $args 0] discard option]} {
-		return $node(document:$option)
-	    } elseif {[regexp [format {^-(%s)$} $documentOptionsRW] [lindex $args 0] discard option]} {
-		switch -- $option {
-		    encoding -
-		    version -
-		    standalone {
-			array set xmldecl $node(document:xmldecl)
-			return $xmldecl($option)
-		    }
-		    default {
-			return $node(document:$option)
-		    }
-		}
-	    } else {
-		return -code error "bad option \"[lindex $args 0]\""
-	    }
-	}
-	configure {
-	    if {[llength $args] == 1} {
-		return [document cget $token [lindex $args 0]]
-	    } elseif {[expr [llength $args] % 2]} {
-		return -code error "no value specified for option \"[lindex $args end]\""
-	    } else {
-		foreach {option value} $args {
-		    if {[regexp [format {^-(%s)$} $documentOptionsRW] $option discard opt]} {
-			switch -- $opt {
-			    encoding {
-				catch {unset xmldecl}
-				array set xmldecl $node(document:xmldecl)
-				set xmldecl(encoding) $value
-				set node(document:xmldecl) [array get xmldecl]
-			    }
-			    standalone {
-				if {[string is boolean $value]} {
-				    catch {unset xmldecl}
-				    array set xmldecl $node(document:xmldecl)
-				    if {[string is true $value]} {
-					set xmldecl(standalone) yes
-				    } else {
-					set xmldecl(standalone) no
-				    }
-				    set node(document:xmldecl) [array get xmldecl]
-				} else {
-				    return -code error "unsupported value for option \"$option\" - must be boolean"
-				}
-			    }
-			    version {
-				if {$value == "1.0"} {
-				    catch {unset xmldecl}
-				    array set xmldecl $node(document:xmldecl)
-				    set xmldecl(version) $value
-				    set node(document:xmldecl) [array get xmldecl]
-				} else {
-				    return -code error "unsupported value for option \"$option\""
-				}
-			    }
-			    default {
-				set node(document:$opt) $value
-			    }
-			}
-		    } elseif {[regexp [format {^-(%s)$} $documentOptionsRO] $option discard opt]} {
-			return -code error "attribute \"$option\" is read-only"
-		    } else {
-			return -code error "bad option \"$option\""
-		    }
-		}
-	    }
-	}
-
-	createElement {
-	    if {[llength $args] != 1} {
-		return -code error "wrong # args: should be \"document createElement token name\""
-	    }
-
-	    # Check that the element name is kosher
-	    if {![regexp ^$::xml::Name\$ [lindex $args 0]]} {
-		return -code error "invalid element name \"[lindex $args 0]\""
-	    }
-
-	    # Invoke internal factory function
-	    set result [CreateElement $token [lindex $args 0] {}]
-
-	}
-	createDocumentFragment {
-	    if {[llength $args]} {
-		return -code error "wrong # args: should be \"document createDocumentFragment token\""
-	    }
-
-	    set result [CreateGeneric $token node:nodeType documentFragment node:nodeName #document-fragment node:nodeValue {}]
-	}
-	createTextNode {
-	    if {[llength $args] != 1} {
-		return -code error "wrong # args: should be \"document createTextNode token text\""
-	    }
-
-	    set result [CreateTextNode $token [lindex $args 0]]
-	}
-	createComment {
-	    if {[llength $args] != 1} {
-		return -code error "wrong # args: should be \"document createComment token data\""
-	    }
-
-	    set result [CreateGeneric $token node:nodeType comment node:nodeName #comment node:nodeValue [lindex $args 0]]
-	}
-	createCDATASection {
-	    if {[llength $args] != 1} {
-		return -code error "wrong # args: should be \"document createCDATASection token data\""
-	    }
-
-	    set result [CreateTextNode $token [lindex $args 0]]
-	    node configure $result -cdatasection 1
-	}
-	createProcessingInstruction {
-	    if {[llength $args] != 2} {
-		return -code error "wrong # args: should be \"document createProcessingInstruction token target data\""
-	    }
-
-	    set result [CreateGeneric $token node:nodeType processingInstruction \
-		    node:nodeName [lindex $args 0] node:nodeValue [lindex $args 1]]
-	}
-	createAttribute {
-	    if {[llength $args] != 1} {
-		return -code error "wrong # args: should be \"document createAttributes token name\""
-	    }
-
-	    # Check that the attribute name is kosher
-	    if {![regexp ^$::xml::Name\$ [lindex $args 0]]} {
-		return -code error "invalid attribute name \"[lindex $args 0]\""
-	    }
-
-	    set result [CreateGeneric $token node:nodeType attribute node:nodeName [lindex $args 0]]
-	}
-	createEntity {
-	    set result [CreateGeneric $token node:nodeType entity]
-	}
-	createEntityReference {
-	    if {[llength $args] != 1} {
-		return -code error "wrong # args: should be \"document createEntityReference token name\""
-	    }
-	    set result [CreateGeneric $token node:nodeType entityReference node:nodeName [lindex $args 0]]
-	}
-
-	importNode {
-	    # Introduced in DOM Level 2
-
-	    if {[llength $args] < 1} {
-		return -code error "wrong # args: should be \"importNode token ?-deep boolean?\""
-	    }
-	    array set opts {
-		-deep 1
-	    }
-	    array set opts [lrange $args 1 end]
-	    set opts(-deep) [Boolean $opts(-deep)]
-
-	    if {[namespace qualifiers [lindex $args 0]] == [namespace qualifiers $token]} {
-		return -code error "source node \"[lindex $args 0]\" is in the same document"
-	    }
-
-	    switch [node cget [lindex $args 0] -nodeType] {
-		document -
-		documentType {
-		    return -code error "node type \"[node cget [lindex $args 0] -type]\" cannot be imported"
-		}
-		documentFragment {
-		    set result [document createDocumentFragment $token]
-		    if {$opts(-deep)} {
-			foreach child [node children [lindex $args 0]] {
-			    $result appendChild [$token importNode $child -deep 1]
-			}
-		    }
-		}
-		element {
-		    set result [CreateElement {} [node cget [lindex $args 0] -nodeName] [array get [node cget [lindex $args 0] -attributes]] -document $token]
-		    if {$opts(-deep)} {
-			foreach child [node children [lindex $args 0]] {
-			    $result appendChild [$token importNode $child -deep 1]
-			}
-		    }
-		}
-		textNode {
-		    set result [CreateTextNode {} [node cget [lindex $args 0] -nodeValue] -document $token]
-		}
-		attribute -
-		processingInstruction -
-		comment {
-		    set result [CreateGeneric {} -document $token node:nodeType [node cget [lindex $args 0] -nodeType] node:nodeName [node cget [lindex $args 0] -nodeName] node:nodeValue [node cget [lindex $args 0] -nodeValue]]
-		}
-	    }
-	}
-
-	createElementNS {
-	    # Introduced in DOM Level 2
-
-	    if {[llength $args] != 2} {
-		return -code error "wrong # args: should be: \"createElementNS nsuri qualname\""
-	    }
-
-	    # Check that the qualified name is kosher
-	    if {[catch {foreach {prefix localname} [::xml::qnamesplit [lindex $args 1]]  break} err]} {
-		return -code error "invalid qualified name \"[lindex $args 1]\" due to \"$err\""
-	    }
-
-	    # Invoke internal factory function
-	    set result [CreateElement $token [lindex $args 1] {} -prefix $prefix -namespace [lindex $args 0] -localname $localname]
-	}
-
-	createAttributeNS {
-	    # Introduced in DOM Level 2
-
-	    return -code error "not yet implemented"
-	}
-
-	getElementsByTagNameNS {
-	    # Introduced in DOM Level 2
-
-	    return -code error "not yet implemented"
-	}
-
-	getElementsById {
-	    # Introduced in DOM Level 2
-
-	    return -code error "not yet implemented"
-	}
-
-	createEvent {
-	    # Introduced in DOM Level 2
-
-	    if {[llength $args] != 1} {
-		return -code error "wrong # args: should be \"document createEvent token type\""
-	    }
-
-	    set result [CreateEvent $token [lindex $args 0]]
-
-	}
-
-	getElementsByTagName {
-	    if {[llength $args] < 1} {
-		return -code error "wrong # args: should be \"document getElementsByTagName token what\""
-	    }
-
-	    return [eval Element:GetByTagName [list $token [lindex $args 0]] \
-		    [lrange $args 1 end]]
-	}
-
-	default {
-	    return -code error "unknown method \"$method\""
-	}
-
-    }
-
-    # Dispatch events
-
-    # Node insertion events are generated here instead of the
-    # internal factory procedures.  This is because the factory
-    # procedures are meant to be mean-and-lean during the parsing
-    # phase, and dispatching events at that time would be an
-    # excessive overhead.  The factory methods here are pretty
-    # heavyweight anyway.
-
-    if {[string match create* $method] && [string compare $method "createEvent"]} {
-
-	event postMutationEvent $result DOMNodeInserted -relatedNode $token
-	event postMutationEvent $result DOMNodeInsertedIntoDocument
-	event postMutationEvent $token DOMSubtreeModified
-
-    }
-
-    return $result
-}
-
-###	Factory methods
-###
-### These are lean-and-mean for fastest possible tree building
-
-# dom::tcl::CreateElement --
-#
-#	Append an element to the given (parent) node (if any)
-#
-# Arguments:
-#	token	parent node (if empty -document option is mandatory)
-#	name	element name (no checking performed here)
-#	aList	attribute list
-#	args	configuration options
-#
-# Results:
-#	New node created, parent optionally modified
-
-proc dom::tcl::CreateElement {token name aList args} {
-    array set opts $args
-
-    if {[string length $token]} {
-	upvar #0 $token parent
-	upvar #0 [namespace qualifiers $token]::Document document
-	set child [namespace qualifiers $token]::node[incr document(counter)]
-    } elseif {[info exists opts(-document)]} {
-	upvar #0 $opts(-document) document
-	set child [namespace qualifiers $opts(-document)]::node[incr document(counter)]
-    } else {
-	return -code error "no parent or document specified"
-    }
-
-    upvar #0 $child new
-
-    # Create the new node
-    # NB. normally we'd use Node:create here,
-    # but inline it instead for performance
-    array set new [list \
-	    node:parentNode $token		\
-	    node:childNodes ${child}var		\
-	    node:nodeType element		\
-	    node:nodeName $name			\
-	    node:namespaceURI {}		\
-	    node:prefix {}			\
-	    node:localName $name		\
-	    node:nodeValue {}			\
-	    element:attributeList ${child}arr	\
-	    element:attributeNodes {}		\
-    ]
-
-    catch {set new(node:namespaceURI) $opts(-namespace)}
-    catch {set new(node:localName) $opts(-localname)}
-    catch {set new(node:prefix) $opts(-prefix)}
-
-    # Initialise associated variables
-    set ${child}var {}
-    array set ${child}arr $aList
-    catch {
-	foreach {ns nsAttrList} $opts(-namespaceattributelists) {
-	    foreach {attrName attrValue} $nsAttrList {
-		array set ${child}arr [list $ns^$attrName $attrValue]
-	    }
-	}
-    }
-
-    # Update parent record
-
-    # Does this element qualify as the document element?
-    # If so, then has a document element already been set?
-
-    if {[string length $token] && 
-	[string equal $parent(node:nodeType) document]} {
-
-	if {$token == $parent(documentFragment:masterDoc)} {
-	    if {[info exists parent(document:documentElement)] && \
-		    [string length $parent(document:documentElement)]} {
-		# Do not attach to the tree
-		set new(node:parentNode) {}
-	    } else {
-
-		# Check against document type decl
-		if {[string length $parent(document:doctype)]} {
-		    upvar #0 $parent(document:doctype) doctypedecl
-		    if {[string compare $name $doctypedecl(doctype:name)]} {
-			return -code error "mismatch between root element type in document type declaration \"$doctypedecl(doctype:name)\" and root element \"$name\""
-		    }
-
-		} else {
-		    # Synthesize document type declaration
-		    set doctype [CreateDocType $name {} {}]
-		    set document(document:doctype) $doctype
-		}
-
-		set parent(document:documentElement) $child
-		catch {lappend $parent(node:childNodes) $child}
-	    }
-	} else {
-	    catch {lappend $parent(node:childNodes) $child}
-	}
-    } else {
-	catch {lappend $parent(node:childNodes) $child}
-    }
-
-    proc $child {method args} "return \[eval [namespace current]::node \[list \$method\] $child \$args\]"
-    trace add command $child delete [namespace code [list Node:Delete $child]]
-
-    return $child
-}
-
-# dom::tcl::CreateTextNode --
-#
-#	Append a textNode node to the given (parent) node (if any).
-#
-#	This factory function can also be performed by
-#	CreateGeneric, but text nodes are created so often
-#	that this specific factory procedure speeds things up.
-#
-# Arguments:
-#	token	parent node (if empty -document option is mandatory)
-#	text	initial text
-#	args	additional configuration options
-#
-# Results:
-#	New node created, parent optionally modified
-
-proc dom::tcl::CreateTextNode {token text args} {
-    array set opts $args
-
-    if {[string length $token]} {
-	upvar #0 $token parent
-	upvar #0 [namespace qualifiers $token]::Document document
-	set child [namespace qualifiers $token]::node[incr document(counter)]
-    } elseif {[info exists opts(-document)]} {
-	upvar #0 $opts(-document) document
-	set child [namespace qualifiers $opts(-document)]::node[incr document(counter)]
-    } else {
-	return -code error "no parent or document specified"
-    }
-
-    upvar #0 $child new
-
-    # Create the new node
-    # NB. normally we'd use Node:create here,
-    # but inline it instead for performance
-
-    # Text nodes never have children, so don't create a variable
-
-    array set new [list \
-	    node:parentNode $token		\
-	    node:childNodes ${child}var		\
-	    node:nodeType textNode		\
-	    node:nodeValue $text		\
-	    node:nodeName #text			\
-	    node:cdatasection 0			\
-    ]
-
-    set ${child}var {}
-
-    # Update parent record
-    catch {lappend $parent(node:childNodes) $child}
-
-    proc $child {method args} "return \[eval [namespace current]::node \[list \$method\] $child \$args\]"
-    trace add command $child delete [namespace code [list Node:Delete $child]]
-
-    return $child
-}
-
-# dom::tcl::CreateGeneric --
-#
-#	This is a template used for type-specific factory procedures
-#
-# Arguments:
-#	token	parent node (if empty -document option is mandatory)
-#	args	optional values
-#
-# Results:
-#	New node created, parent modified
-
-proc dom::tcl::CreateGeneric {token args} {
-    array set opts $args
-
-    if {[string length $token]} {
-	upvar #0 $token parent
-	upvar #0 [namespace qualifiers $token]::Document document
-	set child [namespace qualifiers $token]::node[incr document(counter)]
-    } elseif {[info exists opts(-document)]} {
-	upvar #0 $opts(-document) document
-	set child [namespace qualifiers $opts(-document)]::node[incr document(counter)]
-    } else {
-	return -code error "no parent or document specified"
-    }
-    upvar #0 $child new
-
-    # Create the new node
-    # NB. normally we'd use Node:create here,
-    # but inline it instead for performance
-    array set new [eval list [list \
-	    node:parentNode $token	\
-	    node:childNodes ${child}var	] \
-	    $args			\
-    ]
-    set ${child}var {}
-
-    switch -glob -- [string length $token],$opts(node:nodeType) {
-	0,* -
-	*,attribute -
-	*,namespace {
-	    # These type of nodes are not children of their parent
-	}
-
-	default {
-	    # Update parent record
-	    lappend $parent(node:childNodes) $child
-	}
-    }
-
-    proc $child {method args} "return \[eval [namespace current]::node \[list \$method\] $child \$args\]"
-    trace add command $child delete [namespace code [list Node:Delete $child]]
-
-    return $child
-}
-
-### Specials
-
-# dom::tcl::CreateDocType --
-#
-#	Create a Document Type Declaration node.
-#
-# Arguments:
-#	name	root element type
-#	publicid	public identifier
-#	systemid	system identifier
-#	internaldtd	internal DTD subset
-#
-# Results:
-#	Returns node id of the newly created node.
-
-proc dom::tcl::CreateDocType {name publicid systemid {internaldtd {}}} {
-    if {![regexp ^$::xml::QName\$ $name]} {
-	return -code error "invalid QName \"$name\""
-    }
-
-    set nodename [namespace current]::$name
-    upvar #0 $nodename doctype
-    if {[info exists doctype]} {
-	return $nodename
-    }
-
-    if {[llength $internaldtd] == 1 && [string length [lindex $internaldtd 0]] == 0} {
-	set dtd {}
-    }
-
-    array set doctype [list \
-	    node:childNodes {} \
-	    node:nodeType documentType \
-	    node:nodeName $name \
-	    node:nodeValue {} \
-	    doctype:name $name \
-	    doctype:entities {} \
-	    doctype:notations {} \
-	    doctype:publicId $publicid \
-	    doctype:systemId $systemid \
-	    doctype:internalSubset $internaldtd \
-    ]
-
-    proc $nodename {method args} "return \[eval [namespace current]::documenttype \[list \$method\] $nodename \$args\]"
-    trace add command $nodename delete [namespace code [list DocumentType:Delete $nodename]]
-
-    return $nodename
-}
-
-# dom::tcl::documenttype --
-#
-#	Functions for a document type declaration node.
-#
-# Arguments:
-#	method	method to invoke
-#	token	token for node
-#	args	arguments for method
-#
-# Results:
-#	Depends on method used.
-
-namespace eval dom::tcl {
-    variable documenttypeOptionsRO name|entities|notations|publicId|systemId|internalSubset
-    variable documenttypeOptionsRW {}
-}
-
-proc dom::tcl::documenttype {method token args} {
-    variable documenttypeOptionsRO
-    variable documenttypeOptionsRW
-
-    upvar #0 $token node
-
-    set result {}
-
-    switch -- $method {
-	cget {
-	    if {[llength $args] != 1} {
-		return -code error "wrong # args: should be \"dom::documenttype method token ?args ...?\""
-	    }
-	    if {[regexp [format {^-(%s)$} $documenttypeOptionsRO] [lindex $args 0] discard option]} {
-		switch -- $option {
-		    name {
-			return $node(node:nodeName)
-		    }
-		    default {
-			return $node(doctype:$option)
-		    }
-		}
-	    } elseif {[regexp [format {^-(%s)$} $documenttypeOptionsRW] [lindex $args 0] discard option]} {
-		return $node(doctype:$option)
-	    } else {
-		return -code error "bad option \"[lindex $args 0]\""
-	    }
-	}
-	configure {
-	    if {[llength $args] == 1} {
-		return [documenttype cget $token [lindex $args 0]]
-	    } elseif {[expr [llength $args] % 2]} {
-		return -code error "no value specified for option \"[lindex $args end]\""
-	    } else {
-		foreach {option value} $args {
-		    if {[regexp [format {^-(%s)$} $documenttypeOptionsRW] $option discard opt]} {
-			switch -- $opt {
-			    default {
-				set node(doctype:$opt) $value
-			    }
-			}
-		    } elseif {[regexp [format {^-(%s)$} $documenttypeOptionsRO] $option discard opt]} {
-			return -code error "attribute \"$option\" is read-only"
-		    } else {
-			return -code error "bad option \"$option\""
-		    }
-		}
-	    }
-	}
-    }
-
-    return $result
-}
-
-# dom::tcl::DocumentType:Delete --
-#
-#	Handle node destruction
-#
-# Arguments:
-#	name	node token
-#	old	)
-#	new	) arguments appended by trace command
-#	op	)
-#
-# Results:
-#	Node is destroyed
-
-proc dom::tcl::DocumentType:Delete {name old new op} {
-    DOMImplementation destroy $name
-}
-
-# dom::tcl::node --
-#
-#	Functions for a general node.
-#
-#	Implements EventTarget Interface - introduced in DOM Level 2
-#
-# Arguments:
-#	method	method to invoke
-#	token	token for node
-#	args	arguments for method
-#
-# Results:
-#	Depends on method used.
-
-namespace eval dom::tcl {
-    variable nodeOptionsRO nodeType|parentNode|childNodes|firstChild|lastChild|previousSibling|nextSibling|attributes|namespaceURI|prefix|localName|ownerDocument
-    variable nodeOptionsRW nodeValue|cdatasection
-
-    # Allowing nodeName to be rw is not standard DOM.
-    # A validating implementation would have to be very careful
-    # in allowing this feature
-    if {$::dom::strictDOM} {
-	append nodeOptionsRO |nodeName
-    } else {
-	append nodeOptionsRW |nodeName
-    }
-}
-# NB. cdatasection is not a standard DOM option
-
-proc dom::tcl::node {method token args} {
-    variable nodeOptionsRO
-    variable nodeOptionsRW
-
-    upvar #0 $token node
-
-    set result {}
-
-    switch -glob -- $method {
-	cg* {
-	    # cget
-
-	    # Some read-only configuration options are computed
-	    if {[llength $args] != 1} {
-		return -code error "wrong # args: should be \"dom::node cget token option\""
-	    }
-	    if {[regexp [format {^-(%s)$} $nodeOptionsRO] [lindex $args 0] discard option]} {
-		switch $option {
-		    nodeName {
-			set result $node(node:nodeName)
-			switch $node(node:nodeType) {
-			    textNode {
-				catch {set result [expr {$node(node:cdatasection) ? "#cdata-section" : $node(node:nodeName)}]}
-			    }
-			    default {
-			    }
-			}
-		    }
-		    childNodes {
-			# How are we going to handle documentElement?
-			set result $node(node:childNodes)
-		    }
-		    firstChild {
-			upvar #0 $node(node:childNodes) children
-			switch $node(node:nodeType) {
-			    document {
-				set result [lindex $children 0]
-				catch {set result $node(document:documentElement)}
-			    }
-			    default {
-				set result [lindex $children 0]
-			    }
-			}
-		    }
-		    lastChild {
-			upvar #0 $node(node:childNodes) children
-			switch $node(node:nodeType) {
-			    document {
-				set result [lindex $children end]
-				catch {set result $node(document:documentElement)}
-			    }
-			    default {
-				set result [lindex $children end]
-			    }
-			}
-		    }
-		    previousSibling {
-			# BUG: must take documentElement into account
-			# Find the parent node
-			upvar #0 $node(node:parentNode) parent
-			upvar #0 $parent(node:childNodes) children
-			set idx [lsearch $children $token]
-			if {$idx >= 0} {
-			    set sib [lindex $children [incr idx -1]]
-			    if {[llength $sib]} {
-				set result $sib
-			    } else {
-				set result {}
-			    }
-			} else {
-			    set result {}
-			}
-		    }
-		    nextSibling {
-			# BUG: must take documentElement into account
-			# Find the parent node
-			upvar #0 $node(node:parentNode) parent
-			upvar #0 $parent(node:childNodes) children
-			set idx [lsearch $children $token]
-			if {$idx >= 0} {
-			    set sib [lindex $children [incr idx]]
-			    if {[llength $sib]} {
-				set result $sib
-			    } else {
-				set result {}
-			    }
-			} else {
-			    set result {}
-			}
-		    }
-		    attributes {
-			if {[string compare $node(node:nodeType) element]} {
-			    set result {}
-			} else {
-			    set result $node(element:attributeList)
-			}
-		    }
-		    ownerDocument {
-			if {[string compare $node(node:parentNode) {}]} {
-			    return [namespace qualifiers $token]::Document
-			} else {
-			    return $token
-			}
-		    }
-		    default {
-			return [GetField node(node:$option)]
-		    }
-		}
-	    } elseif {[regexp [format {^-(%s)$} $nodeOptionsRW] [lindex $args 0] discard option]} {
-		return [GetField node(node:$option)]
-	    } else {
-		return -code error "unknown option \"[lindex $args 0]\""
-	    }
-	}
-	co* {
-	    # configure
-
-	    if {[llength $args] == 1} {
-		return [node cget $token [lindex $args 0]]
-	    } elseif {[expr [llength $args] % 2]} {
-		return -code error "wrong \# args: should be \"::dom::node configure node option\""
-	    } else {
-		foreach {option value} $args {
-		    if {[regexp [format {^-(%s)$} $nodeOptionsRW] $option discard opt]} {
-
-			switch $opt,$node(node:nodeType) {
-			    nodeValue,textNode -
-			    nodeValue,processingInstruction {
-				# Dispatch event
-				set evid [CreateEvent $token DOMCharacterDataModified]
-				event initMutationEvent $evid DOMCharacterDataModified 1 0 {} $node(node:nodeValue) $value {} {}
-				set node(node:nodeValue) $value
-				node dispatchEvent $token $evid
-				DOMImplementation destroy $evid
-			    }
-			    default {
-				set node(node:$opt) $value
-			    }
-			}
-
-		    } elseif {[regexp [format {^-(%s)$} $nodeOptionsRO] $option discard opt]} {
-			return -code error "attribute \"$option\" is read-only"
-		    } else {
-			return -code error "unknown option \"$option\""
-		    }
-		}
-	    }
-	}
-
-	in* {
-
-	    # insertBefore
-
-	    # Previous and next sibling relationships are OK, 
-	    # because they are dynamically determined
-
-	    if {[llength $args] < 1 || [llength $args] > 2} {
-		return -code error "wrong # args: should be \"dom::node insertBefore token new ?ref?\""
-	    }
-
-	    upvar #0 [lindex $args 0] newChild
-	    if {[string compare [namespace qualifiers [lindex $args 0]] [namespace qualifiers $token]]} {
-		return -code error "new node must be in the same document"
-	    }
-
-	    switch [llength $args] {
-		1 {
-		    # Append as the last node
-		    if {[string length $newChild(node:parentNode)]} {
-			node removeChild $newChild(node:parentNode) [lindex $args 0]
-		    }
-		    lappend $node(node:childNodes) [lindex $args 0]
-		    set newChild(node:parentNode) $token
-		}
-		2 {
-		    upvar #0 [lindex $args 1] refChild
-
-		    if {[string compare [namespace qualifiers [lindex $args 1]] [namespace qualifiers [lindex $args 0]]]} {
-			return -code error "nodes must be in the same document"
-		    }
-		    set idx [lsearch [set $node(node:childNodes)] [lindex $args 1]]
-		    if {$idx < 0} {
-			return -code error "no such reference child"
-		    } else {
-
-			# Remove from previous parent
-			if {[string length $newChild(node:parentNode)]} {
-			    node removeChild $newChild(node:parentNode) [lindex $args 0]
-			}
-
-			# Insert into new node
-			set $node(node:childNodes) \
-				[linsert [set $node(node:childNodes)] $idx [lindex $args 0]]
-			set newChild(node:parentNode) $token
-		    }
-		}
-	    }
-
-	    event postMutationEvent [lindex $args 0] DOMNodeInserted -relatedNode $token
-	    FireNodeInsertedEvents [lindex $args 0]
-	    event postMutationEvent $token DOMSubtreeModified
-
-	    set result [lindex $args 0]
-
-	}
-
-	rep* {
-
-	    # replaceChild
-
-	    if {[llength $args] != 2} {
-		return -code error "wrong # args: should be \"dom::node replaceChild token new old\""
-	    }
-
-	    upvar #0 [lindex $args 0] newChild
-	    upvar #0 [lindex $args 1] oldChild
-	    upvar #0 $node(node:childNodes) children
-
-	    # Find where to insert new child
-	    set idx [lsearch $children [lindex $args 1]]
-	    if {$idx < 0} {
-		return -code error "no such old child"
-	    }
-
-	    # Remove new child from current parent
-	    if {[string length $newChild(node:parentNode)]} {
-		node removeChild $newChild(node:parentNode) [lindex $args 0]
-	    }
-
-	    set children \
-		[lreplace $children $idx $idx [lindex $args 0]]
-	    set newChild(node:parentNode) $token
-
-	    # Update old child to reflect lack of parentage
-	    set oldChild(node:parentNode) {}
-
-	    set result [lindex $args 1]
-
-	    event postMutationEvent [lindex $args 0] DOMNodeInserted -relatedNode $token
-	    FireNodeInsertedEvents [lindex $args 0]
-	    event postMutationEvent $token DOMSubtreeModified
-
-	}
-
-	removeC* {
-
-	    # removeChild
-
-	    if {[llength $args] != 1} {
-		return -code error "wrong # args: should be \"dom::node removeChild token child\""
-	    }
-	    upvar #0 [lindex $args 0] oldChild
-	    if {[string compare [namespace qualifiers [lindex $args 0]] [namespace qualifiers $token]]} {
-		return -code error "node \"[lindex $args 0]\" is not a child"
-	    }
-
-	    # Remove the child from the parent
-	    upvar #0 $node(node:childNodes) myChildren
-	    if {[set idx [lsearch $myChildren [lindex $args 0]]] < 0} {
-		return -code error "node \"[lindex $args 0]\" is not a child"
-	    }
-	    set myChildren [lreplace $myChildren $idx $idx]
-
-	    # Update the child to reflect lack of parentage
-	    set oldChild(node:parentNode) {}
-
-	    set result [lindex $args 0]
-
-	    # Event propagation has a problem here:
-	    # Nodes that until recently were ancestors may
-	    # want to capture the event, but we've just removed
-	    # the parentage information.  They get a DOMSubtreeModified
-	    # instead.
-	    event postMutationEvent [lindex $args 0] DOMNodeRemoved -relatedNode $token
-	    FireNodeRemovedEvents [lindex $args 0]
-	    event postMutationEvent $token DOMSubtreeModified
-
-	}
-
-	ap* {
-
-	    # appendChild
-
-	    if {[llength $args] != 1} {
-		return -code error "wrong # args: should be \"dom::node appendChild token child\""
-	    }
-
-	    # Add to new parent
-	    node insertBefore $token [lindex $args 0]
-
-	    set result [lindex $args 0]
-
-	}
-
-	hasChildNodes {
-	    set result [Min 1 [llength [set $node(node:childNodes)]]]
-	}
-
-	isSameNode {
-	    # Introduced in DOM Level 3
-	    switch [llength $args] {
-		1 {
-		    return [expr {$token == [lindex $args 0]}]
-		}
-		default {
-		    return -code error "wrong # args: should be \"dom::node isSameNode token ref\""
-		}
-	    }
-	}
-
-	cl* {
-	    # cloneNode
-
-	    # May need to pay closer attention to generation of events here
-
-	    set deep 0
-	    switch [llength $args] {
-		0 {
-		}
-		2 {
-		    foreach {opt value} $args {
-			switch -- $opt {
-			    -deep {
-				set deep [Boolean $value]
-			    }
-			    default {
-				return -code error "bad option \"$opt\""
-			    }
-			}
-		    }
-		}
-		default {
-		    return -code error "wrong # args: should be \"dom::node cloneNode token ?-deep boolean?\""
-		}
-	    }
-
-	    switch $node(node:nodeType) {
-		element {
-		    set result [CreateElement {} $node(node:nodeName) [array get $node(element:attributeList)] -document [namespace qualifiers $token]::Document]
-		    if {$deep} {
-			foreach child [set $node(node:childNodes)] {
-			    node appendChild $result [node cloneNode $child -deep 1]
-			}
-		    }
-		}
-		textNode {
-		    set result [CreateTextNode {} $node(node:nodeValue) -document [namespace qualifiers $token]::Document]
-		}
-		document {
-		    set result [DOMImplementation create]
-		    upvar #0 $result clonedDoc
-		    array set clonedDoc [array get node document:doctype]
-		    if {$deep} {
-			foreach child [set $node(node:childNodes)] {
-			    node appendChild $result [document importNode $result $child -deep 1]
-			}
-		    }
-		}
-		documentFragment -
-		default {
-		    set result [CreateGeneric {} node:nodeType $node(node:nodeType) -document [namespace qualifiers $token]::Document]
-		    if {$deep} {
-			foreach child [set $node(node:childNodes)] {
-			    node appendChild $result [node cloneNode $child -deep 1]
-			}
-		    }
-		}
-	    }
-	}
-
-	ch* {
-	    # children -- non-standard method
-
-	    # If this is a textNode, then catch the error
-	    set result {}
-	    catch {set result [set $node(node:childNodes)]}
-
-	}
-
-	par* {
-	    # parent -- non-standard method
-
-	    return $node(node:parentNode)
-
-	}
-
-	pat* {
-	    # path -- non-standard method
-
-	    for {
-		set ancestor $token
-		upvar #0 $token ancestorNd
-		set result {}
-	    } {[string length $ancestorNd(node:parentNode)]} {
-		set ancestor $ancestorNd(node:parentNode)
-		upvar #0 $ancestor ancestorNd
-	    } {
-		set result [linsert $result 0 $ancestor]
-	    }
-	    # The last node is the document node
-	    set result [linsert $result 0 $ancestor]
-
-	}
-
-	createNode {
-	    # createNode -- non-standard method
-
-	    # Creates node(s) in this document given an XPath expression.
-	    # Relative location paths have this node as their initial context.
-
-	    if {[llength $args] != 1} {
-		return -code error "wrong # args: should be \"dom::node createNode token path\""
-	    }
-
-	    package require xpath
-
-	    return [XPath:CreateNode $token [lindex $args 0]]
-	}
-
-	selectNode {
-	    # selectNode -- non-standard method
-
-	    # Returns nodeset in this document matching an XPath expression.
-	    # Relative location paths have this node as their initial context.
-
-	    if {[llength $args] != 1} {
-		return -code error "wrong # args: should be \"dom::node selectNode token path\""
-	    }
-
-	    package require xpath
-
-	    return [XPath:SelectNode $token [lindex $args 0]]
-	}
-
-	stringValue {
-	    # stringValue -- non-standard method
-	    # Returns string value of a node, as defined by XPath Rec.
-
-	    if {[llength $args] > 0} {
-		return -code error "wrong # args: should be \"dom::node stringValue token\""
-	    }
-
-	    switch $node(node:nodeType) {
-		document -
-		documentFragment -
-		element {
-		    set value {}
-		    foreach child [set $node(node:childNodes)] {
-			switch [node cget $child -nodeType] {
-			    element -
-			    textNode {
-				append value [node stringValue $child]
-			    }
-			    default {
-				# Other nodes are not considered
-			    }
-			}
-		    }
-		    return $value
-		}
-		attribute -
-		textNode -
-		processingInstruction -
-		comment {
-		    return $node(node:nodeValue)
-		}
-		default {
-		    return {}
-		}
-	    }
-
-	}
-
-	addEv* {
-	    # addEventListener -- introduced in DOM Level 2
-
-	    if {[llength $args] < 1} {
-		return -code error "wrong # args: should be \"dom::node addEventListener token type ?listener? ?option value...?\""
-	    }
-
-	    set type [lindex $args 0]
-	    set args [lrange $args 1 end]
-	    set listener [lindex $args 0]
-	    if {[llength $args] == 1} {
-		set args {}
-	    } elseif {[llength $args] > 1} {
-		if {[string match -* $listener]} {
-		    set listener {}
-		} else {
-		    set args [lrange $args 1 end]
-		}
-	    }
-	    array set opts {-usecapture 0}
-	    if {[catch {array set opts $args}]} {
-		return -code error "missing value for option \"[lindex $args end]\""
-	    }
-	    set opts(-usecapture) [Boolean $opts(-usecapture)]
-	    set listenerType [expr {$opts(-usecapture) ? "capturer" : "listener"}]
-
-	    if {[string length $listener]} {
-		if {![info exists node(event:$type:$listenerType)] || \
-			[lsearch $node(event:$type:$listenerType) $listener] < 0} {
-		    lappend node(event:$type:$listenerType) $listener
-		}
-		# else avoid registering same listener twice
-	    } else {
-		# List all listeners
-		set result {}
-		catch {set result $node(event:$type:$listenerType)}
-		return $result
-	    }
-	}
-
-	removeE* {
-	    # removeEventListener -- introduced in DOM Level 2
-
-	    if {[llength $args] < 2} {
-		return -code error "wrong # args: should be \"dom::node removeEventListener token type listener ?option value...?\""
-	    }
-
-	    set type [lindex $args 0]
-	    set listener [lindex $args 1]
-	    array set opts {-usecapture 0}
-	    array set opts [lrange $args 2 end]
-	    set opts(-usecapture) [Boolean $opts(-usecapture)]
-	    set listenerType [expr {$opts(-usecapture) ? "capturer" : "listener"}]
-
-	    set idx [lsearch $node(event:$type:$listenerType) $listener]
-	    if {$idx >= 0} {
-		set node(event:$type:$listenerType) [lreplace $node(event:$type:$listenerType) $idx $idx]
-	    }
-
-	}
-
-	disp* {
-	    # dispatchEvent -- introduced in DOM Level 2
-
-	    # This is where the fun happens!
-	    # Check to see if there one or more event listener,
-	    # if so trigger the listener(s).
-	    # Then pass the event up to the ancestor.
-	    # This may be modified by event capturing and bubbling.
-
-	    if {[llength $args] != 1} {
-		return -code error "wrong # args: should be \"dom::node dispatchEvent token eventnode\""
-	    }
-
-	    set eventId [lindex $args 0]
-	    upvar #0 $eventId event
-	    set type $event(type)
-
-	    if {![string length $event(eventPhase)]} {
-
-		# This is the initial dispatch of the event.
-		# First trigger any capturing event listeners
-		# Starting from the root, proceed downward
-
-		set event(eventPhase) capturing_phase
-		set event(target) $token
-
-		# DOM L2 specifies that the ancestors are determined
-		# at the moment of event dispatch, so using a static
-		# list is the correct thing to do
-
-		foreach ancestor [lreplace [node path $token] end end] {
-		    set event(currentNode) $ancestor
-
-		    upvar #0 $ancestor ancNode
-
-		    if {[info exists ancNode(event:$type:capturer)]} {
-			foreach capturer $ancNode(event:$type:capturer) {
-			    if {[catch {uplevel #0 $capturer [list $eventId]} capturerError]} {
-				bgerror "error in capturer \"$capturerError\""
-			    }
-			}
-
-			# A listener may stop propagation,
-			# but we check here to let all of the
-			# listeners at that level complete
-
-			if {$event(cancelable) && $event(stopPropagation)} {
-			    break
-			}
-		    }
-		}
-
-		# Prepare for next phase
-		set event(eventPhase) at_target
-
-	    }
-
-	    set event(currentNode) $token
-
-	    if {[info exists node(event:$type:listener)]} {
-		foreach listener $node(event:$type:listener) {
-		    if {[catch {uplevel #0 $listener [list $eventId]} listenerError]} {
-			bgerror "error in listener \"$listenerError\""
-		    }
-		}
-	    }
-
-	    set event(eventPhase) bubbling_phase
-
-	    # Now propagate the event
-	    if {$event(cancelable) && $event(stopPropagation)} {
-		# Event has been cancelled
-	    } elseif {[llength $node(node:parentNode)]} {
-		# Go ahead and propagate
-		node dispatchEvent $node(node:parentNode) $eventId
-	    }
-
-	    set event(dispatched) 1
-	}
-
-	default {
-	    return -code error "unknown method \"$method\""
-	}
-
-    }
-
-    return $result
-}
-
-# dom::tcl::Node:create --
-#
-#	Generic node creation.
-#	See also CreateElement, CreateTextNode, CreateGeneric.
-#
-# Arguments:
-#	pVar	array in caller which contains parent details
-#	args	configuration options
-#
-# Results:
-#	New child node created.
-
-proc dom::tcl::Node:create {pVar args} {
-    upvar #0 $pVar parent
-
-    array set opts {-name {} -value {}}
-    array set opts $args
-
-    upvar #0 [namespace qualifiers $pVar]::Document document
-
-    # Create new node
-    if {![info exists opts(-id)]} {
-	set opts(-id) node[incr document(counter)]
-    }
-    set child [namespace qualifiers $pVar]::$opts(-id)
-    upvar #0 $child new
-    array set new [list \
-	    node:parentNode $opts(-parent)	\
-	    node:childNodes ${child}var		\
-	    node:nodeType $opts(-type)		\
-	    node:nodeName $opts(-name)		\
-	    node:nodeValue $opts(-value)	\
-	    element:attributeList ${child}arr	\
-    ]
-    set ${child}var {}
-    array set ${child}arr {}
-
-    # Update parent node
-    if {![info exists parent(document:documentElement)]} {
-	lappend parent(node:childNodes) $child
-    }
-
-    proc $child {method args} "return \[eval [namespace current]::node \[list \$method\] $child \$args\]"
-    trace add command $child delete [namespace code [list Node:Delete $child]]
-
-    return $child
-}
-
-# dom::tcl::Node:set --
-#
-#	Generic node update
-#
-# Arguments:
-#	token	node token
-#	args	configuration options
-#
-# Results:
-#	Node modified.
-
-proc dom::tcl::Node:set {token args} {
-    upvar #0 $token node
-
-    foreach {key value} $args {
-	set node($key) $value
-    }
-
-    return {}
-}
-
-# dom::tcl::Node:Delete --
-#
-#	Handle node destruction
-#
-# Arguments:
-#	name	node token
-#	old	)
-#	new	) arguments appended by trace command
-#	op	)
-#
-# Results:
-#	Node is destroyed
-
-proc dom::tcl::Node:Delete {name old new op} {
-    if {[catch {DOMImplementation destroy $name} ret]} {
-	# Document has been deleted... namespace has been destroyed
-    } else {
-	return $ret
-    }
-}
-
-# dom::tcl::FireNodeInsertedEvents --
-#
-#	Recursively descend the tree triggering DOMNodeInserted
-#	events as we go.
-#
-# Arguments:
-#	nodeid	Node ID
-#
-# Results:
-#	DOM L2 DOMNodeInserted events posted
-
-proc dom::tcl::FireNodeInsertedEvents nodeid {
-    event postMutationEvent $nodeid DOMNodeInsertedIntoDocument
-    foreach child [node children $nodeid] {
-	FireNodeInsertedEvents $child
-    }
-
-    return {}
-}
-
-# dom::tcl::FireNodeRemovedEvents --
-#
-#	Recursively descend the tree triggering DOMNodeRemoved
-#	events as we go.
-#
-# Arguments:
-#	nodeid	Node ID
-#
-# Results:
-#	DOM L2 DOMNodeRemoved events posted
-
-proc dom::tcl::FireNodeRemovedEvents nodeid {
-    event postMutationEvent $nodeid DOMNodeRemovedFromDocument
-    foreach child [node children $nodeid] {
-	FireNodeRemovedEvents $child
-    }
-
-    return {}
-}
-
-# dom::tcl::element --
-#
-#	Functions for an element.
-#
-# Arguments:
-#	method	method to invoke
-#	token	token for node
-#	args	arguments for method
-#
-# Results:
-#	Depends on method used.
-
-namespace eval dom::tcl {
-    variable elementOptionsRO tagName|empty
-    variable elementOptionsRW {}
-}
-
-proc dom::tcl::element {method token args} {
-    variable elementOptionsRO
-    variable elementOptionsRW
-
-    upvar #0 $token node
-
-    if {[string compare $node(node:nodeType) "element"]} {
-	return -code error "malformed node token \"$token\""
-    }
-    set result {}
-
-    switch -- $method {
-
-	cget {
-	    # Some read-only configuration options are computed
-	    if {[llength $args] != 1} {
-		return -code error "wrong # args: should be \"dom::element cget token option\""
-	    }
-	    if {[regexp [format {^-(%s)$} $elementOptionsRO] [lindex $args 0] discard option]} {
-		switch $option {
-		    tagName {
-			set result [lindex $node(node:nodeName) 0]
-		    }
-		    empty {
-			if {![info exists node(element:empty)]} {
-			    return 0
-			} else {
-			    return $node(element:empty)
-			}
-		    }
-		    default {
-			return $node(node:$option)
-		    }
-		}
-	    } elseif {[regexp [format {^-(%s)$} $elementOptionsRW] [lindex $args 0] discard option]} {
-		return $node(node:$option)
-	    } else {
-		return -code error "bad option \"[lindex $args 0]\""
-	    }
-	}
-	configure {
-	    if {[llength $args] == 1} {
-		return [document cget $token [lindex $args 0]]
-	    } elseif {[expr [llength $args] % 2]} {
-		return -code error "no value specified for option \"[lindex $args end]\""
-	    } else {
-		foreach {option value} $args {
-		    if {[regexp [format {^-(%s)$} $elementOptionsRO] $option discard opt]} {
-			return -code error "option \"$option\" cannot be modified"
-		    } elseif {[regexp [format {^-(%s)$} $elementOptionsRW] $option discard opt]} {
-			return -code error "not implemented"
-		    } else {
-			return -code error "bad option \"$option\""
-		    }
-		}
-	    }
-	}
-
-	getAttribute {
-	    if {[llength $args] != 1} {
-		return -code error "wrong # args: should be \"dom::element getAttribute token name\""
-	    }
-
-	    set result {}
-
-	    upvar #0 $node(element:attributeList) attrList
-	    catch {set result $attrList([lindex $args 0])}
-
-	    return $result
-
-	}
-
-	setAttribute {
-	    if {[llength $args] != 2} {
-		return -code error "wrong # args: should be \"dom::element setAttribute token name value\""
-	    }
-
-	    # Check that the attribute name is kosher
-	    if {![regexp ^$::xml::Name\$ [lindex $args 0]]} {
-		return -code error "invalid attribute name \"[lindex $args 0]\""
-	    }
-
-	    upvar #0 $node(element:attributeList) attrList
-	    set evid [CreateEvent $token DOMAttrModified]
-	    set oldValue {}
-	    catch {set oldValue $attrList([lindex $args 0])}
-	    event initMutationEvent $evid DOMAttrModified 1 0 $token $oldValue [lindex $args 1] [lindex $args 0] [expr {[info exists attrList([lindex $args 0])] ? "modification" : "addition"}]
-	    set result [set attrList([lindex $args 0]) [lindex $args 1]]
-	    node dispatchEvent $token $evid
-	    DOMImplementation destroy $evid
-
-	}
-
-	removeAttribute {
-	    if {[llength $args] != 1} {
-		return -code error "wrong # args: should be \"dom::element removeAttribute token name\""
-	    }
-
-	    upvar #0 $node(element:attributeList) attrList
-	    catch {unset attrList([lindex $args 0])}
-
-	    event postMutationEvent $token DOMAttrRemoved -attrName [lindex $args 0] -attrChange removal
-
-	}
-
-	getAttributeNS {
-	    if {[llength $args] != 2} {
-		return -code error "wrong # args: should be \"dom::element getAttributeNS token ns name\""
-	    }
-
-	    set result {}
-	    upvar #0 $node(element:attributeList) attrList
-	    catch {set result $attrList([lindex $args 0]^[lindex $args 1])}
-
-	    return $result
-
-	}
-
-	setAttributeNS {
-	    if {[llength $args] != 3} {
-		return -code error "wrong # args: should be \"dom::element setAttributeNS token ns attr value\""
-	    }
-
-	    # Check that the attribute name is kosher
-	    if {![regexp ^$::xml::QName\$ [lindex $args 1] discard prefix localName]} {
-		return -code error "invalid qualified attribute name \"[lindex $args 1]\""
-	    }
-
-	    # BUG: At the moment the prefix is ignored
-
-	    upvar #0 $node(element:attributeList) attrList
-	    set evid [CreateEvent $token DOMAttrModified]
-	    set oldValue {}
-	    catch {set oldValue $attrList([lindex $args 0]^$localName)}
-	    event initMutationEvent $evid DOMAttrModified 1 0 $token $oldValue [lindex $args 2] [lindex $args 0]^localName [expr {[info exists attrList([lindex $args 0]^$localName)] ? "modification" : "addition"}]
-	    set result [set attrList([lindex $args 0]^$localName) [lindex $args 2]]
-	    node dispatchEvent $token $evid
-	    DOMImplementation destroy $evid
-
-	}
-
-	removeAttributeNS {
-	    if {[llength $args] != 2} {
-		return -code error "wrong # args: should be \"dom::element removeAttributeNS token ns name\""
-	    }
-
-	    upvar #0 $node(element:attributeList) attrList
-	    catch {unset attrList([lindex $args 0]^[lindex $args 1])}
-
-	    event postMutationEvent $token DOMAttrRemoved -attrName [lindex $args 0]^[lindex $args 1] -attrChange removal
-
-	}
-
-	getAttributeNode {
-	    array set tmp [array get $node(element:attributeList)]
-	    if {![info exists tmp([lindex $args 0])]} {
-		return {}
-	    }
-
-	    # Synthesize an attribute node if one doesn't already exist
-	    array set attrNodes $node(element:attributeNodes)
-	    if {[catch {set result $attrNodes([lindex $args 0])}]} {
-		set result [CreateGeneric $token node:nodeType attribute node:nodeName [lindex $args 0] node:nodeValue $tmp([lindex $args 0])]
-		lappend node(element:attributeNodes) [lindex $args 0] $result
-	    }
-	}
-
-	setAttributeNode -
-	removeAttributeNode -
-	getAttributeNodeNS -
-	setAttributeNodeNS -
-	removeAttributeNodeNS {
-	    return -code error "not yet implemented"
-	}
-
-	getElementsByTagName {
-	    if {[llength $args] < 1} {
-		return -code error "wrong # args: should be \"dom::element getElementsByTagName token name\""
-	    }
-
-	    return [eval Element:GetByTagName [list $token [lindex $args 0]] \
-		    [lrange $args 1 end]]
-	}
-
-	normalize {
-	    if {[llength $args]} {
-		return -code error "wrong # args: should be dom::element normalize token"
-	    }
-
-	    Element:Normalize node [set $node(node:childNodes)]
-	}
-
-	default {
-	    return -code error "bad method \"$method\": should be cget, configure, getAttribute, setAttribute, removeAttribute, getAttributeNS, setAttributeNS, removeAttributeNS, getAttributeNode, setAttributeNode, removeAttributeNode, getAttributeNodeNS, setAttributeNodeNS, removeAttributeNodeNS, getElementsByTagName or normalize"
-	}
-
-    }
-
-    return $result
-}
-
-# dom::tcl::Element:GetByTagName --
-#
-#	Search for (child) elements
-#
-#	This used to be non-recursive, but then I read the DOM spec
-#	properly and discovered that it should recurse.  The -deep
-#	option allows for backward-compatibility, and defaults to the
-#	DOM-specified value of true.
-#
-# Arguments:
-#	token	parent node
-#	name	element type to search for
-#	args	configuration options
-#
-# Results:
-#	The name of the variable containing the list of matching node tokens
-
-proc dom::tcl::Element:GetByTagName {token name args} {
-    upvar #0 $token node
-    upvar #0 [namespace qualifiers $token]::Document document
-
-    array set cfg {-deep 1}
-    array set cfg $args
-    set cfg(-deep) [Boolean $cfg(-deep)]
-
-    # Guard against arbitrary glob characters
-    # Checking that name is a legal XML Name does this
-    # However, '*' is permitted
-    if {![regexp ^$::xml::Name\$ $name] && [string compare $name "*"]} {
-	return -code error "invalid element name"
-    }
-
-    # Allocate variable name for this search
-    set searchVar ${token}search[incr document(counter)]
-    upvar \#0 $searchVar search
-
-    # Make list live by interposing on variable reads
-    # I don't think we need to interpose on unsets,
-    # and writing to this variable by the application is
-    # not permitted.
-
-    trace variable $searchVar w [namespace code Element:GetByTagName:Error]
-
-    if {[string compare $node(node:nodeType) "document"]} {
-	trace variable $searchVar r [namespace code [list Element:GetByTagName:Search [set $node(node:childNodes)] $name $cfg(-deep)]]
-    } elseif {[llength $node(document:documentElement)]} {
-	# Document Element must exist and must be an element type node
-	trace variable $searchVar r [namespace code [list Element:GetByTagName:Search $node(document:documentElement) $name $cfg(-deep)]]
-    }
-
-    return $searchVar
-}
-
-# dom::tcl::Element:GetByTagName:Search --
-#
-#	Search for elements.  This does the real work.
-#	Because this procedure is invoked everytime
-#	the variable is read, it returns the live list.
-#
-# Arguments:
-#	tokens	nodes to search (inclusive)
-#	name	element type to search for
-#	deep	whether to search recursively
-#	name1	\
-#	name2	 > appended by trace command
-#	op	/
-#
-# Results:
-#	List of matching node tokens
-
-proc dom::tcl::Element:GetByTagName:Search {tokens name deep name1 name2 op} {
-    set result {}
-
-    foreach tok $tokens {
-	upvar #0 $tok nodeInfo
-	switch -- $nodeInfo(node:nodeType) {
-	    element {
-		if {[string match $name [GetField nodeInfo(node:nodeName)]]} {
-		    lappend result $tok
-		}
-		if {$deep} {
-		    set childResult [Element:GetByTagName:Search [set $nodeInfo(node:childNodes)] $name $deep {} {} {}]
-		    if {[llength $childResult]} {
-			eval lappend result $childResult
-		    }
-		}
-	    }
-	}
-    }
-
-    if {[string length $name1]} {
-	set $name1 $result
-	return {}
-    } else {
-	return $result
-    }
-}
-
-# dom::tcl::Element:GetByTagName:Error --
-#
-#	Complain about the application writing to a variable
-#	that this package maintains.
-#
-# Arguments:
-#	name1	\
-#	name2	 > appended by trace command
-#	op	/
-#
-# Results:
-#	Error code returned.
-
-proc dom::tcl::Element:GetByTagName:Error {name1 name2 op} {
-    return -code error "dom: Read-only variable"
-}
-
-# dom::tcl::Element:Normalize --
-#
-#	Normalize the text nodes
-#
-# Arguments:
-#	pVar	parent array variable in caller
-#	nodes	list of node tokens
-#
-# Results:
-#	Adjacent text nodes are coalesced
-
-proc dom::tcl::Element:Normalize {pVar nodes} {
-    upvar #0 $pVar parent
-
-    set textNode {}
-
-    foreach n $nodes {
-	upvar #0 $n child
-	set cleanup {}
-
-	switch $child(node:nodeType) {
-	    textNode {
-		if {[llength $textNode]} {
-
-		    # Coalesce into previous node
-		    set evid [CreateEvent $n DOMCharacterDataModified]
-		    event initMutationEvent $evid DOMCharacterDataModified 1 0 {} $text(node:nodeValue) $text(node:nodeValue)$child(node:nodeValue) {} {}
-		    append text(node:nodeValue) $child(node:nodeValue)
-		    node dispatchEvent $n $evid
-		    DOMImplementation destroy $evid
-
-		    # Remove this child
-		    upvar #0 $parent(node:childNodes) childNodes
-		    set idx [lsearch $childNodes $n]
-		    set childNodes [lreplace $childNodes $idx $idx]
-		    unset $n
-		    set cleanup [list event postMutationEvent [node parent $n] DOMSubtreeModified]
-		    event postMutationEvent $n DOMNodeRemoved
-
-		    set $textNode [array get text]
-		} else {
-		    set textNode $n
-		    catch {unset text}
-		    array set text [array get child]
-		}
-	    }
-	    element -
-	    document -
-	    documentFragment {
-		set textNode {}
-		Element:Normalize child [set $child(node:childNodes)]
-	    }
-	    default {
-		set textNode {}
-	    }
-	}
-
-	eval $cleanup
-    }
-
-    return {}
-}
-
-# dom::tcl::processinginstruction --
-#
-#	Functions for a processing intruction.
-#
-# Arguments:
-#	method	method to invoke
-#	token	token for node
-#	args	arguments for method
-#
-# Results:
-#	Depends on method used.
-
-namespace eval dom::tcl {
-    variable piOptionsRO target
-    variable piOptionsRW data
-}
-
-proc dom::tcl::processinginstruction {method token args} {
-    variable piOptionsRO
-    variable piOptionsRW
-
-    upvar #0 $token node
-
-    set result {}
-
-    switch -- $method {
-
-	cget {
-	    # Some read-only configuration options are computed
-	    if {[llength $args] != 1} {
-		return -code error "too many arguments"
-	    }
-	    if {[regexp [format {^-(%s)$} $elementOptionsRO] [lindex $args 0] discard option]} {
-		switch $option {
-		    target {
-			set result [lindex $node(node:nodeName) 0]
-		    }
-		    default {
-			return $node(node:$option)
-		    }
-		}
-	    } elseif {[regexp [format {^-(%s)$} $elementOptionsRW] [lindex $args 0] discard option]} {
-		switch $option {
-		    data {
-			return $node(node:nodeValue)
-		    }
-		    default {
-			return $node(node:$option)
-		    }
-		}
-	    } else {
-		return -code error "unknown option \"[lindex $args 0]\""
-	    }
-	}
-	configure {
-	    if {[llength $args] == 1} {
-		return [document cget $token [lindex $args 0]]
-	    } elseif {[expr [llength $args] % 2]} {
-		return -code error "no value specified for option \"[lindex $args end]\""
-	    } else {
-		foreach {option value} $args {
-		    if {[regexp [format {^-(%s)$} $elementOptionsRO] $option discard opt]} {
-			return -code error "attribute \"$option\" is read-only"
-		    } elseif {[regexp [format {^-(%s)$} $elementOptionsRW] $option discard opt]} {
-			switch $opt {
-			    data {
-				set evid [CreateEvent $token DOMCharacterDataModified]
-				event initMutationEvent $evid DOMCharacterModified 1 0 {} $node(node:nodeValue) $value {} {}
-				set node(node:nodeValue) $value
-				node dispatchEvent $token $evid
-				DOMImplementation destroy $evid
-			    }
-			    default {
-				set node(node:$opt) $value
-			    }
-			}
-		    } else {
-			return -code error "unknown option \"$option\""
-		    }
-		}
-	    }
-	}
-
-	default {
-	    return -code error "unknown method \"$method\""
-	}
-
-    }
-
-    return $result
-}
-
-#################################################
-#
-# DOM Level 2 Interfaces
-#
-#################################################
-
-# dom::tcl::event --
-#
-#	Implements Event Interface
-#
-#	Subclassed Interfaces are also defined here,
-#	such as UIEvents.
-#
-# Arguments:
-#	method	method to invoke
-#	token	token for event
-#	args	arguments for method
-#
-# Results:
-#	Depends on method used.
-
-namespace eval dom::tcl {
-    variable eventOptionsRO type|target|currentNode|eventPhase|bubbles|cancelable|timeStamp|detail|view|screenX|screenY|clientX|clientY|ctrlKey|shiftKey|altKey|metaKey|button|relatedNode|prevValue|newValue|attrName|attrChange
-    variable eventOptionsRW {}
-
-    # Issue: should the attributes belonging to the subclassed Interface
-    # be separated out?
-
-    variable uieventOptionsRO detail|view
-    variable uieventOptionsRW {}
-
-    variable mouseeventOptionsRO screenX|screenY|clientX|clientY|ctrlKey|shiftKey|altKey|metaKey|button|relatedNode
-    variable mouseeventOptionsRW {}
-
-    variable mutationeventOptionsRO relatedNode|prevValue|newValue|attrName
-    variable mutationeventOptionsRW {}
-}
-
-proc dom::tcl::event {method token args} {
-    variable eventOptionsRO
-    variable eventOptionsRW
-
-    upvar #0 $token event
-
-    set result {}
-
-    switch -glob -- $method {
-
-	cg* {
-	    # cget
-
-	    if {[llength $args] != 1} {
-		return -code error "too many arguments"
-	    }
-	    if {[regexp [format {^-(%s)$} $eventOptionsRO] [lindex $args 0] discard option]} {
-		return $event($option)
-	    } elseif {[regexp [format {^-(%s)$} $eventOptionsRW] [lindex $args 0] discard option]} {
-		return $event($option)
-	    } else {
-		return -code error "unknown option \"[lindex $args 0]\""
-	    }
-	}
-
-	co* {
-	    # configure
-
-	    if {[llength $args] == 1} {
-		return [event cget $token [lindex $args 0]]
-	    } elseif {[expr [llength $args] % 2]} {
-		return -code error "no value specified for option \"[lindex $args end]\""
-	    } else {
-		foreach {option value} $args {
-		    if {[regexp [format {^-(%s)$} $eventOptionsRW] $option discard opt]} {
-			set event($opt) $value
-		    } elseif {[regexp [format {^-(%s)$} $eventOptionsRO] $option discard opt]} {
-			return -code error "attribute \"$option\" is read-only"
-		    } else {
-			return -code error "unknown option \"$option\""
-		    }
-		}
-	    }
-
-	}
-
-	st* {
-	    # stopPropagation
-
-	    set event(stopPropagation) 1
-	}
-
-	pr* {
-	    # preventDefault
-
-	    set event(preventDefault) 1
-	}
-
-	initE* {
-	    # initEvent
-
-	    if {[llength $args] != 3} {
-		return -code error "wrong # args: should be dom::event initEvent token type bubbles cancelable"
-	    }
-
-	    if {$event(dispatched)} {
-		return -code error "event has been dispatched"
-	    }
-
-	    foreach {event(type) event(bubbles) event(cancelable)} $args break
-	}
-
-	initU* {
-	    # initUIEvent
-
-	    if {[llength $args] < 4 || [llength $args] > 5} {
-		return -code error "wrong # args: should be dom::event initUIEvent token type bubbles cancelable view detail"
-	    }
-
-	    if {$event(dispatched)} {
-		return -code error "event has been dispatched"
-	    }
-
-	    set event(detail) 0
-	    foreach {event(type) event(bubbles) event(cancelable) event(view) event(detail)} $args break
-	}
-
-	initMo* {
-	    # initMouseEvent
-
-	    if {[llength $args] != 15} {
-		return -code error "wrong # args: should be dom::event initMouseEvent token type bubbles cancelable view detail screenX screenY clientX clientY ctrlKey altKey shiftKey metaKey button relatedNode"
-	    }
-
-	    if {$event(dispatched)} {
-		return -code error "event has been dispatched"
-	    }
-
-	    set event(detail) 1
-	    foreach {event(type) event(bubbles) event(cancelable) event(view) event(detail) event(screenX) event(screenY) event(clientX) event(clientY) event(ctrlKey) event(altKey) event(shiftKey) event(metaKey) event(button) event(relatedNode)} $args break
-	}
-
-	initMu* {
-	    # initMutationEvent
-
-	    if {[llength $args] != 8} {
-		return -code error "wrong # args: should be dom::event initMutationEvent token type bubbles cancelable relatedNode prevValue newValue attrName attrChange"
-	    }
-
-	    if {$event(dispatched)} {
-		return -code error "event has been dispatched"
-	    }
-
-	    foreach {event(type) event(bubbles) event(cancelable) event(relatedNode) event(prevValue) event(newValue) event(attrName) event(attrChange)} $args break
-	}
-
-	postUI* {
-	    # postUIEvent, non-standard convenience method
-
-	    set evType [lindex $args 0]
-	    array set evOpts [list \
-		    -bubbles $::dom::bubbles($evType) -cancelable $::dom::cancelable($evType)	\
-		    -view {}			\
-		    -detail {}			\
-	    ]
-	    array set evOpts [lrange $args 1 end]
-
-	    set evid [CreateEvent $token $evType]
-	    event initUIEvent $evid $evType $evOpts(-bubbles) $evOpts(-cancelable) $evOpts(-view) $evOpts(-detail)
-	    node dispatchEvent $token $evid
-	    DOMImplementation destroy $evid
-
-	}
-
-	postMo* {
-	    # postMouseEvent, non-standard convenience method
-
-	    set evType [lindex $args 0]
-	    array set evOpts [list \
-		    -bubbles $::dom::bubbles($evType) -cancelable $::dom::cancelable($evType)	\
-		    -view {}			\
-		    -detail {}			\
-		    -screenX {}			\
-		    -screenY {}			\
-		    -clientX {}			\
-		    -clientY {}			\
-		    -ctrlKey {}			\
-		    -altKey {}			\
-		    -shiftKey {}		\
-		    -metaKey {}			\
-		    -button {}			\
-		    -relatedNode {}		\
-	    ]
-	    array set evOpts [lrange $args 1 end]
-
-	    set evid [CreateEvent $token $evType]
-	    event initMouseEvent $evid $evType $evOpts(-bubbles) $evOpts(-cancelable) $evOpts(-view) $evOpts(-detail) $evOpts(-screenX) $evOpts(-screenY) $evOpts(-clientX) $evOpts(-clientY) $evOpts(-ctrlKey) $evOpts(-altKey) $evOpts(-shiftKey) $evOpts(-metaKey) $evOpts(-button) $evOpts(-relatedNode)
-	    node dispatchEvent $token $evid
-	    DOMImplementation destroy $evid
-
-	}
-
-	postMu* {
-	    # postMutationEvent, non-standard convenience method
-
-	    set evType [lindex $args 0]
-	    array set evOpts [list \
-		    -bubbles $::dom::bubbles($evType) -cancelable $::dom::cancelable($evType)	\
-		    -relatedNode {}			\
-		    -prevValue {} -newValue {}		\
-		    -attrName {} -attrChange {}		\
-	    ]
-	    array set evOpts [lrange $args 1 end]
-
-	    set evid [CreateEvent $token $evType]
-	    event initMutationEvent $evid $evType $evOpts(-bubbles) $evOpts(-cancelable) $evOpts(-relatedNode) $evOpts(-prevValue) $evOpts(-newValue) $evOpts(-attrName) $evOpts(-attrChange)
-	    node dispatchEvent $token $evid
-	    DOMImplementation destroy $evid
-
-	}
-
-	default {
-	    return -code error "unknown method \"$method\""
-	}
-    }
-
-    return $result
-}
-
-# dom::tcl::CreateEvent --
-#
-#	Create an event object
-#
-# Arguments:
-#	token	parent node
-#	type	event type
-#	args	configuration options
-#
-# Results:
-#	Returns event token
-
-proc dom::tcl::CreateEvent {token type args} {
-    array set opts $args
-    if {[string length $token]} {
-	upvar #0 $token parent
-	upvar #0 [namespace qualifiers $token]::Document document
-	set child [namespace qualifiers $token]::event[incr document(counter)]
-    } elseif {[info exists $opts(-document)]} {
-	upvar #0 $opts(-document) document
-	set child [namespace qualifiers $opts(-document)]::event[incr document(counter)]
-    }
-
-    upvar #0 $child event
-
-    # Create the event
-    array set event [list \
-	    node:nodeType event	\
-	    type $type		\
-	    target {}		\
-	    currentNode {}	\
-	    cancelable 1	\
-	    stopPropagation 0	\
-	    preventDefault 0	\
-	    dispatched 0	\
-	    bubbles 1		\
-	    eventPhase {}	\
-	    timeStamp [clock clicks -milliseconds]	\
-	    ]
-
-    proc $child {method args} "return \[eval [namespace current]::event \[list \$method\] $child \$args\]"
-    trace add command $child delete [namespace code [list Node:Delete $child]]
-
-    return $child
-}
-
-#################################################
-#
-# Serialisation
-#
-#################################################
-
-# dom::tcl::Serialize:documentFragment --
-#
-#	Produce text for documentFragment.
-#
-# Arguments:
-#	token	node token
-#	args	configuration options
-#
-# Results:
-#	XML format text.
-
-proc dom::tcl::Serialize:documentFragment {token args} {
-    upvar #0 $token node
-
-    if {[string compare "Document" [namespace tail $token]]} {
-	return [eval [list Serialize:node $token] $args]
-    } else {
-	if {[string compare {} [GetField node(document:documentElement)]]} {
-	    return [eval Serialize:document [list $token] $args]
-	} else {
-	    return -code error "document has no document element"
-	}
-    }
-
-}
-
-# dom::tcl::Serialize:document --
-#
-#	Produce text for document.
-#
-# Arguments:
-#	token	node token
-#	args	configuration options
-#
-# Results:
-#	XML format text.
-
-proc dom::tcl::Serialize:document {token args} {
-    upvar #0 $token node
-    array set opts {
-	-showxmldecl 1
-	-showdoctypedecl 1
-    }
-    array set opts $args
-
-    set result {}
-
-    if {[string length $node(document:doctype)]} {
-
-	upvar #0 $node(document:doctype) doctype
-
-	# Bug fix: can't use Serialize:attributeList for XML declaration,
-	# since attributes must occur in a given order (XML 2.8 [23])
-
-	set result {}
-
-	if {$opts(-showxmldecl)} {
-	    append result <?xml[Serialize:XMLDecl version $node(document:xmldecl)][Serialize:XMLDecl encoding $node(document:xmldecl)][Serialize:XMLDecl standalone $node(document:xmldecl)]?>\n
-	}
-	if {$opts(-showdoctypedecl)} {
-	    # Is document element in an XML Namespace?
-	    # If so then include prefix in doctype decl
-	    foreach {prefix localName} [::xml::qnamesplit $doctype(doctype:name)] break
-	    if {![string length $prefix]} {
-		# The prefix may not have been allocated yet
-		upvar #0 $node(document:documentElement) docel
-		if {[info exists docel(node:namespaceURI)] && \
-			[string length $docel(node:namespaceURI)]} {
-		    set declPrefix [GetNamespacePrefix $node(document:documentElement) $docel(node:namespaceURI)]
-		    set docelName $declPrefix:$doctype(doctype:name)
-		} else {
-		    set docelName $doctype(doctype:name)
-		}
-	    } else {
-		set docelName $doctype(doctype:name)
-	    }
-	    # Applied patch by Marco Gonnelli, bug #590914
-	    append result <!DOCTYPE\ $docelName[Serialize:ExternalID $doctype(doctype:publicId) $doctype(doctype:systemId)][expr {[string length $doctype(doctype:internalSubset)] ? " \[[string trim $doctype(doctype:internalSubset) \{\} ]\]" : {}}]>\n
-	}
-    }
-
-    # BUG #525505: Want to serialize all children including the
-    # document element.
-
-    if {[info exists $node(node:childNodes)]} {
-	foreach child [set $node(node:childNodes)] {
-	    append result [eval Serialize:[node cget $child -nodeType] [list $child] $args]
-	}
-    }
-
-    return $result
-}
-
-# dom::tcl::Serialize:ExternalID --
-#
-#	Returned appropriately quoted external identifiers
-#
-# Arguments:
-#	publicid	public identifier
-#	systemid	system identifier
-#
-# Results:
-#	text
-
-proc dom::tcl::Serialize:ExternalID {publicid systemid} {
-
-    switch -glob -- [string length $publicid],[string length $systemid] {
-	0,0 {
-	    return {}
-	}
-	0,* {
-	    return " SYSTEM \"$systemid\""
-	}
-	*,* {
-	    # Patch from c.l.t., Richard Calmbach (rc at hnc.com )
-	    return " PUBLIC \"$publicid\" \"$systemid\""
-	}
-    }
-
-    return {}
-}
-
-# dom::tcl::Serialize:XMLDecl --
-#
-#	Produce text for XML Declaration attribute.
-#	Order is determine by document serialisation procedure.
-#
-# Arguments:
-#	attr	required attribute
-#	attList	attribute list
-#
-# Results:
-#	XML format text.
-
-proc dom::tcl::Serialize:XMLDecl {attr attrList} {
-    array set data $attrList
-    if {![info exists data($attr)]} {
-	return {}
-    } elseif {[string length $data($attr)]} {
-	return " $attr='$data($attr)'"
-    } else {
-	return {}
-    }
-}
-
-# dom::tcl::Serialize:node --
-#
-#	Produce text for an arbitrary node.
-#	This simply serializes the child nodes of the node.
-#
-# Arguments:
-#	token	node token
-#	args	configuration options
-#
-# Results:
-#	XML format text.
-
-proc dom::tcl::Serialize:node {token args} {
-    upvar #0 $token node
-    array set opts $args
-
-    if {[info exists opts(-indent)]} {
-	# NB. 0|1 cannot be used as booleans - mention this in docn
-	if {[regexp {^false|no|off$} $opts(-indent)]} {
-	    # No action required
-	} elseif {[regexp {^true|yes|on$} $opts(-indent)]} {
-	    set opts(-indent) 1
-	} else {
-	    incr opts(-indent)
-	}
-    }
-
-    set result {}
-    foreach childToken [set $node(node:childNodes)] {
-	upvar #0 $childToken child
-	append result [eval [list Serialize:$child(node:nodeType) $childToken] [array get opts]]
-    }
-
-    return $result
-}
-
-# dom::tcl::Serialize:element --
-#
-#	Produce text for an element.
-#
-# Arguments:
-#	token	node token
-#	args	configuration options
-#
-# Results:
-#	XML format text.
-
-proc dom::tcl::Serialize:element {token args} {
-    upvar #0 $token node
-    array set opts {-newline {}}
-    array set opts $args
-
-    set result {}
-    set newline {}
-    if {[lsearch $opts(-newline) $node(node:nodeName)] >= 0} {
-	append result \n
-	set newline \n
-    }
-    append result [eval Serialize:Indent [array get opts]]
-    switch [info exists node(node:namespaceURI)],[info exists node(node:prefix)] {
-
-	1,1 {
-	    # XML Namespace is in scope, prefix supplied
-	    if {[string length $node(node:prefix)]} {
-		# Make sure that there's a declaration for this XML Namespace
-		set declPrefix [GetNamespacePrefix $token $node(node:namespaceURI) -prefix $node(node:prefix)]
-		# ASSERTION: $declPrefix == $node(node:prefix)
-		set nsPrefix $node(node:prefix):
-	    } elseif {[string length $node(node:namespaceURI)]} {
-		set nsPrefix [GetNamespacePrefix $token $node(node:namespaceURI)]:
-	    } else {
-		set nsPrefix {}
-	    }
-	}
-
-	1,0 {
-	    # XML Namespace is in scope, no prefix
-	    set nsPrefix [GetNamespacePrefix $token $node(node:namespaceURI)]:
-	    if {![string compare $nsPrefix :]} {
-		set nsPrefix {}
-	    }
-	}
-
-	0,1 {
-	    # Internal error
-	    set nsPrefix {}
-	}
-
-	0,0 -
-	default {
-	    # No XML Namespace is in scope
-	    set nsPrefix {}
-	}
-    }
-    append result <$nsPrefix$node(node:localName)
-
-    append result [Serialize:attributeList [array get $node(element:attributeList)]]
-
-    if {![llength [set $node(node:childNodes)]]} {
-
-	append result />$newline
-
-    } else {
-
-	append result >$newline
-
-	# Do the children
-	if {[hasmixedcontent $token]} {
-	    set opts(-indent) no
-	}
-	append result [eval Serialize:node [list $token] [array get opts]]
-
-	append result [eval Serialize:Indent [array get opts]]
-	append result "$newline</$nsPrefix$node(node:localName)>$newline"
-
-    }
-
-    return $result
-}
-
-# dom::tcl::GetNamespacePrefix --
-#
-#	Determine the XML Namespace prefix for a Namespace URI
-#
-# Arguments:
-#	token	node token
-#	nsuri	XML Namespace URI
-#	args	configuration options
-#
-# Results:
-#	Returns prefix.
-#	May add prefix information to node
-
-proc dom::tcl::GetNamespacePrefix {token nsuri args} {
-    upvar #0 $token node
-    array set options $args
-
-    GetNamespaceDecl $token $nsuri declNode prefix
-
-    if {[llength $declNode]} {
-	# A declaration was found for this Namespace URI
-	return $prefix
-    } else {
-	# No declaration found.  Allocate a prefix
-	# and add XML Namespace declaration
-	set prefix {}
-	catch {set prefix $options(-prefix)}
-	if {![string compare $prefix {}]} {
-	    upvar #0 [namespace qualifiers $token]::Document document
-	    set prefix ns[incr document(counter)]
-	}
-	set node(node:prefix) $prefix
-	upvar \#0 $node(element:attributeList) attrs
-	set attrs(${::dom::xmlnsURI}^$prefix) $nsuri
-
-	return $prefix
-    }
-}
-
-# dom::tcl::GetNamespaceDecl --
-#
-#	Find the XML Namespace declaration.
-#
-# Arguments:
-#	token	node token
-#	nsuri	XML Namespace URI
-#	nodeVar	Variable name for declaration
-#	prefVar Variable for prefix
-#
-# Results:
-#	If the declaration is found returns node and prefix
-
-proc dom::tcl::GetNamespaceDecl {token nsuri nodeVar prefVar} {
-    upvar #0 $token node
-    upvar $nodeVar declNode
-    upvar $prefVar prefix
-
-    while {[string length $node(node:parentNode)]} {
-
-	# Check this node's XML Namespace declarations
-	catch {unset attrs}
-	array set attrs [array get $node(element:attributeList)]
-	foreach {nsdecl decluri} [array get attrs ${::dom::xmlnsURI}^*] {
-	    if {![string compare $decluri $nsuri]} {
-		regexp [format {%s\^(.*)} $::dom::xmlnsURI] $nsdecl dummy prefix
-		set declNode $token
-		return
-	    }
-	}
-
-	# Move up to parent
-	set token $node(node:parentNode)
-	upvar #0 $token node
-    }
-
-    # Got to Document node and didn't find XML NS decl
-    set prefix {}
-    set declNode {}
-}
-
-# dom::tcl::Serialize:textNode --
-#
-#	Produce text for a text node.  This procedure may
-#	return a CDATA section where appropriate.
-#
-# Arguments:
-#	token	node token
-#	args	configuration options
-#
-# Results:
-#	XML format text.
-
-proc dom::tcl::Serialize:textNode {token args} {
-    upvar #0 $token node
-
-    if {$node(node:cdatasection)} {
-	return [Serialize:CDATASection $node(node:nodeValue)]
-    } elseif {[Serialize:ExceedsThreshold $node(node:nodeValue)]} {
-	return [Serialize:CDATASection $node(node:nodeValue)]
-    } else {
-	return [Encode $node(node:nodeValue)]
-    }
-}
-
-# dom::tcl::Serialize:ExceedsThreshold --
-#
-#	Applies heuristic(s) to determine whether a text node
-#	should be formatted as a CDATA section.
-#
-# Arguments:
-#	text	node text
-#
-# Results:
-#	Boolean.
-
-proc dom::tcl::Serialize:ExceedsThreshold {text} {
-    return [expr {[regsub -all {[<>&]} $text {} discard] > $::dom::maxSpecials}]
-}
-
-# dom::tcl::Serialize:CDATASection --
-#
-#	Formats a CDATA section.
-#
-# Arguments:
-#	text	node text
-#
-# Results:
-#	XML text.
-
-proc dom::tcl::Serialize:CDATASection {text} {
-    set result {}
-    while {[regexp {(.*)]]>(.*)} $text discard text trailing]} {
-	set result \]\]&gt\;<!\[CDATA\[$trailing\]\]>$result
-    }
-    return <!\[CDATA\[$text\]\]>$result
-}
-
-# dom::tcl::Serialize:processingInstruction --
-#
-#	Produce text for a PI node.
-#
-# Arguments:
-#	token	node token
-#	args	configuration options
-#
-# Results:
-#	XML format text.
-
-proc dom::tcl::Serialize:processingInstruction {token args} {
-    upvar #0 $token node
-
-    return "[eval Serialize:Indent $args]<?$node(node:nodeName)[expr {$node(node:nodeValue) == "" ? "" : " $node(node:nodeValue)"}]?>"
-}
-
-# dom::tcl::Serialize:comment --
-#
-#	Produce text for a comment node.
-#
-# Arguments:
-#	token	node token
-#	args	configuration options
-#
-# Results:
-#	XML format text.
-
-proc dom::tcl::Serialize:comment {token args} {
-    upvar #0 $token node
-
-    return [eval Serialize:Indent $args]<!--$node(node:nodeValue)-->
-}
-
-# dom::tcl::Serialize:entityReference --
-#
-#	Produce text for an entity reference.
-#
-# Arguments:
-#	token	node token
-#	args	configuration options
-#
-# Results:
-#	XML format text.
-
-proc dom::tcl::Serialize:entityReference {token args} {
-    upvar #0 $token node
-
-    return &$node(node:nodeName)\;
-}
-
-# dom::tcl::Encode --
-#
-#	Encode special characters
-#
-# Arguments:
-#	value	text value
-#
-# Results:
-#	XML format text.
-
-proc dom::tcl::Encode value {
-    array set Entity {
-	$ $
-	< <
-	> >
-	& &
-	\" "
-	' '
-    }
-
-    regsub -all {([$<>&"'])} $value {$Entity(\1)} value
-
-    return [subst -nocommand -nobackslash $value]
-}
-
-# dom::tcl::Serialize:attributeList --
-#
-#	Produce text for an attribute list.
-#
-# Arguments:
-#	l	name/value paired list
-#
-# Results:
-#	XML format text.
-
-proc dom::tcl::Serialize:attributeList {l} {
-
-    set result {}
-    foreach {name value} $l {
-
-	if {[regexp {^([^^]+)\^(.*)$} $name discard nsuri prefix]} {
-	    if {[string compare $nsuri $::dom::xmlnsURI]} {
-		# Need the node token to resolve the Namespace URI
-		append result { } ?:$prefix =
-	    } else {
-		# A Namespace declaration
-		append result { } xmlns:$prefix =
-	    }
-	} else {
-	    append result { } $name =
-	}
-
-	# Handle special characters
-	regsub -all & $value {\&} value
-	regsub -all < $value {\<} value
-
-	if {![string match *\"* $value]} {
-	    append result \"$value\"
-	} elseif {![string match *'* $value]} {
-	    append result '$value'
-	} else {
-	    regsub -all \" $value {\"} value
-	    append result \"$value\"
-	}
-
-    }
-
-    return $result
-}
-
-# dom::tcl::Serialize:Indent --
-#
-#	Calculate the indentation required, if any
-#
-# Arguments:
-#	args	configuration options, which may specify -indent
-#
-# Results:
-#	May return white space
-
-proc dom::tcl::Serialize:Indent args {
-    array set opts [list -indentspec $::dom::indentspec]
-    array set opts $args
-
-    if {![info exists opts(-indent)] || \
-	    [regexp {^false|no|off$} $opts(-indent)]} {
-	return {}
-    }
-
-    if {[regexp {^true|yes|on$} $opts(-indent)]} {
-	# Default indent level is 0
-	return \n
-    }
-
-    if {!$opts(-indent)} {
-	return \n
-    }
-
-    set ws [format \n%\ [expr $opts(-indent) * [lindex $opts(-indentspec) 0]]s { }]
-    regsub -all [lindex [lindex $opts(-indentspec) 1] 0] $ws [lindex [lindex $opts(-indentspec) 1] 1] ws
-
-    return $ws
-
-}
-
-#################################################
-#
-# Parsing
-#
-#################################################
-
-# dom::tcl::ParseElementStart --
-#
-#	Push a new element onto the stack.
-#
-# Arguments:
-#	stateVar	global state array variable
-#	name		element name
-#	attrList	attribute list
-#	args		configuration options
-#
-# Results:
-#	An element is created within the currently open element.
-
-proc dom::tcl::ParseElementStart {stateVar name attrList args} {
-
-    upvar #0 $stateVar state
-    array set opts $args
-
-    # Push namespace declarations
-    # We need to be able to map namespaceURI's back to prefixes
-    set nsattrlists {}
-    catch {
-	foreach {namespaceURI prefix} $opts(-namespacedecls) {
-	    lappend state(NS:$namespaceURI) $prefix
-
-	    # Also, synthesize namespace declaration attributes
-	    # TclXML is a little too clever when it parses them away!
-
-	    lappend nsattrlists $prefix $namespaceURI
-	}
-	lappend opts(-namespaceattributelists) $::dom::xmlnsURI $nsattrlists
-
-    }
-
-    set nsarg {}
-    catch {
-	lappend nsarg -namespace $opts(-namespace)
-	lappend nsarg -localname $name
-	lappend nsarg -prefix [lindex $state(NS:$opts(-namespace)) end]
-    }
-
-    lappend state(current) \
-	[eval CreateElement [list [lindex $state(current) end] $name $attrList] $nsarg [array get opts -namespaceattributelists]]
-
-    if {[info exists opts(-empty)] && $opts(-empty)} {
-	# Flag this node as being an empty element
-	upvar #0 [lindex $state(current) end] node
-	set node(element:empty) 1
-    }
-
-    # Temporary: implement -progresscommand here, because of broken parser
-    if {[string length $state(-progresscommand)]} {
-	if {!([incr state(progCounter)] % $state(-chunksize))} {
-	    uplevel #0 $state(-progresscommand)
-	}
-    }
-}
-
-# dom::tcl::ParseElementEnd --
-#
-#	Pop an element from the stack.
-#
-# Arguments:
-#	stateVar	global state array variable
-#	name		element name
-#	args		configuration options
-#
-# Results:
-#	Currently open element is closed.
-
-proc dom::tcl::ParseElementEnd {stateVar name args} {
-    upvar #0 $stateVar state
-
-    set state(current) [lreplace $state(current) end end]
-}
-
-# dom::tcl::ParseCharacterData --
-#
-#	Add a textNode to the currently open element.
-#
-# Arguments:
-#	stateVar	global state array variable
-#	data		character data
-#
-# Results:
-#	A textNode is created.
-
-proc dom::tcl::ParseCharacterData {stateVar data} {
-    upvar #0 $stateVar state
-
-    CreateTextNode [lindex $state(current) end] $data
-}
-
-# dom::tcl::ParseProcessingInstruction --
-#
-#	Add a PI to the currently open element.
-#
-# Arguments:
-#	stateVar	global state array variable
-#	name		PI name
-#	target		PI target
-#
-# Results:
-#	A processingInstruction node is created.
-
-proc dom::tcl::ParseProcessingInstruction {stateVar name target} {
-    upvar #0 $stateVar state
-
-    CreateGeneric [lindex $state(current) end] node:nodeType processingInstruction node:nodeName $name node:nodeValue $target
-}
-
-# dom::tcl::ParseXMLDeclaration --
-#
-#	Add information from the XML Declaration to the document.
-#
-# Arguments:
-#	stateVar	global state array variable
-#	version		version identifier
-#	encoding	character encoding
-#	standalone	standalone document declaration
-#
-# Results:
-#	Document node modified.
-
-proc dom::tcl::ParseXMLDeclaration {stateVar version encoding standalone} {
-    upvar #0 $stateVar state
-
-    upvar #0 $state(docNode) document
-    array set xmldecl $document(document:xmldecl)
-
-    array set xmldecl [list version $version	\
-	    standalone $standalone		\
-	    encoding $encoding			\
-    ]
-
-    set document(document:xmldecl) [array get xmldecl]
-
-    return {}
-}
-
-# dom::tcl::ParseDocType --
-#
-#	Add a Document Type Declaration node to the document.
-#
-# Arguments:
-#	stateVar	global state array variable
-#	root		root element type
-#	publit		public identifier literal
-#	systemlist	system identifier literal
-#	dtd		internal DTD subset
-#
-# Results:
-#	DocType node added
-
-proc dom::tcl::ParseDocType {stateVar root {publit {}} {systemlit {}} {dtd {}} args} {
-    upvar #0 $stateVar state
-    upvar #0 $state(docNode) document
-
-    set document(document:doctype) [CreateDocType $state(docNode) $publit $systemlit $dtd]
-
-    return {}
-}
-
-# dom::tcl::ParseComment --
-#
-#	Parse comment
-#
-# Arguments:
-#	stateVar	state array
-#	data		comment data
-#
-# Results:
-#	Comment node added to DOM tree
-
-proc dom::tcl::ParseComment {stateVar data} {
-    upvar #0 $stateVar state
-
-    CreateGeneric [lindex $state(current) end] node:nodeType comment node:nodeValue $data
-
-    return {}
-}
-
-# dom::tcl::ParseEntityReference --
-#
-#	Parse an entity reference
-#
-# Arguments:
-#	stateVar	state variable
-#	ref		entity
-#
-# Results:
-#	Entity reference node added to DOM tree
-
-proc dom::tcl::ParseEntityReference {stateVar ref} {
-    upvar #0 $stateVar state
-
-    CreateGeneric [lindex $state(current) end] node:nodeType entityReference node:nodeName $ref
-
-    return {}
-}
-
-#################################################
-#
-# Trim white space
-#
-#################################################
-
-# dom::tcl::Trim --
-#
-#	Remove textNodes that only contain white space
-#
-# Arguments:
-#	nodeid	node to trim
-#
-# Results:
-#	textNode nodes may be removed (from descendants)
-
-proc dom::tcl::Trim nodeid {
-    upvar #0 $nodeid node
-
-    switch $node(node:nodeType) {
-
-	textNode {
-	    if {![string length [string trim $node(node:nodeValue)]]} {
-		node removeChild $node(node:parentNode) $nodeid
-	    }
-	}
-
-	default {
-	    # Some nodes have no child list.  Reported by Jim Hollister <jhollister at objectspace.com>
-	    set children {}
-	    catch {set children [set $node(node:childNodes)]}
-	    foreach child $children {
-		Trim $child
-	    }
-	}
-
-    }
-
-    return {}
-}
-
-#################################################
-#
-# XPath support
-#
-#################################################
-
-# dom::tcl::XPath:CreateNode --
-#
-#	Given an XPath expression, create the node
-#	referred to by the expression.  Nodes required
-#	as steps of the path are created if they do
-#	not exist.
-#
-# Arguments:
-#	node	context node
-#	path	location path
-#
-# Results:
-#	Node(s) created in the DOM tree.
-#	Returns token for deepest node in the expression.
-
-proc dom::tcl::XPath:CreateNode {node path} {
-
-    set root [::dom::node cget $node -ownerDocument]
-
-    set spath [::xpath::split $path]
-
-    if {[llength $spath] <= 1} {
-	# / - do nothing
-	return $root
-    }
-
-    if {![llength [lindex $spath 0]]} {
-	# Absolute location path
-	set context $root
-	set spath [lrange $spath 1 end]
-	set contexttype document
-    } else {
-	set context $node
-	set contexttype [::dom::node cget $node -nodeType]
-    }
-
-    foreach step $spath {
-
-	# Sanity check on path
-	switch $contexttype {
-	    document -
-	    documentFragment -
-	    element {}
-	    default {
-		return -code error "node type \"$contexttype\" have no children"
-	    }
-	}
-
-	switch [lindex $step 0] {
-
-	    child {
-		if {[llength [lindex $step 1]] > 1} {
-		    foreach {nodetype discard} [lindex $step 1] break
-
-		    switch -- $nodetype {
-			text {
-			    set posn [CreateNode:FindPosition [lindex $step 2]]
-
-			    set count 0
-			    set targetNode {}
-			    foreach child [::dom::node children $context] {
-				switch [::dom::node cget $child -nodeType] {
-				    textNode {
-					incr count
-					if {$count == $posn} {
-					    set targetNode $child
-					    break
-					}
-				    }
-				    default {}
-				}
-			    }
-
-			    if {[string length $targetNode]} {
-				set context $targetNode
-			    } else {
-				# Creating sequential textNodes doesn't make sense
-				set context [::dom::document createTextNode $context {}]
-			    }
-			    set contexttype textNode
-			}
-			default {
-			    return -code error "node type test \"${nodetype}()\" not supported"
-			}
-		    }
-		} else {
-		    # Find the child element
-		    set posn [CreateNode:FindPosition [lindex $step 2]]
-
-		    set count 0
-		    set targetNode {}
-		    foreach child [::dom::node children $context] {
-			switch [node cget $child -nodeType] {
-			    element {
-				if {![string compare [lindex $step 1] [::dom::node cget $child -nodeName]]} {
-				    incr count
-				    if {$count == $posn} {
-					set targetNode $child
-					break
-				    }
-				}
-			    }
-			    default {}
-			}
-		    }
-
-		    if {[string length $targetNode]} {
-			set context $targetNode
-		    } else {
-			# Didn't find it so create required elements
-			while {$count < $posn} {
-			    set child [::dom::document createElement $context [lindex $step 1]]
-			    incr count
-			}
-			set context $child
-		    }
-		    set contexttype element
-
-		}
-	    }
-
-	    default {
-		return -code error "axis \"[lindex $step 0]\" is not supported"
-	    }
-	}
-    }
-
-    return $context
-}
-
-# dom::tcl::CreateNode:FindPosition --
-
-proc dom::tcl::CreateNode:FindPosition predicates {
-    switch [llength $predicates] {
-	0 {
-	    return 1
-	}
-	1 {
-	    # Fall-through
-	}
-	default {
-	    return -code error "multiple predicates not yet supported"
-	}
-    }
-    set predicate [lindex $predicates 0]
-
-    switch -- [lindex [lindex $predicate 0] 0] {
-	function {
-	    switch -- [lindex [lindex $predicate 0] 1] {
-		position {
-		    if {[lindex $predicate 1] == "="} {
-			if {[string compare [lindex [lindex $predicate 2] 0] "number"]} {
-			    return -code error "operand must be a number"
-			} else {
-			    set posn [lindex [lindex $predicate 2] 1]
-			}
-		    } else {
-			return -code error "operator must be \"=\""
-		    }
-		}
-		default {
-		    return -code error "predicate function \"[lindex [lindex $predicate 0] 1]\" not supported"
-		}
-	    }
-	}
-	default {
-	    return -code error "predicate must be position() function"
-	}
-    }
-
-    return $posn
-}
-
-# dom::tcl::XPath:SelectNode --
-#
-#	Match nodes with an XPath location path
-#
-# Arguments:
-#	ctxt	context - Tcl list
-#	path	location path
-#
-# Results:
-#	Returns Tcl list of matching nodes
-
-proc dom::tcl::XPath:SelectNode {ctxt path} {
-
-    if {![llength $ctxt]} {
-	return {}
-    }
-
-    set spath [xpath::split $path]
-
-    if {[string length [node parent [lindex $ctxt 0]]]} {
-	set root [namespace qualifiers [lindex $ctxt 0]]::Document
-    } else {
-	set root [lindex $ctxt 0]
-    }
-
-    if {[llength $spath] == 0} {
-	return $root
-    }
-    if {[llength $spath] == 1 && [llength [lindex $spath 0]] == 0} {
-	return $root
-    }
-
-    if {![llength [lindex $spath 0]]} {
-	set ctxt $root
-	set spath [lrange $spath 1 end]
-    }
-
-    return [XPath:SelectNode:Rel $ctxt $spath]
-}
-
-# dom::tcl::XPath:SelectNode:Rel --
-#
-#	Match nodes with an XPath location path
-#
-# Arguments:
-#	ctxt	context - Tcl list
-#	path	split location path
-#
-# Results:
-#	Returns Tcl list of matching nodes
-
-proc dom::tcl::XPath:SelectNode:Rel {ctxt spath} {
-    if {![llength $spath]} {
-	return $ctxt
-    }
-
-    set step [lindex $spath 0]
-    set result {}
-    switch [lindex $step 0] {
-
-	child {
-	    # All children are candidates
-	    set children {}
-	    foreach node [XPath:SN:GetElementTypeNodes $ctxt] {
-		eval lappend children [node children $node]
-	    }
-
-	    # Now apply node test to each child
-	    foreach node $children {
-		if {[XPath:SN:ApplyNodeTest $node [lindex $step 1]]} {
-		    lappend result $node
-		}
-	    }
-
-	}
-
-	descendant-or-self {
-	    foreach node $ctxt {
-		if {[XPath:SN:ApplyNodeTest $node [lindex $step 1]]} {
-		    lappend result $node
-		}
-		eval lappend result [XPath:SN:DescendAndTest [node children $node] [lindex $step 1]]
-	    }
-	}
-
-	descendant {
-	    foreach node $ctxt {
-		eval lappend result [XPath:SN:DescendAndTest [node children $node] [lindex $step 1]]
-	    }
-	}
-
-	attribute {
-	    if {[string compare [lindex $step 1] "*"]} {
-		foreach node $ctxt {
-		    set attrNode [element getAttributeNode $node [lindex $step 1]]
-		    if {[llength $attrNode]} {
-			lappend result $attrNode
-		    }
-		}
-	    } else {
-		# All attributes are returned
-		foreach node $ctxt {
-		    foreach attrName [array names [node cget $node -attributes]] {
-			set attrNode [element getAttributeNode $node $attrName]
-			if {[llength $attrNode]} {
-			    lappend result $attrNode
-			}
-		    }
-		}
-	    }
-	}
-
-	default {
-	    return -code error "axis \"[lindex $step 0]\" is not supported"
-	}
-    }
-
-    # Now apply predicates
-    set result [XPath:ApplyPredicates $result [lindex $step 2]]
-
-    # Apply the next location step
-    return [XPath:SelectNode:Rel $result [lrange $spath 1 end]]
-}
-
-# dom::tcl::XPath:SN:GetElementTypeNodes --
-#
-#	Reduce nodeset to those nodes of element type
-#
-# Arguments:
-#	nodeset	set of nodes
-#
-# Results:
-#	Returns nodeset in which all nodes are element type
-
-proc dom::tcl::XPath:SN:GetElementTypeNodes nodeset {
-    set result {}
-    foreach node $nodeset {
-	switch [node cget $node -nodeType] {
-	    document -
-	    documentFragment -
-	    element {
-		lappend result $node
-	    }
-	    default {}
-	}
-    }
-    return $result
-}
-
-# dom::tcl::XPath:SN:ApplyNodeTest --
-#
-#	Apply the node test to a node
-#
-# Arguments:
-#	node	DOM node to test
-#	test	node test
-#
-# Results:
-#	1 if node passes, 0 otherwise
-
-proc dom::tcl::XPath:SN:ApplyNodeTest {node test} {
-    if {[llength $test] > 1} {
-	foreach {name typetest} $test break
-	# Node type test
-	switch -glob -- $name,[node cget $node -nodeType] {
-	    node,* {
-		return 1
-	    }
-	    text,textNode -
-	    comment,comment -
-	    processing-instruction,processingInstruction {
-		return 1
-	    }
-	    text,* -
-	    comment,* -
-	    processing-instruction,* {
-		return 0
-	    }
-	    default {
-		return -code error "illegal node type test \"[lindex $step 1]\""
-	    }
-	}
-    } else {
-	# Node name test
-	switch -glob -- $test,[node cget $node -nodeType],[node cget $node -nodeName] \
-		\\*,element,* {
-	    return 1
-	} \
-		\\*,* {
-	    return 0
-	} \
-		*,element,$test {
-	    return 1
-	}
-    }
-
-    return 0
-}
-
-# dom::tcl::XPath:SN:DescendAndTest --
-#
-#	Descend the element hierarchy,
-#	apply the node test as we go
-#
-# Arguments:
-#	nodeset	nodes to be tested and descended
-#	test	node test
-#
-# Results:
-#	Returned nodeset of nodes which pass the test
-
-proc dom::tcl::XPath:SN:DescendAndTest {nodeset test} {
-    set result {}
-
-    foreach node $nodeset {
-	if {[XPath:SN:ApplyNodeTest $node $test]} {
-	    lappend result $node
-	}
-	switch [node cget $node -nodeType] {
-	    document -
-	    documentFragment -
-	    element {
-		eval lappend result [XPath:SN:DescendAndTest [node children $node] $test]
-	    }
-	}
-    }
-
-    return $result
-}
-
-# dom::tcl::XPath:ApplyPredicates --
-#
-#	Filter a nodeset with predicates
-#
-# Arguments:
-#	ctxt	current context nodeset
-#	preds	list of predicates
-#
-# Results:
-#	Returns new (possibly reduced) context nodeset
-
-proc dom::tcl::XPath:ApplyPredicates {ctxt preds} {
-
-    set result {}
-    foreach node $ctxt {
-	set passed 1
-	foreach predicate $preds {
-	    if {![XPath:ApplyPredicate $node $predicate]} {
-		set passed 0
-		break
-	    }
-	}
-	if {$passed} {
-	    lappend result $node
-	}
-    }
-
-    return $result
-}
-
-# dom::tcl::XPath:ApplyPredicate --
-#
-#	Filter a node with a single predicate
-#
-# Arguments:
-#	node	current context node
-#	pred	predicate
-#
-# Results:
-#	Returns boolean
-
-proc dom::tcl::XPath:ApplyPredicate {node pred} {
-
-    switch -- [lindex $pred 0] {
-	= -
-	!= -
-	>= -
-	<= -
-	> -
-	> {
-
-	    if {[llength $pred] != 3} {
-		return -code error "malformed expression"
-	    }
-
-	    set operand1 [XPath:Pred:ResolveExpr $node [lindex $pred 1]]
-	    set operand2 [XPath:Pred:ResolveExpr $node [lindex $pred 2]]
-
-	    # Convert operands to the correct type, if necessary
-	    switch -glob [lindex $operand1 0],[lindex $operand2 0] {
-		literal,literal {
-		    return [XPath:Pred:CompareLiterals [lindex $pred 0] [lindex $operand1 1] [lindex $operand2 1]]
-		}
-
-		number,number -
-		literal,number -
-		number,literal {
-		    # Compare as numbers
-		    return [XPath:Pred:CompareNumbers [lindex $pred 0] [lindex $operand1 1] [lindex $operand2 1]]
-		}
-
-		boolean,boolean {
-		    # Compare as booleans
-		    return -code error "boolean comparison not yet implemented"
-		}
-
-		node,node {
-		    # Nodeset comparison
-		    return -code error "nodeset comparison not yet implemented"
-		}
-
-		node,* {
-		    set value {}
-		    if {[llength [lindex $operand1 1]]} {
-			set value [node stringValue [lindex [lindex $operand1 1] 0]]
-		    }
-		    return [XPath:Pred:CompareLiterals [lindex $pred 0] $value [lindex $operand2 1]]
-		}
-		*,node {
-		    set value {}
-		    if {[llength [lindex $operand2 1]]} {
-			set value [node stringValue [lindex [lindex $operand2 1] 0]]
-		    }
-		    return [XPath:Pred:CompareLiterals [lindex $pred 0] $value [lindex $operand1 1]]
-		}
-
-		default {
-		    return -code error "can't compare [lindex $operand1 0] to [lindex $operand2 0]"
-		}
-	    }
-	}
-
-	function {
-	    return -code error "invalid predicate"
-	}
-	number -
-	literal {
-	    return -code error "invalid predicate"
-	}
-
-	path {
-	    set nodeset [XPath:SelectNode:Rel $node [lindex $pred 1]]
-	    return [expr {[llength $nodeset] > 0 ? 1 : 0}]
-	}
-
-    }
-
-    return 1
-}
-
-# dom::tcl::XPath:Pred:Compare --
-
-proc dom::tcl::XPath:Pred:CompareLiterals {op operand1 operand2} {
-    set result [string compare $operand1 $operand2]
-
-    # The obvious:
-    #return [expr {$result $opMap($op) 0}]
-    # doesn't compile
-    
-    switch $op {
-	= {
-	    return [expr {$result == 0}]
-	}
-	!= {
-	    return [expr {$result != 0}]
-	}
-	<= {
-	    return [expr {$result <= 0}]
-	}
-	>= {
-	    return [expr {$result >= 0}]
-	}
-	< {
-	    return [expr {$result < 0}]
-	}
-	> {
-	    return [expr {$result > 0}]
-	}
-    }
-    return -code error "internal error"
-}
-
-# dom::tcl::XPath:Pred:ResolveExpr --
-
-proc dom::tcl::XPath:Pred:ResolveExpr {node expr} {
-
-    switch [lindex $expr 0] {
-	path {
-	    return [list node [XPath:SelectNode:Rel $node [lindex $expr 1]]]
-	}
-
-	function -
-	group {
-	    return -code error "[lindex $expr 0] not yet implemented"
-	}
-	literal -
-	number -
-	boolean {
-	    return $expr
-	}
-
-	default {
-	    return -code error "internal error"
-	}
-    }
-
-    return {}
-}
-
-#################################################
-#
-# Miscellaneous
-#
-#################################################
-
-# dom::tcl::hasmixedcontent --
-#
-#	Determine whether an element contains mixed content
-#
-# Arguments:
-#	token	dom node
-#
-# Results:
-#	Returns 1 if element contains mixed content,
-#	0 otherwise
-
-proc dom::tcl::hasmixedcontent token {
-    upvar #0 $token node
-
-    if {[string compare $node(node:nodeType) "element"]} {
-	# Really undefined
-	return 0
-    }
-
-    foreach child [set $node(node:childNodes)] {
-	upvar #0 $child childnode
-	if {![string compare $childnode(node:nodeType) "textNode"]} {
-	    return 1
-	}
-    }
-
-    return 0
-}
-
-# dom::tcl::prefix2namespaceURI --
-#
-#	Given an XML Namespace prefix, find the corresponding Namespace URI
-#
-# Arguments:
-#	node	DOM Node
-#	prefix	XML Namespace prefix
-#
-# Results:
-#	Returns URI
-
-proc dom::tcl::prefix2namespaceURI {node prefix} {
-
-    # Search this node and its ancestors for the appropriate
-    # XML Namespace declaration
-
-    set parent [dom::node parent $node]
-    set nsuri [dom::element getAttributeNS $node $::dom::xmlnsURI $prefix]
-    if {[string length $parent] && ![string length $nsuri]} {
-	set nsuri [dom::element getAttributeNS $parent $::dom::xmlnsURI $prefix]
-	set parent [dom::node parent $parent]
-    }
-
-    if {[string length $nsuri]} {
-	return $nsuri
-    } else {
-	return -code error "unable to find namespace URI for prefix \"$prefix\""
-    }
-
-}
-
-# dom::tcl::namespaceURI2prefix --
-#
-#	Given an XML Namespace URI, find the corresponding prefix
-#
-# Arguments:
-#	node	DOM Node
-#	nsuri	XML Namespace URI
-#
-# Results:
-#	Returns prefix
-
-proc dom::tcl::namespaceURI2prefix {node nsuri} {
-
-    # Search this node and its ancestors for the desired
-    # XML Namespace declaration
-
-    set found 0
-    set prefix {}
-    set parent [dom::node parent $node]
-    while {[string length $parent]} {
-	upvar #0 $node nodeinfo
-	catch {unset attrs}
-	array set attrs [array get $nodeinfo(element:attributeList)]
-	foreach {nsdecl declNSuri} [array get attrs ${::dom::xmlnsURI}^*] {
-	    if {![string compare $declNSuri $nsuri]} {
-		set found 1
-		set prefix [lindex [split $nsdecl ^] 1]
-		break
-	    }
-	}
-	if {$found} {
-	    break
-	}
-	set node $parent
-	set parent [dom::node parent $node]
-    }
-
-    if {$found} {
-	return $prefix
-    } else {
-	return -code error "unable to find prefix for namespace URI \"$nsuri\""
-    }
-
-}
-
-# dom::tcl::GetField --
-#
-#	Return a value, or empty string if not defined
-#
-# Arguments:
-#	var	name of variable to return
-#
-# Results:
-#	Returns the value, or empty string if variable is not defined.
-
-proc dom::tcl::GetField var {
-    upvar $var v
-    if {[info exists v]} {
-	return $v
-    } else {
-	return {}
-    }
-}
-
-# dom::tcl::Min --
-#
-#	Return the minimum of two numeric values
-#
-# Arguments:
-#	a	a value
-#	b	another value
-#
-# Results:
-#	Returns the value which is lower than the other.
-
-proc dom::tcl::Min {a b} {
-    return [expr {$a < $b ? $a : $b}]
-}
-
-# dom::tcl::Max --
-#
-#	Return the maximum of two numeric values
-#
-# Arguments:
-#	a	a value
-#	b	another value
-#
-# Results:
-#	Returns the value which is greater than the other.
-
-proc dom::tcl::Max {a b} {
-    return [expr {$a > $b ? $a : $b}]
-}
-
-# dom::tcl::Boolean --
-#
-#	Return a boolean value
-#
-# Arguments:
-#	b	value
-#
-# Results:
-#	Returns 0 or 1
-
-proc dom::tcl::Boolean b {
-    regsub -nocase {^(true|yes|1|on)$} $b 1 b
-    regsub -nocase {^(false|no|0|off)$} $b 0 b
-    return $b
-}
-
diff --git a/tclxml-3.2/tcldom-tcl/dommap.tcl b/tclxml-3.2/tcldom-tcl/dommap.tcl
deleted file mode 100644
index 9d9ec87..0000000
--- a/tclxml-3.2/tcldom-tcl/dommap.tcl
+++ /dev/null
@@ -1,108 +0,0 @@
-# dommap.tcl --
-#
-#	Apply a mapping function to a DOM structure
-#
-# Copyright (c) 1998-2003 Zveno Pty Ltd
-# http://www.zveno.com/
-#
-# See the file "LICENSE" in this distribution for information on usage and
-# redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
-#
-# $Id: dommap.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package provide dommap 1.0
-
-# We need the DOM
-package require dom 2.6
-
-namespace eval dommap {
-    namespace export map
-}
-
-# dommap::apply --
-#
-#	Apply a function to a DOM document.
-#
-#	The callback command is invoked with the node ID of the
-#	matching DOM node as its argument.  The command may return
-#	an error, continue or break code to alter the processing
-#	of further nodes.
-#
-#	Filter functions may be applied to match particular
-#	nodes.  Valid functions include:
-#
-#	-nodeType regexp
-#	-nodeName regexp
-#	-nodeValue regexp
-#	-attribute {regexp regexp}
-#
-#	If a filter is specified then the node must match for the
-#	callback command to be invoked.  If a filter is not specified
-#	then all nodes match that filter.
-#
-# Arguments:
-#	node	DOM document node
-#	cmd	callback command
-#	args	configuration options
-#
-# Results:
-#	Depends on callback command
-
-proc dommap::apply {node cmd args} {
-    array set opts $args
-
-    # Does this node match?
-    set match 1
-    catch {set match [expr $match && [regexp $opts(-nodeType) [::dom::node cget $node -nodeType]]]}
-    catch {set match [expr $match && [regexp $opts(-nodeName) [::dom::node cget $node -nodeName]]]}
-    catch {set match [expr $match && [regexp $opts(-nodeValue) [::dom::node cget $node -nodeValue]]]}
-    if {$match && ![string compare [::dom::node cget $node -nodeType] element]} {
-	set match 0
-	foreach {attrName attrValue} [array get [::dom::node cget $node -attributes]] {
-	    set match 1
-	    catch {set match [expr $match && [regexp [lindex $opts(-attribute) 0] $attrName]]}
-	    catch {set match [expr $match && [regexp [lindex $opts(-attribute) 1] $attrValue]]}
-	    if {$match} break
-	}
-    }
-    if {$match && [set code [catch {eval $cmd [list $node]} msg]]} {
-	switch $code {
-	    0 {}
-	    3 {
-		return -code break
-	    }
-	    4 {
-		return -code continue
-	    }
-	    default {
-		return -code error $msg
-	    }
-	}
-    }
-
-    # Process children
-    foreach child [::dom::node children $node] {
-	switch [catch {eval apply [list $child] [list $cmd] $args} msg] {
-	    0 {
-		# No action required
-	    }
-	    3 {
-		# break
-		return -code break
-	    }
-	    4 {
-		# continue - skip processing of siblings
-		return
-	    }
-	    1 -
-	    2 -
-	    default {
-		# propagate the error message
-		return -code error $msg
-	    }
-	}
-    }
-
-    return {}
-}
-
diff --git a/tclxml-3.2/tcldom-tcl/xmlswitch.tcl b/tclxml-3.2/tcldom-tcl/xmlswitch.tcl
deleted file mode 100644
index 4e2a2a1..0000000
--- a/tclxml-3.2/tcldom-tcl/xmlswitch.tcl
+++ /dev/null
@@ -1,520 +0,0 @@
-# xmlswitch.tcl --
-#
-#	This file implements a control structure for Tcl.
-#	'xmlswitch' iterates over an XML document.  Features in
-#	the document may be specified using XPath location paths,
-#	and these will trigger Tcl scripts when matched.
-#
-# Copyright (c) 2008 Explain
-# http://www.explain.com.au/
-# Copyright (c) 2000-2003 Zveno Pty Ltd
-# http://www.zveno.com/
-#
-# See the file "LICENSE" in this distribution for information on usage and
-# redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
-#
-# $Id: xmlswitch.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package provide xmlswitch 3.2
-
-# We need the xml, dom and xpath packages
-
-package require xml 3.2
-package require dom 3.2
-package require xpath 1.0
-
-namespace eval xmlswitch {
-    namespace export xmlswitch xmlswitchcont xmlswitchend
-    namespace export domswitch
-    namespace export free rootnode
-
-    variable counter 0
-
-    variable typemap
-    array set typemap {
-	text textNode
-	comment comment
-	processing-instruction processingInstruction
-    }
-}
-
-# xmlswitch::xmlswitch --
-#
-#	Parse XML data, matching for XPath locations along the way
-#	and (possibly) triggering callbacks.
-#
-#	A DOM tree is built as a side-effect (necessary for resolving
-#	XPath location paths).
-#
-# Arguments:
-#	xml	XML document
-#	args	configuration options,
-#		plus a single path/script expression, or multiple expressions
-#
-# Results:
-#	Tcl callbacks may be invoked.
-#	If -async option is true returns a token for this "process".
-
-proc xmlswitch::xmlswitch {xml args} {
-    variable counter
-
-    set stateVarName [namespace current]::State[incr counter]
-    upvar #0 $stateVarName state
-    set state(stateVarName) $stateVarName
-    set state(-async) 0
-
-    set state(pathArray) ${stateVarName}Paths
-    upvar #0 $state(pathArray) paths
-    array set paths {}
-
-    set cleanup {
-	unset state
-	unset paths
-    }
-
-    # Find configuration options and remove
-    set numOpts 0
-    foreach {opt value} $args {
-	switch -glob -- $opt {
-	    -* {
-		set state($opt) $value
-		incr numOpts 2
-	    }
-	    default {
-		set args [lrange $args $numOpts end]
-		break
-	    }
-	}
-    }
-
-    switch -- [llength $args] {
-	0 {
-	    # Nothing to do
-	    eval $cleanup
-	    return $stateVarName
-	}
-	1 {
-	    foreach {path script} [lindex $args 0] {
-		set paths([xpath::split $path]) $script
-	    }
-	}
-	default {
-	    if {[llength $args] % 2} {
-		eval $cleanup
-		return -code error "no script matching location path \"[lindex $args end]\""
-	    }
-	    foreach {path script} $args {
-		set paths([xpath::split $path]) $script
-	    }
-	}
-    }
-
-    set root [set state(root) [dom::DOMImplementation create]]
-    set state(current) $root
-
-    # Parse the document
-    # We're going to do this incrementally, so the caller can
-    # break at any time
-    set state(parser) [eval xml::parser [array get state -parser]]
-    #append cleanup "\n $parser destroy\n"
-    $state(parser) configure \
-	    -elementstartcommand [namespace code [list ParseElementStart $stateVarName]]	\
-	    -elementendcommand [namespace code [list ParseElementEnd $stateVarName]]		\
-	    -characterdatacommand [namespace code [list ParseCharacterData $stateVarName]]	\
-	    -final 0
-
-#	    -processinginstructioncommand [namespace code [list ParsePI $stateVarName]]		\
-#	    -commentcommand [namespace code [list ParseComment]]
-
-    if {[catch {$state(parser) parse $xml} err]} {
-	eval $cleanup
-	return -code error $err
-    }
-
-    if {$state(-async)} {
-	return $stateVarName
-    } else {
-	eval $cleanup
-	return {}
-    }
-}
-
-# xmlswitch::xmlswitchcont --
-#
-#	Provide more XML data to parse
-#
-# Arguments:
-#	token	state variable name
-#	xml	XML data
-#
-# Results:
-#	More parsing
-
-proc xmlswitch::xmlswitchcont {token xml} {
-    upvar #0 $token state
-
-    $state(parser) parse $xml
-
-    return {}
-}
-
-# xmlswitch::xmlswitchend --
-#
-#	Signal that no further data is available
-#
-# Arguments:
-#	token	state array
-#
-# Results:
-#	Parser configuration changed
-
-proc xmlswitch::xmlswitchend token {
-    upvar #0 $token state
-
-    $state(parser) configure -final true
-
-    return {}
-}
-
-# xmlswitch::rootnode --
-#
-#	Get the root node
-#
-# Arguments:
-#	token	state array
-#
-# Results:
-#	Returns root node token
-
-proc xmlswitch::rootnode token {
-    upvar #0 $token state
-
-    return $state(root)
-}
-
-# xmlswitch::free --
-#
-#	Free resources EXCEPT the DOM tree.
-#	"-all" causes DOM tree to be destroyed too.
-#
-# Arguments:
-#	token	state array
-#	args	options
-#
-# Results:
-#	Resources freed.
-
-proc xmlswitch::free {token args} {
-    upvar #0 $token state
-
-    if {[lsearch $args "-all"] >= 0} {
-	dom::DOMImplementation destroy $state(root)
-    }
-
-    catch {unset $state(pathArray)}
-    catch {unset state}
-
-    catch {$state(parser) free}
-
-    return {}
-}
-
-# xmlswitch::ParseElementStart --
-#
-#	Handle element start tag
-#
-# Arguments:
-#	token	state array
-#	name	element type
-#	attrList attribute list
-#	args	options
-# Results:
-#	All XPath location paths are checked for a match,
-#	and script evaluated for matching XPath.
-#	DOM tree node added.
-
-proc xmlswitch::ParseElementStart:dbgdisabled {token name attrList args} {
-    if {[catch {eval ParseElementStart:dbg [list $token $name $attrList] $args} msg]} {
-	puts stderr [list ParseElementStart failed with msg $msg]
-	puts stderr $::errorInfo
-	return -code error $msg
-    } else {
-	puts stderr [list ParseElementStart returned OK]
-    }
-    return $msg
-}
-proc xmlswitch::ParseElementStart {token name attrList args} {
-
-    upvar #0 $token state
-    array set opts $args
-
-    #puts stderr [list xmlswitch::ParseElementStart $token $name $attrList $args]
-
-    lappend state(current) \
-	    [dom::document createElement [lindex $state(current) end] $name]
-    foreach {name value} $attrList {
-	dom::element setAttribute [lindex $state(current) end] $name $value
-    }
-
-    MatchTemplates $token [lindex $state(current) end]
-
-    return {}
-}
-
-# xmlswitch::ParseElementEnd --
-#
-#	Handle element end tag
-#
-# Arguments:
-#	token	state array
-#	name	element type
-#	args	options
-# Results:
-#	State changed
-
-proc xmlswitch::ParseElementEnd {token name args} {
-    upvar #0 $token state
-
-    set state(current) [lreplace $state(current) end end]
-
-    return {}
-}
-
-# xmlswitch::ParseCharacterData --
-#
-#	Handle character data
-#
-# Arguments:
-#	token	state array
-#	data	pcdata
-#
-# Results:
-#	All XPath location paths are checked for a match,
-#	and script evaluated for matching XPath.
-#	DOM tree node added.
-
-proc xmlswitch::ParseCharacterData {token data} {
-    upvar #0 $token state
-
-    lappend state(current) \
-	    [dom::document createTextNode [lindex $state(current) end] $data]
-
-    MatchTemplates $token [lindex $state(current) end]
-
-    set state(current) [lreplace $state(current) end end]
-
-    return {}
-}
-
-# xmlswitch::domswitch --
-#
-#	Similar to xmlswitch above, but iterates over a pre-built
-#	DOM tree.
-#
-# Arguments:
-#	xml	XML document
-#	args	a single path/script expression, or multiple expressions
-#
-# Results:
-#	Tcl callbacks may be invoked.
-
-proc xmlswitch::domswitch {xml args} {
-}
-
-# xmlswitch::MatchTemplates --
-#
-#	Check all templates for one which matches
-#	the current node.
-#
-# Arguments:
-#	token	state array
-#	node	Current DOM node
-#
-# Results:
-#	If a template matches, its script is evaluated
-
-proc xmlswitch::MatchTemplates {token node} {
-    upvar #0 $token state
-    upvar #0 $state(pathArray) paths
-
-    #puts stderr [list xmlswitch::MatchTemplates $token $node (type: [dom::node cget $node -nodeType]) (name: [dom::node cget $node -nodeName])]
-
-    set matches {}
-
-    foreach {path script} [array get paths] {
-
-	#puts stderr [list checking path $path for a match]
-
-	set context $node
-
-	# Work backwards along the path, reversing each axis
-	set match 0
-	set i [llength $path]
-	#puts stderr [list $i steps to be tested]
-	while {[incr i -1] >= 0} {
-	    #puts stderr [list step $i [lindex $path $i]]
-	    switch -glob [llength [lindex $path $i]],$i {
-		0,0 {
-		    #puts stderr [list absolute path, end of steps - am I at the root?]
-		    if {![string length [dom::node parent $context]]} {
-			#puts stderr [list absolute path matched]
-			lappend matches [list $path $script]
-		    } else {
-			#puts stderr [list absolute path did not match]
-		    }
-		}
-		*,0 {
-		    #puts stderr [list last step, relative path]
-		    switch [lindex [lindex $path $i] 0] {
-			child {
-			    if {[NodeTest [lindex $path $i] $context] && \
-				    [CheckPredicates [lindex $path $i] $context]} {
-				#puts stderr [list relative path matched]
-				lappend matches [list $path $script]
-			    } else {
-				#puts stderr [list relative path did not match]
-			    }
-			}
-			default {
-			    return -code error "axis \"[lindex [lindex $path $i] 0]\" not supported"
-			}
-		    }
-		}
-		default {
-		    #puts stderr [list continuing checking steps]
-		    switch [lindex [lindex $path $i] 0] {
-			child {
-			    if {[NodeTest [lindex $path $i] $context] && \
-				    [CheckPredicates [lindex $path $i] $context]} {
-				set context [dom::node parent $context]
-			    } else {
-				#puts stderr [list no match]
-			    }
-			}
-			default {
-			    return -code error "axis \"[lindex [lindex $path $i] 0]\" not supported"
-			}
-		    }
-		}
-	    }
-	}
-    }
-
-    # TODO: If there are multiple matches then we must pick the
-    # most specific match
-
-    if {[llength $matches] > 1} {
-	# For the moment we'll just take the first match
-	set matches [list [lindex $matches 0]]
-    }
-
-    if {[llength $matches]} {
-	#puts stderr [list evaluating callback at level [info level]]
-	uplevel 3 [lindex [lindex $matches 0] 1]
-    }
-
-    return {}
-}
-
-# xmlswitch::NodeTest --
-#
-#	Check that the node passes the node (type) test
-#
-# Arguments:
-#	step	Location step
-#	node	DOM node
-#
-# Results:
-#	Boolean
-
-proc xmlswitch::NodeTest {step node} {
-
-    if {[llength [lindex $step 1]] > 1} {
-	switch -glob -- [lindex [lindex $step 1] 0],[dom::node cget $node -nodeType] {
-	    node,* -
-	    text,textNode -
-	    comment,comment -
-	    processing-instruction,processingInstruction {
-		return 1
-	    }
-	    default {
-		return 0
-	    }
-	}
-    } elseif {![string compare [lindex $step 1] "*"]} {
-	return 1
-    } elseif {![string compare [lindex $step 1] [dom::node cget $node -nodeName]]} {
-	return 1
-    } else {
-	return 0
-    }
-}
-
-# xmlswitch::CheckPredicates --
-#
-#	Check that the node passes the predicates
-#
-# Arguments:
-#	step	Location step
-#	node	DOM node
-#
-# Results:
-#	Boolean
-
-proc xmlswitch::CheckPredicates {step node} {
-    variable typemap
-
-    set predicates [lindex $step 2]
-    # Shortcut: no predicates means everything passes
-    if {![llength $predicates]} {
-	return 1
-    }
-
-    # Get the context node set
-    switch [lindex $step 0] {
-	child {
-	    set nodeset {}
-	    if {[llength [lindex $step 1]]} {
-		foreach {name typetest} [lindex $step 1] break
-		switch -- $name {
-		    node {
-			set nodeset [dom::node children [dom::node parent $node]]
-		    }
-		    text -
-		    comment -
-		    processing-instruction {
-			foreach child [dom::node children [dom::node parent $node]] {
-			    if {![string compare [dom::node cget $child -nodeType] $typemap($name)]} {
-				lappend nodeset $child
-			    }
-			}
-		    }
-		    default {
-			# Error
-		    }
-		}
-	    } else {
-		foreach child [dom::node children [dom::node parent $node]] {
-		    if {![string compare [lindex $step 1] [dom::node cget $child -nodeName]]} {
-			lappend nodeset $child
-		    }
-		}
-	    }
-	}
-	default {
-	    return -code error "axis \"[lindex $step 0]\" not supported"
-	}
-    }
-
-    foreach predicate $predicates {
-	# position() is the only supported predicate
-	if {[lsearch $nodeset $node] + 1 == $predicate} {
-	    # continue
-	} else {
-	    return 0
-	}
-    }
-
-    return 1
-}
-
diff --git a/tclxml-3.2/tcldom.c b/tclxml-3.2/tcldom.c
deleted file mode 100644
index 467a9c2..0000000
--- a/tclxml-3.2/tcldom.c
+++ /dev/null
@@ -1,333 +0,0 @@
-/*
- * tcldom.c --
- *
- *	Generic interface to DOM Implementation.
- *	As of v3.0, there is no substantial generic layer;
- *	instead each implementation provides its own commands
- *	directly.  This module now provides common definitions
- *	for method/option tables, etc.
- *
- * Copyright (c) 2006-2007 Explain
- * http://www.explain.com.au/
- * Copyright (c) 2002-2004 Steve Ball, Zveno Pty Ltd
- *
- * See the file "LICENSE" for information on usage and
- * redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
- *
- * $Id: tcldom.c,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
- *
- */
-
-#include <tcldom/tcldom.h>
-
-/*
- * Method tables for commands
- */
-
-#ifndef CONST84
-#define CONST84 /* Before 8.4 no 'const' required */
-#endif
-
-CONST84 char *TclDOM_DOMImplementationCommandMethods[] = {
-  "hasFeature",
-  "createDocument",
-  "create",
-  "createDocumentType",
-  "createNode",
-  "destroy",
-  "isNode",
-  "parse",
-  "selectNode",
-  "serialize",
-  "trim",
-  (char *) NULL
-};
-CONST84 char *TclDOM_DocumentCommandMethods[] = {
-  "cget",
-  "configure",
-  "createElement",
-  "createDocumentFragment",
-  "createTextNode",
-  "createComment",
-  "createCDATASection",
-  "createProcessingInstruction",
-  "createAttribute",
-  "createEntity",
-  "createEntityReference",
-  "createDocTypeDecl",
-  "importNode",
-  "createElementNS",
-  "createAttributeNS",
-  "getElementsByTagNameNS",
-  "getElementsById",
-  "createEvent",
-  "getElementsByTagName",
-  "dtd",
-  "schema",
-  (char *) NULL
-};
-CONST84 char *TclDOM_DocumentCommandOptions[] = {
-  "-doctype",
-  "-implementation",
-  "-documentElement",
-  (char *) NULL
-};
-CONST84 char *TclDOM_DocumentDTDSubmethods[] = {
-  "validate",
-  (char *) NULL
-};
-CONST84 char *TclDOM_DocumentSchemaSubmethods[] = {
-  "compile",
-  "validate",
-  (char *) NULL
-};
-CONST84 char *TclDOM_DocumentRelaxNGSubmethods[] = {
-  "compile",
-  "validate",
-  (char *) NULL
-};
-CONST84 char *TclDOM_NodeCommandMethods[] = {
-  "cget",
-  "configure",
-  "insertBefore",
-  "replaceChild",
-  "removeChild",
-  "appendChild",
-  "hasChildNodes",
-  "cloneNode",
-  "children",
-  "parent",
-  "path",
-  "createNode",
-  "selectNode",
-  "stringValue",
-  "addEventListener",
-  "removeEventListener",
-  "dispatchEvent",
-  "isSameNode",
-  (char *) NULL
-};
-CONST84 char *TclDOM_NodeCommandOptions[] = {
-  "-nodeType",
-  "-parentNode",
-  "-childNodes",
-  "-firstChild",
-  "-lastChild",
-  "-previousSibling",
-  "-nextSibling",
-  "-attributes",
-  "-namespaceURI",
-  "-prefix",
-  "-localName",
-  "-nodeValue",
-  "-cdatasection",
-  "-nodeName",
-  "-ownerDocument",
-  (char *) NULL
-};
-CONST84 char *TclDOM_NodeCommandAddEventListenerOptions[] = {
-  "-usecapture",
-  (char *) NULL
-};
-CONST84 char *TclDOM_ElementCommandMethods[] = {
-  "cget",
-  "configure",
-  "getAttribute",
-  "setAttribute",
-  "removeAttribute",
-  "getAttributeNS",
-  "setAttributeNS",
-  "removeAttributeNS",
-  "getAttributeNode",
-  "setAttributeNode",
-  "removeAttributeNode",
-  "getAttributeNodeNS",
-  "setAttributeNodeNS",
-  "removeAttributeNodeNS",
-  "getElementsByTagName",
-  "normalize",
-  (char *) NULL
-};
-CONST84 char *TclDOM_ElementCommandOptions[] = {
-  "-tagName",
-  "-empty",
-  (char *) NULL
-};
-CONST84 char *TclDOM_EventCommandMethods[] = {
-  "cget",
-  "configure",
-  "stopPropagation",
-  "preventDefault",
-  "initEvent",
-  "initUIEvent",
-  "initMouseEvent",
-  "initMutationEvent",
-  "postUIEvent",
-  "postMouseEvent",
-  "postMutationEvent",
-  (char *) NULL
-};
-CONST84 char *TclDOM_EventCommandOptions[] = {
-  "-altKey",
-  "-attrName",
-  "-attrChange",
-  "-bubbles",
-  "-button",
-  "-cancelable",
-  "-clientX",
-  "-clientY",
-  "-ctrlKey",
-  "-currentNode",
-  "-detail",
-  "-eventPhase",
-  "-metaKey",
-  "-newValue",
-  "-prevValue",
-  "-relatedNode",
-  "-screenX",
-  "-screenY",
-  "-shiftKey",
-  "-target",
-  "-timeStamp",
-  "-type",
-  "-view",
-  (char *) NULL
-};
-CONST84 char *TclDOM_EventTypes[] = {
-  "DOMFocusIn",
-  "DOMFocusOut",
-  "DOMActivate",
-  "click",
-  "mousedown",
-  "mouseup",
-  "mouseover",
-  "mousemove",
-  "mouseout",
-  "DOMSubtreeModified",
-  "DOMNodeInserted",
-  "DOMNodeRemoved",
-  "DOMNodeInsertedIntoDocument",
-  "DOMNodeRemovedFromDocument",
-  "DOMAttrModified",
-  "DOMCharacterDataModified"
-};
-
-CONST84 char *TclDOM_ParseCommandOptions[] = {
-  "-baseuri",
-  "-externalentitycommand",
-  (char *) NULL
-};
-CONST84 char *TclDOM_SerializeCommandOptions[] = {
-  "-indent",
-  "-method",
-  "-encoding",
-  "-omitxmldeclaration",
-  (char *) NULL
-};
-CONST84 char *TclDOM_SerializeMethods[] = {
-  "xml",
-  "html",
-  "text",
-  (char *) NULL
-};
-CONST84 char *TclDOM_SelectNodeOptions[] = {
-  "-namespaces",
-  (char *) NULL
-};
-
-#if 0
-/*
- *----------------------------------------------------------------------------
- *
- * Tcldom_Init --
- *
- *  Initialisation routine for generic module.
- *  NB. As of TclDOM v3.0 this module no longer gets loaded as
- *  a separate package.
- *
- * Results:
- *  None.
- *
- * Side effects:
- *  Creates variables.
- *
- *----------------------------------------------------------------------------
- */
-
-int
-Tcldom_Init (interp)
-      Tcl_Interp *interp; /* Interpreter to initialise. */
-{
-  Tcl_Obj *objPtr;
-
-  Tcl_SetVar(interp, "::dom::strictDOM", "0", TCL_GLOBAL_ONLY);
-  Tcl_SetVar(interp, "::dom::maxSpecials", "10", TCL_GLOBAL_ONLY);
-  objPtr = Tcl_NewListObj(0, NULL);
-  Tcl_ListObjAppendElement(interp, objPtr, Tcl_NewIntObj(2));
-  Tcl_ListObjAppendElement(interp, objPtr, Tcl_NewStringObj("        ", -1));
-  Tcl_ListObjAppendElement(interp, objPtr, Tcl_NewStringObj("\t", -1));
-  Tcl_SetVar2Ex(interp, "::dom::indentspec", NULL, objPtr, TCL_GLOBAL_ONLY);
-  Tcl_SetVar(interp, "::dom::xmlnsURI", "http://www.w3.org/2000/xmlns/", TCL_GLOBAL_ONLY);
-
-  return TCL_OK;
-}
-#endif /* 0 */
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclDOM_SetVars --
- *
- *  Initialisation routine for TclDOM modules.
- *
- * Results:
- *  None.
- *
- * Side effects:
- *  Creates variables.
- *
- *----------------------------------------------------------------------------
- */
-
-int
-TclDOM_SetVars(interp)
-     Tcl_Interp *interp;
-{
-  Tcl_SetVar2Ex(interp, "::dom::bubbles", "DOMFocusIn", Tcl_NewIntObj(1), 0);
-  Tcl_SetVar2Ex(interp, "::dom::bubbles", "DOMFocusOut", Tcl_NewIntObj(1), 0);
-  Tcl_SetVar2Ex(interp, "::dom::bubbles", "DOMActivate", Tcl_NewIntObj(1), 0);
-  Tcl_SetVar2Ex(interp, "::dom::bubbles", "click", Tcl_NewIntObj(1), 0);
-  Tcl_SetVar2Ex(interp, "::dom::bubbles", "mousedown", Tcl_NewIntObj(1), 0);
-  Tcl_SetVar2Ex(interp, "::dom::bubbles", "mouseup", Tcl_NewIntObj(1), 0);
-  Tcl_SetVar2Ex(interp, "::dom::bubbles", "mouseover", Tcl_NewIntObj(1), 0);
-  Tcl_SetVar2Ex(interp, "::dom::bubbles", "mousemove", Tcl_NewIntObj(1), 0);
-  Tcl_SetVar2Ex(interp, "::dom::bubbles", "mouseout", Tcl_NewIntObj(1), 0);
-  Tcl_SetVar2Ex(interp, "::dom::bubbles", "DOMSubtreeModified", Tcl_NewIntObj(1), 0);
-  Tcl_SetVar2Ex(interp, "::dom::bubbles", "DOMNodeInserted", Tcl_NewIntObj(1), 0);
-  Tcl_SetVar2Ex(interp, "::dom::bubbles", "DOMRemoved", Tcl_NewIntObj(1), 0);
-  Tcl_SetVar2Ex(interp, "::dom::bubbles", "DOMNodeInsertedIntoDocument", Tcl_NewIntObj(0), 0);
-  Tcl_SetVar2Ex(interp, "::dom::bubbles", "DOMRemovedFromDocument", Tcl_NewIntObj(0), 0);
-  Tcl_SetVar2Ex(interp, "::dom::bubbles", "DOMAttrModified", Tcl_NewIntObj(1), 0);
-  Tcl_SetVar2Ex(interp, "::dom::bubbles", "DOMAttrRemoved", Tcl_NewIntObj(1), 0);
-  Tcl_SetVar2Ex(interp, "::dom::bubbles", "DOMCharacterDataModified", Tcl_NewIntObj(1), 0);
-
-  Tcl_SetVar2Ex(interp, "::dom::cancelable", "DOMFocusIn", Tcl_NewIntObj(0), 0);
-  Tcl_SetVar2Ex(interp, "::dom::cancelable", "DOMFocusOut", Tcl_NewIntObj(0), 0);
-  Tcl_SetVar2Ex(interp, "::dom::cancelable", "DOMActivate", Tcl_NewIntObj(1), 0);
-  Tcl_SetVar2Ex(interp, "::dom::cancelable", "click", Tcl_NewIntObj(1), 0);
-  Tcl_SetVar2Ex(interp, "::dom::cancelable", "mousedown", Tcl_NewIntObj(1), 0);
-  Tcl_SetVar2Ex(interp, "::dom::cancelable", "mouseup", Tcl_NewIntObj(1), 0);
-  Tcl_SetVar2Ex(interp, "::dom::cancelable", "mouseover", Tcl_NewIntObj(1), 0);
-  Tcl_SetVar2Ex(interp, "::dom::cancelable", "mousemove", Tcl_NewIntObj(0), 0);
-  Tcl_SetVar2Ex(interp, "::dom::cancelable", "mouseout", Tcl_NewIntObj(1), 0);
-  Tcl_SetVar2Ex(interp, "::dom::cancelable", "DOMSubtreeModified", Tcl_NewIntObj(0), 0);
-  Tcl_SetVar2Ex(interp, "::dom::cancelable", "DOMNodeInserted", Tcl_NewIntObj(0), 0);
-  Tcl_SetVar2Ex(interp, "::dom::cancelable", "DOMRemoved", Tcl_NewIntObj(0), 0);
-  Tcl_SetVar2Ex(interp, "::dom::cancelable", "DOMNodeInsertedIntoDocument", Tcl_NewIntObj(0), 0);
-  Tcl_SetVar2Ex(interp, "::dom::cancelable", "DOMRemovedFromDocument", Tcl_NewIntObj(0), 0);
-  Tcl_SetVar2Ex(interp, "::dom::cancelable", "DOMAttrModified", Tcl_NewIntObj(0), 0);
-  Tcl_SetVar2Ex(interp, "::dom::cancelable", "DOMAttrRemoved", Tcl_NewIntObj(0), 0);
-  Tcl_SetVar2Ex(interp, "::dom::cancelable", "DOMCharacterDataModified", Tcl_NewIntObj(0), 0);
-
-  return TCL_OK;
-}
diff --git a/tclxml-3.2/tclxml-libxml2.c b/tclxml-3.2/tclxml-libxml2.c
deleted file mode 100755
index 29ee985..0000000
--- a/tclxml-3.2/tclxml-libxml2.c
+++ /dev/null
@@ -1,982 +0,0 @@
-/* tcllibxml2.c --
- *
- *	A Tcl wrapper for libxml2.
- *
- * Copyright (c) 2005-2008 Explain.
- * http://www.explain.com.au/
- * Copyright (c) 2003-2004 Zveno Pty Ltd
- * http://www.zveno.com/
- *
- * See the file "LICENSE" for information on usage and
- * redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
- *
- * $Id: tclxml-libxml2.c,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
- */
-
-#include <tclxml-libxml2/tclxml-libxml2.h>
-#include <libxml/globals.h>
-#include <libxml/tree.h>
-#include <libxml/parserInternals.h>
-#include <libxml/xmlreader.h>
-#include <libxml/SAX2.h>
-#include <libxml/xmlerror.h>
-#include <libxml/uri.h>
-#include <string.h>
-
-#define TCL_DOES_STUBS \
-    (TCL_MAJOR_VERSION > 8 || TCL_MAJOR_VERSION == 8 && (TCL_MINOR_VERSION > 1 || \
-    (TCL_MINOR_VERSION == 1 && TCL_RELEASE_LEVEL == TCL_FINAL_RELEASE)))
-
-/*
- * The structure below is used to refer to a libxml2 parser object.
- */
-
-typedef struct TclXMLlibxml2Info {
-  Tcl_Interp *interp;		/* Interpreter for this instance */
-
-  xmlTextReaderPtr reader;  /* New TextReader interface */
-
-  Tcl_Obj *docObjPtr;		/* Result of parsing */
-  TclXML_libxml2_DocumentHandling keep;	/* Document handling flag */
-  Tcl_Obj *preserve;  /* XPath for retaining (a portion of) the document */
-  Tcl_Obj *preservens; /* list of namespace declarations */
-
-  TclXML_Info *xmlinfo;		/* Generic data structure */
-
-  Tcl_HashTable *scope;		/* XML namespaces in scope */
-
-} TclXMLlibxml2Info;
-
-/*
- * Forward declarations for private functions.
- */
-
-static ClientData ReaderCreate _ANSI_ARGS_((Tcl_Interp *interp, 
-											TclXML_Info *xmlinfo));
-static int  ReaderReset _ANSI_ARGS_((ClientData clientData));
-static int	TclXMLlibxml2Delete _ANSI_ARGS_((ClientData clientData));
-static int	ReaderParse _ANSI_ARGS_((ClientData clientData, 
-											char *data, int len, int final));
-static int	TclXMLlibxml2Configure _ANSI_ARGS_((ClientData clientdata, 
-						    Tcl_Obj *CONST optionPtr,
-						    Tcl_Obj *CONST valuePtr));
-static int	TclXMLlibxml2Get _ANSI_ARGS_((ClientData clientData, 
-                    int objc, Tcl_Obj *CONST objv[]));
-
-static xmlParserInputPtr TclXMLlibxml2ExternalEntityLoader _ANSI_ARGS_((const char *URL,
-									const char *ID,
-									xmlParserCtxtPtr ctxt));
-
-/*
- * Externally visible functions
- */
-
-typedef struct ThreadSpecificData {
-  int initialized;
-
-  Tcl_Interp *interp;
-
-  /*
-   * Interpose on default external entity loader
-   */
-
-  TclXMLlibxml2Info *current;
-  xmlExternalEntityLoader defaultLoader;
-
-} ThreadSpecificData;
-static Tcl_ThreadDataKey dataKey;
-
-/*
- * libxml2 is mostly thread-safe, but there are issues with error callbacks
- */
-
-TCL_DECLARE_MUTEX(libxml2)
-
-#ifndef CONST84
-#define CONST84 /* Before 8.4 no 'const' required */
-#endif
-
-/*
- *----------------------------------------------------------------------------
- *
- * Tclxml_libxml2_Init --
- *
- *  Initialisation routine for loadable module
- *
- * Results:
- *  None.
- *
- * Side effects:
- *  Creates commands in the interpreter,
- *
- *----------------------------------------------------------------------------
- */
-
-int
-Tclxml_libxml2_Init (interp)
-     Tcl_Interp *interp;	/* Interpreter to initialise */
-{
-  ThreadSpecificData *tsdPtr;
-  TclXML_ParserClassInfo *classinfo;
-
-#ifdef USE_TCL_STUBS
-  if (Tcl_InitStubs(interp, "8.1", 0) == NULL) {
-    return TCL_ERROR;
-  }
-#endif
-#ifdef USE_TCLXML_STUBS
-  if (TclXML_InitStubs(interp, TCLXML_VERSION, 1) == NULL) {
-    return TCL_ERROR;
-  }
-#endif
-
-  classinfo = (TclXML_ParserClassInfo *) ckalloc(sizeof(TclXML_ParserClassInfo));
-  classinfo->name = Tcl_NewStringObj("libxml2", -1);
-  classinfo->create = ReaderCreate;
-  classinfo->createCmd = NULL;
-  classinfo->createEntity = NULL; /* TclXMLlibxml2CreateEntityParser; */
-  classinfo->createEntityCmd = NULL;
-  classinfo->parse = ReaderParse;
-  classinfo->parseCmd = NULL;
-  classinfo->configure = TclXMLlibxml2Configure;
-  classinfo->configureCmd = NULL;
-  classinfo->get = TclXMLlibxml2Get;
-  classinfo->getCmd = NULL;
-  classinfo->destroy = TclXMLlibxml2Delete;
-  classinfo->destroyCmd = NULL;
-  classinfo->reset = ReaderReset;
-  classinfo->resetCmd = NULL;
-
-  if (TclXML_RegisterXMLParser(interp, classinfo) != TCL_OK) {
-    Tcl_SetResult(interp, "unable to register parser", NULL);
-    return TCL_ERROR;
-  }
-
-  /* Configure the libxml2 parser */
-
-  Tcl_MutexLock(&libxml2);
-
-  xmlInitParser();
-  xmlSubstituteEntitiesDefault(1);
-
-  /*
-   * TODO: provide configuration option for setting this value.
-   */
-  xmlLoadExtDtdDefaultValue |= 1;
-  xmlLoadExtDtdDefaultValue |= XML_COMPLETE_ATTRS;
-
-  /*
-   * Override default entity loader so we can implement callbacks
-   */
-
-  tsdPtr = (ThreadSpecificData *) Tcl_GetThreadData(&dataKey, sizeof(ThreadSpecificData));
-
-  if (!tsdPtr->initialized) {
-    tsdPtr->initialized = 1;
-    tsdPtr->interp = interp;
-
-    tsdPtr->current = NULL;
-    tsdPtr->defaultLoader = xmlGetExternalEntityLoader();
-    xmlSetExternalEntityLoader(TclXMLlibxml2ExternalEntityLoader);
-  } /* only need to init the library once per process */
-
-  /* Setting the variable is insufficient - must create namespace too. */
-  if (Tcl_VarEval(interp, "namespace eval ::xml::libxml2 {variable libxml2version ", xmlParserVersion, "}\n", NULL) != TCL_OK) {
-    return TCL_ERROR;
-  }
-
-  Tcl_MutexUnlock(&libxml2);
-
-  TclXML_libxml2_InitDocObj(interp);
-
-  #if (TCL_DOES_STUBS && USE_TCLXML_STUBS)
-    {
-      extern Tclxml_libxml2Stubs tclxml_libxml2Stubs;
-      if (Tcl_PkgProvideEx(interp, "xml::libxml2", TCLXML_VERSION,
-	(ClientData) &tclxml_libxml2Stubs) != TCL_OK) {
-        return TCL_ERROR;
-      }
-    }
-  #else
-    if (Tcl_PkgProvide(interp, "xml::libxml2", TCLXML_VERSION) != TCL_OK) {
-      return TCL_ERROR;
-    }
-  #endif
-
-  return TCL_OK;
-}
-
-/*
- * TclXML/libxml2 is made safe by preventing the use of the default
- * external entity loader.
- */
-
-int
-Tclxml_libxml2_SafeInit (interp)
-     Tcl_Interp *interp;	/* Interpreter to initialise */
-{
-  return Tclxml_libxml2_Init(interp);
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXMLlibxml2Create --
- *
- *	Prepare for parsing.
- *
- * Results:
- *	Standard Tcl result.
- *
- * Side effects:
- *	This creates a Text Reader.
- *
- *----------------------------------------------------------------------------
- */
-
-static ClientData
-ReaderCreate(interp, xmlinfo)
-     Tcl_Interp *interp;
-     TclXML_Info *xmlinfo;
-{
-  TclXMLlibxml2Info *info;
-  xmlParserInputBufferPtr inputPtr;
-
-  if (!(info = (TclXMLlibxml2Info *) Tcl_Alloc(sizeof(TclXMLlibxml2Info)))) {
-    Tcl_Free((char *) info);
-    Tcl_SetResult(interp, "unable to create parser", NULL);
-    return NULL;
-  }
-  info->interp = interp;
-  info->xmlinfo = xmlinfo;
-  info->preserve = NULL;
-  info->preservens = NULL;
-
-  /* Create a dummy input buffer for the purpose of creating the TextReader.
-   * This will be replaced when we come to actually parse the document.
-   */
-  Tcl_MutexLock(&libxml2);
-  inputPtr = xmlAllocParserInputBuffer(XML_CHAR_ENCODING_NONE);
-  if (inputPtr == NULL) {
-	Tcl_MutexUnlock(&libxml2);
-	
-	Tcl_Free((char *) info);
-	Tcl_SetResult(interp, "unable to create input buffer", NULL);
-	return NULL;
-  }
-  info->reader = xmlNewTextReader(inputPtr, NULL);
-  if (info->reader == NULL) {
-	Tcl_MutexUnlock(&libxml2);
-
-	Tcl_Free((char *) info);
-	Tcl_SetResult(interp, "unable to create XML reader", NULL);
-	return NULL;
-  }
-   xmlTextReaderSetStructuredErrorHandler(info->reader,
-					  (xmlStructuredErrorFunc) TclXML_libxml2_ErrorHandler,
-					  NULL);
-
-  Tcl_MutexUnlock(&libxml2);
-
-  info->docObjPtr = NULL;
-  info->keep = TCLXML_LIBXML2_DOCUMENT_IMPLICIT;
-  info->scope = (Tcl_HashTable *) Tcl_Alloc(sizeof(Tcl_HashTable));
-  Tcl_InitHashTable(info->scope, TCL_STRING_KEYS);
-
-  return (ClientData) info;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXMLlibxml2Delete --
- *
- *	Destroy the libxml2 parser structure.
- *
- * Results:
- *	None.
- *
- * Side effects:
- *	Frees any memory allocated for the XML parser.
- *
- *----------------------------------------------------------------------------
- */
-
-static int
-TclXMLlibxml2Delete(clientData)
-     ClientData clientData;
-{
-  TclXMLlibxml2Info *info = (TclXMLlibxml2Info *) clientData;
-
-  if (info->reader) {
-    xmlFreeTextReader(info->reader);
-  }
-  if (info->docObjPtr) {
-    Tcl_DecrRefCount(info->docObjPtr);
-  }
-  if (info->preserve) {
-    Tcl_DecrRefCount(info->preserve);
-  }
-  if (info->preservens) {
-    Tcl_DecrRefCount(info->preservens);
-  }
-  Tcl_DeleteHashTable(info->scope);
-  Tcl_Free((char *) info->scope);
-  Tcl_Free((char *) info);
-
-  return TCL_OK;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * ReaderReset --
- *
- *	Reset the libxml2 parser structure.
- *
- * Results:
- *	None.
- *
- * Side effects:
- *	None.
- *
- *----------------------------------------------------------------------------
- */
-
-static int
-ReaderReset(clientData)
-ClientData clientData;
-{
-  TclXML_Info *xmlinfo = (TclXML_Info *) clientData;
-
-  if (xmlinfo->clientData == NULL) {
-    xmlinfo->clientData = (ClientData) ReaderCreate(xmlinfo->interp, xmlinfo);
-    if (xmlinfo->clientData == NULL) {
-      return TCL_ERROR;
-    }
-  }
-
-  return TCL_OK;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * ReaderParse --
- *
- *	Wrapper to invoke libxml2 parser and check return result.
- *
- *	NB. Most of the logic from xmlSAXUserParseMemory is used here.
- *
- * Results:
- *     TCL_OK if no errors, TCL_ERROR otherwise.
- *
- * Side effects:
- *     Sets interpreter result as appropriate.
- *
- *----------------------------------------------------------------------------
- */
-
-static int
-ReaderParse(clientData, data, len, final)
-     ClientData clientData;
-     char *data;
-     int len;
-     int final;
-{
-  ThreadSpecificData *tsdPtr = (ThreadSpecificData *) Tcl_GetThreadData(&dataKey, sizeof(ThreadSpecificData));
-  TclXMLlibxml2Info *info = (TclXMLlibxml2Info *) clientData;
-  Tcl_Obj *nameObj, *nsObj, *nsdeclObj, *valueObj, *attrsObj, *errObj, *baseuriObj, *sysidObj, *extidObj;
-  const char *baseuri, *encoding, *name, *ns, *value;
-  xmlChar **preservens = NULL;
-  int ret, result = TCL_OK, i, listlen, options = 0, empty;
-
-  /* not used... at present (see case XML_READER_TYPE_DOCUMENT_TYPE)
-    xmlNodePtr nodePtr;
-  */
-  xmlEntityPtr entityPtr = NULL;
-
-  if (final == 0) {
-    Tcl_SetResult(info->interp, "partial input not yet supported", NULL);
-    return TCL_ERROR;
-  }
-
-  if (info->preserve && info->preservens) {
-    if (Tcl_ListObjLength(info->interp, info->preservens, &listlen) != TCL_OK) {
-      return TCL_ERROR;
-    }
-    preservens = (xmlChar **) Tcl_Alloc(len * sizeof(xmlChar *) + 1);
-    for (i = 0; i < listlen; i++) {
-      Tcl_Obj *objPtr;
-      const char *str;
-      int strlen;
-
-      if (Tcl_ListObjIndex(info->interp, info->preservens, i, &objPtr) != TCL_OK) {
-	Tcl_Free((char *) preservens);
-	return TCL_ERROR;
-      }
-      str = Tcl_GetStringFromObj(objPtr, &strlen);
-      preservens[i] = xmlCharStrndup(str, strlen);
-    }
-    preservens[listlen] = NULL;
-  }
-  if (info->xmlinfo->base) {
-	baseuri = Tcl_GetStringFromObj(info->xmlinfo->base, NULL);
-  } else {
-	baseuri = NULL;
-  }
-  if (info->xmlinfo->encoding) {
-	encoding = Tcl_GetStringFromObj(info->xmlinfo->encoding, NULL);
-	if (strcmp(encoding, "unknown") == 0) {
-	  encoding = NULL;
-	}
-  } else {
-	encoding = "utf-8";
-  }
-
-  TclXML_libxml2_ResetError(info->interp);
-
-  options |= XML_PARSE_NOCDATA;
-
-  tsdPtr->current = info;
-
-  Tcl_MutexLock(&libxml2);
-
-  if (info->xmlinfo->expandinternalentities) {
-    options |= XML_PARSE_NOENT;
-    xmlSubstituteEntitiesDefault(1);
-  } else {
-    xmlSubstituteEntitiesDefault(0);
-  }
-  if (info->xmlinfo->nowhitespace) {
-    options |= XML_PARSE_NOBLANKS;
-  }
-
-  if (xmlReaderNewMemory(info->reader,
-			 data, len,
-			 baseuri,
-			 encoding,
-			 options) != 0) {
-    Tcl_MutexUnlock(&libxml2);
-    if (preservens) {
-      int i;
-      for (i = 0; preservens[i]; i++) {
-	xmlFree(preservens[i]);
-      }
-      Tcl_Free((char *) preservens);
-    }
-    tsdPtr->current = NULL;
-    Tcl_SetResult(info->interp, "unable to prepare parser", NULL);
-    return TCL_ERROR;
-  }
-
-  if (info->preserve) {
-    int preserveret;
-    preserveret = xmlTextReaderPreservePattern(info->reader,
-					       (const xmlChar *) Tcl_GetStringFromObj(info->preserve, NULL),
-					       (const xmlChar **) preservens);
-    if (preserveret < 0) {
-      Tcl_MutexUnlock(&libxml2);
-      if (preservens) {
-	int i;
-	for (i = 0; preservens[i]; i++) {
-	  xmlFree(preservens[i]);
-	}
-	Tcl_Free((char *) preservens);
-      }
-      tsdPtr->current = NULL;
-      Tcl_ResetResult(info->interp);
-      Tcl_AppendResult(info->interp,
-		       "preparation for parsing failed: unable to preserve pattern \"",
-		       Tcl_GetStringFromObj(info->preserve, NULL),
-		       "\"",
-		       NULL);
-      return TCL_ERROR;
-    }
-  }
-
-  for (ret = xmlTextReaderRead(info->reader);
-       ret == 1;
-       ret = xmlTextReaderRead(info->reader)) {
-    result = TCL_OK;
-    switch (xmlTextReaderNodeType(info->reader)) {
-    case XML_READER_TYPE_ELEMENT:
-      name = (const char *) xmlTextReaderConstLocalName(info->reader);
-      ns = (const char *) xmlTextReaderConstNamespaceUri(info->reader);
-      Tcl_MutexUnlock(&libxml2);
-      if (name != NULL) {
-	nameObj = Tcl_NewStringObj(name, -1);
-      } else {
-	nameObj = Tcl_NewObj();
-      }
-      Tcl_IncrRefCount(nameObj);
-      if (ns != NULL) {
-	nsObj = Tcl_NewStringObj(ns, -1);
-      } else {
-	nsObj = Tcl_NewObj();
-      }
-      Tcl_IncrRefCount(nsObj);
-
-      attrsObj = Tcl_NewObj();
-      Tcl_IncrRefCount(attrsObj);
-      Tcl_MutexLock(&libxml2);
-      if (xmlTextReaderHasAttributes(info->reader)) {
-	if (xmlTextReaderMoveToFirstAttribute(info->reader) == 1) {
-	  Tcl_Obj *itemObj;
-
-	  itemObj = Tcl_NewObj();
-	  Tcl_SetStringObj(itemObj, (CONST char *) xmlTextReaderConstLocalName(info->reader), -1);
-	  Tcl_ListObjAppendElement(info->interp, attrsObj, itemObj);
-	  itemObj = Tcl_NewStringObj((CONST char *) xmlTextReaderConstValue(info->reader), -1);
-	  Tcl_ListObjAppendElement(info->interp, attrsObj, itemObj);
-
-	  while (xmlTextReaderMoveToNextAttribute(info->reader) == 1) {
-	    itemObj = Tcl_NewStringObj((CONST char *) xmlTextReaderConstLocalName(info->reader), -1);
-	    Tcl_ListObjAppendElement(info->interp, attrsObj, itemObj);
-	    itemObj = Tcl_NewStringObj((CONST char *) xmlTextReaderConstValue(info->reader), -1);
-	    Tcl_ListObjAppendElement(info->interp, attrsObj, itemObj);
-	  }
-	}
-      }
-      empty = xmlTextReaderIsEmptyElement(info->reader);
-      Tcl_MutexUnlock(&libxml2);
-
-      nsdeclObj = Tcl_NewObj();
-      Tcl_IncrRefCount(nsdeclObj);
-
-      TclXML_ElementStartHandler(info->xmlinfo,
-				 nameObj,
-				 nsObj,
-				 attrsObj, nsdeclObj);
-
-      Tcl_DecrRefCount(nsdeclObj);
-
-      if (empty) {
-	TclXML_ElementEndHandler(info->xmlinfo,
-				 nameObj);
-      }
-
-      Tcl_DecrRefCount(nameObj);
-      Tcl_DecrRefCount(nsObj);
-      Tcl_DecrRefCount(attrsObj);
-      break;
-
-    case XML_READER_TYPE_END_ELEMENT:
-      name = (const char *) xmlTextReaderConstLocalName(info->reader);
-      ns = (const char *) xmlTextReaderConstNamespaceUri(info->reader);
-      Tcl_MutexUnlock(&libxml2);
-
-      if (name != NULL) {
-	nameObj = Tcl_NewStringObj(name, -1);
-      } else {
-	nameObj = Tcl_NewObj();
-      }
-      Tcl_IncrRefCount(nameObj);
-      if (ns != NULL) {
-	nsObj = Tcl_NewStringObj(ns, -1);
-      } else {
-	nsObj = Tcl_NewObj();
-      }
-      Tcl_IncrRefCount(nsObj);
-
-      TclXML_ElementEndHandler(info->xmlinfo,
-			       nameObj);
-
-      Tcl_DecrRefCount(nameObj);
-      Tcl_DecrRefCount(nsObj);
-      break;
-
-    case XML_READER_TYPE_TEXT:
-    case XML_READER_TYPE_CDATA:
-    case XML_READER_TYPE_WHITESPACE:
-    case XML_READER_TYPE_SIGNIFICANT_WHITESPACE:
-      value = (const char *) xmlTextReaderConstValue(info->reader);
-      Tcl_MutexUnlock(&libxml2);
-      if (value != NULL) {
-	valueObj = Tcl_NewStringObj(value, -1);
-      } else {
-	valueObj = Tcl_NewObj();
-      }
-      Tcl_IncrRefCount(valueObj);
-
-      TclXML_CharacterDataHandler(info->xmlinfo,
-				  valueObj);
-
-      Tcl_DecrRefCount(valueObj);
-      break;
-
-    case XML_READER_TYPE_COMMENT:
-      value = (const char *) xmlTextReaderConstValue(info->reader);
-      Tcl_MutexUnlock(&libxml2);
-      if (value != NULL) {
-	valueObj = Tcl_NewStringObj(value, -1);
-      } else {
-	valueObj = Tcl_NewObj();
-      }
-
-      TclXML_CommentHandler(info->xmlinfo,
-			    valueObj);
-      break;
-
-    case XML_READER_TYPE_PROCESSING_INSTRUCTION:
-      name = (const char *) xmlTextReaderConstName(info->reader);
-      value = (const char *) xmlTextReaderConstValue(info->reader);
-      Tcl_MutexUnlock(&libxml2);
-      if (name != NULL) {
-	nameObj = Tcl_NewStringObj(name, -1);
-      } else {
-	nameObj = Tcl_NewObj();
-      }
-      if (value != NULL) {
-	valueObj = Tcl_NewStringObj(value, -1);
-      } else {
-	valueObj = Tcl_NewObj();
-      }
-
-      TclXML_ProcessingInstructionHandler(info->xmlinfo,
-					  nameObj,
-					  valueObj);
-      break;
-
-    case XML_READER_TYPE_ENTITY_REFERENCE:
-      name = (const char *) xmlTextReaderConstName(info->reader);
-      baseuri = (const char *) xmlTextReaderConstBaseUri(info->reader);
-      entityPtr = xmlGetDocEntity(xmlTextReaderCurrentDoc(info->reader),
-				  (const xmlChar *) name);
-      Tcl_MutexUnlock(&libxml2);
-
-      nameObj = Tcl_NewStringObj(name, -1);
-      Tcl_IncrRefCount(nameObj);
-      baseuriObj = Tcl_NewStringObj(baseuri, -1);
-      Tcl_IncrRefCount(baseuriObj);
-      sysidObj = Tcl_NewStringObj((CONST char *) entityPtr->SystemID, -1);
-      Tcl_IncrRefCount(sysidObj);
-      extidObj = Tcl_NewStringObj((CONST char *) entityPtr->ExternalID, -1);
-      Tcl_IncrRefCount(extidObj);
-
-      result = TclXML_ExternalEntityRefHandler(info->xmlinfo,
-					       nameObj,
-					       baseuriObj,
-					       sysidObj,
-					       extidObj);
-
-      Tcl_MutexLock(&libxml2);
-
-      Tcl_DecrRefCount(nameObj);
-      Tcl_DecrRefCount(baseuriObj);
-      Tcl_DecrRefCount(sysidObj);
-      Tcl_DecrRefCount(extidObj);
-
-      if (result == TCL_ERROR || result == TCL_BREAK) {
-	Tcl_MutexUnlock(&libxml2);
-	xmlTextReaderClose(info->reader);
-	break;
-      }
-      Tcl_MutexUnlock(&libxml2);
-
-      break;
-
-    case XML_READER_TYPE_DOCUMENT_TYPE:
-      /* these are not used... at present
-	name = xmlTextReaderName(info->reader);
-	nodePtr = xmlTextReaderCurrentNode(info->reader);
-      */
-      Tcl_MutexUnlock(&libxml2);
-
-    default:
-      break;
-    }
-    Tcl_MutexLock(&libxml2);
-  }
-
-  Tcl_MutexUnlock(&libxml2);
-
-  if (preservens) {
-    int i;
-    for (i = 0; preservens[i]; i++) {
-      xmlFree(preservens[i]);
-    }
-    Tcl_Free((char *) preservens);
-  }
-
-  if (ret != 0 || result != TCL_OK) {
-    errObj = TclXML_libxml2_GetErrorObj(info->interp);
-    if (errObj) {
-      Tcl_SetObjResult(info->interp, errObj);
-    } else {
-      Tcl_SetResult(info->interp, "parsing error", NULL);
-    }
-    tsdPtr->current = NULL;
-
-    return TCL_ERROR;
-  }
-
-  info->docObjPtr = TclXML_libxml2_CreateObjFromDoc(xmlTextReaderCurrentDoc(info->reader));
-
-  TclXML_libxml2_DocKeep(info->docObjPtr, info->keep);
-
-  /* TODO: errObjPtr may contain warnings, flush them through */
-  
-  tsdPtr->current = NULL;
-  return TCL_OK;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXMLlibxml2Configure --
- *
- *      Set options for the parser.
- *
- * Results:
- *     None.
- *
- * Side effects:
- *     None (there are no options to set).
- *
- *----------------------------------------------------------------------------
- */
-
-static int
-TclXMLlibxml2Configure(clientData, optionPtr, valuePtr)
-    ClientData clientData;
-    Tcl_Obj *CONST optionPtr;
-    Tcl_Obj *CONST valuePtr;
-{
-  TclXMLlibxml2Info *info = (TclXMLlibxml2Info *) clientData;
-  int option, len;
-  char *value;
-  CONST84 char *Options[] = {
-    "-keep",
-    "-retainpath",
-    "-retainpathns",
-    NULL
-  };
-  enum Options {
-    OPTION_KEEP,
-    OPTION_RETAINPATH,
-    OPTION_RETAINPATHNS
-  };
-  CONST84 char *KeepOptions[] = {
-    "normal",
-    "implicit",
-    NULL
-  };
-  enum KeepOptions {
-    OPTION_KEEP_NORMAL,
-    OPTION_KEEP_IMPLICIT
-  };
-
-  if (Tcl_GetIndexFromObj(info->interp, optionPtr, Options,
-			  "option", 0, &option) != TCL_OK) {
-    /*
-     * Just ignore options we don't understand
-     */
-    return TCL_OK;
-  }
-
-  switch ((enum Options) option) {
-  case OPTION_KEEP:
-
-    value = Tcl_GetStringFromObj(valuePtr, &len);
-    if (len == 0) {
-      info->keep = TCLXML_LIBXML2_DOCUMENT_KEEP;
-      if (info->docObjPtr) {
-	TclXML_libxml2_DocKeep(info->docObjPtr, TCLXML_LIBXML2_DOCUMENT_KEEP);
-	return TCL_BREAK;
-      }
-    } else {
-      if (Tcl_GetIndexFromObj(info->interp, valuePtr, KeepOptions,
-			      "value", 0, &option) != TCL_OK) {
-	return TCL_ERROR;
-      }
-      switch ((enum KeepOptions) option) {
-      case OPTION_KEEP_NORMAL:
-	info->keep = TCLXML_LIBXML2_DOCUMENT_KEEP;
-	if (info->docObjPtr) {
-	  TclXML_libxml2_DocKeep(info->docObjPtr, TCLXML_LIBXML2_DOCUMENT_KEEP);
-	}
-	return TCL_BREAK;
-
-      case OPTION_KEEP_IMPLICIT:
-	info->keep = TCLXML_LIBXML2_DOCUMENT_IMPLICIT;
-	if (info->docObjPtr) {
-	  TclXML_libxml2_DocKeep(info->docObjPtr, TCLXML_LIBXML2_DOCUMENT_IMPLICIT);
-	}
-	return TCL_BREAK;
-
-      default:
-	Tcl_SetResult(info->interp, "bad value", NULL);
-	return TCL_ERROR;
-      }
-    }
-
-    break;
-
-  case OPTION_RETAINPATH:
-	if (info->preserve) {
-	  Tcl_DecrRefCount(info->preserve);
-	}
-	info->preserve = valuePtr;
-	Tcl_IncrRefCount(valuePtr);
-	return TCL_BREAK;
-
-  case OPTION_RETAINPATHNS:
-	if (info->preservens) {
-	  Tcl_DecrRefCount(info->preservens);
-	}
-	info->preservens = valuePtr;
-	Tcl_IncrRefCount(valuePtr);
-	return TCL_BREAK;
-
-  default:
-
-    Tcl_SetResult(info->interp, "no such option", NULL);
-    return TCL_ERROR;
-  }
-
-  return TCL_OK;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXMLlibxml2Get --
- *
- *      Retrieve data from the parser.
- *
- * Results:
- *     Depends on argument.
- *
- * Side effects:
- *     May create Tcl object.
- *
- *----------------------------------------------------------------------------
- */
-
-static int
-TclXMLlibxml2Get(clientData, objc, objv)
-    ClientData clientData;
-    int objc;
-    Tcl_Obj *CONST objv[];
-{
-  TclXMLlibxml2Info *info = (TclXMLlibxml2Info *) clientData;
-  CONST84 char *methods[] = {
-    "document",
-    NULL
-  };
-  enum methods {
-    TCLXML_LIBXML2_GET_DOCUMENT
-  };
-  int option;
-
-  if (objc != 1) {
-    Tcl_WrongNumArgs(info->interp, 0, objv, "method");
-    return TCL_ERROR;
-  }
-
-  if (Tcl_GetIndexFromObj(info->interp, objv[0], methods,
-                          "method", 0, &option) != TCL_OK) {
-    return TCL_ERROR;
-  }
-
-  switch ((enum methods) option) {
-  case TCLXML_LIBXML2_GET_DOCUMENT:
-    if (info->docObjPtr) {
-      Tcl_SetObjResult(info->interp, info->docObjPtr);
-    }
-
-    break;
-
-  default:
-    Tcl_SetResult(info->interp, "unknown method", NULL);
-    return TCL_ERROR;
-  }
-
-  return TCL_OK;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXMLlibxml2ExternalEntityLoader --
- *
- *      Retrieve an external entity, allowing interposing by the application.
- *
- * Results:
- *     External entity parsed.
- *
- * Side effects:
- *     Depends on application callback.
- *
- *----------------------------------------------------------------------------
- */
-
-static xmlParserInputPtr
-Result2ParserInput(interp, ctxt, URL)
-     Tcl_Interp *interp;
-     xmlParserCtxtPtr ctxt;
-     const char *URL;
-{
-  xmlParserInputPtr inputPtr = NULL;
-
-  /* build our own xmlParserInput from returned data */
-  inputPtr = xmlNewStringInputStream(ctxt, (const xmlChar *) Tcl_GetStringFromObj(Tcl_GetObjResult(interp), NULL));
-  if (inputPtr == NULL) {
-    Tcl_SetResult(interp, "unable to create input stream", NULL);
-    Tcl_BackgroundError(interp);
-    return NULL;
-  }
-  inputPtr->filename = (char *) xmlCanonicPath((const xmlChar *) URL);
-
-  return inputPtr;
-}
-
-static xmlParserInputPtr
-TclXMLlibxml2ExternalEntityLoader(URL, ID, ctxt)
-    const char *URL;
-    const char *ID;
-    xmlParserCtxtPtr ctxt;
-{
-  ThreadSpecificData *tsdPtr = (ThreadSpecificData *) Tcl_GetThreadData(&dataKey, sizeof(ThreadSpecificData));
-  TclXMLlibxml2Info *info;
-  Tcl_Interp *interp;
-  int result;
-
-  info = tsdPtr->current;
-
-  if (info) {
-    result = TclXML_ExternalEntityRefHandler(info->xmlinfo, NULL, NULL,
-					     Tcl_NewStringObj(URL, -1),
-					     Tcl_NewStringObj(ID, -1));
-    interp = info->interp;
-  } else {
-    result = TclXML_ExternalEntityRefHandler(NULL, NULL, NULL,
-					     Tcl_NewStringObj(URL, -1),
-					     Tcl_NewStringObj(ID, -1));
-    interp = tsdPtr->interp;
-  }
-
-  switch (result) {
-  case TCL_OK:
-    return Result2ParserInput(interp, ctxt, URL);
-
-  case TCL_BREAK:
-    return NULL;
-
-  case TCL_CONTINUE:
-    break;
-
-  case TCL_ERROR:
-  case TCL_RETURN:
-  default:
-    Tcl_BackgroundError(interp);
-    return NULL;
-  }
-
-  if (Tcl_IsSafe(interp)) {
-    return NULL;
-  } else {
-    return (tsdPtr->defaultLoader)(URL, ID, ctxt);
-  }
-}
diff --git a/tclxml-3.2/tclxml-tcl/sgml-8.0.tcl b/tclxml-3.2/tclxml-tcl/sgml-8.0.tcl
deleted file mode 100755
index f1179cf..0000000
--- a/tclxml-3.2/tclxml-tcl/sgml-8.0.tcl
+++ /dev/null
@@ -1,143 +0,0 @@
-# sgml-8.0.tcl --
-#
-#	This file provides generic parsing services for SGML-based
-#	languages, namely HTML and XML.
-#	This file supports Tcl 8.0 characters and regular expressions.
-#
-#	NB.  It is a misnomer.  There is no support for parsing
-#	arbitrary SGML as such.
-#
-# Copyright (c) 1998,1999 Zveno Pty Ltd
-# http://www.zveno.com/
-#
-# See the file "LICENSE" in this distribution for information on usage and
-# redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
-#
-# $Id: sgml-8.0.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require -exact Tcl 8.0
-
-package provide sgml 1.9
-
-namespace eval sgml {
-
-    # Convenience routine
-    proc cl x {
-	return "\[$x\]"
-    }
-
-    # Define various regular expressions
-
-    # Character classes
-    variable Char \t\n\r\ -\xFF
-    variable BaseChar A-Za-z
-    variable Letter $BaseChar
-    variable Digit 0-9
-    variable CombiningChar {}
-    variable Extender {}
-    variable Ideographic {}
-
-    # white space
-    variable Wsp " \t\r\n"
-    variable noWsp [cl ^$Wsp]
-
-    # Various XML names
-    variable NameChar \[-$Letter$Digit._:$CombiningChar$Extender\]
-    variable Name \[_:$BaseChar$Ideographic\]$NameChar*
-    variable Names ${Name}(?:$Wsp$Name)*
-    variable Nmtoken $NameChar+
-    variable Nmtokens ${Nmtoken}(?:$Wsp$Nmtoken)*
-
-    # table of predefined entities for XML
-
-    variable EntityPredef
-    array set EntityPredef {
-	lt <   gt >   amp &   quot \"   apos '
-    }
-
-}
-
-# These regular expressions are defined here once for better performance
-
-namespace eval sgml {
-    variable Wsp
-
-    # Watch out for case-sensitivity
-
-    set attlist_exp [cl $Wsp]*([cl ^$Wsp]+)[cl $Wsp]*([cl ^$Wsp]+)[cl $Wsp]*(#REQUIRED|#IMPLIED)
-    set attlist_enum_exp [cl $Wsp]*([cl ^$Wsp]+)[cl $Wsp]*\\(([cl ^)]*)\\)[cl $Wsp]*("([cl ^")])")? ;# "
-    set attlist_fixed_exp [cl $Wsp]*([cl ^$Wsp]+)[cl $Wsp]*([cl ^$Wsp]+)[cl $Wsp]*(#FIXED)[cl $Wsp]*([cl ^$Wsp]+)
-
-    set param_entity_exp [cl $Wsp]*([cl ^$Wsp]+)[cl $Wsp]*([cl ^"$Wsp]*)[cl $Wsp]*"([cl ^"]*)"
-
-    set notation_exp [cl $Wsp]*([cl ^$Wsp]+)[cl $Wsp]*(.*)
-
-}
-
-### Utility procedures
-
-# sgml::noop --
-#
-#	A do-nothing proc
-#
-# Arguments:
-#	args	arguments
-#
-# Results:
-#	Nothing.
-
-proc sgml::noop args {
-    return 0
-}
-
-# sgml::identity --
-#
-#	Identity function.
-#
-# Arguments:
-#	a	arbitrary argument
-#
-# Results:
-#	$a
-
-proc sgml::identity a {
-    return $a
-}
-
-# sgml::Error --
-#
-#	Throw an error
-#
-# Arguments:
-#	args	arguments
-#
-# Results:
-#	Error return condition.
-
-proc sgml::Error args {
-    uplevel return -code error [list $args]
-}
-
-### Following procedures are based on html_library
-
-# sgml::zapWhite --
-#
-#	Convert multiple white space into a single space.
-#
-# Arguments:
-#	data	plain text
-#
-# Results:
-#	As above
-
-proc sgml::zapWhite data {
-    regsub -all "\[ \t\r\n\]+" $data { } data
-    return $data
-}
-
-proc sgml::Boolean value {
-    regsub {1|true|yes|on} $value 1 value
-    regsub {0|false|no|off} $value 0 value
-    return $value
-}
-
diff --git a/tclxml-3.2/tclxml-tcl/sgml-8.1.tcl b/tclxml-3.2/tclxml-tcl/sgml-8.1.tcl
deleted file mode 100755
index 60748bb..0000000
--- a/tclxml-3.2/tclxml-tcl/sgml-8.1.tcl
+++ /dev/null
@@ -1,143 +0,0 @@
-# sgml-8.1.tcl --
-#
-#	This file provides generic parsing services for SGML-based
-#	languages, namely HTML and XML.
-#	This file supports Tcl 8.1 characters and regular expressions.
-#
-#	NB.  It is a misnomer.  There is no support for parsing
-#	arbitrary SGML as such.
-#
-# Copyright (c) 1998-2003 Zveno Pty Ltd
-# http://www.zveno.com/
-#
-# See the file "LICENSE" in this distribution for information on usage and
-# redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
-#
-# $Id: sgml-8.1.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require Tcl 8.1
-
-package provide sgml 1.9
-
-namespace eval sgml {
-
-    # Convenience routine
-    proc cl x {
-	return "\[$x\]"
-    }
-
-    # Define various regular expressions
-
-    # Character classes
-    variable Char \t\n\r\ -\uD7FF\uE000-\uFFFD\u10000-\u10FFFF
-    variable BaseChar \u0041-\u005A\u0061-\u007A\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u00FF\u0100-\u0131\u0134-\u013E\u0141-\u0148\u014A-\u017E\u0180-\u01C3\u01CD-\u01F0\u01F4-\u01F5\u01FA-\u0217\u0250-\u02A8\u02BB-\u02C1\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03CE\u03D0-\u03D6\u03DA\u03DC\u03DE\u03E0\u03E2-\u03F3\u0401-\u040C\u040E-\u044F\u0451-\u045C\u045E-\u0481\u0490-\u04C4\u04C7-\u04C8\u04CB-\u04CC\u04D0-\u04EB\u04EE-\u04F5\u04F8-\u04F9\u0531-\u0556\u0559\u0561-\u0586\u05D0-\u05EA\u05F0-\u05F2\u0621-\u063A\u0641-\u064A\u0671-\u06B7\u06BA-\u06BE\u06C0-\u06CE\u06D0-\u06D3\u06D5\u06E5-\u06E6\u0905-\u0939\u093D\u0958-\u0961\u0985-\u098C\u098F-\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09DC-\u09DD\u09DF-\u09E1\u09F0-\u09F1\u0A05-\u0A0A\u0A0F-\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32-\u0A33\u0A35-\u0A36\u0A38-\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8B\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2-\u0AB3\u0AB5-\u0AB9\u0ABD\u0AE0\u0B05-\u0B0C\u0B0F-\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32-\u0B33\u0B36-\u0B39\u0B3D\u0B5C-\u0B5D\u0B5F-\u0B61\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99-\u0B9A\u0B9C\u0B9E-\u0B9F\u0BA3-\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB5\u0BB7-\u0BB9\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C33\u0C35-\u0C39\u0C60-\u0C61\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CDE\u0CE0-\u0CE1\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D28\u0D2A-\u0D39\u0D60-\u0D61\u0E01-\u0E2E\u0E30\u0E32-\u0E33\u0E40-\u0E45\u0E81-\u0E82\u0E84\u0E87-\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA-\u0EAB\u0EAD-\u0EAE\u0EB0\u0EB2-\u0EB3\u0EBD\u0EC0-\u0EC4\u0F40-\u0F47\u0F49-\u0F69\u10A0-\u10C5\u10D0-\u10F6\u1100\u1102-\u1103\u1105-\u1107\u1109\u110B-\u110C\u110E-\u1112\u113C\u113E\u1140\u114C\u114E\u1150\u1154-\u1155\u1159\u115F-\u1161\u1163\u1165\u1167\u1169\u116D-\u116E\u1172-\u1173\u1175\u119E\u11A8\u11AB\u11AE-\u11AF\u11B7-\u11B8\u11BA\u11BC-\u11C2\u11EB\u11F0\u11F9\u1E00-\u1E9B\u1EA0-\u1EF9\u1F00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2126\u212A-\u212B\u212E\u2180-\u2182\u3041-\u3094\u30A1-\u30FA\u3105-\u312C\uAC00-\uD7A3  
-    variable Ideographic \u4E00-\u9FA5\u3007\u3021-\u3029
-    variable CombiningChar \u0300-\u0345\u0360-\u0361\u0483-\u0486\u0591-\u05A1\u05A3-\u05B9\u05BB-\u05BD\u05BF\u05C1-\u05C2\u05C4\u064B-\u0652\u0670\u06D6-\u06DC\u06DD-\u06DF\u06E0-\u06E4\u06E7-\u06E8\u06EA-\u06ED\u0901-\u0903\u093C\u093E-\u094C\u094D\u0951-\u0954\u0962-\u0963\u0981-\u0983\u09BC\u09BE\u09BF\u09C0-\u09C4\u09C7-\u09C8\u09CB-\u09CD\u09D7\u09E2-\u09E3\u0A02\u0A3C\u0A3E\u0A3F\u0A40-\u0A42\u0A47-\u0A48\u0A4B-\u0A4D\u0A70-\u0A71\u0A81-\u0A83\u0ABC\u0ABE-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0B01-\u0B03\u0B3C\u0B3E-\u0B43\u0B47-\u0B48\u0B4B-\u0B4D\u0B56-\u0B57\u0B82-\u0B83\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD7\u0C01-\u0C03\u0C3E-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55-\u0C56\u0C82-\u0C83\u0CBE-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5-\u0CD6\u0D02-\u0D03\u0D3E-\u0D43\u0D46-\u0D48\u0D4A-\u0D4D\u0D57\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0EB1\u0EB4-\u0EB9\u0EBB-\u0EBC\u0EC8-\u0ECD\u0F18-\u0F19\u0F35\u0F37\u0F39\u0F3E\u0F3F\u0F71-\u0F84\u0F86-\u0F8B\u0F90-\u0F95\u0F97\u0F99-\u0FAD\u0FB1-\u0FB7\u0FB9\u20D0-\u20DC\u20E1\u302A-\u302F\u3099\u309A
-    variable Digit \u0030-\u0039\u0660-\u0669\u06F0-\u06F9\u0966-\u096F\u09E6-\u09EF\u0A66-\u0A6F\u0AE6-\u0AEF\u0B66-\u0B6F\u0BE7-\u0BEF\u0C66-\u0C6F\u0CE6-\u0CEF\u0D66-\u0D6F\u0E50-\u0E59\u0ED0-\u0ED9\u0F20-\u0F29
-    variable Extender \u00B7\u02D0\u02D1\u0387\u0640\u0E46\u0EC6\u3005\u3031-\u3035\u309D-\u309E\u30FC-\u30FE
-    variable Letter $BaseChar|$Ideographic
-
-    # white space
-    variable Wsp " \t\r\n"
-    variable noWsp [cl ^$Wsp]
-
-    # Various XML names
-    variable NameChar \[-$Letter$Digit._:$CombiningChar$Extender\]
-    variable Name \[_:$BaseChar$Ideographic\]$NameChar*
-    variable Names ${Name}(?:$Wsp$Name)*
-    variable Nmtoken $NameChar+
-    variable Nmtokens ${Nmtoken}(?:$Wsp$Nmtoken)*
-
-    # table of predefined entities for XML
-
-    variable EntityPredef
-    array set EntityPredef {
-	lt <   gt >   amp &   quot \"   apos '
-    }
-
-}
-
-# These regular expressions are defined here once for better performance
-
-namespace eval sgml {
-    variable Wsp
-
-    # Watch out for case-sensitivity
-
-    set attlist_exp [cl $Wsp]*([cl ^$Wsp]+)[cl $Wsp]*([cl ^$Wsp]+)[cl $Wsp]*(#REQUIRED|#IMPLIED)
-    set attlist_enum_exp [cl $Wsp]*([cl ^$Wsp]+)[cl $Wsp]*\\(([cl ^)]*)\\)[cl $Wsp]*("([cl ^")]*)")? ;# "
-    set attlist_fixed_exp [cl $Wsp]*([cl ^$Wsp]+)[cl $Wsp]*([cl ^$Wsp]+)[cl $Wsp]*(#FIXED)[cl $Wsp]*([cl ^$Wsp]+)
-
-    set param_entity_exp [cl $Wsp]*([cl ^$Wsp]+)[cl $Wsp]*([cl ^"$Wsp]*)[cl $Wsp]*"([cl ^"]*)"
-
-    set notation_exp [cl $Wsp]*([cl ^$Wsp]+)[cl $Wsp]*(.*)
-
-}
-
-### Utility procedures
-
-# sgml::noop --
-#
-#	A do-nothing proc
-#
-# Arguments:
-#	args	arguments
-#
-# Results:
-#	Nothing.
-
-proc sgml::noop args {
-    return 0
-}
-
-# sgml::identity --
-#
-#	Identity function.
-#
-# Arguments:
-#	a	arbitrary argument
-#
-# Results:
-#	$a
-
-proc sgml::identity a {
-    return $a
-}
-
-# sgml::Error --
-#
-#	Throw an error
-#
-# Arguments:
-#	args	arguments
-#
-# Results:
-#	Error return condition.
-
-proc sgml::Error args {
-    uplevel return -code error [list $args]
-}
-
-### Following procedures are based on html_library
-
-# sgml::zapWhite --
-#
-#	Convert multiple white space into a single space.
-#
-# Arguments:
-#	data	plain text
-#
-# Results:
-#	As above
-
-proc sgml::zapWhite data {
-    regsub -all "\[ \t\r\n\]+" $data { } data
-    return $data
-}
-
-proc sgml::Boolean value {
-    regsub {1|true|yes|on} $value 1 value
-    regsub {0|false|no|off} $value 0 value
-    return $value
-}
-
diff --git a/tclxml-3.2/tclxml-tcl/sgmlparser.tcl b/tclxml-3.2/tclxml-tcl/sgmlparser.tcl
deleted file mode 100755
index 2677a44..0000000
--- a/tclxml-3.2/tclxml-tcl/sgmlparser.tcl
+++ /dev/null
@@ -1,2814 +0,0 @@
-# sgmlparser.tcl --
-#
-#	This file provides the generic part of a parser for SGML-based
-#	languages, namely HTML and XML.
-#
-#	NB.  It is a misnomer.  There is no support for parsing
-#	arbitrary SGML as such.
-#
-#	See sgml.tcl for variable definitions.
-#
-# Copyright (c) 2008 Explain
-# http://www.explain.com.au/
-# Copyright (c) 1998-2003 Zveno Pty Ltd
-# http://www.zveno.com/
-#
-# See the file "LICENSE" in this distribution for information on usage and
-# redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
-#
-# $Id: sgmlparser.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require sgml 1.9
-
-package require uri 1.1
-
-package provide sgmlparser 1.1
-
-namespace eval sgml {
-    namespace export tokenise parseEvent
-
-    namespace export parseDTD
-
-    # NB. Most namespace variables are defined in sgml-8.[01].tcl
-    # to account for differences between versions of Tcl.
-    # This especially includes the regular expressions used.
-
-    variable ParseEventNum
-    if {![info exists ParseEventNum]} {
-	set ParseEventNum 0
-    }
-    variable ParseDTDnum
-    if {![info exists ParseDTDNum]} {
-	set ParseDTDNum 0
-    }
-
-    variable declExpr [cl $::sgml::Wsp]*([cl ^$::sgml::Wsp]+)[cl $::sgml::Wsp]*([cl ^>]*)
-    variable EntityExpr [cl $::sgml::Wsp]*(%[cl $::sgml::Wsp])?[cl $::sgml::Wsp]*($::sgml::Name)[cl $::sgml::Wsp]+(.*)
-
-    #variable MarkupDeclExpr <([cl ^$::sgml::Wsp>]+)[cl $::sgml::Wsp]*([cl ^$::sgml::Wsp]+)[cl $::sgml::Wsp]*([cl ^>]*)>
-    #variable MarkupDeclSub "} {\\1} {\\2} {\\3} {"
-    variable MarkupDeclExpr <[cl $::sgml::Wsp]*([cl ^$::sgml::Wsp>]+)[cl $::sgml::Wsp]*([cl ^>]*)>
-    variable MarkupDeclSub "\} {\\1} {\\2} \{"
-
-    variable ExternalEntityExpr ^(PUBLIC|SYSTEM)[cl $::sgml::Wsp]+("|')(.*?)\\2([cl $::sgml::Wsp]+("|')(.*?)\\2)?([cl $::sgml::Wsp]+NDATA[cl $::sgml::Wsp]+($::xml::Name))?\$
-
-    variable StdOptions
-    array set StdOptions [list \
-	-elementstartcommand		[namespace current]::noop	\
-	-elementendcommand		[namespace current]::noop	\
-	-characterdatacommand		[namespace current]::noop	\
-	-processinginstructioncommand	[namespace current]::noop	\
-	-externalentitycommand		{}				\
-	-xmldeclcommand			[namespace current]::noop	\
-	-doctypecommand			[namespace current]::noop	\
-	-commentcommand			[namespace current]::noop	\
-	-entitydeclcommand		[namespace current]::noop	\
-	-unparsedentitydeclcommand	[namespace current]::noop	\
-	-parameterentitydeclcommand	[namespace current]::noop	\
-	-notationdeclcommand		[namespace current]::noop	\
-	-elementdeclcommand		[namespace current]::noop	\
-	-attlistdeclcommand		[namespace current]::noop	\
-	-paramentityparsing		1				\
-	-defaultexpandinternalentities	1				\
-	-startdoctypedeclcommand	[namespace current]::noop	\
-	-enddoctypedeclcommand		[namespace current]::noop	\
-	-entityreferencecommand		{}				\
-	-warningcommand			[namespace current]::noop	\
-	-errorcommand			[namespace current]::Error	\
-	-final				1				\
-	-validate			0				\
-	-baseuri			{}				\
-	-name				{}				\
-	-cmd				{}				\
-	-emptyelement			[namespace current]::EmptyElement	\
-	-parseattributelistcommand	[namespace current]::noop	\
-	-parseentitydeclcommand		[namespace current]::noop	\
-	-normalize			1				\
-	-internaldtd			{}				\
-	-reportempty			0				\
-	-ignorewhitespace		0				\
-    ]
-}
-
-# sgml::tokenise --
-#
-#	Transform the given HTML/XML text into a Tcl list.
-#
-# Arguments:
-#	sgml		text to tokenize
-#	elemExpr	RE to recognise tags
-#	elemSub		transform for matched tags
-#	args		options
-#
-# Valid Options:
-#       -internaldtdvariable
-#	-final		boolean		True if no more data is to be supplied
-#	-statevariable	varName		Name of a variable used to store info
-#
-# Results:
-#	Returns a Tcl list representing the document.
-
-proc sgml::tokenise {sgml elemExpr elemSub args} {
-    array set options {-final 1}
-    array set options $args
-    set options(-final) [Boolean $options(-final)]
-
-    # If the data is not final then there must be a variable to store
-    # unused data.
-    if {!$options(-final) && ![info exists options(-statevariable)]} {
-	return -code error {option "-statevariable" required if not final}
-    }
-
-    # Pre-process stage
-    #
-    # Extract the internal DTD subset, if any
-
-    catch {upvar #0 $options(-internaldtdvariable) dtd}
-    if {[regexp {<!DOCTYPE[^[<]+\[([^]]+)\]} $sgml discard dtd]} {
-	regsub {(<!DOCTYPE[^[<]+)(\[[^]]+\])} $sgml {\1\&xml:intdtd;} sgml
-    }
-
-    # Protect Tcl special characters
-    regsub -all {([{}\\])} $sgml {\\\1} sgml
-
-    # Do the translation
-
-    if {[info exists options(-statevariable)]} {
-	# Mats: Several rewrites here to handle -final 0 option.
-	# If any cached unparsed xml (state(leftover)), prepend it.
-	upvar #0 $options(-statevariable) state
-	if {[string length $state(leftover)]} {
-	    regsub -all $elemExpr $state(leftover)$sgml $elemSub sgml
-	    set state(leftover) {}
-	} else {
-	    regsub -all $elemExpr $sgml $elemSub sgml
-	}
-	set sgml "{} {} {} \{$sgml\}"
-
-	# Performance note (Tcl 8.0):
-	#	Use of lindex, lreplace will cause parsing to list object
-
-	# This RE only fixes chopped inside tags, not chopped text.
-	if {[regexp {^([^<]*)(<[^>]*$)} [lindex $sgml end] x text rest]} {
-	    set sgml [lreplace $sgml end end $text]
-	    # Mats: unmatched stuff means that it is chopped off. Cache it for next round.
-	    set state(leftover) $rest
-	}
-
-	# Patch from bug report #596959, Marshall Rose
-	if {[string compare [lindex $sgml 4] ""]} {
-	    set sgml [linsert $sgml 0 {} {} {} {} {}]
-	}
-
-    } else {
-
-	# Performance note (Tcl 8.0):
-	#	In this case, no conversion to list object is performed
-
-	# Mats: This fails if not -final and $sgml is chopped off right in a tag.	
-	regsub -all $elemExpr $sgml $elemSub sgml
-	set sgml "{} {} {} \{$sgml\}"
-    }
-
-    return $sgml
-
-}
-
-# sgml::parseEvent --
-#
-#	Produces an event stream for a XML/HTML document,
-#	given the Tcl list format returned by tokenise.
-#
-#	This procedure checks that the document is well-formed,
-#	and throws an error if the document is found to be not
-#	well formed.  Warnings are passed via the -warningcommand script.
-#
-#	The procedure only check for well-formedness,
-#	no DTD is required.  However, facilities are provided for entity expansion.
-#
-# Arguments:
-#	sgml		Instance data, as a Tcl list.
-#	args		option/value pairs
-#
-# Valid Options:
-#	-final			Indicates end of document data
-#	-validate		Boolean to enable validation
-#	-baseuri		URL for resolving relative URLs
-#	-elementstartcommand	Called when an element starts
-#	-elementendcommand	Called when an element ends
-#	-characterdatacommand	Called when character data occurs
-#	-entityreferencecommand	Called when an entity reference occurs
-#	-processinginstructioncommand	Called when a PI occurs
-#	-externalentitycommand	Called for an external entity reference
-#
-#	-xmldeclcommand		Called when the XML declaration occurs
-#	-doctypecommand		Called when the document type declaration occurs
-#	-commentcommand		Called when a comment occurs
-#	-entitydeclcommand	Called when a parsed entity is declared
-#	-unparsedentitydeclcommand	Called when an unparsed external entity is declared
-#	-parameterentitydeclcommand	Called when a parameter entity is declared
-#	-notationdeclcommand	Called when a notation is declared
-#	-elementdeclcommand	Called when an element is declared
-#	-attlistdeclcommand	Called when an attribute list is declared
-#	-paramentityparsing	Boolean to enable/disable parameter entity substitution
-#	-defaultexpandinternalentities	Boolean to enable/disable expansion of entities declared in internal DTD subset
-#
-#	-startdoctypedeclcommand	Called when the Doc Type declaration starts (see also -doctypecommand)
-#	-enddoctypedeclcommand	Called when the Doc Type declaration ends (see also -doctypecommand)
-#
-#	-errorcommand		Script to evaluate for a fatal error
-#	-warningcommand		Script to evaluate for a reportable warning
-#	-statevariable		global state variable
-#	-normalize		whether to normalize names
-#	-reportempty		whether to include an indication of empty elements
-#	-ignorewhitespace	whether to automatically strip whitespace
-#
-# Results:
-#	The various callback scripts are invoked.
-#	Returns empty string.
-#
-# BUGS:
-#	If command options are set to empty string then they should not be invoked.
-
-proc sgml::parseEvent {sgml args} {
-    variable Wsp
-    variable noWsp
-    variable Nmtoken
-    variable Name
-    variable ParseEventNum
-    variable StdOptions
-
-    array set options [array get StdOptions]
-    catch {array set options $args}
-
-    # Mats:
-    # If the data is not final then there must be a variable to persistently store the parse state.
-    if {!$options(-final) && ![info exists options(-statevariable)]} {
-	return -code error {option "-statevariable" required if not final}
-    }
-    
-    foreach {opt value} [array get options *command] {
-	if {[string compare $opt "-externalentitycommand"] && ![string length $value]} {
-	    set options($opt) [namespace current]::noop
-	}
-    }
-
-    if {![info exists options(-statevariable)]} {
-	set options(-statevariable) [namespace current]::ParseEvent[incr ParseEventNum]
-    }
-    if {![info exists options(entities)]} {
-	set options(entities) [namespace current]::Entities$ParseEventNum
-	array set $options(entities) [array get [namespace current]::EntityPredef]
-    }
-    if {![info exists options(extentities)]} {
-	set options(extentities) [namespace current]::ExtEntities$ParseEventNum
-    }
-    if {![info exists options(parameterentities)]} {
-	set options(parameterentities) [namespace current]::ParamEntities$ParseEventNum
-    }
-    if {![info exists options(externalparameterentities)]} {
-	set options(externalparameterentities) [namespace current]::ExtParamEntities$ParseEventNum
-    }
-    if {![info exists options(elementdecls)]} {
-	set options(elementdecls) [namespace current]::ElementDecls$ParseEventNum
-    }
-    if {![info exists options(attlistdecls)]} {
-	set options(attlistdecls) [namespace current]::AttListDecls$ParseEventNum
-    }
-    if {![info exists options(notationdecls)]} {
-	set options(notationdecls) [namespace current]::NotationDecls$ParseEventNum
-    }
-    if {![info exists options(namespaces)]} {
-	set options(namespaces) [namespace current]::Namespaces$ParseEventNum
-    }
-
-    # For backward-compatibility
-    catch {set options(-baseuri) $options(-baseurl)}
-
-    # Choose an external entity resolver
-
-    if {![string length $options(-externalentitycommand)]} {
-	if {$options(-validate)} {
-	    set options(-externalentitycommand) [namespace code ResolveEntity]
-	} else {
-	    set options(-externalentitycommand) [namespace code noop]
-	}
-    }
-
-    upvar #0 $options(-statevariable) state
-    upvar #0 $options(entities) entities
-
-    # Mats:
-    # The problem is that the state is not maintained when -final 0 !
-    # I've switched back to an older version here. 
-    
-    if {![info exists state(line)]} {
-	# Initialise the state variable
-	array set state {
-	    mode normal
-	    haveXMLDecl 0
-	    haveDocElement 0
-	    inDTD 0
-	    context {}
-	    stack {}
-	    line 0
-	    defaultNS {}
-	    defaultNSURI {}
-	}
-    }
-
-    foreach {tag close param text} $sgml {
-
-	# Keep track of lines in the input
-	incr state(line) [regsub -all \n $param {} discard]
-	incr state(line) [regsub -all \n $text {} discard]
-
-	# If the current mode is cdata or comment then we must undo what the
-	# regsub has done to reconstitute the data
-
-	set empty {}
-	switch $state(mode) {
-	    comment {
-		# This had "[string length $param] && " as a guard -
-		# can't remember why :-(
-		if {[regexp ([cl ^-]*)--\$ $tag discard comm1]} {
-		    # end of comment (in tag)
-		    set tag {}
-		    set close {}
-		    set state(mode) normal
-		    DeProtect1 $options(-commentcommand) $state(commentdata)<$comm1
-		    unset state(commentdata)
-		} elseif {[regexp ([cl ^-]*)--\$ $param discard comm1]} {
-		    # end of comment (in attributes)
-		    DeProtect1 $options(-commentcommand) $state(commentdata)<$close$tag>$comm1
-		    unset state(commentdata)
-		    set tag {}
-		    set param {}
-		    set close {}
-		    set state(mode) normal
-		} elseif {[regexp ([cl ^-]*)-->(.*) $text discard comm1 text]} {
-		    # end of comment (in text)
-		    DeProtect1 $options(-commentcommand) $state(commentdata)<$close$tag$param>$comm1
-		    unset state(commentdata)
-		    set tag {}
-		    set param {}
-		    set close {}
-		    set state(mode) normal
-		} else {
-		    # comment continues
-		    append state(commentdata) <$close$tag$param>$text
-		    continue
-		}
-	    }
-	    cdata {
-		if {[string length $param] && [regexp ([cl ^\]]*)\]\][cl $Wsp]*\$ $tag discard cdata1]} {
-		    # end of CDATA (in tag)
-		    PCDATA [array get options] $state(cdata)<[subst -nocommand -novariable $close$cdata1]
-		    set text [subst -novariable -nocommand $text]
-		    set tag {}
-		    unset state(cdata)
-		    set state(mode) normal
-		} elseif {[regexp ([cl ^\]]*)\]\][cl $Wsp]*\$ $param discard cdata1]} {
-		    # end of CDATA (in attributes)
-		    PCDATA [array get options] $state(cdata)<[subst -nocommand -novariable $close$tag$cdata1]
-		    set text [subst -novariable -nocommand $text]
-		    set tag {}
-		    set param {}
-		    unset state(cdata)
-		    set state(mode) normal
-		} elseif {[regexp (.*)\]\][cl $Wsp]*>(.*) $text discard cdata1 text]} {
-		    # end of CDATA (in text)
-		    PCDATA [array get options] $state(cdata)<[subst -nocommand -novariable $close$tag$param>$cdata1]
-		    set text [subst -novariable -nocommand $text]
-		    set tag {}
-		    set param {}
-		    set close {}
-		    unset state(cdata)
-		    set state(mode) normal
-		} else {
-		    # CDATA continues
-		    append state(cdata) [subst -nocommand -novariable <$close$tag$param>$text]
-		    continue
-		}
-	    }
-	    continue {
-		# We're skipping elements looking for the close tag
-		switch -glob -- [string length $tag],[regexp {^\?|!.*} $tag],$close {
-		    0,* {
-			continue
-		    }
-		    *,0, {
-			if {![string compare $tag $state(continue:tag)]} {
-			    set empty [uplevel #0 $options(-emptyelement) [list $tag $param $empty]]
-			    if {![string length $empty]} {
-				incr state(continue:level)
-			    }
-			}
-			continue
-		    }
-		    *,0,/ {
-			if {![string compare $tag $state(continue:tag)]} {
-			    incr state(continue:level) -1
-			}
-			if {!$state(continue:level)} {
-			    unset state(continue:tag)
-			    unset state(continue:level)
-			    set state(mode) {}
-			}
-		    }
-		    default {
-			continue
-		    }
-		}
-	    }
-	    default {
-		# The trailing slash on empty elements can't be automatically separated out
-		# in the RE, so we must do it here.
-		regexp (.*)(/)[cl $Wsp]*$ $param discard param empty
-	    }
-	}
-
-	# default: normal mode
-
-	# Bug: if the attribute list has a right angle bracket then the empty
-	# element marker will not be seen
-
-	set empty [uplevel #0 $options(-emptyelement) [list $tag $param $empty]]
-
-	switch -glob -- [string length $tag],[regexp {^\?|!.*} $tag],$close,$empty {
-
-	    0,0,, {
-		# Ignore empty tag - dealt with non-normal mode above
-	    }
-	    *,0,, {
-
-		# Start tag for an element.
-
-		# Check if the internal DTD entity is in an attribute value
-		regsub -all &xml:intdtd\; $param \[$options(-internaldtd)\] param
-
-		set code [catch {ParseEvent:ElementOpen $tag $param [array get options]} msg]
-		set state(haveDocElement) 1
-		switch $code {
-		    0 {# OK}
-		    3 {
-			# break
-			return {}
-		    }
-		    4 {
-			# continue
-			# Remember this tag and look for its close
-			set state(continue:tag) $tag
-			set state(continue:level) 1
-			set state(mode) continue
-			continue
-		    }
-		    default {
-			return -code $code -errorinfo $::errorInfo $msg
-		    }
-		}
-
-	    }
-
-	    *,0,/, {
-
-		# End tag for an element.
-
-		set code [catch {ParseEvent:ElementClose $tag [array get options]} msg]
-		switch $code {
-		    0 {# OK}
-		    3 {
-			# break
-			return {}
-		    }
-		    4 {
-			# continue
-			# skip sibling nodes
-			set state(continue:tag) [lindex $state(stack) end]
-			set state(continue:level) 1
-			set state(mode) continue
-			continue
-		    }
-		    default {
-			return -code $code -errorinfo $::errorInfo $msg
-		    }
-		}
-
-	    }
-
-	    *,0,,/ {
-
-		# Empty element
-
-		# The trailing slash sneaks through into the param variable
-		regsub -all /[cl $::sgml::Wsp]*\$ $param {} param
-
-		set code [catch {ParseEvent:ElementOpen $tag $param [array get options] -empty 1} msg]
-		set state(haveDocElement) 1
-		switch $code {
-		    0 {# OK}
-		    3 {
-			# break
-			return {}
-		    }
-		    4 {
-			# continue
-			# Pretty useless since it closes straightaway
-		    }
-		    default {
-			return -code $code -errorinfo $::errorInfo $msg
-		    }
-		}
-		set code [catch {ParseEvent:ElementClose $tag [array get options] -empty 1} msg]
-		switch $code {
-		    0 {# OK}
-		    3 {
-			# break
-			return {}
-		    }
-		    4 {
-			# continue
-			# skip sibling nodes
-			set state(continue:tag) [lindex $state(stack) end]
-			set state(continue:level) 1
-			set state(mode) continue
-			continue
-		    }
-		    default {
-			return -code $code -errorinfo $::errorInfo $msg
-		    }
-		}
-
-	    }
-
-	    *,1,* {
-		# Processing instructions or XML declaration
-		switch -glob -- $tag {
-
-		    {\?xml} {
-			# XML Declaration
-			if {$state(haveXMLDecl)} {
-			    uplevel #0 $options(-errorcommand) [list illegalcharacter "unexpected characters \"<$tag\" around line $state(line)"]
-			} elseif {![regexp {\?$} $param]} {
-			    uplevel #0 $options(-errorcommand) [list missingcharacters "XML Declaration missing characters \"?>\" around line $state(line)"]
-			} else {
-
-			    # We can do the parsing in one step with Tcl 8.1 RE's
-			    # This has the benefit of performing better WF checking
-
-			    set adv_re [format {^[%s]*version[%s]*=[%s]*("|')(-+|[a-zA-Z0-9_.:]+)\1([%s]+encoding[%s]*=[%s]*("|')([A-Za-z][-A-Za-z0-9._]*)\4)?([%s]*standalone[%s]*=[%s]*("|')(yes|no)\7)?[%s]*\?$} $::sgml::Wsp $::sgml::Wsp $::sgml::Wsp $::sgml::Wsp $::sgml::Wsp $::sgml::Wsp $::sgml::Wsp $::sgml::Wsp $::sgml::Wsp $::sgml::Wsp]
-
-			    if {[catch {regexp $adv_re $param discard delimiter version discard delimiter encoding discard delimiter standalone} matches]} {
-				# Otherwise we must fallback to 8.0.
-				# This won't detect certain well-formedness errors
-
-				# Get the version number
-				if {[regexp [format {[%s]*version[%s]*=[%s]*"(-+|[a-zA-Z0-9_.:]+)"[%s]*} $::sgml::Wsp $::sgml::Wsp $::sgml::Wsp $::sgml::Wsp] $param discard version] || [regexp [format {[%s]*version[%s]*=[%s]*'(-+|[a-zA-Z0-9_.:]+)'[%s]*} $::sgml::Wsp $::sgml::Wsp $::sgml::Wsp $::sgml::Wsp] $param discard version]} {
-				    if {[string compare $version "1.0"]} {
-					# Should we support future versions?
-					# At least 1.X?
-					uplevel #0 $options(-errorcommand) [list versionincompatibility "document XML version \"$version\" is incompatible with XML version 1.0"]
-				    }
-				} else {
-				    uplevel #0 $options(-errorcommand) [list missingversion "XML Declaration missing version information around line $state(line)"]
-				}
-
-				# Get the encoding declaration
-				set encoding {}
-				regexp [format {[%s]*encoding[%s]*=[%s]*"([A-Za-z]([A-Za-z0-9._]|-)*)"[%s]*} $::sgml::Wsp $::sgml::Wsp $::sgml::Wsp $::sgml::Wsp] $param discard encoding
-				regexp [format {[%s]*encoding[%s]*=[%s]*'([A-Za-z]([A-Za-z0-9._]|-)*)'[%s]*} $::sgml::Wsp $::sgml::Wsp $::sgml::Wsp $::sgml::Wsp] $param discard encoding
-
-				# Get the standalone declaration
-				set standalone {}
-				regexp [format {[%s]*standalone[%s]*=[%s]*"(yes|no)"[%s]*} $::sgml::Wsp $::sgml::Wsp $::sgml::Wsp $::sgml::Wsp] $param discard standalone
-				regexp [format {[%s]*standalone[%s]*=[%s]*'(yes|no)'[%s]*} $::sgml::Wsp $::sgml::Wsp $::sgml::Wsp $::sgml::Wsp] $param discard standalone
-
-				# Invoke the callback
-				uplevel #0 $options(-xmldeclcommand) [list $version $encoding $standalone]
-
-			    } elseif {$matches == 0} {
-				uplevel #0 $options(-errorcommand) [list illformeddeclaration "XML Declaration not well-formed around line $state(line)"]
-			    } else {
-
-				# Invoke the callback
-				uplevel #0 $options(-xmldeclcommand) [list $version $encoding $standalone]
-
-			    }
-
-			}
-
-		    }
-
-		    {\?*} {
-			# Processing instruction
-			set tag [string range $tag 1 end]
-			if {[regsub {\?$} $tag {} tag]} {
-			    if {[string length [string trim $param]]} {
-				uplevel #0 $options(-errorcommand) [list unexpectedtext "unexpected text \"$param\" in processing instruction around line $state(line)"]
-			    }
-			} elseif {![regexp ^$Name\$ $tag]} {
-			    uplevel #0 $options(-errorcommand) [list illegalcharacter "illegal character in processing instruction target \"$tag\""]
-			} elseif {[regexp {[xX][mM][lL]} $tag]} {
-			    uplevel #0 $options(-errorcommand) [list illegalcharacters "characters \"xml\" not permitted in processing instruction target \"$tag\""]
-			} elseif {![regsub {\?$} $param {} param]} {
-			    uplevel #0 $options(-errorcommand) [list missingquestion "PI: expected '?' character around line $state(line)"]
-			}
-			set code [catch {uplevel #0 $options(-processinginstructioncommand) [list $tag [string trimleft $param]]} msg]
-			switch $code {
-			    0 {# OK}
-			    3 {
-				# break
-				return {}
-			    }
-			    4 {
-				# continue
-				# skip sibling nodes
-				set state(continue:tag) [lindex $state(stack) end]
-				set state(continue:level) 1
-				set state(mode) continue
-				continue
-			    }
-			    default {
-				return -code $code -errorinfo $::errorInfo $msg
-			    }
-			}
-		    }
-
-		    !DOCTYPE {
-			# External entity reference
-			# This should move into xml.tcl
-			# Parse the params supplied.  Looking for Name, ExternalID and MarkupDecl
-			set matched [regexp ^[cl $Wsp]*($Name)[cl $Wsp]*(.*) $param x state(doc_name) param]
-			set state(doc_name) [Normalize $state(doc_name) $options(-normalize)]
-			set externalID {}
-			set pubidlit {}
-			set systemlit {}
-			set externalID {}
-			if {[regexp -nocase ^[cl $Wsp]*(SYSTEM|PUBLIC)(.*) $param x id param]} {
-			    switch [string toupper $id] {
-				SYSTEM {
-				    if {[regexp ^[cl $Wsp]+"([cl ^"]*)"(.*) $param x systemlit param] || [regexp ^[cl $Wsp]+'([cl ^']*)'(.*) $param x systemlit param]} {
-					set externalID [list SYSTEM $systemlit] ;# "
-				    } else {
-					uplevel #0 $options(-errorcommand) {syntaxerror {syntax error: SYSTEM identifier not followed by literal}}
-				    }
-				}
-				PUBLIC {
-				    if {[regexp ^[cl $Wsp]+"([cl ^"]*)"(.*) $param x pubidlit param] || [regexp ^[cl $Wsp]+'([cl ^']*)'(.*) $param x pubidlit param]} {
-					if {[regexp ^[cl $Wsp]+"([cl ^"]*)"(.*) $param x systemlit param] || [regexp ^[cl $Wsp]+'([cl ^']*)'(.*) $param x systemlit param]} {
-					    set externalID [list PUBLIC $pubidlit $systemlit]
-					} else {
-					    uplevel #0 $options(-errorcommand) [list syntaxerror "syntax error: PUBLIC identifier not followed by system literal around line $state(line)"]
-					}
-				    } else {
-					uplevel #0 $options(-errorcommand) [list syntaxerror "syntax error: PUBLIC identifier not followed by literal around line $state(line)"]
-				    }
-				}
-			    }
-			    if {[regexp -nocase ^[cl $Wsp]+NDATA[cl $Wsp]+($Name)(.*) $param x notation param]} {
-				lappend externalID $notation
-			    }
-			}
-
-			set state(inDTD) 1
-
-			ParseEvent:DocTypeDecl [array get options] $state(doc_name) $pubidlit $systemlit $options(-internaldtd)
-
-			set state(inDTD) 0
-
-		    }
-
-		    !--* {
-
-			# Start of a comment
-			# See if it ends in the same tag, otherwise change the
-			# parsing mode
-
-			regexp {!--(.*)} $tag discard comm1
-			if {[regexp ([cl ^-]*)--[cl $Wsp]*\$ $comm1 discard comm1_1]} {
-			    # processed comment (end in tag)
-			    uplevel #0 $options(-commentcommand) [list $comm1_1]
-			} elseif {[regexp ([cl ^-]*)--[cl $Wsp]*\$ $param discard comm2]} {
-			    # processed comment (end in attributes)
-			    uplevel #0 $options(-commentcommand) [list $comm1$comm2]
-			} elseif {[regexp ([cl ^-]*)-->(.*) $text discard comm2 text]} {
-			    # processed comment (end in text)
-			    uplevel #0 $options(-commentcommand) [list $comm1$param$empty>$comm2]
-			} else {
-			    # start of comment
-			    set state(mode) comment
-			    set state(commentdata) "$comm1$param$empty>$text"
-			    continue
-			}
-		    }
-
-		    {!\[CDATA\[*} {
-
-			regexp {!\[CDATA\[(.*)} $tag discard cdata1
-			if {[regexp {(.*)]]$} $cdata1 discard cdata2]} {
-			    # processed CDATA (end in tag)
-			    PCDATA [array get options] [subst -novariable -nocommand $cdata2]
-			    set text [subst -novariable -nocommand $text]
-			} elseif {[regexp {(.*)]]$} $param discard cdata2]} {
-			    # processed CDATA (end in attribute)
-			    # Backslashes in param are quoted at this stage
-			    PCDATA [array get options] $cdata1[subst -novariable -nocommand $cdata2]
-			    set text [subst -novariable -nocommand $text]
-			} elseif {[regexp {(.*)]]>(.*)} $text discard cdata2 text]} {
-			    # processed CDATA (end in text)
-			    # Backslashes in param and text are quoted at this stage
-			    PCDATA [array get options] $cdata1[subst -novariable -nocommand $param]$empty>[subst -novariable -nocommand $cdata2]
-			    set text [subst -novariable -nocommand $text]
-			} else {
-			    # start CDATA
-			    set state(cdata) "$cdata1$param>$text"
-			    set state(mode) cdata
-			    continue
-			}
-
-		    }
-
-		    !ELEMENT -
-		    !ATTLIST -
-		    !ENTITY -
-		    !NOTATION {
-			uplevel #0 $options(-errorcommand) [list illegaldeclaration "[string range $tag 1 end] declaration not expected in document instance around line $state(line)"]
-		    }
-
-		    default {
-			uplevel #0 $options(-errorcommand) [list unknowninstruction "unknown processing instruction \"<$tag>\" around line $state(line)"]
-		    }
-		}
-	    }
-	    *,1,* -
-	    *,0,/,/ {
-		# Syntax error
-	    	uplevel #0 $options(-errorcommand) [list syntaxerror "syntax error: closed/empty tag: tag $tag param $param empty $empty close $close around line $state(line)"]
-	    }
-	}
-
-	# Process character data
-
-	if {$state(haveDocElement) && [llength $state(stack)]} {
-
-	    # Check if the internal DTD entity is in the text
-	    regsub -all &xml:intdtd\; $text \[$options(-internaldtd)\] text
-
-	    # Look for entity references
-	    if {([array size entities] || \
-		    [string length $options(-entityreferencecommand)]) && \
-		    $options(-defaultexpandinternalentities) && \
-		    [regexp {&[^;]+;} $text]} {
-
-		# protect Tcl specials
-		# NB. braces and backslashes may already be protected
-		regsub -all {\\({|}|\\)} $text {\1} text
-		regsub -all {([][$\\{}])} $text {\\\1} text
-
-		# Mark entity references
-		regsub -all {&([^;]+);} $text [format {%s; %s {\1} ; %s %s} \}\} [namespace code [list Entity [array get options] $options(-entityreferencecommand) [namespace code [list PCDATA [array get options]]] $options(entities)]] [namespace code [list DeProtect [namespace code [list PCDATA [array get options]]]]] \{\{] text
-		set text "uplevel #0 [namespace code [list DeProtect1 [namespace code [list PCDATA [array get options]]]]] {{$text}}"
-		eval $text
-	    } else {
-
-		# Restore protected special characters
-		regsub -all {\\([][{}\\])} $text {\1} text
-		PCDATA [array get options] $text
-	    }
-	} elseif {[string length [string trim $text]]} {
-	    uplevel #0 $options(-errorcommand) [list unexpectedtext "unexpected text \"$text\" in document prolog around line $state(line)"]
-	}
-
-    }
-
-    # If this is the end of the document, close all open containers
-    if {$options(-final) && [llength $state(stack)]} {
-	eval $options(-errorcommand) [list unclosedelement "element [lindex $state(stack) end] remains unclosed around line $state(line)"]
-    }
-
-    return {}
-}
-
-# sgml::DeProtect --
-#
-#	Invoke given command after removing protecting backslashes
-#	from given text.
-#
-# Arguments:
-#	cmd	Command to invoke
-#	text	Text to deprotect
-#
-# Results:
-#	Depends on command
-
-proc sgml::DeProtect1 {cmd text} {
-    if {[string compare {} $text]} {
-	regsub -all {\\([]$[{}\\])} $text {\1} text
-	uplevel #0 $cmd [list $text]
-    }
-}
-proc sgml::DeProtect {cmd text} {
-    set text [lindex $text 0]
-    if {[string compare {} $text]} {
-	regsub -all {\\([]$[{}\\])} $text {\1} text
-	uplevel #0 $cmd [list $text]
-    }
-}
-
-# sgml::ParserDelete --
-#
-#	Free all memory associated with parser
-#
-# Arguments:
-#	var	global state array
-#
-# Results:
-#	Variables unset
-
-proc sgml::ParserDelete var {
-    upvar #0 $var state
-
-    if {![info exists state]} {
-	return -code error "unknown parser"
-    }
-
-    catch {unset $state(entities)}
-    catch {unset $state(parameterentities)}
-    catch {unset $state(elementdecls)}
-    catch {unset $state(attlistdecls)}
-    catch {unset $state(notationdecls)}
-    catch {unset $state(namespaces)}
-
-    unset state
-
-    return {}
-}
-
-# sgml::ParseEvent:ElementOpen --
-#
-#	Start of an element.
-#
-# Arguments:
-#	tag	Element name
-#	attr	Attribute list
-#	opts	Options
-#	args	further configuration options
-#
-# Options:
-#	-empty boolean
-#		indicates whether the element was an empty element
-#
-# Results:
-#	Modify state and invoke callback
-
-proc sgml::ParseEvent:ElementOpen {tag attr opts args} {
-    variable Name
-    variable Wsp
-
-    array set options $opts
-    upvar #0 $options(-statevariable) state
-    array set cfg {-empty 0}
-    array set cfg $args
-    set handleEmpty 0
-
-    if {$options(-normalize)} {
-	set tag [string toupper $tag]
-    }
-
-    # Update state
-    lappend state(stack) $tag
-
-    # Parse attribute list into a key-value representation
-    if {[string compare $options(-parseattributelistcommand) {}]} {
-	if {[catch {uplevel #0 $options(-parseattributelistcommand) [list $opts $attr]} attr]} {
-	    if {[string compare [lindex $attr 0] "unterminated attribute value"]} {
-		uplevel #0 $options(-errorcommand) [list unterminatedattribute "$attr around line $state(line)"]
-		set attr {}
-	    } else {
-
-		# It is most likely that a ">" character was in an attribute value.
-		# This manifests itself by ">" appearing in the element's text.
-		# In this case the callback should return a three element list;
-		# the message "unterminated attribute value", the attribute list it
-		# did manage to parse and the remainder of the attribute list.
-
-		foreach {msg attlist brokenattr} $attr break
-
-		upvar text elemText
-		if {[string first > $elemText] >= 0} {
-
-		    # Now piece the attribute list back together
-		    regexp [cl $Wsp]*($Name)[cl $Wsp]*=[cl $Wsp]*("|')(.*) $brokenattr discard attname delimiter attvalue
-		    regexp (.*)>([cl ^>]*)\$ $elemText discard remattlist elemText
-		    regexp ([cl ^$delimiter]*)${delimiter}(.*) $remattlist discard remattvalue remattlist
-
-		    # Gotcha: watch out for empty element syntax
-		    if {[string match */ [string trimright $remattlist]]} {
-			set remattlist [string range $remattlist 0 end-1]
-			set handleEmpty 1
-			set cfg(-empty) 1
-		    }
-
-		    append attvalue >$remattvalue
-		    lappend attlist $attname $attvalue
-
-		    # Complete parsing the attribute list
-		    if {[catch {uplevel #0 $options(-parseattributelistcommand) [list $options(-statevariable) $remattlist]} attr]} {
-			uplevel #0 $options(-errorcommand) [list unterminatedattribute "$attr around line $state(line)"]
-			set attr {}
-			set attlist {}
-		    } else {
-			eval lappend attlist $attr
-		    }
-
-		    set attr $attlist
-
-		} else {
-		    uplevel #0 $options(-errorcommand) [list unterminatedattribute "$attr around line $state(line)"]
-		    set attr {}
-		}
-	    }
-	}
-    }
-
-    set empty {}
-    if {$cfg(-empty) && $options(-reportempty)} {
-	set empty {-empty 1}
-    }
-
-    # Check for namespace declarations
-    upvar #0 $options(namespaces) namespaces
-    set nsdecls {}
-    if {[llength $attr]} {
-	array set attrlist $attr
-	foreach {attrName attrValue} [array get attrlist xmlns*] {
-	    unset attrlist($attrName)
-	    set colon [set prefix {}]
-	    if {[regexp {^xmlns(:(.+))?$} $attrName discard colon prefix]} {
-		switch -glob [string length $colon],[string length $prefix] {
-		    0,0 {
-			# default NS declaration
-			lappend state(defaultNSURI) $attrValue
-			lappend state(defaultNS) [llength $state(stack)]
-			lappend nsdecls $attrValue {}
-		    }
-		    0,* {
-			# Huh?
-		    }
-		    *,0 {
-			# Error
-			uplevel #0 $state(-warningcommand) "no prefix specified for namespace URI \"$attrValue\" in element \"$tag\""
-		    }
-		    default {
-			set namespaces($prefix,[llength $state(stack)]) $attrValue
-			lappend nsdecls $attrValue $prefix
-		    }
-		}
-	    }
-	}
-	if {[llength $nsdecls]} {
-	    set nsdecls [list -namespacedecls $nsdecls]
-	}
-	set attr [array get attrlist]
-    }
-
-    # Check whether this element has an expanded name
-    set ns {}
-    if {[regexp {([^:]+):(.*)$} $tag discard prefix tag]} {
-	set nsspec [lsort -dictionary -decreasing [array names namespaces $prefix,*]]
-	if {[llength $nsspec]} {
-	    set nsuri $namespaces([lindex $nsspec 0])
-	    set ns [list -namespace $nsuri]
-	} else {
-	    uplevel #0 $options(-errorcommand) [list namespaceundeclared "no namespace declared for prefix \"$prefix\" in element $tag"]
-	}
-    } elseif {[llength $state(defaultNSURI)]} {
-	set ns [list -namespace [lindex $state(defaultNSURI) end]]
-    }
-
-    # Invoke callback
-    set code [catch {uplevel #0 $options(-elementstartcommand) [list $tag $attr] $empty $ns $nsdecls} msg]
-
-    # Sometimes empty elements must be handled here (see above)
-    if {$code == 0 && $handleEmpty} {
-	ParseEvent:ElementClose $tag $opts -empty 1
-    }
-
-    return -code $code -errorinfo $::errorInfo $msg
-}
-
-# sgml::ParseEvent:ElementClose --
-#
-#	End of an element.
-#
-# Arguments:
-#	tag	Element name
-#	opts	Options
-#	args	further configuration options
-#
-# Options:
-#	-empty boolean
-#		indicates whether the element as an empty element
-#
-# Results:
-#	Modify state and invoke callback
-
-proc sgml::ParseEvent:ElementClose {tag opts args} {
-    array set options $opts
-    upvar #0 $options(-statevariable) state
-    array set cfg {-empty 0}
-    array set cfg $args
-
-    # WF check
-    if {[string compare $tag [lindex $state(stack) end]]} {
-	uplevel #0 $options(-errorcommand) [list illegalendtag "end tag \"$tag\" does not match open element \"[lindex $state(stack) end]\" around line $state(line)"]
-	return
-    }
-
-    # Check whether this element has an expanded name
-    upvar #0 $options(namespaces) namespaces
-    set ns {}
-    if {[regexp {([^:]+):(.*)$} $tag discard prefix tag]} {
-	set nsuri $namespaces([lindex [lsort -dictionary -decreasing [array names namespaces $prefix,*]] 0])
-	set ns [list -namespace $nsuri]
-    } elseif {[llength $state(defaultNSURI)]} {
-	set ns [list -namespace [lindex $state(defaultNSURI) end]]
-    }
-
-    # Pop namespace stacks, if any
-    if {[llength $state(defaultNS)]} {
-	if {[llength $state(stack)] == [lindex $state(defaultNS) end]} {
-	    set state(defaultNS) [lreplace $state(defaultNS) end end]
-	}
-    }
-    foreach nsspec [array names namespaces *,[llength $state(stack)]] {
-	unset namespaces($nsspec)
-    }
-
-    # Update state
-    set state(stack) [lreplace $state(stack) end end]
-
-    set empty {}
-    if {$cfg(-empty) && $options(-reportempty)} {
-	set empty {-empty 1}
-    }
-
-    # Invoke callback
-    # Mats: Shall be same as sgml::ParseEvent:ElementOpen to handle exceptions in callback.
-    set code [catch {uplevel #0 $options(-elementendcommand) [list $tag] $empty $ns} msg]
-    return -code $code -errorinfo $::errorInfo $msg
-}
-
-# sgml::PCDATA --
-#
-#	Process PCDATA before passing to application
-#
-# Arguments:
-#	opts	options
-#	pcdata	Character data to be processed
-#
-# Results:
-#	Checks that characters are legal,
-#	checks -ignorewhitespace setting.
-
-proc sgml::PCDATA {opts pcdata} {
-    array set options $opts
-
-    if {$options(-ignorewhitespace) && \
-	    ![string length [string trim $pcdata]]} {
-	return {}
-    }
-
-    if {![regexp ^[cl $::sgml::Char]*\$ $pcdata]} {
-	upvar \#0 $options(-statevariable) state
-	uplevel \#0 $options(-errorcommand) [list illegalcharacters "illegal, non-Unicode characters found in text \"$pcdata\" around line $state(line)"]
-    }
-
-    uplevel \#0 $options(-characterdatacommand) [list $pcdata]
-}
-
-# sgml::Normalize --
-#
-#	Perform name normalization if required
-#
-# Arguments:
-#	name	name to normalize
-#	req	normalization required
-#
-# Results:
-#	Name returned as upper-case if normalization required
-
-proc sgml::Normalize {name req} {
-    if {$req} {
-	return [string toupper $name]
-    } else {
-	return $name
-    }
-}
-
-# sgml::Entity --
-#
-#	Resolve XML entity references (syntax: &xxx;).
-#
-# Arguments:
-#	opts		options
-#	entityrefcmd	application callback for entity references
-#	pcdatacmd	application callback for character data
-#	entities	name of array containing entity definitions.
-#	ref		entity reference (the "xxx" bit)
-#
-# Results:
-#	Returns substitution text for given entity.
-
-proc sgml::Entity {opts entityrefcmd pcdatacmd entities ref} {
-    array set options $opts
-    upvar #0 $options(-statevariable) state
-
-    if {![string length $entities]} {
-	set entities [namespace current]::EntityPredef
-    }
-
-    # SRB: Bug fix 2008-11-18 #812051: surround case labels in braces for compatibility with Freewrap
-    switch -glob -- $ref {
-	{%*} {
-	    # Parameter entity - not recognised outside of a DTD
-	}
-	{#x*} {
-	    # Character entity - hex
-	    if {[catch {format %c [scan [string range $ref 2 end] %x tmp; set tmp]} char]} {
-		return -code error "malformed character entity \"$ref\""
-	    }
-	    uplevel #0 $pcdatacmd [list $char]
-
-	    return {}
-
-	}
-	{#*} {
-	    # Character entity - decimal
-	    if {[catch {format %c [scan [string range $ref 1 end] %d tmp; set tmp]} char]} {
-		return -code error "malformed character entity \"$ref\""
-	    }
-	    uplevel #0 $pcdatacmd [list $char]
-
-	    return {}
-
-	}
-	default {
-	    # General entity
-	    upvar #0 $entities map
-	    if {[info exists map($ref)]} {
-
-		if {![regexp {<|&} $map($ref)]} {
-
-		    # Simple text replacement - optimise
-		    uplevel #0 $pcdatacmd [list $map($ref)]
-
-		    return {}
-
-		}
-
-		# Otherwise an additional round of parsing is required.
-		# This only applies to XML, since HTML doesn't have general entities
-
-		# Must parse the replacement text for start & end tags, etc
-		# This text must be self-contained: balanced closing tags, and so on
-
-		set tokenised [tokenise $map($ref) $::xml::tokExpr $::xml::substExpr]
-		set options(-final) 0
-		eval parseEvent [list $tokenised] [array get options]
-
-		return {}
-
-	    } elseif {[string compare $entityrefcmd "::sgml::noop"]} {
-
-		set result [uplevel #0 $entityrefcmd [list $ref]]
-
-		if {[string length $result]} {
-		    uplevel #0 $pcdatacmd [list $result]
-		}
-
-		return {}
-
-	    } else {
-
-		# Reconstitute entity reference
-
-		uplevel #0 $options(-errorcommand) [list illegalentity "undefined entity reference \"$ref\""]
-
-		return {}
-
-	    }
-	}
-    }
-
-    # If all else fails leave the entity reference untouched
-    uplevel #0 $pcdatacmd [list &$ref\;]
-
-    return {}
-}
-
-####################################
-#
-# DTD parser for SGML (XML).
-#
-# This DTD actually only handles XML DTDs.  Other language's
-# DTD's, such as HTML, must be written in terms of a XML DTD.
-#
-####################################
-
-# sgml::ParseEvent:DocTypeDecl --
-#
-#	Entry point for DTD parsing
-#
-# Arguments:
-#	opts	configuration options
-#	docEl	document element name
-#	pubId	public identifier
-#	sysId	system identifier (a URI)
-#	intSSet	internal DTD subset
-
-proc sgml::ParseEvent:DocTypeDecl {opts docEl pubId sysId intSSet} {
-    array set options {}
-    array set options $opts
-
-    set code [catch {uplevel #0 $options(-doctypecommand) [list $docEl $pubId $sysId $intSSet]} err]
-    switch $code {
-	3 {
-	    # break
-	    return {}
-	}
-	0 -
-	4 {
-	    # continue
-	}
-	default {
-	    return -code $code $err
-	}
-    }
-
-    # Otherwise we'll parse the DTD and report it piecemeal
-
-    # The internal DTD subset is processed first (XML 2.8)
-    # During this stage, parameter entities are only allowed
-    # between markup declarations
-
-    ParseDTD:Internal [array get options] $intSSet
-
-    # The external DTD subset is processed last (XML 2.8)
-    # During this stage, parameter entities may occur anywhere
-
-    # We must resolve the external identifier to obtain the
-    # DTD data.  The application may supply its own resolver.
-
-    if {[string length $pubId] || [string length $sysId]} {
-	uplevel #0 $options(-externalentitycommand) [list $options(-cmd) $options(-baseuri) $sysId $pubId]
-    }
-
-    return {}
-}
-
-# sgml::ParseDTD:Internal --
-#
-#	Parse the internal DTD subset.
-#
-#	Parameter entities are only allowed between markup declarations.
-#
-# Arguments:
-#	opts	configuration options
-#	dtd	DTD data
-#
-# Results:
-#	Markup declarations parsed may cause callback invocation
-
-proc sgml::ParseDTD:Internal {opts dtd} {
-    variable MarkupDeclExpr
-    variable MarkupDeclSub
-
-    array set options {}
-    array set options $opts
-
-    upvar #0 $options(-statevariable) state
-    upvar #0 $options(parameterentities) PEnts
-    upvar #0 $options(externalparameterentities) ExtPEnts
-
-    # Bug 583947: remove comments before further processing
-    regsub -all {<!--.*?-->} $dtd {} dtd
-
-    # Tokenize the DTD
-
-    # Protect Tcl special characters
-    regsub -all {([{}\\])} $dtd {\\\1} dtd
-
-    regsub -all $MarkupDeclExpr $dtd $MarkupDeclSub dtd
-
-    # Entities may have angle brackets in their replacement
-    # text, which breaks the RE processing.  So, we must
-    # use a similar technique to processing doc instances
-    # to rebuild the declarations from the pieces
-
-    set mode {} ;# normal
-    set delimiter {}
-    set name {}
-    set param {}
-
-    set state(inInternalDTD) 1
-
-    # Process the tokens
-    foreach {decl value text} [lrange "{} {} \{$dtd\}" 3 end] {
-
-	# Keep track of line numbers
-	incr state(line) [regsub -all \n $text {} discard]
-
-	ParseDTD:EntityMode [array get options] mode replText decl value text $delimiter $name $param
-
-	ParseDTD:ProcessMarkupDecl [array get options] decl value delimiter name mode replText text param
-
-	# There may be parameter entity references between markup decls
-
-	if {[regexp {%.*;} $text]} {
-
-	    # Protect Tcl special characters
-	    regsub -all {([{}\\])} $text {\\\1} text
-
-	    regsub -all %($::sgml::Name)\; $text "\} {\\1} \{" text
-
-	    set PElist "\{$text\}"
-	    set PElist [lreplace $PElist end end]
-	    foreach {text entref} $PElist {
-		if {[string length [string trim $text]]} {
-		    uplevel #0 $options(-errorcommand) [list unexpectedtext "unexpected text in internal DTD subset around line $state(line)"]
-		}
-
-		# Expand parameter entity and recursively parse
-		# BUG: no checks yet for recursive entity references
-
-		if {[info exists PEnts($entref)]} {
-		    set externalParser [$options(-cmd) entityparser]
-		    $externalParser parse $PEnts($entref) -dtdsubset internal
-		} elseif {[info exists ExtPEnts($entref)]} {
-		    set externalParser [$options(-cmd) entityparser]
-		    $externalParser parse $ExtPEnts($entref) -dtdsubset external
-		    #$externalParser free
-		} else {
-		    uplevel #0 $options(-errorcommand) [list illegalreference "reference to undeclared parameter entity \"$entref\""]
-		}
-	    }
-
-	}
-
-    }
-
-    return {}
-}
-
-# sgml::ParseDTD:EntityMode --
-#
-#	Perform special processing for various parser modes
-#
-# Arguments:
-#	opts	configuration options
-#	modeVar	pass-by-reference mode variable
-#	replTextVar	pass-by-ref
-#	declVar	pass-by-ref
-#	valueVar	pass-by-ref
-#	textVar	pass-by-ref
-#	delimiter	delimiter currently in force
-#	name
-#	param
-#
-# Results:
-#	Depends on current mode
-
-proc sgml::ParseDTD:EntityMode {opts modeVar replTextVar declVar valueVar textVar delimiter name param} {
-    upvar 1 $modeVar mode
-    upvar 1 $replTextVar replText
-    upvar 1 $declVar decl
-    upvar 1 $valueVar value
-    upvar 1 $textVar text
-    array set options $opts
-
-    switch $mode {
-	{} {
-	    # Pass through to normal processing section
-	}
-	entity {
-	    # Look for closing delimiter
-	    if {[regexp ([cl ^$delimiter]*)${delimiter}(.*) $decl discard val1 remainder]} {
-		append replText <$val1
-		DTD:ENTITY [array get options] $name [string trim $param] $delimiter$replText$delimiter
-		set decl /
-		set text $remainder\ $value>$text
-		set value {}
-		set mode {}
-	    } elseif {[regexp ([cl ^$delimiter]*)${delimiter}(.*) $value discard val2 remainder]} {
-		append replText <$decl\ $val2
-		DTD:ENTITY [array get options] $name [string trim $param] $delimiter$replText$delimiter
-		set decl /
-		set text $remainder>$text
-		set value {}
-		set mode {}
-	    } elseif {[regexp ([cl ^$delimiter]*)${delimiter}(.*) $text discard val3 remainder]} {
-		append replText <$decl\ $value>$val3
-		DTD:ENTITY [array get options] $name [string trim $param] $delimiter$replText$delimiter
-		set decl /
-		set text $remainder
-		set value {}
-		set mode {}
-	    } else {
-
-		# Remain in entity mode
-		append replText <$decl\ $value>$text
-		return -code continue
-
-	    }
-	}
-
-	ignore {
-	    upvar #0 $options(-statevariable) state
-
-	    if {[regexp {]](.*)$} $decl discard remainder]} {
-		set state(condSections) [lreplace $state(condSections) end end]
-		set decl $remainder
-		set mode {}
-	    } elseif {[regexp {]](.*)$} $value discard remainder]} {
-		set state(condSections) [lreplace $state(condSections) end end]
-		regexp <[cl $::sgml::Wsp]*($::sgml::Name)(.*) $remainder discard decl value
-		set mode {}
-	    } elseif {[regexp {]]>(.*)$} $text discard remainder]} {
-		set state(condSections) [lreplace $state(condSections) end end]
-		set decl /
-		set value {}
-		set text $remainder
-		#regexp <[cl $::sgml::Wsp]*($::sgml::Name)([cl ^>]*)>(.*) $remainder discard decl value text
-		set mode {}
-	    } else {
-		set decl /
-	    }
-
-	}
-
-	comment {
-	    # Look for closing comment delimiter
-
-	    upvar #0 $options(-statevariable) state
-
-	    if {[regexp (.*?)--(.*)\$ $decl discard data1 remainder]} {
-	    } elseif {[regexp (.*?)--(.*)\$ $value discard data1 remainder]} {
-	    } elseif {[regexp (.*?)--(.*)\$ $text discard data1 remainder]} {
-	    } else {
-		# comment continues
-		append state(commentdata) <$decl\ $value>$text
-		set decl /
-		set value {}
-		set text {}
-	    }
-	}
-
-    }
-
-    return {}
-}
-
-# sgml::ParseDTD:ProcessMarkupDecl --
-#
-#	Process a single markup declaration
-#
-# Arguments:
-#	opts	configuration options
-#	declVar	pass-by-ref
-#	valueVar	pass-by-ref
-#	delimiterVar	pass-by-ref for current delimiter in force
-#	nameVar	pass-by-ref
-#	modeVar	pass-by-ref for current parser mode
-#	replTextVar	pass-by-ref
-#	textVar	pass-by-ref
-#	paramVar	pass-by-ref
-#
-# Results:
-#	Depends on markup declaration.  May change parser mode
-
-proc sgml::ParseDTD:ProcessMarkupDecl {opts declVar valueVar delimiterVar nameVar modeVar replTextVar textVar paramVar} {
-    upvar 1 $modeVar mode
-    upvar 1 $replTextVar replText
-    upvar 1 $textVar text
-    upvar 1 $declVar decl
-    upvar 1 $valueVar value
-    upvar 1 $nameVar name
-    upvar 1 $delimiterVar delimiter
-    upvar 1 $paramVar param
-
-    variable declExpr
-    variable ExternalEntityExpr
-
-    array set options $opts
-    upvar #0 $options(-statevariable) state
-
-    switch -glob -- $decl {
-
-	/ {
-	    # continuation from entity processing
-	}
-
-	!ELEMENT {
-	    # Element declaration
-	    if {[regexp $declExpr $value discard tag cmodel]} {
-		DTD:ELEMENT [array get options] $tag $cmodel
-	    } else {
-		uplevel #0 $options(-errorcommand) [list illegaldeclaration "malformed element declaration around line $state(line)"]
-	    }
-	}
-
-	!ATTLIST {
-	    # Attribute list declaration
-	    variable declExpr
-	    if {[regexp $declExpr $value discard tag attdefns]} {
-		if {[catch {DTD:ATTLIST [array get options] $tag $attdefns} err]} {
-		    #puts stderr "Stack trace: $::errorInfo\n***\n"
-		    # Atttribute parsing has bugs at the moment
-		    #return -code error "$err around line $state(line)"
-		    return {}
-		}
-	    } else {
-		uplevel #0 $options(-errorcommand) [list illegaldeclaration "malformed attribute list declaration around line $state(line)"]
-	    }
-	}
-
-	!ENTITY {
-	    # Entity declaration
-	    variable EntityExpr
-
-	    if {[regexp $EntityExpr $value discard param name value]} {
-
-		# Entity replacement text may have a '>' character.
-		# In this case, the real delimiter will be in the following
-		# text.  This is complicated by the possibility of there
-		# being several '<','>' pairs in the replacement text.
-		# At this point, we are searching for the matching quote delimiter.
-
-		if {[regexp $ExternalEntityExpr $value]} {
-		    DTD:ENTITY [array get options] $name [string trim $param] $value
-		} elseif {[regexp ("|')(.*?)\\1(.*) $value discard delimiter replText value]} {
-
-		    if {[string length [string trim $value]]} {
-			uplevel #0 $options(-errorcommand) [list illegaldeclaration "malformed entity declaration around line $state(line)"]
-		    } else {
-			DTD:ENTITY [array get options] $name [string trim $param] $delimiter$replText$delimiter
-		    }
-		} elseif {[regexp ("|')(.*) $value discard delimiter replText]} {
-		    append replText >$text
-		    set text {}
-		    set mode entity
-		} else {
-		    uplevel #0 $options(-errorcommand) [list illegaldeclaration "no delimiter for entity declaration around line $state(line)"]
-		}
-
-	    } else {
-		uplevel #0 $options(-errorcommand) [list illegaldeclaration "malformed entity declaration around line $state(line)"]
-	    }
-	}
-
-	!NOTATION {
-	    # Notation declaration
-	    if {[regexp $declExpr param discard tag notation]} {
-		DTD:ENTITY [array get options] $tag $notation
-	    } else {
-		uplevel #0 $options(-errorcommand) [list illegaldeclaration "malformed entity declaration around line $state(line)"]
-	    }
-	}
-
-	!--* {
-	    # Start of a comment
-
-	    if {[regexp !--(.*?)--\$ $decl discard data]} {
-		if {[string length [string trim $value]]} {
-		    uplevel #0 $options(-errorcommand) [list unexpectedtext "unexpected text \"$value\""]
-		}
-		uplevel #0 $options(-commentcommand) [list $data]
-		set decl /
-		set value {}
-	    } elseif {[regexp -- ^(.*?)--\$ $value discard data2]} {
-		regexp !--(.*)\$ $decl discard data1
-		uplevel #0 $options(-commentcommand) [list $data1\ $data2]
-		set decl /
-		set value {}
-	    } elseif {[regexp (.*?)-->(.*)\$ $text discard data3 remainder]} {
-		regexp !--(.*)\$ $decl discard data1
-		uplevel #0 $options(-commentcommand) [list $data1\ $value>$data3]
-		set decl /
-		set value {}
-		set text $remainder
-	    } else {
-		regexp !--(.*)\$ $decl discard data1
-		set state(commentdata) $data1\ $value>$text
-		set decl /
-		set value {}
-		set text {}
-		set mode comment
-	    }
-	}
-
-	!*INCLUDE* -
-	!*IGNORE* {
-	    if {$state(inInternalDTD)} {
-		uplevel #0 $options(-errorcommand) [list illegalsection "conditional section not permitted in internal DTD subset around line $state(line)"]
-	    }
-
-	    if {[regexp {^!\[INCLUDE\[(.*)} $decl discard remainder]} {
-		# Push conditional section stack, popped by ]]> sequence
-
-		if {[regexp {(.*?)]]$} $remainder discard r2]} {
-		    # section closed immediately
-		    if {[string length [string trim $r2]]} {
-			uplevel #0 $options(-errorcommand) [list unexpectedtext "unexpected text \"$r2\" in conditional section"]
-		    }
-		} elseif {[regexp {(.*?)]](.*)} $value discard r2 r3]} {
-		    # section closed immediately
-		    if {[string length [string trim $r2]]} {
-			uplevel #0 $options(-errorcommand) [list unexpectedtext "unexpected text \"$r2\" in conditional section"]
-		    }
-		    if {[string length [string trim $r3]]} {
-			uplevel #0 $options(-errorcommand) [list unexpectedtext "unexpected text \"$r3\" in conditional section"]
-		    }
-		} else {
-
-		    lappend state(condSections) INCLUDE
-
-		    set parser [$options(-cmd) entityparser]
-		    $parser parse $remainder\ $value> -dtdsubset external
-		    #$parser free
-
-		    if {[regexp {(.*?)]]>(.*)} $text discard t1 t2]} {
-			if {[string length [string trim $t1]]} {
-			    uplevel #0 $options(-errorcommand) [list unexpectedtext "unexpected text \"$t1\""]
-			}
-			if {![llength $state(condSections)]} {
-			    uplevel #0 $options(-errorcommand) [list illegalsection "extraneous conditional section close"]
-			}
-			set state(condSections) [lreplace $state(condSections) end end]
-			set text $t2
-		    }
-
-		}
-	    } elseif {[regexp {^!\[IGNORE\[(.*)} $decl discard remainder]} {
-		# Set ignore mode.  Still need a stack
-		set mode ignore
-
-		if {[regexp {(.*?)]]$} $remainder discard r2]} {
-		    # section closed immediately
-		    if {[string length [string trim $r2]]} {
-			uplevel #0 $options(-errorcommand) [list unexpectedtext "unexpected text \"$r2\" in conditional section"]
-		    }
-		} elseif {[regexp {(.*?)]](.*)} $value discard r2 r3]} {
-		    # section closed immediately
-		    if {[string length [string trim $r2]]} {
-			uplevel #0 $options(-errorcommand) [list unexpectedtext "unexpected text \"$r2\" in conditional section"]
-		    }
-		    if {[string length [string trim $r3]]} {
-			uplevel #0 $options(-errorcommand) [list unexpectedtext "unexpected text \"$r3\" in conditional section"]
-		    }
-		} else {
-		    
-		    lappend state(condSections) IGNORE
-
-		    if {[regexp {(.*?)]]>(.*)} $text discard t1 t2]} {
-			if {[string length [string trim $t1]]} {
-			    uplevel #0 $options(-errorcommand) [list unexpectedtext "unexpected text \"$t1\""]
-			}
-			if {![llength $state(condSections)]} {
-			    uplevel #0 $options(-errorcommand) [list illegalsection "extraneous conditional section close"]
-			}
-			set state(condSections) [lreplace $state(condSections) end end]
-			set text $t2
-		    }
-
-		}
-	    } else {
-		uplevel #0 $options(-errorcommand) [list illegaldeclaration "illegal markup declaration \"$decl\" around line $state(line)"]
-	    }
-
-	}
-
-	default {
-	    if {[regexp {^\?(.*)} $decl discard target]} {
-		# Processing instruction
-	    } else {
-		uplevel #0 $options(-errorcommand) [list illegaldeclaration "illegal markup declaration \"$decl\""]
-	    }
-	}
-    }
-
-    return {}
-}
-
-# sgml::ParseDTD:External --
-#
-#	Parse the external DTD subset.
-#
-#	Parameter entities are allowed anywhere.
-#
-# Arguments:
-#	opts	configuration options
-#	dtd	DTD data
-#
-# Results:
-#	Markup declarations parsed may cause callback invocation
-
-proc sgml::ParseDTD:External {opts dtd} {
-    variable MarkupDeclExpr
-    variable MarkupDeclSub
-    variable declExpr
-
-    array set options $opts
-    upvar #0 $options(parameterentities) PEnts
-    upvar #0 $options(externalparameterentities) ExtPEnts
-    upvar #0 $options(-statevariable) state
-
-    # As with the internal DTD subset, watch out for
-    # entities with angle brackets
-    set mode {} ;# normal
-    set delimiter {}
-    set name {}
-    set param {}
-
-    set oldState 0
-    catch {set oldState $state(inInternalDTD)}
-    set state(inInternalDTD) 0
-
-    # Initialise conditional section stack
-    if {![info exists state(condSections)]} {
-	set state(condSections) {}
-    }
-    set startCondSectionDepth [llength $state(condSections)]
-
-    while {[string length $dtd]} {
-	set progress 0
-	set PEref {}
-	if {![string compare $mode "ignore"]} {
-	    set progress 1
-	    if {[regexp {]]>(.*)} $dtd discard dtd]} {
-		set remainder {}
-		set mode {} ;# normal
-		set state(condSections) [lreplace $state(condSections) end end]
-		continue
-	    } else {
-		uplevel #0 $options(-errorcommand) [list missingdelimiter "IGNORE conditional section closing delimiter not found"]
-	    }
-	} elseif {[regexp ^(.*?)%($::sgml::Name)\;(.*)\$ $dtd discard data PEref remainder]} {
-	    set progress 1
-	} else {
-	    set data $dtd
-	    set dtd {}
-	    set remainder {}
-	}
-
-	# Tokenize the DTD (so far)
-
-	# Protect Tcl special characters
-	regsub -all {([{}\\])} $data {\\\1} dataP
-
-	set n [regsub -all $MarkupDeclExpr $dataP $MarkupDeclSub dataP]
-
-	if {$n} {
-	    set progress 1
-	    # All but the last markup declaration should have no text
-	    set dataP [lrange "{} {} \{$dataP\}" 3 end]
-	    if {[llength $dataP] > 3} {
-		foreach {decl value text} [lrange $dataP 0 [expr [llength $dataP] - 4]] {
-		    ParseDTD:EntityMode [array get options] mode replText decl value text $delimiter $name $param
-		    ParseDTD:ProcessMarkupDecl [array get options] decl value delimiter name mode repltextVar text param
-
-		    if {[string length [string trim $text]]} {
-			# check for conditional section close
-			if {[regexp {]]>(.*)$} $text discard text]} {
-			    if {[string length [string trim $text]]} {
-				uplevel #0 $options(-errorcommand) [list unexpectedtext "unexpected text \"$text\""]
-			    }
-			    if {![llength $state(condSections)]} {
-				uplevel #0 $options(-errorcommand) [list illegalsection "extraneous conditional section close"]
-			    }
-			    set state(condSections) [lreplace $state(condSections) end end]
-			    if {![string compare $mode "ignore"]} {
-				set mode {} ;# normal
-			    }
-			} else {
-			    uplevel #0 $options(-errorcommand) [list unexpectedtext "unexpected text \"$text\""]
-			}
-		    }
-		}
-	    }
-	    # Do the last declaration
-	    foreach {decl value text} [lrange $dataP [expr [llength $dataP] - 3] end] {
-		ParseDTD:EntityMode [array get options] mode replText decl value text $delimiter $name $param
-		ParseDTD:ProcessMarkupDecl [array get options] decl value delimiter name mode repltextVar text param
-	    }
-	}
-
-	# Now expand the PE reference, if any
-	switch -glob $mode,[string length $PEref],$n {
-	    ignore,0,* {
-		set dtd $text
-	    }
-	    ignore,*,* {
-		set dtd $text$remainder
-	    }
-	    *,0,0 {
-		set dtd $data
-	    }
-	    *,0,* {
-		set dtd $text
-	    }
-	    *,*,0 {
-		if {[catch {append data $PEnts($PEref)}]} {
-		    if {[info exists ExtPEnts($PEref)]} {
-			set externalParser [$options(-cmd) entityparser]
-			$externalParser parse $ExtPEnts($PEref) -dtdsubset external
-			#$externalParser free
-		    } else {
-			uplevel #0 $options(-errorcommand) [list entityundeclared "parameter entity \"$PEref\" not declared"]
-		    }
-		}
-		set dtd $data$remainder
-	    }
-	    default {
-		if {[catch {append text $PEnts($PEref)}]} {
-		    if {[info exists ExtPEnts($PEref)]} {
-			set externalParser [$options(-cmd) entityparser]
-			$externalParser parse $ExtPEnts($PEref) -dtdsubset external
-			#$externalParser free
-		    } else {
-			uplevel #0 $options(-errorcommand) [list entityundeclared "parameter entity \"$PEref\" not declared"]
-		    }
-		}
-		set dtd $text$remainder
-	    }
-	}
-
-	# Check whether a conditional section has been terminated
-	if {[regexp {^(.*?)]]>(.*)$} $dtd discard t1 t2]} {
-	    if {![regexp <.*> $t1]} {
-		if {[string length [string trim $t1]]} {
-		    uplevel #0 $options(-errorcommand) [list unexpectedtext "unexpected text \"$t1\""]
-		}
-		if {![llength $state(condSections)]} {
-		    uplevel #0 $options(-errorcommand) [list illegalsection "extraneous conditional section close"]
-		}
-		set state(condSections) [lreplace $state(condSections) end end]
-		if {![string compare $mode "ignore"]} {
-		    set mode {} ;# normal
-		}
-		set dtd $t2
-		set progress 1
-	    }
-	}
-
-	if {!$progress} {
-	    # No parameter entity references were found and 
-	    # the text does not contain a well-formed markup declaration
-	    # Avoid going into an infinite loop
-	    upvar #0 $options(-errorcommand) [list syntaxerror "external entity does not contain well-formed markup declaration"]
-	    break
-	}
-    }
-
-    set state(inInternalDTD) $oldState
-
-    # Check that conditional sections have been closed properly
-    if {[llength $state(condSections)] > $startCondSectionDepth} {
-	uplevel #0 $options(-errorcommand) [list syntaxerror "[lindex $state(condSections) end] conditional section not closed"]
-    }
-    if {[llength $state(condSections)] < $startCondSectionDepth} {
-	uplevel #0 $options(-errorcommand) [list syntaxerror "too many conditional section closures"]
-    }
-
-    return {}
-}
-
-# Procedures for handling the various declarative elements in a DTD.
-# New elements may be added by creating a procedure of the form
-# parse:DTD:_element_
-
-# For each of these procedures, the various regular expressions they use
-# are created outside of the proc to avoid overhead at runtime
-
-# sgml::DTD:ELEMENT --
-#
-#	<!ELEMENT ...> defines an element.
-#
-#	The content model for the element is stored in the contentmodel array,
-#	indexed by the element name.  The content model is parsed into the
-#	following list form:
-#
-#		{}	Content model is EMPTY.
-#			Indicated by an empty list.
-#		*	Content model is ANY.
-#			Indicated by an asterix.
-#		{ELEMENT ...}
-#			Content model is element-only.
-#		{MIXED {element1 element2 ...}}
-#			Content model is mixed (PCDATA and elements).
-#			The second element of the list contains the 
-#			elements that may occur.  #PCDATA is assumed 
-#			(ie. the list is normalised).
-#
-# Arguments:
-#	opts	configuration options
-#	name	element GI
-#	modspec	unparsed content model specification
-
-proc sgml::DTD:ELEMENT {opts name modspec} {
-    variable Wsp
-    array set options $opts
-
-    upvar #0 $options(elementdecls) elements
-
-    if {$options(-validate) && [info exists elements($name)]} {
-	eval $options(-errorcommand) [list elementdeclared "element \"$name\" already declared"]
-    } else {
-	switch -- $modspec {
-	    EMPTY {
-	    	set elements($name) {}
-		uplevel #0 $options(-elementdeclcommand) $name {{}}
-	    }
-	    ANY {
-	    	set elements($name) *
-		uplevel #0 $options(-elementdeclcommand) $name *
-	    }
-	    default {
-		# Don't parse the content model for now,
-		# just pass the model to the application
-		if {0 && [regexp [format {^\([%s]*#PCDATA[%s]*(\|([^)]+))?[%s]*\)*[%s]*$} $Wsp $Wsp $Wsp $Wsp] discard discard mtoks]} {
-		    set cm($name) [list MIXED [split $mtoks |]]
-		} elseif {0} {
-		    if {[catch {CModelParse $state(state) $value} result]} {
-			eval $options(-errorcommand) [list element? $result]
-		    } else {
-			set cm($id) [list ELEMENT $result]
-		    }
-		} else {
-		    set elements($name) $modspec
-		    uplevel #0 $options(-elementdeclcommand) $name [list $modspec]
-		}
-	    }
-	}
-    }
-}
-
-# sgml::CModelParse --
-#
-#	Parse an element content model (non-mixed).
-#	A syntax tree is constructed.
-#	A transition table is built next.
-#
-#	This is going to need alot of work!
-#
-# Arguments:
-#	state	state array variable
-#	value	the content model data
-#
-# Results:
-#	A Tcl list representing the content model.
-
-proc sgml::CModelParse {state value} {
-    upvar #0 $state var
-
-    # First build syntax tree
-    set syntaxTree [CModelMakeSyntaxTree $state $value]
-
-    # Build transition table
-    set transitionTable [CModelMakeTransitionTable $state $syntaxTree]
-
-    return [list $syntaxTree $transitionTable]
-}
-
-# sgml::CModelMakeSyntaxTree --
-#
-#	Construct a syntax tree for the regular expression.
-#
-#	Syntax tree is represented as a Tcl list:
-#	rep {:choice|:seq {{rep list1} {rep list2} ...}}
-#	where:	rep is repetition character, *, + or ?. {} for no repetition
-#		listN is nested expression or Name
-#
-# Arguments:
-#	spec	Element specification
-#
-# Results:
-#	Syntax tree for element spec as nested Tcl list.
-#
-#	Examples:
-#	(memo)
-#		{} {:seq {{} memo}}
-#	(front, body, back?)
-#		{} {:seq {{} front} {{} body} {? back}}
-#	(head, (p | list | note)*, div2*)
-#		{} {:seq {{} head} {* {:choice {{} p} {{} list} {{} note}}} {* div2}}
-#	(p | a | ul)+
-#		+ {:choice {{} p} {{} a} {{} ul}}
-
-proc sgml::CModelMakeSyntaxTree {state spec} {
-    upvar #0 $state var
-    variable Wsp
-    variable name
-
-    # Translate the spec into a Tcl list.
-
-    # None of the Tcl special characters are allowed in a content model spec.
-    if {[regexp {\$|\[|\]|\{|\}} $spec]} {
-	return -code error "illegal characters in specification"
-    }
-
-    regsub -all [format {(%s)[%s]*(\?|\*|\+)?[%s]*(,|\|)?} $name $Wsp $Wsp] $spec [format {%sCModelSTname %s {\1} {\2} {\3}} \n $state] spec
-    regsub -all {\(} $spec "\nCModelSTopenParen $state " spec
-    regsub -all [format {\)[%s]*(\?|\*|\+)?[%s]*(,|\|)?} $Wsp $Wsp] $spec [format {%sCModelSTcloseParen %s {\1} {\2}} \n $state] spec
-
-    array set var {stack {} state start}
-    eval $spec
-
-    # Peel off the outer seq, its redundant
-    return [lindex [lindex $var(stack) 1] 0]
-}
-
-# sgml::CModelSTname --
-#
-#	Processes a name in a content model spec.
-#
-# Arguments:
-#	state	state array variable
-#	name	name specified
-#	rep	repetition operator
-#	cs	choice or sequence delimiter
-#
-# Results:
-#	See CModelSTcp.
-
-proc sgml::CModelSTname {state name rep cs args} {
-    if {[llength $args]} {
-	return -code error "syntax error in specification: \"$args\""
-    }
-
-    CModelSTcp $state $name $rep $cs
-}
-
-# sgml::CModelSTcp --
-#
-#	Process a content particle.
-#
-# Arguments:
-#	state	state array variable
-#	name	name specified
-#	rep	repetition operator
-#	cs	choice or sequence delimiter
-#
-# Results:
-#	The content particle is added to the current group.
-
-proc sgml::CModelSTcp {state cp rep cs} {
-    upvar #0 $state var
-
-    switch -glob -- [lindex $var(state) end]=$cs {
-	start= {
-	    set var(state) [lreplace $var(state) end end end]
-	    # Add (dummy) grouping, either choice or sequence will do
-	    CModelSTcsSet $state ,
-	    CModelSTcpAdd $state $cp $rep
-	}
-	:choice= -
-	:seq= {
-	    set var(state) [lreplace $var(state) end end end]
-	    CModelSTcpAdd $state $cp $rep
-	}
-	start=| -
-	start=, {
-	    set var(state) [lreplace $var(state) end end [expr {$cs == "," ? ":seq" : ":choice"}]]
-	    CModelSTcsSet $state $cs
-	    CModelSTcpAdd $state $cp $rep
-	}
-	:choice=| -
-	:seq=, {
-	    CModelSTcpAdd $state $cp $rep
-	}
-	:choice=, -
-	:seq=| {
-	    return -code error "syntax error in specification: incorrect delimiter after \"$cp\", should be \"[expr {$cs == "," ? "|" : ","}]\""
-	}
-	end=* {
-	    return -code error "syntax error in specification: no delimiter before \"$cp\""
-	}
-	default {
-	    return -code error "syntax error"
-	}
-    }
-    
-}
-
-# sgml::CModelSTcsSet --
-#
-#	Start a choice or sequence on the stack.
-#
-# Arguments:
-#	state	state array
-#	cs	choice oir sequence
-#
-# Results:
-#	state is modified: end element of state is appended.
-
-proc sgml::CModelSTcsSet {state cs} {
-    upvar #0 $state var
-
-    set cs [expr {$cs == "," ? ":seq" : ":choice"}]
-
-    if {[llength $var(stack)]} {
-	set var(stack) [lreplace $var(stack) end end $cs]
-    } else {
-	set var(stack) [list $cs {}]
-    }
-}
-
-# sgml::CModelSTcpAdd --
-#
-#	Append a content particle to the top of the stack.
-#
-# Arguments:
-#	state	state array
-#	cp	content particle
-#	rep	repetition
-#
-# Results:
-#	state is modified: end element of state is appended.
-
-proc sgml::CModelSTcpAdd {state cp rep} {
-    upvar #0 $state var
-
-    if {[llength $var(stack)]} {
-	set top [lindex $var(stack) end]
-    	lappend top [list $rep $cp]
-	set var(stack) [lreplace $var(stack) end end $top]
-    } else {
-	set var(stack) [list $rep $cp]
-    }
-}
-
-# sgml::CModelSTopenParen --
-#
-#	Processes a '(' in a content model spec.
-#
-# Arguments:
-#	state	state array
-#
-# Results:
-#	Pushes stack in state array.
-
-proc sgml::CModelSTopenParen {state args} {
-    upvar #0 $state var
-
-    if {[llength $args]} {
-	return -code error "syntax error in specification: \"$args\""
-    }
-
-    lappend var(state) start
-    lappend var(stack) [list {} {}]
-}
-
-# sgml::CModelSTcloseParen --
-#
-#	Processes a ')' in a content model spec.
-#
-# Arguments:
-#	state	state array
-#	rep	repetition
-#	cs	choice or sequence delimiter
-#
-# Results:
-#	Stack is popped, and former top of stack is appended to previous element.
-
-proc sgml::CModelSTcloseParen {state rep cs args} {
-    upvar #0 $state var
-
-    if {[llength $args]} {
-	return -code error "syntax error in specification: \"$args\""
-    }
-
-    set cp [lindex $var(stack) end]
-    set var(stack) [lreplace $var(stack) end end]
-    set var(state) [lreplace $var(state) end end]
-    CModelSTcp $state $cp $rep $cs
-}
-
-# sgml::CModelMakeTransitionTable --
-#
-#	Given a content model's syntax tree, constructs
-#	the transition table for the regular expression.
-#
-#	See "Compilers, Principles, Techniques, and Tools",
-#	Aho, Sethi and Ullman.  Section 3.9, algorithm 3.5.
-#
-# Arguments:
-#	state	state array variable
-#	st	syntax tree
-#
-# Results:
-#	The transition table is returned, as a key/value Tcl list.
-
-proc sgml::CModelMakeTransitionTable {state st} {
-    upvar #0 $state var
-
-    # Construct nullable, firstpos and lastpos functions
-    array set var {number 0}
-    foreach {nullable firstpos lastpos} [	\
-	TraverseDepth1st $state $st {
-	    # Evaluated for leaf nodes
-	    # Compute nullable(n)
-	    # Compute firstpos(n)
-	    # Compute lastpos(n)
-	    set nullable [nullable leaf $rep $name]
-	    set firstpos [list {} $var(number)]
-	    set lastpos [list {} $var(number)]
-	    set var(pos:$var(number)) $name
-	} {
-	    # Evaluated for nonterminal nodes
-	    # Compute nullable, firstpos, lastpos
-	    set firstpos [firstpos $cs $firstpos $nullable]
-	    set lastpos  [lastpos  $cs $lastpos  $nullable]
-	    set nullable [nullable nonterm $rep $cs $nullable]
-	}	\
-    ] break
-
-    set accepting [incr var(number)]
-    set var(pos:$accepting) #
-
-    # var(pos:N) maps from position to symbol.
-    # Construct reverse map for convenience.
-    # NB. A symbol may appear in more than one position.
-    # var is about to be reset, so use different arrays.
-
-    foreach {pos symbol} [array get var pos:*] {
-	set pos [lindex [split $pos :] 1]
-	set pos2symbol($pos) $symbol
-	lappend sym2pos($symbol) $pos
-    }
-
-    # Construct the followpos functions
-    catch {unset var}
-    followpos $state $st $firstpos $lastpos
-
-    # Construct transition table
-    # Dstates is [union $marked $unmarked]
-    set unmarked [list [lindex $firstpos 1]]
-    while {[llength $unmarked]} {
-	set T [lindex $unmarked 0]
-	lappend marked $T
-	set unmarked [lrange $unmarked 1 end]
-
-	# Find which input symbols occur in T
-	set symbols {}
-	foreach pos $T {
-	    if {$pos != $accepting && [lsearch $symbols $pos2symbol($pos)] < 0} {
-		lappend symbols $pos2symbol($pos)
-	    }
-	}
-	foreach a $symbols {
-	    set U {}
-	    foreach pos $sym2pos($a) {
-		if {[lsearch $T $pos] >= 0} {
-		    # add followpos($pos)
-	    	    if {$var($pos) == {}} {
-	    	    	lappend U $accepting
-	    	    } else {
-	    	    	eval lappend U $var($pos)
-	    	    }
-		}
-	    }
-	    set U [makeSet $U]
-	    if {[llength $U] && [lsearch $marked $U] < 0 && [lsearch $unmarked $U] < 0} {
-		lappend unmarked $U
-	    }
-	    set Dtran($T,$a) $U
-	}
-	
-    }
-
-    return [list [array get Dtran] [array get sym2pos] $accepting]
-}
-
-# sgml::followpos --
-#
-#	Compute the followpos function, using the already computed
-#	firstpos and lastpos.
-#
-# Arguments:
-#	state		array variable to store followpos functions
-#	st		syntax tree
-#	firstpos	firstpos functions for the syntax tree
-#	lastpos		lastpos functions
-#
-# Results:
-#	followpos functions for each leaf node, in name/value format
-
-proc sgml::followpos {state st firstpos lastpos} {
-    upvar #0 $state var
-
-    switch -- [lindex [lindex $st 1] 0] {
-	:seq {
-	    for {set i 1} {$i < [llength [lindex $st 1]]} {incr i} {
-	    	followpos $state [lindex [lindex $st 1] $i]			\
-			[lindex [lindex $firstpos 0] [expr $i - 1]]	\
-			[lindex [lindex $lastpos 0] [expr $i - 1]]
-	    	foreach pos [lindex [lindex [lindex $lastpos 0] [expr $i - 1]] 1] {
-		    eval lappend var($pos) [lindex [lindex [lindex $firstpos 0] $i] 1]
-		    set var($pos) [makeSet $var($pos)]
-	    	}
-	    }
-	}
-	:choice {
-	    for {set i 1} {$i < [llength [lindex $st 1]]} {incr i} {
-		followpos $state [lindex [lindex $st 1] $i]			\
-			[lindex [lindex $firstpos 0] [expr $i - 1]]	\
-			[lindex [lindex $lastpos 0] [expr $i - 1]]
-	    }
-	}
-	default {
-	    # No action at leaf nodes
-	}
-    }
-
-    switch -- [lindex $st 0] {
-	? {
-	    # We having nothing to do here ! Doing the same as
-	    # for * effectively converts this qualifier into the other.
-	}
-	* {
-	    foreach pos [lindex $lastpos 1] {
-		eval lappend var($pos) [lindex $firstpos 1]
-		set var($pos) [makeSet $var($pos)]
-	    }
-	}
-    }
-
-}
-
-# sgml::TraverseDepth1st --
-#
-#	Perform depth-first traversal of a tree.
-#	A new tree is constructed, with each node computed by f.
-#
-# Arguments:
-#	state	state array variable
-#	t	The tree to traverse, a Tcl list
-#	leaf	Evaluated at a leaf node
-#	nonTerm	Evaluated at a nonterminal node
-#
-# Results:
-#	A new tree is returned.
-
-proc sgml::TraverseDepth1st {state t leaf nonTerm} {
-    upvar #0 $state var
-
-    set nullable {}
-    set firstpos {}
-    set lastpos {}
-
-    switch -- [lindex [lindex $t 1] 0] {
-	:seq -
-	:choice {
-	    set rep [lindex $t 0]
-	    set cs [lindex [lindex $t 1] 0]
-
-	    foreach child [lrange [lindex $t 1] 1 end] {
-		foreach {childNullable childFirstpos childLastpos} \
-			[TraverseDepth1st $state $child $leaf $nonTerm] break
-		lappend nullable $childNullable
-		lappend firstpos $childFirstpos
-		lappend lastpos  $childLastpos
-	    }
-
-	    eval $nonTerm
-	}
-	default {
-	    incr var(number)
-	    set rep [lindex [lindex $t 0] 0]
-	    set name [lindex [lindex $t 1] 0]
-	    eval $leaf
-	}
-    }
-
-    return [list $nullable $firstpos $lastpos]
-}
-
-# sgml::firstpos --
-#
-#	Computes the firstpos function for a nonterminal node.
-#
-# Arguments:
-#	cs		node type, choice or sequence
-#	firstpos	firstpos functions for the subtree
-#	nullable	nullable functions for the subtree
-#
-# Results:
-#	firstpos function for this node is returned.
-
-proc sgml::firstpos {cs firstpos nullable} {
-    switch -- $cs {
-	:seq {
-	    set result [lindex [lindex $firstpos 0] 1]
-	    for {set i 0} {$i < [llength $nullable]} {incr i} {
-	    	if {[lindex [lindex $nullable $i] 1]} {
-	    	    eval lappend result [lindex [lindex $firstpos [expr $i + 1]] 1]
-		} else {
-		    break
-		}
-	    }
-	}
-	:choice {
-	    foreach child $firstpos {
-		eval lappend result $child
-	    }
-	}
-    }
-
-    return [list $firstpos [makeSet $result]]
-}
-
-# sgml::lastpos --
-#
-#	Computes the lastpos function for a nonterminal node.
-#	Same as firstpos, only logic is reversed
-#
-# Arguments:
-#	cs		node type, choice or sequence
-#	lastpos		lastpos functions for the subtree
-#	nullable	nullable functions forthe subtree
-#
-# Results:
-#	lastpos function for this node is returned.
-
-proc sgml::lastpos {cs lastpos nullable} {
-    switch -- $cs {
-	:seq {
-	    set result [lindex [lindex $lastpos end] 1]
-	    for {set i [expr [llength $nullable] - 1]} {$i >= 0} {incr i -1} {
-		if {[lindex [lindex $nullable $i] 1]} {
-		    eval lappend result [lindex [lindex $lastpos $i] 1]
-		} else {
-		    break
-		}
-	    }
-	}
-	:choice {
-	    foreach child $lastpos {
-		eval lappend result $child
-	    }
-	}
-    }
-
-    return [list $lastpos [makeSet $result]]
-}
-
-# sgml::makeSet --
-#
-#	Turn a list into a set, ie. remove duplicates.
-#
-# Arguments:
-#	s	a list
-#
-# Results:
-#	A set is returned, which is a list with duplicates removed.
-
-proc sgml::makeSet s {
-    foreach r $s {
-	if {[llength $r]} {
-	    set unique($r) {}
-	}
-    }
-    return [array names unique]
-}
-
-# sgml::nullable --
-#
-#	Compute the nullable function for a node.
-#
-# Arguments:
-#	nodeType	leaf or nonterminal
-#	rep		repetition applying to this node
-#	name		leaf node: symbol for this node, nonterm node: choice or seq node
-#	subtree		nonterm node: nullable functions for the subtree
-#
-# Results:
-#	Returns nullable function for this branch of the tree.
-
-proc sgml::nullable {nodeType rep name {subtree {}}} {
-    switch -glob -- $rep:$nodeType {
-	:leaf -
-	+:leaf {
-	    return [list {} 0]
-	}
-	\\*:leaf -
-	\\?:leaf {
-	    return [list {} 1]
-	}
-	\\*:nonterm -
-	\\?:nonterm {
-	    return [list $subtree 1]
-	}
-	:nonterm -
-	+:nonterm {
-	    switch -- $name {
-		:choice {
-		    set result 0
-		    foreach child $subtree {
-			set result [expr $result || [lindex $child 1]]
-		    }
-		}
-		:seq {
-		    set result 1
-		    foreach child $subtree {
-			set result [expr $result && [lindex $child 1]]
-		    }
-		}
-	    }
-	    return [list $subtree $result]
-	}
-    }
-}
-
-# sgml::DTD:ATTLIST --
-#
-#	<!ATTLIST ...> defines an attribute list.
-#
-# Arguments:
-#	opts	configuration opions
-#	name	Element GI
-#	attspec	unparsed attribute definitions
-#
-# Results:
-#	Attribute list variables are modified.
-
-proc sgml::DTD:ATTLIST {opts name attspec} {
-    variable attlist_exp
-    variable attlist_enum_exp
-    variable attlist_fixed_exp
-
-    array set options $opts
-
-    # Parse the attribute list.  If it were regular, could just use foreach,
-    # but some attributes may have values.
-    regsub -all {([][$\\])} $attspec {\\\1} attspec
-    regsub -all $attlist_exp $attspec "\}\nDTDAttribute {$options(-attlistdeclcommand)} $name $options(attlistdecls) {\\1} {\\2} {\\3} {} \{" attspec
-    regsub -all $attlist_enum_exp $attspec "\}\nDTDAttribute {$options(-attlistdeclcommand)} $name $options(attlistdecls) {\\1} {\\2} {} {\\4} \{" attspec
-    regsub -all $attlist_fixed_exp $attspec "\}\nDTDAttribute {$options(-attlistdeclcommand)} $name $options(attlistdecls) {\\1} {\\2} {\\3} {\\4} \{" attspec
-
-    eval "noop \{$attspec\}"
-
-    return {}
-}
-
-# sgml::DTDAttribute --
-#
-#	Parse definition of a single attribute.
-#
-# Arguments:
-#	callback	attribute defn callback
-#	name	element name
-#	var	array variable
-#	att	attribute name
-#	type	type of this attribute
-#	default	default value of the attribute
-#	value	other information
-#	text	other text (should be empty)
-#
-# Results:
-#	Attribute defn added to array, unless it already exists
-
-proc sgml::DTDAttribute args {
-    # BUG: Some problems with parameter passing - deal with it later
-    foreach {callback name var att type default value text} $args break
-
-    upvar #0 $var atts
-
-    if {[string length [string trim $text]]} {
-	return -code error "unexpected text \"$text\" in attribute definition"
-    }
-
-    # What about overridden attribute defns?
-    # A non-validating app may want to know about them
-    # (eg. an editor)
-    if {![info exists atts($name/$att)]} {
-	set atts($name/$att) [list $type $default $value]
-	uplevel #0 $callback [list $name $att $type $default $value]
-    }
-
-    return {}
-}
-
-# sgml::DTD:ENTITY --
-#
-#	<!ENTITY ...> declaration.
-#
-#	Callbacks:
-#	-entitydeclcommand for general entity declaration
-#	-unparsedentitydeclcommand for unparsed external entity declaration
-#	-parameterentitydeclcommand for parameter entity declaration
-#
-# Arguments:
-#	opts	configuration options
-#	name	name of entity being defined
-#	param	whether a parameter entity is being defined
-#	value	unparsed replacement text
-#
-# Results:
-#	Modifies the caller's entities array variable
-
-proc sgml::DTD:ENTITY {opts name param value} {
-
-    array set options $opts
-
-    if {[string compare % $param]} {
-	# Entity declaration - general or external
-	upvar #0 $options(entities) ents
-	upvar #0 $options(extentities) externals
-
-	if {[info exists ents($name)] || [info exists externals($name)]} {
-	    eval $options(-warningcommand) entity [list "entity \"$name\" already declared"]
-	} else {
-	    if {[catch {uplevel #0 $options(-parseentitydeclcommand) [list $value]} value]} {
-		return -code error "unable to parse entity declaration due to \"$value\""
-	    }
-	    switch -glob [lindex $value 0],[lindex $value 3] {
-		internal, {
-		    set ents($name) [EntitySubst [array get options] [lindex $value 1]]
-		    uplevel #0 $options(-entitydeclcommand) [list $name $ents($name)]
-		}
-		internal,* {
-		    return -code error "unexpected NDATA declaration"
-		}
-		external, {
-		    set externals($name) [lrange $value 1 2]
-		    uplevel #0 $options(-entitydeclcommand) [eval list $name [lrange $value 1 2]]
-		}
-		external,* {
-		    set externals($name) [lrange $value 1 3]
-		    uplevel #0 $options(-unparsedentitydeclcommand) [eval list $name [lrange $value 1 3]]
-		}
-		default {
-		    return -code error "internal error: unexpected parser state"
-		}
-	    }
-	}
-    } else {
-	# Parameter entity declaration
-	upvar #0 $options(parameterentities) PEnts
-	upvar #0 $options(externalparameterentities) ExtPEnts
-
-	if {[info exists PEnts($name)] || [info exists ExtPEnts($name)]} {
-	    eval $options(-warningcommand) parameterentity [list "parameter entity \"$name\" already declared"]
-	} else {
-	    if {[catch {uplevel #0 $options(-parseentitydeclcommand) [list $value]} value]} {
-		return -code error "unable to parse parameter entity declaration due to \"$value\""
-	    }
-	    if {[string length [lindex $value 3]]} {
-		return -code error "NDATA illegal in parameter entity declaration"
-	    }
-	    switch [lindex $value 0] {
-		internal {
-		    # Substitute character references and PEs (XML: 4.5)
-		    set value [EntitySubst [array get options] [lindex $value 1]]
-
-		    set PEnts($name) $value
-		    uplevel #0 $options(-parameterentitydeclcommand) [list $name $value]
-		}
-		external -
-		default {
-		    # Get the replacement text now.
-		    # Could wait until the first reference, but easier
-		    # to just do it now.
-
-		    set token [uri::geturl [uri::resolve $options(-baseuri) [lindex $value 1]]]
-
-		    set ExtPEnts($name) [lindex [array get $token data] 1]
-		    uplevel #0 $options(-parameterentitydeclcommand) [eval list $name [lrange $value 1 2]]
-		}
-	    }
-	}
-    }
-}
-
-# sgml::EntitySubst --
-#
-#	Perform entity substitution on an entity replacement text.
-#	This differs slightly from other substitution procedures,
-#	because only parameter and character entity substitution
-#	is performed, not general entities.
-#	See XML Rec. section 4.5.
-#
-# Arguments:
-#	opts	configuration options
-#	value	Literal entity value
-#
-# Results:
-#	Expanded replacement text
-
-proc sgml::EntitySubst {opts value} {
-    array set options $opts
-
-    # Protect Tcl special characters
-    regsub -all {([{}\\])} $value {\\\1} value
-
-    # Find entity references
-    regsub -all (&#\[0-9\]+|&#x\[0-9a-fA-F\]+|%${::sgml::Name})\; $value "\[EntitySubstValue [list $options(parameterentities)] {\\1}\]" value
-
-    set result [subst $value]
-
-    return $result
-}
-
-# sgml::EntitySubstValue --
-#
-#	Handle a single character or parameter entity substitution
-#
-# Arguments:
-#	PEvar	array variable containing PE declarations
-#	ref	character or parameter entity reference
-#
-# Results:
-#	Replacement text
-
-proc sgml::EntitySubstValue {PEvar ref} {
-    # SRB: Bug fix 2008-11-18 #812051: surround case labels in braces for compatibility with Freewrap
-    switch -glob -- $ref {
-	{&#x*} {
-	    scan [string range $ref 3 end] %x hex
-	    return [format %c $hex]
-	}
-	{&#*} {
-	    return [format %c [string range $ref 2 end]]
-	}
-	{%*} {
-	    upvar #0 $PEvar PEs
-	    set ref [string range $ref 1 end]
-	    if {[info exists PEs($ref)]} {
-		return $PEs($ref)
-	    } else {
-		return -code error "parameter entity \"$ref\" not declared"
-	    }
-	}
-	default {
-	    return -code error "internal error - unexpected entity reference"
-	}
-    }
-    return {}
-}
-
-# sgml::DTD:NOTATION --
-#
-#	Process notation declaration
-#
-# Arguments:
-#	opts	configuration options
-#	name	notation name
-#	value	unparsed notation spec
-
-proc sgml::DTD:NOTATION {opts name value} {
-    return {}
-
-    variable notation_exp
-    upvar opts state
-
-    if {[regexp $notation_exp $value x scheme data] == 2} {
-    } else {
-	eval $state(-errorcommand) [list notationvalue "notation value \"$value\" incorrectly specified"]
-    }
-}
-
-# sgml::ResolveEntity --
-#
-#	Default entity resolution routine
-#
-# Arguments:
-#	cmd	command of parent parser
-#	base	base URL for relative URLs
-#	sysId	system identifier
-#	pubId	public identifier
-
-proc sgml::ResolveEntity {cmd base sysId pubId} {
-    variable ParseEventNum
-
-    if {[catch {uri::resolve $base $sysId} url]} {
-	return -code error "unable to resolve system identifier \"$sysId\""
-    }
-    if {[catch {uri::geturl $url} token]} {
-	return -code error "unable to retrieve external entity \"$url\" for system identifier \"$sysId\""
-    }
-
-    upvar #0 $token data
-
-    set parser [uplevel #0 $cmd entityparser]
-
-    set body {}
-    catch {set body $data(body)}
-    catch {set body $data(data)}
-    if {[string length $body]} {
-	uplevel #0 $parser parse [list $body] -dtdsubset external
-    }
-    $parser free
-
-    return {}
-}
diff --git a/tclxml-3.2/tclxml-tcl/tclparser-8.0.tcl b/tclxml-3.2/tclxml-tcl/tclparser-8.0.tcl
deleted file mode 100755
index e2573f8..0000000
--- a/tclxml-3.2/tclxml-tcl/tclparser-8.0.tcl
+++ /dev/null
@@ -1,359 +0,0 @@
-# tclparser-8.0.tcl --
-#
-#	This file provides a Tcl implementation of a XML parser.
-#	This file supports Tcl 8.0.
-#
-#	See xml-8.[01].tcl for definitions of character sets and
-#	regular expressions.
-#
-# Copyright (c) 2005-2008 by Explain.
-# http://www.explain.com.au/
-# Copyright (c) 1998-2004 Zveno Pty Ltd
-# http://www.zveno.com/
-# 
-# See the file "LICENSE" in this distribution for information on usage and
-# redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
-#
-# $Id: tclparser-8.0.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require -exact Tcl 8.0
-
-package require xmldefs 3.2
-
-package require sgmlparser 1.0
-
-package provide xml::tclparser 3.2
-
-namespace eval xml {
-
-    # Procedures for parsing XML documents
-    namespace export parser
-    # Procedures for parsing XML DTDs
-    namespace export DTDparser
-
-    # Counter for creating unique parser objects
-    variable ParserCounter 0
-
-}
-
-# xml::parser --
-#
-#	Creates XML parser object.
-#
-# Arguments:
-#	args	Unique name for parser object
-#		plus option/value pairs
-#
-# Recognised Options:
-#	-final			Indicates end of document data
-#	-elementstartcommand	Called when an element starts
-#	-elementendcommand	Called when an element ends
-#	-characterdatacommand	Called when character data occurs
-#	-processinginstructioncommand	Called when a PI occurs
-#	-externalentityrefcommand	Called for an external entity reference
-#
-#	(Not compatible with expat)
-#	-xmldeclcommand		Called when the XML declaration occurs
-#	-doctypecommand		Called when the document type declaration occurs
-#
-#	-errorcommand		Script to evaluate for a fatal error
-#	-warningcommand		Script to evaluate for a reportable warning
-#	-statevariable		global state variable
-#	-reportempty		whether to provide empty element indication
-#
-# Results:
-#	The state variable is initialised.
-
-proc xml::parser {args} {
-    variable ParserCounter
-
-    if {[llength $args] > 0} {
-	set name [lindex $args 0]
-	set args [lreplace $args 0 0]
-    } else {
-	set name parser[incr ParserCounter]
-    }
-
-    if {[info command [namespace current]::$name] != {}} {
-	return -code error "unable to create parser object \"[namespace current]::$name\" command"
-    }
-
-    # Initialise state variable and object command
-    upvar \#0 [namespace current]::$name parser
-    set sgml_ns [namespace parent]::sgml
-    array set parser [list name $name			\
-	-final 1					\
-	-elementstartcommand ${sgml_ns}::noop		\
-	-elementendcommand ${sgml_ns}::noop		\
-	-characterdatacommand ${sgml_ns}::noop		\
-	-processinginstructioncommand ${sgml_ns}::noop	\
-	-externalentityrefcommand ${sgml_ns}::noop	\
-	-xmldeclcommand ${sgml_ns}::noop		\
-	-doctypecommand ${sgml_ns}::noop		\
-	-warningcommand ${sgml_ns}::noop		\
-	-statevariable [namespace current]::$name	\
-	-reportempty 0					\
-	internaldtd {}					\
-    ]
-
-    proc [namespace current]::$name {method args} \
-	"eval ParseCommand $name \$method \$args"
-
-    eval ParseCommand [list $name] configure $args
-
-    return [namespace current]::$name
-}
-
-# xml::ParseCommand --
-#
-#	Handles parse object command invocations
-#
-# Valid Methods:
-#	cget
-#	configure
-#	parse
-#	reset
-#
-# Arguments:
-#	parser	parser object
-#	method	minor command
-#	args	other arguments
-#
-# Results:
-#	Depends on method
-
-proc xml::ParseCommand {parser method args} {
-    upvar \#0 [namespace current]::$parser state
-
-    switch -- $method {
-	cget {
-	    return $state([lindex $args 0])
-	}
-	configure {
-	    foreach {opt value} $args {
-		set state($opt) $value
-	    }
-	}
-	parse {
-	    ParseCommand_parse $parser [lindex $args 0]
-	}
-	reset {
-	    if {[llength $args]} {
-		return -code error "too many arguments"
-	    }
-	    ParseCommand_reset $parser
-	}
-	default {
-	    return -code error "unknown method \"$method\""
-	}
-    }
-
-    return {}
-}
-
-# xml::ParseCommand_parse --
-#
-#	Parses document instance data
-#
-# Arguments:
-#	object	parser object
-#	xml	data
-#
-# Results:
-#	Callbacks are invoked, if any are defined
-
-proc xml::ParseCommand_parse {object xml} {
-    upvar \#0 [namespace current]::$object parser
-    variable Wsp
-    variable tokExpr
-    variable substExpr
-
-    set parent [namespace parent]
-    if {![string compare :: $parent]} {
-	set parent {}
-    }
-
-    set tokenised [lrange \
-	    [${parent}::sgml::tokenise $xml \
-	    $tokExpr \
-	    $substExpr \
-	    -internaldtdvariable [namespace current]::${object}(internaldtd)] \
-	4 end]
-
-    eval ${parent}::sgml::parseEvent \
-	[list $tokenised \
-	    -emptyelement [namespace code ParseEmpty] \
-	    -parseattributelistcommand [namespace code ParseAttrs]] \
-	[array get parser -*command] \
-	[array get parser -entityvariable] \
-	[array get parser -reportempty] \
-	[array get parser -final] \
-	-normalize 0 \
-	-internaldtd [list $parser(internaldtd)]
-
-    return {}
-}
-
-# xml::ParseEmpty --  Tcl 8.0 version
-#
-#       Used by parser to determine whether an element is empty.
-#       This should be dead easy in XML.  The only complication is
-#       that the RE above can't catch the trailing slash, so we have
-#       to dig it out of the tag name or attribute list.
-#
-#       Tcl 8.1 REs should fix this.
-#
-# Arguments:
-#       tag     element name
-#       attr    attribute list (raw)
-#       e       End tag delimiter.
-#
-# Results:
-#       "/" if the trailing slash is found.  Optionally, return a list
-#       containing new values for the tag name and/or attribute list.
-
-proc xml::ParseEmpty {tag attr e} {
-
-    if {[string match */ [string trimright $tag]] && \
-            ![string length $attr]} {
-        regsub {/$} $tag {} tag
-        return [list / $tag $attr]
-    } elseif {[string match */ [string trimright $attr]]} {
-        regsub {/$} [string trimright $attr] {} attr
-        return [list / $tag $attr]
-    } else {
-        return {}
-    }
-
-}
-
-# xml::ParseAttrs --
-#
-#	Parse element attributes.
-#
-# There are two forms for name-value pairs:
-#
-#	name="value"
-#	name='value'
-#
-# Watch out for the trailing slash on empty elements.
-#
-# Arguments:
-#	attrs	attribute string given in a tag
-#
-# Results:
-#	Returns a Tcl list representing the name-value pairs in the 
-#	attribute string
-
-proc xml::ParseAttrs attrs {
-    variable Wsp
-    variable Name
-
-    # First check whether there's any work to do
-    if {![string compare {} [string trim $attrs]]} {
-	return {}
-    }
-
-    # Strip the trailing slash on empty elements
-    regsub [format {/[%s]*$} " \t\n\r"] $attrs {} atList
-
-    set mode name
-    set result {}
-    foreach component [split $atList =] {
-	switch $mode {
-	    name {
-		set component [string trim $component]
-		if {[regexp $Name $component]} {
-		    lappend result $component
-		} else {
-		    return -code error "invalid attribute name \"$component\""
-		}
-		set mode value:start
-	    }
-	    value:start {
-		set component [string trimleft $component]
-		set delimiter [string index $component 0]
-		set value {}
-		switch -- $delimiter {
-		    \" -
-		    ' {
-			if {[regexp [format {%s([^%s]*)%s(.*)} $delimiter $delimiter $delimiter] $component discard value remainder]} {
-			    lappend result $value
-			    set remainder [string trim $remainder]
-			    if {[string length $remainder]} {
-				if {[regexp $Name $remainder]} {
-				    lappend result $remainder
-				    set mode value:start
-				} else {
-				    return -code error "invalid attribute name \"$remainder\""
-				}
-			    } else {
-				set mode end
-			    }
-			} else {
-			    set value [string range $component 1 end]
-			    set mode value:continue
-			}
-		    }
-		    default {
-			return -code error "invalid value for attribute \"[lindex $result end]\""
-		    }
-		}
-	    }
-	    value:continue {
-		if {[regexp [format {([^%s]*)%s(.*)} $delimiter $delimiter] $component discard valuepart remainder]} {
-		    append value = $valuepart
-		    lappend result $value
-		    set remainder [string trim $remainder]
-		    if {[string length $remainder]} {
-			if {[regexp $Name $remainder]} {
-			    lappend result $remainder
-			    set mode value:start
-			} else {
-			    return -code error "invalid attribute name \"$remainder\""
-			}
-		    } else {
-			set mode end
-		    }
-		} else {
-		    append value = $component
-		}
-	    }
-	    end {
-		return -code error "unexpected data found after end of attribute list"
-	    }
-	}
-    }
-
-    switch $mode {
-	name -
-	end {
-	    # This is normal
-	}
-	default {
-	    return -code error "unexpected end of attribute list"
-	}
-    }
-
-    return $result
-}
-
-# xml::ParseCommand_reset --
-#
-#	Initialize parser data
-#
-# Arguments:
-#	object	parser object
-#
-# Results:
-#	Parser data structure initialised
-
-proc xml::ParseCommand_reset object {
-    upvar \#0 [namespace current]::$object parser
-
-    array set parser [list \
-	    -final 1		\
-	    internaldtd {}	\
-    ]
-}
-
diff --git a/tclxml-3.2/tclxml-tcl/tclparser-8.1.tcl b/tclxml-3.2/tclxml-tcl/tclparser-8.1.tcl
deleted file mode 100755
index 40a0af9..0000000
--- a/tclxml-3.2/tclxml-tcl/tclparser-8.1.tcl
+++ /dev/null
@@ -1,614 +0,0 @@
-# tclparser-8.1.tcl --
-#
-#	This file provides a Tcl implementation of a XML parser.
-#	This file supports Tcl 8.1.
-#
-#	See xml-8.[01].tcl for definitions of character sets and
-#	regular expressions.
-#
-# Copyright (c) 2005-2008 by Explain.
-# http://www.explain.com.au/
-# Copyright (c) 1998-2003 Zveno Pty Ltd
-# http://www.zveno.com/
-# 
-# See the file "LICENSE" in this distribution for information on usage and
-# redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
-#
-# $Id: tclparser-8.1.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require Tcl 8.1
-
-package provide xml::tclparser 3.2
-
-package require xmldefs 3.2
-
-package require sgmlparser 1.0
-
-namespace eval xml::tclparser {
-
-    namespace export create createexternal externalentity parse configure get delete
-
-    # Tokenising expressions
-
-    variable tokExpr $::xml::tokExpr
-    variable substExpr $::xml::substExpr
-
-    # Register this parser class
-
-    ::xml::parserclass create tcl \
-	    -createcommand [namespace code create] \
-	    -createentityparsercommand [namespace code createentityparser] \
-	    -parsecommand [namespace code parse] \
-	    -configurecommand [namespace code configure] \
-	    -deletecommand [namespace code delete] \
-	    -resetcommand [namespace code reset]
-}
-
-# xml::tclparser::create --
-#
-#	Creates XML parser object.
-#
-# Arguments:
-#	name	unique identifier for this instance
-#
-# Results:
-#	The state variable is initialised.
-
-proc xml::tclparser::create name {
-
-    # Initialise state variable
-    upvar \#0 [namespace current]::$name parser
-    array set parser [list -name $name			\
-	-cmd [uplevel 3 namespace current]::$name	\
-	-final 1					\
-	-validate 0					\
-	-statevariable [namespace current]::$name	\
-	-baseuri {}					\
-	internaldtd {}					\
-	entities [namespace current]::Entities$name	\
-	extentities [namespace current]::ExtEntities$name	\
-	parameterentities [namespace current]::PEntities$name	\
-	externalparameterentities [namespace current]::ExtPEntities$name	\
-	elementdecls [namespace current]::ElDecls$name	\
-	attlistdecls [namespace current]::AttlistDecls$name	\
-	notationdecls [namespace current]::NotDecls$name	\
-	depth 0						\
-	leftover {}                                     \
-    ]
-
-    # Initialise entities with predefined set
-    array set [namespace current]::Entities$name [array get ::sgml::EntityPredef]
-
-    return $parser(-cmd)
-}
-
-# xml::tclparser::createentityparser --
-#
-#	Creates XML parser object for an entity.
-#
-# Arguments:
-#	name	name for the new parser
-#	parent	name of parent parser
-#
-# Results:
-#	The state variable is initialised.
-
-proc xml::tclparser::createentityparser {parent name} {
-    upvar #0 [namespace current]::$parent p
-
-    # Initialise state variable
-    upvar \#0 [namespace current]::$name external
-    array set external [array get p]
-
-    regsub $parent $p(-cmd) {} parentns
-
-    array set external [list -name $name		\
-	-cmd $parentns$name				\
-	-statevariable [namespace current]::$name	\
-	internaldtd {}					\
-	line 0						\
-    ]
-    incr external(depth)
-
-    return $external(-cmd)
-}
-
-# xml::tclparser::configure --
-#
-#	Configures a XML parser object.
-#
-# Arguments:
-#	name	unique identifier for this instance
-#	args	option name/value pairs
-#
-# Results:
-#	May change values of config options
-
-proc xml::tclparser::configure {name args} {
-    upvar \#0 [namespace current]::$name parser
-
-    # BUG: very crude, no checks for illegal args
-    # Mats: Should be synced with sgmlparser.tcl
-    set options {-elementstartcommand -elementendcommand \
-      -characterdatacommand -processinginstructioncommand \
-      -externalentitycommand -xmldeclcommand \
-      -doctypecommand -commentcommand \
-      -entitydeclcommand -unparsedentitydeclcommand \
-      -parameterentitydeclcommand -notationdeclcommand \
-      -elementdeclcommand -attlistdeclcommand \
-      -paramentityparsing -defaultexpandinternalentities \
-      -startdoctypedeclcommand -enddoctypedeclcommand \
-      -entityreferencecommand -warningcommand \
-      -defaultcommand -unknownencodingcommand -notstandalonecommand \
-      -startcdatasectioncommand -endcdatasectioncommand \
-      -errorcommand -final \
-      -validate -baseuri -baseurl \
-      -name -cmd -emptyelement \
-      -parseattributelistcommand -parseentitydeclcommand \
-      -normalize -internaldtd -dtdsubset \
-      -reportempty -ignorewhitespace \
-      -reportempty \
-    }
-    set usage [join $options ", "]
-    regsub -all -- - $options {} options
-    set pat ^-([join $options |])$
-    foreach {flag value} $args {
-	if {[regexp $pat $flag]} {
-	    # Validate numbers
-	    if {[info exists parser($flag)] && \
-		    [string is integer -strict $parser($flag)] && \
-		    ![string is integer -strict $value]} {
-		return -code error "Bad value for $flag ($value), must be integer"
-	    }
-	    set parser($flag) $value
-	} else {
-	    return -code error "Unknown option $flag, can be: $usage"
-	}
-    }
-
-    # Backward-compatibility: -baseuri is a synonym for -baseurl
-    catch {set parser(-baseuri) $parser(-baseurl)}
-
-    return {}
-}
-
-# xml::tclparser::parse --
-#
-#	Parses document instance data
-#
-# Arguments:
-#	name	parser object
-#	xml	data
-#	args	configuration options
-#
-# Results:
-#	Callbacks are invoked
-
-proc xml::tclparser::parse {name xml args} {
-
-    array set options $args
-    upvar \#0 [namespace current]::$name parser
-    variable tokExpr
-    variable substExpr
-
-    # Mats:
-    if {[llength $args]} {
-	eval {configure $name} $args
-    }
-
-    set parseOptions [list \
-	    -emptyelement [namespace code ParseEmpty] \
-	    -parseattributelistcommand [namespace code ParseAttrs] \
-	    -parseentitydeclcommand [namespace code ParseEntity] \
-	    -normalize 0]
-    eval lappend parseOptions \
-	    [array get parser -*command] \
-	    [array get parser -reportempty] \
-	    [array get parser -ignorewhitespace] \
-	    [array get parser -name] \
-	    [array get parser -cmd] \
-	    [array get parser -baseuri] \
-	    [array get parser -validate] \
-	    [array get parser -final] \
-	    [array get parser -defaultexpandinternalentities] \
-	    [array get parser entities] \
-	    [array get parser extentities] \
-	    [array get parser parameterentities] \
-	    [array get parser externalparameterentities] \
-	    [array get parser elementdecls] \
-	    [array get parser attlistdecls] \
-	    [array get parser notationdecls]
-
-    # Mats:
-    # If -final 0 we also need to maintain the state with a -statevariable !
-    if {!$parser(-final)} {
-	eval lappend parseOptions [array get parser -statevariable]
-    }
-
-    set dtdsubset no
-    catch {set dtdsubset $options(-dtdsubset)}
-    switch -- $dtdsubset {
-	internal {
-	    # Bypass normal parsing
-	    lappend parseOptions -statevariable $parser(-statevariable)
-	    array set intOptions [array get ::sgml::StdOptions]
-	    array set intOptions $parseOptions
-	    ::sgml::ParseDTD:Internal [array get intOptions] $xml
-	    return {}
-	}
-	external {
-	    # Bypass normal parsing
-	    lappend parseOptions -statevariable $parser(-statevariable)
-	    array set intOptions [array get ::sgml::StdOptions]
-	    array set intOptions $parseOptions
-	    ::sgml::ParseDTD:External [array get intOptions] $xml
-	    return {}
-	}
-	default {
-	    # Pass through to normal processing
-	}
-    }
-
-    lappend tokenOptions  \
-      -internaldtdvariable [namespace current]::${name}(internaldtd)
-    
-    # Mats: If -final 0 we also need to maintain the state with a -statevariable !
-    if {!$parser(-final)} {
-	eval lappend tokenOptions [array get parser -statevariable] \
-	  [array get parser -final]
-    }
-    
-    # Mats:
-    # Why not the first four? Just padding? Lrange undos \n interp.
-    # It is necessary to have the first four as well if chopped off in
-    # middle of pcdata.
-    set tokenised [lrange \
-	    [eval {::sgml::tokenise $xml $tokExpr $substExpr} $tokenOptions] \
-	0 end]
-
-    lappend parseOptions -internaldtd [list $parser(internaldtd)]
-    eval ::sgml::parseEvent [list $tokenised] $parseOptions
-
-    return {}
-}
-
-# xml::tclparser::ParseEmpty --  Tcl 8.1+ version
-#
-#	Used by parser to determine whether an element is empty.
-#	This is usually dead easy in XML, but as always not quite.
-#	Have to watch out for empty element syntax
-#
-# Arguments:
-#	tag	element name
-#	attr	attribute list (raw)
-#	e	End tag delimiter.
-#
-# Results:
-#	Return value of e
-
-proc xml::tclparser::ParseEmpty {tag attr e} {
-    switch -glob [string length $e],[regexp "/[::xml::cl $::xml::Wsp]*$" $attr] {
-	0,0 {
-	    return {}
-	}
-	0,* {
-	    return /
-	}
-	default {
-	    return $e
-	}
-    }
-}
-
-# xml::tclparser::ParseAttrs -- Tcl 8.1+ version
-#
-#	Parse element attributes.
-#
-# There are two forms for name-value pairs:
-#
-#	name="value"
-#	name='value'
-#
-# Arguments:
-#	opts	parser options
-#	attrs	attribute string given in a tag
-#
-# Results:
-#	Returns a Tcl list representing the name-value pairs in the 
-#	attribute string
-#
-#	A ">" occurring in the attribute list causes problems when parsing
-#	the XML.  This manifests itself by an unterminated attribute value
-#	and a ">" appearing the element text.
-#	In this case return a three element list;
-#	the message "unterminated attribute value", the attribute list it
-#	did manage to parse and the remainder of the attribute list.
-
-proc xml::tclparser::ParseAttrs {opts attrs} {
-
-    set result {}
-
-    while {[string length [string trim $attrs]]} {
-	if {[regexp [::sgml::cl $::xml::Wsp]*($::xml::Name)[::sgml::cl $::xml::Wsp]*=[::sgml::cl $::xml::Wsp]*("|')([::sgml::cl ^<]*?)\\2(.*) $attrs discard attrName delimiter value attrs]} {
-	    lappend result $attrName [NormalizeAttValue $opts $value]
-	} elseif {[regexp [::sgml::cl $::xml::Wsp]*$::xml::Name[::sgml::cl $::xml::Wsp]*=[::sgml::cl $::xml::Wsp]*("|')[::sgml::cl ^<]*\$ $attrs]} {
-	    return -code error [list {unterminated attribute value} $result $attrs]
-	} else {
-	    return -code error "invalid attribute list"
-	}
-    }
-
-    return $result
-}
-
-# xml::tclparser::NormalizeAttValue --
-#
-#	Perform attribute value normalisation.  This involves:
-#	. character references are appended to the value
-#	. entity references are recursively processed and replacement value appended
-#	. whitespace characters cause a space to be appended
-#	. other characters appended as-is
-#
-# Arguments:
-#	opts	parser options
-#	value	unparsed attribute value
-#
-# Results:
-#	Normalised value returned.
-
-proc xml::tclparser::NormalizeAttValue {opts value} {
-
-    # sgmlparser already has backslashes protected
-    # Protect Tcl specials
-    regsub -all {([][$])} $value {\\\1} value
-
-    # Deal with white space
-    regsub -all "\[$::xml::Wsp\]" $value { } value
-
-    # Find entity refs
-    regsub -all {&([^;]+);} $value {[NormalizeAttValue:DeRef $opts {\1}]} value
-
-    return [subst $value]
-}
-
-# xml::tclparser::NormalizeAttValue:DeRef --
-#
-#	Handler to normalize attribute values
-#
-# Arguments:
-#	opts	parser options
-#	ref	entity reference
-#
-# Results:
-#	Returns character
-
-proc xml::tclparser::NormalizeAttValue:DeRef {opts ref} {
-    # SRB: Bug fix 2008-11-18 #812051: surround case labels in braces for compatibility with Freewrap
-    switch -glob -- $ref {
-	{#x*} {
-	    scan [string range $ref 2 end] %x value
-	    set char [format %c $value]
-	    # Check that the char is legal for XML
-	    if {[regexp [format {^[%s]$} $::xml::Char] $char]} {
-		return $char
-	    } else {
-		return -code error "illegal character"
-	    }
-	}
-	{#*} {
-	    scan [string range $ref 1 end] %d value
-	    set char [format %c $value]
-	    # Check that the char is legal for XML
-	    if {[regexp [format {^[%s]$} $::xml::Char] $char]} {
-		return $char
-	    } else {
-		return -code error "illegal character"
-	    }
-	}
-	lt -
-	gt -
-	amp -
-	quot -
-	apos {
-	    array set map {lt < gt > amp & quot \" apos '}
-	    return $map($ref)
-	}
-	default {
-	    # A general entity.  Must resolve to a text value - no element structure.
-
-	    array set options $opts
-	    upvar #0 $options(entities) map
-
-	    if {[info exists map($ref)]} {
-
-		if {[regexp < $map($ref)]} {
-		    return -code error "illegal character \"<\" in attribute value"
-		}
-
-		if {![regexp & $map($ref)]} {
-		    # Simple text replacement
-		    return $map($ref)
-		}
-
-		# There are entity references in the replacement text.
-		# Can't use child entity parser since must catch element structures
-
-		return [NormalizeAttValue $opts $map($ref)]
-
-	    } elseif {[string compare $options(-entityreferencecommand) "::sgml::noop"]} {
-
-		set result [uplevel #0 $options(-entityreferencecommand) [list $ref]]
-
-		return $result
-
-	    } else {
-		return -code error "unable to resolve entity reference \"$ref\""
-	    }
-	}
-    }
-}
-
-# xml::tclparser::ParseEntity --
-#
-#	Parse general entity declaration
-#
-# Arguments:
-#	data	text to parse
-#
-# Results:
-#	Tcl list containing entity declaration
-
-proc xml::tclparser::ParseEntity data {
-    set data [string trim $data]
-    if {[regexp $::sgml::ExternalEntityExpr $data discard type delimiter1 id1 discard delimiter2 id2 optNDATA ndata]} {
-	switch $type {
-	    PUBLIC {
-		return [list external $id2 $id1 $ndata]
-	    }
-	    SYSTEM {
-		return [list external $id1 {} $ndata]
-	    }
-	}
-    } elseif {[regexp {^("|')(.*?)\1$} $data discard delimiter value]} {
-	return [list internal $value]
-    } else {
-	return -code error "badly formed entity declaration"
-    }
-}
-
-# xml::tclparser::delete --
-#
-#	Destroy parser data
-#
-# Arguments:
-#	name	parser object
-#
-# Results:
-#	Parser data structure destroyed
-
-proc xml::tclparser::delete name {
-    upvar \#0 [namespace current]::$name parser
-    catch {::sgml::ParserDelete $parser(-statevariable)}
-    catch {unset parser}
-    return {}
-}
-
-# xml::tclparser::get --
-#
-#	Retrieve additional information from the parser
-#
-# Arguments:
-#	name	parser object
-#	method	info to retrieve
-#	args	additional arguments for method
-#
-# Results:
-#	Depends on method
-
-proc xml::tclparser::get {name method args} {
-    upvar #0 [namespace current]::$name parser
-
-    switch -- $method {
-
-	elementdecl {
-	    switch [llength $args] {
-
-		0 {
-		    # Return all element declarations
-		    upvar #0 $parser(elementdecls) elements
-		    return [array get elements]
-		}
-
-		1 {
-		    # Return specific element declaration
-		    upvar #0 $parser(elementdecls) elements
-		    if {[info exists elements([lindex $args 0])]} {
-			return [array get elements [lindex $args 0]]
-		    } else {
-			return -code error "element \"[lindex $args 0]\" not declared"
-		    }
-		}
-
-		default {
-		    return -code error "wrong number of arguments: should be \"elementdecl ?element?\""
-		}
-	    }
-	}
-
-	attlist {
-	    if {[llength $args] != 1} {
-		return -code error "wrong number of arguments: should be \"get attlist element\""
-	    }
-
-	    upvar #0 $parser(attlistdecls)
-
-	    return {}
-	}
-
-	entitydecl {
-	}
-
-	parameterentitydecl {
-	}
-
-	notationdecl {
-	}
-
-	default {
-	    return -code error "unknown method \"$method\""
-	}
-    }
-
-    return {}
-}
-
-# xml::tclparser::ExternalEntity --
-#
-#	Resolve and parse external entity
-#
-# Arguments:
-#	name	parser object
-#	base	base URL
-#	sys	system identifier
-#	pub	public identifier
-#
-# Results:
-#	External entity is fetched and parsed
-
-proc xml::tclparser::ExternalEntity {name base sys pub} {
-}
-
-# xml::tclparser:: --
-#
-#	Reset a parser instance, ready to parse another document
-#
-# Arguments:
-#	name	parser object
-#
-# Results:
-#	Variables unset
-
-proc xml::tclparser::reset {name} {
-    upvar \#0 [namespace current]::$name parser
-
-    # Has this parser object been properly initialised?
-    if {![info exists parser] || \
-	    ![info exists parser(-name)]} {
-	return [create $name]
-    }
-
-    array set parser {
-	-final 1
-	depth 0
-	leftover {}
-    }
-
-    foreach var {Entities ExtEntities PEntities ExtPEntities ElDecls AttlistDecls NotDecls} {
-	catch {unset [namespace current]::${var}$name}
-    }
-
-    # Initialise entities with predefined set
-    array set [namespace current]::Entities$name [array get ::sgml::EntityPredef]
-
-    return {}
-}
diff --git a/tclxml-3.2/tclxml-tcl/xml-8.0.tcl b/tclxml-3.2/tclxml-tcl/xml-8.0.tcl
deleted file mode 100755
index db28423..0000000
--- a/tclxml-3.2/tclxml-tcl/xml-8.0.tcl
+++ /dev/null
@@ -1,92 +0,0 @@
-# xml-8.0.tcl --
-#
-#	This file provides generic XML services for all implementations.
-#	This file supports Tcl 8.0 regular expressions.
-#
-#	See xmlparse.tcl for the Tcl implementation of a XML parser.
-#
-# Copyright (c) 2005 by Explain.
-# http://www.explain.com.au/
-# Copyright (c) 1998-2004 Zveno Pty Ltd
-# http://www.zveno.com/
-# 
-# See the file "LICENSE" in this distribution for information on usage and
-# redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
-#
-# $Id: xml-8.0.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require -exact Tcl 8.0
-
-package require sgml 1.8
-
-package provide xmldefs 3.2
-
-namespace eval xml {
-
-    # Convenience routine
-    proc cl x {
-	return "\[$x\]"
-    }
-
-    # Define various regular expressions
-
-    # Characters
-    variable Char $::sgml::Char
-
-    # white space
-    variable Wsp " \t\r\n"
-    variable noWsp [cl ^$Wsp]
-
-    # Various XML names and tokens
-
-    variable NameChar $::sgml::NameChar
-    variable Name $::sgml::Name
-    variable Names $::sgml::Names
-    variable Nmtoken $::sgml::Nmtoken
-    variable Nmtokens $::sgml::Nmtokens
-
-    # The definition of the Namespace URI for XML Namespaces themselves.
-    # The prefix 'xml' is automatically bound to this URI.
-    variable xmlnsNS http://www.w3.org/XML/1998/namespace
-
-    # Tokenising expressions
-
-    variable tokExpr <(/?)([cl ^$Wsp>/]+)([cl $Wsp]*[cl ^>]*)>
-    variable substExpr "\}\n{\\2} {\\1} {\\3} \{"
-
-    # table of predefined entities
-
-    variable EntityPredef
-    array set EntityPredef {
-	lt <   gt >   amp &   quot \"   apos '
-    }
-
-}
-
-###
-###	General utility procedures
-###
-
-# xml::noop --
-#
-# A do-nothing proc
-
-proc xml::noop args {}
-
-### Following procedures are based on html_library
-
-# xml::zapWhite --
-#
-#	Convert multiple white space into a single space.
-#
-# Arguments:
-#	data	plain text
-#
-# Results:
-#	As above
-
-proc xml::zapWhite data {
-    regsub -all "\[ \t\r\n\]+" $data { } data
-    return $data
-}
-
diff --git a/tclxml-3.2/tclxml-tcl/xml-8.1.tcl b/tclxml-3.2/tclxml-tcl/xml-8.1.tcl
deleted file mode 100755
index 5ec410b..0000000
--- a/tclxml-3.2/tclxml-tcl/xml-8.1.tcl
+++ /dev/null
@@ -1,135 +0,0 @@
-# xml.tcl --
-#
-#	This file provides generic XML services for all implementations.
-#	This file supports Tcl 8.1 regular expressions.
-#
-#	See tclparser.tcl for the Tcl implementation of a XML parser.
-#
-# Copyright (c) 2005 by Explain.
-# http://www.explain.com.au/
-# Copyright (c) 1998-2004 Zveno Pty Ltd
-# http://www.zveno.com/
-# 
-# See the file "LICENSE" in this distribution for information on usage and
-# redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
-#
-# $Id: xml-8.1.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require Tcl 8.1
-
-package provide xmldefs 3.2
-
-package require sgml 1.8
-
-namespace eval xml {
-
-    namespace export qnamesplit
-
-    # Convenience routine
-    proc cl x {
-	return "\[$x\]"
-    }
-
-    # Define various regular expressions
-
-    # Characters
-    variable Char $::sgml::Char
-
-    # white space
-    variable Wsp " \t\r\n"
-    variable allWsp [cl $Wsp]*
-    variable noWsp [cl ^$Wsp]
-
-    # Various XML names and tokens
-
-    variable NameChar $::sgml::NameChar
-    variable Name $::sgml::Name
-    variable Names $::sgml::Names
-    variable Nmtoken $::sgml::Nmtoken
-    variable Nmtokens $::sgml::Nmtokens
-
-    # XML Namespaces names
-
-    # NCName ::= Name - ':'
-    variable NCName $::sgml::Name
-    regsub -all : $NCName {} NCName
-    variable QName (${NCName}:)?$NCName		;# (Prefix ':')? LocalPart
-
-    # The definition of the Namespace URI for XML Namespaces themselves.
-    # The prefix 'xml' is automatically bound to this URI.
-    variable xmlnsNS http://www.w3.org/XML/1998/namespace
-
-    # table of predefined entities
-
-    variable EntityPredef
-    array set EntityPredef {
-	lt <   gt >   amp &   quot \"   apos '
-    }
-
-    # Expressions for pulling things apart
-    variable tokExpr <(/?)([::xml::cl ^$::xml::Wsp>/]+)([::xml::cl $::xml::Wsp]*[::xml::cl ^>]*)>
-    variable substExpr "\}\n{\\2} {\\1} {\\3} \{"
-
-}
-
-###
-###	Exported procedures
-###
-
-# xml::qnamesplit --
-#
-#	Split a QName into its constituent parts:
-#	the XML Namespace prefix and the Local-name
-#
-# Arguments:
-#	qname	XML Qualified Name (see XML Namespaces [6])
-#
-# Results:
-#	Returns prefix and local-name as a Tcl list.
-#	Error condition returned if the prefix or local-name
-#	are not valid NCNames (XML Name)
-
-proc xml::qnamesplit qname {
-    variable NCName
-    variable Name
-
-    set prefix {}
-    set localname $qname
-    if {[regexp : $qname]} {
-	if {![regexp ^($NCName)?:($NCName)\$ $qname discard prefix localname]} {
-	    return -code error "name \"$qname\" is not a valid QName"
-	}
-    } elseif {![regexp ^$Name\$ $qname]} {
-	return -code error "name \"$qname\" is not a valid Name"
-    }
-
-    return [list $prefix $localname]
-}
-
-###
-###	General utility procedures
-###
-
-# xml::noop --
-#
-# A do-nothing proc
-
-proc xml::noop args {}
-
-### Following procedures are based on html_library
-
-# xml::zapWhite --
-#
-#	Convert multiple white space into a single space.
-#
-# Arguments:
-#	data	plain text
-#
-# Results:
-#	As above
-
-proc xml::zapWhite data {
-    regsub -all "\[ \t\r\n\]+" $data { } data
-    return $data
-}
-
diff --git a/tclxml-3.2/tclxml-tcl/xml__tcl.tcl b/tclxml-3.2/tclxml-tcl/xml__tcl.tcl
deleted file mode 100644
index bdb7bd9..0000000
--- a/tclxml-3.2/tclxml-tcl/xml__tcl.tcl
+++ /dev/null
@@ -1,272 +0,0 @@
-# xml__tcl.tcl --
-#
-#	This file provides a Tcl implementation of the parser
-#	class support found in ../tclxml.c.  It is only used
-#	when the C implementation is not installed (for some reason).
-#
-# Copyright (c) 2005 by Explain.
-# http://www.explain.com.au/
-# Copyright (c) 2000-2004 Zveno Pty Ltd
-# http://www.zveno.com/
-# 
-# See the file "LICENSE" in this distribution for information on usage and
-# redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
-#
-# $Id: xml__tcl.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package provide xml::tcl 3.2
-
-namespace eval xml {
-    namespace export configure parser parserclass
-
-    # Parser implementation classes
-    variable classes
-    array set classes {}
-
-    # Default parser class
-    variable default {}
-
-    # Counter for generating unique names
-    variable counter 0
-}
-
-# xml::configure --
-#
-#	Configure the xml package
-#
-# Arguments:
-#	None
-#
-# Results:
-#	None (not yet implemented)
-
-proc xml::configure args {}
-
-# xml::parserclass --
-#
-#	Implements the xml::parserclass command for managing
-#	parser implementations.
-#
-# Arguments:
-#	method	subcommand
-#	args	method arguments
-#
-# Results:
-#	Depends on method
-
-proc xml::parserclass {method args} {
-    variable classes
-    variable default
-
-    switch -- $method {
-
-	create {
-	    if {[llength $args] < 1} {
-		return -code error "wrong number of arguments, should be xml::parserclass create name ?args?"
-	    }
-
-	    set name [lindex $args 0]
-	    if {[llength [lrange $args 1 end]] % 2} {
-		return -code error "missing value for option \"[lindex $args end]\""
-	    }
-	    array set classes [list $name [list \
-		    -createcommand [namespace current]::noop \
-		    -createentityparsercommand [namespace current]::noop \
-		    -parsecommand [namespace current]::noop \
-		    -configurecommand [namespace current]::noop \
-		    -getcommand [namespace current]::noop \
-		    -deletecommand [namespace current]::noop \
-	    ]]
-	    # BUG: we're not checking that the arguments are kosher
-	    set classes($name) [lrange $args 1 end]
-	    set default $name
-	}
-
-	destroy {
-	    if {[llength $args] < 1} {
-		return -code error "wrong number of arguments, should be xml::parserclass destroy name"
-	    }
-
-	    if {[info exists classes([lindex $args 0])]} {
-		unset classes([lindex $args 0])
-	    } else {
-		return -code error "no such parser class \"[lindex $args 0]\""
-	    }
-	}
-
-	info {
-	    if {[llength $args] < 1} {
-		return -code error "wrong number of arguments, should be xml::parserclass info method"
-	    }
-
-	    switch -- [lindex $args 0] {
-		names {
-		    return [array names classes]
-		}
-		default {
-		    return $default 
-		}
-	    }
-	}
-
-	default {
-	    return -code error "unknown method \"$method\""
-	}
-    }
-
-    return {}
-}
-
-# xml::parser --
-#
-#	Create a parser object instance
-#
-# Arguments:
-#	args	optional name, configuration options
-#
-# Results:
-#	Returns object name.  Parser instance created.
-
-proc xml::parser args {
-    variable classes
-    variable default
-
-    if {[llength $args] < 1} {
-	# Create unique name, no options
-	set parserName [FindUniqueName]
-    } else {
-	if {[string index [lindex $args 0] 0] == "-"} {
-	    # Create unique name, have options
-	    set parserName [FindUniqueName]
-	} else {
-	    # Given name, optional options
-	    set parserName [lindex $args 0]
-	    set args [lrange $args 1 end]
-	}
-    }
-
-    array set options [list \
-	-parser $default
-    ]
-    array set options $args
-
-    if {![info exists classes($options(-parser))]} {
-	return -code error "no such parser class \"$options(-parser)\""
-    }
-
-    # Now create the parser instance command and data structure
-    # The command must be created in the caller's namespace
-    uplevel 1 [list proc $parserName {method args} "eval [namespace current]::ParserCmd [list $parserName] \[list \$method\] \$args"]
-    upvar #0 [namespace current]::$parserName data
-    array set data [list class $options(-parser)]
-
-    array set classinfo $classes($options(-parser))
-    if {[string compare $classinfo(-createcommand) ""]} {
-	eval $classinfo(-createcommand) [list $parserName]
-    }
-    if {[string compare $classinfo(-configurecommand) ""] && \
-	    [llength $args]} {
-	eval $classinfo(-configurecommand) [list $parserName] $args
-    }
-
-    return $parserName
-}
-
-# xml::FindUniqueName --
-#
-#	Generate unique object name
-#
-# Arguments:
-#	None
-#
-# Results:
-#	Returns string.
-
-proc xml::FindUniqueName {} {
-    variable counter
-    return xmlparser[incr counter]
-}
-
-# xml::ParserCmd --
-#
-#	Implements parser object command
-#
-# Arguments:
-#	name	object reference
-#	method	subcommand
-#	args	method arguments
-#
-# Results:
-#	Depends on method
-
-proc xml::ParserCmd {name method args} {
-    variable classes
-    upvar #0 [namespace current]::$name data
-
-    array set classinfo $classes($data(class))
-
-    switch -- $method {
-
-	configure {
-	    # BUG: We're not checking for legal options
-	    array set data $args
-	    eval $classinfo(-configurecommand) [list $name] $args
-	    return {}
-	}
-
-	cget {
-	    return $data([lindex $args 0])
-	}
-
-	entityparser {
-	    set new [FindUniqueName]
-
-	    upvar #0 [namespace current]::$name parent
-	    upvar #0 [namespace current]::$new data
-	    array set data [array get parent]
-
-	    uplevel 1 [list proc $new {method args} "eval [namespace current]::ParserCmd [list $new] \[list \$method\] \$args"]
-
-	    return [eval $classinfo(-createentityparsercommand) [list $name $new] $args]
-	}
-
-	free {
-	    eval $classinfo(-deletecommand) [list $name]
-	    unset data
-	    uplevel 1 [list rename $name {}]
-	}
-
-	get {
-	    eval $classinfo(-getcommand) [list $name] $args
-	}
-
-	parse {
-	    if {[llength $args] < 1} {
-		return -code error "wrong number of arguments, should be $name parse xml ?options?"
-	    }
-	    eval $classinfo(-parsecommand) [list $name] $args
-	}
-
-	reset {
-	    eval $classinfo(-resetcommand) [list $name]
-	}
-
-	default {
-	    return -code error "unknown method"
-	}
-    }
-
-    return {}
-}
-
-# xml::noop --
-#
-#	Do nothing utility proc
-#
-# Arguments:
-#	args	whatever
-#
-# Results:
-#	Nothing happens
-
-proc xml::noop args {}
diff --git a/tclxml-3.2/tclxml-tcl/xmldep.tcl b/tclxml-3.2/tclxml-tcl/xmldep.tcl
deleted file mode 100644
index bbb2613..0000000
--- a/tclxml-3.2/tclxml-tcl/xmldep.tcl
+++ /dev/null
@@ -1,179 +0,0 @@
-# xmldep.tcl --
-#
-#	Find the dependencies in an XML document.
-#	Supports external entities and XSL include/import.
-#
-# TODO:
-#	XInclude
-#
-# Copyright (c) 2001-2003 Zveno Pty Ltd
-# http://www.zveno.com/
-#
-# See the file "LICENSE" in this distribution for information on usage and
-# redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
-#
-# $Id: xmldep.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require xml
-
-package provide xml::dep 1.0
-
-namespace eval xml::dep {
-    namespace export depend
-
-    variable extEntities
-    array set extEntities {}
-
-    variable XSLTNS http://www.w3.org/1999/XSL/Transform
-}
-
-# xml::dep::depend --
-#
-#	Find the resources which an XML document
-#	depends on.  The document is parsed
-#	sequentially, rather than using DOM, for efficiency.
-#
-# TODO:
-#	Asynchronous parsing.
-#
-# Arguments:
-#	xml	XML document entity
-#	args	configuration options
-#
-# Results:
-#	Returns list of resource (system) identifiers
-
-proc xml::dep::depend {xml args} {
-    variable resources
-    variable entities
-
-    set resources {}
-    catch {unset entities}
-    array set entities {}
-
-    set p [xml::parser \
-	    -elementstartcommand [namespace code ElStart]	\
-	    -doctypecommand [namespace code DocTypeDecl]	\
-	    -entitydeclcommand [namespace code EntityDecl]	\
-	    -entityreferencecommand [namespace code EntityReference]	\
-	    -validate 1	\
-	    ]
-    if {[llength $args]} {
-	eval [list $p] configure $args
-    }
-    $p parse $xml
-
-    return $resources
-}
-
-# xml::dep::ElStart --
-#
-#	Process start element
-#
-# Arguments:
-#	name	tag name
-#	atlist	attribute list
-#	args	options
-#
-# Results:
-#	May add to resources list
-
-proc xml::dep::ElStart {name atlist args} {
-    variable XSLTNS
-    variable resources
-
-    array set opts {
-	-namespace {}
-    }
-    array set opts $args
-
-    switch -- $opts(-namespace) \
-	    $XSLTNS {
-	switch $name {
-	    import -
-	    include {
-		array set attr {
-		    href {}
-		}
-		array set attr $atlist
-
-		if {[string length $attr(href)]} {
-		    if {[lsearch $resources $attr(href)] < 0} {
-			lappend resources $attr(href)
-		    }
-		}
-
-	    }
-	}
-    }
-}
-
-# xml::dep::DocTypeDecl --
-#
-#	Process Document Type Declaration
-#
-# Arguments:
-#	name	Document element
-#	pubid	Public identifier
-#	sysid	System identifier
-#	dtd	Internal DTD Subset
-#
-# Results:
-#	Resource added to list
-
-proc xml::dep::DocTypeDecl {name pubid sysid dtd} {
-    variable resources
-
-    puts stderr [list DocTypeDecl $name $pubid $sysid dtd]
-
-    if {[string length $sysid] && \
-	    [lsearch $resources $sysid] < 0} {
-	lappend resources $sysid
-    }
-
-    return {}
-}
-
-# xml::dep::EntityDecl --
-#
-#	Process entity declaration, looking for external entity
-#
-# Arguments:
-#	name	entity name
-#	sysid	system identifier
-#	pubid	public identifier or repl. text
-#
-# Results:
-#	Store external entity info for later reference
-
-proc xml::dep::EntityDecl {name sysid pubid} {
-    variable extEntities
-
-    puts stderr [list EntityDecl $name $sysid $pubid]
-
-    set extEntities($name) $sysid
-}
-
-# xml::dep::EntityReference --
-#
-#	Process entity reference
-#
-# Arguments:
-#	name	entity name
-#
-# Results:
-#	May add to resources list
-
-proc xml::dep::EntityReference name {
-    variable extEntities
-    variable resources
-
-    puts stderr [list EntityReference $name]
-
-    if {[info exists extEntities($name)] && \
-	[lsearch $resources $extEntities($name)] < 0} {
-	lappend resources $extEntities($name)
-    }
-
-}
-
diff --git a/tclxml-3.2/tclxml-tcl/xpath.tcl b/tclxml-3.2/tclxml-tcl/xpath.tcl
deleted file mode 100644
index e772e67..0000000
--- a/tclxml-3.2/tclxml-tcl/xpath.tcl
+++ /dev/null
@@ -1,362 +0,0 @@
-# xpath.tcl --
-#
-#	Provides an XPath parser for Tcl,
-#	plus various support procedures
-#
-# Copyright (c) 2000-2003 Zveno Pty Ltd
-#
-# See the file "LICENSE" in this distribution for information on usage and
-# redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
-#
-# $Id: xpath.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package provide xpath 1.0
-
-# We need the XML package for definition of Names
-package require xml
-
-namespace eval xpath {
-    namespace export split join createnode
-
-    variable axes {
-	ancestor
-	ancestor-or-self
-	attribute
-	child
-	descendant
-	descendant-or-self
-	following
-	following-sibling
-	namespace
-	parent
-	preceding
-	preceding-sibling
-	self
-    }
-
-    variable nodeTypes {
-	comment
-	text
-	processing-instruction
-	node
-    }
-
-    # NB. QName has parens for prefix
-
-    variable nodetestExpr ^(${::xml::QName})${::xml::allWsp}(\\(${::xml::allWsp}(("|')(.*?)\\5)?${::xml::allWsp}\\))?${::xml::allWsp}(.*)
-
-    variable nodetestExpr2 ((($::xml::QName)${::xml::allWsp}(\\(${::xml::allWsp}(("|')(.*?)\\7)?${::xml::allWsp}\\))?)|${::xml::allWsp}(\\*))${::xml::allWsp}(.*)
-}
-
-# xpath::split --
-#
-#	Parse an XPath location path
-#
-# Arguments:
-#	locpath	location path
-#
-# Results:
-#	A Tcl list representing the location path.
-#	The list has the form: {{axis node-test {predicate predicate ...}} ...}
-#	Where each list item is a location step.
-
-proc xpath::split locpath {
-    set leftover {}
-
-    set result [InnerSplit $locpath leftover]
-
-    if {[string length [string trim $leftover]]} {
-	return -code error "unexpected text \"$leftover\""
-    }
-
-    return $result
-}
-
-proc xpath::InnerSplit {locpath leftoverVar} {
-    upvar $leftoverVar leftover
-
-    variable axes
-    variable nodetestExpr
-    variable nodetestExpr2
-
-    # First determine whether we have an absolute location path
-    if {[regexp {^/(.*)} $locpath discard locpath]} {
-	set path {{}}
-    } else {
-	set path {}
-    }
-
-    while {[string length [string trimleft $locpath]]} {
-	if {[regexp {^\.\.(.*)} $locpath discard locpath]} {
-	    # .. abbreviation
-	    set axis parent
-	    set nodetest *
-	} elseif {[regexp {^/(.*)} $locpath discard locpath]} {
-	    # // abbreviation
-	    set axis descendant-or-self
-	    if {[regexp ^$nodetestExpr2 [string trimleft $locpath] discard discard discard nodetest discard typetest discard discard literal wildcard locpath]} {
-		set nodetest [ResolveWildcard $nodetest $typetest $wildcard $literal]
-	    } else {
-		set leftover $locpath
-		return $path
-	    }
-	} elseif {[regexp ^\\.${::xml::allWsp}(.*) $locpath discard locpath]} {
-	    # . abbreviation
-	    set axis self
-	    set nodetest *
-	} elseif {[regexp ^@($::xml::QName)${::xml::allWsp}=${::xml::allWsp}"(\[^"\])"(.*) $locpath discard attrName discard attrValue locpath]} {
-	    # @ abbreviation
-	    set axis attribute
-	    set nodetest $attrName
-	} elseif {[regexp ^@($::xml::QName)${::xml::allWsp}=${::xml::allWsp}'(\[^'\])'(.*) $locpath discard attrName discard attrValue locpath]} {
-	    # @ abbreviation
-	    set axis attribute
-	    set nodetest $attrName
-	} elseif {[regexp ^@($::xml::QName)(.*) $locpath discard attrName discard2 locpath]} {
-	    # @ abbreviation
-	    set axis attribute
-	    set nodetest $attrName
-	} elseif {[regexp ^((${::xml::QName})${::xml::allWsp}::${::xml::allWsp})?\\*(.*) $locpath discard discard axis discard locpath]} {
-	    # wildcard specified
-	    set nodetest *
-	    if {![string length $axis]} {
-		set axis child
-	    }
-	} elseif {[regexp ^((${::xml::QName})${::xml::allWsp}::${::xml::allWsp})?$nodetestExpr2 $locpath discard discard axis discard discard discard nodetest discard typetest discard discard literal wildcard locpath]} {
-	    # nodetest, with or without axis
-	    if {![string length $axis]} {
-		set axis child
-	    }
-	    set nodetest [ResolveWildcard $nodetest $typetest $wildcard $literal]
-	} else {
-	    set leftover $locpath
-	    return $path
-	}
-
-	# ParsePredicates
-	set predicates {}
-	set locpath [string trimleft $locpath]
-	while {[regexp {^\[(.*)} $locpath discard locpath]} {
-	    if {[regexp {^([0-9]+)(\].*)} [string trim $locpath] discard posn locpath]} {
-		set predicate [list = {function position {}} [list number $posn]]
-	    } else {
-		set leftover2 {}
-		set predicate [ParseExpr $locpath leftover2]
-		set locpath $leftover2
-		unset leftover2
-	    }
-
-	    if {[regexp {^\](.*)} [string trimleft $locpath] discard locpath]} {
-		lappend predicates $predicate
-	    } else {
-		return -code error "unexpected text in predicate \"$locpath\""
-	    }
-	}
-
-	set axis [string trim $axis]
-	set nodetest [string trim $nodetest]
-
-	# This step completed
-	if {[lsearch $axes $axis] < 0} {
-	    return -code error "invalid axis \"$axis\""
-	}
-	lappend path [list $axis $nodetest $predicates]
-
-	# Move to next step
-
-	if {[string length $locpath] && ![regexp ^/(.*) $locpath discard locpath]} {
-            set leftover $locpath
-	    return $path
-	}
-
-    }
-
-    return $path
-}
-
-# xpath::ParseExpr --
-#
-#	Parse one expression in a predicate
-#
-# Arguments:
-#	locpath	location path to parse
-#	leftoverVar	Name of variable in which to store remaining path
-#
-# Results:
-#	Returns parsed expression as a Tcl list
-
-proc xpath::ParseExpr {locpath leftoverVar} {
-    upvar $leftoverVar leftover
-    variable nodeTypes
-
-    set expr {}
-    set mode expr
-    set stack {}
-
-    while {[string index [string trimleft $locpath] 0] != "\]"} {
-	set locpath [string trimleft $locpath]
-	switch $mode {
-	    expr {
-		# We're looking for a term
-		if {[regexp ^-(.*) $locpath discard locpath]} {
-		    # UnaryExpr
-		    lappend stack "-"
-		} elseif {[regexp ^\\\$({$::xml::QName})(.*) $locpath discard varname discard locpath]} {
-		    # VariableReference
-		    lappend stack [list varRef $varname]
-		    set mode term
-		} elseif {[regexp {^\((.*)} $locpath discard locpath]} {
-		    # Start grouping
-		    set leftover2 {}
-		    lappend stack [list group [ParseExpr $locpath leftover2]]
-		    set locpath $leftover2
-		    unset leftover2
-
-		    if {[regexp {^\)(.*)} [string trimleft $locpath] discard locpath]} {
-			set mode term
-		    } else {
-			return -code error "unexpected text \"$locpath\", expected \")\""
-		    }
-
-		} elseif {[regexp {^"([^"]*)"(.*)} $locpath discard literal locpath]} {
-		    # Literal (" delimited)
-		    lappend stack [list literal $literal]
-		    set mode term
-		} elseif {[regexp {^'([^']*)'(.*)} $locpath discard literal locpath]} {
-		    # Literal (' delimited)
-		    lappend stack [list literal $literal]
-		    set mode term
-		} elseif {[regexp {^([0-9]+(\.[0-9]+)?)(.*)} $locpath discard number discard locpath]} {
-		    # Number
-		    lappend stack [list number $number]
-		    set mode term
-		} elseif {[regexp {^(\.[0-9]+)(.*)} $locpath discard number locpath]} {
-		    # Number
-		    lappend stack [list number $number]
-		    set mode term
-		} elseif {[regexp ^(${::xml::QName})\\(${::xml::allWsp}(.*) $locpath discard functionName discard locpath]} {
-		    # Function call start or abbreviated node-type test
-
-		    if {[lsearch $nodeTypes $functionName] >= 0} {
-			# Looking like a node-type test
-			if {[regexp ^\\)${::xml::allWsp}(.*) $locpath discard locpath]} {
-			    lappend stack [list path [list child [list $functionName ()] {}]]
-			    set mode term
-			} else {
-			    return -code error "invalid node-type test \"$functionName\""
-			}
-		    } else {
-			if {[regexp ^\\)${::xml::allWsp}(.*) $locpath discard locpath]} {
-			    set parameters {}
-			} else {
-			    set leftover2 {}
-			    set parameters [ParseExpr $locpath leftover2]
-			    set locpath $leftover2
-			    unset leftover2
-			    while {[regexp {^,(.*)} $locpath discard locpath]} {
-				set leftover2 {}
-				lappend parameters [ParseExpr $locpath leftover2]
-				set locpath $leftover2
-				unset leftover2
-			    }
-
-			    if {![regexp ^\\)${::xml::allWsp}(.*) [string trimleft $locpath] discard locpath]} {
-				return -code error "unexpected text \"locpath\" - expected \")\""
-			    }
-		        }
-
-			lappend stack [list function $functionName $parameters]
-			set mode term
-		    }
-
-		} else {
-		    # LocationPath
-		    set leftover2 {}
-		    lappend stack [list path [InnerSplit $locpath leftover2]]
-		    set locpath $leftover2
-		    unset leftover2
-		    set mode term
-		}
-	    }
-	    term {
-		# We're looking for an expression operator
-		if {[regexp ^-(.*) $locpath discard locpath]} {
-		    # UnaryExpr
-		    set stack [linsert $stack 0 expr "-"]
-		    set mode expr
-		} elseif {[regexp ^(and|or|\\=|!\\=|<|>|<\\=|>\\=|\\||\\+|\\-|\\*|div|mod)(.*) $locpath discard exprtype locpath]} {
-		    # AndExpr, OrExpr, EqualityExpr, RelationalExpr or UnionExpr
-		    set stack [linsert $stack 0 $exprtype]
-		    set mode expr
-		} else {
-		    return -code error "unexpected text \"$locpath\", expecting operator"
-		}
-	    }
-	    default {
-		# Should never be here!
-		return -code error "internal error"
-	    }
-	}
-    }
-
-    set leftover $locpath
-    return $stack
-}
-
-# xpath::ResolveWildcard --
-
-proc xpath::ResolveWildcard {nodetest typetest wildcard literal} {
-    variable nodeTypes
-
-    switch -glob -- [string length $nodetest],[string length $typetest],[string length $wildcard],[string length $literal] {
-	0,0,0,* {
-	    return -code error "bad location step (nothing parsed)"
-	}
-	0,0,* {
-	    # Name wildcard specified
-	    return *
-	}
-	*,0,0,* {
-	    # Element type test - nothing to do
-	    return $nodetest
-	}
-	*,0,*,* {
-	    # Internal error?
-	    return -code error "bad location step (found both nodetest and wildcard)"
-	}
-	*,*,0,0 {
-	    # Node type test
-	    if {[lsearch $nodeTypes $nodetest] < 0} {
-		return -code error "unknown node type \"$typetest\""
-	    }
-	    return [list $nodetest $typetest]
-	}
-	*,*,0,* {
-	    # Node type test
-	    if {[lsearch $nodeTypes $nodetest] < 0} {
-		return -code error "unknown node type \"$typetest\""
-	    }
-	    return [list $nodetest $literal]
-	}
-	default {
-	    # Internal error?
-	    return -code error "bad location step"
-	}
-    }
-}
-
-# xpath::join --
-#
-#	Reconstitute an XPath location path from a
-#	Tcl list representation.
-#
-# Arguments:
-#	spath	split path
-#
-# Results:
-#	Returns an Xpath location path
-
-proc xpath::join spath {
-    return -code error "not yet implemented"
-}
-
diff --git a/tclxml-3.2/tclxml.c b/tclxml-3.2/tclxml.c
deleted file mode 100755
index adc2e0f..0000000
--- a/tclxml-3.2/tclxml.c
+++ /dev/null
@@ -1,3708 +0,0 @@
-/*
- * tclxml.c --
- *
- *  Entry point for XML parsers, DOM and XSLT.
- *
- * Copyright (c) 2005-2007 Steve Ball, explain
- * http://www.explain.com.au/
- * Copyright (c) 1998-2004 Steve Ball, Zveno Pty Ltd
- *
- * See the file "LICENSE" for information on usage and
- * redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
- *
- * $Id: tclxml.c,v 1.2 2009/03/03 22:55:36 joye Exp $
- *
- */
-
-#include <tclxml/tclxml.h>
-#include <tclxml-libxml2/tclxml-libxml2.h>
-#include <tcldom-libxml2/tcldom-libxml2.h>
-#include <tclxslt/tclxslt.h>
-#include <string.h>
-
-#define TCL_DOES_STUBS \
-    (TCL_MAJOR_VERSION > 8 || TCL_MAJOR_VERSION == 8 && (TCL_MINOR_VERSION > 1 || \
-    (TCL_MINOR_VERSION == 1 && TCL_RELEASE_LEVEL == TCL_FINAL_RELEASE)))
-#ifdef USE_TCLXML_STUBS
-#ifndef TCLXML_DOES_STUBS
-# define TCLXML_DOES_STUBS TCL_DOES_STUBS
-#endif /* USE_TCLXML_STUBS */
-#endif /* TCL_DOES_STUBS */
-
-/*
- * The structure below is used to manage package options.
- */
-
-typedef struct ThreadSpecificData {
-  int initialized;
-
-  TclXML_ParserClassInfo *defaultParser;    /* Current default parser */
-  Tcl_HashTable *registeredParsers;         /* All known parser classes */
-
-  /*
-   * Retain a pointer to the whitespace variable
-   */
-
-  Tcl_Obj *whitespaceRE;
-
-  /*
-   * Counter to generate unique command names
-   */
-
-  int uniqueCounter;
-
-  /*
-   * Callback for external entity resolution
-   */
-
-  Tcl_Obj *externalentitycmd;
-  Tcl_Interp *interp;
-} ThreadSpecificData;
-static Tcl_ThreadDataKey dataKey;
-
-/* This string is a backup.  Value should be defined in xml package. */
-static char whitespace[] = " \t\r\n";
-
-/*
- * Configuration option tables
- */
-
-static CONST84 char *globalConfigureSwitches[] = {
-  "-externalentitycommand",
-  (char *) NULL
-};
-enum globalConfigureSwitches {
-  TCLXML_GLOBAL_EXTERNALENTITYCOMMAND
-};
-
-static CONST84 char *instanceConfigureSwitches[] = {
-    "-final",
-    "-validate",
-    "-baseurl", 
-    "-baseuri", 
-    "-encoding",
-    "-elementstartcommand",
-    "-elementendcommand",
-    "-characterdatacommand",
-    "-processinginstructioncommand",
-    "-defaultcommand",
-    "-unparsedentitydeclcommand",
-    "-notationdeclcommand",
-    "-externalentitycommand",
-    "-unknownencodingcommand",
-    "-commentcommand",
-    "-notstandalonecommand",
-    "-startcdatasectioncommand",
-    "-endcdatasectioncommand",
-    "-defaultexpandinternalentities",
-    "-elementdeclcommand",
-    "-attlistdeclcommand",
-    "-startdoctypedeclcommand",
-    "-enddoctypedeclcommand",
-    "-paramentityparsing",
-    "-ignorewhitespace",
-    "-reportempty",
-    "-entitydeclcommand",             /* added to avoid exception */
-    "-parameterentitydeclcommand",    /* added to avoid exception */
-    "-doctypecommand",                /* added to avoid exception */
-    "-entityreferencecommand",        /* added to avoid exception */
-    "-xmldeclcommand",                /* added to avoid exception */
-    (char *) NULL
-  };
-enum instanceConfigureSwitches {
-  TCLXML_FINAL, TCLXML_VALIDATE, TCLXML_BASEURL, TCLXML_BASEURI, 
-  TCLXML_ENCODING,
-  TCLXML_ELEMENTSTARTCMD, TCLXML_ELEMENTENDCMD,
-  TCLXML_DATACMD, TCLXML_PICMD, 
-  TCLXML_DEFAULTCMD,
-  TCLXML_UNPARSEDENTITYCMD, TCLXML_NOTATIONCMD,
-  TCLXML_EXTERNALENTITYCMD, TCLXML_UNKNOWNENCODINGCMD,
-  TCLXML_COMMENTCMD, TCLXML_NOTSTANDALONECMD,
-  TCLXML_STARTCDATASECTIONCMD, TCLXML_ENDCDATASECTIONCMD,
-  TCLXML_DEFAULTEXPANDINTERNALENTITIES,
-  TCLXML_ELEMENTDECLCMD, TCLXML_ATTLISTDECLCMD,
-  TCLXML_STARTDOCTYPEDECLCMD, TCLXML_ENDDOCTYPEDECLCMD,
-  TCLXML_PARAMENTITYPARSING,
-  TCLXML_NOWHITESPACE,
-  TCLXML_REPORTEMPTY,
-  TCLXML_ENTITYDECLCMD,
-  TCLXML_PARAMENTITYDECLCMD,
-  TCLXML_DOCTYPECMD,
-  TCLXML_ENTITYREFCMD,
-  TCLXML_XMLDECLCMD
-};
-
-/*
- * Prototypes for procedures defined later in this file:
- */
-
-static void TclXMLInstanceDeleteCmd _ANSI_ARGS_((ClientData clientData));
-static int  TclXMLDestroyParserInstance _ANSI_ARGS_((TclXML_Info *xmlinfo));
-static int  TclXMLInstanceCmd _ANSI_ARGS_((ClientData dummy,
-            Tcl_Interp *interp, int objc, struct Tcl_Obj *CONST objv[]));
-static int  TclXMLCreateParserCmd _ANSI_ARGS_((ClientData dummy,
-            Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]));
-static int  TclXMLParserClassCmd _ANSI_ARGS_((ClientData dummy,
-            Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]));
-static int  TclXMLResetParser _ANSI_ARGS_((Tcl_Interp *interp, TclXML_Info *xmlinfo));
-static int  TclXMLConfigureCmd _ANSI_ARGS_((ClientData dummy,
-            Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]));
-static Tcl_Obj* FindUniqueCmdName _ANSI_ARGS_((Tcl_Interp *interp));
-static int  TclXMLInstanceConfigure _ANSI_ARGS_((Tcl_Interp *interp,
-            TclXML_Info *xmlinfo, int objc, Tcl_Obj *CONST objv[]));
-static int  TclXMLCget _ANSI_ARGS_((Tcl_Interp *interp,
-            TclXML_Info *xmlinfo, int objc, Tcl_Obj *CONST objv[]));
-static int  TclXMLConfigureParserInstance _ANSI_ARGS_((
-            TclXML_Info *xmlinfo, Tcl_Obj *option, Tcl_Obj *value));
-static int  TclXMLGet _ANSI_ARGS_((Tcl_Interp *interp,
-            TclXML_Info *xmlinfo, int objc, Tcl_Obj *CONST objv[]));
-static int  TclXMLParse _ANSI_ARGS_((Tcl_Interp *interp,
-            TclXML_Info *xmlinfo, char *data, int len));
-static void TclXMLDispatchPCDATA _ANSI_ARGS_((TclXML_Info *xmlinfo));
-
-#if (TCL_MAJOR_VERSION == 8 && TCL_MINOR_VERSION == 0)
-
-/*
- *----------------------------------------------------------------------------
- *
- * Tcl_GetString --
- *
- *  Compatibility routine for Tcl 8.0
- *
- * Results:
- *  String representation of object..
- *
- * Side effects:
- *  None.
- *
- *----------------------------------------------------------------------------
- */
-
-static char *
-Tcl_GetString (obj)
-      Tcl_Obj *obj; /* Object to retrieve string from. */
-{
-  char *s;
-  int i;
-
-  s = Tcl_GetStringFromObj(obj, &i);
-  return s;
-}
-#endif /* TCL_MAJOR_VERSION == 8 && TCL_MINOR_VERSION == 0 */
-
-/*
- *----------------------------------------------------------------------------
- *
- * Tclxml_Init --
- *
- *  Initialisation routine for loadable module.
- *  Also calls the initialisation routines for TclDOM and TclXSLT,
- *  as these were originally separate modules.
- *
- * Results:
- *  None.
- *
- * Side effects:
- *  Creates commands in the interpreter,
- *  loads xml, dom and xslt packages.
- *
- *----------------------------------------------------------------------------
- */
-
-int
-Tclxml_Init (interp)
-      Tcl_Interp *interp; /* Interpreter to initialise. */
-{
-  ThreadSpecificData *tsdPtr;
-
-#ifdef USE_TCL_STUBS
-  if (Tcl_InitStubs(interp, "8.1", 0) == NULL) {
-    return TCL_ERROR;
-  }
-#endif
-
-  tsdPtr = (ThreadSpecificData *) Tcl_GetThreadData(&dataKey, sizeof(ThreadSpecificData));
-  tsdPtr->initialized = 1;
-  tsdPtr->defaultParser = NULL;
-  tsdPtr->uniqueCounter = 0;
-
-  /*
-  tsdPtr->whitespaceRE = Tcl_GetVar2Ex(interp, "::xml::Wsp", NULL, TCL_GLOBAL_ONLY);
-  if (tsdPtr->whitespaceRE == NULL) {
-    tsdPtr->whitespaceRE = Tcl_SetVar2Ex(interp, "::xml::Wsp", NULL, Tcl_NewStringObj(whitespace, -1), TCL_GLOBAL_ONLY|TCL_LEAVE_ERR_MSG);
-    if (tsdPtr->whitespaceRE == NULL) {
-      return TCL_ERROR;
-    }
-  }
-  Tcl_IncrRefCount(tsdPtr->whitespaceRE);
-  */
-
-  tsdPtr->registeredParsers = (Tcl_HashTable *) Tcl_Alloc(sizeof(Tcl_HashTable));
-  Tcl_InitHashTable(tsdPtr->registeredParsers, TCL_STRING_KEYS);
-
-  tsdPtr->externalentitycmd = NULL;
-  tsdPtr->interp = interp;
-
-  Tcl_CreateObjCommand(interp, "xml::configure", TclXMLConfigureCmd, NULL, NULL);
-  Tcl_CreateObjCommand(interp, "xml::parser", TclXMLCreateParserCmd, NULL, NULL);
-  Tcl_CreateObjCommand(interp, "xml::parserclass", TclXMLParserClassCmd, NULL, NULL);
-
-  if (Tclxml_libxml2_Init(interp) != TCL_OK) {
-    return TCL_ERROR;
-  }
-
-  /*
-  if (Tcldom_libxml2_Init(interp) != TCL_OK) {
-    return TCL_ERROR;
-  }
-
-  if (Tclxslt_libxslt_Init(interp) != TCL_OK) {
-    return TCL_ERROR;
-  }
-  */
-
-  #if TCLXML_DOES_STUBS
-    {
-      extern TclxmlStubs tclxmlStubs;
-      if (Tcl_PkgProvideEx(interp, "xml::c", TCLXML_VERSION,
-	(ClientData) &tclxmlStubs) != TCL_OK) {
-        return TCL_ERROR;
-      }
-    }
-  #else
-    if (Tcl_PkgProvide(interp, "xml::c", TCLXML_VERSION) != TCL_OK) {
-      return TCL_ERROR;
-    }
-  #endif
-
-  return TCL_OK;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * Tclxml_SafeInit --
- *
- *  Initialisation routine for loadable module in a safe interpreter.
- *
- * Results:
- *  None.
- *
- * Side effects:
- *  Creates commands in the interpreter,
- *  loads xml package.
- *
- *----------------------------------------------------------------------------
- */
-
-int
-Tclxml_SafeInit (interp)
-      Tcl_Interp *interp; /* Interpreter to initialise. */
-{
-    return Tclxml_Init(interp);
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXMLConfigureCmd --
- *
- *  Command for xml::configure command.
- *
- * Results:
- *  Depends on method.
- *
- * Side effects:
- *  Depends on method.
- *
- *----------------------------------------------------------------------------
- */
-
-static int
-TclXMLConfigureCmd(clientData, interp, objc, objv)
-     ClientData clientData;
-     Tcl_Interp *interp;
-     int objc;
-     Tcl_Obj *CONST objv[];
-{
-  ThreadSpecificData *tsdPtr = (ThreadSpecificData *) Tcl_GetThreadData(&dataKey, sizeof(ThreadSpecificData));
-  int index;
-
-  if (objc < 3) {
-    Tcl_SetResult(interp, "must specify option", NULL);
-    return TCL_ERROR;
-  } else if (objc == 3) {
-    /* TODO: retrieve option's value */
-    return TCL_OK;
-  } else if (objc % 2 == 1) {
-    Tcl_SetResult(interp, "value for option missing", NULL);
-    return TCL_ERROR;
-  }
-
-  for (objc -= 2, objv += 2; objc; objc -= 2, objv += 2) {
-    if (Tcl_GetIndexFromObj(interp, objv[0], globalConfigureSwitches,
-			    "switch", 0, &index) != TCL_OK) {
-      return TCL_ERROR;
-    }
-    switch ((enum globalConfigureSwitches) index) {
-    case TCLXML_GLOBAL_EXTERNALENTITYCOMMAND:
-      tsdPtr->externalentitycmd = objv[1];
-      Tcl_IncrRefCount(tsdPtr->externalentitycmd);
-      break;
-
-    default:
-      return TCL_ERROR;
-    }
-  }
-
-  return TCL_OK;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXMLParserClassCmd --
- *
- *  Command for xml::parserclass command.
- *
- * Results:
- *  Depends on method.
- *
- * Side effects:
- *  Depends on method.
- *
- *----------------------------------------------------------------------------
- */
-
-static int
-TclXMLParserClassCmd(clientData, interp, objc, objv)
-     ClientData clientData;
-     Tcl_Interp *interp;
-     int objc;
-     Tcl_Obj *CONST objv[];
-{
-  ThreadSpecificData *tsdPtr = (ThreadSpecificData *) Tcl_GetThreadData(&dataKey, sizeof(ThreadSpecificData));
-  TclXML_ParserClassInfo *classinfo;
-  int method, index;
-  Tcl_Obj *listPtr;
-  Tcl_HashEntry *entryPtr;
-  Tcl_HashSearch search;
-
-  static CONST84 char *methods[] = {
-    "create", "destroy", "info", 
-    NULL
-  };
-  enum methods {
-    TCLXML_CREATE, TCLXML_DESTROY, TCLXML_INFO
-  };
-  static CONST84 char *createOptions[] = {
-    "-createcommand", "-createentityparsercommand",
-    "-parsecommand", "-configurecommand",
-    "-deletecommand", "-resetcommand", 
-    NULL
-  };
-  enum createOptions {
-    TCLXML_CREATEPROC, TCLXML_CREATE_ENTITY_PARSER,
-    TCLXML_PARSEPROC, TCLXML_CONFIGUREPROC,
-    TCLXML_DELETEPROC, TCLXML_RESETPROC
-  };
-  static CONST84 char *infoMethods[] = {
-    "names", "default", 
-    NULL
-  };
-  enum infoMethods {
-    TCLXML_INFO_NAMES, TCLXML_INFO_DEFAULT
-  };
-
-  if (objc < 2) {
-    Tcl_WrongNumArgs(interp, 1, objv, "method ?args?");
-    return TCL_ERROR;
-  }
-
-  if (Tcl_GetIndexFromObj(interp, objv[1], methods, 
-              "method", 0, &method) != TCL_OK) {
-    return TCL_ERROR;
-  }
-
-  switch ((enum methods) method) {
-    case TCLXML_CREATE:
-      if (objc < 3) {
-        Tcl_WrongNumArgs(interp, 2, objv, "create name ?args?");
-        return TCL_ERROR;
-      }
-
-      classinfo = (TclXML_ParserClassInfo *) Tcl_Alloc(sizeof(TclXML_ParserClassInfo));
-      classinfo->name = objv[2];
-      Tcl_IncrRefCount(classinfo->name);
-      classinfo->create = NULL;
-      classinfo->createCmd = NULL;
-      classinfo->createEntity = NULL;
-      classinfo->createEntityCmd = NULL;
-      classinfo->parse = NULL;
-      classinfo->parseCmd = NULL;
-      classinfo->configure = NULL;
-      classinfo->configureCmd = NULL;
-      classinfo->reset = NULL;
-      classinfo->resetCmd = NULL;
-      classinfo->destroy = NULL;
-      classinfo->destroyCmd = NULL;
-
-      objv += 3;
-      objc -= 3;
-      while (objc > 1) {
-        if (Tcl_GetIndexFromObj(interp, objv[0], createOptions, 
-          "options", 0, &index) != TCL_OK) {
-          return TCL_ERROR;
-        }
-        Tcl_IncrRefCount(objv[1]);
-        switch ((enum createOptions) index) {
-
-          case TCLXML_CREATEPROC:
-
-            classinfo->createCmd = objv[1];
-            break;
-
-          case TCLXML_CREATE_ENTITY_PARSER:
-
-            classinfo->createEntityCmd = objv[1];
-            break;
-
-          case TCLXML_PARSEPROC:
-
-            classinfo->parseCmd = objv[1];
-            break;
-
-          case TCLXML_CONFIGUREPROC:
-
-            classinfo->configureCmd = objv[1];
-            break;
-
-          case TCLXML_RESETPROC:
-
-            classinfo->resetCmd = objv[1];
-            break;
-
-          case TCLXML_DELETEPROC:
-
-            classinfo->destroyCmd = objv[1];
-            break;
-
-          default:
-            Tcl_AppendResult(interp, "unknown option \"", Tcl_GetStringFromObj(objv[0], NULL), "\"", NULL);
-            Tcl_DecrRefCount(objv[1]);
-            Tcl_DecrRefCount(classinfo->name);
-            Tcl_Free((char *)classinfo);
-            return TCL_ERROR;
-        }
-    
-        objc -= 2;
-        objv += 2;
-
-      }
-
-      if (TclXML_RegisterXMLParser(interp, classinfo) != TCL_OK) {
-        Tcl_Free((char *)classinfo);
-        return TCL_ERROR;
-      }
-      break;
-    
-    case TCLXML_DESTROY:
-      /* Not yet implemented */
-      break;
-    
-    case TCLXML_INFO:
-      if (objc < 3) {
-        Tcl_WrongNumArgs(interp, 2, objv, "method");
-        return TCL_ERROR;
-      }
-
-      if (Tcl_GetIndexFromObj(interp, objv[2], infoMethods,
-                              "method", 0, &index) != TCL_OK) {
-        return TCL_ERROR;
-      }
-      switch ((enum infoMethods) index) {
-        case TCLXML_INFO_NAMES:
-          
-          listPtr = Tcl_NewListObj(0, NULL);
-          entryPtr = Tcl_FirstHashEntry(tsdPtr->registeredParsers, &search);
-          while (entryPtr != NULL) {
-            Tcl_ListObjAppendElement(interp, listPtr, Tcl_NewStringObj(Tcl_GetHashKey(tsdPtr->registeredParsers, entryPtr), -1));
-            entryPtr = Tcl_NextHashEntry(&search);
-          }
-
-          Tcl_SetObjResult(interp, listPtr);
-
-          break;
-
-        case TCLXML_INFO_DEFAULT:
-
-          if (!tsdPtr->defaultParser) {
-            Tcl_SetResult(interp, "", NULL);
-          } else {
-            Tcl_SetObjResult(interp, tsdPtr->defaultParser->name);
-          }
-
-          break;
-
-        default:
-            Tcl_SetResult(interp, "unknown method", NULL);
-            return TCL_ERROR;
-      }
-      break;
-
-    default:
-      Tcl_SetResult(interp, "unknown method", NULL);
-      return TCL_ERROR;
-    }
-
-  return TCL_OK;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXML_RegisterXMLParser --
- *
- *  Adds a new XML parser.
- *
- * Results:
- *  Standard Tcl return code.
- *
- * Side effects:
- *  New parser is available for use in parser instances.
- *
- *----------------------------------------------------------------------------
- */
-
-int
-TclXML_RegisterXMLParser(interp, classinfo)
-     Tcl_Interp *interp;
-     TclXML_ParserClassInfo *classinfo;
-{
-  ThreadSpecificData *tsdPtr = (ThreadSpecificData *) Tcl_GetThreadData(&dataKey, sizeof(ThreadSpecificData));
-  int new;
-  Tcl_HashEntry *entryPtr;
-
-  entryPtr = Tcl_CreateHashEntry(tsdPtr->registeredParsers, Tcl_GetStringFromObj(classinfo->name, NULL), &new);
-  if (!new) {
-    Tcl_Obj *ptr = Tcl_NewStringObj("parser class \"", -1);
-    Tcl_AppendObjToObj(ptr, classinfo->name);
-    Tcl_AppendObjToObj(ptr, Tcl_NewStringObj("\" already registered", -1));
-
-    Tcl_ResetResult(interp);
-    Tcl_SetObjResult(interp, ptr);
-    return TCL_ERROR;
-  }
-
-  Tcl_SetHashValue(entryPtr, (ClientData) classinfo);
-
-  /*
-   * Set default parser - last wins
-   */
-
-  tsdPtr->defaultParser = classinfo;
-
-  return TCL_OK;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXMLCreateParserCmd --
- *
- *  Creation command for xml::parser command.
- *
- * Results:
- *  The name of the newly created parser instance.
- *
- * Side effects:
- *  This creates a parser instance.
- *
- *----------------------------------------------------------------------------
- */
-
-static int
-TclXMLCreateParserCmd(clientData, interp, objc, objv)
-     ClientData clientData;
-     Tcl_Interp *interp;
-     int objc;
-     Tcl_Obj *CONST objv[];
-{
-  ThreadSpecificData *tsdPtr = (ThreadSpecificData *) Tcl_GetThreadData(&dataKey, sizeof(ThreadSpecificData));
-  TclXML_Info *xmlinfo;
-  int found, i, index, poption;
-
-  static CONST84 char *switches[] = {
-    "-parser",
-    (char *) NULL
-  };
-  enum switches {
-    TCLXML_PARSER
-  };
-
-  if (tsdPtr == NULL) {
-    Tcl_SetObjResult(interp, Tcl_NewStringObj("TclXML package improperly initialised", -1));
-    return TCL_ERROR;
-  }
-  if (!tsdPtr->defaultParser) {
-    Tcl_SetResult(interp, "no parsers available", NULL);
-    return TCL_ERROR;
-  }
-
-  /*
-   * Create the data structures for this parser.
-   */
-
-  if (!(xmlinfo = (TclXML_Info *) Tcl_Alloc(sizeof(TclXML_Info)))) {
-    Tcl_SetResult(interp, "unable to create parser", NULL);
-    return TCL_ERROR;
-  }
-  xmlinfo->interp = interp;
-  xmlinfo->clientData = NULL;
-  xmlinfo->base = NULL;
-  xmlinfo->encoding = Tcl_NewStringObj("utf-8", -1);
-
-  /*
-   * Find unique command name
-   */
-  if (objc < 2) {
-    xmlinfo->name = FindUniqueCmdName(interp);
-  } else {
-    xmlinfo->name = objv[1];
-    if (*(Tcl_GetStringFromObj(xmlinfo->name, NULL)) != '-') {
-      Tcl_IncrRefCount(xmlinfo->name);
-      objv++;
-      objc--;
-    } else {
-      xmlinfo->name = FindUniqueCmdName(interp);
-    }
-  }
-
-  xmlinfo->validate = 0;
-  xmlinfo->elementstartcommand = NULL;
-  xmlinfo->elementstart = NULL;
-  xmlinfo->elementstartdata = 0;
-  xmlinfo->elementendcommand = NULL;
-  xmlinfo->elementend = NULL;
-  xmlinfo->elementenddata = 0;
-  xmlinfo->datacommand = NULL;
-  xmlinfo->cdatacb = NULL;
-  xmlinfo->cdatacbdata = 0;
-  xmlinfo->picommand = NULL;
-  xmlinfo->pi = NULL;
-  xmlinfo->pidata = 0;
-  xmlinfo->defaultcommand = NULL;
-  xmlinfo->defaultcb = NULL;
-  xmlinfo->defaultdata = 0;
-  xmlinfo->unparsedcommand = NULL;
-  xmlinfo->unparsed = NULL;
-  xmlinfo->unparseddata = 0;
-  xmlinfo->notationcommand = NULL;
-  xmlinfo->notation = NULL;
-  xmlinfo->notationdata = 0;
-  xmlinfo->entitycommand = NULL;
-  xmlinfo->entity = NULL;
-  xmlinfo->entitydata = 0;
-  xmlinfo->unknownencodingcommand = NULL;
-  xmlinfo->unknownencoding = NULL;
-  xmlinfo->unknownencodingdata = 0;
-  /* ericm at scriptics.com */
-  xmlinfo->commentCommand                = NULL;
-  xmlinfo->comment                       = NULL;
-  xmlinfo->commentdata = 0;
-  xmlinfo->notStandaloneCommand          = NULL;
-  xmlinfo->notStandalone                 = NULL;
-  xmlinfo->notstandalonedata = 0;
-  xmlinfo->elementDeclCommand            = NULL;
-  xmlinfo->elementDecl                   = NULL;
-  xmlinfo->elementdecldata = 0;
-  xmlinfo->attlistDeclCommand            = NULL;
-  xmlinfo->attlistDecl                   = NULL;
-  xmlinfo->attlistdecldata = 0;
-  xmlinfo->startDoctypeDeclCommand       = NULL;
-  xmlinfo->startDoctypeDecl              = NULL;
-  xmlinfo->startdoctypedecldata = 0;
-  xmlinfo->endDoctypeDeclCommand         = NULL;
-  xmlinfo->endDoctypeDecl                = NULL;
-  xmlinfo->enddoctypedecldata = 0;
-#ifdef TCLXML_CDATASECTIONS
-  xmlinfo->startCDATASectionCommand      = NULL;
-  xmlinfo->startCDATASection             = NULL;
-  xmlinfo->startcdatasectiondata = 0;
-  xmlinfo->endCdataSectionCommand        = NULL;
-  xmlinfo->endCdataSection               = NULL;
-  xmlinfo->endcdatasectiondata = 0;
-#endif
-
-  /*
-   * Options may include an explicit desired parser class
-   *
-   * SF TclXML Bug 513909 ...
-   * Start search at first argument!  If there was a parser name
-   * specified we already skipped over it.
-   *
-   * Changing the search. Do not stop at the first occurence of
-   * "-parser". There can be more than one instance of the option in
-   * the argument list and it is the last instance that counts.
-   */
-
-  found   = 0;
-  i       = 1;
-  poption = -1;
-
-  while (i < objc) {
-    Tcl_ResetResult (interp);
-    if (Tcl_GetIndexFromObj(interp, objv[i], switches, "option", 0, &index) == TCL_OK) {
-      poption = i;
-      found   = 1;
-    }
-    i += 2;
-  }
-  Tcl_ResetResult (interp);
-
-  if (found) {
-    Tcl_HashEntry *pentry;
-
-    if (poption == (objc - 1)) {
-      Tcl_SetResult(interp, "no value for option", NULL);
-      goto error;
-    }
-
-    /*
-     * Use given parser class
-     */
-
-    pentry = Tcl_FindHashEntry(tsdPtr->registeredParsers,
-			       Tcl_GetStringFromObj(objv[poption + 1],
-						    NULL));
-    if (pentry != NULL) {
-      xmlinfo->parserClass = Tcl_GetHashValue(pentry);
-    } else {
-      Tcl_AppendResult(interp, "no such parser class \"",
-		       Tcl_GetStringFromObj(objv[poption + 1], NULL),
-		       "\"", NULL);
-      goto error;
-    }
-
-  } else {
-    /*
-     * Use default parser
-     */
-    xmlinfo->parserClass = tsdPtr->defaultParser;
-  }
-
-  if (TclXMLResetParser(interp, xmlinfo) != TCL_OK) {
-    /* this may leak memory...
-    Tcl_Free((char *)xmlinfo);
-    */
-    return TCL_ERROR;
-  }
-
-  /*
-   * Register a Tcl command for this parser instance.
-   */
-
-  Tcl_CreateObjCommand(interp, Tcl_GetStringFromObj(xmlinfo->name, NULL),
-      TclXMLInstanceCmd, (ClientData) xmlinfo, TclXMLInstanceDeleteCmd);
-
-  /*
-   * Handle configuration options
-   *
-   * SF TclXML Bug 513909 ...
-   * Note: If the caller used "-parser" to specify a parser class we
-   * have to take care that it and its argument are *not* seen by
-   * "TclXMLInstanceConfigure" because this option is not allowed
-   * during general configuration.
-   */
-
-  if (objc > 1) {
-    if (found) {
-      /*
-       * The options contained at least one instance of "-parser
-       * class". We now go through the whole list of arguments and
-       * build a new list which contains only the non-"-parser"
-       * switches. The 'ResetResult' takes care of clearing the
-       * interpreter result before "Tcl_GetIndexFromObj" tries to
-       * use it again.
-       */
-
-      int      res;
-      int       cfgc = 0;
-      Tcl_Obj** cfgv = (Tcl_Obj**) Tcl_Alloc (objc * sizeof (Tcl_Obj*));
-
-      i = 1;
-      while (i < objc) {
-	Tcl_ResetResult (interp);
-	if (Tcl_GetIndexFromObj(interp, objv[i], switches, "option", 0, &index) == TCL_OK) {
-	  /* Ignore "-parser" during copying */
-	  i += 2;
-	  continue;
-	}
-
-	cfgv [cfgc] = objv [i]; i++ ; cfgc++ ; /* copy option ... */
-	cfgv [cfgc] = objv [i]; i++ ; cfgc++ ; /* ...   and value */
-      }
-      Tcl_ResetResult (interp);
-
-      res = TclXMLInstanceConfigure(interp, xmlinfo, cfgc, cfgv);
-      Tcl_Free ((char*) cfgv);
-      if (res == TCL_ERROR) {
-	return TCL_ERROR;
-      }
-    } else {
-      /*
-       * The options contained no "-parser class" specification. We
-       * can propagate it unchanged.
-       */
-
-      if (TclXMLInstanceConfigure(interp, xmlinfo, objc - 1, objv + 1) == TCL_ERROR) {
-	return TCL_ERROR;
-      }
-    }
-  }
-
-  Tcl_SetObjResult(interp, xmlinfo->name);
-  return TCL_OK;
-
- error:
-/* this may leak memory
-  Tcl_Free((char*)xmlinfo);
-*/
-  return TCL_ERROR;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * FindUniqueCmdName --
- *
- *  Generate new command name in caller's namespace.
- *
- * Results:
- *  Returns newly allocated Tcl object containing name.
- *
- * Side effects:
- *  Allocates Tcl object.
- *
- *----------------------------------------------------------------------------
- */
-
-static Tcl_Obj *
-FindUniqueCmdName(interp)
-     Tcl_Interp *interp;
-{
-  ThreadSpecificData *tsdPtr = (ThreadSpecificData *) Tcl_GetThreadData(&dataKey, sizeof(ThreadSpecificData));
-  Tcl_Obj *name;
-  Tcl_CmdInfo cmdinfo;
-  char s[20];
-
-  name = Tcl_NewObj();
-  Tcl_IncrRefCount(name);
-
-  do {
-    sprintf(s, "xmlparser%d", tsdPtr->uniqueCounter++);
-    Tcl_SetStringObj(name, s, -1);
-  } while (Tcl_GetCommandInfo(interp, Tcl_GetStringFromObj(name, NULL), &cmdinfo));
-
-  return name;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXMLResetParser --
- *
- *  (Re-)Initialise the parser instance structure.
- *
- * Results:
- *  Parser made ready for parsing.
- *
- * Side effects:
- *  Destroys and creates a parser instance.
- *  Modifies TclXML_Info fields.
- *
- *----------------------------------------------------------------------------
- */
-
-static int
-TclXMLResetParser(interp, xmlinfo)
-     Tcl_Interp *interp;
-     TclXML_Info *xmlinfo;
-{
-  TclXML_ParserClassInfo *classInfo = (TclXML_ParserClassInfo *) xmlinfo->parserClass;
-
-  if (xmlinfo->base) {
-    Tcl_DecrRefCount(xmlinfo->base);
-    xmlinfo->base = NULL;
-  }
-  
-  xmlinfo->final = 1;
-  xmlinfo->status = TCL_OK;
-  xmlinfo->result = NULL;
-  xmlinfo->continueCount = 0;
-  xmlinfo->context = NULL;
-
-  xmlinfo->cdata = NULL;
-  xmlinfo->nowhitespace = 0;
-
-  xmlinfo->reportempty = 0;
-  xmlinfo->expandinternalentities = 1;
-  xmlinfo->paramentities = 1;
-
-  if (classInfo->reset) {
-    if ((*classInfo->reset)((ClientData) xmlinfo) != TCL_OK) {
-      return TCL_ERROR;
-    }
-  } else if (classInfo->resetCmd) {
-    Tcl_Obj *cmdPtr = Tcl_DuplicateObj(classInfo->resetCmd);
-    int result;
-
-    Tcl_IncrRefCount(cmdPtr);
-    Tcl_Preserve((ClientData) interp);
-    Tcl_ListObjAppendElement(interp, cmdPtr, xmlinfo->name);
-
-    result = Tcl_GlobalEvalObj(xmlinfo->interp, cmdPtr);
-
-    Tcl_DecrRefCount(cmdPtr);
-    Tcl_Release((ClientData) interp);
-
-    if (result != TCL_OK) {
-      Tcl_Free((char*)xmlinfo);
-      return TCL_ERROR;
-    }
-  } else if (classInfo->create) {
-
-    /*
-     * Otherwise destroy and then create a fresh parser instance
-     */
-
-    /*
-     * Destroy the old parser instance, if it exists
-     * Could probably just reset it, but this approach
-     * is pretty much guaranteed to work.
-     */
-
-    if (TclXMLDestroyParserInstance(xmlinfo) != TCL_OK) {
-      return TCL_ERROR;
-    }
-
-    /*
-     * Directly invoke the create routine
-     */
-    if ((xmlinfo->clientData = (*classInfo->create)(interp, xmlinfo)) == NULL) {
-      Tcl_Free((char*)xmlinfo);
-      return TCL_ERROR;
-    }
-  } else if (classInfo->createCmd) {
-    Tcl_Obj *cmdPtr = Tcl_DuplicateObj(classInfo->createCmd);
-    int result, i;
-
-    Tcl_IncrRefCount(cmdPtr);
-    Tcl_Preserve((ClientData) interp);
-    Tcl_ListObjAppendElement(interp, cmdPtr, xmlinfo->name);
-
-    result = Tcl_GlobalEvalObj(xmlinfo->interp, cmdPtr);
-
-    Tcl_DecrRefCount(cmdPtr);
-    Tcl_Release((ClientData) interp);
-
-    if (result != TCL_OK) {
-      Tcl_Free((char*)xmlinfo);
-      return TCL_ERROR;
-    } else {
-
-      /*
-       * Return result is parser instance argument
-       */
-
-      xmlinfo->clientData = (ClientData) Tcl_GetObjResult(interp);
-      Tcl_IncrRefCount((Tcl_Obj *) xmlinfo->clientData);
-
-      /*
-       * Add all of the currently configured callbacks to the
-       * creation command line.  Destroying the parser instance
-       * just clobbered all of these settings.
-       */
-
-      cmdPtr = Tcl_DuplicateObj(classInfo->configureCmd);
-      Tcl_IncrRefCount(cmdPtr);
-      Tcl_Preserve((ClientData) interp);
-      Tcl_ListObjAppendElement(interp, cmdPtr, xmlinfo->name);
-
-      for (i = 0; instanceConfigureSwitches[i]; i++) {
-        Tcl_Obj *objPtr = Tcl_NewStringObj(instanceConfigureSwitches[i], -1);
-        Tcl_ListObjAppendElement(interp, cmdPtr, objPtr);
-        TclXMLCget(interp, xmlinfo, 1, &objPtr);
-        Tcl_ListObjAppendElement(interp, cmdPtr, Tcl_GetObjResult(interp));
-      }
-
-      result = Tcl_GlobalEvalObj(xmlinfo->interp, cmdPtr);
-
-      Tcl_DecrRefCount(cmdPtr);
-      Tcl_Release((ClientData) interp);
-
-      if (result != TCL_OK) {
-        Tcl_Free((char *)xmlinfo);
-        return TCL_ERROR;
-      }
-
-    }
-
-  } else {
-    Tcl_SetResult(interp, "bad parser class data", NULL);
-    Tcl_Free((char*)xmlinfo);
-    return TCL_ERROR;
-  }
-  
-  return TCL_OK;
-}
-
-/*
- *----------------------------------------------------------------------
- *
- * TclXMLCreateEntityParser --
- *
- *  Create an entity parser, based on the original
- *      parser referred to by parent.
- *
- * Results:
- *  New entity parser created and initialized.
- *
- * Side effects:
- *  The TclXML_Info struct pointed to by external is modified.
- *
- *----------------------------------------------------------------------
- */
-
-static int
-TclXMLCreateEntityParser(interp, external, parent)
-     Tcl_Interp *interp;
-     TclXML_Info *external;
-     TclXML_Info *parent;
-{
-  TclXML_ParserClassInfo *extClassInfo;
-
-  external->parserClass = parent->parserClass;
-  extClassInfo = (TclXML_ParserClassInfo *) external->parserClass;
-
-  if (!extClassInfo->createEntity || !extClassInfo->createEntityCmd) {
-    Tcl_SetResult(interp, "cannot create entity parser", NULL);
-    return TCL_ERROR;
-  }
-
-    if (parent->elementstartcommand) {
-      Tcl_IncrRefCount(parent->elementstartcommand);
-    }
-    if (parent->elementendcommand) {
-      Tcl_IncrRefCount(parent->elementendcommand);
-    }
-    if (parent->datacommand) {
-      Tcl_IncrRefCount(parent->datacommand);
-    }
-    if (parent->picommand) {
-      Tcl_IncrRefCount(parent->picommand);
-    }
-    if (parent->defaultcommand) {
-      Tcl_IncrRefCount(parent->defaultcommand);
-    }
-    if (parent->unparsedcommand) {
-      Tcl_IncrRefCount(parent->unparsedcommand);
-    }
-    if (parent->notationcommand) {
-      Tcl_IncrRefCount(parent->notationcommand);
-    }
-    if (parent->entitycommand) {
-      Tcl_IncrRefCount(parent->entitycommand);
-    }
-    if (parent->unknownencodingcommand) {
-      Tcl_IncrRefCount(parent->unknownencodingcommand);
-    }
-    if (parent->commentCommand) {
-      Tcl_IncrRefCount(parent->commentCommand);
-    }
-    if (parent->notStandaloneCommand) {
-      Tcl_IncrRefCount(parent->notStandaloneCommand);
-    }
-#ifdef TCLXML_CDATASECTIONS
-    if (parent->startCdataSectionCommand) {
-      Tcl_IncrRefCount(parent->startCdataSectionCommand);
-    }
-    if (parent->endCdataSectionCommand) {
-      Tcl_IncrRefCount(parent->endCdataSectionCommand);
-    }
-#endif
-    if (parent->elementDeclCommand) {
-      Tcl_IncrRefCount(parent->elementDeclCommand);
-    }
-    if (parent->attlistDeclCommand) {
-      Tcl_IncrRefCount(parent->attlistDeclCommand);
-    }
-    if (parent->startDoctypeDeclCommand) {
-      Tcl_IncrRefCount(parent->startDoctypeDeclCommand);
-    }
-    if (parent->endDoctypeDeclCommand) {
-      Tcl_IncrRefCount(parent->endDoctypeDeclCommand);
-    }
-    
-    external->elementstartcommand      = parent->elementstartcommand;
-    external->elementstart             = parent->elementstart;
-    external->elementendcommand        = parent->elementendcommand;
-    external->elementend               = parent->elementend;
-    external->datacommand              = parent->datacommand;
-    external->cdatacb                  = parent->cdatacb;
-    external->picommand                = parent->picommand;
-    external->pi                       = parent->pi;
-    external->defaultcommand           = parent->defaultcommand;
-    external->defaultcb                = parent->defaultcb;
-    external->unparsedcommand          = parent->unparsedcommand;
-    external->unparsed                 = parent->unparsed;
-    external->notationcommand          = parent->notationcommand;
-    external->notation                 = parent->notation;
-    external->entitycommand            = parent->entitycommand;
-    external->entity                   = parent->entity;
-    external->unknownencodingcommand   = parent->unknownencodingcommand;
-    external->unknownencoding          = parent->unknownencoding;
-    external->commentCommand           = parent->commentCommand;
-    external->comment                  = parent->comment;
-    external->notStandaloneCommand     = parent->notStandaloneCommand;
-    external->notStandalone            = parent->notStandalone;
-    external->elementDeclCommand       = parent->elementDeclCommand;
-    external->elementDecl              = parent->elementDecl;
-    external->attlistDeclCommand       = parent->attlistDeclCommand;
-    external->attlistDecl              = parent->attlistDecl;
-    external->startDoctypeDeclCommand  = parent->startDoctypeDeclCommand;
-    external->startDoctypeDecl         = parent->startDoctypeDecl;
-    external->endDoctypeDeclCommand    = parent->endDoctypeDeclCommand;
-    external->endDoctypeDecl           = parent->endDoctypeDecl;
-#ifdef TCLXML_CDATASECTIONS
-    external->startCdataSectionCommand = parent->startCdataSectionCommand;
-    external->startCdataSection        = parent->startCdataSection;
-    external->endCdataSectionCommand   = parent->endCdataSectionCommand;
-    external->endCdataSection          = parent->endCdataSection;
-#endif
-
-    external->final = 1;
-    external->validate = parent->validate;
-    external->status = TCL_OK;
-    external->result = NULL;
-    external->continueCount = 0;
-    external->context = NULL;
-    external->cdata = NULL;
-    external->nowhitespace = parent->nowhitespace;
-	if (parent->encoding) {
-	  external->encoding = Tcl_DuplicateObj(parent->encoding);
-	} else {
-	  external->encoding = Tcl_NewStringObj("utf-8", -1);
-	}
-
-  if (extClassInfo->createEntity) {
-    /*
-     * Directly invoke the create routine
-     */
-    if ((external->clientData = (*extClassInfo->createEntity)(interp, (ClientData) external)) == NULL) {
-      Tcl_Free((char*)external);
-      return TCL_ERROR;
-    }
-  } else if (extClassInfo->createEntityCmd) {
-    int result;
-
-    result = Tcl_GlobalEvalObj(interp, extClassInfo->createEntityCmd);
-    if (result != TCL_OK) {
-      Tcl_Free((char*)external);
-      return TCL_ERROR;
-    } else {
-
-      /*
-       * Return result is parser instance argument
-       */
-
-      external->clientData = (ClientData) Tcl_GetObjResult(interp);
-      Tcl_IncrRefCount((Tcl_Obj *) external->clientData);
-
-    }
-  }
-
-  return TCL_OK;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXMLDestroyParserInstance --
- *
- *  Destroys the parser instance.
- *
- * Results:
- *  None.
- *
- * Side effects:
- *  Depends on class destroy proc.
- *
- *----------------------------------------------------------------------------
- */
-
-static int
-TclXMLDestroyParserInstance(xmlinfo)
-     TclXML_Info *xmlinfo;
-{
-  TclXML_ParserClassInfo *classInfo = (TclXML_ParserClassInfo *) xmlinfo->parserClass;
-
-  if (xmlinfo->clientData) {
-    if (classInfo->destroy) {
-      if ((*classInfo->destroy)(xmlinfo->clientData) != TCL_OK) {
-		if (xmlinfo->encoding) {
-		  Tcl_DecrRefCount(xmlinfo->encoding);
-		}
-        Tcl_Free((char *)xmlinfo);
-        return TCL_ERROR;
-      }
-    } else if (classInfo->destroyCmd) {
-      Tcl_Obj *cmdPtr = Tcl_DuplicateObj(classInfo->destroyCmd);
-       int result;
-
-      Tcl_IncrRefCount(cmdPtr);
-      Tcl_Preserve((ClientData) xmlinfo->interp);
-      Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, (Tcl_Obj *) xmlinfo->clientData);
-
-      result = Tcl_GlobalEvalObj(xmlinfo->interp, cmdPtr);
-      Tcl_DecrRefCount(cmdPtr);
-      Tcl_Release((ClientData) xmlinfo->interp);
-
-      if (result != TCL_OK) {
-		if (xmlinfo->encoding) {
-		  Tcl_DecrRefCount(xmlinfo->encoding);
-		}
-        Tcl_Free((char *)xmlinfo);
-        return TCL_ERROR;
-      }
-
-      Tcl_DecrRefCount((Tcl_Obj *) xmlinfo->clientData);
-
-    }
-
-    xmlinfo->clientData = NULL;
-
-  }
-
-  return TCL_OK;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXMLFreeParser --
- *
- *  Destroy the parser instance structure.
- *
- * Results:
- *  None.
- *
- * Side effects:
- *  Frees any memory allocated for the XML parser instance.
- *
- *----------------------------------------------------------------------------
- */
-
-static void
-TclXMLFreeParser(xmlinfo)
-     TclXML_Info *xmlinfo;
-{
-  if (TclXMLDestroyParserInstance(xmlinfo) == TCL_OK) {
-	if (xmlinfo->encoding) {
-	  Tcl_DecrRefCount(xmlinfo->encoding);
-	}
-	Tcl_Free((char*)xmlinfo);
-  }
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXMLInstanceCmd --
- *
- *  Implements instance command for XML parsers.
- *
- * Results:
- *  Depends on the method.
- *
- * Side effects:
- *  Depends on the method.
- *
- *----------------------------------------------------------------------------
- */
-
-static int
-TclXMLInstanceCmd (clientData, interp, objc, objv)
-     ClientData clientData;
-     Tcl_Interp *interp;
-     int objc;
-     Tcl_Obj *CONST objv[];
-{
-  TclXML_Info *xmlinfo = (TclXML_Info *) clientData;
-  TclXML_Info *child;
-  char *encoding, *data;
-  int len, index, result = TCL_OK;
-  Tcl_Obj *childNamePtr;
-  static CONST84 char *options[] = {
-    "configure", "cget", "entityparser", "free", "get", "parse", "reset", NULL
-  };
-  enum options {
-    TCLXML_CONFIGURE, TCLXML_CGET, TCLXML_ENTITYPARSER, TCLXML_FREE, TCLXML_GET,
-    TCLXML_PARSE, TCLXML_RESET
-  };
-
-  if (objc < 2) {
-    Tcl_WrongNumArgs(interp, 1, objv, "method ?args?");
-    return TCL_ERROR;
-  }
-
-  if (Tcl_GetIndexFromObj(interp, objv[1], options, "option", 0,
-                          &index) != TCL_OK) {
-    return TCL_ERROR;
-  }
-
-  switch ((enum options) index) {
-    case TCLXML_CONFIGURE:
-
-      result = TclXMLInstanceConfigure(interp, xmlinfo, objc - 2, objv + 2);
-      break;
-
-    case TCLXML_CGET:
-
-      if (objc != 3) {
-       Tcl_WrongNumArgs(interp, 1, objv, "cget option");
-       return TCL_ERROR;
-      }
-
-      result = TclXMLCget(interp, xmlinfo, objc - 2, objv + 2);
-      break;
-
-    case TCLXML_ENTITYPARSER:
-      /* ericm at scriptics.com, 1999.9.13 */
-
-      /* check for args - Pat Thoyts */
-      if (objc == 2) {
-	childNamePtr = FindUniqueCmdName(interp);
-      } else if (objc == 3) {
-	childNamePtr = objv[2];
-      } else {
-        Tcl_WrongNumArgs(interp, 1, objv, "entityparser ?args?");
-        return TCL_ERROR;
-      }
-
-      /*
-       * Create the data structures for this parser.
-       */
-      if (!(child = (TclXML_Info *) Tcl_Alloc(sizeof(TclXML_Info)))) {
-        Tcl_Free((char*)child);
-        Tcl_SetResult(interp, "unable to create parser", NULL);
-        return TCL_ERROR;
-      }
-
-      child->interp = interp;
-      Tcl_IncrRefCount(childNamePtr);
-      child->name = childNamePtr;
-    
-      /* Actually create the parser instance */
-      if (TclXMLCreateEntityParser(interp, child,
-        xmlinfo) != TCL_OK) {
-	Tcl_DecrRefCount(childNamePtr);
-        Tcl_Free((char*)child);
-        return TCL_ERROR;
-      }
-    
-      /* Register a Tcl command for this parser instance */
-      Tcl_CreateObjCommand(interp, Tcl_GetString(child->name),
-          TclXMLInstanceCmd, (ClientData) child, TclXMLInstanceDeleteCmd);
-
-      Tcl_SetObjResult(interp, child->name);
-      result = TCL_OK;
-      break;
-   
-    case TCLXML_FREE:
-
-      /* ericm at scriptics.com, 1999.9.13 */
-      Tcl_DeleteCommand(interp, Tcl_GetString(xmlinfo->name));
-      result = TCL_OK;
-      break;
-      
-    case TCLXML_GET:
-      
-      /* ericm at scriptics.com, 1999.6.28 */
-      result = TclXMLGet(interp, xmlinfo, objc - 2, objv + 2);
-      break;
-
-    case TCLXML_PARSE:
-
-      if (objc != 3) {
-        Tcl_WrongNumArgs(interp, 2, objv, "data");
-        return TCL_ERROR;
-      }
-
-	  if (xmlinfo->encoding) {
-		encoding = Tcl_GetStringFromObj(xmlinfo->encoding, NULL);
-	  } else {
-		encoding = "utf-8";
-	  }
-	  if (strlen(encoding) == 0 || strcmp(encoding, "utf-8") == 0) {
-		data = Tcl_GetStringFromObj(objv[2], &len);
-	  } else {
-	    data = (char *) Tcl_GetByteArrayFromObj(objv[2], &len);
-	  }
-
-      result = TclXMLParse(interp, xmlinfo, data, len);
-
-      break;
-
-    case TCLXML_RESET:
-
-      if (objc > 2) {
-        Tcl_WrongNumArgs(interp, 1, objv, "");
-        return TCL_ERROR;
-      }
-
-      TclXMLResetParser(interp, xmlinfo);
-      break;
-
-    default:
-
-      Tcl_SetResult(interp, "unknown method", NULL);
-      return TCL_ERROR;
-  }
-
-  return result;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXMLParse --
- *
- *  Invoke parser class' parse proc and check return result.
- *
- * Results:
- *     TCL_OK if no errors, TCL_ERROR otherwise.
- *
- * Side effects:
- *     Sets interpreter result as appropriate.
- *
- *----------------------------------------------------------------------------
- */
-
-static int
-TclXMLParse (interp, xmlinfo, data, len)
-     Tcl_Interp *interp;
-     TclXML_Info *xmlinfo;
-     char *data;
-     int len;
-{
-  int result;
-  TclXML_ParserClassInfo *classInfo = (TclXML_ParserClassInfo *) xmlinfo->parserClass;
-
-  xmlinfo->status = TCL_OK;
-  if (xmlinfo->result != NULL) {
-    Tcl_DecrRefCount(xmlinfo->result);
-  }
-  xmlinfo->result = NULL;
-
-  if (classInfo->parse) {
-    if ((*classInfo->parse)(xmlinfo->clientData, data, len, xmlinfo->final) != TCL_OK) {
-      return TCL_ERROR;
-    }
-  } else if (classInfo->parseCmd) {
-    Tcl_Obj *cmdPtr = Tcl_DuplicateObj(classInfo->parseCmd);
-    Tcl_IncrRefCount(cmdPtr);
-    Tcl_Preserve((ClientData) xmlinfo->interp);
-
-    if (xmlinfo->clientData) {
-      Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, (Tcl_Obj *) xmlinfo->clientData);
-    } else if (xmlinfo->name) {
-      Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, xmlinfo->name);
-    }
-    Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, Tcl_NewStringObj(data, len));
-
-    result = Tcl_GlobalEvalObj(xmlinfo->interp, cmdPtr);
-
-    Tcl_DecrRefCount(cmdPtr);
-    Tcl_Release((ClientData) xmlinfo->interp);
-
-    if (result != TCL_OK) {
-      return TCL_ERROR;
-    }
-
-  } else {
-    Tcl_SetResult(interp, "XML parser cannot parse", NULL);
-    return TCL_ERROR;
-  }
-
-  switch (xmlinfo->status) {
-    case TCL_OK:
-    case TCL_BREAK:
-    case TCL_CONTINUE:
-      TclXMLDispatchPCDATA(xmlinfo);
-      Tcl_ResetResult(interp);
-      return TCL_OK;
-
-    case TCL_ERROR:
-      Tcl_SetObjResult(interp, xmlinfo->result);
-      return TCL_ERROR;
-
-    default:
-      /*
-       * Propagate application-specific error condition.
-       * Patch by Marshall Rose <mrose at dbc.mtview.ca.us>
-       */
-      Tcl_SetObjResult(interp, xmlinfo->result);
-      return xmlinfo->status;
-  }
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXMLInstanceConfigure --
- *
- *  Configures a XML parser instance.
- *
- * Results:
- *  Depends on the method.
- *
- * Side effects:
- *  Depends on the method.
- *
- *----------------------------------------------------------------------------
- */
-
-static int
-TclXMLInstanceConfigure (interp, xmlinfo, objc, objv)
-     Tcl_Interp *interp;
-     TclXML_Info *xmlinfo;
-     int objc;
-     Tcl_Obj *CONST objv[];
-{
-  int index, bool, doParse = 0, result;
-  TclXML_ParserClassInfo *classinfo = (TclXML_ParserClassInfo *) xmlinfo->parserClass;
-
-  while (objc > 1) {
-    /*
-     * Firstly, pass the option to the parser's own 
-     * configuration management routine.
-     * It may pass back an error or break code to
-     * stop us from further processing the options.
-     */
-
-    if (classinfo->configure) {
-      result = (*classinfo->configure)(xmlinfo->clientData, objv[0], objv[1]);
-      if (result == TCL_BREAK) {
-	objc -= 2;
-	objv += 2;
-	continue;
-      }
-      if (result != TCL_OK) {
-	return TCL_ERROR;
-      }
-    } else if (classinfo->configureCmd) {
-      Tcl_Obj *cmdPtr = Tcl_DuplicateObj(classinfo->configureCmd);
-
-      Tcl_IncrRefCount(cmdPtr);
-      Tcl_Preserve((ClientData) interp);
-
-      if (xmlinfo->clientData) {
-	Tcl_ListObjAppendElement(interp, cmdPtr, (Tcl_Obj *) xmlinfo->clientData);
-      } else if (xmlinfo->name) {
-	Tcl_ListObjAppendElement(interp, cmdPtr, xmlinfo->name);
-      }
-
-      Tcl_ListObjAppendElement(interp, cmdPtr, objv[0]);
-      Tcl_ListObjAppendElement(interp, cmdPtr, objv[1]);
-
-      result = Tcl_GlobalEvalObj(interp, cmdPtr);
-
-      Tcl_DecrRefCount(cmdPtr);
-      Tcl_Release((ClientData) interp);
-
-      if (result == TCL_BREAK) {
-	objc -= 2;
-	objv += 2;
-	continue;
-      } else if (result != TCL_OK) {
-	return TCL_ERROR;
-      }
-    }
-
-    Tcl_ResetResult (interp);
-
-    if (Tcl_GetIndexFromObj(interp, objv[0], instanceConfigureSwitches,
-                            "switch", 0, &index) != TCL_OK) {
-      return TCL_ERROR;
-    }
-    switch ((enum instanceConfigureSwitches) index) {
-      case TCLXML_FINAL:            /* -final */
-
-        if (Tcl_GetBooleanFromObj(interp, objv[1], &bool) != TCL_OK) {
-          return TCL_ERROR;
-        }
-
-        if (bool && !xmlinfo->final) {
-          doParse = 1;
-
-        } else if (!bool && xmlinfo->final) {
-          /*
-           * Reset the parser for new input
-           */
-
-          TclXMLResetParser(interp, xmlinfo);
-          doParse = 0;
-        }
-        xmlinfo->final = bool;
-        break;
-
-	  case TCLXML_ENCODING: /* -encoding */
-		if (xmlinfo->encoding) {
-		  Tcl_DecrRefCount(xmlinfo->encoding);
-		}
-		xmlinfo->encoding = objv[1];
-		Tcl_IncrRefCount(xmlinfo->encoding);
-		break;
-
-      case TCLXML_VALIDATE:         /* -validate */
-        if (Tcl_GetBooleanFromObj(interp, objv[1], &bool) != TCL_OK) {
-          return TCL_ERROR;
-        }
-        /*
-         * If the parser is in the middle of parsing a document,
-         * this will be ignored.  Perhaps an error should be returned?
-         */
-        xmlinfo->validate = bool;
-        break;
-
-    case TCLXML_BASEURL:             /* -baseurl, -baseuri */
-    case TCLXML_BASEURI:
-        if (xmlinfo->base != NULL) {
-          Tcl_DecrRefCount(xmlinfo->base);
-        }
-
-        xmlinfo->base = objv[1];
-        Tcl_IncrRefCount(xmlinfo->base);
-        break;
-
-      case TCLXML_DEFAULTEXPANDINTERNALENTITIES:    /* -defaultexpandinternalentities */
-        /* ericm at scriptics */
-        if (Tcl_GetBooleanFromObj(interp, objv[1], &bool) != TCL_OK) {
-          return TCL_ERROR;
-        }
-        xmlinfo->expandinternalentities = bool;
-        break;
-
-      case TCLXML_PARAMENTITYPARSING:
-        /* ericm at scriptics */
-      case TCLXML_NOWHITESPACE:
-      case TCLXML_REPORTEMPTY:
-        /*
-         * All of these get passed through to the instance's
-         * configure procedure.
-         */
-
-        if (TclXMLConfigureParserInstance(xmlinfo, objv[0], objv[1]) != TCL_OK) {
-          return TCL_ERROR;
-        }
-        break;
-
-      case TCLXML_ELEMENTSTARTCMD:  /* -elementstartcommand */
-
-        if (xmlinfo->elementstartcommand != NULL) {
-          Tcl_DecrRefCount(xmlinfo->elementstartcommand);
-        }
-        xmlinfo->elementstart = NULL;
-
-        xmlinfo->elementstartcommand = objv[1];
-        Tcl_IncrRefCount(xmlinfo->elementstartcommand);
-        break;
-
-      case TCLXML_ELEMENTENDCMD:        /* -elementendcommand */
-
-        if (xmlinfo->elementendcommand != NULL) {
-          Tcl_DecrRefCount(xmlinfo->elementendcommand);
-        }
-        xmlinfo->elementend = NULL;
-
-        xmlinfo->elementendcommand = objv[1];
-        Tcl_IncrRefCount(xmlinfo->elementendcommand);
-        break;
-
-      case TCLXML_DATACMD:      /* -characterdatacommand */
-
-        if (xmlinfo->datacommand != NULL) {
-          Tcl_DecrRefCount(xmlinfo->datacommand);
-        }
-        xmlinfo->cdatacb = NULL;
-
-        xmlinfo->datacommand = objv[1];
-        Tcl_IncrRefCount(xmlinfo->datacommand);
-        break;
-
-      case TCLXML_PICMD:         /* -processinginstructioncommand */
-
-        if (xmlinfo->picommand != NULL) {
-          Tcl_DecrRefCount(xmlinfo->picommand);
-        }
-        xmlinfo->pi = NULL;
-
-        xmlinfo->picommand = objv[1];
-        Tcl_IncrRefCount(xmlinfo->picommand);
-        break;
-
-      case TCLXML_DEFAULTCMD:       /* -defaultcommand */
-
-        if (xmlinfo->defaultcommand != NULL) {
-          Tcl_DecrRefCount(xmlinfo->defaultcommand);
-        }
-        xmlinfo->defaultcb = NULL;
-
-        xmlinfo->defaultcommand = objv[1];
-        Tcl_IncrRefCount(xmlinfo->defaultcommand);
-        break;
-
-      case TCLXML_UNPARSEDENTITYCMD:        /* -unparsedentitydeclcommand */
-
-        if (xmlinfo->unparsedcommand != NULL) {
-          Tcl_DecrRefCount(xmlinfo->unparsedcommand);
-        }
-        xmlinfo->unparsed = NULL;
-
-        xmlinfo->unparsedcommand = objv[1];
-        Tcl_IncrRefCount(xmlinfo->unparsedcommand);
-        break;
-
-      case TCLXML_NOTATIONCMD:          /* -notationdeclcommand */
-
-        if (xmlinfo->notationcommand != NULL) {
-          Tcl_DecrRefCount(xmlinfo->notationcommand);
-        }
-        xmlinfo->notation = NULL;
-
-        xmlinfo->notationcommand = objv[1];
-        Tcl_IncrRefCount(xmlinfo->notationcommand);
-        break;
-
-      case TCLXML_EXTERNALENTITYCMD:    /* -externalentitycommand */
-
-        if (xmlinfo->entitycommand != NULL) {
-          Tcl_DecrRefCount(xmlinfo->entitycommand);
-        }
-        xmlinfo->entity = NULL;
-
-        xmlinfo->entitycommand = objv[1];
-        Tcl_IncrRefCount(xmlinfo->entitycommand);
-        break;
-
-      case TCLXML_UNKNOWNENCODINGCMD:       /* -unknownencodingcommand */
-
-        /* Not implemented */
-        break;
-
-        if (xmlinfo->unknownencodingcommand != NULL) {
-          Tcl_DecrRefCount(xmlinfo->unknownencodingcommand);
-        }
-        xmlinfo->unknownencoding = NULL;
-
-        xmlinfo->unknownencodingcommand = objv[1];
-        Tcl_IncrRefCount(xmlinfo->unknownencodingcommand);
-        break;
-    
-      case TCLXML_COMMENTCMD:      /* -commentcommand */
-        /* ericm at scriptics.com */
-        if (xmlinfo->commentCommand != NULL) {
-          Tcl_DecrRefCount(xmlinfo->commentCommand);
-        }
-        xmlinfo->comment = NULL;
-
-        xmlinfo->commentCommand = objv[1];
-        Tcl_IncrRefCount(xmlinfo->commentCommand);
-        break;
-
-      case TCLXML_NOTSTANDALONECMD:      /* -notstandalonecommand */
-        /* ericm at scriptics.com */
-        if (xmlinfo->notStandaloneCommand != NULL) {
-          Tcl_DecrRefCount(xmlinfo->notStandaloneCommand);
-        }
-        xmlinfo->notStandalone = NULL;
-
-        xmlinfo->notStandaloneCommand = objv[1];
-        Tcl_IncrRefCount(xmlinfo->notStandaloneCommand);
-        break;
-
-#ifdef TCLXML_CDATASECTIONS
-      case TCLXML_STARTCDATASECTIONCMD: /* -startcdatasectioncommand */
-        /* ericm at scriptics */
-        if (xmlinfo->startCdataSectionCommand != NULL) {
-          Tcl_DecrRefCount(xmlinfo->startCdataSectionCommand);
-        }
-        xmlinfo->startCDATASection = NULL;
-
-        xmlinfo->startCdataSectionCommand = objv[1];
-        Tcl_IncrRefCount(xmlinfo->startCdataSectionCommand);
-        break;
-
-      case TCLXML_ENDCDATASECTIONCMD:       /* -endcdatasectioncommand */
-        /* ericm at scriptics */
-        if (xmlinfo->endCdataSectionCommand != NULL) {
-          Tcl_DecrRefCount(xmlinfo->endCdataSectionCommand);
-        }
-        xmlinfo->endCDATASection = NULL;
-
-        xmlinfo->endCdataSectionCommand = objv[1];
-        Tcl_IncrRefCount(xmlinfo->endCdataSectionCommand);
-        break;
-#endif
-
-      case TCLXML_ELEMENTDECLCMD:      /* -elementdeclcommand */
-        /* ericm at scriptics.com */
-        if (xmlinfo->elementDeclCommand != NULL) {
-          Tcl_DecrRefCount(xmlinfo->elementDeclCommand);
-        }
-        xmlinfo->elementDecl = NULL;
-
-        xmlinfo->elementDeclCommand = objv[1];
-        Tcl_IncrRefCount(xmlinfo->elementDeclCommand);
-        break;
-
-      case TCLXML_ATTLISTDECLCMD:      /* -attlistdeclcommand */
-        /* ericm at scriptics.com */
-        if (xmlinfo->attlistDeclCommand != NULL) {
-          Tcl_DecrRefCount(xmlinfo->attlistDeclCommand);
-        }
-        xmlinfo->attlistDecl = NULL;
-
-        xmlinfo->attlistDeclCommand = objv[1];
-        Tcl_IncrRefCount(xmlinfo->attlistDeclCommand);
-        break;
-
-      case TCLXML_STARTDOCTYPEDECLCMD:      /* -startdoctypedeclcommand */
-        /* ericm at scriptics.com */
-        if (xmlinfo->startDoctypeDeclCommand != NULL) {
-          Tcl_DecrRefCount(xmlinfo->startDoctypeDeclCommand);
-        }
-        xmlinfo->startDoctypeDecl = NULL;
-
-        xmlinfo->startDoctypeDeclCommand = objv[1];
-        Tcl_IncrRefCount(xmlinfo->startDoctypeDeclCommand);
-        break;
-
-      case TCLXML_ENDDOCTYPEDECLCMD:      /* -enddoctypedeclcommand */
-        /* ericm at scriptics.com */
-        if (xmlinfo->endDoctypeDeclCommand != NULL) {
-          Tcl_DecrRefCount(xmlinfo->endDoctypeDeclCommand);
-        }
-        xmlinfo->endDoctypeDecl = NULL;
-
-        xmlinfo->endDoctypeDeclCommand = objv[1];
-        Tcl_IncrRefCount(xmlinfo->endDoctypeDeclCommand);
-        break;
-
-      case TCLXML_ENTITYDECLCMD:      /* -entitydeclcommand */
-      case TCLXML_PARAMENTITYDECLCMD: /* -parameterentitydeclcommand */
-      case TCLXML_DOCTYPECMD:         /* -doctypecommand */
-      case TCLXML_ENTITYREFCMD:       /* -entityreferencecommand */
-      case TCLXML_XMLDECLCMD:         /* -xmldeclcommand */
-	/* commands used by tcldom, but not here yet */
-        break;
-
-      default:
-        return TCL_ERROR;
-        break;
-    }
-
-    objv += 2;
-    objc -= 2;
-
-  }
-
-  if (doParse) {
-    return TclXMLParse(interp, xmlinfo, "", 0);
-  } else {
-    return TCL_OK;
-  }
-
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXMLCget --
- *
- *  Returns setting of configuration option.
- *
- * Results:
- *  Option value.
- *
- * Side effects:
- *  None.
- *
- *----------------------------------------------------------------------------
- */
-
-static int
-TclXMLCget (interp, xmlinfo, objc, objv)
-     Tcl_Interp *interp;
-     TclXML_Info *xmlinfo;
-     int objc;
-     Tcl_Obj *CONST objv[];
-{
-  int index;
-
-  if (Tcl_GetIndexFromObj(interp, objv[0], instanceConfigureSwitches, "switch", 0, &index) != TCL_OK) {
-    return TCL_ERROR;
-  }
-
-  Tcl_SetObjResult(interp, Tcl_NewObj());
-
-  switch ((enum instanceConfigureSwitches) index) {
-    case TCLXML_FINAL:
-      Tcl_SetObjResult(interp, Tcl_NewBooleanObj(xmlinfo->final));
-      break;
-    case TCLXML_VALIDATE:
-      Tcl_SetObjResult(interp, Tcl_NewBooleanObj(xmlinfo->validate));
-      break;
-    case TCLXML_DEFAULTEXPANDINTERNALENTITIES:
-      Tcl_SetObjResult(interp, Tcl_NewBooleanObj(xmlinfo->expandinternalentities));
-      break;
-    case TCLXML_REPORTEMPTY:
-      Tcl_SetObjResult(interp, Tcl_NewBooleanObj(xmlinfo->reportempty));
-      break;
-    case TCLXML_PARAMENTITYPARSING:
-      Tcl_SetObjResult(interp, Tcl_NewBooleanObj(xmlinfo->paramentities));
-      break;
-    case TCLXML_NOWHITESPACE:
-      Tcl_SetObjResult(interp, Tcl_NewBooleanObj(xmlinfo->nowhitespace));
-      break;
-    case TCLXML_BASEURL:
-	case TCLXML_BASEURI:
-      if (xmlinfo->base) {
-        Tcl_SetObjResult(interp, xmlinfo->base);
-      }
-      break;
-	case TCLXML_ENCODING:
-	  if (xmlinfo->encoding) {
-		Tcl_SetObjResult(interp, xmlinfo->encoding);
-	  }
-	  break;
-    case TCLXML_ELEMENTSTARTCMD:
-      if (xmlinfo->elementstartcommand) {
-        Tcl_SetObjResult(interp, xmlinfo->elementstartcommand);
-      }
-      break;
-    case TCLXML_ELEMENTENDCMD:
-      if (xmlinfo->elementendcommand) {
-        Tcl_SetObjResult(interp, xmlinfo->elementendcommand);
-      }
-      break;
-    case TCLXML_DATACMD:
-      if (xmlinfo->datacommand) {
-       Tcl_SetObjResult(interp, xmlinfo->datacommand);
-      }
-      break;
-    case TCLXML_PICMD:
-      if (xmlinfo->picommand) {
-        Tcl_SetObjResult(interp, xmlinfo->picommand);
-      }
-      break;
-    case TCLXML_DEFAULTCMD:
-      if (xmlinfo->defaultcommand) {
-        Tcl_SetObjResult(interp, xmlinfo->defaultcommand);
-      }
-      break;
-    case TCLXML_UNPARSEDENTITYCMD:
-      if (xmlinfo->unparsedcommand) {
-        Tcl_SetObjResult(interp, xmlinfo->unparsedcommand);
-      }
-      break;
-    case TCLXML_NOTATIONCMD:
-      if (xmlinfo->notationcommand) {
-        Tcl_SetObjResult(interp, xmlinfo->notationcommand);
-      }
-      break;
-    case TCLXML_EXTERNALENTITYCMD:
-      if (xmlinfo->entitycommand) {
-        Tcl_SetObjResult(interp, xmlinfo->entitycommand);
-      }
-      break;
-    case TCLXML_UNKNOWNENCODINGCMD:
-      if (xmlinfo->unknownencodingcommand) {
-        Tcl_SetObjResult(interp, xmlinfo->unknownencodingcommand);
-      }
-      break;
-    case TCLXML_COMMENTCMD:
-      if (xmlinfo->commentCommand) {
-        Tcl_SetObjResult(interp, xmlinfo->commentCommand);
-      }
-      break;
-    case TCLXML_NOTSTANDALONECMD:
-      if (xmlinfo->notStandaloneCommand) {
-        Tcl_SetObjResult(interp, xmlinfo->notStandaloneCommand);
-      }
-      break;
-#ifdef TCLXML_CDATASECTIONS
-    case TCLXML_STARTCDATASECTIONCMD:
-      if (xmlinfo->startCdataSectionCommand) {
-        Tcl_SetObjResult(interp, xmlinfo->startCdataSectionCommand);
-      }
-      break;
-    case TCLXML_ENDCDATASECTIONCMD:
-      if (xmlinfo->endCdataSectionCommand) {
-        Tcl_SetObjResult(interp, xmlinfo->endCdataSectionCommand);
-      }
-      break;
-#else
-    case TCLXML_STARTCDATASECTIONCMD:
-    case TCLXML_ENDCDATASECTIONCMD:
-      break;
-#endif
-    case TCLXML_ELEMENTDECLCMD:
-      if (xmlinfo->elementDeclCommand) {
-        Tcl_SetObjResult(interp, xmlinfo->elementDeclCommand);
-      }
-      break;
-    case TCLXML_ATTLISTDECLCMD:
-      if (xmlinfo->attlistDeclCommand) {
-       Tcl_SetObjResult(interp, xmlinfo->attlistDeclCommand);
-      }
-      break;
-    case TCLXML_STARTDOCTYPEDECLCMD:
-      if (xmlinfo->startDoctypeDeclCommand) {
-       Tcl_SetObjResult(interp, xmlinfo->startDoctypeDeclCommand);
-      }
-      break;
-    case TCLXML_ENDDOCTYPEDECLCMD:
-      if (xmlinfo->endDoctypeDeclCommand) {
-        Tcl_SetObjResult(interp, xmlinfo->endDoctypeDeclCommand);
-      }
-      break;
-
-  case TCLXML_ENTITYDECLCMD:
-  case TCLXML_PARAMENTITYDECLCMD:
-  case TCLXML_DOCTYPECMD:
-  case TCLXML_ENTITYREFCMD:
-  case TCLXML_XMLDECLCMD:
-    /* These are not (yet) supported) */
-    break;
-  }
-
-  return TCL_OK;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXMLConfigureParserInstance --
- *
- *  Set an option in a parser instance.
- *
- * Results:
- *  Standard Tcl result.
- *
- * Side effects:
- *  Depends on parser class.
- *
- *----------------------------------------------------------------------------
- */
-
-static int
-TclXMLConfigureParserInstance (xmlinfo, option, value)
-     TclXML_Info *xmlinfo;
-     Tcl_Obj *option;
-     Tcl_Obj *value;
-{
-  TclXML_ParserClassInfo *classInfo = (TclXML_ParserClassInfo *) xmlinfo->parserClass;
-
-  if (classInfo->configure) {
-    if ((*classInfo->configure)(xmlinfo->clientData, option, value) != TCL_OK) {
-      return TCL_ERROR;
-    }
-  } else if (classInfo->configureCmd) {
-    Tcl_Obj *cmdPtr = Tcl_DuplicateObj(classInfo->configureCmd);
-    int result;
-
-    Tcl_IncrRefCount(cmdPtr);
-    Tcl_Preserve((ClientData) xmlinfo->interp);
-
-    /* SF Bug 514045.
-     */
-
-    if (xmlinfo->clientData) {
-      Tcl_ListObjAppendElement(NULL, cmdPtr, (Tcl_Obj *) xmlinfo->clientData);
-    } else if (xmlinfo->name) {
-      Tcl_ListObjAppendElement(NULL, cmdPtr, xmlinfo->name);
-    }
-
-    Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, option);
-    Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, value);
-
-    result = Tcl_GlobalEvalObj(xmlinfo->interp, cmdPtr);
-
-    Tcl_DecrRefCount(cmdPtr);
-    Tcl_Release((ClientData) xmlinfo->interp);
-
-    if (result != TCL_OK) {
-      return TCL_ERROR;
-    }
-  } else {
-    Tcl_SetResult(xmlinfo->interp, "no configure procedure for parser", NULL);
-    return TCL_ERROR;
-  }
-  return TCL_OK;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXMLGet --
- *
- *  Returns runtime parser information, depending on option
- *      ericm at scriptics.com, 1999.6.28
- *
- * Results:
- *  Option value.
- *
- * Side effects:
- *  None.
- *
- *----------------------------------------------------------------------------
- */
-
-static int
-TclXMLGet (interp, xmlinfo, objc, objv)
-     Tcl_Interp *interp;
-     TclXML_Info *xmlinfo;
-     int objc;
-     Tcl_Obj *CONST objv[];
-{
-  TclXML_ParserClassInfo *classInfo = (TclXML_ParserClassInfo *) xmlinfo->parserClass; 
-
-  if (classInfo->get) {
-    return (*classInfo->get)(xmlinfo->clientData, objc, objv);
-  } else if (classInfo->getCmd) {
-    Tcl_Obj *cmdPtr = Tcl_DuplicateObj(classInfo->getCmd);
-    int i, result;
-
-    Tcl_IncrRefCount(cmdPtr);
-    Tcl_Preserve((ClientData) xmlinfo->interp);
-
-    for (i = 0; i < objc; i++) {
-      Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, objv[i]);
-    }
-
-    result = Tcl_GlobalEvalObj(xmlinfo->interp, cmdPtr);
-
-    Tcl_DecrRefCount(cmdPtr);
-    Tcl_Release((ClientData) xmlinfo->interp);
-
-    return result;
-  } else {
-    Tcl_SetResult(interp, "parser has no get procedure", NULL);
-    return TCL_ERROR;
-  }
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXMLHandlerResult --
- *
- *  Manage the result of the application callback.
- *
- * Results:
- *  None.
- *
- * Side Effects:
- *  Further invocation of callback scripts may be inhibited.
- *
- *----------------------------------------------------------------------------
- */
-
-static void
-TclXMLHandlerResult(xmlinfo, result)
-     TclXML_Info *xmlinfo;
-     int result;
-{
-  switch (result) {
-    case TCL_OK:
-      xmlinfo->status = TCL_OK;
-      break;
-
-    case TCL_CONTINUE:
-      /*
-       * Skip callbacks until the matching end element event
-       * occurs for the currently open element.
-       * Keep a reference count to handle nested
-       * elements.
-       */
-      xmlinfo->status = TCL_CONTINUE;
-      xmlinfo->continueCount = 0;
-      break;
-
-    case TCL_BREAK:
-      /*
-       * Skip all further callbacks, but return OK.
-       */
-      xmlinfo->status = TCL_BREAK;
-      break;
-
-    case TCL_ERROR:
-    default:
-      /*
-       * Skip all further callbacks, and return error.
-       */
-      xmlinfo->status = TCL_ERROR;
-      xmlinfo->result = Tcl_GetObjResult(xmlinfo->interp);
-      Tcl_IncrRefCount(xmlinfo->result);
-      break;
-  }
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXML_ElementStartHandler --
- *
- *  Called by parser instance for each start tag.
- *
- * Results:
- *  None.
- *
- * Side Effects:
- *  Callback script is invoked.
- *
- *----------------------------------------------------------------------------
- */
-
-void
-TclXML_ElementStartHandler(userData, name, nsuri, atts, nsDecls)
-     void *userData;
-     Tcl_Obj *name;
-     Tcl_Obj *nsuri;
-     Tcl_Obj *atts;
-     Tcl_Obj *nsDecls;
-{
-  TclXML_Info *xmlinfo = (TclXML_Info *) userData;
-  int result = TCL_OK;
-
-  TclXMLDispatchPCDATA(xmlinfo);
-
-  if (xmlinfo->status == TCL_CONTINUE) {
-
-    /*
-     * We're currently skipping elements looking for the 
-     * close of the continued element.
-     */
-
-    xmlinfo->continueCount++;
-    return;
-  }
-
-  if ((xmlinfo->elementstartcommand == NULL && 
-       xmlinfo->elementstart == NULL) || 
-      xmlinfo->status != TCL_OK) {
-    return;
-  }
-
-  if (xmlinfo->elementstart) {
-    result = (xmlinfo->elementstart)(xmlinfo->interp, xmlinfo->elementstartdata, name, nsuri, atts, nsDecls);
-  } else if (xmlinfo->elementstartcommand) {
-    Tcl_Obj *cmdPtr;
-
-    /*
-     * Take a copy of the callback script so that arguments may be appended.
-     */
-
-    cmdPtr = Tcl_DuplicateObj(xmlinfo->elementstartcommand);
-    Tcl_IncrRefCount(cmdPtr);
-    Tcl_Preserve((ClientData) xmlinfo->interp);
-
-    Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, name);
-    Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, atts);
-    if (nsuri) {
-      Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, Tcl_NewStringObj("-namespace", -1));
-      Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, nsuri);
-    }
-    if (nsDecls) {
-      int len;
-      if ((Tcl_ListObjLength(xmlinfo->interp, nsDecls, &len) == TCL_OK) && (len > 0)) {
-	Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, Tcl_NewStringObj("-namespacedecls", -1));
-	Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, nsDecls);
-      }
-    }
-
-    /*
-     * It would be desirable to be able to terminate parsing
-     * if the return result is TCL_ERROR or TCL_BREAK.
-     */
-
-    result = Tcl_GlobalEvalObj(xmlinfo->interp, cmdPtr);
-
-    Tcl_DecrRefCount(cmdPtr);
-    Tcl_Release((ClientData) xmlinfo->interp);
-  }
-
-  TclXMLHandlerResult(xmlinfo, result);
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXML_ElementEndHandler --
- *
- *  Called by parser instance for each end tag.
- *
- * Results:
- *  None.
- *
- * Side Effects:
- *  Callback script is invoked.
- *
- *----------------------------------------------------------------------------
- */
-
-void
-TclXML_ElementEndHandler(userData, name)
-     void *userData;
-     Tcl_Obj *name;
-{
-  TclXML_Info *xmlinfo = (TclXML_Info *) userData;
-  int result = TCL_OK;;
-
-  TclXMLDispatchPCDATA(xmlinfo);
-
-  if (xmlinfo->status == TCL_CONTINUE) {
-    /*
-     * We're currently skipping elements looking for the
-     * end of the currently open element.
-     */
-
-    if (!--(xmlinfo->continueCount)) {
-      xmlinfo->status = TCL_OK;
-    } else {
-      return;
-	}
-  }
-
-  if ((xmlinfo->elementend == NULL && 
-       xmlinfo->elementendcommand == NULL) ||
-      xmlinfo->status != TCL_OK) {
-    return;
-  }
-
-  if (xmlinfo->elementend) {
-    result = (xmlinfo->elementend)(xmlinfo->interp, xmlinfo->elementenddata, name);
-  } else if (xmlinfo->elementendcommand) {
-    Tcl_Obj *cmdPtr;
-
-    /*
-     * Take a copy of the callback script so that arguments may be appended.
-     */
-
-    cmdPtr = Tcl_DuplicateObj(xmlinfo->elementendcommand);
-    Tcl_IncrRefCount(cmdPtr);
-    Tcl_Preserve((ClientData) xmlinfo->interp);
-
-    Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, name);
-
-    /*
-     * It would be desirable to be able to terminate parsing
-     * if the return result is TCL_ERROR or TCL_BREAK.
-     */
-    result = Tcl_GlobalEvalObj(xmlinfo->interp, cmdPtr);
-
-    Tcl_DecrRefCount(cmdPtr);
-    Tcl_Release((ClientData) xmlinfo->interp);
-  }
-
-  TclXMLHandlerResult(xmlinfo, result);
-
-  return;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXML_CharacterDataHandler --
- *
- *  Called by parser instance for character data.
- *
- * Results:
- *  None.
- *
- * Side Effects:
- *  Character data is accumulated in a string object
- *
- *----------------------------------------------------------------------------
- */
-
-void
-TclXML_CharacterDataHandler(userData, s)
-     void *userData;
-     Tcl_Obj *s;
-{
-  TclXML_Info *xmlinfo = (TclXML_Info *) userData;
-  if (xmlinfo->cdata == NULL) {
-    xmlinfo->cdata = s;
-    Tcl_IncrRefCount(xmlinfo->cdata);
-  } else {
-    Tcl_AppendObjToObj(xmlinfo->cdata, s);
-  }
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXMLDispatchPCDATA --
- *
- *  Called to check whether any accumulated character data
- *  exists, and if so invoke the callback.
- *
- * Results:
- *  None.
- *
- * Side Effects:
- *  Callback script evaluated.
- *
- *----------------------------------------------------------------------------
- */
-
-static void
-TclXMLDispatchPCDATA(xmlinfo)
-     TclXML_Info *xmlinfo;
-{
-  ThreadSpecificData *tsdPtr = (ThreadSpecificData *) Tcl_GetThreadData(&dataKey, sizeof(ThreadSpecificData));
-  int result = TCL_OK;
-
-  if (xmlinfo->cdata == NULL || 
-      (xmlinfo->datacommand == NULL && xmlinfo->cdatacb == NULL) ||
-      xmlinfo->status != TCL_OK) {
-    return;
-  }
-
-  /*
-   * Optionally ignore white-space-only PCDATA
-   */
-
-  if (xmlinfo->nowhitespace) {
-    if (!Tcl_RegExpMatchObj(xmlinfo->interp, xmlinfo->cdata, tsdPtr->whitespaceRE)) {
-      goto finish;
-    }
-  }
-
-  if (xmlinfo->cdatacb) {
-    result = (xmlinfo->cdatacb)(xmlinfo->interp, xmlinfo->cdatacbdata, xmlinfo->cdata);
-  } else if (xmlinfo->datacommand) {
-    Tcl_Obj *cmdPtr;
-
-    /*
-     * Take a copy of the callback script so that arguments may be appended.
-     */
-
-    cmdPtr = Tcl_DuplicateObj(xmlinfo->datacommand);
-    Tcl_IncrRefCount(cmdPtr);
-    Tcl_Preserve((ClientData) xmlinfo->interp);
-
-    if (Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, xmlinfo->cdata) != TCL_OK) {
-      xmlinfo->status = TCL_ERROR;
-      return;
-    }
-
-    /*
-     * It would be desirable to be able to terminate parsing
-     * if the return result is TCL_ERROR or TCL_BREAK.
-     */
-    result = Tcl_GlobalEvalObj(xmlinfo->interp, cmdPtr);
-
-    Tcl_DecrRefCount(cmdPtr);
-    Tcl_Release((ClientData) xmlinfo->interp);
-  }
-
-  TclXMLHandlerResult(xmlinfo, result);
-
- finish:
-  Tcl_DecrRefCount(xmlinfo->cdata);
-  xmlinfo->cdata = NULL;
-
-  return;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXML_ProcessingInstructionHandler --
- *
- *  Called by parser instance for processing instructions.
- *
- * Results:
- *  None.
- *
- * Side Effects:
- *  Callback script is invoked.
- *
- *----------------------------------------------------------------------------
- */
-
-void
-TclXML_ProcessingInstructionHandler(userData, target, data)
-     void *userData;
-     Tcl_Obj *target;
-     Tcl_Obj *data;
-{
-  TclXML_Info *xmlinfo = (TclXML_Info *) userData;
-  int result = TCL_OK;
-
-  TclXMLDispatchPCDATA(xmlinfo);
-
-  if ((xmlinfo->picommand == NULL && xmlinfo->pi == NULL) ||
-      xmlinfo->status != TCL_OK) {
-    return;
-  }
-
-  if (xmlinfo->pi) {
-    result = (xmlinfo->pi)(xmlinfo->interp, xmlinfo->pidata, target, data);
-  } else if (xmlinfo->picommand) {
-    Tcl_Obj *cmdPtr;
-
-    /*
-     * Take a copy of the callback script so that arguments may be appended.
-     */
-
-    cmdPtr = Tcl_DuplicateObj(xmlinfo->picommand);
-    Tcl_IncrRefCount(cmdPtr);
-    Tcl_Preserve((ClientData) xmlinfo->interp);
-
-    Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, target);
-    Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, data);
-
-    /*
-     * It would be desirable to be able to terminate parsing
-     * if the return result is TCL_ERROR or TCL_BREAK.
-     */
-    result = Tcl_GlobalEvalObj(xmlinfo->interp, cmdPtr);
-
-    Tcl_DecrRefCount(cmdPtr);
-    Tcl_Release((ClientData) xmlinfo->interp);
-  }
-
-  TclXMLHandlerResult(xmlinfo, result);
-
-  return;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXML_DefaultHandler --
- *
- *  Called by parser instance for processing data which has no other handler.
- *
- * Results:
- *  None.
- *
- * Side Effects:
- *  Callback script is invoked.
- *
- *----------------------------------------------------------------------------
- */
-
-void
-TclXML_DefaultHandler(userData, s)
-     void *userData;
-     Tcl_Obj *s;
-{
-  TclXML_Info *xmlinfo = (TclXML_Info *) userData;
-  int result = TCL_OK;
-
-  TclXMLDispatchPCDATA(xmlinfo);
-
-  if ((xmlinfo->defaultcommand == NULL && xmlinfo->defaultcb == NULL) ||
-      xmlinfo->status != TCL_OK) {
-    return;
-  }
-
-  if (xmlinfo->defaultcb) {
-    result = (xmlinfo->defaultcb)(xmlinfo->interp, xmlinfo->defaultdata, s);
-  } else if (xmlinfo->defaultcommand) {
-    Tcl_Obj *cmdPtr;
-
-    /*
-     * Take a copy of the callback script so that arguments may be appended.
-     */
-
-    cmdPtr = Tcl_DuplicateObj(xmlinfo->defaultcommand);
-    Tcl_IncrRefCount(cmdPtr);
-    Tcl_Preserve((ClientData) xmlinfo->interp);
-
-    Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, s);
-
-    /*
-     * It would be desirable to be able to terminate parsing
-     * if the return result is TCL_ERROR or TCL_BREAK.
-     */
-    result = Tcl_GlobalEvalObj(xmlinfo->interp, cmdPtr);
-
-    Tcl_DecrRefCount(cmdPtr);
-    Tcl_Release((ClientData) xmlinfo->interp);
-  }
-
-  TclXMLHandlerResult(xmlinfo, result);
-
-  return;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXML_UnparsedDeclHandler --
- *
- *  Called by parser instance for processing an unparsed entity references.
- *
- * Results:
- *  None.
- *
- * Side Effects:
- *  Callback script is invoked.
- *
- *----------------------------------------------------------------------------
- */
-
-void
-TclXML_UnparsedDeclHandler(userData, entityName, base, systemId, publicId, notationName)
-     void *userData;
-     Tcl_Obj *entityName;
-     Tcl_Obj *base;
-     Tcl_Obj *systemId;
-     Tcl_Obj *publicId;
-     Tcl_Obj *notationName;
-{
-  TclXML_Info *xmlinfo = (TclXML_Info *) userData;
-  int result = TCL_OK;
-
-  TclXMLDispatchPCDATA(xmlinfo);
-
-  if ((xmlinfo->unparsedcommand == NULL && xmlinfo->unparsed == NULL) ||
-      xmlinfo->status != TCL_OK) {
-    return;
-  }
-
-  if (xmlinfo->unparsed) {
-    result = (xmlinfo->unparsed)(xmlinfo->interp, xmlinfo->unparseddata, entityName, base, systemId, publicId, notationName);
-  } else if (xmlinfo->unparsedcommand) {
-    Tcl_Obj *cmdPtr;
-
-    /*
-     * Take a copy of the callback script so that arguments may be appended.
-     */
-
-    cmdPtr = Tcl_DuplicateObj(xmlinfo->unparsedcommand);
-    Tcl_IncrRefCount(cmdPtr);
-    Tcl_Preserve((ClientData) xmlinfo->interp);
-
-    Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, entityName);
-    Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, base);
-    Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, systemId);
-    if (publicId == NULL) {
-      Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, Tcl_NewObj());
-    } else {
-      Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, publicId);
-    }
-    if (notationName == NULL) {
-      Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, Tcl_NewObj());
-    } else {
-      Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, notationName);
-    }
-
-    /*
-     * It would be desirable to be able to terminate parsing
-     * if the return result is TCL_ERROR or TCL_BREAK.
-     */
-    result = Tcl_GlobalEvalObj(xmlinfo->interp, cmdPtr);
-
-    Tcl_DecrRefCount(cmdPtr);
-    Tcl_Release((ClientData) xmlinfo->interp);
-  }
-
-  TclXMLHandlerResult(xmlinfo, result);
-
-  return;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXML_NotationDeclHandler --
- *
- *  Called by parser instance for processing a notation declaration.
- *
- * Results:
- *  None.
- *
- * Side Effects:
- *  Callback script is invoked.
- *
- *----------------------------------------------------------------------------
- */
-
-void
-TclXML_NotationDeclHandler(userData, notationName, base, systemId, publicId)
-     void *userData;
-     Tcl_Obj *notationName;
-     Tcl_Obj *base;
-     Tcl_Obj *systemId;
-     Tcl_Obj *publicId;
-{
-  TclXML_Info *xmlinfo = (TclXML_Info *) userData;
-  int result = TCL_OK;
-
-  TclXMLDispatchPCDATA(xmlinfo);
-
-  if ((xmlinfo->notationcommand == NULL && xmlinfo->notation == NULL) ||
-      xmlinfo->status != TCL_OK) {
-    return;
-  }
-
-  if (xmlinfo->notation) {
-    result = (xmlinfo->notation)(xmlinfo->interp, xmlinfo->notationdata, notationName, base, systemId, publicId);
-  } else if (xmlinfo->notationcommand) {
-    Tcl_Obj *cmdPtr;
-
-    /*
-     * Take a copy of the callback script so that arguments may be appended.
-     */
-
-    cmdPtr = Tcl_DuplicateObj(xmlinfo->notationcommand);
-    Tcl_IncrRefCount(cmdPtr);
-    Tcl_Preserve((ClientData) xmlinfo->interp);
-
-    Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, notationName);
-    Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, base);
-    if (systemId == NULL) {
-      Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, Tcl_NewObj());
-    } else {
-      Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, systemId);
-    }
-    if (publicId == NULL) {
-      Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, Tcl_NewObj());
-    } else {
-      Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, publicId);
-    }
-
-    /*
-     * It would be desirable to be able to terminate parsing
-     * if the return result is TCL_ERROR or TCL_BREAK.
-     */
-    result = Tcl_GlobalEvalObj(xmlinfo->interp, cmdPtr);
-
-    Tcl_DecrRefCount(cmdPtr);
-    Tcl_Release((ClientData) xmlinfo->interp);
-  }
-
-  TclXMLHandlerResult(xmlinfo, result);
-
-  return;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXML_UnknownEncodingHandler --
- *
- *  Called by parser instance for processing a reference to a character in an 
- *  unknown encoding.
- *
- * Results:
- *  None.
- *
- * Side Effects:
- *  Callback script is invoked.
- *
- *----------------------------------------------------------------------------
- */
-
-int
-TclXML_UnknownEncodingHandler(encodingHandlerData, name, info)
-     void *encodingHandlerData;
-     Tcl_Obj *name;
-     void *info;
-{
-  TclXML_Info *xmlinfo = (TclXML_Info *) encodingHandlerData;
-  int result = TCL_OK;
-
-  TclXMLDispatchPCDATA(xmlinfo);
-
-  Tcl_SetResult(xmlinfo->interp, "not implemented", NULL);
-  return 0;
-
-  if ((xmlinfo->unknownencodingcommand == NULL && xmlinfo->unknownencoding == NULL) ||
-      xmlinfo->status != TCL_OK) {
-    return 0;
-  }
-
-  if (xmlinfo->unknownencoding) {
-    result = (xmlinfo->unknownencoding)(xmlinfo->interp, xmlinfo->unknownencodingdata, name, info);
-  } else if (xmlinfo->unknownencodingcommand) {
-    Tcl_Obj *cmdPtr;
-
-    /*
-     * Take a copy of the callback script so that arguments may be appended.
-     */
-
-    cmdPtr = Tcl_DuplicateObj(xmlinfo->unknownencodingcommand);
-    Tcl_IncrRefCount(cmdPtr);
-    Tcl_Preserve((ClientData) xmlinfo->interp);
-
-    /*
-     * Setup the arguments
-     */
-
-    /*
-     * It would be desirable to be able to terminate parsing
-     * if the return result is TCL_ERROR or TCL_BREAK.
-     */
-    result = Tcl_GlobalEvalObj(xmlinfo->interp, cmdPtr);
-
-    Tcl_DecrRefCount(cmdPtr);
-    Tcl_Release((ClientData) xmlinfo->interp);
-  }
-
-  TclXMLHandlerResult(xmlinfo, result);
-
-  return 0;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXML_ExternalEntityRefHandler --
- *
- *  Called by parser instance for processing external entity references.
- *  May also be called outside the context of a parser for XInclude
- *  or XSLT import/include.
- *
- * Results:
- *  Returns success code.
- *
- * Side Effects:
- *  Callback script is invoked.
- *
- *----------------------------------------------------------------------------
- */
-
-int
-TclXML_ExternalEntityRefHandler(userData, openEntityNames, base,
-    systemId, publicId)
-     ClientData userData;	/* NULL if not in parser context, current interp gets result */
-     Tcl_Obj *openEntityNames;
-     Tcl_Obj *base;
-     Tcl_Obj *systemId;
-     Tcl_Obj *publicId;
-{
-  ThreadSpecificData *tsdPtr = (ThreadSpecificData *) Tcl_GetThreadData(&dataKey, sizeof(ThreadSpecificData));
-  TclXML_Info *xmlinfo = (TclXML_Info *) userData;
-  int result = TCL_OK;
-  Tcl_Obj *oldContext;
-
-  if (xmlinfo != NULL) {
-    TclXMLDispatchPCDATA(xmlinfo);
-
-    if (xmlinfo->entitycommand == NULL && xmlinfo->entity == NULL) {
-      if (Tcl_IsSafe(xmlinfo->interp)) {
-	return TCL_BREAK;
-      } else {
-	return TCL_CONTINUE;
-      }
-    }
-    if (xmlinfo->status != TCL_OK) {
-      return xmlinfo->status;
-    }
-    oldContext = xmlinfo->context;
-    xmlinfo->context = openEntityNames;
-
-    if (xmlinfo->entity) {
-      result = (xmlinfo->entity)(xmlinfo->interp, xmlinfo->entitydata, xmlinfo->name, base, systemId, publicId);
-    } else if (xmlinfo->entitycommand) {
-      Tcl_Obj *cmdPtr;
-
-      /*
-       * Take a copy of the callback script so that arguments may be appended.
-       */
-
-      cmdPtr = Tcl_DuplicateObj(xmlinfo->entitycommand);
-      Tcl_IncrRefCount(cmdPtr);
-      Tcl_Preserve((ClientData) xmlinfo->interp);
-
-      Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, xmlinfo->name);
-
-      if (base) {
-	Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, base);
-      } else {
-	Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, Tcl_NewObj());
-      }
-
-      Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, systemId);
-
-      if (publicId) {
-	Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, publicId);
-      } else {
-	Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, Tcl_NewObj());
-      }
-
-      /*
-       * It would be desirable to be able to terminate parsing
-       * if the return result is TCL_ERROR or TCL_BREAK.
-       */
-      result = Tcl_GlobalEvalObj(xmlinfo->interp, cmdPtr);
-
-      Tcl_DecrRefCount(cmdPtr);
-      Tcl_Release((ClientData) xmlinfo->interp);
-    }
-
-    /*
-     * Return results have a different meaning for external entities,
-     * so don't retain the result for later use.
-     * TclXMLHandlerResult(xmlinfo, result);
-     */
-    xmlinfo->context = oldContext;
-
-  } else {
-    /*
-     * No parser context
-     */
-
-    if (tsdPtr->externalentitycmd) {
-      Tcl_Obj *cmdPtr;
-
-      /*
-       * Take a copy of the callback script so that arguments may be appended.
-       */
-
-      cmdPtr = Tcl_DuplicateObj(tsdPtr->externalentitycmd);
-      Tcl_IncrRefCount(cmdPtr);
-      Tcl_Preserve((ClientData) tsdPtr->interp);
-
-      if (base) {
-	Tcl_ListObjAppendElement(tsdPtr->interp, cmdPtr, base);
-      } else {
-	Tcl_ListObjAppendElement(tsdPtr->interp, cmdPtr, Tcl_NewObj());
-      }
-
-      Tcl_ListObjAppendElement(tsdPtr->interp, cmdPtr, systemId);
-
-      if (publicId) {
-	Tcl_ListObjAppendElement(tsdPtr->interp, cmdPtr, publicId);
-      } else {
-	Tcl_ListObjAppendElement(tsdPtr->interp, cmdPtr, Tcl_NewObj());
-      }
-
-      /*
-       * It would be desirable to be able to terminate parsing
-       * if the return result is TCL_ERROR or TCL_BREAK.
-       */
-      result = Tcl_GlobalEvalObj(tsdPtr->interp, cmdPtr);
-
-      Tcl_DecrRefCount(cmdPtr);
-      Tcl_Release((ClientData) tsdPtr->interp);
-    } else if (Tcl_IsSafe(tsdPtr->interp)) {
-      return TCL_BREAK;
-    } else {
-      return TCL_CONTINUE;
-    }
-  }
-
-  return result;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXML_CommentHandler --
- *
- *  Called by parser instance to handle comments encountered while parsing
- *      Added by ericm at scriptics.com, 1999.6.25.
- *
- * Results:
- *  None.
- *
- * Side Effects:
- *  Callback script is invoked.
- *
- *----------------------------------------------------------------------------
- */
-void
-TclXML_CommentHandler(userData, data)
-    void *userData;
-    Tcl_Obj *data;
-{
-  TclXML_Info *xmlinfo = (TclXML_Info *) userData;
-  int result = TCL_OK;
-
-  TclXMLDispatchPCDATA(xmlinfo);
-
-  if (xmlinfo->status == TCL_CONTINUE) {
-    /* Currently skipping elements, looking for the close of the
-     * continued element.  Comments don't have an end tag, so
-     * don't increment xmlinfo->continueCount
-     */
-    return;
-  }
-
-  if ((xmlinfo->commentCommand == NULL && xmlinfo->comment == NULL) ||
-      xmlinfo->status != TCL_OK) {
-    return;
-  }
-
-  if (xmlinfo->comment) {
-    result = (xmlinfo->comment)(xmlinfo->interp, xmlinfo->commentdata, data);
-  } else if (xmlinfo->commentCommand) {
-    Tcl_Obj *cmdPtr;
-
-    cmdPtr = Tcl_DuplicateObj(xmlinfo->commentCommand);
-    Tcl_IncrRefCount(cmdPtr);
-    Tcl_Preserve((ClientData) xmlinfo->interp);
-
-    Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, data);
-
-    result = Tcl_GlobalEvalObj(xmlinfo->interp, cmdPtr);
-
-    Tcl_DecrRefCount(cmdPtr);
-    Tcl_Release((ClientData) xmlinfo->interp);
-  }
-
-  TclXMLHandlerResult(xmlinfo, result);
-
-  return;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXML_NotStandaloneHandler --
- *
- *  Called by parser instance to handle "not standalone" documents (ie, documents
- *      that have an external subset or a reference to a parameter entity, 
- *      but do not have standalone="yes")
- *      Added by ericm at scriptics.com, 1999.6.25.
- *
- * Results:
- *  None.
- *
- * Side Effects:
- *  Callback script is invoked.
- *
- *----------------------------------------------------------------------------
- */
-
-int
-TclXML_NotStandaloneHandler(userData)
-    void *userData;
-{
-  TclXML_Info *xmlinfo = (TclXML_Info *) userData;
-  int result = TCL_OK;
-
-  TclXMLDispatchPCDATA(xmlinfo);
-
-  if (xmlinfo->status != TCL_OK) {
-    return 0;
-  } else if (xmlinfo->notStandaloneCommand == NULL && xmlinfo->notStandalone == NULL) {
-    return 1;
-  }
-
-  if (xmlinfo->notStandalone) {
-    result = (xmlinfo->notStandalone)(xmlinfo->interp, xmlinfo->notstandalonedata);
-  } else if (xmlinfo->notStandaloneCommand) {
-    Tcl_Obj *cmdPtr;
-
-    cmdPtr = Tcl_DuplicateObj(xmlinfo->notStandaloneCommand);
-    Tcl_IncrRefCount(cmdPtr);
-    Tcl_Preserve((ClientData) xmlinfo->interp);
-
-    result = Tcl_GlobalEvalObj(xmlinfo->interp, cmdPtr);
-
-    Tcl_DecrRefCount(cmdPtr);
-    Tcl_Release((ClientData) xmlinfo->interp);
-  }
-
-  TclXMLHandlerResult(xmlinfo, result);
-
-  return 1;
-}
-
-/*
- *----------------------------------------------------------------------
- *
- * TclXML_ElementDeclHandler --
- *
- *	Called by expat to handle <!ELEMENT declarations.
- *
- * Results:
- *	None.
- *
- * Side effects:
- *	Callback script is invoked.
- *
- *----------------------------------------------------------------------
- */
-
-void
-TclXML_ElementDeclHandler(userData, name, contentspec)
-    void *userData;
-    Tcl_Obj *name;
-    Tcl_Obj *contentspec;
-{
-  TclXML_Info *xmlinfo = (TclXML_Info *) userData;
-  int result = TCL_OK;
-
-  TclXMLDispatchPCDATA(xmlinfo);
-
-  if ((xmlinfo->elementDeclCommand == NULL && xmlinfo->elementDecl == NULL) || 
-      xmlinfo->status != TCL_OK) {
-    return;
-  }
-
-  if (xmlinfo->elementDecl) {
-    result = (xmlinfo->elementDecl)(xmlinfo->interp, xmlinfo->elementdecldata, name, contentspec);
-  } else if (xmlinfo->elementDeclCommand) {
-    Tcl_Obj *cmdPtr;
-
-    cmdPtr = Tcl_DuplicateObj(xmlinfo->elementDeclCommand);
-    Tcl_IncrRefCount(cmdPtr);
-    Tcl_Preserve((ClientData) xmlinfo->interp);
-
-    Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, name);
-  
-    Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, contentspec);
-
-    result = Tcl_GlobalEvalObj(xmlinfo->interp, cmdPtr);
-
-    Tcl_DecrRefCount(cmdPtr);
-    Tcl_Release((ClientData) xmlinfo->interp);
-  }
-
-  TclXMLHandlerResult(xmlinfo, result);
-
-  return;
-}
-
-/*
- *----------------------------------------------------------------------
- *
- * TclXML_AttlistDeclHandler --
- *
- *	Called by parser instance to handle <!ATTLIST declarations.
- *
- * Results:
- *	None.
- *
- * Side effects:
- *	Callback script is invoked.
- *
- *----------------------------------------------------------------------
- */
-
-void
-TclXML_AttlistDeclHandler(userData, name, attributes)
-    void *userData;
-    Tcl_Obj *name;
-    Tcl_Obj *attributes;
-{
-  TclXML_Info *xmlinfo = (TclXML_Info *) userData;
-  int result = TCL_OK;
-
-  TclXMLDispatchPCDATA(xmlinfo);
-
-  if ((xmlinfo->attlistDeclCommand == NULL && xmlinfo->attlistDecl == NULL) || 
-      xmlinfo->status != TCL_OK) {
-    return;
-  }
-
-  if (xmlinfo->attlistDecl) {
-    result = (xmlinfo->attlistDecl)(xmlinfo->interp, xmlinfo->attlistdecldata, name, attributes);
-  } else if (xmlinfo->attlistDeclCommand) {
-    Tcl_Obj *cmdPtr;
-
-    cmdPtr = Tcl_DuplicateObj(xmlinfo->attlistDeclCommand);
-    Tcl_IncrRefCount(cmdPtr);
-    Tcl_Preserve((ClientData) xmlinfo->interp);
-
-    Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, name);
-  
-    Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, attributes);
-
-    result = Tcl_GlobalEvalObj(xmlinfo->interp, cmdPtr);
-
-    Tcl_DecrRefCount(cmdPtr);
-    Tcl_Release((ClientData) xmlinfo->interp);
-  }
-
-  TclXMLHandlerResult(xmlinfo, result);
-
-  return;
-}
-
-/*
- *----------------------------------------------------------------------
- *
- * TclXML_StartDoctypeDeclHandler --
- *
- *	Called by parser instance to handle the start of <!DOCTYPE declarations.
- *
- * Results:
- *	None.
- *
- * Side effects:
- *	Callback script is invoked.
- *
- *----------------------------------------------------------------------
- */
-
-void
-TclXML_StartDoctypeDeclHandler(userData, name)
-    void *userData;
-    Tcl_Obj *name;
-{
-  TclXML_Info *xmlinfo = (TclXML_Info *) userData;
-  int result = TCL_OK;
-
-  TclXMLDispatchPCDATA(xmlinfo);
-
-  if ((xmlinfo->startDoctypeDeclCommand == NULL && xmlinfo->startDoctypeDecl == NULL) || 
-      xmlinfo->status != TCL_OK) {
-    return;
-  }
-
-  if (xmlinfo->startDoctypeDecl) {
-    result = (xmlinfo->startDoctypeDecl)(xmlinfo->interp, xmlinfo->startdoctypedecldata, name);
-  } else if (xmlinfo->startDoctypeDeclCommand) {
-    Tcl_Obj *cmdPtr;
-
-    cmdPtr = Tcl_DuplicateObj(xmlinfo->startDoctypeDeclCommand);
-    Tcl_IncrRefCount(cmdPtr);
-    Tcl_Preserve((ClientData) xmlinfo->interp);
-
-    Tcl_ListObjAppendElement(xmlinfo->interp, cmdPtr, name);
-  
-    result = Tcl_GlobalEvalObj(xmlinfo->interp, cmdPtr);
-
-    Tcl_DecrRefCount(cmdPtr);
-    Tcl_Release((ClientData) xmlinfo->interp);
-  }
-
-  TclXMLHandlerResult(xmlinfo, result);
-
-  return;
-}
-
-/*
- *----------------------------------------------------------------------
- *
- * TclXML_EndDoctypeDeclHandler --
- *
- *	Called by parser instance to handle the end of <!DOCTYPE declarations.
- *
- * Results:
- *	None.
- *
- * Side effects:
- *	Callback script is invoked.
- *
- *----------------------------------------------------------------------
- */
-
-void
-TclXML_EndDoctypeDeclHandler(userData)
-    void *userData;
-{
-  TclXML_Info *xmlinfo = (TclXML_Info *) userData;
-  int result = TCL_OK;
-
-  TclXMLDispatchPCDATA(xmlinfo);
-
-  if ((xmlinfo->endDoctypeDeclCommand == NULL && xmlinfo->endDoctypeDecl == NULL) || 
-      xmlinfo->status != TCL_OK) {
-    return;
-  }
-
-  if (xmlinfo->endDoctypeDecl) {
-    result = (xmlinfo->endDoctypeDecl)(xmlinfo->interp, xmlinfo->enddoctypedecldata);
-  } else if (xmlinfo->endDoctypeDeclCommand) {
-    Tcl_Obj *cmdPtr;
-
-    cmdPtr = Tcl_DuplicateObj(xmlinfo->endDoctypeDeclCommand);
-    Tcl_IncrRefCount(cmdPtr);
-    Tcl_Preserve((ClientData) xmlinfo->interp);
-
-    result = Tcl_GlobalEvalObj(xmlinfo->interp, cmdPtr);
-
-    Tcl_DecrRefCount(cmdPtr);
-    Tcl_Release((ClientData) xmlinfo->interp);
-  }
-
-  TclXMLHandlerResult(xmlinfo, result);
-
-  return;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXMLInstanceDeleteCmd --
- *
- *	Called when a parser instance is deleted.
- *
- * Results:
- *	None.
- *
- * Side Effects:
- *	Memory structures are freed.
- *
- *----------------------------------------------------------------------------
- */
-
-static void
-TclXMLInstanceDeleteCmd(clientData)
-     ClientData clientData;
-{
-  TclXML_Info *xmlinfo = (TclXML_Info *) clientData;
-
-  Tcl_DecrRefCount(xmlinfo->name);
-
-  if (xmlinfo->cdata) {
-    Tcl_DecrRefCount(xmlinfo->cdata);
-    xmlinfo->cdata = NULL;
-  }
-
-  if (xmlinfo->elementstartcommand) {
-    Tcl_DecrRefCount(xmlinfo->elementstartcommand);
-  }
-  if (xmlinfo->elementendcommand) {
-    Tcl_DecrRefCount(xmlinfo->elementendcommand);
-  }
-  if (xmlinfo->datacommand) {
-    Tcl_DecrRefCount(xmlinfo->datacommand);
-  }
-  if (xmlinfo->picommand) {
-    Tcl_DecrRefCount(xmlinfo->picommand);
-  }
-  if (xmlinfo->entitycommand) {
-    Tcl_DecrRefCount(xmlinfo->entitycommand);
-  }
-
-  if (xmlinfo->unknownencodingcommand) {
-    Tcl_DecrRefCount(xmlinfo->unknownencodingcommand);
-  }
-
-  if (xmlinfo->commentCommand) {
-    Tcl_DecrRefCount(xmlinfo->commentCommand);
-  }
-
-  if (xmlinfo->notStandaloneCommand) {
-    Tcl_DecrRefCount(xmlinfo->notStandaloneCommand);
-  }
-
-  if (xmlinfo->elementDeclCommand) {
-    Tcl_DecrRefCount(xmlinfo->elementDeclCommand);
-  }
-
-  if (xmlinfo->attlistDeclCommand) {
-    Tcl_DecrRefCount(xmlinfo->attlistDeclCommand);
-  }
-
-  if (xmlinfo->startDoctypeDeclCommand) {
-    Tcl_DecrRefCount(xmlinfo->startDoctypeDeclCommand);
-  }
-
-  if (xmlinfo->endDoctypeDeclCommand) {
-    Tcl_DecrRefCount(xmlinfo->endDoctypeDeclCommand);
-  }
-
-  TclXMLFreeParser(xmlinfo);
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXML_Register*Cmd --
- *
- *	Configures a direct callback handler.
- *
- * Results:
- *	None.
- *
- * Side Effects:
- *	Parser data structure modified.
- *
- *----------------------------------------------------------------------------
- */
-
-int
-TclXML_RegisterElementStartProc(interp, parser, clientData, callback)
-     Tcl_Interp *interp;
-     TclXML_Info *parser;
-     ClientData clientData;
-     TclXML_ElementStartProc *callback;
-{
-  parser->elementstart = callback;
-  parser->elementstartdata = clientData;
-
-  if (parser->elementstartcommand) {
-    Tcl_DecrRefCount(parser->elementstartcommand);
-    parser->elementstartcommand = NULL;
-  }
-
-  return TCL_OK;
-}
-
-int
-TclXML_RegisterElementEndProc(interp, parser, clientData, callback)
-     Tcl_Interp *interp;
-     TclXML_Info *parser;
-     ClientData clientData;
-     TclXML_ElementEndProc *callback;
-{
-  parser->elementend = callback;
-  parser->elementenddata = clientData;
-
-  if (parser->elementendcommand) {
-    Tcl_DecrRefCount(parser->elementendcommand);
-    parser->elementendcommand = NULL;
-  }
-
-  return TCL_OK;
-}
-
-int
-TclXML_RegisterCharacterDataProc(interp, parser, clientData, callback)
-     Tcl_Interp *interp;
-     TclXML_Info *parser;
-     ClientData clientData;
-     TclXML_CharacterDataProc *callback;
-{
-  parser->cdatacb = callback;
-  parser->cdatacbdata = clientData;
-
-  if (parser->datacommand) {
-    Tcl_DecrRefCount(parser->datacommand);
-    parser->datacommand = NULL;
-  }
-
-  return TCL_OK;
-}
-
-int
-TclXML_RegisterPIProc(interp, parser, clientData, callback)
-     Tcl_Interp *interp;
-     TclXML_Info *parser;
-     ClientData clientData;
-     TclXML_PIProc *callback;
-{
-  parser->pi = callback;
-  parser->pidata = clientData;
-
-  if (parser->picommand) {
-    Tcl_DecrRefCount(parser->picommand);
-    parser->picommand = NULL;
-  }
-
-  return TCL_OK;
-}
-
-int
-TclXML_RegisterDefaultProc(interp, parser, clientData, callback)
-     Tcl_Interp *interp;
-     TclXML_Info *parser;
-     ClientData clientData;
-     TclXML_DefaultProc *callback;
-{
-  parser->defaultcb = callback;
-  parser->defaultdata = clientData;
-
-  if (parser->defaultcommand) {
-    Tcl_DecrRefCount(parser->defaultcommand);
-    parser->defaultcommand = NULL;
-  }
-
-  return TCL_OK;
-}
-
-int
-TclXML_RegisterUnparsedProc(interp, parser, clientData, callback)
-     Tcl_Interp *interp;
-     TclXML_Info *parser;
-     ClientData clientData;
-     TclXML_UnparsedProc *callback;
-{
-  parser->unparsed = callback;
-  parser->unparseddata = clientData;
-
-  if (parser->unparsedcommand) {
-    Tcl_DecrRefCount(parser->unparsedcommand);
-    parser->unparsedcommand = NULL;
-  }
-
-  return TCL_OK;
-}
-
-int
-TclXML_RegisterNotationDeclProc(interp, parser, clientData, callback)
-     Tcl_Interp *interp;
-     TclXML_Info *parser;
-     ClientData clientData;
-     TclXML_NotationDeclProc *callback;
-{
-  parser->notation = callback;
-  parser->notationdata = clientData;
-
-  if (parser->notationcommand) {
-    Tcl_DecrRefCount(parser->notationcommand);
-    parser->notationcommand = NULL;
-  }
-
-  return TCL_OK;
-}
-
-int
-TclXML_RegisterEntityProc(interp, parser, clientData, callback)
-     Tcl_Interp *interp;
-     TclXML_Info *parser;
-     ClientData clientData;
-     TclXML_EntityProc *callback;
-{
-  parser->entity = callback;
-  parser->entitydata = clientData;
-
-  if (parser->entitycommand) {
-    Tcl_DecrRefCount(parser->entitycommand);
-    parser->entitycommand = NULL;
-  }
-
-  return TCL_OK;
-}
-
-int
-TclXML_RegisterUnknownEncodingProc(interp, parser, clientData, callback)
-     Tcl_Interp *interp;
-     TclXML_Info *parser;
-     ClientData clientData;
-     TclXML_UnknownEncodingProc *callback;
-{
-  parser->unknownencoding = callback;
-  parser->unknownencodingdata = clientData;
-
-  if (parser->unknownencodingcommand) {
-    Tcl_DecrRefCount(parser->unknownencodingcommand);
-    parser->unknownencodingcommand = NULL;
-  }
-
-  return TCL_OK;
-}
-
-int
-TclXML_RegisterCommentProc(interp, parser, clientData, callback)
-     Tcl_Interp *interp;
-     TclXML_Info *parser;
-     ClientData clientData;
-     TclXML_CommentProc *callback;
-{
-  parser->comment = callback;
-  parser->commentdata = clientData;
-
-  if (parser->commentCommand) {
-    Tcl_DecrRefCount(parser->commentCommand);
-    parser->commentCommand = NULL;
-  }
-
-  return TCL_OK;
-}
-
-int
-TclXML_RegisterNotStandaloneProc(interp, parser, clientData, callback)
-     Tcl_Interp *interp;
-     TclXML_Info *parser;
-     ClientData clientData;
-     TclXML_NotStandaloneProc *callback;
-{
-  parser->notStandalone = callback;
-  parser->notstandalonedata = clientData;
-
-  if (parser->notStandaloneCommand) {
-    Tcl_DecrRefCount(parser->notStandaloneCommand);
-    parser->notStandaloneCommand = NULL;
-  }
-
-  return TCL_OK;
-}
-
-int
-TclXML_RegisterElementDeclProc(interp, parser, clientData, callback)
-     Tcl_Interp *interp;
-     TclXML_Info *parser;
-     ClientData clientData;
-     TclXML_ElementDeclProc *callback;
-{
-  parser->elementDecl = callback;
-  parser->elementdecldata = clientData;
-
-  if (parser->elementDeclCommand) {
-    Tcl_DecrRefCount(parser->elementDeclCommand);
-    parser->elementDeclCommand = NULL;
-  }
-
-  return TCL_OK;
-}
-
-int
-TclXML_RegisterAttListDeclProc(interp, parser, clientData, callback)
-     Tcl_Interp *interp;
-     TclXML_Info *parser;
-     ClientData clientData;
-     TclXML_AttlistDeclProc *callback;
-{
-  parser->attlistDecl = callback;
-  parser->attlistdecldata = clientData;
-
-  if (parser->attlistDeclCommand) {
-    Tcl_DecrRefCount(parser->attlistDeclCommand);
-    parser->attlistDeclCommand = NULL;
-  }
-
-  return TCL_OK;
-}
-
-int
-TclXML_RegisterStartDoctypeDeclProc(interp, parser, clientData, callback)
-     Tcl_Interp *interp;
-     TclXML_Info *parser;
-     ClientData clientData;
-     TclXML_StartDoctypeDeclProc *callback;
-{
-  parser->startDoctypeDecl = callback;
-  parser->startdoctypedecldata = clientData;
-
-  if (parser->startDoctypeDeclCommand) {
-    Tcl_DecrRefCount(parser->startDoctypeDeclCommand);
-    parser->startDoctypeDeclCommand = NULL;
-  }
-
-  return TCL_OK;
-}
-
-int
-TclXML_RegisterEndDoctypeDeclProc(interp, parser, clientData, callback)
-     Tcl_Interp *interp;
-     TclXML_Info *parser;
-     ClientData clientData;
-     TclXML_EndDoctypeDeclProc *callback;
-{
-  parser->endDoctypeDecl = callback;
-  parser->enddoctypedecldata = clientData;
-
-  if (parser->endDoctypeDeclCommand) {
-    Tcl_DecrRefCount(parser->endDoctypeDeclCommand);
-    parser->endDoctypeDeclCommand = NULL;
-  }
-
-  return TCL_OK;
-}
diff --git a/tclxml-3.2/tclxml.decls b/tclxml-3.2/tclxml.decls
deleted file mode 100644
index 72fd483..0000000
--- a/tclxml-3.2/tclxml.decls
+++ /dev/null
@@ -1,187 +0,0 @@
-# tclxml.decls --
-#
-# This file contains the declarations for all supported public functions
-# that are exported by the TCLXML library via the stubs table. This file
-# is used to generate the tclxmlDecls.h/tclxmlStubsLib.c/tclxmlStubsInit.c
-# files.
-#	
-
-# Declare each of the functions in the public TclXML interface.  Note that
-# the an index should never be reused for a different function in order
-# to preserve backwards compatibility.
-
-library tclxml
-
-# Define the TCLXML interface:
-
-interface tclxml
-#hooks {}
-
-declare 0 generic {
-    int Tclxml_Init(Tcl_Interp *interp)
-}
-declare 1 generic {
-    int Tclxml_SafeInit(Tcl_Interp *interp)
-}
-
-#########################################################################
-###  Parser registration API
-
-declare 2 generic {
-    int TclXML_RegisterXMLParser (Tcl_Interp *interp, \
-	TclXML_ParserClassInfo *parser)
-}
-
-#########################################################################
-###  Application callback C API.
-###  These are equivalent to the Tcl API, and may be used in conjunction.
-
-declare 3 generic {
-    int TclXML_RegisterElementStartProc (Tcl_Interp *interp, \
-	TclXML_Info *parser, ClientData clientData, \
-	TclXML_ElementStartProc *callback)
-}
-declare 4 generic {
-    int TclXML_RegisterElementEndProc (Tcl_Interp *interp, \
-	TclXML_Info *parser, ClientData clientData, \
-	TclXML_ElementEndProc *callback)
-}
-declare 5 generic {
-    int TclXML_RegisterCharacterDataProc (Tcl_Interp *interp, \
-	TclXML_Info *parser, ClientData clientData, \
-	TclXML_CharacterDataProc *callback)
-}
-declare 6 generic {
-    int TclXML_RegisterPIProc (Tcl_Interp *interp, TclXML_Info *parser, \
-	ClientData clientData, TclXML_PIProc *callback)
-}
-declare 7 generic {
-    int TclXML_RegisterDefaultProc (Tcl_Interp *interp, \
-	TclXML_Info *parser, ClientData clientData, \
-	TclXML_DefaultProc *callback)
-}
-declare 8 generic {
-    int TclXML_RegisterUnparsedProc (Tcl_Interp *interp, \
-	TclXML_Info *parser, ClientData clientData, \
-	TclXML_UnparsedProc *callback)
-}
-declare 9 generic {
-    int TclXML_RegisterNotationDeclProc (Tcl_Interp *interp, \
-	TclXML_Info *parser, ClientData clientData, \
-	TclXML_NotationDeclProc *callback)
-}
-declare 10 generic {
-    int TclXML_RegisterEntityProc (Tcl_Interp *interp, TclXML_Info *parser, \
-	ClientData clientData, TclXML_EntityProc *callback)
-}
-declare 11 generic {
-    int TclXML_RegisterUnknownEncodingProc (Tcl_Interp *interp, \
-	TclXML_Info *parser, ClientData clientData, \
-	TclXML_UnknownEncodingProc *callback)
-}
-declare 12 generic {
-    int TclXML_RegisterCommentProc (Tcl_Interp *interp, TclXML_Info *parser, \
-	ClientData clientData, TclXML_CommentProc *callback)
-}
-declare 13 generic {
-    int TclXML_RegisterNotStandaloneProc (Tcl_Interp *interp, \
-	TclXML_Info *parser, ClientData clientData, \
-	TclXML_NotStandaloneProc *callback)
-}
-declare 14 generic {
-    int TclXML_RegisterElementDeclProc (Tcl_Interp *interp, \
-	TclXML_Info *parser, ClientData clientData, \
-	TclXML_ElementDeclProc *callback)
-}
-declare 15 generic {
-    int TclXML_RegisterAttListDeclProc (Tcl_Interp *interp, \
-	TclXML_Info *parser, ClientData clientData, \
-	TclXML_AttlistDeclProc *callback)
-}
-declare 16 generic {
-    int TclXML_RegisterStartDoctypeDeclProc (Tcl_Interp *interp, \
-	TclXML_Info *parser, ClientData clientData, \
-	TclXML_StartDoctypeDeclProc *callback)
-}
-declare 17 generic {
-    int TclXML_RegisterEndDoctypeDeclProc (Tcl_Interp *interp, \
-	TclXML_Info *parser, ClientData clientData, \
-	TclXML_EndDoctypeDeclProc *callback)
-}
-
-#########################################################################
-###  Call-ins for parser class implementations.
-###  A parser implementation calls these functions.
-###  The generic layer then invokes application callbacks
-###  that may be defined.
-
-declare 18 generic {
-    void TclXML_ElementStartHandler (void *userdata, Tcl_Obj *name, \
-	Tcl_Obj *nsuri, \
-	Tcl_Obj *atts, Tcl_Obj *nsDeclsObj)
-}
-declare 19 generic {
-    void TclXML_ElementEndHandler (void	*userData, Tcl_Obj *name)
-}
-declare 20 generic {
-    void TclXML_CharacterDataHandler (void *userData, Tcl_Obj *s)
-}
-declare 21 generic {
-    void TclXML_ProcessingInstructionHandler (void *userData, \
-	Tcl_Obj *target, Tcl_Obj *data)
-}
-declare 22 generic {
-    int TclXML_ExternalEntityRefHandler (ClientData clientData, \
-	Tcl_Obj *openEntityNames, Tcl_Obj *base, Tcl_Obj *systemId, \
-	Tcl_Obj *publicId)
-}
-declare 23 generic {
-    void TclXML_DefaultHandler (void *userData, Tcl_Obj *s)
-}
-declare 24 generic {
-    void TclXML_UnparsedDeclHandler (void *userData, Tcl_Obj *entityname, \
-	Tcl_Obj *base, Tcl_Obj *systemId, Tcl_Obj *publicId, \
-	Tcl_Obj *notationName)
-}
-declare 25 generic {
-    void TclXML_NotationDeclHandler (void *userData, Tcl_Obj *notationName, \
-	Tcl_Obj *base, Tcl_Obj *systemId, Tcl_Obj *publicId)
-}
-declare 26 generic {
-    int TclXML_UnknownEncodingHandler (void *encodingHandlerData, \
-	Tcl_Obj *name, void *info)
-}
-
-#########################################################################
-###  Following added by ericm at scriptics, 1999.6.25
-
-###  Prototype definition for the comment handler
-declare 27 generic {
-    void TclXML_CommentHandler (void *userData, Tcl_Obj *data)
-}
-
-###  Prototype for Not Standalone Handler
-declare 28 generic {
-    int	TclXML_NotStandaloneHandler (void *userData)
-}
-
-#########################################################################
-###  Added by ericm at scriptics.com, 1999.09.13
-
-###  Prototype for (Element|Attlist) Declaration Handlers
-declare 31 generic {
-    void TclXML_ElementDeclHandler (void *userData, Tcl_Obj *name, \
-	Tcl_Obj *contentspec)
-}
-declare 32 generic {
-    void TclXML_AttlistDeclHandler (void *userData, Tcl_Obj *name, \
-	Tcl_Obj *attributes)
-}
-
-###  Prototypes for the Doctype Decl handlers
-declare 33 generic {
-    void TclXML_StartDoctypeDeclHandler (void *userData, Tcl_Obj *name)
-}
-declare 34 generic {
-    void TclXML_EndDoctypeDeclHandler (void *userData)
-}
diff --git a/tclxml-3.2/tclxmlDecls.h b/tclxml-3.2/tclxmlDecls.h
deleted file mode 100644
index 9576479..0000000
--- a/tclxml-3.2/tclxmlDecls.h
+++ /dev/null
@@ -1,361 +0,0 @@
-/*
- * tclxmlDecls.h --
- *
- *	Declarations of functions in the platform independent public TCLXML API.
- *
- */
-
-#ifndef _TCLXMLDECLS
-#define _TCLXMLDECLS
-
-/*
- * WARNING: The contents of this file is automatically generated by the
- * genStubs.tcl script. Any modifications to the function declarations
- * below should be made in the tclxml.decls script.
- */
-
-/* !BEGIN!: Do not edit below this line. */
-
-/*
- * Exported function declarations:
- */
-
-/* 0 */
-EXTERN int		Tclxml_Init _ANSI_ARGS_((Tcl_Interp * interp));
-/* 1 */
-EXTERN int		Tclxml_SafeInit _ANSI_ARGS_((Tcl_Interp * interp));
-/* 2 */
-EXTERN int		TclXML_RegisterXMLParser _ANSI_ARGS_((
-				Tcl_Interp * interp, 
-				TclXML_ParserClassInfo * parser));
-/* 3 */
-EXTERN int		TclXML_RegisterElementStartProc _ANSI_ARGS_((
-				Tcl_Interp * interp, TclXML_Info * parser, 
-				ClientData clientData, 
-				TclXML_ElementStartProc * callback));
-/* 4 */
-EXTERN int		TclXML_RegisterElementEndProc _ANSI_ARGS_((
-				Tcl_Interp * interp, TclXML_Info * parser, 
-				ClientData clientData, 
-				TclXML_ElementEndProc * callback));
-/* 5 */
-EXTERN int		TclXML_RegisterCharacterDataProc _ANSI_ARGS_((
-				Tcl_Interp * interp, TclXML_Info * parser, 
-				ClientData clientData, 
-				TclXML_CharacterDataProc * callback));
-/* 6 */
-EXTERN int		TclXML_RegisterPIProc _ANSI_ARGS_((
-				Tcl_Interp * interp, TclXML_Info * parser, 
-				ClientData clientData, 
-				TclXML_PIProc * callback));
-/* 7 */
-EXTERN int		TclXML_RegisterDefaultProc _ANSI_ARGS_((
-				Tcl_Interp * interp, TclXML_Info * parser, 
-				ClientData clientData, 
-				TclXML_DefaultProc * callback));
-/* 8 */
-EXTERN int		TclXML_RegisterUnparsedProc _ANSI_ARGS_((
-				Tcl_Interp * interp, TclXML_Info * parser, 
-				ClientData clientData, 
-				TclXML_UnparsedProc * callback));
-/* 9 */
-EXTERN int		TclXML_RegisterNotationDeclProc _ANSI_ARGS_((
-				Tcl_Interp * interp, TclXML_Info * parser, 
-				ClientData clientData, 
-				TclXML_NotationDeclProc * callback));
-/* 10 */
-EXTERN int		TclXML_RegisterEntityProc _ANSI_ARGS_((
-				Tcl_Interp * interp, TclXML_Info * parser, 
-				ClientData clientData, 
-				TclXML_EntityProc * callback));
-/* 11 */
-EXTERN int		TclXML_RegisterUnknownEncodingProc _ANSI_ARGS_((
-				Tcl_Interp * interp, TclXML_Info * parser, 
-				ClientData clientData, 
-				TclXML_UnknownEncodingProc * callback));
-/* 12 */
-EXTERN int		TclXML_RegisterCommentProc _ANSI_ARGS_((
-				Tcl_Interp * interp, TclXML_Info * parser, 
-				ClientData clientData, 
-				TclXML_CommentProc * callback));
-/* 13 */
-EXTERN int		TclXML_RegisterNotStandaloneProc _ANSI_ARGS_((
-				Tcl_Interp * interp, TclXML_Info * parser, 
-				ClientData clientData, 
-				TclXML_NotStandaloneProc * callback));
-/* 14 */
-EXTERN int		TclXML_RegisterElementDeclProc _ANSI_ARGS_((
-				Tcl_Interp * interp, TclXML_Info * parser, 
-				ClientData clientData, 
-				TclXML_ElementDeclProc * callback));
-/* 15 */
-EXTERN int		TclXML_RegisterAttListDeclProc _ANSI_ARGS_((
-				Tcl_Interp * interp, TclXML_Info * parser, 
-				ClientData clientData, 
-				TclXML_AttlistDeclProc * callback));
-/* 16 */
-EXTERN int		TclXML_RegisterStartDoctypeDeclProc _ANSI_ARGS_((
-				Tcl_Interp * interp, TclXML_Info * parser, 
-				ClientData clientData, 
-				TclXML_StartDoctypeDeclProc * callback));
-/* 17 */
-EXTERN int		TclXML_RegisterEndDoctypeDeclProc _ANSI_ARGS_((
-				Tcl_Interp * interp, TclXML_Info * parser, 
-				ClientData clientData, 
-				TclXML_EndDoctypeDeclProc * callback));
-/* 18 */
-EXTERN void		TclXML_ElementStartHandler _ANSI_ARGS_((
-				void * userdata, Tcl_Obj * name, 
-				Tcl_Obj * nsuri, Tcl_Obj * atts, 
-				Tcl_Obj * nsDeclsObj));
-/* 19 */
-EXTERN void		TclXML_ElementEndHandler _ANSI_ARGS_((
-				void * userData, Tcl_Obj * name));
-/* 20 */
-EXTERN void		TclXML_CharacterDataHandler _ANSI_ARGS_((
-				void * userData, Tcl_Obj * s));
-/* 21 */
-EXTERN void		TclXML_ProcessingInstructionHandler _ANSI_ARGS_((
-				void * userData, Tcl_Obj * target, 
-				Tcl_Obj * data));
-/* 22 */
-EXTERN int		TclXML_ExternalEntityRefHandler _ANSI_ARGS_((
-				ClientData clientData, 
-				Tcl_Obj * openEntityNames, Tcl_Obj * base, 
-				Tcl_Obj * systemId, Tcl_Obj * publicId));
-/* 23 */
-EXTERN void		TclXML_DefaultHandler _ANSI_ARGS_((void * userData, 
-				Tcl_Obj * s));
-/* 24 */
-EXTERN void		TclXML_UnparsedDeclHandler _ANSI_ARGS_((
-				void * userData, Tcl_Obj * entityname, 
-				Tcl_Obj * base, Tcl_Obj * systemId, 
-				Tcl_Obj * publicId, Tcl_Obj * notationName));
-/* 25 */
-EXTERN void		TclXML_NotationDeclHandler _ANSI_ARGS_((
-				void * userData, Tcl_Obj * notationName, 
-				Tcl_Obj * base, Tcl_Obj * systemId, 
-				Tcl_Obj * publicId));
-/* 26 */
-EXTERN int		TclXML_UnknownEncodingHandler _ANSI_ARGS_((
-				void * encodingHandlerData, Tcl_Obj * name, 
-				void * info));
-/* 27 */
-EXTERN void		TclXML_CommentHandler _ANSI_ARGS_((void * userData, 
-				Tcl_Obj * data));
-/* 28 */
-EXTERN int		TclXML_NotStandaloneHandler _ANSI_ARGS_((
-				void * userData));
-/* Slot 29 is reserved */
-/* Slot 30 is reserved */
-/* 31 */
-EXTERN void		TclXML_ElementDeclHandler _ANSI_ARGS_((
-				void * userData, Tcl_Obj * name, 
-				Tcl_Obj * contentspec));
-/* 32 */
-EXTERN void		TclXML_AttlistDeclHandler _ANSI_ARGS_((
-				void * userData, Tcl_Obj * name, 
-				Tcl_Obj * attributes));
-/* 33 */
-EXTERN void		TclXML_StartDoctypeDeclHandler _ANSI_ARGS_((
-				void * userData, Tcl_Obj * name));
-/* 34 */
-EXTERN void		TclXML_EndDoctypeDeclHandler _ANSI_ARGS_((
-				void * userData));
-
-typedef struct TclxmlStubs {
-    int magic;
-    struct TclxmlStubHooks *hooks;
-
-    int (*tclxml_Init) _ANSI_ARGS_((Tcl_Interp * interp)); /* 0 */
-    int (*tclxml_SafeInit) _ANSI_ARGS_((Tcl_Interp * interp)); /* 1 */
-    int (*tclXML_RegisterXMLParser) _ANSI_ARGS_((Tcl_Interp * interp, TclXML_ParserClassInfo * parser)); /* 2 */
-    int (*tclXML_RegisterElementStartProc) _ANSI_ARGS_((Tcl_Interp * interp, TclXML_Info * parser, ClientData clientData, TclXML_ElementStartProc * callback)); /* 3 */
-    int (*tclXML_RegisterElementEndProc) _ANSI_ARGS_((Tcl_Interp * interp, TclXML_Info * parser, ClientData clientData, TclXML_ElementEndProc * callback)); /* 4 */
-    int (*tclXML_RegisterCharacterDataProc) _ANSI_ARGS_((Tcl_Interp * interp, TclXML_Info * parser, ClientData clientData, TclXML_CharacterDataProc * callback)); /* 5 */
-    int (*tclXML_RegisterPIProc) _ANSI_ARGS_((Tcl_Interp * interp, TclXML_Info * parser, ClientData clientData, TclXML_PIProc * callback)); /* 6 */
-    int (*tclXML_RegisterDefaultProc) _ANSI_ARGS_((Tcl_Interp * interp, TclXML_Info * parser, ClientData clientData, TclXML_DefaultProc * callback)); /* 7 */
-    int (*tclXML_RegisterUnparsedProc) _ANSI_ARGS_((Tcl_Interp * interp, TclXML_Info * parser, ClientData clientData, TclXML_UnparsedProc * callback)); /* 8 */
-    int (*tclXML_RegisterNotationDeclProc) _ANSI_ARGS_((Tcl_Interp * interp, TclXML_Info * parser, ClientData clientData, TclXML_NotationDeclProc * callback)); /* 9 */
-    int (*tclXML_RegisterEntityProc) _ANSI_ARGS_((Tcl_Interp * interp, TclXML_Info * parser, ClientData clientData, TclXML_EntityProc * callback)); /* 10 */
-    int (*tclXML_RegisterUnknownEncodingProc) _ANSI_ARGS_((Tcl_Interp * interp, TclXML_Info * parser, ClientData clientData, TclXML_UnknownEncodingProc * callback)); /* 11 */
-    int (*tclXML_RegisterCommentProc) _ANSI_ARGS_((Tcl_Interp * interp, TclXML_Info * parser, ClientData clientData, TclXML_CommentProc * callback)); /* 12 */
-    int (*tclXML_RegisterNotStandaloneProc) _ANSI_ARGS_((Tcl_Interp * interp, TclXML_Info * parser, ClientData clientData, TclXML_NotStandaloneProc * callback)); /* 13 */
-    int (*tclXML_RegisterElementDeclProc) _ANSI_ARGS_((Tcl_Interp * interp, TclXML_Info * parser, ClientData clientData, TclXML_ElementDeclProc * callback)); /* 14 */
-    int (*tclXML_RegisterAttListDeclProc) _ANSI_ARGS_((Tcl_Interp * interp, TclXML_Info * parser, ClientData clientData, TclXML_AttlistDeclProc * callback)); /* 15 */
-    int (*tclXML_RegisterStartDoctypeDeclProc) _ANSI_ARGS_((Tcl_Interp * interp, TclXML_Info * parser, ClientData clientData, TclXML_StartDoctypeDeclProc * callback)); /* 16 */
-    int (*tclXML_RegisterEndDoctypeDeclProc) _ANSI_ARGS_((Tcl_Interp * interp, TclXML_Info * parser, ClientData clientData, TclXML_EndDoctypeDeclProc * callback)); /* 17 */
-    void (*tclXML_ElementStartHandler) _ANSI_ARGS_((void * userdata, Tcl_Obj * name, Tcl_Obj * nsuri, Tcl_Obj * atts, Tcl_Obj * nsDeclsObj)); /* 18 */
-    void (*tclXML_ElementEndHandler) _ANSI_ARGS_((void * userData, Tcl_Obj * name)); /* 19 */
-    void (*tclXML_CharacterDataHandler) _ANSI_ARGS_((void * userData, Tcl_Obj * s)); /* 20 */
-    void (*tclXML_ProcessingInstructionHandler) _ANSI_ARGS_((void * userData, Tcl_Obj * target, Tcl_Obj * data)); /* 21 */
-    int (*tclXML_ExternalEntityRefHandler) _ANSI_ARGS_((ClientData clientData, Tcl_Obj * openEntityNames, Tcl_Obj * base, Tcl_Obj * systemId, Tcl_Obj * publicId)); /* 22 */
-    void (*tclXML_DefaultHandler) _ANSI_ARGS_((void * userData, Tcl_Obj * s)); /* 23 */
-    void (*tclXML_UnparsedDeclHandler) _ANSI_ARGS_((void * userData, Tcl_Obj * entityname, Tcl_Obj * base, Tcl_Obj * systemId, Tcl_Obj * publicId, Tcl_Obj * notationName)); /* 24 */
-    void (*tclXML_NotationDeclHandler) _ANSI_ARGS_((void * userData, Tcl_Obj * notationName, Tcl_Obj * base, Tcl_Obj * systemId, Tcl_Obj * publicId)); /* 25 */
-    int (*tclXML_UnknownEncodingHandler) _ANSI_ARGS_((void * encodingHandlerData, Tcl_Obj * name, void * info)); /* 26 */
-    void (*tclXML_CommentHandler) _ANSI_ARGS_((void * userData, Tcl_Obj * data)); /* 27 */
-    int (*tclXML_NotStandaloneHandler) _ANSI_ARGS_((void * userData)); /* 28 */
-    void *reserved29;
-    void *reserved30;
-    void (*tclXML_ElementDeclHandler) _ANSI_ARGS_((void * userData, Tcl_Obj * name, Tcl_Obj * contentspec)); /* 31 */
-    void (*tclXML_AttlistDeclHandler) _ANSI_ARGS_((void * userData, Tcl_Obj * name, Tcl_Obj * attributes)); /* 32 */
-    void (*tclXML_StartDoctypeDeclHandler) _ANSI_ARGS_((void * userData, Tcl_Obj * name)); /* 33 */
-    void (*tclXML_EndDoctypeDeclHandler) _ANSI_ARGS_((void * userData)); /* 34 */
-} TclxmlStubs;
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-extern TclxmlStubs *tclxmlStubsPtr;
-#ifdef __cplusplus
-}
-#endif
-
-#if defined(USE_TCLXML_STUBS) && !defined(USE_TCLXML_STUB_PROCS)
-
-/*
- * Inline function declarations:
- */
-
-#ifndef Tclxml_Init
-#define Tclxml_Init \
-	(tclxmlStubsPtr->tclxml_Init) /* 0 */
-#endif
-#ifndef Tclxml_SafeInit
-#define Tclxml_SafeInit \
-	(tclxmlStubsPtr->tclxml_SafeInit) /* 1 */
-#endif
-#ifndef TclXML_RegisterXMLParser
-#define TclXML_RegisterXMLParser \
-	(tclxmlStubsPtr->tclXML_RegisterXMLParser) /* 2 */
-#endif
-#ifndef TclXML_RegisterElementStartProc
-#define TclXML_RegisterElementStartProc \
-	(tclxmlStubsPtr->tclXML_RegisterElementStartProc) /* 3 */
-#endif
-#ifndef TclXML_RegisterElementEndProc
-#define TclXML_RegisterElementEndProc \
-	(tclxmlStubsPtr->tclXML_RegisterElementEndProc) /* 4 */
-#endif
-#ifndef TclXML_RegisterCharacterDataProc
-#define TclXML_RegisterCharacterDataProc \
-	(tclxmlStubsPtr->tclXML_RegisterCharacterDataProc) /* 5 */
-#endif
-#ifndef TclXML_RegisterPIProc
-#define TclXML_RegisterPIProc \
-	(tclxmlStubsPtr->tclXML_RegisterPIProc) /* 6 */
-#endif
-#ifndef TclXML_RegisterDefaultProc
-#define TclXML_RegisterDefaultProc \
-	(tclxmlStubsPtr->tclXML_RegisterDefaultProc) /* 7 */
-#endif
-#ifndef TclXML_RegisterUnparsedProc
-#define TclXML_RegisterUnparsedProc \
-	(tclxmlStubsPtr->tclXML_RegisterUnparsedProc) /* 8 */
-#endif
-#ifndef TclXML_RegisterNotationDeclProc
-#define TclXML_RegisterNotationDeclProc \
-	(tclxmlStubsPtr->tclXML_RegisterNotationDeclProc) /* 9 */
-#endif
-#ifndef TclXML_RegisterEntityProc
-#define TclXML_RegisterEntityProc \
-	(tclxmlStubsPtr->tclXML_RegisterEntityProc) /* 10 */
-#endif
-#ifndef TclXML_RegisterUnknownEncodingProc
-#define TclXML_RegisterUnknownEncodingProc \
-	(tclxmlStubsPtr->tclXML_RegisterUnknownEncodingProc) /* 11 */
-#endif
-#ifndef TclXML_RegisterCommentProc
-#define TclXML_RegisterCommentProc \
-	(tclxmlStubsPtr->tclXML_RegisterCommentProc) /* 12 */
-#endif
-#ifndef TclXML_RegisterNotStandaloneProc
-#define TclXML_RegisterNotStandaloneProc \
-	(tclxmlStubsPtr->tclXML_RegisterNotStandaloneProc) /* 13 */
-#endif
-#ifndef TclXML_RegisterElementDeclProc
-#define TclXML_RegisterElementDeclProc \
-	(tclxmlStubsPtr->tclXML_RegisterElementDeclProc) /* 14 */
-#endif
-#ifndef TclXML_RegisterAttListDeclProc
-#define TclXML_RegisterAttListDeclProc \
-	(tclxmlStubsPtr->tclXML_RegisterAttListDeclProc) /* 15 */
-#endif
-#ifndef TclXML_RegisterStartDoctypeDeclProc
-#define TclXML_RegisterStartDoctypeDeclProc \
-	(tclxmlStubsPtr->tclXML_RegisterStartDoctypeDeclProc) /* 16 */
-#endif
-#ifndef TclXML_RegisterEndDoctypeDeclProc
-#define TclXML_RegisterEndDoctypeDeclProc \
-	(tclxmlStubsPtr->tclXML_RegisterEndDoctypeDeclProc) /* 17 */
-#endif
-#ifndef TclXML_ElementStartHandler
-#define TclXML_ElementStartHandler \
-	(tclxmlStubsPtr->tclXML_ElementStartHandler) /* 18 */
-#endif
-#ifndef TclXML_ElementEndHandler
-#define TclXML_ElementEndHandler \
-	(tclxmlStubsPtr->tclXML_ElementEndHandler) /* 19 */
-#endif
-#ifndef TclXML_CharacterDataHandler
-#define TclXML_CharacterDataHandler \
-	(tclxmlStubsPtr->tclXML_CharacterDataHandler) /* 20 */
-#endif
-#ifndef TclXML_ProcessingInstructionHandler
-#define TclXML_ProcessingInstructionHandler \
-	(tclxmlStubsPtr->tclXML_ProcessingInstructionHandler) /* 21 */
-#endif
-#ifndef TclXML_ExternalEntityRefHandler
-#define TclXML_ExternalEntityRefHandler \
-	(tclxmlStubsPtr->tclXML_ExternalEntityRefHandler) /* 22 */
-#endif
-#ifndef TclXML_DefaultHandler
-#define TclXML_DefaultHandler \
-	(tclxmlStubsPtr->tclXML_DefaultHandler) /* 23 */
-#endif
-#ifndef TclXML_UnparsedDeclHandler
-#define TclXML_UnparsedDeclHandler \
-	(tclxmlStubsPtr->tclXML_UnparsedDeclHandler) /* 24 */
-#endif
-#ifndef TclXML_NotationDeclHandler
-#define TclXML_NotationDeclHandler \
-	(tclxmlStubsPtr->tclXML_NotationDeclHandler) /* 25 */
-#endif
-#ifndef TclXML_UnknownEncodingHandler
-#define TclXML_UnknownEncodingHandler \
-	(tclxmlStubsPtr->tclXML_UnknownEncodingHandler) /* 26 */
-#endif
-#ifndef TclXML_CommentHandler
-#define TclXML_CommentHandler \
-	(tclxmlStubsPtr->tclXML_CommentHandler) /* 27 */
-#endif
-#ifndef TclXML_NotStandaloneHandler
-#define TclXML_NotStandaloneHandler \
-	(tclxmlStubsPtr->tclXML_NotStandaloneHandler) /* 28 */
-#endif
-/* Slot 29 is reserved */
-/* Slot 30 is reserved */
-#ifndef TclXML_ElementDeclHandler
-#define TclXML_ElementDeclHandler \
-	(tclxmlStubsPtr->tclXML_ElementDeclHandler) /* 31 */
-#endif
-#ifndef TclXML_AttlistDeclHandler
-#define TclXML_AttlistDeclHandler \
-	(tclxmlStubsPtr->tclXML_AttlistDeclHandler) /* 32 */
-#endif
-#ifndef TclXML_StartDoctypeDeclHandler
-#define TclXML_StartDoctypeDeclHandler \
-	(tclxmlStubsPtr->tclXML_StartDoctypeDeclHandler) /* 33 */
-#endif
-#ifndef TclXML_EndDoctypeDeclHandler
-#define TclXML_EndDoctypeDeclHandler \
-	(tclxmlStubsPtr->tclXML_EndDoctypeDeclHandler) /* 34 */
-#endif
-
-#endif /* defined(USE_TCLXML_STUBS) && !defined(USE_TCLXML_STUB_PROCS) */
-
-/* !END!: Do not edit above this line. */
-
-#endif /* _TCLXMLDECLS */
-
diff --git a/tclxml-3.2/tclxmlStubInit.c b/tclxml-3.2/tclxmlStubInit.c
deleted file mode 100644
index 2c6db27..0000000
--- a/tclxml-3.2/tclxmlStubInit.c
+++ /dev/null
@@ -1,60 +0,0 @@
-/* 
- * tclxmlStubInit.c --
- */
-
-#include <tclxml/tclxml.h>
-
-/*
- * Remove macros that will interfere with the definitions below.
- */
-
-
-/*
- * WARNING: The contents of this file is automatically generated by the
- * genStubs.tcl script. Any modifications to the function declarations
- * below should be made in the tclxml.decls script.
- */
-
-/* !BEGIN!: Do not edit below this line. */
-
-TclxmlStubs tclxmlStubs = {
-    TCL_STUB_MAGIC,
-    NULL,
-    Tclxml_Init, /* 0 */
-    Tclxml_SafeInit, /* 1 */
-    TclXML_RegisterXMLParser, /* 2 */
-    TclXML_RegisterElementStartProc, /* 3 */
-    TclXML_RegisterElementEndProc, /* 4 */
-    TclXML_RegisterCharacterDataProc, /* 5 */
-    TclXML_RegisterPIProc, /* 6 */
-    TclXML_RegisterDefaultProc, /* 7 */
-    TclXML_RegisterUnparsedProc, /* 8 */
-    TclXML_RegisterNotationDeclProc, /* 9 */
-    TclXML_RegisterEntityProc, /* 10 */
-    TclXML_RegisterUnknownEncodingProc, /* 11 */
-    TclXML_RegisterCommentProc, /* 12 */
-    TclXML_RegisterNotStandaloneProc, /* 13 */
-    TclXML_RegisterElementDeclProc, /* 14 */
-    TclXML_RegisterAttListDeclProc, /* 15 */
-    TclXML_RegisterStartDoctypeDeclProc, /* 16 */
-    TclXML_RegisterEndDoctypeDeclProc, /* 17 */
-    TclXML_ElementStartHandler, /* 18 */
-    TclXML_ElementEndHandler, /* 19 */
-    TclXML_CharacterDataHandler, /* 20 */
-    TclXML_ProcessingInstructionHandler, /* 21 */
-    TclXML_ExternalEntityRefHandler, /* 22 */
-    TclXML_DefaultHandler, /* 23 */
-    TclXML_UnparsedDeclHandler, /* 24 */
-    TclXML_NotationDeclHandler, /* 25 */
-    TclXML_UnknownEncodingHandler, /* 26 */
-    TclXML_CommentHandler, /* 27 */
-    TclXML_NotStandaloneHandler, /* 28 */
-    NULL, /* 29 */
-    NULL, /* 30 */
-    TclXML_ElementDeclHandler, /* 31 */
-    TclXML_AttlistDeclHandler, /* 32 */
-    TclXML_StartDoctypeDeclHandler, /* 33 */
-    TclXML_EndDoctypeDeclHandler, /* 34 */
-};
-
-/* !END!: Do not edit above this line. */
diff --git a/tclxml-3.2/tclxmlStubLib.c b/tclxml-3.2/tclxmlStubLib.c
deleted file mode 100644
index b376329..0000000
--- a/tclxml-3.2/tclxmlStubLib.c
+++ /dev/null
@@ -1,71 +0,0 @@
-/* 
- * tclxmlStubLib.c --
- *
- *	Stub object that will be statically linked into extensions that wish
- *	to access the TCLXML API.
- *
- * Copyright (c) 1998 Paul Duffin.
- * Copyright (c) 1998-1999 by Scriptics Corporation.
- * Copyright (c) 2004 Zveno Pty Ltd.
- *
- * See the file "license.terms" for information on usage and redistribution
- * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
- *
- * RCS: @(#) $Id: tclxmlStubLib.c,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
- */
-
-#ifndef USE_TCL_STUBS
-#define USE_TCL_STUBS
-#endif
-
-#include <tclxml/tclxml.h>
-
-TclxmlStubs *tclxmlStubsPtr;
-
-/*
- *----------------------------------------------------------------------
- *
- * TclXML_InitStubs --
- *
- *	Checks that the correct version of Blt is loaded and that it
- *	supports stubs. It then initialises the stub table pointers.
- *
- * Results:
- *	The actual version of BLT that satisfies the request, or
- *	NULL to indicate that an error occurred.
- *
- * Side effects:
- *	Sets the stub table pointers.
- *
- *----------------------------------------------------------------------
- */
-
-CONST char *
-TclXML_InitStubs(interp, version, exact)
-    Tcl_Interp *interp;
-    CONST char *version;
-    int exact;
-{
-    CONST char *result;
-
-    /* HACK: de-CONST 'version' if compiled against 8.3.
-     * The API has no CONST despite not modifying the argument
-     * And a debug build with high warning-level on windows
-     * will abort the compilation.
-     */
-
-#if ((TCL_MAJOR_VERSION < 8) || ((TCL_MAJOR_VERSION == 8) && (TCL_MINOR_VERSION < 4)))
-#define UNCONST (char*)
-#else
-#define UNCONST 
-#endif
-
-    result = Tcl_PkgRequireEx(interp, "xml::c", UNCONST version, exact,
-		(ClientData *) &tclxmlStubsPtr);
-    if (!result || !tclxmlStubsPtr) {
-        return (char *) NULL;
-    }
-
-    return result;
-}
-#undef UNCONST
diff --git a/tclxml-3.2/tclxslt-libxslt.c b/tclxml-3.2/tclxslt-libxslt.c
deleted file mode 100644
index f375d23..0000000
--- a/tclxml-3.2/tclxslt-libxslt.c
+++ /dev/null
@@ -1,1872 +0,0 @@
-/*
- * tclxslt.c --
- *
- *  Interface to Gnome libxslt.
- *
- * Copyright (c) 2005-2007 Explain
- * http://www.explain.com.au/
- * Copyright (c) 2001-2004 Zveno Pty Ltd
- * http://www.zveno.com/
- *
- * See the file "LICENSE" for information on usage and
- * redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
- *
- * $Id: tclxslt-libxslt.c,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
- *
- */
-
-#include <tclxslt/tclxslt.h>
-#include <string.h>
-#include <libxslt/imports.h>
-#include <libxslt/security.h>
-
-#undef TCL_STORAGE_CLASS
-#define TCL_STORAGE_CLASS DLLEXPORT
-
-#ifdef __WIN32__
-#     include "win/win32config.h"
-#endif
-
-/*
- * Manage stylesheet objects
- */
-
-typedef struct TclXSLT_Stylesheet {
-  Tcl_Interp *interp;
-  char *name;
-  xsltStylesheetPtr stylesheet;
-  Tcl_HashEntry *entryPtr;
-
-  Tcl_Obj *resulturi;
-  Tcl_Obj *profilechannelObj;
-
-  Tcl_Obj *messagecommand;
-} TclXSLT_Stylesheet;
-
-/*
- * Extension management
- */
-
-typedef struct TclXSLT_Extension {
-  Tcl_Interp *interp;
-  Tcl_Obj *nsuri;
-  Tcl_Obj *tclns;
-  xsltTransformContextPtr xformCtxt;
-} TclXSLT_Extension;
-
-typedef struct ThreadSpecificData {
-  int initialised;
-  Tcl_Interp *interp;
-  int ssheetCntr;
-  Tcl_HashTable *stylesheets;
-  Tcl_HashTable *extensions;
-} ThreadSpecificData;
-static Tcl_ThreadDataKey dataKey;
-
-/*
- * Prototypes for procedures defined later in this file:
- */
-
-/*
- * Forward declarations for private functions.
- */
-
-static void TclXSLTGenericError _ANSI_ARGS_((void *ctx, const char *msg, ...));
-
-static int TclXSLTCompileCommand _ANSI_ARGS_((ClientData dummy,
-						Tcl_Interp *interp,
-						int objc,
-						Tcl_Obj *CONST objv[]));
-static int TclXSLTInstanceCommand _ANSI_ARGS_((ClientData ssheet,
-						Tcl_Interp *interp,
-						int objc,
-						Tcl_Obj *CONST objv[]));
-static void TclXSLTDeleteStylesheet _ANSI_ARGS_((ClientData ssheet));
-static int TclXSLTExtensionCommand _ANSI_ARGS_((ClientData dummy,
-						Tcl_Interp *interp,
-						int objc,
-						Tcl_Obj *CONST objv[]));
-
-static Tcl_Obj * GetParameters _ANSI_ARGS_((Tcl_Interp *interp,
-					    xsltStylesheetPtr stylesheet));
-static int TclXSLTTransform _ANSI_ARGS_((TclXSLT_Stylesheet *stylesheet,
-                                         Tcl_Obj *source,
-                                         int paramc,
-                                         Tcl_Obj *CONST paramv[]));
-
-static void TclXSLT_RegisterAll _ANSI_ARGS_((TclXSLT_Extension *extinfo,
-						const xmlChar *nsuri));
-
-/* static xsltExtInitFunction TclXSLTExtInit; */
-static void *TclXSLTExtInit _ANSI_ARGS_((xsltTransformContextPtr ctxt,
-					const xmlChar *URI));
-/* static xsltExtShutdownFunction TclXSLTExtShutdown; */
-static void TclXSLTExtShutdown _ANSI_ARGS_((xsltTransformContextPtr ctxt,
-					    const xmlChar *URI,
-					    void *userdata));
-/* static xmlXPathEvalFunc TclXSLTExtFunction; */
-static void TclXSLTExtFunction _ANSI_ARGS_((xmlXPathParserContextPtr xpathCtxt,
-					    int nargs));
-/* static xsltPreComputeFunction TclXSLTExtElementPreComp; */
-static void TclXSLTExtElementPreComp _ANSI_ARGS_((xsltStylesheetPtr style,
-						  xmlNodePtr inst,
-						  xsltTransformFunction function));
-/* static xsltTransformFunction TclXSLTExtElementTransform; */
-static void TclXSLTExtElementTransform _ANSI_ARGS_((xsltTransformContextPtr ctxt,
-					            xmlNodePtr node,
-					            xmlNodePtr inst,
-					            xsltStylePreCompPtr comp));
-/* static xsltSecurityCheck TclXSLTSecurityReadFile; */
-static int TclXSLTSecurityReadFile _ANSI_ARGS_((xsltSecurityPrefsPtr sec,
-						xsltTransformContextPtr ctxt,
-						const char *value));
-/* static xsltSecurityCheck TclXSLTSecurityWriteFile; */
-static int TclXSLTSecurityWriteFile _ANSI_ARGS_((xsltSecurityPrefsPtr sec,
-						 xsltTransformContextPtr ctxt,
-						 const char *value));
-/* static xsltSecurityCheck TclXSLTSecurityCreateDirectory; */
-static int TclXSLTSecurityCreateDirectory _ANSI_ARGS_((xsltSecurityPrefsPtr sec,
-						       xsltTransformContextPtr ctxt,
-						       const char *value));
-/* static xsltSecurityCheck TclXSLTSecurityReadNetwork; */
-static int TclXSLTSecurityReadNetwork _ANSI_ARGS_((xsltSecurityPrefsPtr sec,
-						   xsltTransformContextPtr ctxt,
-						   const char *value));
-/* static xsltSecurityCheck TclXSLTSecurityWriteNetwork; */
-static int TclXSLTSecurityWriteNetwork _ANSI_ARGS_((xsltSecurityPrefsPtr sec,
-						    xsltTransformContextPtr ctxt,
-						    const char *value));
-
-static Tcl_Obj * TclXSLT_ConvertXPathObjToTclObj _ANSI_ARGS_((Tcl_Interp *interp,
-                                                              xmlXPathObjectPtr xpobj));
-static xmlXPathObjectPtr TclXSLT_ConvertTclObjToXPathObj _ANSI_ARGS_((Tcl_Interp *interp,
-                                                              Tcl_Obj *objPtr));
-
-/*
- * Error context for passing error result back to caller.
- */
-
-typedef struct GenericError_Info {
-  Tcl_Interp *interp;
-  TclXSLT_Stylesheet *stylesheet;
-  int code;
-  Tcl_Obj *msg;
-} GenericError_Info;
-
-/*
- * Switch tables
- */
-
-#ifndef CONST84
-#define CONST84 /* Before 8.4 no 'const' required */
-#endif
-
-static CONST84 char *instanceCommandMethods[] = {
-  "cget",
-  "configure",
-  "get",
-  "transform",
-  (char *) NULL
-};
-enum instanceCommandMethods {
-  TCLXSLT_CGET,
-  TCLXSLT_CONFIGURE,
-  TCLXSLT_GET,
-  TCLXSLT_TRANSFORM
-};
-static CONST84 char *instanceCommandOptions[] = {
-  "-messagecommand",
-  "-method",
-  "-indent",
-  "-resulturi",
-  "-profilechannel",
-  "-encoding",
-  "-omitxmldeclaration",
-  (char *) NULL
-};
-enum instanceCommandOptions {
-  TCLXSLT_OPTION_MESSAGECOMMAND,
-  TCLXSLT_OPTION_METHOD,
-  TCLXSLT_OPTION_INDENT,
-  TCLXSLT_OPTION_RESULTURI,
-  TCLXSLT_OPTION_PROFILECHANNEL,
-  TCLXSLT_OPTION_ENCODING,
-  TCLXSLT_OPTION_OMITXMLDECLARATION
-};
-
-static CONST84 char *instanceGetMethods[] = {
-  "parameters",
-  (char *) NULL
-};
-enum instanceGetMethods {
-  TCLXSLT_GET_PARAMETERS
-};
-
-static CONST84 char *extensionCommandMethods[] = {
-  "add",
-  "remove",
-  (char *) NULL
-};
-enum extensionCommandMethods {
-  TCLXSLT_EXT_ADD,
-  TCLXSLT_EXT_REMOVE
-};
-
-/*
- * libxml2 and libxslt are mostly thread-safe,
- * but there are issues with error callbacks.
- */
-
-TCL_DECLARE_MUTEX(libxslt)
-
-/*
- *----------------------------------------------------------------------------
- *
- * Tclxslt_libxslt_Init --
- *
- *  Initialisation routine for loadable module
- *
- * Results:
- *  None.
- *
- * Side effects:
- *  Creates commands in the interpreter,
- *
- *----------------------------------------------------------------------------
- */
-
-int
-Tclxslt_libxslt_Init (interp)
-     Tcl_Interp *interp;	/* Interpreter to initialise */
-{
-  ThreadSpecificData *tsdPtr;
-  xsltSecurityPrefsPtr sec;
-
-  tsdPtr = (ThreadSpecificData *) Tcl_GetThreadData(&dataKey, sizeof(ThreadSpecificData));
-  if (!tsdPtr->initialised) {
-    tsdPtr->initialised = 1;
-    tsdPtr->interp = interp;
-    tsdPtr->ssheetCntr = 0;
-    tsdPtr->stylesheets = (Tcl_HashTable *) Tcl_Alloc(sizeof(Tcl_HashTable));
-    Tcl_InitHashTable(tsdPtr->stylesheets, TCL_ONE_WORD_KEYS);
-    tsdPtr->extensions = (Tcl_HashTable *) Tcl_Alloc(sizeof(Tcl_HashTable));
-    Tcl_InitHashTable(tsdPtr->extensions, TCL_STRING_KEYS);
-  } /* only need to init the library once per process */
-
-  Tcl_CreateObjCommand(interp, "xslt::compile", TclXSLTCompileCommand, NULL, NULL);
-  Tcl_CreateObjCommand(interp, "xslt::extension", TclXSLTExtensionCommand, NULL, NULL);
-
-  Tcl_MutexLock(&libxslt);
-#ifndef TCLXML_STATIC_TCLXSLT
-  exsltRegisterAll();
-#endif /* TCLXML_STATIC_TCLXSLT */
-
-  /*
-   * Setup security preferences
-   */
-  sec = xsltNewSecurityPrefs();
-  if (xsltSetSecurityPrefs(sec, XSLT_SECPREF_READ_FILE,
-			   TclXSLTSecurityReadFile)) {
-    Tcl_SetResult(interp, "unable to set readfile security", NULL);
-    return TCL_ERROR;
-  }
-  if (xsltSetSecurityPrefs(sec, XSLT_SECPREF_WRITE_FILE,
-			   TclXSLTSecurityWriteFile)) {
-    Tcl_SetResult(interp, "unable to set writefile security", NULL);
-    return TCL_ERROR;
-  }
-  if (xsltSetSecurityPrefs(sec, XSLT_SECPREF_CREATE_DIRECTORY,
-			   TclXSLTSecurityCreateDirectory)) {
-    Tcl_SetResult(interp, "unable to set createdirectory security", NULL);
-    return TCL_ERROR;
-  }
-  if (xsltSetSecurityPrefs(sec, XSLT_SECPREF_READ_NETWORK,
-			   TclXSLTSecurityReadNetwork)) {
-    Tcl_SetResult(interp, "unable to set readnetwork security", NULL);
-    return TCL_ERROR;
-  }
-  if (xsltSetSecurityPrefs(sec, XSLT_SECPREF_WRITE_NETWORK,
-			   TclXSLTSecurityWriteNetwork)) {
-    Tcl_SetResult(interp, "unable to set writenetwork security", NULL);
-    return TCL_ERROR;
-  }
-  /* xsltSetCtxtSecurityPrefs(sec, userCtxt); */
-  xsltSetDefaultSecurityPrefs(sec);
-
-  Tcl_MutexUnlock(&libxslt);
-
-  Tcl_SetVar2Ex(interp, "::xslt::libxsltversion", NULL, Tcl_NewStringObj(xsltEngineVersion, -1), 0);
-  Tcl_SetVar2Ex(interp, "::xslt::libexsltversion", NULL, Tcl_NewStringObj(exsltLibraryVersion, -1), 0);
-
-  return TCL_OK;
-}
-
-/*
- * XSLT is not safe due to the document(), xsl:include and xsl:import functions/elements.
- * However, libxslt checks whether access is permitted to external resources.
- *
- * NOTE: need to make sure decision to allow access to resources is made by a trusted interpreter, not the untrusted slave.  Even better, use a mechanism similar to TclXML/libxml2 to access external resources.
- */
-
-int
-Tclxslt_libxslt_SafeInit (interp)
-     Tcl_Interp *interp;	/* Interpreter to initialise */
-{
-  return Tclxslt_libxslt_Init(interp);
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXSLTCompileCommand --
- *
- *  Class creation command for xslt stylesheet objects.
- *
- * Results:
- *  Compiles the XSLT stylesheet.
- *  Creates a Tcl command associated with that stylesheet.
- *
- * Side effects:
- *  Memory allocated, stylesheet is compiled.
- *
- *----------------------------------------------------------------------------
- */
-
-static int
-TclXSLTCompileCommand(dummy, interp, objc, objv)
-     ClientData dummy;
-     Tcl_Interp *interp;
-     int objc;
-     Tcl_Obj *CONST objv[];
-{
-  ThreadSpecificData *tsdPtr = (ThreadSpecificData *) Tcl_GetThreadData(&dataKey, sizeof(ThreadSpecificData));
-  TclXSLT_Stylesheet *info;
-  xmlDocPtr origDoc, doc;
-  xsltStylesheetPtr ssheetPtr = NULL;
-  void *oldxsltErrorCtx, *oldxmlErrorCtx;
-  xmlGenericErrorFunc old_xsltGenericError, old_xmlGenericError;
-  GenericError_Info *errorInfoPtr;
-  Tcl_Obj *errObjPtr = NULL;
-  int new;
-
-  if (objc != 2) {
-    Tcl_WrongNumArgs(interp, 1, objv, "stylesheet-doc");
-    return TCL_ERROR;
-  }
-
-  if (TclXML_libxml2_GetDocFromObj(interp, objv[1], &origDoc) != TCL_OK) {
-    return TCL_ERROR;
-  }
-
-  Tcl_MutexLock(&libxslt);
-  doc = xmlCopyDoc(origDoc, 1);
-  /*
-   * xmlCopyDoc doesn't copy some of the fields.
-   */
-  if (origDoc->URL) {
-    doc->URL = (const xmlChar *) Tcl_Alloc(strlen((char *) origDoc->URL) + 1);
-    strcpy((char *) doc->URL, (char *) origDoc->URL);
-  }
-
-  /*
-   * Prepare for compiling stylesheet
-   */
-
-  TclXML_libxml2_ResetError(interp);
-
-  errorInfoPtr = (GenericError_Info *) Tcl_Alloc(sizeof(GenericError_Info));
-  errorInfoPtr->interp = interp;
-  errorInfoPtr->stylesheet = NULL;
-  errorInfoPtr->code = TCL_OK;
-  errorInfoPtr->msg = NULL;
-  xmlSetGenericErrorFunc((void *) errorInfoPtr,
-			 TclXSLTGenericError);
-
-  /*
-   * Save the previous error context so that it can
-   * be restored upon completion of the operation.
-   */
-  old_xsltGenericError = xsltGenericError;
-  oldxsltErrorCtx = xsltGenericErrorContext;
-  old_xmlGenericError = xmlGenericError;
-  oldxmlErrorCtx = xmlGenericErrorContext;
-
-  xmlSetGenericErrorFunc((void *) errorInfoPtr,
-			 TclXSLTGenericError);
-  xsltSetGenericErrorFunc((void *) errorInfoPtr, TclXSLTGenericError);
-
-  /*
-   * Compile stylesheet
-   */
-
-  ssheetPtr = xsltParseStylesheetDoc(doc);
-
-  xmlSetGenericErrorFunc((void *) oldxmlErrorCtx, old_xmlGenericError);
-  xsltSetGenericErrorFunc((void *) oldxsltErrorCtx, old_xsltGenericError);
-
-  Tcl_MutexUnlock(&libxslt);
-
-  errObjPtr = TclXML_libxml2_GetErrorObj(interp);
-
-  if (ssheetPtr == NULL) {
-    Tcl_SetResult(interp, "error compiling stylesheet", NULL);
-    goto error;
-  }
-
-  if (ssheetPtr->errors > 0) {
-    Tcl_SetResult(interp, "error compiling XSLT stylesheet", NULL);
-    goto error;
-  }
-
-  if (errorInfoPtr->code != TCL_OK) {
-    goto error;
-  }
-
-  /* TODO: notify app of any warnings */
-
-  info = (TclXSLT_Stylesheet *) Tcl_Alloc(sizeof(TclXSLT_Stylesheet));
-  info->interp = interp;
-  info->name = Tcl_Alloc(20);
-  sprintf(info->name, "style%d", tsdPtr->ssheetCntr++);
-  info->stylesheet = ssheetPtr;
-  info->messagecommand = NULL;
-  info->resulturi = NULL;
-  info->profilechannelObj = NULL;
-
-  /*
-   * Create reverse mapping of stylesheet to name of stylesheet command.
-   */
-  info->entryPtr = Tcl_CreateHashEntry(tsdPtr->stylesheets, (ClientData) ssheetPtr, &new);
-  /* sanity check: new == 1 */
-  Tcl_SetHashValue(info->entryPtr, (ClientData) info->name);
-
-  Tcl_CreateObjCommand(interp, info->name, TclXSLTInstanceCommand, (ClientData) info, TclXSLTDeleteStylesheet);
-
-  Tcl_SetObjResult(interp, Tcl_NewStringObj(info->name, -1));
-
-  return TCL_OK;
-
-error:
-
-  if (errObjPtr) {
-    Tcl_SetObjResult(interp, errObjPtr);
-  } else if (errorInfoPtr->msg) {
-    Tcl_SetObjResult(interp, errorInfoPtr->msg);
-    Tcl_DecrRefCount(errorInfoPtr->msg);
-  }
-  Tcl_Free((char *) errorInfoPtr);
-
-  Tcl_MutexLock(&libxslt);
-  if (ssheetPtr) {
-    xsltFreeStylesheet(ssheetPtr);
-  } else {
-    xmlFreeDoc(doc);
-  }
-  Tcl_MutexUnlock(&libxslt);
-  
-  return TCL_ERROR;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXSLTDeleteStylesheet --
- *
- *  Class destruction command for xslt stylesheet objects.
- *
- * Results:
- *  Frees memory associated with a stylesheet.
- *
- * Side effects:
- *  Memory deallocated.
- *
- *----------------------------------------------------------------------------
- */
-
-static void
-TclXSLTDeleteStylesheet(clientData)
-     ClientData clientData;
-{
-  TclXSLT_Stylesheet *ssheet = (TclXSLT_Stylesheet *) clientData;
-
-  Tcl_DeleteHashEntry(ssheet->entryPtr);
-  
-  Tcl_Free(ssheet->name);
-  if (ssheet->messagecommand) {
-    Tcl_DecrRefCount(ssheet->messagecommand);
-  }
-  if (ssheet->resulturi) {
-    Tcl_DecrRefCount(ssheet->resulturi);
-  }
-  if (ssheet->profilechannelObj) {
-    Tcl_DecrRefCount(ssheet->profilechannelObj);
-  }
-  Tcl_MutexLock(&libxslt);
-  xsltFreeStylesheet(ssheet->stylesheet); /* Also frees document */
-  Tcl_MutexUnlock(&libxslt);
-  Tcl_Free((char *) ssheet);
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXSLTInstanceCommand --
- *
- *  Handles the stylesheet object command.
- *
- * Results:
- *  Depends on method.
- *
- * Side effects:
- *  Depends on method.
- *
- *----------------------------------------------------------------------------
- */
-
-static int
-TclXSLTInstanceCommand(clientData, interp, objc, objv)
-     ClientData clientData;
-     Tcl_Interp *interp;
-     int objc;
-     Tcl_Obj *CONST objv[];
-{
-  TclXSLT_Stylesheet *ssheet = (TclXSLT_Stylesheet *) clientData;
-  int method, option, indent = 0, theOmitXMLDeclaration = 0;
-  const xmlChar *theMethod, *theEncoding;
-
-  if (objc < 3) {
-    Tcl_WrongNumArgs(interp, 1, objv, "method ?args ...?");
-    return TCL_ERROR;
-  }
-
-  if (Tcl_GetIndexFromObj(interp, objv[1], instanceCommandMethods, 
-			    "method", 0, &method) != TCL_OK) {
-    return TCL_ERROR;
-  }
-
-  switch ((enum instanceCommandMethods) method) {
-  case TCLXSLT_CGET:
-
-    if (objc != 3) {
-      Tcl_WrongNumArgs(interp, 2, objv, "option");
-      return TCL_ERROR;
-    }
-
-    if (Tcl_GetIndexFromObj(interp, objv[2], instanceCommandOptions, 
-			    "option", 0, &option) != TCL_OK) {
-      return TCL_ERROR;
-    }
-
-    switch ((enum instanceCommandOptions) option) {
-
-    case TCLXSLT_OPTION_METHOD:
-      XSLT_GET_IMPORT_PTR(theMethod, ssheet->stylesheet, method);
-      if (theMethod != NULL) {
-        Tcl_SetObjResult(interp, Tcl_NewStringObj((CONST char *) theMethod, -1));
-      } /* theMethod == NULL means XML method; result should be empty.
-	   EXCEPTION: if the result document is of type XML_HTML_DOCUMENT_NODE
-	   then the method should be "html".
-	 */
-      break;
-
-    case TCLXSLT_OPTION_ENCODING:
-      XSLT_GET_IMPORT_PTR(theEncoding, ssheet->stylesheet, encoding);
-      if (theEncoding != NULL) {
-        Tcl_SetObjResult(interp, Tcl_NewStringObj((CONST char *) theEncoding, -1));
-      } /* theEncoding == NULL means default (UTF-8) encoding; result should be empty.
-	 */
-      break;
-
-    case TCLXSLT_OPTION_OMITXMLDECLARATION:
-      XSLT_GET_IMPORT_INT(theOmitXMLDeclaration, ssheet->stylesheet, omitXmlDeclaration);
-      Tcl_SetObjResult(interp, Tcl_NewBooleanObj(theOmitXMLDeclaration == 1));
-      break;
-
-    case TCLXSLT_OPTION_INDENT:
-      XSLT_GET_IMPORT_INT(indent, ssheet->stylesheet, indent);
-      Tcl_SetObjResult(interp, Tcl_NewBooleanObj(indent));
-      break;
-
-    case TCLXSLT_OPTION_MESSAGECOMMAND:
-      if (ssheet->messagecommand != NULL) {
-        Tcl_SetObjResult(interp, ssheet->messagecommand);
-      }
-      break;
-
-    case TCLXSLT_OPTION_RESULTURI:
-      if (ssheet->resulturi != NULL) {
-        Tcl_SetObjResult(interp, ssheet->resulturi);
-      }
-      break;
-
-    case TCLXSLT_OPTION_PROFILECHANNEL:
-      if (ssheet->profilechannelObj != NULL) {
-        Tcl_SetObjResult(interp, ssheet->profilechannelObj);
-      }
-      break;
-
-    default:
-      Tcl_SetResult(interp, "unknown option", NULL);
-      return TCL_ERROR;
-    }
-
-    break;
-
-  case TCLXSLT_CONFIGURE:
-    
-    if (objc != 4) {
-      Tcl_WrongNumArgs(interp, 2, objv, "option value");
-      return TCL_ERROR;
-    }
-
-    if (Tcl_GetIndexFromObj(interp, objv[2], instanceCommandOptions, 
-			    "option", 0, &option) != TCL_OK) {
-      return TCL_ERROR;
-    }
-
-    switch ((enum instanceCommandOptions) option) {
-
-    case TCLXSLT_OPTION_METHOD:
-    case TCLXSLT_OPTION_INDENT:
-    case TCLXSLT_OPTION_ENCODING:
-    case TCLXSLT_OPTION_OMITXMLDECLARATION:
-      Tcl_SetResult(interp, "read-only option", NULL);
-      return TCL_ERROR;
-      break;
-
-    case TCLXSLT_OPTION_MESSAGECOMMAND:
-      if (ssheet->messagecommand != NULL) {
-        Tcl_DecrRefCount(ssheet->messagecommand);
-      }
-      ssheet->messagecommand = objv[3];
-      Tcl_IncrRefCount(ssheet->messagecommand);
-      break;
-
-    case TCLXSLT_OPTION_RESULTURI:
-      if (ssheet->resulturi != NULL) {
-        Tcl_DecrRefCount(ssheet->resulturi);
-      }
-      ssheet->resulturi = objv[3];
-      Tcl_IncrRefCount(ssheet->resulturi);
-      break;
-
-    case TCLXSLT_OPTION_PROFILECHANNEL:
-      if (ssheet->profilechannelObj != NULL) {
-        Tcl_DecrRefCount(ssheet->profilechannelObj);
-      }
-#ifdef __WIN32__
-      Tcl_SetResult(interp, "profiling not available", NULL);
-      return TCL_ERROR;
-#else
-      ssheet->profilechannelObj = objv[3];
-      Tcl_IncrRefCount(ssheet->profilechannelObj);
-#endif
-      break;
-
-    default:
-      Tcl_SetResult(interp, "unknown option", NULL);
-      return TCL_ERROR;
-    }
-
-    break;
-
-  case TCLXSLT_GET:
-    if (objc != 3) {
-      Tcl_WrongNumArgs(interp, 2, objv, "name");
-      return TCL_ERROR;
-    }
-
-    if (Tcl_GetIndexFromObj(interp, objv[2], instanceGetMethods,
-			    "name", 0, &option) != TCL_OK) {
-      return TCL_ERROR;
-    }
-
-    switch ((enum instanceGetMethods) option) {
-    case TCLXSLT_GET_PARAMETERS:
-
-      Tcl_SetObjResult(interp, GetParameters(interp, ssheet->stylesheet));
-      break;
-
-    default:
-      Tcl_SetResult(interp, "unknown name", NULL);
-      return TCL_ERROR;
-    }
-
-    break;
-
-  case TCLXSLT_TRANSFORM:
-    if (objc < 3) {
-      Tcl_WrongNumArgs(interp, 2, objv, "source ?param value...?");
-      return TCL_ERROR;
-    }
-
-    return TclXSLTTransform(ssheet, objv[2], objc - 3, &objv[3]);
-
-    break;
-
-  default:
-    Tcl_SetResult(interp, "unknown method", NULL);
-    return TCL_OK;
-  }
-
-  return TCL_OK;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXSLTTransform --
- *
- *  Performs an XSL transformation.
- *
- * Results:
- *  Result document created.
- *
- * Side effects:
- *  Memory allocated for result document.
- *
- *----------------------------------------------------------------------------
- */
-
-static int
-TclXSLTTransform(stylesheet, source, paramc, paramv)
-    TclXSLT_Stylesheet *stylesheet;
-    Tcl_Obj *source;
-    int paramc;
-    Tcl_Obj *CONST paramv[];
-{
-  xmlDocPtr doc, result;
-  char **params = NULL;
-  int nbparams = 0, i;
-  GenericError_Info *errorInfoPtr;
-  void *oldxsltErrorCtx, *oldxmlErrorCtx;
-  xmlGenericErrorFunc old_xsltGenericError, old_xmlGenericError;
-  Tcl_Obj *resultObjPtr, *errObjPtr = NULL;
-  char *resulturi = NULL;
-  FILE *profile = NULL;
-  xsltTransformContextPtr userCtxt = NULL;
-
-  errorInfoPtr = (GenericError_Info *) Tcl_Alloc(sizeof(GenericError_Info));
-  errorInfoPtr->interp = stylesheet->interp;
-  errorInfoPtr->stylesheet = stylesheet;
-  errorInfoPtr->code = TCL_OK;
-  errorInfoPtr->msg = NULL;
-
-  if (TclXML_libxml2_GetDocFromObj(stylesheet->interp, source, &doc) != TCL_OK) {
-    goto error;
-  }
-
-  TclXML_libxml2_ResetError(stylesheet->interp);
-
-  params = (char **) Tcl_Alloc(sizeof(char **) * (paramc + 1));
-  for (i = 0; i < paramc; i++) {
-    params[nbparams++] = Tcl_GetStringFromObj(paramv[i++], NULL);
-    params[nbparams++] = Tcl_GetStringFromObj(paramv[i], NULL);
-  }
-  params[nbparams] = NULL;
-
-  if (stylesheet->resulturi) {
-    resulturi = Tcl_GetStringFromObj(stylesheet->resulturi, NULL);
-  }
-#ifdef __WIN32__
-  /* Tcl_GetOpenFile not available on Windows */
-#else
-  if (stylesheet->profilechannelObj) {
-    if (Tcl_GetOpenFile(stylesheet->interp,
-			Tcl_GetStringFromObj(stylesheet->profilechannelObj, NULL),
-			1, 1,
-			(ClientData *) &profile) != TCL_OK) {
-      goto error;
-    }
-  }
-#endif
-
-  /*
-   * Perform the transformation
-   */
-
-  Tcl_MutexLock(&libxslt);
-
-  /*
-   * Save the previous error context so that it can
-   * be restored upon completion of the transformation.
-   * This is necessary because transformations may occur
-   * recursively (usually due to extensions).
-   */
-  old_xsltGenericError = xsltGenericError;
-  oldxsltErrorCtx = xsltGenericErrorContext;
-  old_xmlGenericError = xmlGenericError;
-  oldxmlErrorCtx = xmlGenericErrorContext;
-
-  xmlSetGenericErrorFunc((void *) errorInfoPtr,
-			 TclXSLTGenericError);
-  xsltSetGenericErrorFunc((void *) errorInfoPtr, TclXSLTGenericError);
-
-  userCtxt = xsltNewTransformContext(stylesheet->stylesheet, doc);
-  if (userCtxt == NULL) {
-    xmlSetGenericErrorFunc((void *) oldxmlErrorCtx, old_xmlGenericError);
-    xsltSetGenericErrorFunc((void *) oldxsltErrorCtx, old_xsltGenericError);
-
-    Tcl_MutexUnlock(&libxslt);
-    Tcl_SetResult(stylesheet->interp, "unable to create transformation context", NULL);
-    goto error;
-  }
-
-  result = xsltApplyStylesheetUser(stylesheet->stylesheet,
-				   doc,
-				   (const char **)params,
-				   resulturi,
-				   profile,
-				   userCtxt);
-
-  xsltFreeTransformContext(userCtxt);
-
-  xmlSetGenericErrorFunc((void *) oldxmlErrorCtx, old_xmlGenericError);
-  xsltSetGenericErrorFunc((void *) oldxsltErrorCtx, old_xsltGenericError);
-
-  Tcl_MutexUnlock(&libxslt);
-
-  errObjPtr = TclXML_libxml2_GetErrorObj(stylesheet->interp);
-
-  if (result == NULL) {
-    Tcl_Obj *resultPtr = Tcl_NewStringObj("no result document: ", -1);
-
-    if (errObjPtr) {
-      Tcl_AppendObjToObj(resultPtr, errObjPtr);
-      Tcl_SetObjResult(stylesheet->interp, resultPtr);
-      goto error;
-    } else {
-      if (errorInfoPtr->msg) {
-	Tcl_AppendObjToObj(resultPtr, errorInfoPtr->msg);
-      }
-
-      Tcl_SetObjResult(stylesheet->interp, resultPtr);
-      goto error;
-    }
-  }
-
-  if ((errObjPtr || (errorInfoPtr->code != TCL_OK && errorInfoPtr->msg)) && stylesheet->messagecommand) {
-
-    /* We have produced a result, but there may possibly
-     * have been errors.  Trouble is, there might also
-     * have been some completely innocent messages.
-     * -messageCommand is the only way to find out about these.
-     */
-
-    Tcl_Obj *cmdPtr = Tcl_DuplicateObj(stylesheet->messagecommand);
-    if (errObjPtr) {
-      if (Tcl_ListObjAppendElement(stylesheet->interp, cmdPtr, errObjPtr) != TCL_OK) {
-	goto error;
-      }
-    } else {
-      if (Tcl_ListObjAppendElement(stylesheet->interp, cmdPtr, errorInfoPtr->msg) != TCL_OK) {
-	goto error;
-      }
-    }
-    if (Tcl_GlobalEvalObj(stylesheet->interp, cmdPtr) != TCL_OK) {
-      Tcl_Obj *resultPtr = Tcl_NewStringObj("message command failed: ", -1);
-
-      Tcl_AppendObjToObj(resultPtr, Tcl_GetObjResult(stylesheet->interp));
-      Tcl_SetObjResult(stylesheet->interp, resultPtr);
-      goto error;
-    }
-
-  }
-
-  resultObjPtr = TclDOM_libxml2_CreateObjFromDoc(stylesheet->interp, result);
-  Tcl_SetObjResult(stylesheet->interp, resultObjPtr);
-
-  if (errorInfoPtr->msg) {
-    Tcl_DecrRefCount(errorInfoPtr->msg);
-  }
-  Tcl_Free((char *) errorInfoPtr);
-  Tcl_Free((char *) params);
-
-  return TCL_OK;
-
- error:
-
-  if (errorInfoPtr->msg) {
-    Tcl_DecrRefCount(errorInfoPtr->msg);
-  }
-  if (params) {
-    Tcl_Free((char *) params);
-  }
-  Tcl_Free((char *) errorInfoPtr);
-
-  return TCL_ERROR;
-}
-
-void
-ListObjAppendUniqueList(interp, tablePtr, listPtr, newElementsPtr)
-     Tcl_Interp *interp;
-     Tcl_HashTable *tablePtr;
-     Tcl_Obj *listPtr;
-     Tcl_Obj *newElementsPtr;
-{
-  int len, idx;
-  Tcl_Obj *elementPtr, *keyPtr, *namePtr, *nameURIPtr;
-  Tcl_HashEntry *entryPtr;
-
-  Tcl_ListObjLength(interp, newElementsPtr, &len);
-  for (idx = 0; idx < len; idx++) {
-	Tcl_ListObjIndex(interp, newElementsPtr, idx, &elementPtr);
-	Tcl_ListObjIndex(interp, elementPtr, 0, &namePtr);
-	Tcl_ListObjIndex(interp, elementPtr, 1, &nameURIPtr);
-
-	keyPtr = Tcl_NewObj();
-	Tcl_AppendStringsToObj(keyPtr,
-						   Tcl_GetStringFromObj(nameURIPtr, NULL), 
-						   "^", 
-						   Tcl_GetStringFromObj(namePtr, NULL),
-						   NULL);
-	entryPtr = Tcl_FindHashEntry(tablePtr, (CONST char *) keyPtr);
-	if (entryPtr == NULL) {
-	  Tcl_ListObjAppendElement(interp, listPtr, elementPtr);
-	}
-	Tcl_DecrRefCount(keyPtr);
-  }
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * GetParameters --
- *
- *  Retrieves the parameters for a stylesheet.
- *
- * Results:
- *  Returns a Tcl list object.
- *
- * Side effects:
- *  None.
- *
- *----------------------------------------------------------------------------
- */
-
-static Tcl_Obj *
-GetParameters(interp, stylesheet)
-     Tcl_Interp *interp;
-     xsltStylesheetPtr stylesheet;
-{
-  Tcl_Obj *resultPtr, *objPtr, *keyPtr;
-  xsltStackElemPtr varPtr;
-  Tcl_HashTable entries;  /* to keep track of parameter qnames */
-  int new;
-
-  if (stylesheet == NULL) {
-    return NULL;
-  }
-
-  resultPtr = Tcl_NewListObj(0, NULL);
-  Tcl_InitObjHashTable(&entries);
-
-  for (varPtr = stylesheet->variables; varPtr; varPtr = varPtr->next) {
-    Tcl_Obj *listPtr;
-
-    if (strcmp((char *) varPtr->comp->inst->name, "param") == 0) {
-      listPtr = Tcl_NewListObj(0, NULL);
-      Tcl_ListObjAppendElement(interp, listPtr, Tcl_NewStringObj((CONST char *) varPtr->name, -1));
-      Tcl_ListObjAppendElement(interp, listPtr, Tcl_NewStringObj((CONST char *) varPtr->nameURI, -1));
-      Tcl_ListObjAppendElement(interp, listPtr, Tcl_NewStringObj((CONST char *) varPtr->select, -1));
-
-      Tcl_ListObjAppendElement(interp, resultPtr, listPtr);
-
-	  keyPtr = Tcl_NewStringObj((CONST char *) varPtr->nameURI, -1);
-	  Tcl_AppendStringsToObj(keyPtr, "^", varPtr->name, NULL);
-	  Tcl_CreateHashEntry(&entries, (CONST char *) keyPtr, &new);
-    }
-  }
-
-  objPtr = GetParameters(interp, stylesheet->next);
-  if (objPtr) {
-    ListObjAppendUniqueList(interp, &entries, resultPtr, objPtr);
-  }
-  objPtr = GetParameters(interp, stylesheet->imports);
-  if (objPtr) {
-    ListObjAppendUniqueList(interp, &entries, resultPtr, objPtr);
-  }
-
-  Tcl_DeleteHashTable(&entries);
-
-  return resultPtr;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXSLTGenericError --
- *
- *  Handler for stylesheet errors.
- *
- *  NB. Cannot distinguish between errors and use of xsl:message element.
- *
- * Results:
- *  Stores error message.
- *
- * Side effects:
- *  Transform will return error condition.
- *
- *----------------------------------------------------------------------------
- */
-
-static void
-TclXSLTGenericError (void *ctx, const char *msg, ...)
-{
-  va_list args;
-  char buf[2048];
-  int len;
-  GenericError_Info *errorInfoPtr = (GenericError_Info *) ctx;
-
-  if (ctx < (void *) 0x1000) {
-    fprintf(stderr, "TclXSLT: bad context\n");
-    va_start(args,msg);
-    vfprintf(stderr, msg, args);
-    va_end(args);
-    return;
-  }
-
-  va_start(args,msg);
-  len = vsnprintf(buf, 2047, msg, args);
-  va_end(args);
-
-  if (!errorInfoPtr->interp) {
-    return;
-  }
-
-  if (errorInfoPtr->stylesheet && errorInfoPtr->stylesheet->messagecommand) {
-
-    Tcl_Obj *cmdPtr = Tcl_DuplicateObj(errorInfoPtr->stylesheet->messagecommand);
-    if (Tcl_ListObjAppendElement(errorInfoPtr->interp, cmdPtr, Tcl_NewStringObj(buf, len)) != TCL_OK) {
-      Tcl_BackgroundError(errorInfoPtr->interp);
-      return;
-    }
-    if (Tcl_GlobalEvalObj(errorInfoPtr->interp, cmdPtr) != TCL_OK) {
-      Tcl_BackgroundError(errorInfoPtr->interp);
-      return;
-    }
-
-  } else {
-
-    if (!errorInfoPtr->msg) {
-      errorInfoPtr->msg = Tcl_NewObj();
-      Tcl_IncrRefCount(errorInfoPtr->msg);
-    }
-
-    errorInfoPtr->code = TCL_ERROR;
-
-    Tcl_AppendToObj(errorInfoPtr->msg, buf, len);
-
-  }
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXSLTExtensionCommand --
- *
- *  Command for xslt::extension command.
- *
- * Results:
- *  Depends on method.
- *
- * Side effects:
- *  Depends on method
- *
- *----------------------------------------------------------------------------
- */
-
-static int
-TclXSLTExtensionCommand(dummy, interp, objc, objv)
-     ClientData dummy;
-     Tcl_Interp *interp;
-     int objc;
-     Tcl_Obj *CONST objv[];
-{
-  ThreadSpecificData *tsdPtr = (ThreadSpecificData *) Tcl_GetThreadData(&dataKey, sizeof(ThreadSpecificData));
-  int method, new;
-  TclXSLT_Extension *extinfo;
-  Tcl_HashEntry *entry;
-
-  if (objc < 2) {
-    Tcl_WrongNumArgs(interp, 1, objv, "method ?args ...?");
-    return TCL_ERROR;
-  }
-
-  if (Tcl_GetIndexFromObj(interp, objv[1], extensionCommandMethods,
-			  "method", 0, &method) != TCL_OK) {
-    return TCL_ERROR;
-  }
-
-  switch ((enum extensionCommandMethods) method) {
-
-  case TCLXSLT_EXT_ADD:
-    if (objc != 4) {
-      Tcl_WrongNumArgs(interp, 2, objv, "nsuri tcl-namespace");
-      return TCL_ERROR;
-    }
-
-    Tcl_MutexLock(&libxslt);
-
-    if (xsltRegisterExtModule((const xmlChar *) Tcl_GetStringFromObj(objv[2], NULL),
-			      TclXSLTExtInit,
-			      TclXSLTExtShutdown)) {
-      Tcl_MutexUnlock(&libxslt);
-      Tcl_SetResult(interp, "cannot register extension module", NULL);
-    }
-
-    Tcl_MutexUnlock(&libxslt);
-
-    extinfo = (TclXSLT_Extension *) Tcl_Alloc(sizeof(TclXSLT_Extension));
-    extinfo->interp = interp;
-    extinfo->nsuri = objv[2];
-    Tcl_IncrRefCount(objv[2]);
-    extinfo->tclns = objv[3];
-    Tcl_IncrRefCount(objv[3]);
-
-    extinfo->xformCtxt = NULL;
-
-    entry = Tcl_CreateHashEntry(tsdPtr->extensions, Tcl_GetStringFromObj(objv[2], NULL), &new);
-
-    if (!new) {
-      Tcl_SetResult(interp, "extension already exists", NULL);
-      Tcl_Free((char *) extinfo);
-      return TCL_ERROR;
-    }
-
-    Tcl_SetHashValue(entry, extinfo);
-
-    TclXSLT_RegisterAll(extinfo, (const xmlChar *) Tcl_GetStringFromObj(objv[2], NULL));
-
-    Tcl_ResetResult(interp);
-
-    break;
-
-  case TCLXSLT_EXT_REMOVE:
-    if (objc != 3) {
-      Tcl_WrongNumArgs(interp, 2, objv, "nsuri");
-      return TCL_ERROR;
-    }
-
-    /*
-     * TODO: Remove previously registered elements and functions.
-    */
-
-    entry = Tcl_FindHashEntry(tsdPtr->extensions, Tcl_GetStringFromObj(objv[2], NULL));
-    if (entry == NULL) {
-      Tcl_SetResult(interp, "unknown XML Namespace URI", NULL);
-      return TCL_ERROR;
-    }
-
-    extinfo = (TclXSLT_Extension *) Tcl_GetHashValue(entry);
-    Tcl_DecrRefCount(extinfo->nsuri);
-    Tcl_DecrRefCount(extinfo->tclns);
-    Tcl_Free((char *) extinfo);
-
-    Tcl_DeleteHashEntry(entry);
-
-    break;
-
-  default:
-    Tcl_SetResult(interp, "unknown method", NULL);
-    return TCL_ERROR;
-  }
-
-  return TCL_OK;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXSLTExtInit --
- *
- *  Load extensions into a transformation context.
- *
- * Results:
- *  Returns pointer to extension data.
- *  Elements and functions are pre-registered.
- *
- * Side effects:
- *  None.
- *
- *----------------------------------------------------------------------------
- */
-
-static void *
-TclXSLTExtInit(ctxt, URI)
-     xsltTransformContextPtr ctxt;
-     const xmlChar *URI;
-{
-  ThreadSpecificData *tsdPtr = (ThreadSpecificData *) Tcl_GetThreadData(&dataKey, sizeof(ThreadSpecificData));
-  Tcl_HashEntry *entry;
-  TclXSLT_Extension *extinfo;
-
-  entry = Tcl_FindHashEntry(tsdPtr->extensions, (CONST char *) URI);
-  if (entry == NULL) {
-    /* Extension module was removed */
-    return NULL;
-  }
-
-  extinfo = (TclXSLT_Extension *) Tcl_GetHashValue(entry);
-  extinfo->xformCtxt = ctxt;
-
-  return (void *) extinfo;
-}
-
-void
-TclXSLT_RegisterAll(extinfo, nsuri)
-    TclXSLT_Extension *extinfo;
-    const xmlChar *nsuri;
-{
-  Tcl_Obj *cmdPtr, *objPtr;
-  Tcl_Obj **reg;
-  int ret, i, len;
-
-  /*
-   * Q: How to distinguish between extension elements and functions?
-   * A: Use the formal parameters.  If the command can accept
-   * a variable argument list, then it is registered as a function.
-   * Otherwise it will be registered as an extension (and expected
-   * to accept certain arguments).
-   */
-
-  cmdPtr = Tcl_NewStringObj("::xslt::getprocs ", -1);
-  Tcl_IncrRefCount(cmdPtr);
-  Tcl_AppendObjToObj(cmdPtr, extinfo->tclns);
-  ret = Tcl_EvalObjEx(extinfo->interp, cmdPtr, TCL_EVAL_GLOBAL|TCL_EVAL_DIRECT);
-  objPtr = Tcl_GetObjResult(extinfo->interp);
-  Tcl_IncrRefCount(objPtr);
-  Tcl_DecrRefCount(cmdPtr);
-
-  if (ret != TCL_OK || objPtr == NULL) {
-    /*
-     * Something went wrong, therefore nothing to register.
-     */
-    return;
-  }
-
-  ret = Tcl_ListObjGetElements(extinfo->interp, objPtr, &len, &reg);
-  if (ret != TCL_OK || len != 2) {
-    /*
-     * Something went wrong, therefore nothing to register.
-     */
-    return;
-  }
-
-  /*
-   * reg[0] contains extension elements
-   * reg[1] contains extension functions
-   */
-
-  Tcl_MutexLock(&libxslt);
-
-  /*
-   * First register the extension elements.
-   */
-
-  ret = Tcl_ListObjLength(extinfo->interp, reg[0], &len);
-  if (ret == TCL_OK && len > 0) {
-    for (i = 0; i < len; i++) {
-
-      if (Tcl_ListObjIndex(extinfo->interp, reg[0], i, &objPtr) != TCL_OK) {
-        continue;
-      }
-
-      xsltRegisterExtModuleElement((const xmlChar *) Tcl_GetStringFromObj(objPtr, NULL),
-                             nsuri,
-                             (xsltPreComputeFunction) TclXSLTExtElementPreComp,
-                             (xsltTransformFunction) TclXSLTExtElementTransform);
-    }
-  }
-
-  /*
-   * Now register the extension functions.
-   */
-
-  ret = Tcl_ListObjLength(extinfo->interp, reg[1], &len);
-  if (ret != TCL_OK || len == 0) {
-    Tcl_MutexUnlock(&libxslt);
-    return;
-  }
-
-  for (i = 0; i < len; i++) {
-
-    if (Tcl_ListObjIndex(extinfo->interp, reg[1], i, &objPtr) != TCL_OK) {
-      continue;
-    }
-
-    xsltRegisterExtModuleFunction((const xmlChar *) Tcl_GetStringFromObj(objPtr, NULL),
-    	nsuri,
-    	TclXSLTExtFunction);
-  }
-
-  Tcl_MutexUnlock(&libxslt);
-
-  Tcl_DecrRefCount(objPtr);
-
-  return;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXSLTExtElementPreComp --
- *
- *  Compilation step for extension element.
- *
- * Results:
- *  Not currently used.
- *
- * Side effects:
- *  None.
- *
- *----------------------------------------------------------------------------
- */
-
-static void 
-TclXSLTExtElementPreComp(style, inst, function)
-    xsltStylesheetPtr style;
-    xmlNodePtr inst;
-    xsltTransformFunction function;
-{
-  return;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXSLTExtElementTransform --
- *
- *  Implements extension element.
- *
- * Results:
- *  Returns string returned by Tcl command evaluation.
- *
- * Side effects:
- *  Depends on Tcl command evaluated.
- *
- *----------------------------------------------------------------------------
- */
-
-static void 
-TclXSLTExtElementTransform(ctxt, node, inst, comp)
-    xsltTransformContextPtr ctxt; /* unused */
-    xmlNodePtr node;
-    xmlNodePtr inst;
-    xsltStylePreCompPtr comp; /* unused */
-{
-  ThreadSpecificData *tsdPtr = (ThreadSpecificData *) Tcl_GetThreadData(&dataKey, sizeof(ThreadSpecificData));
-  TclXSLT_Extension *extinfo;
-  Tcl_HashEntry *entry;
-  Tcl_Obj *cmdPtr;
-  int ret;
-
-  if (inst == NULL) {
-    return;
-  }
-
-  entry = Tcl_FindHashEntry(tsdPtr->extensions, (CONST char *) inst->ns->href);
-  if (entry == NULL) {
-    /*
-     * Cannot find extension module.
-     * Must have been removed.
-     */
-    return;
-  }
-
-  extinfo = (TclXSLT_Extension *) Tcl_GetHashValue(entry);
-
-  /*
-   * Start constructing the script by first defining the command.
-   */
-
-  cmdPtr = Tcl_DuplicateObj(extinfo->tclns);
-  Tcl_AppendStringsToObj(cmdPtr, "::", inst->name, NULL);
-
-  if (Tcl_ListObjAppendElement(extinfo->interp, cmdPtr, TclDOM_libxml2_CreateObjFromNode(extinfo->interp, node)) != TCL_OK) {
-    Tcl_DecrRefCount(cmdPtr);
-    return;
-  }
-
-  /*
-   * Converting the stylesheet node to a TclDOM node may clobber the
-   * _private pointer.  It would be nice to find the equivalent node
-   * in the original DOM tree, but it may not even exist anymore :-(
-   *
-   * TODO: make extension elements more effective, and allow
-   * pre-computation.
-   */
-
-  /*
-   * Now evaluate the complete command.
-   * Can't propagqte a return error result to
-   * XSLT, so flag background error instead.
-   */
-  ret = Tcl_EvalObjEx(extinfo->interp, cmdPtr, TCL_EVAL_GLOBAL | TCL_EVAL_DIRECT);
-  if (ret != TCL_OK) {
-    Tcl_BackgroundError(extinfo->interp);
-  }
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXSLTExtFunction --
- *
- *  Handles evaluation of an extension function.
- *
- * Results:
- *  Returns string returned by Tcl command evaluation.
- *
- * Side effects:
- *  Depends on Tcl command evaluated.
- *
- *----------------------------------------------------------------------------
- */
-
-static void 
-TclXSLTExtFunction(xpathCtxt, nargs)
-     xmlXPathParserContextPtr xpathCtxt;
-     int nargs;
-{
-  xsltTransformContextPtr xformCtxt;
-  TclXSLT_Extension *extinfo;
-  Tcl_Obj *cmdPtr, *resultPtr;
-  xmlXPathObjectPtr obj;
-  int ret;
-
-  Tcl_MutexLock(&libxslt);
-
-  xformCtxt = xsltXPathGetTransformContext(xpathCtxt);
-
-  /*
-   * In order to find the instance data we need the
-   * XML Namespace URI of this function.
-   */
-
-  extinfo = (TclXSLT_Extension *) xsltGetExtData(xformCtxt,
-						 xpathCtxt->context->functionURI);
-
-  /*
-   * Start constructing the script by first defining the command.
-   */
-
-  cmdPtr = Tcl_DuplicateObj(extinfo->tclns);
-  Tcl_IncrRefCount(cmdPtr);
-  Tcl_AppendStringsToObj(cmdPtr, "::", xpathCtxt->context->function, NULL);
-
-  /*
-   * Each argument on the stack is converted to a Tcl_Obj
-   * of an appropriate type and passed as an argument to the Tcl command.
-   */
-
-  while (nargs) {
-    Tcl_Obj *objv[2];
-
-    obj = (xmlXPathObjectPtr) valuePop(xpathCtxt);
-    if (obj == NULL) {
-      xmlXPathSetError(xpathCtxt, XPATH_INVALID_OPERAND);
-      Tcl_DecrRefCount(cmdPtr);
-      Tcl_MutexUnlock(&libxslt);
-      return;
-    }
-
-    objv[0] = TclXSLT_ConvertXPathObjToTclObj(extinfo->interp, obj);
-    objv[1] = NULL;
-    if (Tcl_ListObjReplace(extinfo->interp, cmdPtr, 1, 0, 1, objv) != TCL_OK) {
-      Tcl_BackgroundError(extinfo->interp);
-      Tcl_DecrRefCount(objv[0]);
-      Tcl_DecrRefCount(cmdPtr);
-      Tcl_MutexUnlock(&libxslt);
-      return;
-    }
-
-    /* When should this XPath object be freed?
-     * Immediately before returning from the function call?
-     * What if the application retains a pointer to it?
-     * If the application destroys the contents, then memory
-     * will leak because the XPath object is not freed.
-     *
-     * TODO: take a copy of the object's content and pass that
-     * to the application callback.  That would allow this object
-     * to be freed and allow the application to manage the copy.
-     
-     xmlXPathFreeObject(obj);
-     */
-
-    nargs--;
-  }
-
-  ret = Tcl_EvalObjEx(extinfo->interp, cmdPtr, TCL_EVAL_GLOBAL | TCL_EVAL_DIRECT);
-  resultPtr = Tcl_GetObjResult(extinfo->interp);
-  Tcl_DecrRefCount(cmdPtr);
-  Tcl_IncrRefCount(resultPtr);
-
-  if (ret == TCL_OK) {
-    obj = TclXSLT_ConvertTclObjToXPathObj(extinfo->interp, resultPtr);
-    valuePush(xpathCtxt, obj);
-  } else {
-    xmlGenericError(xmlGenericErrorContext,
-		    Tcl_GetStringFromObj(resultPtr, NULL));
-    /* Need to define a new error code - this is the closest in meaning */
-    xpathCtxt->error = XPATH_UNKNOWN_FUNC_ERROR;
-  }
-
-  Tcl_MutexUnlock(&libxslt);
-
-  Tcl_DecrRefCount(resultPtr);
-
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXSLT_ConvertTclObjToXPathObj --
- *
- *  Convert a Tcl Object to an XPath object.
- *  Data type is preserved, with nodesets being
- *  mapped from a list of nodes.
- *
- * NB. Mutex is assumed to be locked when invoking this routine.
- *
- * Results:
- *  XPath Object.
- *
- * Side effects:
- *  None.
- *
- *----------------------------------------------------------------------------
- */
-
-static xmlXPathObjectPtr
-TclXSLT_ConvertTclObjToXPathObj(interp, objPtr)
-     Tcl_Interp *interp;
-     Tcl_Obj *objPtr;
-{
-  xmlNodePtr nodePtr;
-  xmlDocPtr docPtr;
-
-  if (TclDOM_libxml2_GetNodeFromObj(interp, objPtr, &nodePtr) == TCL_OK) {
-    return xmlXPathNewNodeSet(nodePtr);
-  }
-  
-   if (TclXML_libxml2_GetDocFromObj(interp, objPtr, &docPtr) == TCL_OK) {
-    return xmlXPathNewNodeSet((xmlNodePtr) docPtr);
-
-  }
-  
-  if (objPtr->typePtr == Tcl_GetObjType("int") ||
-      objPtr->typePtr == Tcl_GetObjType("double")) {
-    double number;
-
-    if (Tcl_GetDoubleFromObj(interp, objPtr, &number) == TCL_OK) {
-      return xmlXPathNewFloat(number);
-    } else {
-      return NULL;
-    }
-  } else if (objPtr->typePtr == Tcl_GetObjType("boolean")) {
-    int bool;
-
-    if (Tcl_GetBooleanFromObj(interp, objPtr, &bool) == TCL_OK) {
-      return xmlXPathNewBoolean(bool);
-    } else {
-      return NULL;
-    }
-  } else if (objPtr->typePtr == Tcl_GetObjType("list")) {
-    /*
-     * If each of the elements can be converted to a node,
-     * then return a nodeset.
-     */
-
-    int i, len;
-    Tcl_Obj **listPtr;
-    xmlNodeSetPtr nset;
-
-    Tcl_ListObjGetElements(interp, objPtr, &len, &listPtr);
-    if (len == 0) {
-      return xmlXPathNewNodeSet(NULL);
-    }
-
-    /*
-     * First pass: check that the elements are all nodes.
-     */
-    for (i = 0; i < len; i++) {
-      if (TclXML_libxml2_GetDocFromObj(interp, listPtr[i], &docPtr) == TCL_OK) {
-        continue;
-      }
-      if (TclDOM_libxml2_GetNodeFromObj(interp, listPtr[i], &nodePtr) != TCL_OK) {
-        return xmlXPathNewString((const xmlChar *) Tcl_GetStringFromObj(objPtr, NULL));
-      }
-    }
-    /*
-     * Now go ahead and create the nodeset (we already did the hard
-     * work to create internal reps in pass 1).
-     */
-    if (TclXML_libxml2_GetDocFromObj(interp, listPtr[0], &docPtr) == TCL_OK) {
-      nset = xmlXPathNodeSetCreate((xmlNodePtr) docPtr);
-    } else {
-      TclDOM_libxml2_GetNodeFromObj(interp, listPtr[0], &nodePtr);
-      nset = xmlXPathNodeSetCreate(nodePtr);
-    }
-    for (i = 1; i < len; i++) {
-      if (TclXML_libxml2_GetDocFromObj(interp, listPtr[i], &docPtr) == TCL_OK) {
-        xmlXPathNodeSetAdd(nset, (xmlNodePtr) docPtr);
-      } else {
-        TclDOM_libxml2_GetNodeFromObj(interp, listPtr[i], &nodePtr);
-        xmlXPathNodeSetAdd(nset, nodePtr);
-      }
-    }
-    return xmlXPathWrapNodeSet(nset);
-
-  } else {
-    return xmlXPathNewString((const xmlChar *) Tcl_GetStringFromObj(objPtr, NULL));
-  }
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXSLT_ConvertXPathObjToTclObj --
- *
- *  Convert an XPath object to a Tcl Object.
- *  Data type is preserved, with nodesets being
- *  mapped to a list of nodes.
- *
- * Results:
- *  Tcl Object.
- *
- * Side effects:
- *  None.
- *
- *----------------------------------------------------------------------------
- */
-
-static Tcl_Obj *
-TclXSLT_ConvertXPathObjToTclObj(interp, xpobj)
-     Tcl_Interp *interp;
-     xmlXPathObjectPtr xpobj;
-{
-  Tcl_Obj *objPtr;
-  int i;
-
-  switch (xpobj->type) {
-    case XPATH_XSLT_TREE:
-    case XPATH_NODESET:
-
-      objPtr = Tcl_NewListObj(0, NULL);
-      if (xpobj->nodesetval) {
-	for (i = 0; i < xpobj->nodesetval->nodeNr; i++) {
-	  Tcl_Obj *nodeObjPtr = NULL;
-	  if (xpobj->nodesetval->nodeTab[i] &&
-	      xpobj->nodesetval->nodeTab[i]->type == XML_DOCUMENT_NODE) {
-	    nodeObjPtr = TclXML_libxml2_CreateObjFromDoc((xmlDocPtr) xpobj->nodesetval->nodeTab[i]);
-	  } else if (xpobj->nodesetval->nodeTab[i]) {
-	    nodeObjPtr = TclDOM_libxml2_CreateObjFromNode(interp, xpobj->nodesetval->nodeTab[i]);
-	  }
-	  Tcl_ListObjAppendElement(interp, objPtr, nodeObjPtr);
-	}
-      }
-
-      break;
-
-    case XPATH_BOOLEAN:
-      objPtr = Tcl_NewBooleanObj(xpobj->boolval);
-      break;
-      
-    case XPATH_NUMBER:
-      objPtr = Tcl_NewDoubleObj(xpobj->floatval);
-      break;
-
-    case XPATH_STRING:
-    case XPATH_UNDEFINED:
-    case XPATH_POINT:
-    case XPATH_RANGE:
-    case XPATH_LOCATIONSET:
-    case XPATH_USERS:
-    default:
-      objPtr = Tcl_NewStringObj((CONST char *) xmlXPathCastToString(xpobj), -1);
-
-      break;
-  }
-
-  return objPtr;
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXSLTExtShutdown --
- *
- *  Clean up.
- *
- * Results:
- *  None.
- *
- * Side effects:
- *  None.
- *
- *----------------------------------------------------------------------------
- */
-
-static void
-TclXSLTExtShutdown(ctxt, URI, userdata)
-     xsltTransformContextPtr ctxt;
-     const xmlChar *URI;
-     void *userdata;
-{
-  /* Nothing to do */
-}
-
-/*
- *----------------------------------------------------------------------------
- *
- * TclXSLTSecurity --
- * TclXSLTSecurityReadFile --
- * TclXSLTSecurityWriteFile --
- * TclXSLTSecurityCreateDirectory --
- * TclXSLTSecurityReadNetwork --
- * TclXSLTSecurityWriteNetwork --
- *
- *  Check if external operations are permitted.
- *
- * Results:
- *  Returns boolean value.
- *
- * Side effects:
- *  Depends on callback.
- *
- *----------------------------------------------------------------------------
- */
-
-static int
-TclXSLTSecurity(name, method, value)
-     Tcl_Obj *name;
-     const char *method;
-     const char *value;
-{
-  ThreadSpecificData *tsdPtr = (ThreadSpecificData *) Tcl_GetThreadData(&dataKey, sizeof(ThreadSpecificData));
-  Tcl_Interp *master;
-  Tcl_Obj *cmdPtr, *pathPtr;
-  int result, permitted;
-
-  if (Tcl_IsSafe(tsdPtr->interp)) {
-
-    /*
-     * Invoke hidden command
-     */
-
-    master = Tcl_GetMaster(tsdPtr->interp);
-
-    if (!Tcl_IsSafe(master)) {
-      return 0;
-    }
-
-    if (Tcl_GetInterpPath(master, tsdPtr->interp) != TCL_OK) {
-      return 0;
-    }
-    pathPtr = Tcl_GetObjResult(master);
-
-    cmdPtr = Tcl_NewListObj(0, NULL);
-    Tcl_IncrRefCount(cmdPtr);
-    Tcl_ListObjAppendElement(master, cmdPtr, Tcl_NewStringObj("interp", -1));
-    Tcl_ListObjAppendElement(master, cmdPtr, Tcl_NewStringObj("invokehidden", -1));
-    Tcl_ListObjAppendElement(master, cmdPtr, pathPtr);
-    Tcl_ListObjAppendElement(master, cmdPtr, Tcl_NewStringObj("-global", -1));
-    Tcl_ListObjAppendElement(master, cmdPtr, Tcl_NewStringObj("::xslt::security", -1));
-    Tcl_ListObjAppendElement(master, cmdPtr, name);
-    Tcl_ListObjAppendElement(master, cmdPtr, Tcl_NewStringObj(method, -1));
-    Tcl_ListObjAppendElement(master, cmdPtr, Tcl_NewStringObj(value, -1));
-
-    result = Tcl_EvalObjEx(master, cmdPtr, TCL_EVAL_GLOBAL|TCL_EVAL_DIRECT);
-
-    Tcl_DecrRefCount(cmdPtr);
-  } else {
-
-    /*
-     * Invoke command normally
-     */
-
-    cmdPtr = Tcl_NewListObj(0, NULL);
-    Tcl_IncrRefCount(cmdPtr);
-    Tcl_ListObjAppendElement(tsdPtr->interp, cmdPtr, Tcl_NewStringObj("::xslt::security", -1));
-    Tcl_ListObjAppendElement(tsdPtr->interp, cmdPtr, name);
-    Tcl_ListObjAppendElement(tsdPtr->interp, cmdPtr, Tcl_NewStringObj(method, -1));
-    Tcl_ListObjAppendElement(tsdPtr->interp, cmdPtr, Tcl_NewStringObj(value, -1));
-
-    result = Tcl_EvalObjEx(tsdPtr->interp, cmdPtr, TCL_EVAL_GLOBAL|TCL_EVAL_DIRECT);
-
-    Tcl_DecrRefCount(cmdPtr);
-  }
-
-  if (result == TCL_OK) {
-    if (Tcl_GetBooleanFromObj(tsdPtr->interp, Tcl_GetObjResult(tsdPtr->interp), &permitted) == TCL_OK) {
-      return permitted;
-    } else if (Tcl_IsSafe(tsdPtr->interp)) {
-      return 0;
-    } else {
-      return 1;
-    }
-  } else if (Tcl_IsSafe(tsdPtr->interp)) {
-    return 0;
-  } else {
-    return 1;
-  }
-}
-static Tcl_Obj *
-TclXSLTSecurityGetName(ctxt)
-     xsltTransformContextPtr ctxt;
-{
-  ThreadSpecificData *tsdPtr = (ThreadSpecificData *) Tcl_GetThreadData(&dataKey, sizeof(ThreadSpecificData));
-  Tcl_HashEntry *entryPtr;
-
-  if (ctxt) {
-    entryPtr = Tcl_FindHashEntry(tsdPtr->stylesheets, (ClientData) ctxt->style);
-    if (entryPtr) {
-      return Tcl_NewStringObj((char *) Tcl_GetHashValue(entryPtr), -1);
-    } else {
-      return Tcl_NewObj();
-    }
-  } else {
-    return Tcl_NewObj();
-  }
-}
-static int
-TclXSLTSecurityReadFile(sec, ctxt, value)
-     xsltSecurityPrefsPtr sec;
-     xsltTransformContextPtr ctxt;
-     const char *value;
-{
-  return TclXSLTSecurity(TclXSLTSecurityGetName(ctxt), "readfile", value);
-}
-static int
-TclXSLTSecurityWriteFile(sec, ctxt, value)
-     xsltSecurityPrefsPtr sec;
-     xsltTransformContextPtr ctxt;
-     const char *value;
-{
-  return TclXSLTSecurity(TclXSLTSecurityGetName(ctxt), "writefile", value);
-}
-static int
-TclXSLTSecurityCreateDirectory(sec, ctxt, value)
-     xsltSecurityPrefsPtr sec;
-     xsltTransformContextPtr ctxt;
-     const char *value;
-{
-  return TclXSLTSecurity(TclXSLTSecurityGetName(ctxt), "createdirectory", value);
-}
-static int
-TclXSLTSecurityReadNetwork(sec, ctxt, value)
-     xsltSecurityPrefsPtr sec;
-     xsltTransformContextPtr ctxt;
-     const char *value;
-{
-  return TclXSLTSecurity(TclXSLTSecurityGetName(ctxt), "readnetwork", value);
-}
-static int
-TclXSLTSecurityWriteNetwork(sec, ctxt, value)
-     xsltSecurityPrefsPtr sec;
-     xsltTransformContextPtr ctxt;
-     const char *value;
-{
-  return TclXSLTSecurity(TclXSLTSecurityGetName(ctxt), "writenetwork", value);
-}
diff --git a/tclxml-3.2/tclxslt-libxslt.tcl b/tclxml-3.2/tclxslt-libxslt.tcl
deleted file mode 100644
index e67d02a..0000000
--- a/tclxml-3.2/tclxslt-libxslt.tcl
+++ /dev/null
@@ -1,30 +0,0 @@
-# tclxslt.tcl --
-#
-#	Tcl library for TclXSLT package.
-#
-# Copyright (c) 2001-2003 Zveno Pty Ltd
-# http://www.zveno.com/
-#
-# See the file "LICENSE" in this distribution for information on usage and
-# redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
-#
-# $Id: tclxslt-libxslt.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-namespace eval xslt {
-    namespace export getprocs
-}
-
-proc xslt::getprocs ns {
-    set functions {}
-    set elements {}
-    foreach proc [info commands ${ns}::*] {
-	if {[regexp {::([^:]+)$} $proc discard name]} {
-	    if {[string equal [lindex [info args $proc] end] "args"]} {
-		lappend functions $name
-	    } else {
-		lappend elements $name
-	    }
-	}
-    }
-    return [list $elements $functions]
-}
diff --git a/tclxml-3.2/tclxslt/process.tcl b/tclxml-3.2/tclxslt/process.tcl
deleted file mode 100644
index d38e5fb..0000000
--- a/tclxml-3.2/tclxslt/process.tcl
+++ /dev/null
@@ -1,312 +0,0 @@
-# process.tcl --
-#
-#	XSLT extension providing processing functions
-#
-# Copyright (c) 2007 Packaged Press
-# http://www.packagedpress.com/
-# Copyright (c) 2002-2004 Zveno Pty Ltd
-# http://www.zveno.com/
-#
-# See the file "LICENSE" in this distribution for information on usage and
-# redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
-#
-# $Id: process.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package provide xslt::process 1.1
-
-package require uri 1.1
-package require xslt::cache 3.2
-
-namespace eval xslt::process {
-    namespace export transform fop
-    namespace export transform-result
-    namespace export dtd-valid
-}
-
-# Add support for the dom: URI scheme.
-#
-# This scheme allows a script to reference an in-memory DOM tree.
-
-proc ::uri::SplitDom url {
-    return [list dom $url]
-}
-
-proc ::uri::JoinDom args {
-    array set components {
-	dom {}
-    }
-    array set components $args
-
-    return dom:$components(dom)
-}
-
-# xslt::process::transform --
-#
-#	Perform an XSL Transformation.
-#
-# TODO:
-#	Return messages
-#	Cache source and stylesheet documents.
-#	Generate dependency documents.
-#
-# Arguments:
-#	src	Location of source document
-#	ssheet	Location of stylesheet
-#	result	Location for result document
-#	params	Parameters (nodelist)
-#	args	not needed
-#
-# Results:
-#	Returns empty string for success
-
-# This version forks a process
-proc xslt::process::transform_fork {src ssheet result {params {}} args} {
-    if {[catch {exec tclxsltproc -config /Users/steve/scms/lib/config.tcl --xinclude -o $result $ssheet $src} out]} {
-	return $out
-    } else {
-	return {}
-    }
-}
-
-# This version performs the transformation in-process.
-proc xslt::process::transform:dbg {src ssheet result {params {}} args} {
-    puts stderr [list process::transform $src $ssheet $result $params $args]
-    if {[catch {eval transform:dbg [list $src $ssheet $result] $params $args} msg]} {
-	puts stderr "\nprocess::transform returned error $msg\nStack trace:$::errorInfo\n"
-	return -code error $msg
-    } else {
-	puts stderr [list process::transform ran OK]
-	return $msg
-    }
-}
-proc xslt::process::transform {srcNd ssheetNd resultNd {params {}} args} {
-
-    # The filenames may be passed in as nodesets
-    set src $srcNd
-    catch {set src [dom::node stringValue [lindex $srcNd 0]]}
-    set ssheet $ssheetNd
-    catch {set ssheet [dom::node stringValue [lindex $ssheetNd 0]]}
-    set result $resultNd
-    catch {set result [dom::node stringValue [lindex $resultNd 0]]}
-
-    # params will be a nodeset consisting of name/value pairs.
-    # These must be converted to strings
-    set parameterList {}
-    switch [llength $params] {
-	1 {
-	    puts stderr [list xslt::process::transform params nodeType [dom::node cget $params -nodeType]]
-	    set pNdList [dom::node children $params]
-	}
-	default {
-	    set pNdList $params
-	}
-    }
-    foreach paramNd $pNdList {
-	set name [set value {}]
-	foreach child [dom::node children $paramNd] {
-	    set nameNd [dom::node selectNode $child name]
-	    set name [dom::node stringValue $nameNd]
-	    set valueNd [dom::node selectNode $child value]
-	    set value [dom::node stringValue $valueNd]
-	}
-	if {[string compare $name {}]} {
-	    lappend parameterList $name $value
-	}
-    }
-
-    puts stderr [list xslt::process::transform parameters: $parameterList]
-
-    set cleanup {}
-
-    if {[catch {open $src} ch]} {
-	# eval $cleanup
-	return "unable to open source document \"$src\" for reading due to \"$ch\""
-    }
-    if {[catch {::dom::parse [read $ch] -baseuri $src} sourcedoc]} {
-	# eval $cleanup
-	return "unable to parse source document \"$src\" due to \"$sourcedoc\""
-    }
-    close $ch
-
-    append cleanup "dom::destroy $sourcedoc" \n
-
-    dom::xinclude $sourcedoc
-
-    if {[catch {open $ssheet} ch]} {
-	eval $cleanup
-	return "unable to open stylesheet document \"$ssheet\" for reading due to \"$ch\""
-    }
-    if {[catch {::dom::parse [read $ch] -baseuri $ssheet} styledoc]} {
-	eval $cleanup
-	return "unable to parse stylesheet document \"$ssheet\" due to \"$styledoc\""
-    }
-    close $ch
-
-    append cleanup "dom::destroy $styledoc" \n
-
-    if {[catch {xslt::compile $styledoc} style]} {
-	eval $cleanup
-	return "unable to compile stylesheet \"$ssheet\" due to \"$style\""
-    }
-
-    append cleanup "rename $style {}" \n
-
-    if {[catch {eval [list $style] transform [list $sourcedoc] $parameterList} resultdoc]} {
-	eval $cleanup
-	return "unable to transform document \"$src\" with stylesheet \"$ssheet\" due to \"$resultdoc\""
-    }
-
-    append cleanup "dom::destroy $resultdoc" \n
-
-    if {[catch {open $result w} ch]} {
-	eval $cleanup
-	return "unable to save result document \"$result\" due to \"$ch\""
-    }
-
-    puts $ch [dom::serialize $resultdoc -method [$style cget -method]]
-    close $ch
-
-    catch {
-	uplevel \#0 $cleanup
-    }
-
-    return {}
-}
-
-# xslt::process::transform-result --
-#
-#	Perform an XSL Transformation.
-#	This version returns the result document.
-#
-# Arguments:
-#	src	Location of source document
-#	ssheet	Location of stylesheet
-#	params	Parameters (nodelist)
-#	args	not needed
-#
-# Results:
-#	Returns result document.
-
-proc xslt::process::transform-result {srcNd ssheetNd {params {}} args} {
-
-    # The filenames may be passed in as nodesets
-    set src $srcNd
-    catch {set src [dom::node stringValue [lindex $srcNd 0]]}
-    set ssheet $ssheetNd
-    catch {set ssheet [dom::node stringValue [lindex $ssheetNd 0]]}
-
-    # params will be a nodeset consisting of name/value pairs.
-    # These must be converted to strings
-    set parameterList {}
-    foreach paramNd $params {
-	set name [set value {}]
-	foreach child [dom::node children $paramNd] {
-	    set nameNd [dom::node selectNode $child name]
-	    set name [dom::node stringValue $nameNd]
-	    set valueNd [dom::node selectNode $child value]
-	    set value [dom::node stringValue $valueNd]
-	}
-	if {[string compare $name {}]} {
-	    lappend parameterList $name $value
-	}
-    }
-
-    if {[catch {eval xslt::cache::transform [list $src $ssheet] $parameterList} rd]} {
-	return "unable to perform transformation due to \"$rd\""
-    }
-
-    return $rd
-}
-
-# xslt::process::checkwffdoc --
-#
-#	Test a document for well-formedness
-#
-# Arguments:
-#	doc	DOM token for document to check
-#	args	not needed
-#
-# Results:
-#	Returns success message
-
-proc xslt::process::checkwffdoc {doc args} {
-    return "of course it's well-formed, it's a DOM tree!"
-}
-
-# xslt::process::dtd-valid --
-#
-#	Test a document for (DTD) validity
-#
-# Arguments:
-#	uri	URI for document to check, supports dom: scheme
-#	args	not needed
-#
-# Results:
-#	Returns success/failure message
-
-proc xslt::process::dtd-valid {uri args} {
-    array set components [uri::split $uri]
-
-    switch -- $components(scheme) {
-	file {
-	    set ch [open $components(path)]
-	    set xmldata [read $ch]
-	    close $ch
-	    set doc [dom::parse $xmldata -baseuri $uri]
-	    set cleanup [list dom::destroy $doc]
-	}
-	dom {
-	    set doc $components(dom)
-	    set cleanup {}
-	}
-	default {
-	    # TODO: support http: scheme
-	    return -code error "unable to resolve entity $uri"
-	}
-    }
-
-    if {[catch {dom::validate $doc} msg]} {
-	set result $msg
-    } else {
-	set result {document is valid}
-    }
-
-    eval $cleanup
-
-    return $result
-}
-
-# xslt::process::fop --
-#
-#	Format an XSL FO document using FOP
-#
-# Arguments:
-#	fo	Location of FO document
-#	pdf	Location for PDF document
-#	params	Parameters (nodelist)
-#	args	not needed
-#
-# Results:
-#	Returns success message
-
-proc xslt::process::fop {fo pdf params args} {
-    return "format fo $fo to produce $pdf"
-}
-
-# xslt::process::log --
-#
-#	Emit a log message.  The application is expected to override this.
-#
-# Arguments:
-#	msg	Log message
-#	args	not needed
-#
-# Results:
-#	None
-
-proc xslt::process::log {msg args} {
-    Stderr Log:\ $msg
-    return {}
-}
-
-
diff --git a/tclxml-3.2/tclxslt/resources.tcl b/tclxml-3.2/tclxslt/resources.tcl
deleted file mode 100644
index b107a77..0000000
--- a/tclxml-3.2/tclxslt/resources.tcl
+++ /dev/null
@@ -1,388 +0,0 @@
-# resources.tcl --
-#
-#	XSLT extension providing access to resources.
-#
-# Copyright (c) 2005-2008 Explain
-# http://www.explain.com.au/
-# Copyright (c) 2001-2004 Zveno Pty Ltd
-# http://www.zveno.com/
-#
-# See the file "LICENSE" in this distribution for information on usage and
-# redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
-#
-# $Id: resources.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-catch {
-    package require base64
-}
-
-package provide xslt::resources 1.3
-
-namespace eval xslt::resources {
-    namespace export list type exists modified
-}
-
-# xslt::resources::list --
-#
-#	List the resources available at a given location
-#
-# Arguments:
-#	locn	Resource path to list
-#	basedir	Base directory
-#	args	not needed
-#
-# Results:
-#	Returns list of resources
-
-proc xslt::resources::list {locnNd {baseNd {}} args} {
-    # What kind of resource is this?  file, http, ftp, etc?
-
-    if {[llength $args]} {
-	return -code error "too many arguments"
-    }
-
-    set locn $locnNd
-    # The resource may be passed in as a nodeset
-    catch {set locn [dom::node stringValue [lindex $locnNd 0]]}
-    set base $baseNd
-    catch {set base [dom::node stringValue [lindex $baseNd 0]]}
-
-    if {[string match /* $base]} {
-	regsub {^(/)} $locn {} locn
-    }
-
-    set result {}
-    foreach entry [glob -nocomplain [file join $base $locn *]] {
-	lappend result [file tail $entry]
-    }
-
-    return $result
-}
-
-# xslt::resources::type --
-#
-#	Gives the type of the resource
-#
-# Arguments:
-#	locn	Resource path to type
-#	args	not needed
-#
-# Results:
-#	Returns string describing resource
-
-proc xslt::resources::type {locnNd args} {
-
-    if {[llength $args]} {
-	return -code error "too many arguments"
-    }
-
-    set locn $locnNd
-    catch {set locn [dom::node stringValue [lindex $locnNd 0]]}
-
-    if {[file isdir $locn]} {
-	return directory
-    } elseif {[file isfile $locn]} {
-	return file
-    } else {
-	return other
-    }
-}
-
-# xslt::resources::exists --
-#
-#	Check whether a resource exists
-#
-# Arguments:
-#	locn	Resource path to type
-#	args	not needed
-#
-# Results:
-#	Returns boolean
-
-proc xslt::resources::exists {locnNd args} {
-
-    if {[llength $args]} {
-	return -code error "too many arguments"
-    }
-
-    set locn $locnNd
-    catch {set locn [dom::node stringValue [lindex $locnNd 0]]}
-
-    if {[file exists $locn]} {
-	return 1
-    } else {
-	return 0
-    }
-}
-
-# xslt::resources::modified --
-#
-#	Report last modification time of a resource
-#
-# Arguments:
-#	locn	Resource path
-#	args	not needed
-#
-# Results:
-#	Returns ISO standard date-time string
-
-proc xslt::resources::modified {locnNd args} {
-
-    if {[llength $args]} {
-	return -code error "too many arguments"
-    }
-
-    set locn $locnNd
-    catch {set locn [dom::node stringValue [lindex $locnNd 0]]}
-
-    if {[file exists $locn]} {
-	return [clock format [file mtime $locn] -format {%Y-%m-%dT%H:%M:%S}]
-    } else {
-	return {}
-    }
-}
-
-# xslt::resources::mkdir --
-#
-#	Create a directory hierarchy.
-#
-# Arguments:
-#	locn	Resource path for directory
-#	args	not needed
-#
-# Results:
-#	Returns directory created or empty string if unsuccessful
-
-proc xslt::resources::mkdir {locnNd args} {
-
-    if {[llength $args]} {
-	return {}
-    }
-
-    set locn $locnNd
-    catch {set locn [dom::node stringValue [lindex $locnNd 0]]}
-
-    set dir [file split $locn]
-    set current [lindex $dir 0]
-    set remaining [lrange $dir 1 end]
-    while {[llength $remaining]} {
-	set current [file join $current [lindex $remaining 0]]
-	set remaining [lrange $remaining 1 end]
-	if {[file exists $current]} {
-	    if {![file isdir $current]} {
-		return {}
-	    }
-	} elseif {[file isdir $current]} {
-	    continue
-	} else {
-	    if {[catch {file mkdir $current}]} {
-		return {}
-	    }
-	}
-    }
-
-    return $locn
-}
-
-# xslt::resources::copy --
-#
-#	Copy a resource.
-#
-# Arguments:
-#	src	Resource to copy
-#	dest	Destination for resource
-#	args	not needed
-#
-# Results:
-#	Resource copied
-
-proc xslt::resources::copy {srcNd destNd args} {
-    set src $srcNd
-    catch {set src [dom::node stringValue [lindex $srcNd 0]]}
-    set dest $destNd
-    catch {set dest [dom::node stringValue [lindex $destNd 0]]}
-
-    if {[catch {file copy -force $src $dest} msg]} {
-	catch {
-	    package require log
-	    log::log error "copy failed due to \"$msg\""
-	}
-	return 0
-    } else {
-	return 1
-    }
-}
-
-# xslt::resources::move --
-#
-#	Move (rename) a resource.
-#
-# Arguments:
-#	src	Resource to move
-#	dest	Destination for resource
-#	args	not needed
-#
-# Results:
-#	Resource renamed
-
-proc xslt::resources::move {srcNd destNd args} {
-    set src $srcNd
-    catch {set src [dom::node stringValue [lindex $srcNd 0]]}
-    set dest $destNd
-    catch {set dest [dom::node stringValue [lindex $destNd 0]]}
-
-    if {[catch {file rename -force $src $dest}]} {
-	return 0
-    } else {
-	return 1
-    }
-}
-
-# xslt::resources::file-attributes --
-#
-#	Change attributes of a resource.
-#
-# Arguments:
-#	src	Resource to change
-#	what	Attribute to change
-#	detail	Attribute value
-#	args	not needed
-#
-# Results:
-#	Resource attribute changed
-
-proc xslt::resources::file-set-attributes {srcNd whatNd detailNd args} {
-    set src $srcNd
-    catch {set src [dom::node stringValue [lindex $srcNd 0]]}
-    set what $whatNd
-    catch {set what [dom::node stringValue [lindex $whatNd 0]]}
-    set detail $detailNd
-    catch {set detail [dom::node stringValue [lindex $detailNd 0]]}
-
-    if {[catch {file attributes $src -$what $detail} result]} {
-	return {}
-    } else {
-	return $result
-    }
-}
-
-# xslt::resources::delete --
-#
-#	Delete a resource
-#
-# Arguments:
-#	locn	Resource path to type
-#	args	not needed
-#
-# Results:
-#	Returns boolean
-
-proc xslt::resources::delete {locnNd args} {
-
-    if {[llength $args]} {
-	return -code error "too many arguments"
-    }
-
-    set locn $locnNd
-    catch {set locn [dom::node stringValue [lindex $locnNd 0]]}
-
-    if {[catch {file delete -force $locn} msg]} {
-	catch {
-	    package require log
-	    log::log error "delete failed due to \"$msg\""
-	}
-	return 0
-    } else {
-	return 1
-    }
-}
-
-# xslt::resources::link --
-#
-#	Link a resource.
-#
-# Arguments:
-#	from	Link to create
-#	to	Target of link
-#	args	not needed
-#
-# Results:
-#	Symbolic link created
-
-proc xslt::resources::link {fromNd toNd args} {
-    set from $fromNd
-    catch {set from [dom::node stringValue [lindex $fromNd 0]]}
-    set to $toNd
-    catch {set to [dom::node stringValue [lindex $toNd 0]]}
-
-    if {[catch {file link $from $to}]} {
-	return 0
-    } else {
-	return 1
-    }
-}
-
-# xslt::resources::write-base64 --
-#
-#	Decode base64 encoded data and write the binary data to a file
-#
-# Arguments:
-#	fname	Filename
-#	b64	base64 encoded data
-#	args	not needed
-#
-# Results:
-#	File opened for writing and binary data written.
-#	Returns 1 if file successfully written, 0 otherwise.
-
-proc xslt::resources::write-base64 {fnameNd b64Nd args} {
-    set fname $fnameNd
-    catch {set fname [dom::node stringValue [lindex $fnameNd 0]]}
-    set b64 $b64Nd
-    catch {set b64 [dom::node stringValue [lindex $b64Nd 0]]}
-
-    if {[catch {package require base64}]} {
-	return 0
-    }
-
-    if {[catch {open $fname w} ch]} {
-	return 0
-    } else {
-	set binarydata [base64::decode $b64]
-	fconfigure $ch -trans binary -encoding binary
-	puts -nonewline $ch $binarydata
-	close $ch
-	return 1
-    }
-}
-
-# xslt::resources::read-base64 --
-#
-#	Read binary data from a file and base64 encode it
-#
-# Arguments:
-#	fname	Filename
-#	args	not needed
-#
-# Results:
-#	File opened for readng and contents read.
-#	Returns content as base64-encoded data.
-
-proc xslt::resources::read-base64 {fnameNd args} {
-    set fname $fnameNd
-    catch {set fname [dom::node stringValue [lindex $fnameNd 0]]}
-
-    if {[catch {package require base64}]} {
-	return 0
-    }
-
-    if {[catch {open $fname} ch]} {
-	return 0
-    } else {
-	fconfigure $ch -trans binary -encoding binary
-	set binarydata [read $ch]
-	close $ch
-	return [base64::encode $binarydata]
-    }
-}
-
diff --git a/tclxml-3.2/tclxslt/tclxslt.tcl b/tclxml-3.2/tclxslt/tclxslt.tcl
deleted file mode 100644
index 6aa6a2c..0000000
--- a/tclxml-3.2/tclxslt/tclxslt.tcl
+++ /dev/null
@@ -1,30 +0,0 @@
-# tclxslt.tcl --
-#
-#	Tcl library for TclXSLT package.
-#
-# Copyright (c) 2001-2003 Zveno Pty Ltd
-# http://www.zveno.com/
-#
-# See the file "LICENSE" in this distribution for information on usage and
-# redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
-#
-# $Id: tclxslt.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-namespace eval xslt {
-    namespace export getprocs
-}
-
-proc xslt::getprocs ns {
-    set functions {}
-    set elements {}
-    foreach proc [info commands ${ns}::*] {
-	if {[regexp {::([^:]+)$} $proc discard name]} {
-	    if {[string equal [lindex [info args $proc] end] "args"]} {
-		lappend functions $name
-	    } else {
-		lappend elements $name
-	    }
-	}
-    }
-    return [list $elements $functions]
-}
diff --git a/tclxml-3.2/tclxslt/utilities.tcl b/tclxml-3.2/tclxslt/utilities.tcl
deleted file mode 100644
index 8459598..0000000
--- a/tclxml-3.2/tclxslt/utilities.tcl
+++ /dev/null
@@ -1,144 +0,0 @@
-# utilities.tcl --
-#
-#	Miscellaneous extension functions for XSLT.
-#
-# Copyright (c) 2007 Explain
-# http://www.explain.com.au/
-# Copyright (c) 2004 Zveno Pty Ltd
-# http://www.zveno.com/
-#
-# See the file "LICENSE" in this distribution for information on usage and
-# redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
-#
-# $Id: utilities.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package provide xslt::utilities 1.2
-
-namespace eval xslt::utilities {
-    namespace export character-first decode-base64
-}
-
-# xslt::utilities::character-first --
-#
-#	Returns the character that occurs first from a string
-#	of possible characters.
-#
-# Arguments:
-#	src	source string
-#	chars	characters to find
-#	args	not needed
-#
-# Results:
-#	Returns a character or empty string.
-
-proc xslt::utilities::character-first {srcNd charsNd args} {
-    if {[llength $args]} {
-	return -code error "too many arguments"
-    }
-
-    set src $srcNd
-    catch {set src [dom::node stringValue [lindex $srcNd 0]]}
-    set chars $charsNd
-    catch {set chars [dom::node stringValue [lindex $charsNd 0]]}
-
-    regsub -all {([\\\[\]^$-])} $chars {\\\1} chars
-    if {[regexp [format {([%s])} $chars] $src dummy theChar]} {
-	return $theChar
-    }
-
-    return {}
-}
-
-# xslt::utilities::decode-base64 --
-#
-#	Returns decoded (binary) base64-encoded data.
-#
-# Arguments:
-#	src	source string
-#	args	not needed
-#
-# Results:
-#	Returns binary data.
-
-proc xslt::utilities::decode-base64 {srcNd args} {
-    if {[llength $args]} {
-	return -code error "too many arguments"
-    }
-
-    if {[catch {package require base64}]} {
-	return {}
-    }
-
-    set src $srcNd
-    catch {set src [dom::node stringValue [lindex $srcNd 0]]}
-
-    return [base64::decode $src]
-}
-
-# xslt::utilities::binary-document --
-#
-#	Writes binary data into a document
-#	(this should be an extension element)
-#
-# Arguments:
-#	fname	filename
-#	data	binary data
-#	args	not needed
-#
-# Results:
-#	File opened for writing and data written.
-#	Returns 1 on success, 0 otherwise
-
-proc xslt::utilities::binary-document {fnameNd srcNd args} {
-    if {[llength $args]} {
-	return -code error "too many arguments"
-    }
-
-    set fname $fnameNd
-    catch {set fname [dom::node stringValue [lindex $fnameNd 0]]}
-    set data $dataNd
-    catch {set data [dom::node stringValue [lindex $dataNd 0]]}
-
-    if {[catch {open $fname w} ch]} {
-	return 0
-    }
-    fconfigure $ch -trans binary -encoding binary
-    puts -nonewline $ch $data
-    close $ch
-
-    return 1
-}
-
-# xslt::utilities::base64-binary-document --
-#
-#	Returns base64-encoded data from a file.
-#
-# Arguments:
-#	fname	filename
-#	args	not needed
-#
-# Results:
-#	Returns text.  Returns empty string on error.
-
-proc xslt::utilities::base64-binary-document {fnameNd args} {
-    if {[llength $args]} {
-	return -code error "too many arguments"
-    }
-
-    if {[catch {package require base64}]} {
-	return {}
-    }
-
-    set fname $fnameNd
-    catch {set fname [dom::node stringValue [lindex $fnameNd 0]]}
-
-    if {[catch {open $fname} ch]} {
-	return {}
-    }
-    fconfigure $ch -trans binary -encoding binary
-    set data [read $ch]
-    close $ch
-
-    return [base64::encode $data]
-}
-
diff --git a/tclxml-3.2/tclxslt/xsltcache.tcl b/tclxml-3.2/tclxslt/xsltcache.tcl
deleted file mode 100644
index 9a3d8f7..0000000
--- a/tclxml-3.2/tclxslt/xsltcache.tcl
+++ /dev/null
@@ -1,379 +0,0 @@
-# xsltcache.tcl --
-#
-#	Handles performing XSLT transformations,
-#	caching documents and results.
-#
-# Copyright (c) 2005-2007 Steve Ball
-# http://www.packagedpress.com/staff/Steve.Ball
-# Copyright (c) 2002-2003 Zveno Pty Ltd
-# http://www.zveno.com/
-#
-# See the file "LICENSE" in this distribution for information on usage and
-# redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
-#
-# $Id: xsltcache.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require xslt 3.2
-package require uri
-
-package provide xslt::cache 3.2
-
-namespace eval xslt::cache {
-    namespace export transform transformdoc flush
-    namespace export parse_depend
-    namespace export loadstylesheet
-
-    variable sources
-    array set sources {}
-    variable stylesheets
-    array set stylesheets {}
-    variable results
-    array set results {}
-}
-
-# xslt::cache::transform --
-#
-#	Perform an XSLT transformation.
-#
-# Arguments:
-#	src	Filename of source document
-#	ssheet	Filename of stylesheet document
-#	args	Configuration options, stylesheet parameters
-#
-# Results:
-#	Result document token
-
-proc xslt::cache::transform {src ssheet args} {
-    variable sources
-    variable stylesheets
-    variable results
-
-    # Separate parameters from options
-    set parameters {}
-    set options {}
-    foreach {key value} $args {
-	switch -glob -- $key {
-	    -* {
-		lappend options $key $value
-	    }
-	    default {
-		lappend parameters $key $value
-	    }
-	}
-    }
-
-    # Normalize the parameter list
-    array set paramArray $parameters
-    set parameters {}
-    foreach name [lsort [array names paramArray]] {
-	lappend parameters $name $paramArray($name)
-    }
-
-    set hash $src.$ssheet.$parameters
-
-    array set opts {
-	-xmlinclude 1
-    }
-    array set opts $options
-
-    set readSource [ReadXML $src -xmlinclude $opts(-xmlinclude)]
-
-    set readStylesheet 1
-    if {[info exists stylesheets($ssheet)]} {
-	if {[file mtime $ssheet] < $stylesheets($ssheet,time)} {
-	    set readStylesheet 0
-	}
-    }
-    if {$readStylesheet} {
-	catch {rename $stylesheets($ssheet) {}}
-	ReadXML $ssheet -xmlinclude $opts(-xmlinclude)
-
-	set stylesheets($ssheet) [xslt::compile $sources($ssheet)]
-	set stylesheets($ssheet,time) [clock seconds]
-    }
-
-    if {$readSource || $readStylesheet || ![info exists results($hash)]} {
-
-	set results($hash) [eval [list $stylesheets($ssheet)] transform [list $sources($src)] $parameters]
-	set results($hash,time) [clock seconds]
-    }
-
-    return $results($hash)
-}
-
-# xslt::cache::loadstylesheet --
-#
-#	Read, parse and compile an XSLT stylesheet.
-#
-# Arguments:
-#	src	Filename for the stylesheet document
-#	args	options
-#
-# Results:
-#	Returns compiled stylesheet token.  Adds reference to stylesheet to cache.
-
-proc xslt::cache::loadstylesheet {src args} {
-    variable sources
-    variable stylesheets
-
-    array set options {
-	-keepsource 0
-	-xmlinclude 0
-    }
-    array set options $args
-
-    eval ReadXML [list $src] [array get options -xmlinclude]
-
-    set stylesheets($src) [xslt::compile $sources($src)]
-    set stylesheets($src,time) [clock seconds]
-
-    if {!$options(-keepsource)} {
-	flush $src {}
-    }
-
-    # TODO: set command trace so that if the stylesheet is deleted
-    # the cache is invalidated
-
-    return $stylesheets($src)
-}
-
-# xslt::cache::ReadXML --
-#
-#	Internal proc to manage parsing a document.
-#	Used for both source and stylesheet documents.
-#
-# Arguments:
-#	src	Filename of source document
-#	args	Configuration options
-#
-# Results:
-#	Returns 1 if document was read.  Returns 0 if document is cached.
-
-proc xslt::cache::ReadXML {src args} {
-    variable sources
-    array set opts {
-	-xmlinclude 1
-    }
-    array set opts $args
-
-    set readSource 1
-    if {[info exists sources($src)]} {
-	if {[file mtime $src] < $sources($src,time)} {
-	    set readSource 0
-	}
-    }
-    if {$readSource} {
-	catch {dom::destroy $sources($src)}
-	set ch [open $src]
-	set sources($src) [dom::parse [read $ch] -baseuri file://$src]
-	close $ch
-	if {$opts(-xmlinclude)} {
-	    dom::xinclude $sources($src)
-	}
-	set sources($src,time) [clock seconds]
-    }
-
-    return $readSource
-}
-
-# xslt::cache::transformdoc --
-#
-#	Perform an XSLT transformation on a DOM document.
-#
-# Arguments:
-#	src	DOM token of source document
-#	ssheet	Filename of stylesheet document
-#	args	Configuration options, stylesheet parameters
-#
-# Results:
-#	Result document token
-
-proc xslt::cache::transformdoc {src ssheet args} {
-    variable sources
-    variable stylesheets
-
-    # Separate parameters from options
-    set parameters {}
-    set options {}
-    foreach {key value} $args {
-	switch -glob -- $key {
-	    -* {
-		lappend options $key $value
-	    }
-	    default {
-		lappend parameters $key $value
-	    }
-	}
-    }
-
-    # Normalize the parameter list
-    array set paramArray $parameters
-    set parameters {}
-    foreach name [lsort [array names paramArray]] {
-	lappend parameters $name $paramArray($name)
-    }
-
-    array set opts {
-	-xmlinclude 1
-    }
-    array set opts $options
-
-    set readStylesheet 1
-    if {[info exists stylesheets($ssheet)]} {
-	if {[file mtime $ssheet] < $stylesheets($ssheet,time)} {
-	    set readStylesheet 0
-	}
-    }
-    if {$readStylesheet} {
-	catch {rename $stylesheets($ssheet) {}}
-	ReadXML $ssheet -xmlinclude $opts(-xmlinclude)
-
-	set stylesheets($ssheet) [xslt::compile $sources($ssheet)]
-	set stylesheets($ssheet,time) [clock seconds]
-    }
-
-    set result [eval [list $stylesheets($ssheet)] transform [list $src] $parameters]
-
-    return $result
-}
-
-# ::xslt::cache::parse_depend --
-#
-#	Parse a document while determining its dependencies.
-#
-# Arguments:
-#	uri	Document's URI
-#	depVar	Global variable name for dependency document
-#
-# Results:
-#	Returns parsed document token.
-#	Document token for dependency document is stored in depVar.
-
-proc xslt::cache::parse_depend {uri depVar} {
-    upvar #0 $depVar dep
-
-    set dep [dom::create]
-    dom::document createElement $dep dependencies
-
-    array set uriParsed [uri::split $uri]
-
-    switch -- $uriParsed(scheme) {
-	file {
-	    set ch [open $uriParsed(path)]
-	    set doc [dom::parse [read $ch] -baseuri $uri -externalentitycommand [namespace code [list ParseDepend_Entity $depVar]]]
-	    close $ch
-
-	    ParseDepend_XInclude $doc $depVar
-	    ParseDepend_XSLT $doc $depVar
-	}
-	http {
-	    return -code error "URI scheme \"http\" not yet implemented"
-	}
-	dom {
-	    set doc $uriParsed(dom)
-
-	    # Can't determine external entities, but can find XInclude
-	    # and XSL stylesheet includes/imports.
-	    ParseDepend_XInclude $uriParsed(dom) $depVar
-	    ParseDepend_XSLT $uriParsed(dom) $depVar
-	}
-	default {
-	    return -code error "URI scheme \"$uriParsed(scheme)\" not supported"
-	}
-    }
-
-    return $doc
-}
-
-# xslt::cache::ParseDepend_Entity --
-#
-#	Callback for external entity inclusion.
-#
-# Arguments:
-#	depVar	Global variable of dependency document
-#	pubId	Public identifier
-#	sysId	System identifier
-#
-# Results:
-#	Dependency added to dependency document
-
-proc xslt::cache::ParseDepend_Entity {depVar pubId sysId} {
-    upvar #0 $depVar dep
-
-    dom::document createNode $dep /dependencies/external-entities/entity
-}
-
-# ::xslt::cache::flush --
-#
-#	Flush the cache
-#
-# Arguments:
-#	src	source document filename
-#	ssheet	stylesheet document filename
-#	args	parameters
-#
-# Results:
-#	Returns the empty string.
-#	If all arguments are given then all entries corresponding
-#	to that transformation are destroyed.
-#	If the source and/or stylesheet are given then all
-#	entries corresponding to those documents are destroyed.
-
-proc xslt::cache::flush {src ssheet args} {
-    variable sources
-    variable stylesheets
-    variable results
-
-    # Normalize parameter list
-    array set paramArray $args
-    set parameters {}
-    foreach name [lsort [array names paramArray]] {
-	lappend parameters $name $paramArray($name)
-    }
-
-    set hash $src.$ssheet.$parameters
-
-    switch -glob [string length $src],[string length $ssheet],[llength $args] {
-	0,0,* {
-	    # Special case: flush all
-	    unset sources
-	    array set sources {}
-	    unset stylesheets
-	    array set stylesheets {}
-	    unset results
-	    array set results {}
-	}
-
-	0,*,0 {
-	    # Flush all entries for the given stylesheet
-	    catch {rename $stylesheets($ssheet) {}}
-	    catch {unset stylesheets($ssheet)}
-	    catch {unset stylesheets($ssheet,time)}
-
-	    foreach entry [array names results *.$ssheet.*] {
-		catch {dom::destroy $results($entry)}
-		catch {unset results($entry)}
-		catch {unset results($entry,time)}
-	    }
-	}
-
-	*,0,0 {
-	    # Flush all entries for the given source document
-	    catch {dom::destroy $sources($src)}
-	    catch {unset sources($src)}
-	    catch {unset sources($src,time)}
-	    foreach entry [array names results $src.*] {
-		catch {dom::destroy $results($entry)}
-		catch {unset results($entry)}
-		catch {unset results($entry,time)}
-	    }
-	}
-
-	default {
-	    # Flush specific entry
-	    catch {dom::destroy $results($hash)}
-	    catch {unset results($hash)}
-	    catch {unset results($hash,time)}
-	}
-    }
-}
diff --git a/tclxml-3.2/tests/README b/tclxml-3.2/tests/README
deleted file mode 100755
index e7d8f94..0000000
--- a/tclxml-3.2/tests/README
+++ /dev/null
@@ -1,14 +0,0 @@
-		TclXML Test Suite
-
-This directory contains test scripts for TclXML, TclDOM and TclXSLT.
-
-MANIFEST:
----------
-
-README		Tcl test suite design document.
-all.tcl         support module that finds & runs all tests
-tclxml		TclXML tests
-tcldom		TclDOM tests
-tclxslt		TclXSLT tests
-
-RCS: @(#) $Id: README,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
diff --git a/tclxml-3.2/tests/tcldom/DOMImplementation.test b/tclxml-3.2/tests/tcldom/DOMImplementation.test
deleted file mode 100644
index 1c465b9..0000000
--- a/tclxml-3.2/tests/tcldom/DOMImplementation.test
+++ /dev/null
@@ -1,297 +0,0 @@
-# Commands covered:  ::dom::DOMImplementation
-#
-# This file contains a collection of tests for one or more of the 
-# TclDOM commands.  Sourcing this file into Tcl runs the tests and
-# generates output for errors.  No output means no errors were found.
-#
-# Copyright (c) 2008 Explain
-# Copyright (c) 1998-2004 Zveno Pty Ltd.
-#
-# $Id: DOMImplementation.test,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require tcltest
-source [file join [tcltest::workingDirectory] tcldomutils.tcl]
-
-testPackage dom
-
-namespace eval ::dom::DOMImplementationTest {
-    namespace import -force ::tcltest::*
-
-    test DOMImplementation-1.1 {hasFeature create} -body {
-	::dom::DOMImplementation hasFeature create 1.0
-    } -result 1
-    test DOMImplementation-1.2 {hasFeature create wrong version} -body {
-	::dom::DOMImplementation hasFeature create 2.0
-    } -result 0
-    test DOMImplementation-1.3 {hasFeature destroy} -body {
-	::dom::DOMImplementation hasFeature destroy 1.0
-    } -result 1
-    test DOMImplementation-1.4 {hasFeature parse} -body {
-	::dom::DOMImplementation hasFeature parse 1.0
-    } -result 1
-    test DOMImplementation-1.5 {hasFeature serialize} -body {
-	::dom::DOMImplementation hasFeature serialize 1.0
-    } -result 1
-    test DOMImplementation-1.6 {hasFeature unknown feature} -body {
-	::dom::DOMImplementation hasFeature unknown 1.0
-    } -result 0
-    test DOMImplementation-1.7 {error: hasFeature too few arguments} -body {
-	catch {::dom::DOMImplementation hasFeature error}
-    } -result 1
-    test DOMImplementation-1.8 {error: hasFeature too many arguments} -body {
-	catch {::dom::DOMImplementation hasFeature error 1.0 foo}
-    } -result 1
-
-    test DOMImplementation-2.1 {create document} -body {
-	set doc [::dom::DOMImplementation create]
-	ok;
-    } -cleanup {
-	dom::destroy $doc
-    } -result {}
-    test DOMImplementation-2.1.1 {create document} -body {
-	set doc [::dom::create]
-	ok;
-    } -cleanup {
-	dom::destroy $doc
-    } -result {}
-    # test DOMImplementation-2.2 {create named document} is obsolete
-    test DOMImplementation-2.3 {error: create too many arguments} -match glob -body {
-	expectError {
-	    ::dom::DOMImplementation create Foo Bar
-	}
-    } -result *
-    test DOMImplementation-2.3.1 {error: create too many arguments} -match glob -body {
-	expectError {
-	    ::dom::create Foo Bar
-	}
-    } -result *
-
-    test DOMImplementation-3.1 {destroy document} -constraints {dom_tcl} -setup {
-	set doc [dom::DOMImplementation create]
-    } -body {
-	::dom::DOMImplementation destroy $doc
-	namespace exists [namespace qualifiers $doc]
-    } -result 0
-    test DOMImplementation-3.1.0 {destroy document} -constraints {dom_tcl} -setup {
-	set doc [dom::create]
-    } -body {
-	::dom::DOMImplementation destroy $doc
-	namespace exists [namespace qualifiers $doc]
-    } -result 0
-    test DOMImplementation-3.1.1 {destroy document} -match glob -setup {
-	set doc [dom::create]
-    } -body {
-	::dom::destroy $doc
-	expectError {
-	    dom::serialize $doc
-	}
-    } -result *
-    test DOMImplementation-3.2 {error: destroy unknown document} -match glob -body {
-	expectError {
-	    ::dom::DOMImplementation destroy {::Bar node1}
-	}
-    } -result *
-    test DOMImplementation-3.2.1 {error: destroy unknown document} -match glob -body {
-	expectError {
-	    ::dom::destroy {::Bar node1}
-	}
-    } -result *
-    test DOMImplementation-3.3 {destroy too few arguments} -match glob -body {
-	expectError {
-	    ::dom::DOMImplementation destroy
-	}
-    } -result *
-    test DOMImplementation-3.3.1 {destroy too few arguments} -match glob -body {
-	expectError {
-	    ::dom::destroy
-	}
-    } -result *
-    test DOMImplementation-3.4 {destroy too many arguments} -match glob -body {
-	expectError {
-	    ::dom::DOMImplementation destroy {::Bar node1} Extra
-	}
-    } -result *
-    test DOMImplementation-3.4.1 {destroy too many arguments} -match glob -body {
-	expectError {
-	    ::dom::destroy {::Bar node1} Extra
-	}
-    } -result *
-
-    # Bug fix #453741
-    test DOMImplementation-3.5 {destroy an element node} -match regexp -setup {
-	set doc [dom::DOMImplementation create]
-	set root [dom::document createElement $doc top]
-	set node1 [dom::document createElement $root node]
-	set node2 [dom::document createElement $root node]
-	dom::node removeChild $root $node1
-    } -body {
-	dom::DOMImplementation destroy $node1
-	dom::DOMImplementation serialize $doc
-    } -cleanup {
-	dom::DOMImplementation destroy $doc
-    } -result {<\?xml version=("|')1\.0("|')([ 	]*encoding=("|')[^"']*("|'))?\?>
-(<!DOCTYPE top>
-)?<top><node/></top>}
-    test DOMImplementation-3.5.1 {destroy an element node} -match regexp -setup {
-	set doc [dom::create]
-	set root [dom::document createElement $doc top]
-	set node1 [dom::document createElement $root node]
-	set node2 [dom::document createElement $root node]
-	dom::node removeChild $root $node1
-    } -body {
-	dom::destroy $node1
-	dom::serialize $doc
-    } -cleanup {
-	dom::DOMImplementation destroy $doc
-    } -result {<\?xml version=("|')1\.0("|')([ 	]*encoding=("|')[^"']*("|'))?\?>
-(<!DOCTYPE top>
-)?<top><node/></top>}
-    test DOMImplementation-3.6 {destroy document} -setup {
-	set doc [dom::create]
-    } -body {
-	dom::destroy $doc
-    } -result {}
-    test DOMImplementation-3.7 {destroy document - cleanup document command} -match glob -setup {
-	set doc [dom::create]
-	dom::destroy $doc
-    } -body {
-	expectError {
-	    $doc cget -implementation
-	}
-    } -result *
-    test DOMImplementation-3.8 {destroy document - cleanup resources} -setup {
-	set doc [dom::create]
-	set top [$doc createElement Top]
-	dom::node appendChild $doc $top
-    } -body {
-	dom::DOMImplementation destroy $doc
-	list [expr [namespace exists ::dom::$doc] || [namespace exists ::dom::tcl::$doc]] \
-	    [string equal {} [info commands $top]] \
-	    [catch {$doc cget -implementation}] \
-	    [catch {dom::node cget $top -nodeType}]
-    } -result [list 0 1 1 1]
-    test DOMImplementation-3.8.1 {destroy document - cleanup resources} -setup {
-	set doc [dom::create]
-	set top [$doc createElement Top]
-	dom::node appendChild $doc $top
-    } -body {
-	dom::destroy $doc
-	list [expr [namespace exists ::dom::$doc] || [namespace exists ::dom::tcl::$doc]] \
-	    [string equal {} [info commands $top]] \
-	    [catch {$doc cget -implementation}] \
-	    [catch {dom::node cget $top -nodeType}]
-    } -result [list 0 1 1 1]
-
-    # This will fail when using dom_tcl with Tcl < 8.4 due to lack of command tracing
-    test DOMImplementation-3.9 {destroy document - delete document command - cleanup resources} -setup {
-	set doc [dom::create]
-	set top [$doc createElement Top]
-	dom::node appendChild $doc $top
-    } -body {
-	rename $doc {}
-	list [expr [namespace exists ::dom::$doc] || [namespace exists ::dom::tcl::$doc]] \
-	    [string equal {} [info commands $top]] \
-	    [catch {$doc cget -implementation}] \
-	    [catch {dom::node cget $top -nodeType}]
-    } -result [list 0 1 1 1]
-    test DOMImplementation-3.10 {destroy node - cleanup resources} -setup {
-	set doc [dom::create]
-	set top [dom::document createElement $doc Test]
-	set node [$doc createTextNode {to be destroyed}]
-	$top appendChild $node
-    } -body {
-	dom::destroy $node
-	list [$top children] \
-	    [dom::isNode $node] \
-	    [info commands $node]
-    } -result [list {} 0 {}] -cleanup {
-	dom::destroy $doc
-    }
-    test DOMImplementation-3.11 {destroy node - delete node command} -setup {
-	set doc [dom::create]
-	set top [dom::document createElement $doc Test]
-	set node [dom::document createTextNode $top {delete me}]
-    } -body {
-	rename $node {}
-	list [$top children] \
-	    [dom::isNode $node] \
-	    [info commands $node]
-    } -result [list {} 0 {}] -cleanup {
-	dom::destroy $doc
-    }
-
-    # Bug #974323
-    test DOMImplementation-3.12 {destroy document - invalidate document token} -match glob -setup {
-	set doc [dom::create]
-	dom::document createElement $doc Test
-    } -body {
-	dom::destroy $doc
-	set result $doc
-	set doc {}
-	set result
-    } -result *
-
-    variable xml {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test>This is test DOMImplementation-4.X</Test>}
-
-    test DOMImplementation-4.1 {parse document} -constraints {doParse} -body {
-	set doc [::dom::DOMImplementation parse $xml]
-	ok
-    } -cleanup {
-	dom::destroy $doc
-    } -result {}
-    test DOMImplementation-4.2 {error: parse too few arguments} -constraints {doParse} -match glob -body {
-	expectError {
-	    ::dom::DOMImplementation parse
-	}
-    } -result *
-    test DOMImplementation-4.3 {error: parse too many arguments} -constraints {doParse} -match glob -body {
-	expectError {
-	    ::dom::DOMImplementation parse $xml Extra
-	}
-    } -result *
-
-    test DOMImplementation-5.1 {isNode: document} -setup {
-	set doc [dom::create]
-    } -body {
-	dom::DOMImplementation isNode $doc
-    } -cleanup {
-	dom::destroy $doc
-    } -result 1
-    test DOMImplementation-5.1.1 {isNode: document} -setup {
-	set doc [dom::create]
-    } -body {
-	dom::isNode $doc
-    } -cleanup {
-	dom::destroy $doc
-    } -result 1
-    test DOMImplementation-5.2 {isNode: node} -setup {
-	set doc [dom::create]
-	set top [dom::document createElement $doc Top]
-    } -body {
-	dom::DOMImplementation isNode $top
-    } -cleanup {
-	dom::destroy $doc
-    } -result 1
-    test DOMImplementation-5.2.1 {isNode: node} -setup {
-	set doc [dom::create]
-	set top [dom::document createElement $doc Top]
-    } -body {
-	dom::isNode $top
-    } -cleanup {
-	dom::destroy $doc
-    } -result 1
-    test DOMImplementation-5.3 {isNode: not a node} -body {
-	dom::DOMImplementation isNode {an arbitrary string}
-    } -result 0
-    test DOMImplementation-5.3.1 {isNode: not a node} -body {
-	dom::isNode whatever
-    } -result 0
-
-    # cleanup
-    ::tcltest::cleanupTests
-}
-namespace delete ::dom::DOMImplementationTest
-
-return
diff --git a/tclxml-3.2/tests/tcldom/README b/tclxml-3.2/tests/tcldom/README
deleted file mode 100644
index c6d5d00..0000000
--- a/tclxml-3.2/tests/tcldom/README
+++ /dev/null
@@ -1,6 +0,0 @@
-TclDOM Test Suite
------------------
-
-To run the tests, type "tclsh all.tcl"
-See tcltest(n) for details.
-
diff --git a/tclxml-3.2/tests/tcldom/all.tcl b/tclxml-3.2/tests/tcldom/all.tcl
deleted file mode 100755
index fd63cc8..0000000
--- a/tclxml-3.2/tests/tcldom/all.tcl
+++ /dev/null
@@ -1,22 +0,0 @@
-# all.tcl --
-#
-# This file contains a support module to run all of the Tcl
-# tests.  It must be invoked using "source all.test" by 
-# a calling tcl script that has loaded the parser class it wishes to
-# test in this directory.
-#
-# Copyright (c) 2008 Explain
-# http://www.explain.com.au/
-# Copyright (c) 2003 Zveno Pty Ltd
-# Copyright (c) 1998-1999 by Scriptics Corporation.
-#
-# All rights reserved.
-# 
-# RCS: @(#) $Id: all.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require Tcl 8.4
-package require tcltest 2.2
-tcltest::configure -testdir [file dirname [file normalize [info script]]]
-eval tcltest::configure $argv
-
-tcltest::runAllTests
diff --git a/tclxml-3.2/tests/tcldom/doctype.test b/tclxml-3.2/tests/tcldom/doctype.test
deleted file mode 100644
index 1bb06d9..0000000
--- a/tclxml-3.2/tests/tcldom/doctype.test
+++ /dev/null
@@ -1,228 +0,0 @@
-# Commands covered:  ::dom::doctype
-#
-# This file contains a collection of tests for one or more of the Tcl
-# built-in commands.  Sourcing this file into Tcl runs the tests and
-# generates output for errors.  No output means no errors were found.
-#
-# Copyright (c) 2008 Explain
-# http://www.explain.com.au/
-# Copyright (c) 2003 Zveno Pty Ltd.
-# Copyright (c) 2000 Ajuba Solutions.
-# All rights reserved.
-#
-# RCS: @(#) $Id: doctype.test,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require tcltest
-source [file join [tcltest::workingDirectory] tcldomutils.tcl]
-
-testPackage dom
-
-namespace eval ::dom::doctypeTest {
-    namespace import -force ::tcltest::*
-
-    test doctype-1.1 {argument parsing errors} -constraints {dom_c} -body {
-	list [catch {dom::doctype} msg] $msg
-    } -result "1 {wrong \# args: should be \"dom::doctype method ?args...?\"}"
-    test doctype-1.2 {argument parsing errors} -constraints {dom_c} -body {
-	list [catch {dom::doctype foo} msg] $msg
-    } -result {1 {bad method "foo": must be cget or configure}}
-    test doctype-1.3 {argument parsing errors} -constraints {dom_c} -body {
-	list [catch {dom::doctype cget foo} msg] $msg
-    } -result {1 {token not found}}
-    test doctype-1.4 {argument parsing errors} -constraints {dom_c} -setup {
-	set root [dom::DOMImplementation parse {<?xml version="1.0"?><foo/>}]
-    } -body {
-	list [catch {dom::doctype cget $root} msg] $msg
-    } -cleanup {
-	dom::DOMImplementation destroy $root
-    } -result {1 {not a doctype type node}}
-    test doctype-1.5 {argument parsing errors} -constraints {dom_c} -setup {
-	set root [dom::DOMImplementation parse {<?xml version="1.0"?><!DOCTYPE foo><foo/>}]
-	set doctype [dom::document cget $root -doctype]
-    } -body {
-	list [catch {dom::doctype cget $doctype} msg] $msg
-    } -cleanup {
-	dom::DOMImplementation destroy $root
-    } -result "1 {wrong \# args: should be \"dom::doctype cget token option\"}"
-    test doctype-1.6 {argument parsing errors} -constraints {dom_c} -setup {
-	set root [dom::DOMImplementation parse {<?xml version="1.0"?><!DOCTYPE foo><foo/>}]
-	set doctype [dom::document cget $root -doctype]
-    } -body {
-	list [catch {dom::doctype cget $doctype -foo} msg] $msg
-    } -cleanup {
-	dom::DOMImplementation destroy $root
-    } -result {1 {unknown option '-foo', should be -internalSubset, -nodeName, -publicId, or -systemId}}
-    test doctype-1.7 {argument parsing errors} -constraints {dom_c} -setup {
-	set root [dom::DOMImplementation parse {<?xml version="1.0"?><!DOCTYPE foo><foo/>}]
-	set doctype [dom::document cget $root -doctype]
-    } -body {
-	list [catch {dom::doctype configure $doctype} msg] $msg
-    } -cleanup {
-	dom::DOMImplementation destroy $root
-    } -result {1 {doctype configure method not implemented}}
-    test doctype-1.8 {argument parsing errors} -constraints {dom_c} -setup {
-	set root [dom::DOMImplementation parse {<?xml version="1.0"?><!DOCTYPE foo><foo/>}]
-	set doctype [dom::document cget $root -doctype]
-    } -body {
-	list [catch {dom::doctype foo $doctype} msg] $msg
-    } -cleanup {
-	dom::DOMImplementation destroy $root
-    } -result {1 {bad method "foo": must be cget or configure}}
-
-    test doctype-2.1 {cget options, -systemId, empty} -constraints {dom_c} -setup {
-	set root [dom::DOMImplementation parse {<?xml version="1.0"?><!DOCTYPE foo><foo/>}]
-	set doctype [dom::document cget $root -doctype]
-    } -body {
-	dom::doctype cget $doctype -systemId
-    } -cleanup {
-	dom::DOMImplementation destroy $root
-    } -result {}
-    test doctype-2.2 {cget options, -systemId, non-empty SYSTEM} -constraints {dom_c} -setup {
-	set root [dom::DOMImplementation parse {<?xml version="1.0"?>
-	<!DOCTYPE foo SYSTEM "foo.dtd"><foo/>}]
-	set doctype [dom::document cget $root -doctype]
-    } -body {
-	set result [dom::doctype cget $doctype -systemId]
-    } -cleanup {
-	dom::DOMImplementation destroy $root
-    } -result foo.dtd
-    test doctype-2.3 {cget options, -systemId, non-empty PUBLIC} -constraints {dom_c} -setup {
-	set root [dom::DOMImplementation parse {<?xml version="1.0"?>
-	<!DOCTYPE foo PUBLIC "--Foo--" "foo.dtd"><foo/>}]
-	set doctype [dom::document cget $root -doctype]
-    } -body {
-	dom::doctype cget $doctype -systemId
-    } -cleanup {
-	dom::DOMImplementation destroy $root
-    } -result foo.dtd
-    test doctype-2.4 {cget options, -systemId, non-empty internal subset} -constraints {dom_c} -setup {
-	set root [dom::DOMImplementation parse {<?xml version="1.0"?>
-	<!DOCTYPE foo SYSTEM "foo.dtd" [<!ELEMENT foo ANY>]><foo/>}]
-	set doctype [dom::document cget $root -doctype]
-    } -body {
-	dom::doctype cget $doctype -systemId
-    } -cleanup {
-	dom::DOMImplementation destroy $root
-    } -result foo.dtd
-
-    test doctype-3.1 {cget options, -publicId, empty} -constraints {dom_c} -setup {
-	set root [dom::DOMImplementation parse {<?xml version="1.0"?><!DOCTYPE foo><foo/>}]
-	set doctype [dom::document cget $root -doctype]
-    } -body {
-	dom::doctype cget $doctype -publicId
-    } -cleanup {
-	dom::DOMImplementation destroy $root
-    } -result {}
-    test doctype-3.2 {cget options, -publicId, non-empty SYSTEM} -constraints {dom_c} -setup {
-	set root [dom::DOMImplementation parse {<?xml version="1.0"?>
-	<!DOCTYPE foo SYSTEM "foo.dtd"><foo/>}]
-	set doctype [dom::document cget $root -doctype]
-    } -body {
-	dom::doctype cget $doctype -publicId
-    } -cleanup {
-	dom::DOMImplementation destroy $root
-    } -result {}
-    test doctype-3.3 {cget options, -publicId, non-empty PUBLIC} -constraints {dom_c} -setup {
-	set root [dom::DOMImplementation parse {<?xml version="1.0"?>
-	<!DOCTYPE foo PUBLIC "--Foo--" "foo.dtd"><foo/>}]
-	set doctype [dom::document cget $root -doctype]
-    } -body {
-	dom::doctype cget $doctype -publicId
-    } -cleanup {
-	dom::DOMImplementation destroy $root
-    } -result --Foo--
-    test doctype-3.4 {cget options, -publicId, non-empty internal subset} -constraints {dom_c} -setup {
-	set root [dom::DOMImplementation parse {<?xml version="1.0"?>
-	<!DOCTYPE foo PUBLIC "--Foo--" "foo.dtd" [<!ELEMENT foo ANY>]><foo/>}]
-	set doctype [dom::document cget $root -doctype]
-    } -body {
-	dom::doctype cget $doctype -publicId
-    } -cleanup {
-	dom::DOMImplementation destroy $root
-    } -result --Foo--
-
-    test doctype-4.1 {cget options, -nodeName, empty} -constraints {dom_c} -setup {
-	set root [dom::DOMImplementation parse {<?xml version="1.0"?><!DOCTYPE foo><foo/>}]
-	set doctype [dom::document cget $root -doctype]
-    } -body {
-	set result [dom::doctype cget $doctype -nodeName]
-    } -cleanup {
-	dom::DOMImplementation destroy $root
-    } -result foo
-    test doctype-4.2 {cget options, -nodeName, non-empty SYSTEM} -constraints {dom_c} -setup {
-	set root [dom::DOMImplementation parse {<?xml version="1.0"?>
-	<!DOCTYPE foo SYSTEM "foo.dtd"><foo/>}]
-	set doctype [dom::document cget $root -doctype]
-    } -body {
-	dom::doctype cget $doctype -nodeName
-    } -cleanup {
-	dom::DOMImplementation destroy $root
-    } -result foo
-    test doctype-4.3 {cget options, -nodeName, non-empty PUBLIC} -constraints {dom_c} -setup {
-	set root [dom::DOMImplementation parse {<?xml version="1.0"?>
-	<!DOCTYPE foo PUBLIC "--Foo--" "foo.dtd"><foo/>}]
-	set doctype [dom::document cget $root -doctype]
-    } -body {
-	dom::doctype cget $doctype -nodeName
-    } -cleanup {
-	dom::DOMImplementation destroy $root
-    } -result foo
-    test doctype-4.4 {cget options, -nodeName, non-empty internal subset} -constraints {dom_c} -setup {
-	set root [dom::DOMImplementation parse {<?xml version="1.0"?>
-	<!DOCTYPE foo PUBLIC "--Foo--" "foo.dtd" [<!ELEMENT foo ANY>]><foo/>}]
-	set doctype [dom::document cget $root -doctype]
-    } -body {
-	dom::doctype cget $doctype -nodeName
-    } -cleanup {
-	dom::DOMImplementation destroy $root
-    } -result foo
-
-    test doctype-5.1 {cget options, -internalSubset} -constraints {dom_c} -setup {
-	# Not implemented yet
-	set root [dom::DOMImplementation parse {<?xml version="1.0"?>
-	<!DOCTYPE foo PUBLIC "--Foo--" "foo.dtd" [<!ELEMENT foo ANY>]><foo/>}]
-	set doctype [dom::document cget $root -doctype]
-    } -body {
-	dom::doctype cget $doctype -internalSubset
-    } -cleanup {
-	dom::DOMImplementation destroy $root
-    } -result {}
-
-    test doctype-6.1 {createDocumentType} -constraints {!dom_libxml2} -body {
-	set dt [dom::DOMImplementation createDocumentType test {} {}]
-	ok
-    } -cleanup {
-	dom::destroy $dt
-    } -result {}
-    test doctype-6.2 {createDocumentType w/- internal subset} -constraints {!dom_libxml2} -body {
-	set dt [dom::DOMImplementation createDocumentType test {} {} {
-<!ELEMENT test (#PCDATA)>
-}]
-	ok
-    } -cleanup {
-	dom::destroy $dt
-    } -result {}
-    test doctype-6.3 {createDocumentType: use with createDocument} -constraints {!dom_libxml2} -setup {
-	set dt [dom::DOMImplementation createDocumentType test {} {}]
-    } -body {
-	set doc [dom::DOMImplementation createDocument {} test $dt]
-	ok
-    } -cleanup {
-	dom::destroy $doc
-	dom::destroy $dt
-    } -result {}
-    test doctype-6.4 {createDocumentType: use with createDocument} -constraints {!dom_libxml2} -setup {
-	set dt [dom::DOMImplementation createDocumentType test {} {}]
-	set doc [dom::DOMImplementation createDocument {} test $dt]
-    } -body {
-	string equal $dt [$doc cget -doctype]
-    } -cleanup {
-	dom::destroy $doc
-	dom::destroy $dt
-    } -result 1
-
-    cleanupTests
-}
-namespace delete ::dom::doctypeTest
-
-return
diff --git a/tclxml-3.2/tests/tcldom/document.test b/tclxml-3.2/tests/tcldom/document.test
deleted file mode 100644
index a6d0345..0000000
--- a/tclxml-3.2/tests/tcldom/document.test
+++ /dev/null
@@ -1,573 +0,0 @@
-# Commands covered:  ::dom::document
-#
-# This file contains a collection of tests for one or more of the 
-# TclDOM commands.  Sourcing this file into Tcl runs the tests and
-# generates output for errors.  No output means no errors were found.
-#
-# Copyright (c) 2008 Explain
-# Copyright (c) 1998-2004 Zveno Pty Ltd.
-#
-# $Id: document.test,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require tcltest
-source [file join [tcltest::workingDirectory] tcldomutils.tcl]
-
-testPackage dom
-
-namespace eval ::dom::documentTest {
-    namespace import -force ::tcltest::*
-
-    variable SETUP {
-	set doc [::dom::create]
-	set top [$doc createElement Test]
-	::dom::node appendChild $doc $top
-    }
-
-    variable CLEANUP {
-	dom::destroy $doc
-    }
-
-    test document-1.1 {cget -doctype} -setup $SETUP -constraints {dom_c} -body {
-	::dom::document cget $doc -doctype
-    } -cleanup $CLEANUP -result {}
-    test document-1.1 {cget -doctype} -setup $SETUP -constraints {dom_tcl} -body {
-	string equal [::dom::document cget $doc -doctype] {}
-    } -cleanup $CLEANUP -result 0
-    test document-1.1.1 {cget -doctype} -setup $SETUP -constraints {dom_c} -body {
-	$doc cget -doctype
-    } -cleanup $CLEANUP -result {}
-    test document-1.1.1 {cget -doctype} -setup $SETUP -constraints {dom_tcl} -body {
-	string equal [$doc cget -doctype] {}
-    } -cleanup $CLEANUP -result 0
-    test document-1.2 {cget -implementation} -setup $SETUP -constraints {dom_c} -body {
-	::dom::document cget $doc -implementation
-    } -cleanup $CLEANUP -result {::dom::DOMImplementation}
-    test document-1.2 {cget -implementation} -setup $SETUP -constraints {dom_tcl} -body {
-	::dom::document cget $doc -implementation
-    } -cleanup $CLEANUP -result {::dom::tcl::DOMImplementation}
-    test document-1.2.1 {cget -implementation} -setup $SETUP -constraints {dom_tcl} -body {
-	$doc cget -implementation
-    } -cleanup $CLEANUP -result {::dom::tcl::DOMImplementation}
-    test document-1.2 {cget -implementation} -setup $SETUP -constraints {dom_libxml2} -body {
-	::dom::document cget $doc -implementation
-    } -cleanup $CLEANUP -result {::dom::libxml2::DOMImplementation}
-    test document-1.2.1 {cget -implementation} -setup $SETUP -constraints {dom_libxml2} -body {
-	$doc cget -implementation
-    } -cleanup $CLEANUP -result {::dom::libxml2::DOMImplementation}
-    test document-1.3 {cget -documentElement} -body {
-	set doc [dom::create]
-	::dom::document cget $doc -documentElement
-    } -cleanup $CLEANUP -result {}
-    test document-1.3.1 {cget -documentElement} -body {
-	set doc [dom::create]
-	$doc cget -documentElement
-    } -cleanup $CLEANUP -result {}
-    test document-1.4 {error: cget too few arguments} -setup $SETUP -match glob -body {
-	expectError {
-	    ::dom::document cget $doc
-	}
-    } -cleanup $CLEANUP -result {wrong # args*}
-    test document-1.4.1 {error: cget too few arguments} -setup $SETUP -match glob -body {
-	expectError {
-	    $doc cget
-	}
-    } -cleanup $CLEANUP -result {wrong # args*}
-    test document-1.5 {error: cget too many arguments} -setup $SETUP -match glob -body {
-	expectError {
-	    ::dom::document cget $doc -foo bar
-	}
-    } -cleanup $CLEANUP -result {wrong # args*}
-    test document-1.5.1 {error: cget too many arguments} -setup $SETUP -match glob -body {
-	expectError {
-	    $doc cget -foo bar
-	}
-    } -cleanup $CLEANUP -result {wrong # args*}
-    test document-1.6 {error: cget unknown option} -setup $SETUP -match glob -body {
-	expectError {
-	    ::dom::document cget $doc -foo
-	}
-    } -cleanup $CLEANUP -result {bad option*}
-    test document-1.6.1 {error: cget unknown option} -setup $SETUP -match glob -body {
-	expectError {
-	    $doc cget -foo
-	}
-    } -cleanup $CLEANUP -result {bad option*}
-    test document-1.7 {cget -version} -constraints {dom_tcl} -setup $SETUP -body {
-	::dom::document cget $doc -version
-    } -cleanup $CLEANUP -result 1.0
-    test document-1.7.1 {cget -version} -constraints {dom_tcl} -setup $SETUP -body {
-	$doc cget -version
-    } -cleanup $CLEANUP -result 1.0
-
-    test document-2.1 {configure} -body {
-	set doc [dom::create]
-	::dom::document configure $doc -documentElement
-    } -cleanup $CLEANUP -result {}
-    test document-2.1.1 {configure} -body {
-	set doc [dom::create]
-	$doc configure -documentElement
-    } -cleanup $CLEANUP -result {}
-    test document-2.2 {error: configure read-only option} -setup $SETUP -match glob -body {
-	expectError {
-	    ::dom::document configure $doc -documentElement $doc
-	}
-    } -cleanup $CLEANUP -result {attribute * read-only}
-    test document-2.2.1 {error: configure read-only option} -setup $SETUP -match glob -body {
-	expectError {
-	    $doc configure -documentElement $doc
-	}
-    } -cleanup $CLEANUP -result {attribute * read-only}
-    test document-2.3 {configure -version} -constraints {dom_tcl} -setup $SETUP -body {
-	::dom::document configure $doc -version 1.0
-    } -cleanup $CLEANUP -result {}
-    test document-2.3.1 {configure -version} -constraints {dom_tcl} -setup $SETUP -body {
-	$doc configure -version 1.0
-    } -cleanup $CLEANUP -result {}
-    test document-2.4 {error: configure -version} -constraints {dom_tcl} -setup $SETUP -match glob -body {
-	expectError {
-	    ::dom::document configure $doc -version 1.1
-	}
-    } -cleanup $CLEANUP -result *
-    test document-2.4.1 {error: configure -version} -constraints {dom_tcl} -setup $SETUP -match glob -body {
-	expectError {
-	    $doc configure -version 1.1
-	}
-    } -cleanup $CLEANUP -result *
-    test document-2.5 {configure -encoding} -constraints {dom_tcl} -setup $SETUP -body {
-	::dom::document configure $doc -encoding ISO-8859-1
-	::dom::document cget $doc -encoding
-    } -cleanup $CLEANUP -result ISO-8859-1
-    test document-2.5.1 {configure -encoding} -constraints {dom_tcl} -setup $SETUP -body {
-	$doc configure -encoding ISO-8859-1
-	$doc cget -encoding
-    } -cleanup $CLEANUP -result ISO-8859-1
-    test document-2.6 {configure -standalone} -constraints {dom_tcl} -setup $SETUP -body {
-	::dom::document configure $doc -standalone 1
-	::dom::document cget $doc -standalone
-    } -cleanup $CLEANUP -result yes
-    test document-2.6.1 {configure -standalone} -constraints {dom_tcl} -setup $SETUP -body {
-	$doc configure -standalone 1
-	$doc cget -standalone
-    } -cleanup $CLEANUP -result yes
-
-    test document-3.1 {create document element} -body {
-	set doc [dom::create]
-	set top [::dom::document createElement $doc Test]
-	::dom::node appendChild $doc $top
-	ok
-    } -cleanup $CLEANUP -result {}
-    test document-3.1.1 {create document element} -body {
-	set doc [dom::create]
-	set top [$doc createElement Test]
-	::dom::node appendChild $doc $top
-	ok
-    } -cleanup $CLEANUP -result {}
-    test document-3.2 {element node type} -setup $SETUP -body {
-	::dom::node cget $top -nodeType
-    } -cleanup $CLEANUP -result element
-    test document-3.2.1 {element node type} -setup $SETUP -body {
-	$top cget -nodeType
-    } -cleanup $CLEANUP -result element
-    test document-3.3 {element name} -setup $SETUP -body {
-	::dom::node cget $top -nodeName
-    } -cleanup $CLEANUP -result Test
-    test document-3.3.1 {element name} -setup $SETUP -body {
-	$top cget -nodeName
-    } -cleanup $CLEANUP -result Test
-    test document-3.4 {document element set} -setup $SETUP -body {
-	$top isSameNode [::dom::document cget $doc -documentElement]
-    } -cleanup $CLEANUP -result 1
-    test document-3.4.1 {document element set} -setup $SETUP -body {
-	$top isSameNode [$doc cget -documentElement]
-    } -cleanup $CLEANUP -result 1
-    test document-3.5 {error: no element name} -setup $SETUP -match glob -body {
-	expectError {
-	    ::dom::document createElement $doc
-	}
-    } -cleanup $CLEANUP -result {wrong # args*}
-    test document-3.5.1 {error: no element name} -setup $SETUP -match glob -body {
-	expectError {
-	    $doc createElement
-	}
-    } -cleanup $CLEANUP -result {wrong # args*}
-    test document-3.6 {error: invalid element name} -setup $SETUP -match glob -body {
-	expectError {
-    	    ::dom::document createElement $top {Has Space}
-	}
-    } -cleanup $CLEANUP -result {invalid * name *}
-    test document-3.6.1 {error: invalid element name} -constraints {not_implemented} -setup $SETUP -match glob -body {
-	expectError {
-    	    $top createElement {Has Space}
-	}
-    } -cleanup $CLEANUP -result {invalid * name *}
-    test document-3.7 {error: too many arguments} -setup $SETUP -match glob -body {
-	expectError {
-	    ::dom::document createElement $doc Foo Bar
-	}
-    } -cleanup $CLEANUP -result {wrong # args*}
-    test document-3.7.1 {error: too many arguments} -constraints {not_implemented} -setup $SETUP -match glob -body {
-	expectError {
-	    $doc createElement Foo Bar
-	}
-    } -cleanup $CLEANUP -result {wrong # args*}
-    test document-3.8 {create node command} -setup {
-	set doc [dom::create]
-	set node [dom::document createElement $doc Test]
-    } -body {
-	string equal [info commands $node] {}
-    } -result 0 -cleanup $CLEANUP
-    test document-3.9 {create unconnected element} -setup {
-	set doc [dom::create]
-	set docel [dom::document createElement $doc Test]
-    } -body {
-	set new [$doc createElement New]
-	ok
-    } -result {} -cleanup $CLEANUP
-
-    test document-4.1 {create documentFragment} -setup $SETUP -body {
-	set frag [::dom::document createDocumentFragment $top]
-	ok
-    } -cleanup $CLEANUP -result {}
-    test document-4.1.1 {create documentFragment} -setup $SETUP -body {
-	set frag [$doc createDocumentFragment]
-	ok
-    } -cleanup $CLEANUP -result {}
-    test document-4.2 {documentFragment node type} -setup $SETUP -body {
-	set frag [::dom::document createDocumentFragment $top]
-	::dom::node cget $frag -nodeType
-    } -cleanup $CLEANUP -result documentFragment
-    test document-4.2.1 {documentFragment node type} -setup $SETUP -body {
-	set frag [::dom::document createDocumentFragment $top]
-	$frag cget -nodeType
-    } -cleanup $CLEANUP -result documentFragment
-    test document-4.3 {error: documentFragment too many arguments} -setup $SETUP -match glob -body {
-	expectError {
-	    ::dom::document createDocumentFragment $top Foo
-	}
-    } -cleanup $CLEANUP -result {wrong # args*}
-    test document-4.3.1 {error: documentFragment too many arguments} -constraints {not_implemented} -setup $SETUP -match glob -body {
-	expectError {
-	    $doc createDocumentFragment Foo
-	}
-    } -cleanup $CLEANUP -result {wrong # args*}
-
-    test document-5.1 {create textNode} -setup $SETUP -body {
-	set text [::dom::document createTextNode $top {Sample Data}]
-	ok;
-    } -cleanup $CLEANUP -result {}
-    test document-5.1.1 {create textNode} -setup $SETUP -body {
-	set text [$doc createTextNode {Sample Data}]
-	ok;
-    } -cleanup $CLEANUP -result {}
-    test document-5.2 {textNode node type} -setup $SETUP -body {
-	set text [$doc createTextNode {Sample Data}]
-	::dom::node cget $text -nodeType
-    } -cleanup $CLEANUP -result textNode
-    test document-5.2.1 {textNode node type} -setup $SETUP -body {
-	set text [$doc createTextNode {Sample Data}]
-	$text cget -nodeType
-    } -cleanup $CLEANUP -result textNode
-    test document-5.3 {textNode node name} -setup $SETUP -body {
-	set text [$doc createTextNode {Sample Data}]
-	::dom::node cget $text -nodeName
-    } -cleanup $CLEANUP -result {#text}
-    test document-5.3.1 {textNode node name} -setup $SETUP -body {
-	set text [$doc createTextNode {Sample Data}]
-	$text cget -nodeName
-    } -cleanup $CLEANUP -result {#text}
-    test document-5.4 {textNode node value} -setup $SETUP -body {
-	set text [$doc createTextNode {Sample Data}]
-	::dom::node cget $text -nodeValue
-    } -cleanup $CLEANUP -result {Sample Data}
-    test document-5.4.1 {textNode node value} -setup $SETUP -body {
-	set text [$doc createTextNode {Sample Data}]
-	$text cget -nodeValue
-    } -cleanup $CLEANUP -result {Sample Data}
-    test document-5.5 {error: textNode too few arguments} -setup $SETUP -match glob -body {
-	expectError {
-	    ::dom::document createTextNode $top
-	}
-    } -cleanup $CLEANUP -result {wrong # args*}
-    test document-5.5.1 {error: textNode too few arguments} -setup $SETUP -match glob -body {
-	expectError {
-	    $doc createTextNode
-	}
-    } -cleanup $CLEANUP -result {wrong # args*}
-    test document-5.6 {error: textNode too many arguments} -setup $SETUP -match glob -body {
-	expectError {
-	    ::dom::document createTextNode $top {More Sample Data} Foo
-	}
-    } -cleanup $CLEANUP -result {wrong # args*}
-    test document-5.6.1 {error: textNode too many arguments} -setup $SETUP -match glob -body {
-	expectError {
-	    $doc createTextNode {More Sample Data} Foo
-	}
-    } -cleanup $CLEANUP -result {wrong # args*}
-
-    test document-6.1 {create comment} -setup $SETUP -body {
-	set comm [::dom::document createComment $top {Comment Data}]
-	ok;
-    } -cleanup $CLEANUP -result {}
-    test document-6.1.1 {create comment} -setup $SETUP -body {
-	set comm [$doc createComment {Comment Data}]
-	ok;
-    } -cleanup $CLEANUP -result {}
-    test document-6.2 {comment node type} -setup $SETUP -body {
-	set comm [::dom::document createComment $top {Comment Data}]
-	::dom::node cget $comm -nodeType
-    } -cleanup $CLEANUP -result comment
-    test document-6.2.1 {comment node type} -setup $SETUP -body {
-	set comm [::dom::document createComment $top {Comment Data}]
-	$comm cget -nodeType
-    } -cleanup $CLEANUP -result comment
-    test document-6.3 {comment node name} -setup $SETUP -body {
-	set comm [::dom::document createComment $top {Comment Data}]
-	::dom::node cget $comm -nodeName
-    } -cleanup $CLEANUP -result {#comment}
-    test document-6.3.1 {comment node name} -setup $SETUP -body {
-	set comm [::dom::document createComment $top {Comment Data}]
-	$comm cget -nodeName
-    } -cleanup $CLEANUP -result {#comment}
-    test document-6.4 {comment node value} -setup $SETUP -body {
-	set comm [::dom::document createComment $top {Comment Data}]
-	::dom::node cget $comm -nodeValue
-    } -cleanup $CLEANUP -result {Comment Data}
-    test document-6.4.1 {comment node value} -setup $SETUP -body {
-	set comm [::dom::document createComment $top {Comment Data}]
-	$comm cget -nodeValue
-    } -cleanup $CLEANUP -result {Comment Data}
-    test document-6.5 {error: comment too few arguments} -setup $SETUP -match glob -body {
-	expectError {
-	    ::dom::document createComment $top
-	}
-    } -cleanup $CLEANUP -result {wrong # args*}
-    test document-6.5.1 {error: comment too few arguments} -setup $SETUP -match glob -body {
-	expectError {
-	    $doc createComment
-	}
-    } -cleanup $CLEANUP -result {wrong # args*}
-    test document-6.6 {error: comment too many arguments} -setup $SETUP -match glob -body {
-	expectError {
-	    ::dom::document createComment $top {More Comment Data} Foo
-	}
-    } -cleanup $CLEANUP -result {wrong # args*}
-    test document-6.6.1 {error: comment too many arguments} -setup $SETUP -match glob -body {
-	expectError {
-	    $doc createComment {More Comment Data} Foo
-	}
-    } -cleanup $CLEANUP -result {wrong # args*}
-
-    # dom::tcl and dom::libxml2 treat CDATA Sections as plain text
-
-    test document-7.1 {create CDATASection} -setup $SETUP -body {
-	set cdata [::dom::document createCDATASection $top {CDATASection <Data>}]
-	ok
-    } -cleanup $CLEANUP -result {}
-    test document-7.1.1 {create CDATASection} -setup $SETUP -body {
-	set cdata [$doc createCDATASection {CDATASection <Data>}]
-	ok
-    } -cleanup $CLEANUP -result {}
-    test document-7.2 {CDATASection node type} -constraints {dom_c} -setup $SETUP -body {
-	set cdata [::dom::document createCDATASection $top {CDATASection <Data>}]
-	::dom::node cget $cdata -nodeType
-    } -cleanup $CLEANUP -result CDATASection
-    test document-7.2 {CDATASection node type} -constraints {dom_tcl || dom_libxml2} -setup $SETUP -body {
-	set cdata [::dom::document createCDATASection $top {CDATASection <Data>}]
-	::dom::node cget $cdata -nodeType
-    } -cleanup $CLEANUP -result textNode
-    test document-7.2.1 {CDATASection node type} -constraints {dom_tcl || dom_libxml2} -setup $SETUP -body {
-	set cdata [::dom::document createCDATASection $top {CDATASection <Data>}]
-	$cdata cget -nodeType
-    } -cleanup $CLEANUP -result textNode
-    test document-7.3 {CDATASection node name} -constraints {dom_c} -setup $SETUP -body {
-	set cdata [::dom::document createCDATASection $top {CDATASection <Data>}]
-	::dom::node cget $cdata -nodeName
-    } -cleanup $CLEANUP -result {#cdata-section}
-    test document-7.3 {CDATASection node name} -constraints {dom_tcl || dom_libxml2} -setup $SETUP -body {
-	set cdata [::dom::document createCDATASection $top {CDATASection <Data>}]
-	::dom::node cget $cdata -nodeName
-    } -cleanup $CLEANUP -result {#text}
-    test document-7.3.1 {CDATASection node name} -constraints {dom_tcl || dom_libxml2} -setup $SETUP -body {
-	set cdata [::dom::document createCDATASection $top {CDATASection <Data>}]
-	$cdata cget -nodeName
-    } -cleanup $CLEANUP -result {#text}
-    test document-7.4 {CDATASection node value} -setup $SETUP -body {
-	set cdata [::dom::document createCDATASection $top {CDATASection <Data>}]
-	::dom::node cget $cdata -nodeValue
-    } -cleanup $CLEANUP -result {CDATASection <Data>}
-    test document-7.4.1 {CDATASection node value} -setup $SETUP -body {
-	set cdata [::dom::document createCDATASection $top {CDATASection <Data>}]
-	$cdata cget -nodeValue
-    } -cleanup $CLEANUP -result {CDATASection <Data>}
-    test document-7.5 {error: CDATASection too few arguments} -setup $SETUP -match glob -body {
-	expectError {
-	    ::dom::document createCDATASection $top
-	}
-    } -cleanup $CLEANUP -result {wrong # args*}
-    test document-7.5.1 {error: CDATASection too few arguments} -setup $SETUP -match glob -body {
-	expectError {
-	    $doc createCDATASection
-	}
-    } -cleanup $CLEANUP -result {wrong # args*}
-    test document-7.6 {error: CDATASection too many arguments} -setup $SETUP -match glob -body {
-	expectError {
-	    ::dom::document createCDATASection $top {More CDATA} Foo
-	}
-    } -cleanup $CLEANUP -result {wrong # args*}
-    test document-7.6.1 {error: CDATASection too many arguments} -setup $SETUP -match glob -body {
-	expectError {
-	    $doc createCDATASection {More CDATA} Foo
-	}
-    } -cleanup $CLEANUP -result {wrong # args*}
-
-    test document-8.1 {create processingInstruction} -setup $SETUP -body {
-	set pi [::dom::document createProcessingInstruction $top target {PI Data}]
-	ok;
-    } -cleanup $CLEANUP -result {}
-    test document-8.1.1 {create processingInstruction} -setup $SETUP -body {
-	set pi [$doc createProcessingInstruction target {PI Data}]
-	ok;
-    } -cleanup $CLEANUP -result {}
-    test document-8.2 {processingInstruction node type} -setup $SETUP -body {
-	set pi [::dom::document createProcessingInstruction $top target {PI Data}]
-	::dom::node cget $pi -nodeType
-    } -cleanup $CLEANUP -result processingInstruction
-    test document-8.2.1 {processingInstruction node type} -setup $SETUP -body {
-	set pi [::dom::document createProcessingInstruction $top target {PI Data}]
-	$pi cget -nodeType
-    } -cleanup $CLEANUP -result processingInstruction
-    test document-8.3 {processingInstruction node name} -setup $SETUP -body {
-	set pi [::dom::document createProcessingInstruction $top target {PI Data}]
-	::dom::node cget $pi -nodeName
-    } -cleanup $CLEANUP -result target
-    test document-8.3.1 {processingInstruction node name} -setup $SETUP -body {
-	set pi [::dom::document createProcessingInstruction $top target {PI Data}]
-	$pi cget -nodeName
-    } -cleanup $CLEANUP -result target
-    test document-8.4 {processingInstruction node value} -setup $SETUP -body {
-	set pi [::dom::document createProcessingInstruction $top target {PI Data}]
-	::dom::node cget $pi -nodeValue
-    } -cleanup $CLEANUP -result {PI Data}
-    test document-8.4.1 {processingInstruction node value} -setup $SETUP -body {
-	set pi [::dom::document createProcessingInstruction $top target {PI Data}]
-	$pi cget -nodeValue
-    } -cleanup $CLEANUP -result {PI Data}
-    test document-8.5 {error: processingInstruction too few arguments} -setup $SETUP -match glob -body {
-	expectError {
-	    ::dom::document createProcessingInstruction $top
-	}
-    } -cleanup $CLEANUP -result {wrong # args*}
-    test document-8.5.1 {error: processingInstruction too few arguments} -setup $SETUP -match glob -body {
-	expectError {
-	    $doc createProcessingInstruction
-	}
-    } -cleanup $CLEANUP -result {wrong # args*}
-    test document-8.6 {error: processingInstruction too many arguments} -setup $SETUP -match glob -body {
-	expectError {
-	    ::dom::document createProcessingInstruction $top target data Extra
-	}
-    } -cleanup $CLEANUP -result {wrong # args*}
-    test document-8.6.1 {error: processingInstruction too many arguments} -setup $SETUP -match glob -body {
-	expectError {
-	    $doc createProcessingInstruction target data Extra
-	}
-    } -cleanup $CLEANUP -result {wrong # args*}
-
-# TBD: Attribute
-# TBD: EntityReference
-
-    variable SETUP10 {
-	set doc [dom::create]
-	set top [$doc createElement Test]
-	set child1 [$doc createElement Child1]
-	$top appendChild $child1
-	set child2 [$doc createElement Child2]
-	$top appendChild $child2
-	set child3 [$doc createElement Test]
-	$top appendChild $child3
-    }
-
-    test document-10.1 {getElementsByTagName - document element} \
-    -constraints {!dom_libxml2} -setup $SETUP -body {
-	set docTestElements [::dom::document getElementsByTagName $doc Test]
-	list [llength [set $docTestElements]] [$top isSameNode [lindex [set $docTestElements] 0]]
-    } -cleanup $CLEANUP -result [list 1 1]
-    test document-10.1.1 {getElementsByTagName - document element} \
-    -constraints {!dom_libxml2} -setup $SETUP -body {
-	set docTestElements [$doc getElementsByTagName Test]
-	list [llength [set $docTestElements]] [$top isSameNode [lindex [set $docTestElements] 0]]
-    } -cleanup $CLEANUP -result [list 1 1]
-
-    test document-10.3 {getElementsByTagName - continued} \
-    -constraints {!dom_libxml2} -setup $SETUP10 -body {
-	set docTestElements [$doc getElementsByTagName Test]
-	set result [set $docTestElements]
-	list [llength $result] [compareNodeList $result [list $top $child3]]
-    } -cleanup $CLEANUP -result [list 2 1]
-
-    test document-10.4 {getElementsByTagName - element} \
-    -constraints {!dom_libxml2} -setup $SETUP10 -body {
-	set result [::dom::document getElementsByTagName $top Child2]
-	list [llength [set $result]] [compareNodeList [set $result] [list $child2]]
-    } -cleanup $CLEANUP -result [list 1 1]
-
-    test document-10.5 {getElementsByTagName - remove node} \
-    -constraints {!dom_libxml2} -setup $SETUP10 -body {
-	set docTestElements [$doc getElementsByTagName Test]
-	dom::node removeChild $top $child3
-	list [llength [set $docTestElements]] [compareNodeList [set $docTestElements] [list $top]]
-    } -cleanup $CLEANUP -result [list 1 1]
-
-    test document-10.6 {getElementsByTagName - read-only variable} \
-    -constraints {!dom_libxml2} -match glob -setup $SETUP10 -body {
-	set docTestElements [$doc getElementsByTagName Test]
-	expectError {
-	    lappend $docTestElements -foo-
-	}
-    } -cleanup $CLEANUP -result {*: Read-only variable}
-
-    test document-10.7 {getElementsByTagName - unset variable} -constraints {!dom_libxml2 && knownBug} -setup $SETUP10 -body {
-	set docTestElements [$doc getElementsByTagName Test]
-	unset $docTestElements
-	ok
-    } -cleanup $CLEANUP -result {}
-
-    test document-11.1 {importNode} -constraints {dom_c} -body {
-	set testXML "<?xml version=\"1.0\"?><Test><a>aaa<b>bbb</b>aaa</a></Test>"
-	# bug 3620
-	global testXML
-	set doc [::dom::DOMImplementation parse $testXML]
-	set copy [::dom::DOMImplementation create]
-	set root [::dom::document cget $doc -documentElement]
-	set result [catch {::dom::document importNode $copy $root -deep 1} node]
-	::dom::node insert $copy $node
-	set xml [::dom::DOMImplementation serialize $copy]
-	list $result $xml
-    } -result {0 {<?xml version='1.0'?>
-<!DOCTYPE Test>
-<Test><a>aaa<b>bbb</b>aaa</a></Test>}}
-
-    variable IMPORTSETUP {
-	set doc [dom::parse {<test><element>text</element></test>}]
-	set other [dom::parse {<other><element>import me!</element></other>}]
-	set replace [dom::selectNode $doc /test/element/text()]
-	set parent [$replace parent]
-	set with [dom::selectNode $other /other/element/text()]
-    }
-    variable IMPORTCLEANUP {
-	dom::destroy $doc
-	dom::destroy $other
-    }
-
-    test document-11.2 {importNode} -constraints {dom_c} -setup $IMPORTSETUP -match regexp -body {
-	$parent replaceChild [$doc importNode $with -deep 1] $replace
-	dom::serialize $doc
-    } -cleanup $IMPORTCLEANUP -result {.*<test><element>import me!</element></test>}
-
-    # cleanup
-    ::tcltest::cleanupTests
-}
-
-namespace delete ::dom::documentTest
-
-return
diff --git a/tclxml-3.2/tests/tcldom/element.test b/tclxml-3.2/tests/tcldom/element.test
deleted file mode 100644
index 89c11f5..0000000
--- a/tclxml-3.2/tests/tcldom/element.test
+++ /dev/null
@@ -1,138 +0,0 @@
-# Commands covered:  ::dom::element
-#
-# This file contains a collection of tests for one or more of the 
-# TclDOM commands.  Sourcing this file into Tcl runs the tests and
-# generates output for errors.  No output means no errors were found.
-#
-# Copyright (c) 2008 Explain
-# http://www.explain.com.au/
-# Copyright (c) 1998-2004 Zveno Pty Ltd.
-#
-# $Id: element.test,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require tcltest
-source [file join [tcltest::workingDirectory] tcldomutils.tcl]
-
-testPackage dom
-
-namespace eval ::dom::elementTest {
-    namespace import -force ::tcltest::*
-
-    variable SETUP {
-	set doc [dom::create]
-	set top [$doc createElement Test]
-	dom::node appendChild $doc $top
-	set e1 [$doc createElement Element]
-	$top appendChild $e1
-    }
-    variable CLEANUP {
-	dom::destroy $doc
-    }
-
-    test element-1.1 {cget -tagName} -setup $SETUP -body {
-	dom::element cget $top -tagName
-    } -cleanup $CLEANUP -result Test
-    test element-1.2 {cget -tagName} -setup $SETUP -body {
-	dom::element cget $e1 -tagName
-    } -cleanup $CLEANUP -result Element
-    test element-1.3 {error: cget -tagName on non-element node} -setup $SETUP -match glob -body {
-	expectError {
-	    dom::element cget $doc -tagName
-	}
-    } -cleanup $CLEANUP -result {malformed node token*}
-    test element-1.4 {error: cget} -setup $SETUP -match glob -body {
-	expectError {
-	    dom::element cget
-	}
-    } -cleanup $CLEANUP -result {wrong # args*}
-    test element-1.5 {error:cget} -setup $SETUP -match glob -body {
-	expectError {
-	    dom::element cget $e1
-	}
-    } -cleanup $CLEANUP -result {wrong # args*}
-
-    test element-2.1 {error: configure -tagName, read-only option} -setup $SETUP -match glob -body {
-	expectError {
-	    dom::element configure $e1 -tagName Error
-	}
-    } -cleanup $CLEANUP -result {option * cannot be modified}
-
-    test element-3.1 {setAttribute} -constraints {dom_c} -setup $SETUP -body {
-	dom::element setAttribute $e1 class success
-    } -cleanup $CLEANUP -result {}
-    test element-3.1 {setAttribute} -constraints {dom_tcl || dom_libxml2} -setup $SETUP -body {
-	dom::element setAttribute $e1 class success
-    } -cleanup $CLEANUP -result success
-    test element-3.2 {error: setAttribute, wrong number args} -setup $SETUP -match glob -body {
-	expectError {
-	    dom::element setAttribute $e1 href
-	}
-    } -cleanup $CLEANUP -result {wrong # args*}
-    # TODO: test that illegal attribute names are rejected
-
-    test element-4.1 {getAttribute} -setup {
-	eval $SETUP
-	dom::element setAttribute $e1 class success
-    } -body {
-	dom::element getAttribute $e1 class
-    } -cleanup $CLEANUP -result success
-    test element-4.2 {error: getAttribute, wrong number args} -setup $SETUP -match glob -body {
-	expectError {
-	    dom::element getAttribute $e1
-	}
-    } -cleanup $CLEANUP -result {wrong # args*}
-    test element-4.3 {getAttribute, undefined attribute} -setup $SETUP -body {
-	# According to DOM spec this should not raise an exception
-	set rc [catch {dom::element getAttribute $e1 unknown} ans]
-	list $rc $ans
-    } -cleanup $CLEANUP -result [list 0 {}]
-
-    # TODO: check that attribute values are escaped correctly
-
-    test element-5.1 {removeAttribute} -setup {
-	eval $SETUP
-	dom::element setAttribute $e1 class success
-    } -body {
-	dom::element removeAttribute $e1 class
-    } -cleanup $CLEANUP -result {}
-
-    test element-5.2 {removeAttribute a nonexistent attribute} -setup $SETUP -body {
-	dom::element removeAttribute $e1 class
-	# this should be a no-op.
-    } -cleanup $CLEANUP -result {}
-
-    # Attribute nodes are not yet implemented
-    test element-6.1 {getAttributeNode} -constraints {not_implemented} -setup $SETUP -body {
-    } -cleanup $CLEANUP -result {}
-
-    test element-7.1 {setAttributeNode} -constraints {not_implemented} -setup $SETUP -body {
-    } -cleanup $CLEANUP -result {}
-
-    test element-8.1 {removeAttributeNode} -constraints {not_implemented} -setup $SETUP -body {
-    } -cleanup $CLEANUP -result {}
-
-    test element-9.1 {getElementsByTagName} -constraints {emptyTest} -setup $SETUP -body {
-    } -cleanup $CLEANUP -result {}
-
-    test element-10.1 {normalize} -constraints {emptyTest} -setup {
-	set doc [dom::create]
-	set top [dom::document createElement $doc test]
-	dom::document createTextNode $top {First text}
-	dom::document createTextNode $top {Second text}
-    } -body {
-	$top normalize
-	list [llength [$top children]] [$top stringValue]
-    } -cleanup $CLEANUP -result [list 1 {First textSecond text}]
-
-    test element-11.1 {error: method} -setup $SETUP -match glob -body {
-	expectError {
-    	    dom::element foo $e1
-	}
-    } -cleanup $CLEANUP -result {bad method "foo": *}
-
-    cleanupTests
-}
-
-namespace delete ::dom::elementTest
-
-return
diff --git a/tclxml-3.2/tests/tcldom/events.test b/tclxml-3.2/tests/tcldom/events.test
deleted file mode 100644
index a5ccf53..0000000
--- a/tclxml-3.2/tests/tcldom/events.test
+++ /dev/null
@@ -1,501 +0,0 @@
-# Commands covered:  ::dom::event
-#
-# This file contains a collection of tests for one or more of the 
-# TclDOM commands.  Sourcing this file into Tcl runs the tests and
-# generates output for errors.  No output means no errors were found.
-#
-# Copyright (c) 2008 Explain
-# Copyright (c) 2000-2004 Zveno Pty Ltd.
-#
-# $Id: events.test,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require tcltest
-source [file join [tcltest::workingDirectory] tcldomutils.tcl]
-
-testPackage dom
-
-namespace eval ::dom::eventsTest {
-    namespace import -force ::tcltest::*
-
-    testConstraint Events \
-	[dom::DOMImplementation hasFeature Events 1.0]
-
-    # Event listener procs
-
-    proc HandleEvent evid {
-	variable data
-
-	lappend data(currNode) [dom::event cget $evid -currentNode]
-	lappend data(type) [dom::event cget $evid -type]
-	lappend data(phase) [dom::event cget $evid -eventPhase]
-	lappend data(target) [dom::event cget $evid -target]
-    }
-    proc HandleMutation evid {
-	variable data
-
-	lappend data(type) [dom::event cget $evid -type]
-	lappend data(target) [dom::event cget $evid -target]
-	lappend data(related) [$evid cget -relatedNode]
-	lappend data(prev) [$evid cget -prevValue]
-	lappend data(new) [$evid cget -newValue]
-	lappend data(attrname) [$evid cget -attrName]
-	lappend data(attrchange) [$evid cget -attrChange]
-    }
-
-    variable SETUP {
-	set doc [dom::create]
-	set top [dom::document createElement $doc Top]
-    }
-
-    variable BASICSETUP {
-	eval $SETUP
-
-	set l1 [dom::document createElement $top Node1]
-	set l2 [dom::document createElement $top Node2]
-
-	set l1_1 [dom::document createElement $l1 Node1_1]
-	set l1_2 [dom::document createElement $l1 Node1_2]
-
-	set l2_1 [dom::document createElement $l2 Node2_1]
-	set l2_2 [dom::document createElement $l2 Node2_2]
-
-	variable data
-	catch {unset data}
-	array set data {
-	    currNode {}
-	    type {}
-	    phase {}
-	    target {}
-	}
-    }
-    variable E2SETUP {
-	eval $SETUP
-	set event [$doc createEvent click]
-    }
-    variable E2UISETUP {
-	eval $SETUP
-	set event [$doc createEvent DOMActivate]
-    }
-    variable EVENTSETUP {
-	eval $SETUP
-	set event [$doc createEvent DOMActivate]
-	dom::event initUIEvent $event DOMActivate 0 1 {} 2
-    }
-    variable MOUSEEVENTSETUP {
-	eval $SETUP
-	set event [$doc createEvent click]
-	dom::event initMouseEvent $event click 0 1 {} 2 3 4 5 6 ctrl alt shift meta 7 $top
-    }
-    variable HANDLERSETUP {
-	eval $BASICSETUP
-
-	dom::node addEventListener $l1 DOMActivate [namespace code HandleEvent]
-
-	set event [$doc createEvent DOMActivate]
-	$event initUIEvent DOMActivate 1 1 {} 2
-    }
-    variable CAPTURESETUP {
-	eval $BASICSETUP
-
-	dom::node addEventListener $l1 DOMActivate [namespace code HandleEvent] -usecapture 1
-
-	set event [$doc createEvent DOMActivate]
-	$event initUIEvent DOMActivate 1 1 {} 2
-    }
-    variable CAPTUREDOCSETUP {
-	eval $BASICSETUP
-
-	dom::node addEventListener $doc DOMActivate [namespace code HandleEvent] -usecapture 1
-
-	set event [$doc createEvent DOMActivate]
-	$event initUIEvent DOMActivate 1 1 {} 2
-    }
-    variable MUTATIONSETUP {
-	eval $BASICSETUP
-
-	foreach type {DOMSubtreeModified DOMNodeInserted DOMNodeRemoved DOMNodeInsertedIntoDocument DOMNodeRemovedFromDocument DOMAttrModified DOMCharacterDataModified} {
-	    dom::node addEventListener $doc $type [namespace code HandleMutation] -usecapture 1
-	}
-    }
-    variable CLEANUP {
-	dom::destroy $doc
-	catch {unset data}
-    }
-
-    # Test:
-    #   1 creating an event
-
-    test event-1.0 {event creation} -constraints Events -setup $SETUP -body {
-	set event [dom::document createEvent $doc click]
-	dom::isNode $event
-    } -cleanup $CLEANUP -result 1
-    test event-1.0.1 {event creation} -constraints Events -setup $SETUP -body {
-	set event [$doc createEvent click]
-	dom::isNode $event
-    } -cleanup $CLEANUP -result 1
-    test event-1.1 {event creation: user-defined event type} -constraints Events -setup $SETUP -body {
-	set event [dom::document createEvent $doc myEvent]
-	dom::isNode $event
-    } -cleanup $CLEANUP -result 1
-    test event-1.2 {event creation: too few arguments} -constraints Events -match glob -setup $SETUP -body {
-	expectError {
-	    dom::document createEvent $doc
-	}
-    } -cleanup $CLEANUP -result {wrong # args:*}
-    test event-1.3 {event creation: too many arguments} -constraints Events -match glob -setup $SETUP -body {
-	expectError {
-	    dom::document createEvent $doc click here
-	}
-    } -cleanup $CLEANUP -result {wrong # args:*}
-
-    #   2 initialising an event
-
-    test event-2.0 {initialise event} -constraints Events -setup $E2SETUP -body {
-	dom::event initEvent $event click 1 1
-    } -cleanup $CLEANUP -result {}
-    test event-2.0.1 {initialise event} -constraints Events -setup $E2SETUP -body {
-	$event initEvent click 1 1
-    } -cleanup $CLEANUP -result {}
-    test event-2.1 {initialise event: user-defined type} -constraints Events -setup {
-	eval $SETUP
-	set event [dom::document createEvent $doc myEvent]
-    } -body {
-	dom::event initEvent $event myEvent 1 1
-    } -cleanup $CLEANUP -result {}
-    test event-2.2 {initialise event: too few arguments} -constraints Events -match glob -setup $E2SETUP -body {
-	expectError {
-	    dom::event initEvent $event
-	}
-    } -cleanup $CLEANUP -result {wrong # args:*}
-    test event-2.3 {initialise event: too few arguments} -constraints Events -match glob -setup $E2SETUP -body {
-	expectError {
-	    dom::event initEvent $event click
-	}
-    } -cleanup $CLEANUP -result {wrong # args:*}
-    test event-2.4 {initialise event: too few arguments} -constraints Events -match glob -setup $E2SETUP -body {
-	expectError {
-	    dom::event initEvent $event click 1
-	}
-    } -cleanup $CLEANUP -result {wrong # args:*}
-    test event-2.5 {initialise event: too many arguments} -constraints Events -match glob -setup $E2SETUP -body {
-	expectError {
-	    dom::event initEvent $event click 1 1 1
-	}
-    } -cleanup $CLEANUP -result {wrong # args:*}
-    test event-2.6 {initialise UI event} -constraints Events -setup $E2UISETUP -body {
-	dom::event initUIEvent $event DOMActivate 1 1 {} 1
-    } -cleanup $CLEANUP -result {}
-    test event-2.7 {initialise UI event: too few arguments} -constraints Events -setup $E2UISETUP -match glob -body {
-	expectError {
-	    dom::event initUIEvent $event DOMActivate 1 1
-	}
-    } -cleanup $CLEANUP -result {wrong # args:*}
-    test event-2.8 {initialise UI event: no optional arguments} -constraints Events -setup $E2UISETUP -body {
-	dom::event initUIEvent $event DOMActivate 1 1 {}
-    } -cleanup $CLEANUP -result {}
-    test event-2.9 {initialise UI event: too many arguments} -constraints Events -setup $E2UISETUP -match glob -body {
-	expectError {
-	    dom::event initUIEvent $event DOMActivate 1 1 {} 2 extra
-	}
-    } -cleanup $CLEANUP -result {wrong # args:*}
-    test event-2.10 {initialise mouse event} -constraints Events -setup $E2SETUP -body {
-	dom::event initMouseEvent $event click 1 1 {} 1 100 100 10 10 {} {} {} {} 2 {}
-    } -cleanup $CLEANUP -result {}
-    test event-2.11 {initialise mouse event: too few arguments} -constraints Events -match glob -setup {
-	eval $SETUP
-	set event [dom::document createEvent $doc mousedown]
-    } -body {
-	expectError {
-	    dom::event initMouseEvent $event
-	}
-    } -cleanup $CLEANUP -result {wrong # args:*}
-    test event-2.12 {initialise mouse event: too few arguments} -constraints Events -match glob -setup {
-	eval $SETUP
-	set event [dom::document createEvent $doc mouseup]
-    } -body {
-	expectError {
-	    dom::event initMouseEvent $event mouseup 1 1 {} 2 200 100 20 30
-	}
-    } -cleanup $CLEANUP -result {wrong # args:*}
-    test event-2.13 {initialise mouse event: too many arguments} -constraints Events -match glob -setup {
-	eval $SETUP
-	set event [dom::document createEvent $doc mouseover]
-    } -body {
-	expectError {
-	    dom::event initMouseEvent $event mouseover 1 1 {} 1 100 100 10 10 {} {} {} {} 2 {} toomany
-	}
-    } -cleanup $CLEANUP -result {wrong # args:*}
-    test event-2.14 {initialise mutation event} -constraints Events -setup {
-	eval $SETUP
-	set event [dom::document createEvent $doc DOMSubtreeModified]
-    } -body {
-	dom::event initMutationEvent $event click 1 1 {} {} {} {} {}
-    } -cleanup $CLEANUP -result {}
-    test event-2.15 {initialise mutation event: too few arguments} -constraints Events -match glob -setup {
-	eval $SETUP
-	set event [dom::document createEvent $doc DOMNodeInserted]
-    } -body {
-	expectError {
-	    dom::event initMutationEvent $event
-	}
-    } -cleanup $CLEANUP -result {wrong # args:*}
-    test event-2.16 {initialise mutation event: too few arguments} -constraints Events -match glob -setup {
-	eval $SETUP
-	set event [dom::document createEvent $doc DOMNodeRemoved]
-    } -body {
-	expectError {
-	    dom::event initMutationEvent $event DOMNodeRemoved 1 1 {}
-	}
-    } -cleanup $CLEANUP -result {wrong # args:*}
-    test event-2.17 {initialise mutation event: too many arguments} -constraints Events -match glob -setup {
-	eval $SETUP
-	set event [dom::document createEvent $doc DOMAttrModified]
-    } -body {
-	expectError {
-	    dom::event initMutationEvent $event DOMAttrModified 1 1 $top old new my_attribute change extra
-	}
-    } -cleanup $CLEANUP -result {wrong # args:*}
-
-    #   3 the event command
-
-    test event-3.1 {dom::event command} -constraints Events -setup $SETUP -body {
-	set event [dom::document createEvent $doc DOMActivate]
-	$event initEvent DOMActivate 1 1
-    } -cleanup $CLEANUP -result {}
-    test event-3.2 {dom::event cget -type} -constraints Events -setup $EVENTSETUP -body {
-	dom::event cget $event -type
-    } -cleanup $CLEANUP -result DOMActivate
-    test event-3.2.1 {dom::event cget -type} -constraints Events -setup $EVENTSETUP -body {
-	$event cget -type
-    } -cleanup $CLEANUP -result DOMActivate
-    test event-3.3 {dom::event cget -target} -constraints Events -setup $EVENTSETUP -body {
-	$event cget -target
-    } -cleanup $CLEANUP -result {}
-    test event-3.4 {dom::event cget -currentNode} -constraints Events -setup $EVENTSETUP -body {
-	$event cget -currentNode
-    } -cleanup $CLEANUP -result {}
-    test event-3.5 {dom::event cget -eventPhase} -constraints Events -setup $EVENTSETUP -body {
-	$event cget -eventPhase
-    } -cleanup $CLEANUP -result {}
-    test event-3.6 {dom::event cget -bubbles} -constraints Events -setup $EVENTSETUP -body {
-	$event cget -bubbles
-    } -cleanup $CLEANUP -result 0
-    test event-3.7 {dom::event cget -cancelable} -constraints Events -setup $EVENTSETUP -body {
-	$event cget -cancelable
-    } -cleanup $CLEANUP -result 1
-    test event-3.8 {dom::event cget -timeStamp} -constraints Events -match regexp -setup $EVENTSETUP -body {
-	$event cget -timeStamp
-    } -cleanup $CLEANUP -result {[0-9]+}
-    test event-3.9 {dom::event cget -detail} -constraints Events -setup $EVENTSETUP -body {
-	$event cget -detail
-    } -cleanup $CLEANUP -result 2
-    test event-3.10 {dom::event cget -view} -constraints Events -setup $EVENTSETUP -body {
-	$event cget -view
-    } -cleanup $CLEANUP -result {}
-    test event-3.11 {dom::event cget -screenX} -constraints Events -setup $MOUSEEVENTSETUP -body {
-	$event cget -screenX
-    } -cleanup $CLEANUP -result 3
-    test event-3.12 {dom::event cget -screenY} -constraints Events -setup $MOUSEEVENTSETUP -body {
-	$event cget -screenY
-    } -cleanup $CLEANUP -result 4
-    test event-3.13 {dom::event cget -clientX} -constraints Events -setup $MOUSEEVENTSETUP -body {
-	$event cget -clientX
-    } -cleanup $CLEANUP -result 5
-    test event-3.14 {dom::event cget -clientY} -constraints Events -setup $MOUSEEVENTSETUP -body {
-	$event cget -clientY
-    } -cleanup $CLEANUP -result 6
-    test event-3.15 {dom::event cget -ctrlKey} -constraints Events -setup $MOUSEEVENTSETUP -body {
-	$event cget -ctrlKey
-    } -cleanup $CLEANUP -result ctrl
-    test event-3.16 {dom::event cget -altKey} -constraints Events -setup $MOUSEEVENTSETUP -body {
-	$event cget -altKey
-    } -cleanup $CLEANUP -result alt
-    test event-3.17 {dom::event cget -shiftKey} -constraints Events -setup $MOUSEEVENTSETUP -body {
-	$event cget -shiftKey
-    } -cleanup $CLEANUP -result shift
-    test event-3.18 {dom::event cget -metaKey} -constraints Events -setup $MOUSEEVENTSETUP -body {
-	$event cget -metaKey
-    } -cleanup $CLEANUP -result meta
-    test event-3.19 {dom::event cget -button} -constraints Events -setup $MOUSEEVENTSETUP -body {
-	$event cget -button
-    } -cleanup $CLEANUP -result 7
-    test event-3.20 {dom::event cget -relatedNode} -constraints Events -setup $MOUSEEVENTSETUP -body {
-	$top isSameNode [$event cget -relatedNode]
-    } -cleanup $CLEANUP -result 1
-    # TODO: options read-only
-
-    #   4 destroying an event
-
-    test event-4.1 {destroy event} -constraints Events -setup $EVENTSETUP -body {
-	dom::destroy $event
-	list [dom::isNode $event] [info commands $event]
-    } -cleanup $CLEANUP -result {0 {}}
-    test event-4.2 {destroy event: delete Tcl command} -constraints Events -setup $EVENTSETUP -match glob -body {
-	rename $event {}
-	dom::isNode $event
-    } -cleanup $CLEANUP -result 0
-
-    #   5 adding an event listener
-
-    test event-5.1 {register event listener} -constraints {Events} -setup $BASICSETUP -body {
-	dom::node addEventListener $l1_1 click HandleEvent
-    } -cleanup $CLEANUP -result {}
-    test event-5.2 {register capturing event listener} -constraints {Events} -setup $BASICSETUP -body {
-	dom::node addEventListener $l1_1 click HandleEvent -usecapture 1
-    } -cleanup $CLEANUP -result {}
-    test event-5.3 {get event listener} -constraints {Events} -setup {
-	eval $BASICSETUP
-	dom::node addEventListener $l1_1 click HandleEvent
-    } -body {
-	dom::node addEventListener $l1_1 click
-    } -cleanup $CLEANUP -result {HandleEvent}
-    test event-5.4 {get event listener - bubbling vs capturing events} -constraints {Events} -setup {
-	eval $BASICSETUP
-	dom::node addEventListener $l1_1 click HandleEvent
-    } -body {
-	dom::node addEventListener $l1_1 click -usecapture 1
-    } -cleanup $CLEANUP -result {}
-    test event-5.5 {get event listener} -constraints {Events} -setup {
-	eval $BASICSETUP
-	dom::node addEventListener $l1_1 click HandleEvent -usecapture 1
-    } -body {
-	dom::node addEventListener $l1_1 click -usecapture 1
-    } -cleanup $CLEANUP -result {HandleEvent}
-    test event-5.6 {get event listener - bubbling vs capturing events} -constraints {Events} -setup {
-	eval $BASICSETUP
-	dom::node addEventListener $l1_1 click HandleEvent -usecapture 1
-    } -body {
-	dom::node addEventListener $l1_1 click
-    } -cleanup $CLEANUP -result {}
-    test event-5.7 {get event listener: multiple listeners} -constraints {Events} -setup {
-	eval $BASICSETUP
-	dom::node addEventListener $l1_1 click HandleEvent
-	dom::node addEventListener $l1_1 click YetAnotherEventListener
-    } -body {
-	lsort [dom::node addEventListener $l1_1 click]
-    } -cleanup $CLEANUP -result {HandleEvent YetAnotherEventListener}
-    test event-5.8 {register event listener: too few arguments} -constraints {Events} -match glob -setup $BASICSETUP -body {
-	expectError {
-	    dom::node addEventListener $l1_1
-	}
-    } -cleanup $CLEANUP -result {wrong # args:*}
-    test event-5.9 {register event listener: too many arguments} -constraints {Events} -match glob -setup $BASICSETUP -body {
-	expectError {
-	    dom::node addEventListener $l1_1 click HandleEvent tooMany
-	}
-    } -cleanup $CLEANUP -result {missing value*}
-
-    #   6 removing an event listener
-
-    test event-6.1 {remove event listener} -constraints Events -setup {
-	eval $BASICSETUP
-	$l1_1 addEventListener click HandleEvent
-    } -body {
-	dom::node removeEventListener $l1_1 click HandleEvent
-    } -cleanup $CLEANUP -result {}
-    test event-6.2 {remove capturing event listener} -constraints {Events} -setup {
-	eval $BASICSETUP
-	$l1_1 addEventListener click HandleEvent -usecapture 1
-    } -body {
-	dom::node removeEventListener $l1_1 click HandleEvent -usecapture 1
-    } -cleanup $CLEANUP -result {}
-    test event-6.3 {remove event listener: multiple listeners} -constraints Events -setup {
-	eval $BASICSETUP
-	$l1_1 addEventListener click HandleEvent
-	$l1_1 addEventListener click YetAnotherEventHandler
-    } -body {
-	dom::node removeEventListener $l1_1 click HandleEvent
-	$l1_1 addEventListener click
-    } -cleanup $CLEANUP -result YetAnotherEventHandler
-
-    #   7 dispatching an event, w/- and w/o a listener
-
-    test event-7.1 {dispatch an event, bubbling listener} -constraints {Events} -setup $HANDLERSETUP -body {
-	$l1_1 dispatchEvent $event
-	list [$l1 isSameNode $data(currNode)] $data(type) $data(phase) [$l1_1 isSameNode $data(target)]
-    } -cleanup $CLEANUP -result {1 DOMActivate bubbling_phase 1}
-    test event-7.2 {dispatch an event, capturing listener, doc} -constraints {Events} -setup $CAPTUREDOCSETUP -body {
-	$l1_1 dispatchEvent $event
-	list [dom::node isSameNode $doc $data(currNode)] $data(type) $data(phase) [$l1_1 isSameNode $data(target)]
-    } -cleanup $CLEANUP -result {1 DOMActivate capturing_phase 1}
-    test event-7.3 {dispatch an event, capturing listener, node} -constraints {Events} -setup $CAPTURESETUP -body {
-	$l1_1 dispatchEvent $event
-	list [dom::node isSameNode $l1 $data(currNode)] $data(type) $data(phase) [$l1_1 isSameNode $data(target)]
-    } -cleanup $CLEANUP -result {1 DOMActivate capturing_phase 1}
-    test event-7.4 {dispatch an event, no listener} -constraints {Events} -setup {
-	eval $BASICSETUP
-	set event [$doc createEvent DOMActivate]
-	dom::event initUIEvent $event DOMActivate 0 1 {} 2
-    } -body {
-	$l1_1 dispatchEvent $event
-	llength $data(type)
-    } -cleanup $CLEANUP -result 0
-    test event-7.5 {dispatch an event, user-defined type} -constraints {Events} -setup {
-	eval $BASICSETUP
-	$l1 addEventListener test [namespace code HandleEvent]
-	set event [$doc createEvent test]
-	dom::event initEvent $event test 1 1
-    } -body {
-	$l1_1 dispatchEvent $event
-	list [dom::node isSameNode $l1 $data(currNode)] $data(type) $data(phase) [$l1_1 isSameNode $data(target)]
-    } -cleanup $CLEANUP -result {1 test bubbling_phase 1}
-
-    #   7.X cancelling propagation: cancel allowed, cancel not allowed
-    #   7.X no bubbles option: make sure bubbling phase does not occur
-
-    #	8 posting an event, w/- and w/o a listener
-
-    test event-8.1 {Post UI event} -constraints {Events} -setup {
-	eval $BASICSETUP
-	dom::node addEventListener $doc DOMActivate [namespace code HandleEvent]
-    } -body {
-	dom::event postUIEvent $l1_1 DOMActivate -detail 2
-	list [dom::node isSameNode $doc $data(currNode)] $data(type) $data(phase) [$l1_1 isSameNode $data(target)]
-    } -cleanup $CLEANUP -result {1 DOMActivate bubbling_phase 1}
-    test event-8.2 {Post mouse event} -constraints {Events} -setup {
-	eval $BASICSETUP
-	dom::node addEventListener $doc click [namespace code HandleEvent]
-    } -body {
-	dom::event postMouseEvent $l1_1 click -button 3
-	list [dom::node isSameNode $doc $data(currNode)] $data(type) $data(phase) [$l1_1 isSameNode $data(target)]
-    } -cleanup $CLEANUP -result {1 click bubbling_phase 1}
-    test event-8.3 {Post mutation event} -constraints {Events} -setup {
-	eval $BASICSETUP
-	dom::node addEventListener $doc DOMSubtreeModified [namespace code HandleEvent]
-    } -body {
-	dom::event postMutationEvent $l1_1 DOMSubtreeModified -relatedNode $l1
-	list [dom::node isSameNode $doc $data(currNode)] $data(type) $data(phase) [$l1_1 isSameNode $data(target)]
-    } -cleanup $CLEANUP -result {1 DOMSubtreeModified bubbling_phase 1}
-
-    #  9 Mutation events
-
-    test event-9.1 {Mutation event: insert node} -constraints {Events} -setup $MUTATIONSETUP -body {
-	set new [dom::document createElement $top New]
-	list $data(type) \
-	    [list [$new isSameNode [lindex $data(target) 0]] [$new isSameNode [lindex $data(target) 1]] [$top isSameNode [lindex $data(target) 2]]] \
-	    [list [$top isSameNode [lindex $data(related) 0]] [lindex $data(related) 1] [lindex $data(related) 2]] \
-	    $data(prev) $data(new) $data(attrname) $data(attrchange)
-    } -cleanup $CLEANUP -result {{DOMNodeInserted DOMNodeInsertedIntoDocument DOMSubtreeModified} {1 1 1} {1 {} {}} {{} {} {}} {{} {} {}} {{} {} {}} {{} {} {}}}
-    test event-9.2 {Mutation event: move node} -constraints {Events} -setup $MUTATIONSETUP -body {
-	$l2 appendChild $l1_1
-	list $data(type) \
-	    [list [$l1_1 isSameNode [lindex $data(target) 0]] [$l1 isSameNode [lindex $data(target) 1]] [$l2 isSameNode [lindex $data(target) 2]] [$l1_1 isSameNode [lindex $data(target) 3]]] \
-	    [list [$l1 isSameNode [lindex $data(related) 0]] [lindex $data(related) 1] [lindex $data(related) 2] [lindex $data(related) 3]] \
-	    $data(prev) $data(new) $data(attrname) $data(attrchange)
-    } -cleanup $CLEANUP -result {{DOMNodeRemoved DOMSubtreeModified DOMSubtreeModified DOMNodeInserted} {1 1 1 1} {1 {} {} {}} {{} {} {} {}} {{} {} {} {}} {{} {} {} {}} {{} {} {} {}}}
-    test event-9.3 {Mutation event: replace node} -constraints {Events} -setup $MUTATIONSETUP -body {
-	$l2 replaceChild $l1_1 $l2_1
-	list $data(type) \
-	    [list [$l1_1 isSameNode [lindex $data(target) 0]] [$l1 isSameNode [lindex $data(target) 1]] [$l1_1 isSameNode [lindex $data(target) 2]]] \
-	    [list [$l1 isSameNode [lindex $data(related) 0]] [lindex $data(related) 1] [lindex $data(related) 2]] \
-	    $data(prev) $data(new) $data(attrname) $data(attrchange)
-    } -cleanup $CLEANUP -result {{DOMNodeRemoved DOMSubtreeModified DOMNodeInserted} {1 1 1} {1 {} {}} {{} {} {}} {{} {} {}} {{} {} {}} {{} {} {}}}
-    # removeChild
-    # attributes: create, change, remove
-
-    cleanupTests
-}
-
-namespace delete ::dom::eventsTest
-
-return
diff --git a/tclxml-3.2/tests/tcldom/iterator.test b/tclxml-3.2/tests/tcldom/iterator.test
deleted file mode 100644
index ae1a80d..0000000
--- a/tclxml-3.2/tests/tcldom/iterator.test
+++ /dev/null
@@ -1,680 +0,0 @@
-# Commands covered:  ::dom::nodeIterator
-#
-# This file contains a collection of tests for one or more of the 
-# TclDOM commands.  Sourcing this file into Tcl runs the tests and
-# generates output for errors.  No output means no errors were found.
-#
-# Copyright (c) 2008 Explain
-# Copyright (c) 1999-2000 Ajuba Solutions
-#
-# $Id: iterator.test,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require tcltest
-source [file join [tcltest::workingDirectory] tcldomutils.tcl]
-
-testPackage dom
-
-namespace eval ::dom::iteratorTest {
-    namespace import -force ::tcltest::*
-
-    proc IterateXML {xml showList} {
-        set document [::dom::DOMImplementation parse $xml]
-	set iterator [dom::DocumentTraversal createNodeIterator $document \
-		-show $showList]
-	set result {}
-	for {set i 0} {$i < 50} {incr i} {
-		set node [dom::nodeIterator nextNode $iterator]
-		if {$node == ""} break;
-		if {[dom::node cget $node -nodeName] != "#text"} {
-			lappend result [dom::node cget $node -nodeName]
-		} else {
-			lappend result [dom::node cget $node -nodeValue]
-		}
-	}
-	for {set i 0} {$i < 50} {incr i} {
-		set node [dom::nodeIterator previousNode $iterator]
-		if {$node == ""} break;
-		if {[dom::node cget $node -nodeName] != "#text"} {
-			lappend result [dom::node cget $node -nodeName]
-		} else {
-			lappend result [dom::node cget $node -nodeValue]
-		}
-	}
-	return $result
-    }
-
-    set xml1 {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test>This <b>is</b>text.<A>aaa<B>bbb</B><C>ccc<D>ddd</D>ccc2</C>aaa2</A></Test>}
-
-    test iterator-1.1 {argument parsing} -constraints {dom_c} -body {
-        list [catch {dom::nodeIterator} msg] $msg
-} -result {1 {wrong # args: should be "dom::nodeIterator method handle ?arg ...?"}}
-    test iterator-1.2 {argument parsing} -constraints {dom_c} -body {
-        list [catch {dom::nodeIterator foo} msg] $msg
-} -result {1 {bad method "foo": must be cget, configure, previousNode, or nextNode}}
-    test iterator-1.3 {argument parsing} -constraints {dom_c} -body {
-        list [catch {dom::nodeIterator cget blah} msg] $msg
-} -result {1 {token not found}}
-
-    test iterator-2.1 {iterator creation} -constraints {dom_c} -body {
-        set document [::dom::DOMImplementation parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test></Test>}]
-	set result [catch {dom::DocumentTraversal createNodeIterator $document} \
-	    iterator]
-	set handle [string range $iterator 0 7]
-	list $result $handle
-} -result {0 iterator}
-
-    test iterator-2.2 {iterator creation} -constraints {dom_c} -body {
-        set document [::dom::DOMImplementation parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test></Test>}]
-	set iterator [dom::DocumentTraversal createNodeIterator $document]
-	set result [catch {dom::nodeIterator nextNode $iterator} first]
-	set handle [string range $first 0 3]
-	list $result $handle
-} -result {0 node}
-
-    test iterator-3.1 {iterator cget -show} -constraints {dom_c} -body {
-        set document [::dom::DOMImplementation parse {<?xml version="1.0"?><A></A>}]
-	set iterator [dom::DocumentTraversal createNodeIterator $document -show \
-		[list element textNode]]
-	set result [catch {::dom::nodeIterator cget $iterator -show} value]
-	list $result $value
-} -result {0 {element textNode}}
-
-    test iterator-3.2 {iterator configure -show} -constraints {dom_c} -body {
-        set document [::dom::DOMImplementation parse {<?xml version="1.0"?><A></A>}]
-	set iterator [dom::DocumentTraversal createNodeIterator $document -show \
-		[list element textNode]]
-	set result [catch {::dom::nodeIterator configure $iterator -show} value]
-	list $result $value
-} -result {0 {element textNode}}
-
-    test iterator-3.3 {iterator configure -show readonly} -constraints {dom_c} -body {
-        set document [::dom::DOMImplementation parse {<?xml version="1.0"?><A></A>}]
-	set iterator [dom::DocumentTraversal createNodeIterator $document -show \
-		[list element textNode]]
-	set result [catch {::dom::nodeIterator configure $iterator \
-		-show [list element]} value]
-	list $result $value
-} -result {1 {no modification allowed error: an attempt was made to modify an object where modifications are not allowed}}
-
-    test iterator-3.4 {iterator cget -filter} -constraints {dom_c} -body {
-        set document [::dom::DOMImplementation parse {<?xml version="1.0"?><A></A>}]
-	set iterator [dom::DocumentTraversal createNodeIterator $document \
-		-filter nodeFilter]
-	set result [catch {::dom::nodeIterator cget $iterator -filter} value]
-	list $result $value
-} -result {0 nodeFilter}
-
-    test iterator-3.5 {iterator configure -filter} -constraints {dom_c} -body {
-        set document [::dom::DOMImplementation parse {<?xml version="1.0"?><A></A>}]
-	set iterator [dom::DocumentTraversal createNodeIterator $document \
-		-filter nodeFilter]
-	set result [catch {::dom::nodeIterator configure $iterator -filter} value]
-	list $result $value
-} -result {0 nodeFilter}
-
-    test iterator-3.6 {iterator configure -filter readonly} -constraints {dom_c} -body {
-        set document [::dom::DOMImplementation parse {<?xml version="1.0"?><A></A>}]
-	set iterator [dom::DocumentTraversal createNodeIterator $document \
-		-filter nodeFilter]
-	set result [catch {::dom::nodeIterator configure $iterator \
-		-filter someFilter} value]
-	list $result $value
-} -result {1 {no modification allowed error: an attempt was made to modify an object where modifications are not allowed}}
-
-    test iterator-3.7 {iterator cget -expandEntities} -constraints {dom_c} -body {
-        set document [::dom::DOMImplementation parse {<?xml version="1.0"?><A></A>}]
-	set iterator [dom::DocumentTraversal createNodeIterator $document]
-	set result [catch {::dom::nodeIterator cget $iterator \
-		-expandEntities} value]
-	list $result $value
-} -result {0 0}
-
-    test iterator-3.8 {iterator configure -expandEntities} -constraints {dom_c} -body {
-        set document [::dom::DOMImplementation parse {<?xml version="1.0"?><A></A>}]
-	set iterator [dom::DocumentTraversal createNodeIterator $document]
-	set result [catch {::dom::nodeIterator configure $iterator \
-		-expandEntities} value]
-	list $result $value
-} -result {0 0}
-
-    test iterator-3.9 {iterator configure -expandEntities readonly} -constraints {dom_c} -body {
-        set document [::dom::DOMImplementation parse {<?xml version="1.0"?><A></A>}]
-	set iterator [dom::DocumentTraversal createNodeIterator $document]
-	set result [catch {::dom::nodeIterator configure $iterator \
-		-expandEntities 1} value]
-	list $result $value
-} -result {1 {no modification allowed error: an attempt was made to modify an object where modifications are not allowed}}
-
-    test iterator-4.1 {basic iteration} -constraints {dom_c} -body {
-        set document [::dom::DOMImplementation parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test>This <b>is</b>text.</Test>}]
-	set iterator [dom::DocumentTraversal createNodeIterator $document]
-	set result {}
-	for {set i 0} {$i < 9} {incr i} {
-		set node [dom::nodeIterator nextNode $iterator]
-		if {$node == ""} break;
-		lappend result [dom::node cget $node -nodeType]
-		lappend result [dom::node cget $node -nodeName]
-		lappend result [dom::node cget $node -nodeValue]
-	}
-	set result	
-} -result {document #document {} documentType Test {} element Test {} textNode #text {This } element b {} textNode #text is textNode #text text.}
-
-    test iterator-4.2 {basic iteration with -show} -constraints {dom_c} -body {
-        set document [::dom::DOMImplementation parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test>This <b>is</b>text.</Test>}]
-	set iterator [dom::DocumentTraversal createNodeIterator $document \
-		-show [list element textNode]]
-	set result {}
-	for {set i 0} {$i < 9} {incr i} {
-		set node [dom::nodeIterator nextNode $iterator]
-		if {$node == ""} break;
-		lappend result [dom::node cget $node -nodeType]
-		lappend result [dom::node cget $node -nodeName]
-		lappend result [dom::node cget $node -nodeValue]
-	}
-	set result	
-} -result {element Test {} textNode #text {This } element b {} textNode #text is textNode #text text.}
-
-    test iterator-4.3 {basic reverse iteration} -constraints {dom_c} -body {
-        set document [::dom::DOMImplementation parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test>This <b>is</b>text.</Test>}]
-	set iterator [dom::DocumentTraversal createNodeIterator $document]
-	set result {}
-	for {set i 0} {$i < 9} {incr i} {
-		set node [dom::nodeIterator nextNode $iterator]
-		if {$node == ""} break;
-	}
-	for {set i 0} {$i < 9} {incr i} {
-		set node [dom::nodeIterator previousNode $iterator]
-		if {$node == ""} break;
-		lappend result [dom::node cget $node -nodeType]
-		lappend result [dom::node cget $node -nodeName]
-		lappend result [dom::node cget $node -nodeValue]
-	}
-	set result	
-} -result {textNode #text text. textNode #text is element b {} textNode #text {This } element Test {} documentType Test {} document #document {}}
-
-    test iterator-4.4 {basic reverse iteration with -show} -constraints {dom_c} -body {
-        set document [::dom::DOMImplementation parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test>This <b>is</b>text.</Test>}]
-	set iterator [dom::DocumentTraversal createNodeIterator $document \
-		-show [list element textNode]]
-	set result {}
-	for {set i 0} {$i < 9} {incr i} {
-		set node [dom::nodeIterator nextNode $iterator]
-		if {$node == ""} break;
-	}
-	for {set i 0} {$i < 9} {incr i} {
-		set node [dom::nodeIterator previousNode $iterator]
-		if {$node == ""} break;
-		lappend result [dom::node cget $node -nodeType]
-		lappend result [dom::node cget $node -nodeName]
-		lappend result [dom::node cget $node -nodeValue]
-	}
-	set result	
-} -result {textNode #text text. textNode #text is element b {} textNode #text {This } element Test {}}
-
-    test iterator-4.5 {complex iteration} -constraints {dom_c} -body {
-        set document [::dom::DOMImplementation parse $xml1]
-	set iterator [dom::DocumentTraversal createNodeIterator $document]
-	set result {}
-	for {set i 0} {$i < 40} {incr i} {
-		set node [dom::nodeIterator nextNode $iterator]
-		if {$node == ""} break;
-		set name [dom::node cget $node -nodeName]
-		if {$name != "#text"} {
-			lappend result $name
-		} else {
-			lappend result [dom::node cget $node -nodeValue]
-		}
-	}
-	set result	
-} -result {#document Test Test {This } b is text. A aaa B bbb C ccc D ddd ccc2 aaa2}
-
-    test iterator-4.6 {complex iteration} -constraints {dom_c} -body {
-        set document [::dom::DOMImplementation parse $xml1]
-	set iterator [dom::DocumentTraversal createNodeIterator $document]
-	set result {}
-	for {set i 0} {$i < 40} {incr i} {
-		set node [dom::nodeIterator nextNode $iterator]
-		if {$node == ""} break;
-	}
-	for {set i 0} {$i < 40} {incr i} {
-		set node [dom::nodeIterator previousNode $iterator]
-		if {$node == ""} break;
-		set name [dom::node cget $node -nodeName]
-		if {$name != "#text"} {
-			lappend result $name
-		} else {
-			lappend result [dom::node cget $node -nodeValue]
-		}
-	}
-	set result	
-} -result {aaa2 ccc2 ddd D ccc C bbb B aaa A text. is b {This } Test Test #document}
-
-    test iterator-4.7 {basic iteration both directions} -constraints {dom_c} -body {
-        set document [::dom::DOMImplementation parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test>This <b>is</b>text.</Test>}]
-	set iterator [dom::DocumentTraversal createNodeIterator $document]
-	set result {}
-	set node [dom::nodeIterator nextNode $iterator]
-	lappend result [dom::node cget $node -nodeName]
-	set node [dom::nodeIterator previousNode $iterator]
-	lappend result [dom::node cget $node -nodeName]
-	set result	
-} -result {#document #document}
-
-    test iterator-4.8 {backup before start of list} -constraints {dom_c} -body {
-        set document [::dom::DOMImplementation parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test>This <b>is</b>text.</Test>}]
-	set iterator [dom::DocumentTraversal createNodeIterator $document]
-	set result {}
-	set node [dom::nodeIterator previousNode $iterator]
-	set	node
-} -result {}
-
-    test iterator-4.9 {backup before start of list then forward} -constraints {dom_c} -body {
-        set document [::dom::DOMImplementation parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test>This <b>is</b>text.</Test>}]
-	set iterator [dom::DocumentTraversal createNodeIterator $document]
-	set result {}
-	set node [dom::nodeIterator previousNode $iterator]
-	set node [dom::nodeIterator previousNode $iterator]
-	set node [dom::nodeIterator previousNode $iterator]
-	set node [dom::nodeIterator previousNode $iterator]
-	set node [dom::nodeIterator nextNode $iterator]
-	lappend result [dom::node cget $node -nodeName]
-	set	result
-} -result {#document}
-
-    test iterator-4.10 {inserts while iterating} -constraints {dom_c} -body {
-        set document [::dom::DOMImplementation parse $xml1]
-	set iterator [dom::DocumentTraversal createNodeIterator $document]
-	set result {}
-	for {set i 0} {$i < 40} {incr i} {
-		set node [dom::nodeIterator nextNode $iterator]
-		if {$node == ""} break
-		set name [dom::node cget $node -nodeName]
-		if {$name != "#text"} {
-			lappend result $name
-			if {$name == "A"} {
-				set new [dom::document createTextNode $document "New Text"]
-				dom::node insertBefore $node $new \
-					[dom::node cget $node -firstChild]
-			}
-		} else {
-			lappend result [dom::node cget $node -nodeValue]
-		}
-	}
-	set result	
-} -result {#document Test Test {This } b is text. A {New Text} aaa B bbb C ccc D ddd ccc2 aaa2}
-
-    test iterator-4.11 {deletions while iterating} -constraints {dom_c} -body {
-        set document [::dom::DOMImplementation parse $xml1]
-	set iterator [dom::DocumentTraversal createNodeIterator $document]
-	set result {}
-	for {set i 0} {$i < 40} {incr i} {
-		set node [dom::nodeIterator nextNode $iterator]
-		if {$node == ""} break
-		set name [dom::node cget $node -nodeName]
-		if {$name != "#text"} {
-			lappend result $name
-			if {$name == "A"} {
-				dom::node removeChild $node [dom::node cget $node -firstChild]
-			}
-		} else {
-			lappend result [dom::node cget $node -nodeValue]
-		}
-	}
-	set result	
-} -result {#document Test Test {This } b is text. A B bbb C ccc D ddd ccc2 aaa2}
-
-    test iterator-4.12 {reference node deletion while iterating} -constraints {dom_c} -body {
-        set document [::dom::DOMImplementation parse $xml1]
-	set iterator [dom::DocumentTraversal createNodeIterator $document]
-	set result {}
-	for {set i 0} {$i < 40} {incr i} {
-		set node [dom::nodeIterator nextNode $iterator]
-		if {$node == ""} break
-		set name [dom::node cget $node -nodeName]
-		if {$name != "#text"} {
-			lappend result $name
-			if {$name == "B"} {
-				dom::node removeChild [dom::node cget $node -parent] $node
-			}
-		} else {
-			lappend result [dom::node cget $node -nodeValue]
-		}
-	}
-	set result	
-} -result {#document Test Test {This } b is text. A aaa B C ccc D ddd ccc2 aaa2}
-
-    test iterator-4.13 {reference node deletion while iterating II} -constraints {dom_c} -body {
-        set document [::dom::DOMImplementation parse $xml1]
-	set iterator [dom::DocumentTraversal createNodeIterator $document]
-	set result {}
-	for {set i 0} {$i < 40} {incr i} {
-		set node [dom::nodeIterator nextNode $iterator]
-		if {$node == ""} break
-		set name [dom::node cget $node -nodeName]
-		if {$name != "#text"} {
-			lappend result $name
-			if {$name == "C"} {
-				set nodeToDelete $node
-			} elseif {$name == "D"} {
-				dom::node removeChild [dom::node cget $nodeToDelete -parent] \
-					$nodeToDelete
-			}
-		} else {
-			lappend result [dom::node cget $node -nodeValue]
-		}
-	}
-	set result	
-} -result {#document Test Test {This } b is text. A aaa B bbb C ccc D aaa2}
-
-    test iterator-4.14 {deletion of trailing reference node} -constraints {dom_c} -body {
-        set document [::dom::DOMImplementation parse {<?xml version="1.0"?>
-<!DOCTYPE Test><Test>xxx<A/></Test>}]
-	set iterator [dom::DocumentTraversal createNodeIterator $document]
-	set result {}
-	set node {}
-	for {set i 0} {$i < 9} {incr i} {
-		set refNode $node
-		set node [dom::nodeIterator nextNode $iterator]
-		if {$node == ""} break;
-	}
-	set node [dom::nodeIterator previousNode $iterator]
-	dom::node removeChild [dom::node cget $refNode -parent] $refNode
-	set node [dom::nodeIterator previousNode $iterator]
-	lappend result [dom::node cget $node -nodeName]
-	set result
-} -result {Test}
-
-    test iterator-4.15 {complex iteration with filter} -constraints {dom_c} -body {
-	proc nodeFilter {node} {
-		set value [dom::node cget $node -nodeValue]
-		if {$value == "aaa"} {
-			return $::dom::reject 
-		} else {
-			return $::dom::accept 
-		}
-	}
-
-        set document [::dom::DOMImplementation parse $xml1]
-	set iterator [dom::DocumentTraversal createNodeIterator $document \
-		-filter nodeFilter]
-	set result {}
-	for {set i 0} {$i < 40} {incr i} {
-		set node [dom::nodeIterator nextNode $iterator]
-		if {$node == ""} break;
-		set name [dom::node cget $node -nodeName]
-		if {$name != "#text"} {
-			lappend result $name
-		} else {
-			lappend result [dom::node cget $node -nodeValue]
-		}
-	}
-	rename nodeFilter {}
-	set result	
-} -result {#document Test Test {This } b is text. A B bbb C ccc D ddd ccc2 aaa2}
-
-    test iterator-4.16 {complex iteration} -constraints {dom_c} -body {
-        set document [::dom::DOMImplementation parse $xml1]
-	set iterator [dom::DocumentTraversal createNodeIterator $document \
-		-show [list document textNode]]
-	set result {}
-	for {set i 0} {$i < 40} {incr i} {
-		set node [dom::nodeIterator nextNode $iterator]
-		if {$node == ""} break;
-	}
-	for {set i 0} {$i < 40} {incr i} {
-		set node [dom::nodeIterator previousNode $iterator]
-		if {$node == ""} break;
-		set name [dom::node cget $node -nodeName]
-		if {$name != "#text"} {
-			lappend result $name
-		} else {
-			lappend result [dom::node cget $node -nodeValue]
-		}
-	}
-	set result	
-} -result {aaa2 ccc2 ddd ccc bbb aaa text. is {This } #document}
-
-    test iterator-4.17 {complex iteration} -constraints {dom_c} -body {
-	set xml1 {<?xml version="1.0"?><!DOCTYPE Test><A>a<B>b<C>c<D>d</D></C></B></A>}
-	IterateXML $xml1 [list document element]
-} -result {#document A B C D D C B A #document}
-
-    test iterator-4.18 {complex iteration} -constraints {dom_c} -body {
-	set xml1 {<?xml version="1.0"?><!DOCTYPE Test><Test><A>a</A><B>b</B><C>c</C><D>d</D></Test>}
-	IterateXML $xml1 [list document element]
-} -result {#document Test A B C D D C B A Test #document}
-
-    test iterator-4.19 {complex iteration} -constraints {dom_c} -body {
-	IterateXML $xml1 [list document element textNode]
-} -result {#document Test A a B b C c D d d D c C b B a A Test #document}
-
-    set xml1 {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test>test<A><B><C><D><E>eee</E><F>fff</F><G>ggg</G></D>ccc<H><I>iii</I><J>jjj</J><K>kkk</K></H>ccc2</C></B></A></Test>}
-
-    test iterator-4.20 {complex iteration} -constraints {dom_c} -body {
-	IterateXML $xml1 [list document element textNode]
-} -result {#document Test test A B C D E eee F fff G ggg ccc H I iii J jjj K kkk ccc2 ccc2 kkk K jjj J iii I H ccc ggg G fff F eee E D C B A test Test #document}
-
-    test iterator-4.21 {complex iteration} -constraints {dom_c} -body {
-	IterateXML $xml1 [list document textNode]
-} -result {#document test eee fff ggg ccc iii jjj kkk ccc2 ccc2 kkk jjj iii ccc ggg fff eee test #document}
-
-    set xml1 {<?xml version="1.0"?>
-<!DOCTYPE Test><Test><A>a<B>b<C>c<D>d<E>e<F>f</F></E></D></C></B></A></Test>}
-
-    test iterator-4.22 {complex iteration} -constraints {dom_c} -body {
-	IterateXML $xml1 [list document element textNode]
-} -result {#document Test A a B b C c D d E e F f f F e E d D c C b B a A Test #document}
-
-    test iterator-4.23 {complex iteration} -constraints {dom_c} -body {
-	IterateXML $xml1 [list document textNode]
-} -result {#document a b c d e f f e d c b a #document}
-
-    set xml1 {<?xml version="1.0"?>
-<!DOCTYPE Test><Test><A><B><C><D><E><F>f</F>e</E>d</D>c</C>b</B>a</A></Test>}
-
-    test iterator-4.24 {complex iteration} -constraints {dom_c} -body {
-	IterateXML $xml1 [list document textNode]
-} -result {#document f e d c b a a b c d e f #document}
-
-    set xml1 {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test>test
-<A><B><C>
-    <D2><D3><D><E>eee</E><F>fff</F><G>ggg</G></D></D3></D2>ccc
-    <H2><H3><H><I>iii</I><J>jjj</J><K2><K3><K4><K>kkk</K></K4></K3></K2></H></H3></H2>ccc2
-</C></B></A></Test>}
-
-    test iterator-4.25 {complex iteration} -constraints {dom_c} -body {
-	IterateXML $xml1 [list document element textNode]
-} -result {#document Test {test
-} A B C {
-    } D2 D3 D E eee F fff G ggg {ccc
-    } H2 H3 H I iii J jjj K2 K3 K4 K kkk {ccc2
-} {ccc2
-} kkk K K4 K3 K2 jjj J iii I H H3 H2 {ccc
-    } ggg G fff F eee E D D3 D2 {
-    } C B A {test
-} Test #document}
-
-    set xml1 {<?xml version="1.0"?>
-<!DOCTYPE Test><Test>test<A>a<B>b<C>c<D2><D3><D><E>e</E><F>f</F><G>g</G></D></D3></D2>c2<H2><H3><H><I>i</I><J>j</J><K2><K3><K4><K>k</K></K4></K3></K2></H></H3></H2>c3</C></B></A></Test>}
-
-    test iterator-4.26 {complex iteration} -constraints {dom_c} -body {
-	IterateXML $xml1 [list document element textNode]
-} -result {#document Test test A a B b C c D2 D3 D E e F f G g c2 H2 H3 H I i J j K2 K3 K4 K k c3 c3 k K K4 K3 K2 j J i I H H3 H2 c2 g G f F e E D D3 D2 c C b B a A test Test #document}
-
-    test iterator-4.27 {complex iteration} -constraints {dom_c} -body {
-	IterateXML $xml1 [list document textNode]
-} -result {#document test a b c e f g c2 i j k c3 c3 k j i c2 g f e c b a test #document}
-
-    set xml1 {<?xml version="1.0"?>
-<!DOCTYPE Test><Test><A><B><C><D><X><x1/><x2/><x3/><E><e1/><e2/><e3/></E>x</X><F><f1/><f2/>f</F></D><G><g1/><g2/>g</G></C><H><h1/><h2/>h</H></B></A></Test>}
-
-    test iterator-4.28 {complex iteration} -constraints {dom_c} -body {
-	IterateXML $xml1 [list document element textNode]
-} -result {#document Test A B C D X x1 x2 x3 E e1 e2 e3 x F f1 f2 f G g1 g2 g H h1 h2 h h h2 h1 H g g2 g1 G f f2 f1 F x e3 e2 e1 E x3 x2 x1 X D C B A Test #document}
-
-    test iterator-4.29 {complex iteration} -constraints {dom_c} -body {
-	IterateXML $xml1 [list document textNode]
-} -result {#document x f g h h g f x #document}
-
-    set xml1 {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test>This <b>is</b>text.<A>aaa<B>bbb</B><C>ccc<D>ddd</D>ccc2</C>aaa2</A></Test>}
-
-    test iterator-4.30 {complex iteration with filter} -constraints {dom_c} -body {
-	proc nodeFilter {node} {
-		set value [dom::node cget $node -nodeName]
-		if {$value == "A"} {
-			return $::dom::reject 
-		} else {
-			return $::dom::accept
-		}
-	}
-
-        set document [::dom::DOMImplementation parse $xml1]
-	set iterator [dom::DocumentTraversal createNodeIterator $document \
-		-filter nodeFilter]
-	set result {}
-	for {set i 0} {$i < 40} {incr i} {
-		set node [dom::nodeIterator nextNode $iterator]
-		if {$node == ""} break;
-		set name [dom::node cget $node -nodeName]
-		if {$name != "#text"} {
-			lappend result $name
-		} else {
-			lappend result [dom::node cget $node -nodeValue]
-		}
-	}
-	rename nodeFilter {}
-	set result	
-} -result {#document Test Test {This } b is text. aaa B bbb C ccc D ddd ccc2 aaa2}
-
-    test iterator-4.31 {complex reverse iteration} -constraints {dom_c} -body {
-	proc nodeFilter {node} {
-		set value [dom::node cget $node -nodeName]
-		if {$value == "A"} {
-			return $::dom::reject 
-		} else {
-			return $::dom::accept
-		}
-	}
-        set document [::dom::DOMImplementation parse $xml1] 
-	set iterator [dom::DocumentTraversal createNodeIterator $document \
-		-filter nodeFilter]
-	set result {}
-	for {set i 0} {$i < 30} {incr i} {
-		set node [dom::nodeIterator nextNode $iterator]
-		if {$node == ""} break;
-	}
-	for {set i 0} {$i < 30} {incr i} {
-		set node [dom::nodeIterator previousNode $iterator]
-		if {$node == ""} break;
-		set name [dom::node cget $node -nodeName]
-		if {$name != "#text"} {
-			lappend result $name
-		} else {
-			lappend result [dom::node cget $node -nodeValue]
-		}
-	}
-	rename nodeFilter {}
-	set result	
-} -result {aaa2 ccc2 ddd D ccc C bbb B aaa text. is b {This } Test Test #document}
-
-    test iterator-5.1 {iterator destruction} -constraints {dom_c} -body {
-	global xml1
-        set document [::dom::DOMImplementation parse $xml1]
-	set iterator [dom::DocumentTraversal createNodeIterator $document]
-	set result [catch {::dom::DocumentTraversal destroy $iterator} errmsg]
-	list $result $errmsg
-} -result {0 {}}
-
-    test iterator-6.1 {delete document in filter proc} -constraints {dom_c} -body {
-	proc nodeFilter {node} {
-		global document
-		dom::DOMImplementation destroy $document
-		return $::dom::accept
-	}
-        set document [::dom::DOMImplementation parse $xml1]
-	set iterator [dom::DocumentTraversal createNodeIterator $document \
-		-filter nodeFilter]
-	set node [::dom::nodeIterator nextNode $iterator]
-	set result [catch {::dom::nodeIterator nextNode $iterator} errmsg]
-	rename nodeFilter {}
-	list $result $errmsg
-} -result {0 {}}
-
-    test iterator-6.2 {delete document in filter proc} -constraints {dom_c} -body {
-	proc nodeFilter {node} {
-		global document
-		dom::DOMImplementation destroy $document
-		return $::dom::accept
-	}
-        set document [::dom::DOMImplementation parse $xml1]
-	set iterator [dom::DocumentTraversal createNodeIterator $document \
-		-filter nodeFilter]
-	set node [::dom::nodeIterator nextNode $iterator]
-	set result [catch {::dom::node cget $node -nodeName} errmsg]
-	rename nodeFilter {}
-	list $result $errmsg
-} -result {1 {token not found}}
-
-    test iterator-6.3 {delete iterator in filter proc} -constraints {dom_c} -body {
-	proc nodeFilter {node} {
-		global iterator
-		dom::DocumentTraversal destroy $iterator
-		return $::dom::accept
-	}
-        set document [::dom::DOMImplementation parse $xml1]
-	set iterator [dom::DocumentTraversal createNodeIterator $document \
-		-filter nodeFilter]
-	set node [::dom::nodeIterator nextNode $iterator]
-	set result [catch {::dom::nodeIterator nextNode $iterator} errmsg]
-	rename nodeFilter {}
-	list $result $errmsg
-} -result {1 {token not found}}
-
-    test iterator-6.4 {recursively invoke filter proc} -constraints {dom_c} -match glob -body {
-	proc nodeFilter {node} {
-		global iterator
-		set node [::dom::nodeIterator nextNode $iterator]
-		return $::dom::accept
-	}
-	set document [::dom::DOMImplementation parse $xml1]
-	set iterator [dom::DocumentTraversal createNodeIterator $document \
-		-filter nodeFilter]
-	expectError {
-	    ::dom::nodeIterator nextNode $iterator
-	}
-    } -cleanup {
-	rename nodeFilter {}
-    } -result {too many nested calls * (infinite loop?)}
-
-    ::tcltest::cleanupTests
-}
-
-namespace delete ::dom::iteratorTest
-
-return
diff --git a/tclxml-3.2/tests/tcldom/node.test b/tclxml-3.2/tests/tcldom/node.test
deleted file mode 100644
index 070ddbc..0000000
--- a/tclxml-3.2/tests/tcldom/node.test
+++ /dev/null
@@ -1,1102 +0,0 @@
-# Commands covered:  ::dom::node
-#
-# This file contains a collection of tests for one or more of the
-# TclDOM commands.  Sourcing this file into Tcl runs the tests and
-# generates output for errors.  No output means no errors were found.
-#
-# Copyright (c) 2008 Explain
-# Copyright (c) 1998-2004 Zveno Pty Ltd.
-#
-# $Id: node.test,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require tcltest
-source [file join [tcltest::workingDirectory] tcldomutils.tcl]
-
-testPackage dom
-
-namespace eval ::dom::nodeTest {
-    namespace import -force ::tcltest::*
-
-    variable SETUP {
-	set doc [::dom::create]
-	set top [::dom::document createElement $doc Test]
-	set child1 [$top appendChild [::dom::document createElement $top Child1]]
-	set child2 [$top appendChild [::dom::document createTextNode $top Child2]]
-	set child3 [$top appendChild [::dom::document createElement $top Child3]]
-    }
-
-    variable CLEANUP {
-	dom::destroy $doc
-    }
-
-    testConstraint strictDOM [expr $::dom::strictDOM || [testConstraint dom_libxml2]]
-
-    # NB. All factory methods are tested in document.test
-
-    test node-1.1 {cget -nodeName} -setup $SETUP -body {
-	::dom::node cget $top -nodeName
-    } -cleanup $CLEANUP -result Test
-    test node-1.1.1 {cget -nodeName} -setup $SETUP -body {
-	$top cget -nodeName
-    } -cleanup $CLEANUP -result Test
-
-    test node-1.2 {configure -nodeName} -setup $SETUP -body {
-	::dom::node configure $top -nodeName
-    } -cleanup $CLEANUP -result Test
-    test node-1.2.1 {configure -nodeName} -setup $SETUP -body {
-	$top configure -nodeName
-    } -cleanup $CLEANUP -result Test
-
-    test node-1.3 {configure -nodeName readonly} -constraints strictDOM -setup $SETUP -match regexp -body {
-	expectError {
-	    ::dom::node configure $top -nodeName XXX
-	}
-    } -cleanup $CLEANUP -result {(no modification allowed error: an attempt was made to modify an object\
-	where modifications are not allowed)|(attribute "-nodeName" is read-only)}
-    test node-1.3 {configure -nodeName readonly} -constraints {!strictDOM} -setup $SETUP -body {
-	::dom::node configure $top -nodeName XXX
-	ok
-    } -cleanup $CLEANUP -result {}
-
-    test node-1.4 {configure: too many parameters} -setup $SETUP -match regexp -body {
-	expectError {
-	    ::dom::node configure $top -nodeValue XXX ZZZ
-	}
-    } -cleanup $CLEANUP -result {(wrong # args: should be "::dom::node configure node option")|()}
-    test node-1.4.1 {configure: too many parameters} -setup $SETUP -match regexp -body {
-	expectError {
-	    $top configure -nodeValue XXX ZZZ
-	}
-    } -cleanup $CLEANUP -result {(wrong # args: should be "::dom::node configure node option")|()}
-
-    test node-2.1 {argument parsing} -setup $SETUP -match glob -body {
-	expectError {
-	    dom::node
-	}
-    } -cleanup $CLEANUP -result {wrong # args*}
-    test node-2.2 {argument parsing} -setup $SETUP -match regexp -body {
-	expectError {
-	    dom::node foo
-	}
-    } -cleanup $CLEANUP -result {(bad method "foo": must be cget, configure, insertBefore, replaceChild, removeChild, appendChild, hasChildNodes, cloneNode, children, parent, path, createNode, selectNode, stringValue, addEventListener, removeEventListener, dispatchEvent, or isSameNode)|(^wrong # args.*)}
-    test node-2.3 {argument parsing} -constraints {dom_tcl} -setup $SETUP -match glob -body {
-	expectError {
-	    dom::node cget blah
-	}
-    } -cleanup $CLEANUP -result {wrong # args:*}
-    test node-2.3 {argument parsing} -constraints {dom_libxml2} -setup $SETUP -match glob -body {
-	expectError {
-	    dom::node cget blah
-	}
-    } -cleanup $CLEANUP -result {"blah" is neither a DOM document nor a DOM node}
-
-    test node-2.4 {cget -nodeType} -setup $SETUP -body {
-	::dom::node cget $top -nodeType
-    } -cleanup $CLEANUP -result element
-    test node-2.4.1 {cget -nodeType} -setup $SETUP -body {
-	$top cget -nodeType
-    } -cleanup $CLEANUP -result element
-
-    test node-2.5 {configure -nodeType} -setup $SETUP -body {
-	$top configure -nodeType
-    } -cleanup $CLEANUP -result element
-
-    test node-2.6 {configure -nodeType readonly} -match regexp -constraints {strictDOM} -setup $SETUP -match regexp -body {
-	expectError {
-	    ::dom::node configure $top -nodeType XXX
-	}
-    } -cleanup $CLEANUP -result {(no modification allowed error: an attempt was made to modify an object\
-	where modifications are not allowed)|(attribute "-nodeType" is read-only)}
-    test node-2.6 {configure -nodeType readonly} -constraints {!strictDOM} -setup $SETUP -body {
-	::dom::node configure $top -nodeName XXX
-	ok
-    } -cleanup $CLEANUP -result {}
-
-    test node-3.1 {cget -parentNode top} -setup $SETUP -body {
-	compareNodes [::dom::node cget $top -parentNode] $doc
-    } -cleanup $CLEANUP -result 1
-    test node-3.1.1 {cget -parentNode top} -setup $SETUP -body {
-	compareNodes [$top cget -parentNode] $doc
-    } -cleanup $CLEANUP -result 1
-    test node-3.2 {cget -parentNode document} -setup $SETUP -body {
-	::dom::node cget $doc -parentNode
-    } -cleanup $CLEANUP -result {}
-    test node-3.3 {cget -parentNode leaf} -setup $SETUP -body {
-	compareNodes [::dom::node cget $child1 -parentNode] $top
-    } -cleanup $CLEANUP -result 1
-    test node-3.3.1 {cget -parentNode leaf} -setup $SETUP -body {
-	compareNodes [$child1 cget -parentNode] $top
-    } -cleanup $CLEANUP -result 1
-
-    test node-3.4 {configure -parentNode top} -setup $SETUP -body {
-	compareNodes [::dom::node configure $top -parentNode] $doc
-    } -cleanup $CLEANUP -result 1
-    test node-3.4.1 {configure -parentNode top} -setup $SETUP -body {
-	compareNodes [$top configure -parentNode] $doc
-    } -cleanup $CLEANUP -result 1
-
-    test node-3.5 {cget -parentNode document} -setup $SETUP -body {
-	::dom::node configure $doc -parentNode
-    } -cleanup $CLEANUP -result {}
-
-    test node-3.6 {configure -parentNode leaf} -setup $SETUP -body {
-	compareNodes [::dom::node configure $child1 -parentNode] $top
-    } -cleanup $CLEANUP -result 1
-    test node-3.6.1 {configure -parentNode leaf} -setup $SETUP -body {
-	compareNodes [$child1 configure -parentNode] $top
-    } -cleanup $CLEANUP -result 1
-
-    test node-3.7 {configure -parentNode readonly} -constraints {dom_c} -setup $SETUP -body {
-	expectError {
-	    ::dom::node configure $top -parentNode XXX
-	}
-    } -cleanup $CLEANUP -result {no modification allowed error: an attempt was made to modify an object\
-	where modifications are not allowed}
-    test node-3.7 {configure -parentNode readonly} -constraints {dom_tcl||dom_libxml2} -setup $SETUP -body {
-	expectError {
-	    ::dom::node configure $top -parentNode XXX
-	}
-    } -cleanup $CLEANUP -result {attribute "-parentNode" is read-only}
-    test node-3.7.1 {configure -parentNode readonly} -constraints {dom_tcl||dom_libxml2} -setup $SETUP -body {
-	expectError {
-	    $top configure -parentNode XXX
-	}
-    } -cleanup $CLEANUP -result {attribute "-parentNode" is read-only}
-
-    test node-4.1 {cget -childNodes} -setup {
-	eval $SETUP
-    } -body {
-	upvar 0 [::dom::node cget $doc -childNodes] childlist
-	compareNodeList [set childlist] [list $top]
-    } -cleanup {
-	unset childlist
-	eval $CLEANUP
-    } -result 1
-
-    test node-4.2 {cget -childNodes top} -setup $SETUP -body {
-	upvar 0 [::dom::node cget $top -childNodes] childlist
-	compareNodeList $childlist [list $child1 $child2 $child3]
-    } -cleanup $CLEANUP -result 1
-    test node-4.2.1 {cget -childNodes top} -setup $SETUP -body {
-	upvar 0 [$top cget -childNodes] childlist
-	compareNodeList $childlist [list $child1 $child2 $child3]
-    } -cleanup $CLEANUP -result 1
-
-    test node-4.3 {cget -childNodes leaf} -setup $SETUP -body {
-	upvar 0 [::dom::node cget $child1 -childNodes] childlist
-	llength $childlist
-    } -cleanup $CLEANUP -result 0
-    test node-4.3.1 {cget -childNodes leaf} -setup $SETUP -body {
-	upvar 0 [$child1 cget -childNodes] childlist
-	llength $childlist
-    } -cleanup $CLEANUP -result 0
-
-    test node-4.4 {cget -childNodes textNode} -setup $SETUP -body {
-	upvar 0 [::dom::node cget $child2 -childNodes] childlist
-	llength $childlist
-    } -cleanup $CLEANUP -result 0
-    test node-4.4.1 {cget -childNodes textNode} -setup $SETUP -body {
-	upvar 0 [$child2 cget -childNodes] childlist
-	llength $childlist
-    } -cleanup $CLEANUP -result 0
-
-    test node-4.5 {configure -childNodes} -setup $SETUP -body {
-	upvar 0 [::dom::node configure $doc -childNodes] childlist
-	compareNodeList $childlist [list $top]
-    } -cleanup $CLEANUP -result 1
-
-    test node-4.6 {configure -childNodes top} -setup $SETUP -body {
-	upvar 0 [::dom::node cget $top -childNodes] childlist
-	compareNodeList $childlist [list $child1 $child2 $child3]
-    } -cleanup $CLEANUP -result 1
-    test node-4.6.1 {configure -childNodes top} -setup $SETUP -body {
-	upvar 0 [$top cget -childNodes] childlist
-	compareNodeList $childlist [list $child1 $child2 $child3]
-    } -cleanup $CLEANUP -result 1
-
-    test node-4.6.2 {node children} -setup $SETUP -body {
-	set children [::dom::node children $top]
-	compareNodeList $children [list $child1 $child2 $child3]
-    } -cleanup $CLEANUP -result 1
-    test node-4.6.3 {node children} -setup $SETUP -body {
-	set children [$top children]
-	compareNodeList $children [list $child1 $child2 $child3]
-    } -cleanup $CLEANUP -result 1
-
-    test node-4.7 {cget -childNodes leaf} -setup $SETUP -body {
-	set [::dom::node configure $child1 -childNodes]
-    } -cleanup $CLEANUP -result {}
-    test node-4.7.1 {cget -childNodes leaf} -setup $SETUP -body {
-	set [$child1 configure -childNodes]
-    } -cleanup $CLEANUP -result {}
-    test node-4.8 {cget -childNodes textNode} -setup $SETUP -body {
-	set [::dom::node configure $child2 -childNodes]
-    } -cleanup $CLEANUP -result {}
-    test node-4.8.1 {cget -childNodes textNode} -setup $SETUP -body {
-	set [$child2 configure -childNodes]
-    } -cleanup $CLEANUP -result {}
-
-    test node-4.9 {configure -childNodes readonly} -constraints {dom_c} -setup $SETUP -body {
-	expectError {
-	    ::dom::node configure $top -childNodes XXX
-	}
-    } -cleanup $CLEANUP -result {no modification allowed error: an attempt was made to modify an object\
-	where modifications are not allowed}
-    test node-4.9 {configure -childNodes readonly} -constraints {dom_tcl || dom_libxml2} -setup $SETUP -body {
-	expectError {
-	    ::dom::node configure $top -childNodes XXX
-	}
-    } -cleanup $CLEANUP -result {attribute "-childNodes" is read-only}
-    test node-4.9.1 {configure -childNodes readonly} -constraints {dom_tcl || dom_libxml2} -setup $SETUP -body {
-	expectError {
-	    $top configure -childNodes XXX
-	}
-    } -cleanup $CLEANUP -result {attribute "-childNodes" is read-only}
-
-    test node-4.10 {cget -childNodes textNode} -setup $SETUP -body {
-	# bug 3528
-	proc testChildNode {child} {
-		set cl [::dom::node cget $child -childNodes]
-		set $cl
-	}
-	testChildNode $child2
-    } -cleanup $CLEANUP -result {}
-    test node-4.10.1 {cget -childNodes textNode} -setup $SETUP -body {
-	proc testChildNode {child} {
-		set cl [$child cget -childNodes]
-		set $cl
-	}
-	testChildNode $child2
-    } -cleanup $CLEANUP -result {}
-
-    test node-4.11 {cget -childNodes textNode} -setup $SETUP -body {
-	# bug 3529
-	set cl [::dom::node cget $child2 -childNodes]
-	set what [namespace which -variable $cl]
-	set result [string range $what 0 6]
-    } -cleanup $CLEANUP -result {::dom::}
-
-    test node-5.1 {cget -firstChild} -setup $SETUP -body {
-	compareNodes [::dom::node cget $top -firstChild] $child1
-    } -cleanup $CLEANUP -result 1
-    test node-5.1.1 {cget -firstChild} -setup $SETUP -body {
-	compareNodes [$top cget -firstChild] $child1
-    } -cleanup $CLEANUP -result 1
-    test node-5.2 {cget -firstChild document} -setup $SETUP -body {
-	compareNodes [::dom::node cget $doc -firstChild] $top
-    } -cleanup $CLEANUP -result 1
-
-    test node-5.3 {configure -firstChild} -setup $SETUP -body {
-	compareNodes [::dom::node configure $top -firstChild] $child1
-    } -cleanup $CLEANUP -result 1
-    test node-5.3.1 {configure -firstChild} -setup $SETUP -body {
-	compareNodes [$top configure -firstChild] $child1
-    } -cleanup $CLEANUP -result 1
-
-    test node-5.4 {configure -firstChild document} -setup $SETUP -body {
-	compareNodes [::dom::node configure $doc -firstChild] $top
-    } -cleanup $CLEANUP -result 1
-
-    test node-5.5 {configure -firstChild readonly} -constraints {dom_c} -setup $SETUP -body {
-	expectError {
-	    ::dom::node configure $top -firstChild XXX
-	}
-    } -cleanup $CLEANUP -result {no modification allowed error: an attempt was made to modify an object\
-	where modifications are not allowed}
-    test node-5.5 {configure -firstChild readonly} -constraints {dom_tcl} -setup $SETUP -body {
-	expectError {
-	    ::dom::node configure $top -firstChild XXX
-	}
-    } -cleanup $CLEANUP -result {attribute "-firstChild" is read-only}
-    test node-5.5.1 {configure -firstChild readonly} -constraints {dom_tcl} -setup $SETUP -body {
-	expectError {
-	    $top configure -firstChild XXX
-	}
-    } -cleanup $CLEANUP -result {attribute "-firstChild" is read-only}
-
-    test node-6.1 {cget -lastChild} -setup $SETUP -body {
-	compareNodes [::dom::node cget $top -lastChild] $child3
-    } -cleanup $CLEANUP -result 1
-    test node-6.1 {cget -lastChild} -setup $SETUP -body {
-	compareNodes [$top cget -lastChild] $child3
-    } -cleanup $CLEANUP -result 1
-    test node-6.2 {cget -lastChild document} -setup $SETUP -body {
-	compareNodes [::dom::node cget $doc -lastChild] $top
-    } -cleanup $CLEANUP -result 1
-    test node-6.3 {configure -lastChild} -setup $SETUP -body {
-	compareNodes [::dom::node configure $top -lastChild] $child3
-    } -cleanup $CLEANUP -result 1
-    test node-6.3.1 {configure -lastChild} -setup $SETUP -body {
-	compareNodes [$top configure -lastChild] $child3
-    } -cleanup $CLEANUP -result 1
-
-    test node-6.4 {configure -lastChild document} -setup $SETUP -body {
-	compareNodes [::dom::node configure $doc -lastChild] $top
-    } -cleanup $CLEANUP -result 1
-
-    test node-6.5 {configure -lastChild readonly} -constraints {dom_c} -setup $SETUP -body {
-	expectError {
-	    ::dom::node configure $top -lastChild XXX
-	}
-    } -cleanup $CLEANUP -result {no modification allowed error: an attempt was made to modify an object\
-	where modifications are not allowed}
-    test node-6.5 {configure -lastChild readonly} -constraints {dom_tcl} -setup $SETUP -body {
-	expectError {
-	    ::dom::node configure $top -lastChild XXX
-	}
-    } -cleanup $CLEANUP -result {attribute "-lastChild" is read-only}
-
-    test node-7.1 {cget -previousSibling first} -setup $SETUP -body {
-	::dom::node cget $child1 -previousSibling
-    } -cleanup $CLEANUP -result {}
-    test node-7.1.1 {cget -previousSibling first} -setup $SETUP -body {
-	$child1 cget -previousSibling
-    } -cleanup $CLEANUP -result {}
-    test node-7.2 {cget -previousSibling last} -setup $SETUP -body {
-	compareNodes [::dom::node cget $child3 -previousSibling] $child2
-    } -cleanup $CLEANUP -result 1
-    test node-7.2 {cget -previousSibling last} -setup $SETUP -body {
-	compareNodes [$child3 cget -previousSibling] $child2
-    } -cleanup $CLEANUP -result 1
-
-    test node-7.3 {configure -previousSibling first} -setup $SETUP -body {
-	::dom::node configure $child1 -previousSibling
-    } -cleanup $CLEANUP -result {}
-    test node-7.3.1 {configure -previousSibling first} -setup $SETUP -body {
-	$child1 configure -previousSibling
-    } -cleanup $CLEANUP -result {}
-
-    test node-7.4 {configure -previousSibling last} -setup $SETUP -body {
-	compareNodes [::dom::node configure $child3 -previousSibling] $child2
-    } -cleanup $CLEANUP -result 1
-    test node-7.4.1 {configure -previousSibling last} -setup $SETUP -body {
-	compareNodes [$child3 configure -previousSibling] $child2
-    } -cleanup $CLEANUP -result 1
-
-    test node-7.5 {configure -previousSibling readonly} -constraints {dom_c} -setup $SETUP -body {
-	expectError {
-	    ::dom::node configure $top -previousSibling XXX
-	}
-    } -cleanup $CLEANUP -result {no modification allowed error: an attempt was made to modify an object\
-	where modifications are not allowed}
-    test node-7.5 {configure -previousSibling readonly} -constraints {dom_tcl || dom_libxml2} -setup $SETUP -body {
-	expectError {
-	    ::dom::node configure $top -previousSibling XXX
-	}
-    } -cleanup $CLEANUP -result {attribute "-previousSibling" is read-only}
-
-    test node-8.1 {cget -nextSibling first} -setup $SETUP -body {
-	compareNodes [::dom::node cget $child1 -nextSibling] $child2
-    } -cleanup $CLEANUP -result 1
-    test node-8.1.1 {cget -nextSibling first} -setup $SETUP -body {
-	compareNodes [$child1 cget -nextSibling] $child2
-    } -cleanup $CLEANUP -result 1
-    test node-8.2 {cget -nextSibling last} -setup $SETUP -body {
-	::dom::node cget $child3 -nextSibling
-    } -cleanup $CLEANUP -result {}
-    test node-8.2.1 {cget -nextSibling last} -setup $SETUP -body {
-	$child3 cget -nextSibling
-    } -cleanup $CLEANUP -result {}
-    test node-8.3 {configure -nextSibling first} -setup $SETUP -body {
-	compareNodes [::dom::node configure $child1 -nextSibling] $child2
-    } -cleanup $CLEANUP -result 1
-    test node-8.3.1 {configure -nextSibling first} -setup $SETUP -body {
-	compareNodes [$child1 configure -nextSibling] $child2
-    } -cleanup $CLEANUP -result 1
-
-    test node-8.4 {configure -nextSibling last} -setup $SETUP -body {
-	::dom::node configure $child3 -nextSibling
-    } -cleanup $CLEANUP -result {}
-    test node-8.4.1 {configure -nextSibling last} -setup $SETUP -body {
-	$child3 configure -nextSibling
-    } -cleanup $CLEANUP -result {}
-
-    test node-8.5 {configure -nextSibling readonly} -constraints {dom_c} -setup $SETUP -body {
-	expectError {
-	    ::dom::node configure $top -nextSibling XXX
-	}
-    } -cleanup $CLEANUP -result {no modification allowed error: an attempt was made to modify an object\
-	where modifications are not allowed}
-    test node-8.5 {configure -nextSibling readonly} -constraints {dom_tcl} -setup $SETUP -body {
-	expectError {
-	    ::dom::node configure $top -nextSibling XXX
-	}
-    } -cleanup $CLEANUP -result {attribute "-nextSibling" is read-only}
-    test node-8.5.1 {configure -nextSibling readonly} -constraints {dom_tcl} -setup $SETUP -body {
-	expectError {
-	    $top configure -nextSibling XXX
-	}
-    } -cleanup $CLEANUP -result {attribute "-nextSibling" is read-only}
-
-    test node-9.1 {cget -attributes} -setup $SETUP -body {
-	array get [::dom::node cget $top -attributes]
-    } -cleanup $CLEANUP -result {}
-    test node-9.1.1 {cget -attributes} -setup $SETUP -body {
-	array get [$top cget -attributes]
-    } -cleanup $CLEANUP -result {}
-
-    test node-9.2 {configure -attributes} -setup $SETUP -body {
-	array get [::dom::node configure $top -attributes]
-    } -cleanup $CLEANUP -result {}
-    test node-9.2.1 {configure -attributes} -setup $SETUP -body {
-	array get [$top configure -attributes]
-    } -cleanup $CLEANUP -result {}
-
-    variable SETUP9 {
-	set doc [dom::parse "<element1 a='123' b='456'>Some Text\n<element2>More Text\n</element2>Text\n</element1>"]
-	set top [::dom::document cget $doc -documentElement]
-    }
-
-    test node-9.4 {cget -attributes} -setup $SETUP9 -body {
-	set attrArray [::dom::node cget $top -attributes]
-	lsort [array names $attrArray]
-    } -cleanup $CLEANUP -result {a b}
-    test node-9.4.1 {cget -attributes} -setup $SETUP9 -body {
-	set attrArray [$top cget -attributes]
-	lsort [array names $attrArray]
-    } -cleanup $CLEANUP -result {a b}
-    test node-9.5 {configure -attributes} -setup $SETUP9 -body {
-	set attrArray [::dom::node cget $top -attributes]
-	lsort [array names $attrArray]
-    } -cleanup $CLEANUP -result {a b}
-    test node-9.5.1 {configure -attributes} -setup $SETUP9 -body {
-	set attrArray [$top cget -attributes]
-	lsort [array names $attrArray]
-    } -cleanup $CLEANUP -result {a b}
-
-    test node-9.6 {cget -attributes} -setup $SETUP9 -body {
-	set attrArray [::dom::node cget $top -attributes]
-	set result {}
-	upvar 0 $attrArray attr
-	foreach name [lsort [array names $attrArray]] {
-		lappend result $name $attr($name)
-	}
-	set result
-    } -cleanup $CLEANUP -result {a 123 b 456}
-    test node-9.6.1 {cget -attributes} -setup $SETUP9 -body {
-	set attrArray [$top cget -attributes]
-	set result {}
-	upvar 0 $attrArray attr
-	foreach name [lsort [array names $attrArray]] {
-		lappend result $name $attr($name)
-	}
-	set result
-    } -cleanup $CLEANUP -result {a 123 b 456}
-
-    test node-9.7 {configure -attributes} -setup $SETUP9 -body {
-	set attrArray [::dom::node cget $top -attributes]
-	set result {}
-	upvar 0 $attrArray attr
-	foreach name [lsort [array names $attrArray]] {
-		lappend result $name $attr($name)
-	}
-	set result
-    } -cleanup $CLEANUP -result {a 123 b 456}
-    test node-9.7.1 {configure -attributes} -setup $SETUP9 -body {
-	set attrArray [$top cget -attributes]
-	set result {}
-	upvar 0 $attrArray attr
-	foreach name [lsort [array names $attrArray]] {
-		lappend result $name $attr($name)
-	}
-	set result
-    } -cleanup $CLEANUP -result {a 123 b 456}
-
-    variable SETUP98 {
-	set doc [dom::parse {<?xml version="1.0"?><a v1="ok1" v2="ok2">foo</a>}]
-	set top [::dom::document cget $doc -documentElement]
-    }
-
-    test node-9.8 {cget -attributes} -setup $SETUP98 -body {
-	set attrArray [::dom::node cget $top -attributes]
-	set result {}
-	upvar 0 $attrArray attr
-	foreach name [lsort [array names $attrArray]] {
-		lappend result $name $attr($name)
-	}
-	set result
-    } -cleanup $CLEANUP -result {v1 ok1 v2 ok2}
-    test node-9.8.1 {cget -attributes} -setup $SETUP98 -body {
-	set attrArray [$top cget -attributes]
-	set result {}
-	upvar 0 $attrArray attr
-	foreach name [lsort [array names $attrArray]] {
-		lappend result $name $attr($name)
-	}
-	set result
-    } -cleanup $CLEANUP -result {v1 ok1 v2 ok2}
-
-    test node-9.9 {configure -attributes} -setup $SETUP98 -body {
-	set attrArray [::dom::node configure $top -attributes]
-	set result {}
-	upvar 0 $attrArray attr
-	foreach name [lsort [array names $attrArray]] {
-		lappend result $name $attr($name)
-	}
-	set result
-    } -cleanup $CLEANUP -result {v1 ok1 v2 ok2}
-    test node-9.9.1 {configure -attributes} -setup $SETUP98 -body {
-	set attrArray [$top configure -attributes]
-	set result {}
-	upvar 0 $attrArray attr
-	foreach name [lsort [array names $attrArray]] {
-		lappend result $name $attr($name)
-	}
-	set result
-    } -cleanup $CLEANUP -result {v1 ok1 v2 ok2}
-
-    # Discuss this with Joe English.
-    # Destroying the document will destroy the namespace that contains the
-    # attribute variable, so this script should result in an error.
-    # NB. If the application wants to save the attributes and their values
-    # then it should copy them to its own (array) variable. (FAQ topic)
-    test node-9.10 {cget -attributes not global} -constraints {knownBug} -setup {
-	proc xx {} {
-	    variable SETUP98
-	    eval $SETUP98
-	    set attrArray [::dom::node cget $top -attributes]
-	    dom::destroy $doc
-	    return [lsort [array get $attrArray]]
-	}
-	xx
-    } -cleanup {
-	rename xx {}
-    } -result {ok1 ok2 v1 v2}
-
-    test node-9.11 {cget -attributes not global} -setup $SETUP -body {
-	# bug 3529
-	proc xx {} {
-	    variable SETUP98
-	    variable top
-	    eval $SETUP98
-	    set attrArray [::dom::node cget $top -attributes]
-	    return [lsort [array get $attrArray]]
-	}
-	proc xx2 {v} {
-	    return [lsort [array get $v]]
-	}
-	set r1 [xx]
-	set attrArray [::dom::node cget $top -attributes]
-	set r2 [lsort [array get $attrArray]]
-	set r3 [xx2 $attrArray]
-	list $r1 $r2 $r3
-    } -cleanup {
-	dom::destroy [$top cget -ownerDocument]
-	rename xx {}
-	rename xx2 {}
-    } -result {{ok1 ok2 v1 v2} {ok1 ok2 v1 v2} {ok1 ok2 v1 v2}}
-
-    # See comments for node-9.10
-    test node-9.12 {configure -attributes not global} -constraints {knownBug} -setup $SETUP -body {
-	proc xx {} {
-	    variable SETUP98
-	    eval $SETUP98
-	    set attrArray [::dom::node configure $top -attributes]
-	    dom::destroy $doc
-	    return [lsort [array get $attrArray]]
-	}
-	xx
-    } -cleanup {
-	rename xx {}
-    } -result {ok1 ok2 v1 v2}
-
-    test node-9.13 {configure -attributes readonly} -constraints {dom_c} -setup $SETUP -body {
-	expectError {
-	    ::dom::node configure $top -attributes XXX
-	}
-    } -cleanup $CLEANUP -result {no modification allowed error: an attempt was made to modify an object\
-	where modifications are not allowed}
-    test node-9.13 {configure -attributes readonly} -constraints {dom_tcl} -setup $SETUP -body {
-	expectError {
-	    ::dom::node configure $top -attributes XXX
-	}
-    } -cleanup $CLEANUP -result {attribute "-attributes" is read-only}
-    test node-9.13.1 {configure -attributes readonly} -constraints {dom_tcl} -setup $SETUP -body {
-	expectError {
-	    $top configure -attributes XXX
-	}
-    } -cleanup $CLEANUP -result {attribute "-attributes" is read-only}
-
-    test node-10.1 {cget -nodeValue} -setup $SETUP -body {
-	::dom::node cget $top -nodeValue
-    } -cleanup $CLEANUP -result {}
-    test node-10.1.1 {cget -nodeValue} -setup $SETUP -body {
-	$top cget -nodeValue
-    } -cleanup $CLEANUP -result {}
-    test node-10.2 {cget -nodeValue text} -setup $SETUP -body {
-	::dom::node cget $child2 -nodeValue
-    } -cleanup $CLEANUP -result Child2
-    test node-10.2.1 {cget -nodeValue text} -setup $SETUP -body {
-	$child2 cget -nodeValue
-    } -cleanup $CLEANUP -result Child2
-
-    test node-10.3 {configure -nodeValue} -setup $SETUP -body {
-	::dom::node configure $top -nodeValue
-    } -cleanup $CLEANUP -result {}
-    test node-10.3.1 {configure -nodeValue} -setup $SETUP -body {
-	$top configure -nodeValue
-    } -cleanup $CLEANUP -result {}
-
-    test node-10.4 {configure -nodeValue text} -setup $SETUP -body {
-	::dom::node configure $child2 -nodeValue
-    } -cleanup $CLEANUP -result Child2
-    test node-10.4.1 {configure -nodeValue text} -setup $SETUP -body {
-	$child2 configure -nodeValue
-    } -cleanup $CLEANUP -result Child2
-
-    # According to the DOM spec attributes which have obvious mapping to the node type,
-    # ie nodeValue for Element nodes, return NULL for the value rather than an error.
-    test node-10.5 {configure -nodeValue readonly for elements} -constraints {dom_c && knownBug} -setup $SETUP -body {
-	expectError {
-	    ::dom::node configure $top -nodeValue XXX
-	}
-    } -cleanup $CLEANUP -result {no modification allowed error: an attempt was made to modify an object\
-	where modifications are not allowed}
-    test node-10.5 {configure -nodeValue readonly for elements} -constraints {dom_tcl||dom_libxml2} -setup $SETUP -body {
-	::dom::node configure $top -nodeValue XXX
-    } -cleanup $CLEANUP -result {}
-    test node-10.5.1 {configure -nodeValue readonly for elements} -constraints {dom_tcl||dom_libxml2} -setup $SETUP -body {
-	$top configure -nodeValue XXX
-    } -cleanup $CLEANUP -result {}
-
-    test node-10.6 {configure -nodeValue writable for text nodes} -setup $SETUP -body {
-	set result1 [catch {::dom::node configure $child2 -nodeValue XXX} msg1]
-	set result2 [catch {::dom::node configure $child2 -nodeValue} msg2]
-	list $result1 $msg1 $result2 $msg2
-    } -cleanup $CLEANUP -result {0 {} 0 XXX}
-
-    variable SETUP11 {
-	eval $SETUP
-	set branchA [$top appendChild [dom::document createElement $top BranchA]]
-	set branchB [$top appendChild [dom::document createElement $top BranchB]]
-	set new [$branchA appendChild [dom::document createElement $branchA MoveMe]]
-	set ref [$branchB appendChild [dom::document createElement $branchB Reference]]
-    }
-
-    test node-11.1 {insertBefore, different parent} -setup $SETUP11 -body {
-	::dom::node insertBefore $branchB $new $ref
-	# new should now have branchB as parent
-	# branchA should have no children
-	# branchB should have children {$new $ref}
-	list [compareNodes [dom::node cget $new -parentNode] $branchB] \
-	[dom::node children $branchA] \
-	[compareNodeList [dom::node children $branchB] [list $new $ref]]
-    } -cleanup $CLEANUP -result [list 1 {} 1]
-
-    test node-11.2 {insertBefore, same parent} -setup $SETUP11 -body {
-	::dom::node insertBefore $branchB $new $ref
-	::dom::node insertBefore $branchB $ref $new
-	# ref should still have branchB as its parent
-	# branchB should have children {$ref $new}
-	list [compareNodes [dom::node cget $ref -parentNode] $branchB] \
-	[compareNodeList [dom::node children $branchB] [list $ref $new]]
-    } -cleanup $CLEANUP -result [list 1 1]
-    test node-11.3 {insertBefore, no ref child given, node with no children} -setup $SETUP11 -body {
-	::dom::node insertBefore $branchB $new $ref
-	::dom::node insertBefore $branchB $ref $new
-	::dom::node insertBefore $branchA $new
-	# new should have parent branchA
-	# branchA should have child new
-	# branchB should have only child ref
-	list [compareNodes [dom::node cget $new -parentNode] $branchA] \
-	[compareNodeList [dom::node children $branchA] [list $new]] \
-	[compareNodeList [dom::node children $branchB] [list $ref]]
-    } -cleanup $CLEANUP -result [list 1 1 1]
-
-    test node-11.4 {insertBefore, no ref child given, node with children} -setup $SETUP11 -body {
-	::dom::node insertBefore $branchB $new $ref
-	::dom::node insertBefore $branchB $ref $new
-	::dom::node insertBefore $branchA $new
-	::dom::node insertBefore $branchA $ref
-	# ref should have parent branchA
-	# branchA should have children {$new $ref}
-	# branchB should have no children
-	list [compareNodes [dom::node cget $ref -parentNode] $branchA] \
-	[compareNodeList [dom::node children $branchA] [list $new $ref]] \
-	[dom::node children $branchB]
-    } -cleanup $CLEANUP -result [list 1 1 {}]
-
-    # TODO: test using node command, ie. $branchB insertBefore ...
-
-    variable SETUP12 {
-	eval $SETUP
-	set parent [$top appendChild [dom::document createElement  $top    Remove]]
-	set n1  [$parent appendChild [dom::document createTextNode $parent {Leave me alone}]]
-	set rem [$parent appendChild [dom::document createElement  $parent RemoveMe]]
-	set n2  [$parent appendChild [dom::document createTextNode $parent {Leave me alone}]]
-    }
-
-    # test node-12.0 obsolete
-    test node-12.1 {removeChild} -setup $SETUP12 -body {
-	set oldchild [::dom::node removeChild $parent $rem]
-	list [compareNodes $oldchild $rem] \
-	[compareNodeList [::dom::node children $parent] [list $n1 $n2]] \
-	[::dom::node children $oldchild]
-    } -cleanup $CLEANUP -result [list 1 1 {}]
-    test node-12.1.1 {removeChild} -setup $SETUP12 -body {
-	set oldchild [$parent removeChild $rem]
-	list [compareNodes $oldchild $rem] \
-	[compareNodeList [::dom::node children $parent] [list $n1 $n2]] \
-	[::dom::node children $oldchild]
-    } -cleanup $CLEANUP -result [list 1 1 {}]
-    test node-12.2 {removeChild: error, wrong num args} -setup $SETUP -match glob -body {
-	expectError {
-	    ::dom::node removeChild $top
-	}
-    } -cleanup $CLEANUP -result {wrong # args: *}
-    test node-12.2.1 {removeChild: error, wrong num args} -setup $SETUP -match glob -body {
-	expectError {
-	    $top removeChild
-	}
-    } -cleanup $CLEANUP -result {wrong # args: *}
-    test node-12.3 {removeChild: error, wrong num args} -setup $SETUP -match glob -body {
-	expectError {
-	    ::dom::node removeChild $top $child1 $child3
-	}
-    } -cleanup $CLEANUP -result {wrong # args: *}
-    test node-12.3.1 {removeChild: error, wrong num args} -setup $SETUP -match glob -body {
-	expectError {
-	    $top removeChild $child1 $child3
-	}
-    } -cleanup $CLEANUP -result {wrong # args: *}
-    test node-12.4 {removeChild: error, not a child} -setup $SETUP12 -match regexp -body {
-	expectError {
-    	    ::dom::node removeChild $doc $rem
-	}
-    } -cleanup $CLEANUP -result {^(document must have document element.*)|(not found.*)|(node "[^"]*" is not a child)}
-    test node-12.5 {removeChild: error, not a child} -setup $SETUP12 -match regexp -body {
-	expectError {
-    	    ::dom::node removeChild $top $rem
-	}
-    } -cleanup $CLEANUP -result {(not found.*)|(node "[^"]*" is not a child)}
-    test node-12.5.1 {removeChild: error, not a child} -setup $SETUP12 -match regexp -body {
-	expectError {
-    	    $top removeChild $rem
-	}
-    } -cleanup $CLEANUP -result {(not found.*)|(node "[^"]*" is not a child)}
-
-    variable SETUP13 {
-	eval $SETUP
-	set branchA [$top appendChild [dom::document createElement $top ReplaceA]]
-	set branchB [$top appendChild [dom::document createElement $top ReplaceB]]
-	set new [$branchA appendChild [dom::document createElement $branchA MoveMe]]
-	set replace [$branchB appendChild [dom::document createElement $branchB ReplaceMe]]
-    }
-
-    test node-13.1 {replaceChild} -setup $SETUP13 -body {
-	set replaced [::dom::node replaceChild $branchB $new $replace]
-	# replace becomes orphaned (no parent)
-	# new has parent branchB
-	# branchB has children {$new}
-	# branchA has no children
-	# returns $replace
-	list [expr {[::dom::node cget $replace -parentNode] == {} ? 1 : [::dom::node isSameNode $doc [::dom::node cget $replace -parentNode]]}] \
-    	[compareNodes [::dom::node cget $new -parentNode] $branchB ] \
-	[compareNodeList [::dom::node children $branchB] [list $new]] \
-	[::dom::node children $branchA] \
-	[$replace isSameNode $replaced] \
-	;
-    } -cleanup $CLEANUP -result [list 1 1 1 {} 1]
-
-    variable SETUP14 {
-	eval $SETUP
-	set branchA [$top appendChild     [dom::document createElement $top AppendA]]
-	set branchB [$top appendChild     [dom::document createElement $top AppendB]]
-	set node    [$branchA appendChild [dom::document createElement $branchA MoveMe]]
-	set after   [$branchB appendChild [dom::document createElement $branchB AfterMe]]
-    }
-
-    test node-14.1 {appendChild} -setup $SETUP14 -body {
-	::dom::node appendChild $branchB $node
-	# node should have parent branchB
-	# Branch A should have no children
-	# Branch B should have children: {$after $node}
-	list [compareNodes [::dom::node cget $node -parentNode] $branchB] \
-	[::dom::node children $branchA] \
-	[compareNodeList [::dom::node children $branchB] [list $after $node]] \
-	;
-    } -cleanup $CLEANUP -result [list 1 {} 1]
-
-    test node-14.2 {appendChild return value} -setup {
-	set doc [dom::create]
-	set top [dom::document createElement $doc Top]
-	set node [dom::document createElement $top Child]
-    } -body {
-	$node isSameNode [dom::node appendChild $top $node]
-    } -cleanup $CLEANUP -result 1
-    test node-14.2.1 {appendChild return value} -setup {
-	set doc [dom::create]
-	set top [dom::document createElement $doc Top]
-	set node [dom::document createElement $top Child]
-    } -body {
-	$node isSameNode [$top appendChild $node]
-    } -cleanup $CLEANUP -result 1
-    test node-14.3 {appendChild - document element} -setup {
-	set doc [dom::create]
-	set top [$doc createElement Top]
-    } -body {
-	$top isSameNode [dom::node appendChild $doc $top]
-    } -cleanup $CLEANUP -result 1
-
-    # cloneNode tests are disabled for libxml2 as it cannot serialize
-    # a node (only an entire document).
-
-    variable SETUP15 {
-	eval $SETUP
-	set cloneNode [$top appendChild       [dom::document createElement $top Clone]]
-	set clone1    [$cloneNode appendChild [dom::document createElement $cloneNode Nested]] ;#{id one}
-	set clone2    [$cloneNode appendChild [dom::document createElement $cloneNode Nested]] ;#{id two}
-	$cloneNode appendChild [dom::document createElement $cloneNode Nested] ;#{id three}
-	$clone1 appendChild    [dom::document createTextNode $clone1 {text for node 1}]
-	$clone2 appendChild    [dom::document createTextNode $clone2 {text for node 2}]
-    }
-
-    # test node-15.1 obsolete
-
-    test node-15.2 {cloneNode part 2} -constraints {!dom_libxml2} -setup $SETUP15 -body {
-	set cloned [dom::node cloneNode $cloneNode -deep yes]
-	set orig [dom::DOMImplementation serialize $cloneNode]
-	set new [dom::DOMImplementation serialize $cloned]
-	list [string compare $orig $new] [dom::node parent $cloned]
-    } -cleanup $CLEANUP -result {0 {}}
-
-    test node-15.3 {cloneNode of document} -constraints {!dom_libxml2} -setup {
-	set doc1 [dom::parse {<?xml version="1.0" standalone="yes"?><a v1="ok1" v2="ok2">foo</a>}]
-    } -body {
-	set doc2 [dom::node cloneNode $doc1 -deep 1]
-	set sdoc1 [dom::DOMImplementation serialize $doc1]
-	set sdoc2 [dom::DOMImplementation serialize $doc2]
-	string compare $sdoc1 $sdoc2
-    } -cleanup {
-	dom::destroy $doc1
-    } -result {0}
-
-    variable SETUP16 {
-	set doc [dom::parse "<element1>Some Text\n<element2>More Text\n</element2>Text\n</element1>"]
-	set top [::dom::document cget $doc -documentElement]
-    }
-
-    test node-16.1 {cget -startLine} -constraints {dom_c} -setup $SETUP16 -body {
-	::dom::node cget $top -startLine
-    } -cleanup $CLEANUP -result 1
-
-    test node-16.2 {cget -endLine} -constraints {dom_c} -setup $SETUP16 -body {
-	::dom::node cget $top -endLine
-    } -cleanup $CLEANUP -result 4
-
-    test node-16.3 {cget -startColumn} -constraints {dom_c} -setup {
-	set doc [dom::parse "<!-- --><element1>Some Text\n<element2>More Text\n</element2>Text\n</element1>"]
-	set top [::dom::document cget $doc -documentElement]
-    } -body {
-	::dom::node cget $top -startColumn
-    } -cleanup $CLEANUP -result 8
-
-    test node-16.4 {cget -endColumn} -constraints {dom_c} -setup {
-	set doc [dom::parse "<element1>Some Text\n<element2>More Text\n</element2>Text\nXXX</element1>"]
-	set top [::dom::document cget $doc -documentElement]
-    } -body {
-	::dom::node cget $top -endColumn
-    } -cleanup $CLEANUP -result 3
-
-    test node-16.5 {cget -startWidth} -constraints {dom_c} -setup {
-	set doc [dom::parse "<element1>Some Text\n<element2>More Text\n</element2>Text\nXXX</element1>"]
-	set top [::dom::document cget $doc -documentElement]
-    } -body {
-	::dom::node cget $top -startWidth
-    } -cleanup $CLEANUP -result 10
-
-    test node-16.6 {cget -endWidth} -constraints {dom_c} -setup {
-	set doc [dom::parse "<element1>Some Text\n<element2>More Text\n</element2>Text\nXXX</element1>"]
-	set top [::dom::document cget $doc -documentElement]
-    } -body {
-	::dom::node cget $top -endWidth
-    } -cleanup $CLEANUP -result 11
-
-    # documentFragment tests have been disabled for libxml2 because
-    # libxml2-2.5.1 (and earlier) appears to have a bug in serialising
-    # a document containing a document fragment.
-
-    variable SETUP17 {
-	set doc [::dom::DOMImplementation create]
-	set top [::dom::document createElement $doc top]
-	::dom::node appendChild $doc $top
-	set fragment [::dom::document createDocumentFragment $doc]
-    }
-
-    test node-17.1 {document fragments} -constraints {!dom_libxml2} -setup $SETUP17 -body {
-	set text [::dom::document createTextNode $doc \
-		"Now is the time for all good men to come to the aid of their party"]
-	::dom::node appendChild $fragment $text
-	::dom::node appendChild $top $fragment
-	::dom::DOMImplementation serialize $doc
-    } -cleanup $CLEANUP -result {<?xml version='1.0'?>
-<!DOCTYPE top>
-<top>Now is the time for all good men to come to the aid of their party</top>}
-
-    test node-17.2 {document fragment append with multiple text children} -constraints {!dom_libxml2} -setup $SETUP17 -body {
-	foreach xx {abc def ghi jkl mno} {
-		set text [::dom::document createTextNode $doc $xx]
-		::dom::node appendChild $fragment $text
-	}
-	::dom::node appendChild $top $fragment
-	::dom::DOMImplementation serialize $doc
-    } -cleanup $CLEANUP -result {<?xml version='1.0'?>
-<!DOCTYPE top>
-<top>abcdefghijklmno</top>}
-
-    test node-17.3 {document fragment append with multiple children} -constraints {!dom_libxml2} -setup $SETUP17 -body {
-	foreach xx {abc def ghi jkl} {
-	    set child [::dom::document createElement $doc [string toupper $xx]]
-	    set text [::dom::document createTextNode $doc $xx]
-	    ::dom::node appendChild $fragment $child
-	    ::dom::node appendChild $child $text
-	}
-	::dom::node appendChild $top $fragment
-	::dom::DOMImplementation serialize $doc
-    } -cleanup $CLEANUP -result {<?xml version='1.0'?>
-<!DOCTYPE top>
-<top><ABC>abc</ABC><DEF>def</DEF><GHI>ghi</GHI><JKL>jkl</JKL></top>}
-
-    test node-17.4 {document fragment insert} -constraints {!dom_libxml2} -setup $SETUP17 -body {
-	foreach xx {abc jkl} {
-	    set child [::dom::document createElement $doc [string toupper $xx]]
-	    set text [::dom::document createTextNode $doc $xx]
-	    ::dom::node appendChild $fragment $child
-	    ::dom::node appendChild $child $text
-	}
-	::dom::node appendChild $top $fragment
-	set fragment [::dom::document createDocumentFragment $doc]
-	foreach xx {def ghi} {
-	    set child2 [::dom::document createElement $doc [string toupper $xx]]
-	    set text [::dom::document createTextNode $doc $xx]
-	    ::dom::node appendChild $fragment $child2
-	    ::dom::node appendChild $child2 $text
-	}
-	::dom::node insertBefore $top $fragment $child
-	::dom::DOMImplementation serialize $doc
-    } -cleanup $CLEANUP -result {<?xml version='1.0'?>
-<!DOCTYPE top>
-<top><ABC>abc</ABC><DEF>def</DEF><GHI>ghi</GHI><JKL>jkl</JKL></top>}
-
-    test node-17.5 {document fragment replace} -constraints {!dom_libxml2} -setup $SETUP17 -body {
-	foreach xx {abc def xxx} {
-	    set child [::dom::document createElement $doc [string toupper $xx]]
-	    set text [::dom::document createTextNode $doc $xx]
-	    ::dom::node appendChild $fragment $child
-	    ::dom::node appendChild $child $text
-	}
-	::dom::node appendChild $top $fragment
-	set fragment [::dom::document createDocumentFragment $doc]
-	foreach xx {ghi jkl} {
-	    set child2 [::dom::document createElement $doc [string toupper $xx]]
-	    set text [::dom::document createTextNode $doc $xx]
-	    ::dom::node appendChild $fragment $child2
-	    ::dom::node appendChild $child2 $text
-	}
-	::dom::node replaceChild $top $fragment $child
-	::dom::DOMImplementation serialize $doc
-    } -cleanup $CLEANUP -result {<?xml version='1.0'?>
-<!DOCTYPE top>
-<top><ABC>abc</ABC><DEF>def</DEF><GHI>ghi</GHI><JKL>jkl</JKL></top>}
-
-    test node-18.1 {cget -parsingComplete} -constraints {dom_c} -setup $SETUP -body {
-	::dom::node cget $top -parsingComplete
-    } -cleanup $CLEANUP -result 1
-
-    test node-18.2 {cget -parsingComplete document} -constraints {dom_c} -setup $SETUP -body {
-	::dom::node cget $doc -parsingComplete
-    } -cleanup $CLEANUP -result 1
-
-    test node-18.3 {configure -parsingComplete} -constraints {dom_c} -setup $SETUP -body {
-	::dom::node configure $top -parsingComplete
-    } -cleanup $CLEANUP -result 1
-
-    test node-18.4 {configure -parsingComplete document} -constraints {dom_c} -setup $SETUP -body {
-	::dom::node configure $doc -parsingComplete
-    } -cleanup $CLEANUP -result 1
-
-    test node-18.5 {configure -parsingComplete readonly} -constraints {dom_c} -setup $SETUP -body {
-	expectError {
-	    ::dom::node configure $top -parsingComplete 1
-	}
-    } -cleanup $CLEANUP -result {no modification allowed error: an attempt was made to modify an object\
-	where modifications are not allowed}
-
-    test node-19.1 {isSameNode - too few arguments} -constraints {dom_tcl || dom_libxml2} -setup $SETUP -match glob -body {
-	expectError {
-	    ::dom::node isSameNode
-	}
-    } -cleanup $CLEANUP -result {wrong # args*}
-    test node-19.2 {isSameNode - too few arguments} -constraints {dom_tcl || dom_libxml2} -setup $SETUP -match glob -body {
-	expectError {
-	    ::dom::node isSameNode $top
-	}
-    } -cleanup $CLEANUP -result {wrong # args*}
-    test node-19.2.1 {isSameNode - too few arguments} -constraints {dom_tcl || dom_libxml2} -setup $SETUP -match glob -body {
-	expectError {
-	    $top isSameNode
-	}
-    } -cleanup $CLEANUP -result {wrong # args*}
-    test node-19.3 {isSameNode - too many arguments} -constraints {dom_tcl || dom_libxml2} -setup $SETUP -match glob -body {
-	expectError {
-	    ::dom::node isSameNode $top $child1 $child2
-	}
-    } -cleanup $CLEANUP -result {wrong # args*}
-    test node-19.4 {isSameNode - same node} -constraints {dom_tcl || dom_libxml2} -setup $SETUP -body {
-	::dom::node isSameNode $top $top
-    } -cleanup $CLEANUP -result 1
-    test node-19.4.1 {isSameNode - same node} -constraints {dom_tcl || dom_libxml2} -setup $SETUP -body {
-	$top isSameNode $top
-    } -cleanup $CLEANUP -result 1
-    test node-19.5 {isSameNode - different node} -constraints {dom_tcl || dom_libxml2} -setup $SETUP -body {
-	::dom::node isSameNode $top $child1
-    } -cleanup $CLEANUP -result 0
-    test node-19.5.1 {isSameNode - different node} -constraints {dom_tcl || dom_libxml2} -setup $SETUP -body {
-	$top isSameNode $child1
-    } -cleanup $CLEANUP -result 0
-    test node-19.4 {isSameNode - same doc} -constraints {dom_tcl || dom_libxml2} -setup $SETUP -body {
-	::dom::node isSameNode $doc $doc
-    } -cleanup $CLEANUP -result 1
-    test node-19.5 {isSameNode - different doc} -constraints {dom_tcl || dom_libxml2} -setup $SETUP -body {
-	::dom::node isSameNode $doc $top
-    } -cleanup $CLEANUP -result 0
-
-    test node-20.1 {stringValue - argument parsing} -setup $SETUP -match glob -body {
-	expectError {
-	    dom::node stringValue
-	}
-    } -cleanup $CLEANUP -result {wrong # args*}
-    test node-20.2 {stringValue - argument parsing} -setup $SETUP -match glob -body {
-	expectError {
-	    dom::node stringValue $top FooBar
-	}
-    } -cleanup $CLEANUP -result {wrong # args*}
-    test node-20.3 {stringValue - element} -setup $SETUP -body {
-	dom::node stringValue $top
-    } -cleanup $CLEANUP -result Child2
-    test node-20.3.1 {stringValue - element} -setup $SETUP -body {
-	$top stringValue
-    } -cleanup $CLEANUP -result Child2
-    test node-20.4 {stringValue - textNode} -setup $SETUP -body {
-	dom::node stringValue $child2
-    } -cleanup $CLEANUP -result Child2
-    test node-20.4.1 {stringValue - textNode} -setup $SETUP -body {
-	$child2 stringValue
-    } -cleanup $CLEANUP -result Child2
-    test node-20.5 {stringValue - document only containing text node} -setup {
-	set doc [dom::create]
-	set txt [dom::document createTextNode $doc {filename.xml}]
-	dom::node appendChild $doc $txt
-    } -body {
-	dom::node stringValue $doc
-    } -cleanup {
-	dom::destroy $doc
-    } -result {filename.xml}
-    # TODO: test multiple text nodes, attribute nodes, comments, PIs
-
-    cleanupTests
-}
-
-namespace delete ::dom::nodeTest
-
-return
diff --git a/tclxml-3.2/tests/tcldom/parse.test b/tclxml-3.2/tests/tcldom/parse.test
deleted file mode 100644
index ac0dcf1..0000000
--- a/tclxml-3.2/tests/tcldom/parse.test
+++ /dev/null
@@ -1,586 +0,0 @@
-# Commands covered:  ::dom::DOMimplementation parse
-#
-# This file contains a collection of tests for one or more of the 
-# TclDOM commands.  Sourcing this file into Tcl runs the tests and
-# generates output for errors.  No output means no errors were found.
-#
-# Copyright (c) 2008 Explain
-# Copyright (c) 1998-2004 Zveno Pty Ltd.
-#
-# $Id: parse.test,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require tcltest
-source [file join [tcltest::workingDirectory] tcldomutils.tcl]
-
-testPackage dom
-
-namespace eval ::dom::parseTest {
-    namespace import -force ::tcltest::*
-
-    testConstraint sa [file exists $::tcltest::testsDirectory/sa]
-
-    proc readUtfOrUnicode {name} {
-	set f [open $name r]
-	fconfigure $f -encoding binary
-	set prefix [read $f 2]
-	seek $f 0 start
-	if {[string equal $prefix \u00ff\u00fe]} {
-	    fconfigure $f -encoding identity
-	} else {
-	    fconfigure $f -encoding utf-8
-	}
-	set xml [read $f]
-	close $f
-	return $xml
-    }
-
-    proc readBinary {name} {
-	set f [open $name r]
-	fconfigure $f -encoding binary
-	set data [read $f]
-	close $f
-	return $data
-    }
-
-    proc makeUnicode {data} {
-	return [encoding convertfrom identity [encoding convertto unicode $data]]
-    }
-
-    test parse-1.1 {single element document} -constraints {dom_c} -body {
-	set result [::dom::DOMImplementation parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test></Test>}]
-	checkTree $result {
-	    {pi xml}
-	    {pi DOCTYPE}
-	    {element Test {} {}}
-	}
-    } -cleanup {
-	dom::destroy $result
-    } -result 1
-    test parse-1.1 {single element document} -constraints {dom_tcl} -body {
-	set result [::dom::DOMImplementation parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test></Test>}]
-	dom::trim $result
-	checkTree $result {
-	    {doctype Test {} {}}
-	    {element Test {} {}}
-	}
-    } -cleanup {
-	dom::destroy $result
-    } -result 1
-    test parse-1.1 {single element document} -constraints {dom_libxml2} -body {
-	set result [::dom::DOMImplementation parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test></Test>}]
-	dom::trim $result
-	checkTree $result {
-	    {doctype Test {} {}}
-	    {element Test {} {}}
-	} 0
-    } -cleanup {
-	dom::destroy $result
-    } -result 1
-    test parse-1.2 {nested element document} -constraints {dom_c} -body {
-	set result [::dom::DOMImplementation parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test><Nested><Deeper></Deeper></Nested><Nested></Nested></Test>}]
-	checkTree $result {
-	    {pi xml}
-	    {pi DOCTYPE}
-	    {element Test {} {
-		{element Nested {} {
-		    {element Deeper {} {}}
-		}}
-		{element Nested {} {}}
-	    }}
-	}
-    } -cleanup {
-	dom::destroy $result
-    } -result 1
-    test parse-1.2 {nested element document} -constraints {dom_tcl} -body {
-	set result [::dom::DOMImplementation parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test><Nested><Deeper></Deeper></Nested><Nested></Nested></Test>}]
-	dom::trim $result
-	checkTree $result {
-	    {doctype Test {} {}}
-	    {element Test {} {
-		{element Nested {} {
-		    {element Deeper {} {}}
-		}}
-		{element Nested {} {}}
-	    }}
-	}
-    } -cleanup {
-	dom::destroy $result
-    } -result 1
-    test parse-1.2 {nested element document} -constraints {dom_libxml2} -body {
-	set result [::dom::DOMImplementation parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test><Nested><Deeper></Deeper></Nested><Nested></Nested></Test>}]
-	dom::trim $result
-	checkTree $result {
-	    {doctype Test {} {}}
-	    {element Test {} {
-		{element Nested {} {
-		    {element Deeper {} {}}
-		}}
-		{element Nested {} {}}
-	    }}
-	} 0
-    } -cleanup {
-	dom::destroy $result
-    } -result 1
-    test parse-1.3 {elements with attributes} -constraints {dom_c} -body {
-	set result [::dom::DOMImplementation parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test><Nested depth="1"><Nested depth="2"></Nested></Nested></Test>}]
-	checkTree $result {
-	    {pi xml}
-	    {pi DOCTYPE}
-	    {element Test {} {
-		{element Nested {depth 1} {
-		    {element Nested {depth 2} {}}
-		}}
-	    }}
-	}
-    } -cleanup {
-	dom::destroy $result
-    } -result 1
-    test parse-1.3 {elements with attributes} -constraints {dom_tcl} -body {
-	set result [::dom::DOMImplementation parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test><Nested depth="1"><Nested depth="2"></Nested></Nested></Test>}]
-	dom::trim $result
-	checkTree $result {
-	    {doctype Test {} {}}
-	    {element Test {} {
-		{element Nested {depth 1} {
-		    {element Nested {depth 2} {}}
-		}}
-	    }}
-	}
-    } -cleanup {
-	dom::destroy $result
-    } -result 1
-    test parse-1.3 {elements with attributes} -constraints {dom_libxml2} -body {
-	set result [::dom::DOMImplementation parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test><Nested depth="1"><Nested depth="2"></Nested></Nested></Test>}]
-	dom::trim $result
-	checkTree $result {
-	    {doctype Test {} {}}
-	    {element Test {} {
-		{element Nested {depth 1} {
-		    {element Nested {depth 2} {}}
-		}}
-	    }}
-	} 0
-    } -cleanup {
-	dom::destroy $result
-    } -result 1
-    test parse-1.4 {elements with text content} -constraints {dom_c} -body {
-	set result [::dom::DOMImplementation parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test><Nested><Deeper>Inside Deeper</Deeper></Nested><Nested>Second Nested</Nested></Test>}]
-	checkTree $result {
-	    {pi xml}
-	    {pi DOCTYPE}
-	    {element Test {} {
-		{element Nested {} {
-		    {element Deeper {} {
-			{text {Inside Deeper}}
-		    }}
-		}}
-		{element Nested {} {
-		    {text {Second Nested}}
-		}}
-	    }}
-	}
-    } -cleanup {
-	dom::destroy $result
-    } -result 1
-    test parse-1.4 {elements with text content} -constraints {dom_tcl} -body {
-	set result [::dom::DOMImplementation parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test><Nested><Deeper>Inside Deeper</Deeper></Nested><Nested>Second Nested</Nested></Test>}]
-	dom::trim $result
-	checkTree $result {
-	    {doctype Test {} {}}
-	    {element Test {} {
-		{element Nested {} {
-		    {element Deeper {} {
-			{text {Inside Deeper}}
-		    }}
-		}}
-		{element Nested {} {
-		    {text {Second Nested}}
-		}}
-	    }}
-	}
-    } -cleanup {
-	dom::destroy $result
-    } -result 1
-    test parse-1.4 {elements with text content} -constraints {dom_libxml2} -body {
-	set result [::dom::DOMImplementation parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test><Nested><Deeper>Inside Deeper</Deeper></Nested><Nested>Second Nested</Nested></Test>}]
-	dom::trim $result
-	checkTree $result {
-	    {doctype Test {} {}}
-	    {element Test {} {
-		{element Nested {} {
-		    {element Deeper {} {
-			{text {Inside Deeper}}
-		    }}
-		}}
-		{element Nested {} {
-		    {text {Second Nested}}
-		}}
-	    }}
-	} 0
-    } -cleanup {
-	dom::destroy $result
-    } -result 1
-
-    test parse-1.5 {incremental parse} -constraints {!dom_libxml2} -setup {
-	set part1 {<?xml version="1.0"?>}
-	set part2 {<!DOCTYPE Test><Test></Test>}
-    } -body {
-	set result1 [catch {::dom::DOMImplementation parse $part1 -final 0} m1]
-	set result2 [catch {::dom::DOMImplementation parse $part2 -final 1} m2]
-	list $result1 $result2
-    } -cleanup {
-	::dom::DOMImplementation destroy $m2
-    } -result {0 0}
-
-    test parse-1.6 {incremental parse -- parsingComplete flag} -constraints {dom_c} -setup {
-	set part1 {<?xml version="1.0"?><Test><A>abc</A><B>def</B>xyz}
-	set part2 {</Test>}
-    } -body {
-
-	# parse xml that contains <A>...</A>
-	set doc [::dom::DOMImplementation parse $part1 -final 0]
-	set top [::dom::node cget $doc -firstChild]
-	set child [::dom::node cget $top -firstChild]
-	set textNode [::dom::node cget $child -lastChild]
-	set value [::dom::node cget $child -nodeName]
-
-	# get completion flags for first chunk of xml
-	set flag1 [::dom::node cget $top -parsingComplete]
-	set flag2 [::dom::node cget $child -parsingComplete]
-	set flag3 [::dom::node cget $textNode -parsingComplete]
-
-	# parse rest of xml -- close tag for top node
-	::dom::DOMImplementation parse $part2 -final 1
-
-	# get completion flags for completely parsed xml
-	set flag4 [::dom::node cget $top -parsingComplete]
-	set flag5 [::dom::node cget $child -parsingComplete]
-	set flag6 [::dom::node cget $textNode -parsingComplete]
-
-	list $flag1 $flag2 $flag3 $flag4 $flag5 $flag6
-    } -cleanup {
-	::dom::DOMImplementation destroy $doc
-    } -result {0 1 1 1 1 1}
-
-    test parse-2.1 {expat test suite; tests UTF-16 compliance} -constraints {sa} -body {
-	set compositeResult 0
-	foreach fname [glob $::tcltest::testsDirectory/sa/*.xml] {
-	    set xml [readUtfOrUnicode $fname]
-	    set result [catch {::dom::DOMImplementation parse $xml} doc]
-	    if {$result == 0} {
-		::dom::DOMImplementation destroy $doc
-	    } else {
-		if {$compositeResult == 0} {
-		    set compositeResult ""
-		}
-		lappend compositeResult [file tail $fname]
-	    }
-	}
-	set compositeResult 
-    } -result 0
-
-    test parse-2.2 {expat test suite with incrmental parsing} -constraints {sa} -body {
-	set compositeResult 0
-	foreach fname [glob $::tcltest::testsDirectory/sa/*.xml] {
-	    set xml [readUtfOrUnicode $fname]
-	    set xml1 [string range $xml 0 10]
-	    set xml2 [string range $xml 11 end]
-	    catch {::dom::DOMImplementation parse $xml1 -final 0}
-	    set result [catch {::dom::DOMImplementation parse $xml2 -final 1} doc]
-	    if {$result == 0} {
-		::dom::DOMImplementation destroy $doc
-	    } else {
-		if {$compositeResult == 0} {
-		    set compositeResult ""
-		}
-		lappend compositeResult [file tail $fname]
-	    }
-	}
-	set compositeResult 
-    } -result 0
-
-    test parse-2.3 {expat test suite with incremental parsing errors} -constraints {sa} -body {
-	set count 0
-	set passCount 0
-	foreach fname [glob $::tcltest::testsDirectory/sa/*.xml] {
-	    set xml [readUtfOrUnicode $fname]
-	    set xml1 [string range $xml 0 10]
-	    set xml2 [string range $xml 11 end]
-	    catch {::dom::DOMImplementation parse $xml1 -final 0}
-	    # intentionally bad xml -- all parsing should fail
-	    set result [catch {::dom::DOMImplementation parse $xml1 -final 1} doc]
-	    if {$result == 0} {
-		::dom::DOMImplementation destroy $doc
-		incr passCount
-	    } else {
-		incr count
-	    }
-	}
-	list $count $passCount	
-    } -result {119 0}
-
-    test parse-2.4 {incremental parsing errors -- error on first parse} -constraints {sa} -body {
-	set count 0
-	set passCount 0
-	foreach fname [glob $::tcltest::testsDirectory/sa/*.xml] {
-	    set xml [readUtfOrUnicode $fname]
-	    set xml1 [string range $xml 0 10]
-	    set xml2 [string range $xml 11 end]
-	    set result [catch {::dom::DOMImplementation parse xx${xml1} -final 0}]
-	    if {$result == 1} {
-		incr count
-		continue
-	    }
-	    # intentionally bad xml -- all parsing should fail
-	    set result [catch {::dom::DOMImplementation parse $xml2 -final 1} doc]
-	    if {$result == 0} {
-		::dom::DOMImplementation destroy $doc
-		incr passCount
-	    } else {
-		incr count
-	    }
-	}
-	list $count $passCount	
-    } -result {119 0}
-
-    test parse-3.1 {parse error reporting} -match regexp -body {
-	expectError {
-	    ::dom::DOMImplementation parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test>
-<A>
-<B>
-Here is some text
-</A>
-</B>
-</Test>}
-	}
-    } -result {(.*tag-name-mismatch.*)|(illegalendtag.*)}
-
-    test parse-3.2 {parse error reporting; error at char pos 0} -match regexp -body {
-	expectError {
-	    ::dom::DOMImplementation parse {>?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test>
-<A>
-<B>
-Here is some text
-</B>
-</A>
-</Test>}
-	}
-    } -result {(.*document-empty.*)|(unexpectedtext.*)}
-
-    test parse-3.3 {parse error reporting -- error at last char} -match regexp -body {
-	expectError {
-    	    ::dom::DOMImplementation parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test>
-<A>
-<B>
-Here is some text
-</B>
-</A>
-</Test<}
-}
-    } -result {(.*greater-than-character-required.*)|(unclosedelement.*)}
-
-    test parse-3.4 {parse error reporting -- UNICODE source} -constraints {sa} -match glob -body {
-	set fname $::tcltest::testsDirectory/sa/049.xml
-	set xml [readBinary $fname]
-	set part1 [string range $xml 0 9]
-	set part2 [string range $xml 10 end]
-	set badXML [encoding convertfrom identity $part1]
-	if {$tcl_platform(byteOrder) == "littleEndian"} {
-	    append badXML [makeUnicode "<Z>"]
-	} else {
-	    append badXML [makeUnicode "\u3c00\u5a00\u3e00"]
-	}
-	append badXML [encoding convertfrom identity $part2]
-	expectError {
-    	    ::dom::DOMImplementation parse $badXML
-	}
-    } -result {error "not well-formed*}
-
-    test parse-3.5 {parse error reporting, UTF-16 source, error at first char} -constraints {sa} -body {
-	set fname $::tcltest::testsDirectory/sa/049.xml
-	set xml [readBinary $fname]
-	set badXML [encoding convertfrom identity [string range $xml 0 1]]
-	if {$tcl_platform(byteOrder) == "littleEndian"} {
-	    append badXML [makeUnicode ">"]
-	} else {
-	    append badXML [makeUnicode "\u3e00"]
-	}
-	append badXML [encoding convertfrom identity [string range $xml 2 end]]
-	expectError {
-	    ::dom::DOMImplementation parse $badXML
-	}
-    } -result {error "syntax error" at line 1 character 1; at "><!DOCTY"}
-
-    test parse-3.6 {parse error reporting, UTF-16 source, error at last char} -constraints {sa} -body {
-	set fname $::tcltest::testsDirectory/sa/049.xml
-	set xml [readBinary $fname]
-	set badXML [encoding convertfrom identity [string range $xml 0 end-4]]
-	if {$tcl_platform(byteOrder) == "littleEndian"} {
-	    append badXML [makeUnicode "Z"]
-	} else {
-	    append badXML [makeUnicode "\u5a00"]
-	}
-	expectError {
-	    ::dom::DOMImplementation parse $badXML
-	}
-    } -result {error "junk after document element" at line 7 character 12; at "Z" within ">£</doc>Z"}
-
-    test parse-3.8 {parse error reporting, UTF-16 source, error is CR} -constraints {sa} -body {
-	set fname $::tcltest::testsDirectory/sa/049.xml
-	set xml [readBinary $fname]
-	set badXML [encoding convertfrom identity [string range $xml 0 9]]
-	set part2 [string range $xml 10 end]
-	if {$tcl_platform(byteOrder) == "littleEndian"} {
-	    append badXML [makeUnicode "\n"]
-	} else {
-	    append badXML [makeUnicode "\u0a00"]
-	}
-	append badXML [encoding convertfrom identity $part2]
-	expectError {
-	    ::dom::DOMImplementation parse $badXML
-	}
-    } -result {error "syntax error" at line 1 character 1; at "<!DO" within "<!DO
-CTY"}
-
-    test parse-3.9 {parse error reporting; UTF-8 source, error is CR} -match regexp -body {
-	expectError {
-	    ::dom::DOMImplementation parse {<?xml version="1.0"?>
-<!DO
-CTYPE Test>
-<Test>
-<A>
-<B>
-Here is some text
-</B>
-</A>
-</Test>}
-	}
-    } -result {(.*NAME-required.*)|(unknowninstruction.*)}
-
-    test parse-4.1 {white space trimming} -constraints {dom_c} -body {
-	set part1 {<?xml version="1.0"?>
-    <Test>
-    <A>  abc  </A>
-    <B>
-    def
-    </B>
-    xyz}
-    set part2 {
-	</Test>}
-
-	# parse xml that contains <A>...</A>
-	set doc [::dom::DOMImplementation parse $part1 -final 0 -trim]
-	# parse rest of xml -- close tag for top node
-	::dom::DOMImplementation parse $part2 -final 1 -trim
-	set result [::dom::DOMImplementation serialize $doc]
-    } -cleanup {
-	::dom::DOMImplementation destroy $doc
-    } -result {<?xml version='1.0'?>
-<!DOCTYPE Test>
-<Test><A>  abc  </A><B>
-    def
-    </B>
-    xyz
-	</Test>}
-
-    #
-    # Test processing instruction parsing.
-    #
-    variable PIPARSE {
-	set piparse_text "<test><?PITGT processing instruction data?></test>"
-	set doc  [dom::DOMImplementation parse $piparse_text]
-	dom::trim $doc
-	set root [dom::document cget $doc -documentElement]
-	set children [dom::node children $root]
-	set pinode [lindex $children 0]
-    }
-    variable CLEANUP {
-	dom::destroy $doc
-    }
-
-    test parse-5.0 {Processing instruction parsing} -setup $PIPARSE -body {
-	dom::node cget $root -nodeName
-    } -cleanup $CLEANUP -result {test}
-
-    test parse-5.1 {PI present} -setup $PIPARSE -body {
-	llength $children
-    } -cleanup $CLEANUP -result 1
-
-    test parse-5.2 {PI right type} -setup $PIPARSE -body {
-	dom::node cget $pinode -nodeType
-    } -cleanup $CLEANUP -result {processingInstruction}
-
-    test parse-5.3 {PI node name} -setup $PIPARSE -body {
-	dom::node cget $pinode -nodeName
-    } -cleanup $CLEANUP -result {PITGT}
-
-    test parse-5.4 {PI node value} -setup $PIPARSE -body {
-	dom::node cget $pinode -nodeValue
-    } -cleanup $CLEANUP -result {processing instruction data}
-
-    test parse-5.5 {PI serialization} -setup $PIPARSE -constraints {!dom_libxml2} -body {
-	dom::DOMImplementation serialize $root
-    } -cleanup $CLEANUP -result $piparse_text
-
-    variable SETUP6 {
-	variable result {}
-	proc estart {tag attrs args} {
-	    variable result
-	    lappend result [list $tag $attrs]
-	}
-	proc pcdata {text args} {
-	    variable result
-	    lappend result $text
-	}
-    }
-    variable CLEANUP6 {
-	dom::destroy $doc
-	catch {unset result}
-	rename estart {}
-	rename pcdata {}
-    }
-
-    # TODO: pure-Tcl implementation should support this usage as well
-    test parse-6.0 {SAX callbacks} -setup $SETUP6 -constraints {dom_libxml2} -body {
-	set doc [dom::DOMImplementation parse {<Hello>World</Hello>} \
-	    -elementstartcommand [namespace code estart] \
-	    -characterdatacommand [namespace code pcdata]]
-	set result
-    } -cleanup $CLEANUP6 -result {{Hello {}} World}
-
-    cleanupTests
-}
-
-namespace delete ::dom::parseTest
-
-return
diff --git a/tclxml-3.2/tests/tcldom/perf-1.tcl b/tclxml-3.2/tests/tcldom/perf-1.tcl
deleted file mode 100644
index b8962f4..0000000
--- a/tclxml-3.2/tests/tcldom/perf-1.tcl
+++ /dev/null
@@ -1,18 +0,0 @@
-# Create $childNum^2 elements
-
-set childNum 50
-catch {set childNum $numChildren}
-set testNum 10
-catch {set testNum $numTests}
-
-time {
-    set doc [dom::DOMImplementation create]
-    set top [dom::document createElement $doc Test]
-    for {set i 0} {$i < $childNum} {incr i} {
-	set child [dom::document createElement $top Top]
-	for {set j 0} {$j < $childNum} {incr j} {
-	    dom::document createElement $child Child
-	}
-    }
-} $testNum
-
diff --git a/tclxml-3.2/tests/tcldom/serialization.test b/tclxml-3.2/tests/tcldom/serialization.test
deleted file mode 100644
index 20948fe..0000000
--- a/tclxml-3.2/tests/tcldom/serialization.test
+++ /dev/null
@@ -1,238 +0,0 @@
-# Commands covered:  ::dom::DOMimplementation serialize
-#
-# This file contains a collection of tests for one or more of the 
-# TclDOM commands.  Sourcing this file into Tcl runs the tests and
-# generates output for errors.  No output means no errors were found.
-#
-# Copyright (c) 2008 Explain
-# Copyright (c) 1998-2004 Zveno Pty Ltd.
-#
-# $Id: serialization.test,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require tcltest
-source [file join [tcltest::workingDirectory] tcldomutils.tcl]
-
-testPackage dom
-
-namespace eval ::dom::serializationTest {
-    namespace import -force ::tcltest::*
-
-    variable SETUP {
-	set doc [::dom::DOMImplementation create]
-	set top [::dom::document createElement $doc Test]
-	dom::node appendChild $doc $top
-    }
-    variable SETUP2 {
-	eval $SETUP
-	$top appendChild [set e1 [::dom::document createElement $top Element1]]
-	$top appendChild [set e2 [::dom::document createElement $top Element2]]
-	$top appendChild [set e3 [::dom::document createElement $top Element3]]
-    }
-    variable CLEANUP {
-	dom::destroy $doc
-    }
-
-    # The result may or may not use empty element syntax
-    test serialize-1.1 {single element document} -match regexp -setup $SETUP -body {
-	::dom::DOMImplementation serialize $doc
-    } -cleanup $CLEANUP -result {<\?xml version=('|")1\.0('|")( encoding=('|")[^'"]+('|"))?\?>
-(<!DOCTYPE Test>
-)?<Test(/>|></Test>)}
-
-    test serialize-1.2 {element-only document} -match regexp -setup $SETUP2 -body {
-	::dom::DOMImplementation serialize $doc
-    } -cleanup $CLEANUP -result {<\?xml version=('|")1.0('|")( encoding=('|")[^'"]+('|"))?\?>
-(<!DOCTYPE Test>
-)?<Test><Element1/><Element2/><Element3/></Test>}
-
-    test serialize-1.3 {serialize element} -constraints {!dom_libxml2} -setup $SETUP2 -body {
-	::dom::DOMImplementation serialize $top
-    } -result {<Test><Element1/><Element2/><Element3/></Test>}
-
-    test serialize-1.4 {serialize non-empty element} -match regexp -setup {
-	eval $SETUP2
-	$e1 appendChild [::dom::document createElement $e1 Child1]
-    } -body {
-	::dom::DOMImplementation serialize $doc
-    } -cleanup $CLEANUP -result {<\?xml version=('|")1.0('|")( encoding=('|")[^'"]+('|"))?\?>
-(<!DOCTYPE Test>
-)?<Test><Element1><Child1/></Element1><Element2/><Element3/></Test>}
-
-    test serialize-2.1 {missing document element} -match regexp -setup {
-	set doc [::dom::DOMImplementation create]
-    } -body {
-	::dom::DOMImplementation serialize $doc
-    } -cleanup $CLEANUP -result {(<\?xml version=('|")1.0('|")( encoding=('|")[^'"]+('|"))?\?>)?}
-
-    # The result may or may not use empty element syntax
-    test serialize-3.1 {XML declaration: attributes in correct order} -match regexp -setup {
-	set doc [::dom::DOMImplementation parse {<?xml version="1.0"?>
-<Test></Test>
-}]
-    } -body {
-	dom::DOMImplementation serialize $doc
-    } -cleanup $CLEANUP -result {<\?xml version=('|")1\.0('|")( encoding=('|")[^'"]+('|"))?\?>
-(<!DOCTYPE Test>
-)?<Test(/>|></Test>)}
-
-    # This test fails if using TclExpat
-
-    test serialize-3.2 {XML declaration: attributes in correct order} -match regexp -setup {
-	set doc [::dom::DOMImplementation parse {<?xml version="1.0" standalone="yes"?>
-<Test></Test>
-}]
-    } -body {
-	dom::DOMImplementation serialize $doc
-    } -cleanup $CLEANUP -result {<\?xml version=('|")1.0('|")( encoding=('|")[^'"]+('|"))? standalone=('|")yes('|")\?>
-(<!DOCTYPE Test>
-)?<Test(/>|></Test>)}
-
-    test serialize-3.3 {Doctype declaration} -match regexp -setup {
-	set doc [::dom::DOMImplementation parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test></Test>
-}]
-    } -body {
-	dom::DOMImplementation serialize $doc
-    } -cleanup $CLEANUP -result {<\?xml version=('|")1.0('|")( encoding=('|")[^'"]+('|"))?\?>
-(<!DOCTYPE Test>
-)?<Test(/>|></Test>)}
-
-    # See bug #525505
-    test serialize-3.4 {Document prologue} -match regexp -setup {
-	set doc [::dom::parse {<?xml version="1.0"?>
-<!-- a comment in the prologue -->
-<Test/>
-}]
-    } -body {
-	dom::serialize $doc
-    } -cleanup $CLEANUP -result {<\?xml version=('|")1.0('|")( encoding=('|")[^'"]+('|"))?\?>
-(<!DOCTYPE Test>
-)?<!-- a comment in the prologue -->(
-)?<Test/>}
-
-    test serialize-3.5 {Document epilogue} -match regexp -setup {
-	set doc [::dom::parse {<?xml version="1.0"?>
-<Test/>
-<!-- a comment in the epilogue -->
-}]
-    } -body {
-	dom::serialize $doc
-    } -cleanup $CLEANUP -result {<\?xml version=('|")1.0('|")( encoding=('|")[^'"]+('|"))?\?>
-(<!DOCTYPE Test>
-)?<Test/>(
-)?<!-- a comment in the epilogue -->}
-
-    # Test serialization of markup characters:
-
-    variable stText "<test>LT: < GT: > AMP: &</test>"
-    test serialize-4.1 {Serialization of markup characters in #PCDATA} -constraints {!dom_libxml2} -setup {
-	set doc [dom::DOMImplementation parse $stText]
-    } -body {
-	dom::DOMImplementation serialize [dom::document cget $doc -documentElement]
-    } -cleanup $CLEANUP -result $stText
-
-    variable stText {<tests>
-<test LT='<'/>
-<test GT='>'/>
-<test AMP='&'/>
-<test QUOT='"'/>
-<test APOS='''/>
-</tests>}
-    # Result may use different attribute quotes.
-    # Also, only the '<' and '&' are required to be escaped,
-    # but its OK for others to be as well.
-    test serialize-4.2 {Serialization of markup characters in attribute values} -constraints {!dom_libxml2} -match regexp -setup {
-	set doc [dom::DOMImplementation parse $stText]
-    } -body {
-	dom::DOMImplementation serialize [dom::document cget $doc -documentElement]
-    } -cleanup $CLEANUP -result {<tests>
-<test LT=('|")\<('|")/>
-<test GT=('|")(\>|>)('|")/>
-<test AMP=('|")\&('|")/>
-<test QUOT='(\"|")'/>
-<test APOS="(\'|')"/>
-</tests>}
-
-    # CDATA Sections may or may not be serialized using CDATA Section syntax
-    variable stText \
-    {<test>some plain text <![CDATA[ a CDATA section ]]> more text</test>}
-    test serialize-4.3 {Preserve CDATA sections} -constraints {!dom_libxml2} -match regexp -setup {
-	set doc [dom::DOMImplementation parse $stText]
-    } -body {
-	dom::DOMImplementation serialize [dom::document cget $doc -documentElement]
-    } -cleanup $CLEANUP -result {<test>some plain text (<!\[CDATA\[)? a CDATA section (]]>)? more text</test>}
-
-    # Test for bug #512704
-    test serialize-5.1 {Serialize reserved characters in attribute value} -constraints {!dom_libxml2} -match regexp -setup {
-	set doc [dom::DOMImplementation create]
-	set top [dom::document createElement $doc test]
-	dom::element setAttribute $top q {"all lll" <who at where.com>}
-    } -body {
-	dom::DOMImplementation serialize $doc
-    } -cleanup $CLEANUP -result {<\?xml version=('|")1.0('|")( encoding=('|")[^'"]+('|"))?\?>
-<!DOCTYPE test>
-<test q='"all lll" <who at where.com>'/>}
-    test serialize-5.1 {Serialize reserved characters in attribute value} -constraints {dom_libxml2} -match regexp -setup {
-	set doc [dom::DOMImplementation create]
-	set top [dom::document createElement $doc test]
-	dom::element setAttribute $top q {"all lll" <who at where.com>}
-    } -body {
-	dom::DOMImplementation serialize $doc
-    } -cleanup $CLEANUP -result {<\?xml version=('|")1.0('|")( encoding=('|")[^'"]+('|"))?\?>
-<test q=('|")"all lll" <who at where.com>('|")/>
-}
-
-    # XML Namespace support
-    test serialize-6.1 {XML Namespaces - from parsed document} -match regexp -setup {
-	set doc [dom::DOMImplementation parse {<t:Test xmlns:t='urn:test'><t:Value>ABC</t:Value></t:Test>
-}]
-    } -body {
-	dom::DOMImplementation serialize $doc
-    } -cleanup $CLEANUP -result {<\?xml version=("|')1\.0("|')( encoding=('|")[^'"]+('|"))?\?>
-(<!DOCTYPE t:Test>
-)?<t:Test xmlns:t=("|')urn:test("|')><t:Value>ABC</t:Value></t:Test>}
-
-    test serialize-6.2 {XML Namespaces - from generated document, prefix supplied} -match regexp -setup {
-	set doc [dom::DOMImplementation create]
-	set de [dom::document createElementNS $doc urn:test-uri test:Test]
-	dom::document createElementNS $de urn:test-uri test:Value
-    } -body {
-	dom::DOMImplementation serialize $doc
-    } -cleanup $CLEANUP -result {<\?xml version=("|')1\.0("|')( encoding=('|")[^'"]+('|"))?\?>
-(<!DOCTYPE test:Test>
-)?<test:Test xmlns:test=("|')urn:test-uri("|')><test:Value/></test:Test>}
-
-    test serialize-6.3 {XML Namespaces - from generated document, prefix not supplied} -match regexp -setup {
-	set doc [dom::DOMImplementation create]
-	set de [dom::document createElementNS $doc urn:test-uri Test]
-	dom::document createElementNS $de urn:test-uri Value
-    } -body {
-	dom::DOMImplementation serialize $doc
-    } -cleanup $CLEANUP -result {<\?xml version=("|')1\.0("|')( encoding=('|")[^'"]+('|"))?\?>
-(<!DOCTYPE [a-zA-Z0-9]+:Test>
-)?<[a-zA-Z0-9]+:Test xmlns:[a-zA-Z0-9]+=("|')urn:test-uri("|')><[a-zA-Z0-9]+:Value/></[a-zA-Z0-9]+:Test>}
-
-    # Bug 606621
-    test serialize-7.1 {Document prologue} -match regexp -setup {
-	set doc [dom::parse {<?xml version="1.0" encoding="utf-8" standalone="no"?>
-<?xml-stylesheet type="text/xsl" href="test_view.xsl"?>
-<!DOCTYPE test SYSTEM "test.dtd">
-<test />
-}]
-    } -body {
-	dom::serialize $doc
-    } -cleanup {
-	dom::destroy $doc
-    } -result {<\?xml version=("|')1.0("|') encoding=("|')utf-8("|') standalone=("|')no("|')\?>
-<\?xml-stylesheet type=("|')text/xsl("|') href=("|')test_view.xsl("|')\?>
-<!DOCTYPE test SYSTEM ("|')test.dtd("|')>
-<test */>
-}
-
-    cleanupTests
-}
-
-namespace delete ::dom::serializationTest
-
-return
diff --git a/tclxml-3.2/tests/tcldom/stress.test b/tclxml-3.2/tests/tcldom/stress.test
deleted file mode 100644
index 63a4857..0000000
--- a/tclxml-3.2/tests/tcldom/stress.test
+++ /dev/null
@@ -1,44 +0,0 @@
-# Features covered:  Stress test
-#
-# This file contains a collection of tests for the TclDOM package.
-# This file tests the package's overall realtime and memory performance.
-# Sourcing this file into Tcl runs the tests and generates output
-# for errors.  No output means no errors were found.
-#
-# Copyright (c) 2008 Explain
-# Copyright (c) 2004 Zveno Pty Ltd.
-#
-# $Id: stress.test,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require tcltest
-source [file join [tcltest::workingDirectory] tcldomutils.tcl]
-
-testPackage dom
-
-namespace eval ::dom::stressTest {
-    namespace import -force ::tcltest::*
-
-    variable SETUP {
-	proc createdoc {} {
-	    set doc [dom::create]
-	    set top [dom::document createElement $doc top]
-	    dom::document createElement $top child
-	    return $doc
-	}
-	proc createAndDestroy {} {
-	    set doc [createdoc]
-	    dom::destroy $doc
-	}
-    }
-    variable CLEANUP {}
-
-    test stress-1.1 {} -setup $SETUP -body {
-	time createAndDestroy 10000
-	ok
-    } -result {}
-
-    cleanupTests
-}
-
-namespace delete ::dom::stressTest
-return
diff --git a/tclxml-3.2/tests/tcldom/tcldomutils.tcl b/tclxml-3.2/tests/tcldom/tcldomutils.tcl
deleted file mode 100644
index 95eb3aa..0000000
--- a/tclxml-3.2/tests/tcldom/tcldomutils.tcl
+++ /dev/null
@@ -1,21 +0,0 @@
-# tcldomutils.tcl --
-#
-# This script prepares the testing environment for TclXML.
-#
-# Copyright (c) 2008 Explain
-# http://www.explain.com.au/
-# Copyright (c) 2003 Zveno Pty Ltd.
-#
-# $Id: tcldomutils.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require tcltest
-
-source [file join [tcltest::workingDirectory] .. testutils.tcl]
-
-eval tcltest::configure $argv
-
-if {[catch {package require dom::libxml2}]} {
-    tcltest::testConstraint dom_tcl 1
-} else {
-    tcltest::testConstraint dom_libxml2 1
-}
diff --git a/tclxml-3.2/tests/tcldom/treewalker.test b/tclxml-3.2/tests/tcldom/treewalker.test
deleted file mode 100644
index cc4f5e0..0000000
--- a/tclxml-3.2/tests/tcldom/treewalker.test
+++ /dev/null
@@ -1,848 +0,0 @@
-# Commands covered:  ::dom::treeWalker
-#
-# This file contains a collection of tests for one or more of the 
-# TclDOM commands.  Sourcing this file into Tcl runs the tests and
-# generates output for errors.  No output means no errors were found.
-#
-# Copyright (c) 2008 Explain
-# Copyright (c) 2002-2003 Zveno Pty Ltd
-# Copyright (c) 2000 Ajuba Solutions
-#
-# $Id: treewalker.test,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require tcltest
-source [file join [tcltest::workingDirectory] tcldomutils.tcl]
-
-testPackage dom
-
-namespace eval ::dom::treewalkerTest {
-    namespace import -force ::tcltest::*
-
-    variable xml1 {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test>This <b>is</b> text.<A>aaa<B>bbb</B>aaa2<C>ccc<D>ddd</D>ccc2</C>aaa3</A></Test>}
-
-    variable SETUP {
-	set doc [::dom::DOMImplementation parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test></Test>}]
-    }
-    variable CLEANUP {
-	dom::destroy $doc
-    }
-
-    test treewalker-2.1 {argument parsing} -constraints {dom_c} -body {
-	expectError {
-	    dom::treeWalker
-	}
-    } -result {wrong # args: should be "dom::treeWalker method handle ?arg ...?"}
-    test treewalker-2.2 {argument parsing} -constraints {dom_c} -body {
-	expectError {
-	    dom::treeWalker foo
-	}
-    } -result {bad method "foo": must be cget, configure, parentNode, firstChild, lastChild, previousSibling, nextSibling, previousNode, or nextNode}
-    test treewalker-2.3 {argument parsing} -constraints {dom_c} -body {
-	expectError {
-	    dom::treeWalker cget blah
-	}
-    } -result {token not found}
-
-    test treewalker-1.1 {treewalker creation} -constraints {dom_c} -setup $SETUP -body {
-	set result [catch {dom::DocumentTraversal createTreeWalker $doc} \
-	    treewalker]
-	set handle [string range $treewalker 0 9]
-	list $result $handle
-    } -cleanup $CLEANUP -result {0 treewalker}
-
-    test treewalker-1.2 {treewalker creation} -constraints {dom_c} -setup $SETUP -body {
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc]
-	set result [catch {dom::treeWalker nextNode $treewalker} first]
-	set handle [string range $first 0 3]
-	list $result $handle
-    } -cleanup $CLEANUP -result {0 node}
-
-    test treewalker-2.1 {treewalker cget -show} -constraints {dom_c} -setup {
-	set doc [::dom::DOMImplementation parse {<?xml version="1.0"?><A></A>}]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc -show \
-		[list element textNode]]
-    } -body {
-	set result [catch {::dom::treeWalker cget $treewalker -show} value]
-	list $result $value
-    } -cleanup $CLEANUP -result {0 {element textNode}}
-
-    test treewalker-2.2 {treewalker configure -show} -constraints {dom_c} -setup {
-	set doc [::dom::DOMImplementation parse {<?xml version="1.0"?><A></A>}]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc -show \
-		[list element textNode]]
-    } -body {
-	::dom::treeWalker configure $treewalker -show
-    } -cleanup $CLEANUP -result {element textNode}
-
-    test treewalker-2.3 {treewalker configure -show readonly} -constraints {dom_c} -setup {
-	set doc [::dom::DOMImplementation parse {<?xml version="1.0"?><A></A>}]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc -show \
-		[list element textNode]]
-    } -body {
-	expectError {
-	    ::dom::treeWalker configure $treewalker \
-		-show [list element]
-	}
-    } -cleanup $CLEANUP -result {no modification allowed error: an attempt was made to modify an object where modifications are not allowed}
-
-    test treewalker-2.4 {treewalker cget -filter} -constraints {dom_c} -setup {
-	set doc [::dom::DOMImplementation parse {<?xml version="1.0"?><A></A>}]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc \
-		-filter nodeFilter]
-    } -body {
-	::dom::treeWalker cget $treewalker -filter
-    } -cleanup $CLEANUP -result nodeFilter
-
-    test treewalker-2.5 {treewalker configure -filter} -constraints {dom_c} -setup {
-	set doc [::dom::DOMImplementation parse {<?xml version="1.0"?><A></A>}]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc \
-		-filter nodeFilter]
-    } -body {
-	::dom::treeWalker configure $treewalker -filter
-    } -cleanup $CLEANUP -result nodeFilter
-
-    test treewalker-2.6 {treewalker configure -filter readonly} -constraints {dom_c} -setup {
-	set doc [::dom::DOMImplementation parse {<?xml version="1.0"?><A></A>}]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc \
-		-filter nodeFilter]
-    } -body {
-	expectError {
-	    ::dom::treeWalker configure $treewalker \
-		-filter someFilter
-	}
-    } -cleanup $CLEANUP -result {no modification allowed error: an attempt was made to modify an object where modifications are not allowed}
-
-    test treewalker-2.7 {treewalker cget -expandEntities} -constraints {dom_c} -setup {
-	set doc [::dom::DOMImplementation parse {<?xml version="1.0"?><A></A>}]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc]
-    } -body {
-	::dom::treeWalker cget $treewalker \
-		-expandEntities
-    } -cleanup $CLEANUP -result {}
-
-    test treewalker-2.8 {treewalker configure -expandEntities} -constraints {dom_c} -setup {
-	set doc [::dom::DOMImplementation parse {<?xml version="1.0"?><A></A>}]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc]
-    } -body {
-	::dom::treeWalker configure $treewalker \
-		-expandEntities
-    } -cleanup $CLEANUP -result {}
-
-    test treewalker-2.9 {treewalker configure -expandEntities readonly} -constraints {dom_c} -setup {
-	set doc [::dom::DOMImplementation parse {<?xml version="1.0"?><A></A>}]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc]
-    } -body {
-	expectError {
-	    ::dom::treeWalker configure $treewalker \
-		-expandEntities 1
-	}
-    } -cleanup $CLEANUP -result {no modification allowed error: an attempt was made to modify an object where modifications are not allowed}
-
-    test treewalker-2.10 {treewalker cget -currentNode} -constraints {dom_c} -setup {
-	set doc [::dom::DOMImplementation parse {<?xml version="1.0"?><A></A>}]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc]
-    } -body {
-	set value [::dom::treeWalker cget $treewalker \
-		-currentNode]
-	string compare $doc $value
-    } -cleanup $CLEANUP -result 0
-
-    test treewalker-2.10 {treewalker configure -currentNode} -constraints {dom_c} -setup {
-	set doc [::dom::DOMImplementation parse {<?xml version="1.0"?><A></A>}]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc]
-    } -body {
-	set value [::dom::treeWalker configure $treewalker \
-		-currentNode]
-	string compare $document $value
-    } -cleanup $CLEANUP -result 0
-
-    test treewalker-2.10 {treewalker configure -currentNode writable} -constraints {dom_c} -setup {
-	set doc [::dom::DOMImplementation parse {<?xml version="1.0"?><A></A>}]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc]
-	set topNode [dom::document cget $document -documentElement]
-    } -body {
-	set result [catch {::dom::treeWalker configure $treewalker \
-		-currentNode $topNode} value]
-	set result [catch {::dom::treeWalker configure $treewalker \
-		-currentNode} value]
-	list $result [string compare $topNode $value]
-    } -cleanup $CLEANUP -result {0 0}
-
-    test treewalker-3.1 {basic iteration} -constraints {dom_c} -setup {
-	set doc [::dom::DOMImplementation parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test>This <b>is</b>text.</Test>}]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc]
-	set result {}
-    } -body {
-	for {set i 0} {$i < 9} {incr i} {
-		set node [dom::treeWalker nextNode $treewalker]
-		if {$node == ""} break;
-		lappend result [dom::node cget $node -nodeType]
-		lappend result [dom::node cget $node -nodeName]
-		lappend result [dom::node cget $node -nodeValue]
-	}
-	set result	
-    } -cleanup $CLEANUP -result {documentType Test {} element Test {} textNode #text {This } element b {} textNode #text is textNode #text text.}
-
-    test treewalker-3.2 {basic iteration with -show} -constraints {dom_c} -setup {
-	set doc [::dom::DOMImplementation parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test>This <b>is</b>text.</Test>}]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc \
-		-show [list element textNode]]
-	set result {}
-    } -body {
-	for {set i 0} {$i < 9} {incr i} {
-		set node [dom::treeWalker nextNode $treewalker]
-		if {$node == ""} break;
-		lappend result [dom::node cget $node -nodeType]
-		lappend result [dom::node cget $node -nodeName]
-		lappend result [dom::node cget $node -nodeValue]
-	}
-	set result	
-    } -cleanup $CLEANUP -result {element Test {} textNode #text {This } element b {} textNode #text is textNode #text text.}
-
-    test treewalker-3.3 {basic reverse iteration} -constraints {dom_c} -setup {
-	set doc [::dom::DOMImplementation parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test>This <b>is</b>text.</Test>}]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc]
-	set result {}
-    } -body {
-	for {set i 0} {$i < 9} {incr i} {
-		set node [dom::treeWalker nextNode $treewalker]
-		if {$node == ""} break;
-	}
-	for {set i 0} {$i < 9} {incr i} {
-		set node [dom::treeWalker previousNode $treewalker]
-		if {$node == ""} break;
-		lappend result [dom::node cget $node -nodeType]
-		lappend result [dom::node cget $node -nodeName]
-		lappend result [dom::node cget $node -nodeValue]
-	}
-	set result	
-    } -cleanup $CLEANUP -result {textNode #text is element b {} textNode #text {This } element Test {} documentType Test {} document #document {}}
-
-    test treewalker-3.4 {basic reverse iteration with -show} -constraints {dom_c} -setup {
-	set doc [::dom::DOMImplementation parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test>This <b>is</b>text.</Test>}]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc \
-		-show [list element textNode]]
-	set result {}
-    } -body {
-	for {set i 0} {$i < 9} {incr i} {
-		set node [dom::treeWalker nextNode $treewalker]
-		if {$node == ""} break;
-	}
-	for {set i 0} {$i < 9} {incr i} {
-		set node [dom::treeWalker previousNode $treewalker]
-		if {$node == ""} break;
-		lappend result [dom::node cget $node -nodeType]
-		lappend result [dom::node cget $node -nodeName]
-		lappend result [dom::node cget $node -nodeValue]
-	}
-	set result	
-    } -cleanup $CLEANUP -result {textNode #text is element b {} textNode #text {This } element Test {}}
-
-    test treewalker-3.5 {complex iteration} -constraints {dom_c} -setup {
-	set doc [::dom::DOMImplementation parse $xml1]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc]
-	set result {}
-    } -body {
-	for {set i 0} {$i < 40} {incr i} {
-		set node [dom::treeWalker nextNode $treewalker]
-		if {$node == ""} break;
-		set name [dom::node cget $node -nodeName]
-		if {$name != "#text"} {
-			lappend result $name
-		} else {
-			lappend result [dom::node cget $node -nodeValue]
-		}
-	}
-	set result	
-    } -cleanup $CLEANUP -result {Test Test {This } b is { text.} A aaa B bbb aaa2 C ccc D ddd ccc2 aaa3}
-
-    test treewalker-3.6 {complex iteration} -constraints {dom_c} -setup {
-	set doc [::dom::DOMImplementation parse $xml1]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc]
-	set result {}
-    } -body {
-	for {set i 0} {$i < 40} {incr i} {
-		set node [dom::treeWalker nextNode $treewalker]
-		if {$node == ""} break;
-	}
-	for {set i 0} {$i < 40} {incr i} {
-		set node [dom::treeWalker previousNode $treewalker]
-		if {$node == ""} break;
-		set name [dom::node cget $node -nodeName]
-		if {$name != "#text"} {
-			lappend result $name
-		} else {
-			lappend result [dom::node cget $node -nodeValue]
-		}
-	}
-	set result	
-    } -cleanup $CLEANUP -result {ccc2 ddd D ccc C aaa2 bbb B aaa A { text.} is b {This } Test Test #document}
-
-    test treewalker-3.7 {basic iteration both directions} -constraints {dom_c} -setup {
-	set doc [::dom::DOMImplementation parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test>This <b>is</b>text.</Test>}]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc]
-	set result {}
-    } -body {
-	set node [dom::treeWalker nextNode $treewalker]
-	lappend result [dom::node cget $node -nodeName]
-	set node [dom::treeWalker previousNode $treewalker]
-	lappend result [dom::node cget $node -nodeName]
-	set result	
-    } -cleanup $CLEANUP -result {Test #document}
-
-    test treewalker-3.8 {backup before start of list} -constraints {dom_c} -setup {
-	set doc [::dom::DOMImplementation parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test>This <b>is</b>text.</Test>}]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc]
-	set result {}
-    } -body {
-	set node [dom::treeWalker previousNode $treewalker]
-	set	node
-    } -cleanup $CLEANUP -result {}
-
-    test treewalker-3.9 {backup before start of list then forward} -constraints {dom_c} -setup {
-	set doc [::dom::DOMImplementation parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test>This <b>is</b>text.</Test>}]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc]
-	set result {}
-    } -body {
-	set node [dom::treeWalker previousNode $treewalker]
-	set node [dom::treeWalker previousNode $treewalker]
-	set node [dom::treeWalker previousNode $treewalker]
-	set node [dom::treeWalker previousNode $treewalker]
-	set node [dom::treeWalker nextNode $treewalker]
-	lappend result [dom::node cget $node -nodeName]
-	set	result
-    } -cleanup $CLEANUP -result {Test}
-
-    test treewalker-3.10 {inserts while iterating} -constraints {dom_c} -setup {
-	set doc [::dom::DOMImplementation parse $xml1]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc]
-	set result {}
-    } -body {
-	for {set i 0} {$i < 40} {incr i} {
-		set node [dom::treeWalker nextNode $treewalker]
-		if {$node == ""} break
-		set name [dom::node cget $node -nodeName]
-		if {$name != "#text"} {
-			lappend result $name
-			if {$name == "A"} {
-				set new [dom::document createTextNode $document "New Text"]
-				dom::node insertBefore $node $new \
-					[dom::node cget $node -firstChild]
-			}
-		} else {
-			lappend result [dom::node cget $node -nodeValue]
-		}
-	}
-	set result	
-    } -cleanup $CLEANUP -result {Test Test {This } b is { text.} A {New Text} aaa B bbb aaa2 C ccc D ddd ccc2 aaa3}
-
-    test treewalker-3.11 {deletions while iterating} -constraints {dom_c} -setup {
-	set doc [::dom::DOMImplementation parse $xml1]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc]
-	set result {}
-    } -body {
-	for {set i 0} {$i < 40} {incr i} {
-		set node [dom::treeWalker nextNode $treewalker]
-		if {$node == ""} break
-		set name [dom::node cget $node -nodeName]
-		if {$name != "#text"} {
-			lappend result $name
-			if {$name == "A"} {
-				dom::node removeChild $node [dom::node cget $node -firstChild]
-			}
-		} else {
-			lappend result [dom::node cget $node -nodeValue]
-		}
-	}
-	set result	
-    } -cleanup $CLEANUP -result {Test Test {This } b is { text.} A B bbb aaa2 C ccc D ddd ccc2 aaa3}
-
-    test treewalker-3.12 {reference node deletion while iterating} -constraints {dom_c} -setup {
-	set doc [::dom::DOMImplementation parse $xml1]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc]
-	set result {}
-    } -body {
-	for {set i 0} {$i < 40} {incr i} {
-		set node [dom::treeWalker nextNode $treewalker]
-		if {$node == ""} break
-		set name [dom::node cget $node -nodeName]
-		if {$name != "#text"} {
-			lappend result $name
-			if {$name == "B"} {
-				dom::node removeChild [dom::node cget $node -parent] $node
-			}
-		} else {
-			lappend result [dom::node cget $node -nodeValue]
-		}
-	}
-	set result	
-    } -cleanup $CLEANUP -result {Test Test {This } b is { text.} A aaa B aaa2 C ccc D ddd ccc2 aaa3}
-
-    test treewalker-3.13 {reference node deletion while iterating II} -constraints {dom_c} -setup {
-	set doc [::dom::DOMImplementation parse $xml1]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc]
-	set result {}
-    } -body {
-	for {set i 0} {$i < 40} {incr i} {
-		set node [dom::treeWalker nextNode $treewalker]
-		if {$node == ""} break
-		set name [dom::node cget $node -nodeName]
-		if {$name != "#text"} {
-			lappend result $name
-			if {$name == "C"} {
-				set nodeToDelete $node
-			} elseif {$name == "D"} {
-				dom::node removeChild [dom::node cget $nodeToDelete -parent] \
-					$nodeToDelete
-			}
-		} else {
-			lappend result [dom::node cget $node -nodeValue]
-		}
-	}
-	set result	
-    } -cleanup $CLEANUP -result {Test Test {This } b is { text.} A aaa B bbb aaa2 C ccc D aaa3}
-
-    test treewalker-3.14 {deletion of trailing reference node} -constraints {dom_c} -setup {
-	set doc [::dom::DOMImplementation parse {<?xml version="1.0"?>
-<!DOCTYPE Test><Test>xxx<A/></Test>}]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc]
-	set result {}
-	set node {}
-    } -body {
-	for {set i 0} {$i < 9} {incr i} {
-		set refNode $node
-		set node [dom::treeWalker nextNode $treewalker]
-		if {$node == ""} break;
-	}
-	set node [dom::treeWalker previousNode $treewalker]
-	dom::node removeChild [dom::node cget $refNode -parent] $refNode
-	set node [dom::treeWalker previousNode $treewalker]
-	lappend result [dom::node cget $node -nodeName]
-	set result
-    } -cleanup $CLEANUP -result {Test}
-
-    test treewalker-3.15 {complex iteration with filter} -constraints {dom_c} -setup {
-	proc nodeFilter {node} {
-		set value [dom::node cget $node -nodeValue]
-		if {$value == "aaa"} {
-			return $::dom::skip
-		} else {
-			return $::dom::accept
-		}
-	}
-		
-	set doc [::dom::DOMImplementation parse $xml1]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc \
-		-filter nodeFilter]
-	set result {}
-    } -body {
-	for {set i 0} {$i < 40} {incr i} {
-		set node [dom::treeWalker nextNode $treewalker]
-		if {$node == ""} break;
-		set name [dom::node cget $node -nodeName]
-		if {$name != "#text"} {
-			lappend result $name
-		} else {
-			lappend result [dom::node cget $node -nodeValue]
-		}
-	}
-	rename nodeFilter {}
-	set result	
-    } -cleanup {
-	eval $CLEANUP
-	rename nodeFilter {}
-    } -result {Test Test {This } b is { text.} A B bbb aaa2 C ccc D ddd ccc2 aaa3}
-
-    test treewalker-3.16 {firstChild} -constraints {dom_c} -setup {
-	set doc [::dom::DOMImplementation parse $xml1]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc]
-	set result {}
-    } -body {
-	set node [dom::treeWalker firstChild $treewalker]
-	lappend result [dom::node cget $node -nodeName]
-	lappend result [dom::node cget $node -nodeValue]
-	set result	
-    } -cleanup $CLEANUP -result {Test {}}
-
-    test treewalker-3.17 {firstChild with -show} -constraints {dom_c} -setup {
-	set doc [::dom::DOMImplementation parse $xml1]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc \
-		-show textNode]
-	set result {}
-    } -body {
-	set node [dom::treeWalker firstChild $treewalker]
-	lappend result [dom::node cget $node -nodeName]
-	lappend result [dom::node cget $node -nodeValue]
-	set result	
-    } -cleanup $CLEANUP -result {#text {This }}
-
-    test treewalker-3.18 {parentNode} -constraints {dom_c} -setup {
-	set doc [::dom::DOMImplementation parse $xml1]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc]
-	set result {}
-	set node [dom::treeWalker firstChild $treewalker]
-	set node [dom::treeWalker nextSibling $treewalker]
-	set node [dom::treeWalker firstChild $treewalker]
-    } -body {
-	set node [dom::treeWalker parentNode $treewalker]
-	lappend result [dom::node cget $node -nodeName]
-	lappend result [dom::node cget $node -nodeValue]
-	set result	
-    } -cleanup $CLEANUP -result {Test {}}
-
-    test treewalker-3.19 {parentNode with -show} -constraints {dom_c} -setup {
-	set doc [::dom::DOMImplementation parse $xml1]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc \
-		-show [list document textNode]]
-	set result {}
-	set node [dom::treeWalker firstChild $treewalker]
-	lappend result [dom::node cget $node -nodeName]
-	lappend result [dom::node cget $node -nodeValue]
-    } -body {
-	set node [dom::treeWalker parentNode $treewalker]
-	lappend result [dom::node cget $node -nodeName]
-	lappend result [dom::node cget $node -nodeValue]
-	set result	
-    } -cleanup $CLEANUP -result {#text {This } #document {}}
-
-    test treewalker-3.20 {nextSibling with -show} -constraints {dom_c} -setup {
-	set doc [::dom::DOMImplementation parse $xml1]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc \
-		-show [list document textNode]]
-	set result {}
-	set node [dom::treeWalker firstChild $treewalker]
-	lappend result [dom::node cget $node -nodeValue]
-    } -body {
-	while {1} {
-		set node [dom::treeWalker nextSibling $treewalker]
-		if {$node == ""} break
-		lappend result [dom::node cget $node -nodeValue]
-	}
-	set result	
-    } -cleanup $CLEANUP -result {{This } is { text.} aaa bbb aaa2 ccc ddd ccc2 aaa3}
-
-    test treewalker-3.21 {lastChild} -constraints {dom_c} -setup {
-	set doc [::dom::DOMImplementation parse $xml1]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc]
-	set result {}
-    } -body {
-	set node [dom::treeWalker lastChild $treewalker]
-	lappend result [dom::node cget $node -nodeName]
-	lappend result [dom::node cget $node -nodeValue]
-	set result	
-    } -cleanup $CLEANUP -result {Test {}}
-
-    test treewalker-3.22 {lastChild with -show} -constraints {dom_c} -setup {
-	set doc [::dom::DOMImplementation parse $xml1]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc \
-		-show textNode]
-	set result {}
-    } -body {
-	set node [dom::treeWalker lastChild $treewalker]
-	lappend result [dom::node cget $node -nodeName]
-	lappend result [dom::node cget $node -nodeValue]
-	set result	
-    } -cleanup $CLEANUP -result {#text aaa3}
-
-    test treewalker-3.23 {previousSibling with -show} -constraints {dom_c} -setup {
-	set doc [::dom::DOMImplementation parse $xml1]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc \
-		-show [list document textNode]]
-	set result {}
-	set node [dom::treeWalker lastChild $treewalker]
-	lappend result [dom::node cget $node -nodeValue]
-    } -body {
-	while {1} {
-		set node [dom::treeWalker previousSibling $treewalker]
-		if {$node == ""} break
-		lappend result [dom::node cget $node -nodeValue]
-	}
-	set result	
-    } -cleanup $CLEANUP -result {aaa3 ccc2 ddd ccc aaa2 bbb aaa { text.} is {This }}
-
-    test treewalker-3.24 {iteration with skip filter} -constraints {dom_c} -setup {
-	proc nodeFilter {node} {
-		set value [dom::node cget $node -nodeName]
-		if {$value == "A"} {
-			return $::dom::skip
-		} else {
-			return $::dom::accept
-		}
-	}
-		
-	set doc [::dom::DOMImplementation parse $xml1]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc \
-		-filter nodeFilter]
-	set result {}
-    } -body {
-	for {set i 0} {$i < 40} {incr i} {
-		set node [dom::treeWalker nextNode $treewalker]
-		if {$node == ""} break;
-		set name [dom::node cget $node -nodeName]
-		if {$name != "#text"} {
-			lappend result $name
-		} else {
-			lappend result [dom::node cget $node -nodeValue]
-		}
-	}
-	set result	
-    } -cleanup {
-	eval $CLEANUP
-	rename nodeFilter {}
-    } -result {Test Test {This } b is { text.} aaa B bbb aaa2 C ccc D ddd ccc2 aaa3}
-
-    test treewalker-3.25 {iteration with reject filter} -constraints {dom_c} -setup {
-	proc nodeFilter {node} {
-		set value [dom::node cget $node -nodeName]
-		if {$value == "A"} {
-			return $::dom::reject
-		} else {
-			return $::dom::accept
-		}
-	}
-		
-	set doc [::dom::DOMImplementation parse $xml1]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc \
-		-filter nodeFilter]
-	set result {}
-    } -body {
-	for {set i 0} {$i < 40} {incr i} {
-		set node [dom::treeWalker nextNode $treewalker]
-		if {$node == ""} break;
-		set name [dom::node cget $node -nodeName]
-		if {$name != "#text"} {
-			lappend result $name
-		} else {
-			lappend result [dom::node cget $node -nodeValue]
-		}
-	}
-	set result	
-    } -cleanup {
-	eval $CLEANUP
-	rename nodeFilter {}
-    } -result {Test Test {This } b is { text.}}
-
-    test treewalker-3.26 {reverse iteration with skip filter} -constraints {dom_c} -setup {
-	proc nodeFilter {node} {
-		set value [dom::node cget $node -nodeName]
-		if {$value == "A"} {
-			return $::dom::skip
-		} else {
-			return $::dom::accept
-		}
-	}
-		
-	set doc [::dom::DOMImplementation parse $xml1]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc \
-		-filter nodeFilter]
-	set result {}
-    } -body {
-	for {set i 0} {$i < 40} {incr i} {
-		set node [dom::treeWalker nextNode $treewalker]
-		if {$node == ""} break;
-	}
-	for {set i 0} {$i < 40} {incr i} {
-		set node [dom::treeWalker previousNode $treewalker]
-		if {$node == ""} break;
-		set name [dom::node cget $node -nodeName]
-		if {$name != "#text"} {
-			lappend result $name
-		} else {
-			lappend result [dom::node cget $node -nodeValue]
-		}
-	}
-	set result	
-    } -cleanup {
-	eval $CLEANUP
-	rename nodeFilter {}
-    } -result {ccc2 ddd D ccc C aaa2 bbb B aaa { text.} is b {This } Test Test #document}
-
-    test treewalker-3.27 {reverse iteration with reject filter} -constraints {dom_c} -setup {
-	# filter is noop while we go to last node
-	proc nodeFilter {node} {
-		return $::dom::accept
-	}
-		
-	set doc [::dom::DOMImplementation parse $xml1]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc \
-		-filter nodeFilter]
-	set result {}
-    } -body {
-	# advance to last node
-	for {set i 0} {$i < 40} {incr i} {
-		set node [dom::treeWalker nextNode $treewalker]
-		if {$node == ""} break;
-	}
-	proc nodeFilter {node} {
-		set value [dom::node cget $node -nodeName]
-		if {$value == "A"} {
-			return $::dom::reject
-		} else {
-			return $::dom::accept
-		}
-	}
-	for {set i 0} {$i < 40} {incr i} {
-		set node [dom::treeWalker previousNode $treewalker]
-		if {$node == ""} break;
-		set name [dom::node cget $node -nodeName]
-		if {$name != "#text"} {
-			lappend result $name
-		} else {
-			lappend result [dom::node cget $node -nodeValue]
-		}
-	}
-	set result	
-	# child nodes of filtered element appear because we're going
-	# backwards
-    } -cleanup {
-	eval $CLEANUP
-	rename nodeFilter {}
-    } -result {ccc2 ddd D ccc C aaa2 bbb B aaa { text.} is b {This } Test Test #document}
-
-    test treewalker-3.28 {iteration with deletion in filter} -constraints {dom_c} -setup {
-	# this example isn't good coding practice, but we need to test that the
-	# code at least holds up
-	proc nodeFilter {node} {
-		set value [dom::node cget $node -nodeName]
-		if {$value == "A"} {
-			set parent [dom::node cget $node -parentNode]
-			if {$parent != {}} {
-				dom::node removeChild $parent $node
-			}
-			return $::dom::accept
-		} else {
-			return $::dom::accept
-		}
-	}
-
-	set doc [::dom::DOMImplementation parse $xml1]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc \
-		-filter nodeFilter]
-	set result {}
-    } -body {
-	for {set i 0} {$i < 40} {incr i} {
-		set node [dom::treeWalker nextNode $treewalker]
-		if {$node == ""} break;
-		set name [dom::node cget $node -nodeName]
-		if {$name != "#text"} {
-			lappend result $name
-		} else {
-			lappend result [dom::node cget $node -nodeValue]
-		}
-	}
-	set result	
-    } -cleanup {
-	eval $CLEANUP
-	rename nodeFilter {}
-    } -result {Test Test {This } b is { text.} A aaa B bbb aaa2 C ccc D ddd ccc2 aaa3}
-
-
-    test treewalker-4.1 {treewalker deletion} -constraints {dom_c} -setup {
-	set doc [::dom::DOMImplementation parse $xml1]
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc \
-		-show [list document textNode]]
-    } -body {
-	::dom::DocumentTraversal destroy $treewalker
-    } -cleanup $CLEANUP -result {}
-
-    test treewalker-5.1 {delete document in filter proc} -constraints {dom_c} -setup {
-	proc nodeFilter {node} {
-		variable doc
-		dom::DOMImplementation destroy $doc
-		return $::dom::accept
-	}
-		
-	set doc [::dom::DOMImplementation parse $xml1]
-    } -body {
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc \
-		-filter nodeFilter]
-	set node [dom::treeWalker nextNode $treewalker]
- 	expectError {
-	    dom::node cget $node -nodeName
-	}
-    } -cleanup {
-	rename nodeFilter {}
-    } -result {token not found}
-
-    test treewalker-5.2 {delete document in filter proc} -constraints {dom_c} -setup {
-	proc nodeFilter {node} {
-		global document
-		dom::DOMImplementation destroy $document
-		return $::dom::accept
-	}
-		
-	variable doc [::dom::DOMImplementation parse $xml1]
-    } -body {
-	set treewalker [dom::DocumentTraversal createTreeWalker $doc \
-		-filter nodeFilter]
-	set node [dom::treeWalker nextNode $treewalker]
- 	set result [catch {dom::treeWalker nextNode $treewalker} errmsg]
-	rename nodeFilter {}
-	list $result $errmsg
-    } -cleanup {
-	rename nodeFilter {}
-    } -result {0 {}}
-
-    test treewalker-5.3 {delete treewalker in filter proc} -constraints {dom_c} -setup {
-	proc nodeFilter {node} {
-		variable treewalker
-		::dom::DocumentTraversal destroy $treewalker
-		return $::dom::accept
-	}
-
-	set doc [::dom::DOMImplementation parse $xml1]
-	variable treewalker [dom::DocumentTraversal createTreeWalker $doc \
-		-filter nodeFilter]
-    } -body {
-	# first invocation succeeds
-	set node [dom::treeWalker nextNode $treewalker]
-	expectError {
-	    dom::treeWalker nextNode $treewalker
-	}
-    } -cleanup {
-	eval $CLEANUP
-	rename nodeFilter {}
-    } -result {token not found}
-
-    test treewalker-5.4 {recursively invoke filter proc} -constraints {dom_c} -setup {
-	proc nodeFilter {node} {
-		variable treewalker
-		set node [dom::treeWalker nextNode $treewalker]
-		return $::dom::accept
-	}
-		
-	set doc [::dom::DOMImplementation parse $xml1]
-	variable treewalker [dom::DocumentTraversal createTreeWalker $doc \
-		-filter nodeFilter]
-	expectError {
-	    dom::treeWalker nextNode $treewalker
-	}
-    } -cleanup {
-	eval $CLEANUP
-	rename nodeFilter {}
-    } -result {too many nested calls * (infinite loop?)}
-
-    cleanupTests
-}
-
-namespace delete ::dom::treewalkerTest
-
-return
diff --git a/tclxml-3.2/tests/tcldom/validate.test b/tclxml-3.2/tests/tcldom/validate.test
deleted file mode 100644
index b53eb19..0000000
--- a/tclxml-3.2/tests/tcldom/validate.test
+++ /dev/null
@@ -1,131 +0,0 @@
-# Commands covered:  ::dom::validate
-#
-# This file contains a collection of tests for one or more of the 
-# TclDOM commands.  Sourcing this file into Tcl runs the tests and
-# generates output for errors.  No output means no errors were found.
-#
-# Copyright (c) 2008 Explain
-# Copyright (c) 2003-2004 Zveno Pty Ltd.
-#
-# $Id: validate.test,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require tcltest
-source [file join [tcltest::workingDirectory] tcldomutils.tcl]
-
-testPackage dom
-
-namespace eval ::dom::validateTest {
-    namespace import -force ::tcltest::*
-
-    variable SETUP {
-	set inst [dom::parse {<!DOCTYPE Test [
-  <!ELEMENT Test (#PCDATA)>
-]>
-<Test>This is a valid document</Test>
-}]
-    }
-    variable CLEANUP {
-	dom::destroy $inst
-    }
-
-    variable SCHEMASETUP {
-	set inst [dom::parse {<Test>a simple test document</Test>}]
-
-	set schema [dom::parse {<xsd:schema xmlns:xsd='http://www.w3.org/2001/XMLSchema'
-            elementFormDefault='unqualified'
-            attributeFormDefault='unqualified'>
-
-  <xsd:element name='Test' type='xsd:string'/>
-
-</xsd:schema>
-}]
-    }
-    variable SCHEMACLEANUP {
-	dom::destroy $inst
-	dom::destroy $schema
-    }
-
-    ### DTD validation
-
-    test validate-1.1 {validate too few args} -setup $SETUP -constraints {dom_libxml2} -match glob -body {
-	expectError {
-	    $inst dtd
-	}
-    } -cleanup $CLEANUP -result {wrong # args*}
-    test validate-1.2 {validate too many args} -setup $SETUP -constraints {dom_libxml2} -match glob -body {
-	expectError {
-	    $inst dtd validate another
-	}
-    } -cleanup $CLEANUP -result {wrong # args*}
-
-    test validate-1.3 {validate correct doc} -setup $SETUP -constraints {dom_libxml2} -body {
-	$inst dtd validate
-    } -cleanup $CLEANUP -result {}
-
-    test validate-1.4 {validate invalid doc} -constraints {dom_libxml2} -setup {
-	set bad [dom::parse {<!DOCTYPE Test [
-  <!ELEMENT Test (#PCDATA)>
-]>
-<Test>This is <emphasis>not</emphasis> a valid document</Test>}]
-    } -match glob -body {
-	expectError {
-	    $bad dtd validate
-	}
-    } -cleanup {
-	dom::destroy $bad
-    } -result {*unknown-element-type*}
-
-    ### WXS Schema-validation
-
-    test validate-2.1 {schema compile} -setup $SCHEMASETUP -constraints {dom_libxml2} -match glob -body {
-	$schema schema compile
-    } -cleanup $SCHEMACLEANUP -result {}
-    test validate-2.2 {schema method too few args} -setup $SCHEMASETUP -constraints {dom_libxml2} -match glob -body {
-	expectError {
-	    $schema schema
-	}
-    } -cleanup $SCHEMACLEANUP -result {wrong # args*}
-    test validate-2.3 {schema compile too many args} -setup $SCHEMASETUP -constraints {dom_libxml2} -match glob -body {
-	expectError {
-	    $schema schema compile another
-	}
-    } -cleanup $SCHEMACLEANUP -result {wrong # args*}
-
-    test validate-2.4 {schema validate valid doc} -constraints {dom_libxml2} -setup {
-	eval $SCHEMASETUP
-	$schema schema compile
-    } -body {
-	$schema schema validate $inst
-    } -cleanup $SCHEMACLEANUP -result {}
-
-    test validate-2.5 {schema validate invalid doc} -match regexp -constraints {dom_libxml2} -setup {
-	eval $SCHEMASETUP
-	$schema schema compile
-	set bad [dom::parse {<Test>a <emphasis>simple</emphasis> test document</Test>}]
-    } -body {
-	expectError {
-	    $schema schema validate $bad
-	}
-    } -cleanup {
-	eval $SCHEMACLEANUP
-    } -result {.*invalid-element.*|.*Element content is not allowed.*}
-
-    test validate-2.6 {schema compile invalid schema} -constraints {dom_libxml2} -match glob -setup {
-	eval $SCHEMASETUP
-	set badschema [dom::parse {<schema>this is not a schema</schema>}]
-    } -body {
-	expectError {
-	    $badschema schema compile
-	}
-    } -cleanup {
-	eval $SCHEMACLEANUP
-    } -result {* is not a schema*}
-
-    ### TODO: Relax NG validation
-
-    cleanupTests
-}
-
-namespace delete ::dom::validateTest
-
-return
diff --git a/tclxml-3.2/tests/tcldom/xmlswitch.test b/tclxml-3.2/tests/tcldom/xmlswitch.test
deleted file mode 100644
index c92231f..0000000
--- a/tclxml-3.2/tests/tcldom/xmlswitch.test
+++ /dev/null
@@ -1,95 +0,0 @@
-# Commands covered:  ::xmlswitch::xmlswitch
-#
-# This file contains a collection of tests for one or more of the 
-# xmlswitch commands.  It also tests the XPath parsing package.
-# Sourcing this file into Tcl runs the tests and
-# generates output for errors.  No output means no errors were found.
-#
-# Copyright (c) 2008 Explain
-# Copyright (c) 2000-2003 Zveno Pty Ltd.
-#
-# $Id: xmlswitch.test,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require tcltest
-source [file join [tcltest::workingDirectory] tcldomutils.tcl]
-
-testPackage xmlswitch
-
-namespace eval ::dom::xmlswitchTest {
-    namespace import -force ::tcltest::*
-
-    catch {namespace import ::xmlswitch::xmlswitch}
-
-    test xmlswitch-1.1 {Empty statement} -constraints {!dom_libxml2} -body {
-	xmlswitch {<test></test>} {
-	}
-    } -result {}
-
-    test xmlswitch-2.1 {Simple template in single argument} -constraints {!dom_libxml2} -setup {
-	set result {}
-    } -body {
-	xmlswitch {<test></test>} {
-	    test {
-		append result test
-	    }
-	    * {
-		append result *
-	    }
-	}
-	set result
-    } -result {test*}
-
-    test xmlswitch-2.2 {Match absolute path} -constraints {!dom_libxml2} -setup {
-	set result {}
-    } -body {
-	xmlswitch {<test><test/></test>} {
-	    /test {
-		append result absolute
-	    }
-	    test {
-		append result relative
-	    }
-	    * {
-		append result *
-	    }
-	}
-	set result
-    } -result {absoluterelative}
-
-    test xmlswitch-2.3 {Match predicate} -constraints {!dom_libxml2} -setup {
-	set result {}
-    } -body {
-	xmlswitch {<test><test/><test/></test>} {
-	    test[2] {
-		append result second
-	    }
-	    test[1] {
-		append result first
-	    }
-	}
-	set result
-    } -result {firstsecond}
-
-    test xmlswitch-3.1 {Simple template in multiple arguments} -constraints {!dom_libxml2} -setup {
-	set result {}
-    } -body {
-	xmlswitch {<test></test>} \
-	    test {
-		append result test
-	    } \
-	    * {
-		append result *
-	    }
-	set result
-    } -result {test}
-
-    # Test break return code
-
-    # Test continue return code
-
-    cleanupTests
-}
-
-namespace delete ::dom::xmlswitchTest
-
-return
diff --git a/tclxml-3.2/tests/tcldom/zzlast.test b/tclxml-3.2/tests/tcldom/zzlast.test
deleted file mode 100644
index 2c650d0..0000000
--- a/tclxml-3.2/tests/tcldom/zzlast.test
+++ /dev/null
@@ -1,34 +0,0 @@
-# Commands covered:  ::dom::DOMimplementation parse
-#
-# This file contains a collection of tests for one or more of the 
-# TclDOM commands.  Sourcing this file into Tcl runs the tests and
-# generates output for errors.  No output means no errors were found.
-#
-# Copyright (c) 2008 Explain
-# Copyright (c) 1998-2003 Zveno Pty Ltd.
-# Copyright (c) 2000 Ajuba Solutions
-#
-# $Id: zzlast.test,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require tcltest
-source [file join [tcltest::workingDirectory] tcldomutils.tcl]
-
-testPackage dom
-
-namespace eval ::dom::zzlastTest {
-    namespace import -force ::tcltest::*
-
-    test zzlast-1.1 {cleanup after incomplete parse} -constraints {!dom_libxml2} -body {
-	set part1 {<?xml version="1.0"?>}
-	set part2 {<!DOCTYPE Test><Test></Test>}
-	set result1 [catch {::dom::DOMImplementation parse $part1 -final 0} m1]
-	catch {::dom::DOMImplementation destroy $m2}
-	list $result1
-    } -result 0
-
-    cleanupTests
-}
-
-namespace delete ::dom::zzlastTest
-
-return
diff --git a/tclxml-3.2/tests/tclxml/README b/tclxml-3.2/tests/tclxml/README
deleted file mode 100755
index 948fb0c..0000000
--- a/tclxml-3.2/tests/tclxml/README
+++ /dev/null
@@ -1,32 +0,0 @@
-		TclXML Test Suite
-
-This directory contains test scripts for the TclXML package.
-See ../tcldom and ../tclxslt for tests for TclDOM and TclXSLT
-respectively.
-
-The Tcl interfaces to libxml2 and the Tcl-only implementations
-of an XML parser may be tested.  The test scripts accept the '-parser'
-argument to select which parser class to test.  Accepted values
-are 'xml', 'libxml2' and 'tclparser'.  Using the 'xml' value
-is not recommended, as the appropriate test constraint will not be
-set (this will result in various tests being performed that are not
-intended for the parser class that is the default - these will likely
-fail).
-
-all.tcl will test the parser class given by the 'parser' argument.
-If no '-parser' argument is given then all parser classes will
-be tested.
-
-The Tcl testing framework is used for testing TclXML.
-The file license.terms in this directory is from the
-Tcl distribution, and refers to this file, all.tcl and defs.tcl.
-
-MANIFEST:
----------
-
-README		Tcl test suite design document.
-all.tcl         support module that finds & runs all tests
-*.test          test scripts
-*.dtd           dtd files for external dtd test scripts
-
-RCS: @(#) $Id: README,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
diff --git a/tclxml-3.2/tests/tclxml/all.tcl b/tclxml-3.2/tests/tclxml/all.tcl
deleted file mode 100755
index 2df46ab..0000000
--- a/tclxml-3.2/tests/tclxml/all.tcl
+++ /dev/null
@@ -1,33 +0,0 @@
-# all.tcl --
-#
-# This file contains a support module to run all of the Tcl
-# tests.  It must be invoked using "source all.test" by 
-# a calling tcl script that has loaded the parser class it wishes to
-# test in this directory.
-#
-# Copyright (c) 2008 Explain
-# http://www.explain.com.au/
-# Copyright (c) 2003 Zveno Pty Ltd
-# Copyright (c) 1998-1999 by Scriptics Corporation.
-#
-# All rights reserved.
-# 
-# RCS: @(#) $Id: all.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require Tcl 8.4
-package require tcltest 2.2
-tcltest::Option -parser xml {
-    Selects the XML parser class.
-} AcceptAll parser
-tcltest::configure -testdir [file dirname [file normalize [info script]]]
-eval tcltest::configure $argv
-
-if {$::tcltest::parser == "xml"} {
-    foreach parser {libxml2 tclparser} {
-	puts "\nTesting parser class \"$parser\"\n"
-	tcltest::configure -parser $parser
-	tcltest::runAllTests
-    }
-} else {
-    tcltest::runAllTests
-}
diff --git a/tclxml-3.2/tests/tclxml/attribute.test b/tclxml-3.2/tests/tclxml/attribute.test
deleted file mode 100755
index df0604e..0000000
--- a/tclxml-3.2/tests/tclxml/attribute.test
+++ /dev/null
@@ -1,333 +0,0 @@
-# Features covered:  Attribute Lists
-#
-# This file contains a collection of tests for the TclXML parser.
-# This file tests the parser's performance on Attribute Lists.
-# Sourcing this file into Tcl runs the tests and generates output
-# for errors.  No output means no errors were found.
-#
-# Copyright (c) 2008 Explain
-# http://www.explain.com.au/
-# Copyright (c) 1998-2004 Zveno Pty Ltd.
-#
-# $Id: attribute.test,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require tcltest
-source [file join [tcltest::workingDirectory] tclxmlutils.tcl]
-
-testPackage $::tcltest::parser
-
-namespace eval ::xml::attributeTest {
-    namespace import -force ::tcltest::*
-
-    variable SETUP {
-	variable countAttributesOnly 1
-	variable result
-	catch {unset result}
-	array set result {}
-
-	proc EStart {tagName attrList args} {
-	    variable result
-	    variable countAttributesOnly
-
-	    if {![llength $attrList] && !$countAttributesOnly} {
-		if {[info exists result($tagName)]} {
-		    set count 0
-		    while {[info exists result($tagName/[incr count])]} {}
-		    set result($tagName/$count) {}
-		} else {
-		    set result($tagName) {}
-		}
-		return {}
-	    }
-
-	    foreach {name value} $attrList {
-		if {[info exists result($tagName,$name)]} {
-		    set count 0
-		    while {[info exists result($tagName,$name,[incr count])]} {}
-		    set result($tagName,$name,$count) $value
-		} else {
-		    set result($tagName,$name) $value
-		}
-	    }
-	}
-
-	proc pcdata t {
-	    variable pcdata
-	    append pcdata $t
-	}
-
-	proc EntRef args {
-	    variable entrefs
-	    if {[catch {incr entrefs}]} {
-		set entrefs 1
-	    }
-	}
-
-	set parser [::xml::parser -elementstartcommand [namespace code EStart]]
-    }
-    variable SETUP2 {
-	eval $SETUP
-	$parser configure -characterdatacommand [namespace code pcdata]
-    }
-    variable SETUP3 {
-	eval $SETUP
-	$parser configure -entityreferencecommand [namespace code EntRef]
-	variable entrefs 0
-    }
-
-    variable CLEANUP {
-	$parser free
-	catch {unset result}
-	catch {unset pcdata}
-	catch {unset entrefs}
-	rename EStart {}
-	rename pcdata {}
-	rename EntRef {}
-    }
-
-    test attrList-1.1 {empty attribute list} -setup $SETUP -body {
-	$parser parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test></Test>
-}
-	array size result
-    } -cleanup $CLEANUP -result 0
-
-    test attrList-1.2 {single attribute} -setup $SETUP -body {
-	$parser parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test attr="1"></Test>
-}
-
-	array get result
-    } -cleanup $CLEANUP -result {Test,attr 1}
-
-    test attrList-1.3 {multiple distinct attributes} -setup $SETUP -body {
-	$parser parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test first="1" second='2'></Test>
-}
-
-	list [array size result] $result(Test,first) $result(Test,second)
-    } -cleanup $CLEANUP -result {2 1 2}
-
-    test attrList-1.4 {hyphen in attribute name} -setup $SETUP -body {
-	$parser parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test first-attr="1"></Test>
-}
-
-	array get result
-    } -cleanup $CLEANUP -result {Test,first-attr 1}
-
-    test attrList-2.1 {right angle bracket in attribute value} -setup $SETUP -body {
-	$parser parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test attr="value>"></Test>
-}
-
-	array get result
-    } -cleanup $CLEANUP -result {Test,attr value>}
-
-    test attrList-2.2 {right angle bracket in attribute value} -setup $SETUP -body {
-	$parser parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test attr="value1>value2"></Test>
-}
-
-	array get result
-    } -cleanup $CLEANUP -result {Test,attr value1>value2}
-
-    test attrList-2.3 {right angle bracket in attribute value} -setup $SETUP -body {
-	$parser parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test attr1="value1" attr2="value2>"></Test>
-}
-
-	sortedarray result
-    } -cleanup $CLEANUP -result {Test,attr1 value1 Test,attr2 value2>}
-
-    test attrList-2.4 {right angle bracket in attribute value} -setup $SETUP -body {
-	$parser parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test attr2="value2>" attr1="value1"></Test>
-}
-
-	sortedarray result
-    } -cleanup $CLEANUP -result {Test,attr1 value1 Test,attr2 value2>}
-
-    test attrList-2.5 {right angle brackets in attribute values} -setup $SETUP -body {
-	$parser parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test attr1="value>1" attr2="value>2"></Test>
-}
-
-	sortedarray result
-    } -cleanup $CLEANUP -result {Test,attr1 value>1 Test,attr2 value>2}
-
-    test attrList-2.6 {right angle brackets in attribute values} -setup $SETUP2 -body {
-	$parser parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test attr1="value>1">some text</Test>
-}
-
-	list [array get result] $pcdata
-    } -cleanup $CLEANUP -result {{Test,attr1 value>1} {some text}}
-
-    test attrList-3.1 {unnested left brace in attribute value} -setup $SETUP -body {
-	$parser parse [format {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test attr="%svalue"></Test>
-} \{]
-
-	array get result
-    } -cleanup $CLEANUP -result [list Test,attr [format {%svalue} \{]]
-
-    test attrList-3.2 {unnested right brace in attribute value} -setup $SETUP -body {
-	$parser parse [format {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test attr="value%s"></Test>
-} \}]
-
-	array get result
-    } -cleanup $CLEANUP -result [list Test,attr [format {value%s} \}]]
-
-    test attrList-3.3 {Tcl special characters in attribute value} -setup $SETUP -body {
-	$parser parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test attr="dollar $ backslash \ brackets [puts hello]"></Test>
-}
-
-	array get result
-    } -cleanup $CLEANUP -result {Test,attr {dollar $ backslash \ brackets [puts hello]}}
-
-    test attrList-4.1 {Unquoted attribute value} -constraints {xml_tcl} -setup $SETUP -match glob -body {
-	expectError {
-	    $parser parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test attr=noquotes></Test>
-}
-	}
-    } -cleanup $CLEANUP -result {*invalid attribute list around line 2*}
-    test attrList-4.1 {Unquoted attribute value} -constraints {xml_expat} -setup $SETUP -body {
-	expectError {
-	    $parser parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test attr=noquotes></Test>
-}
-	}
-    } -cleanup $CLEANUP -result {error "not well-formed" at line 3 character 11}
-    test attrList-4.1 {Unquoted attribute value} -constraints {xml_libxml2} -match glob -setup $SETUP -body {
-	expectError {
-	    $parser parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test attr=noquotes></Test>
-}
-	}
-    } -cleanup $CLEANUP -result {*unterminatedattribute*}
-
-    # Test case contributed by David Sutton <dsutton at coactive.com>
-    test attrList-5.0 {Complicated attribute list} -setup $SETUP2 -body {
-	variable countAttributesOnly 0
-
-	$parser parse {<?xml version="1.0"?>
-<event name='LogAlarmReset' ID='22' startDisabled='no' deleteOnCompletion='no' startDateTime='' endDateTime=''>
-  <stateChangeTrigger initialState='true' condition='AlarmSwitch = FALSE'/>
-  <eventAction>LightState = LightCtl</eventAction>
-  <eventAction>LOG(AlarmSwitch)</eventAction>
-  <eventAction>DISABLE(BlinkLight)</eventAction>
-  <eventAction>NOTIFY( AlarmSwitch,"Alarm has been reset")</eventAction>
-</event>
-}
-
-	regsub -all "\[ \t\n\]+" $pcdata { } pcdata
-	set sortedResult {}
-	foreach key [lsort -dictionary [array names result]] {
-	    lappend sortedResult $key $result($key)
-	}
-	list $sortedResult $pcdata
-    } -cleanup $CLEANUP -result [list {event,deleteOnCompletion no event,endDateTime {} event,ID 22 event,name LogAlarmReset event,startDateTime {} event,startDisabled no eventAction {} eventAction/1 {} eventAction/2 {} eventAction/3 {} stateChangeTrigger,condition {AlarmSwitch = FALSE} stateChangeTrigger,initialState true} { LightState = LightCtl LOG(AlarmSwitch) DISABLE(BlinkLight) NOTIFY( AlarmSwitch,"Alarm has been reset") }]
-
-    # Test case contributed by Marshall Rose <mrose at dbc.mtview.ca.us>
-    test attrList-5.1 {Attribute list with quoted value} -setup $SETUP -body {
-	variable countAttributesOnly 0
-
-	$parser parse {<test example="isn't this legal?"/>}
-
-	array get result
-    } -cleanup $CLEANUP -result {test,example {isn't this legal?}}
-
-    test attrList-5.2 {Attribute list with unresolved entity reference} -match glob -setup $SETUP -body {
-	variable countAttributesOnly 0
-
-	expectError {
-	    $parser parse {
-<test example='isn't this legal&ques;'/>
-}
-	}
-    } -cleanup $CLEANUP -result *
-
-    test attrList-5.3 {Attribute list with unresolved entity reference and entity callback} -setup $SETUP3 -body {
-	variable countAttributesOnly 0
-
-	$parser parse {
-<test example='isn't this great"'/>
-}
-
-	set entrefs
-    } -cleanup $CLEANUP -result 0
-
-    test attrList-5.4 {Attribute list with entity reference} -setup $SETUP -body {
-	variable countAttributesOnly 0
-
-	$parser parse {<!DOCTYPE test [
-<!ENTITY ques "?">
-]>
-<test example='isn't this great&ques;'/>
-}
-
-	array get result
-    } -cleanup $CLEANUP -result {test,example {isn't this great?}}
-
-    test attrList-5.5 {Attribute list with nested entity references} -setup $SETUP -body {
-	variable countAttributesOnly 0
-
-	$parser parse {<!DOCTYPE test [
-<!ENTITY level2 "OK">
-<!ENTITY rules "rules, &level2;?">
-]>
-<test example='XML &rules;'/>
-}
-
-	array get result
-    } -cleanup $CLEANUP -result {test,example {XML rules, OK?}}
-
-    # Test case contributed by Joe English, bug #546295
-    test attrList-5.6 {Attribute list with character entity references} -setup $SETUP -body {
-	variable countAttributesOnly 0
-
-	$parser parse {
-<foo bar="abc&#xA;def"/>
-}
-
-	array get result
-    } -cleanup $CLEANUP -result {foo,bar {abc
-def}}
-
-    # Test case contributed by Laurent Duperval, bug #620034
-    test attrList-5.7 {Attribute with right angle bracket} -setup $SETUP -body {
-	variable countAttributesOnly 0
-
-	$parser parse {
-<foo><bar att=">=foo"/></foo>
-}
-
-	array get result
-    } -cleanup $CLEANUP -result {foo {} bar,att >=foo}
-
-    cleanupTests
-}
-
-namespace delete ::xml::attributeTest
-
-return
diff --git a/tclxml-3.2/tests/tclxml/cdata.test b/tclxml-3.2/tests/tclxml/cdata.test
deleted file mode 100755
index 1a399a8..0000000
--- a/tclxml-3.2/tests/tclxml/cdata.test
+++ /dev/null
@@ -1,252 +0,0 @@
-# Features covered:  CDATA sections
-#
-# This file contains a collection of tests for the TclXML parser.
-# This file tests the parser's performance on CDATA sections.
-# Sourcing this file into Tcl runs the tests and generates output
-# for errors.  No output means no errors were found.
-#
-# Copyright (c) 1998-2003 Zveno Pty Ltd.
-#
-# $Id: cdata.test,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require tcltest
-source [file join [tcltest::workingDirectory] tclxmlutils.tcl]
-
-testPackage $::tcltest::parser
-
-namespace eval ::xml::cdataTest {
-    namespace import -force ::tcltest::*
-
-    variable SETUP {
-
-	variable element 0
-	variable result {}
-
-	proc pcdata data {
-	    variable result
-	    append result $data
-	}
-	proc EStart {tagName attrList args} {
-	    variable element
-	    switch -- $tagName {
-		Test {
-		}
-		default {
-		    incr element
-		}
-	    }
-	}
-
-	proc EStop {tagName args} {
-	}
-
-	set parser [xml::parser \
-		-elementstartcommand [namespace code EStart] \
-		-elementendcommand [namespace code EStop] \
-		-characterdatacommand [namespace code pcdata]]
-
-    }
-    variable CLEANUP {
-	catch {unset result}
-	catch {unset element}
-	rename EStart {}
-	rename pcdata {}
-	rename EStop {}
-	$parser free
-    }
-
-    test cdata-1.1 {Simple CDATA section} -setup $SETUP -body {
-	$parser parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test><![CDATA[This is CDATA]]></Test>
-}
-	list $result $element
-    } -cleanup $CLEANUP -result {{This is CDATA} 0}
-
-    test cdata-1.2 {CDATA test contributed by Richard Emberson (emberson at netintouch.com)} -setup $SETUP -body {
-	$parser parse {<?xml version="1.0"?>
-  <TOP>
-    <![CDATA[928806871035]]>
-  </TOP>
-}
-	list $result $element
-    } -cleanup $CLEANUP -result {{
-    928806871035
-  } 1}
-
-    # Test bug: ']]>' is not valid character data (XML Rec. subsect. 2.4) - 
-    # this should produce a warning.
-    test cdata-2.0 {CDATA section interpersed with comment} -setup $SETUP -body {
-	$parser parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test><![CDATA[<!-- This is not a comment -->]]>
-<!-- This is a comment <![CDATA[This is not CDATA]]>-->
-<![CDATA[<!-- ]]>-->]]></Test>}
-	list $result $element
-    } -cleanup $CLEANUP -result {{<!-- This is not a comment -->
-
-<!-- -->]]>} 0}
-
-    test cdata-2.1 {CDATA section with an angle bracket} -setup $SETUP -body {
-	$parser parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test><![CDATA[This is a > greater than sign]]></Test>
-}
-	list $result $element
-    } -cleanup $CLEANUP -result {{This is a > greater than sign} 0}
-
-    # Test case contributed by Marshall Rose (mrose at dbc.mtview.ca.us)
-    test cdata-2.2 {CDATA section with multiple angle brackets} -setup $SETUP -body {
-	$parser parse {<?xml version="1.0" ?>
-<!DOCTYPE Test>
-<Test>
-<artwork><![CDATA[
-    <?xml version="1.0">
-    <!DOCTYPE rfc SYSTEM "rfcXXXX.dtd">
-    <rfc>
-    ...
-
-    </rfc>
-]]></artwork>
-</Test>}
-	list $result $element
-    } -cleanup $CLEANUP -result {{
-
-    <?xml version="1.0">
-    <!DOCTYPE rfc SYSTEM "rfcXXXX.dtd">
-    <rfc>
-    ...
-
-    </rfc>
-
-} 1}
-
-    # Test case contributed by J. Linnenkohl (jlinnen at c-s-k.de)
-    test cdata-2.3 {CDATA section with square brackets and curly braces} -setup $SETUP -body {
-	$parser parse {<?xml version="1.0" ?>
-<Tcl>
-<![CDATA[
-proc arithmetic_add {groups inputs outputs atts} {
-    set ret_val ""
-    set t "Hello World"
-    set l [string length $t]
-    return $ret_val
-}
-]]>
-</Tcl>
-}
-	list $result $element
-    } -cleanup $CLEANUP -result {{
-
-proc arithmetic_add {groups inputs outputs atts} {
-    set ret_val ""
-    set t "Hello World"
-    set l [string length $t]
-    return $ret_val
-}
-
-} 1}
-
-    test cdata-2.4 {CDATA section with angle brackets and curly braces} -setup $SETUP -body {
-	$parser parse {<?xml version="1.0" ?>
-<Tcl>
-<![CDATA[
-proc arithmetic_add {groups inputs outputs atts} {
-    set ret_val [expr 1 > 2]
-    set t "Hello World"
-    set l [string length $t]
-    return $ret_val
-}
-]]>
-</Tcl>
-}
-	list $result $element
-    } -cleanup $CLEANUP -result {{
-
-proc arithmetic_add {groups inputs outputs atts} {
-    set ret_val [expr 1 > 2]
-    set t "Hello World"
-    set l [string length $t]
-    return $ret_val
-}
-
-} 1}
-
-    test cdata-2.5 {CDATA section with angle brackets, Tcl specials trailing CDATA section} -setup $SETUP -body {
-	$parser parse {<?xml version="1.0" ?>
-<Tcl>
-<![CDATA[
-proc arithmetic_add {groups inputs outputs atts} {
-    set ret_val [expr 1 > 2]
-    set t "Hello World"
-    set l [string length $t]
-    return $ret_val
-}
-]]> that is {jolly} $good
-</Tcl>
-}
-	list $result $element
-    } -cleanup $CLEANUP -result {{
-
-proc arithmetic_add {groups inputs outputs atts} {
-    set ret_val [expr 1 > 2]
-    set t "Hello World"
-    set l [string length $t]
-    return $ret_val
-}
- that is {jolly} $good
-} 1}
-
-    # Test case contributed by Marshall Rose (mrose at dbc.mtview.ca.us)
-    # SRB 2001-02-11: Test had to modified (slightly) to due non-well-formedness
-
-    test cdata-3.1 {CDATA section with PI and Tcl special characters} -setup $SETUP -body {
-	$parser parse {<?xml version="1.0"?>
-<?x_m_l_2rfc toc="yes"?>
-<!DOCTYPE Test>
-<Test>
-<t>this is a \ test</t>
-<artwork><![CDATA[
-    <date month="December" year="1998"/>
-]]></artwork>
-</Test>}
-	list $result $element
-    } -cleanup $CLEANUP -result {{
-this is a \ test
-
-    <date month="December" year="1998"/>
-
-} 2}
-
-    # Test case from bug #130127 reported by rnurmi at users.sourceforge.net
-
-    test cdata-3.2 {CDATA with Tcl special character} -setup $SETUP -body {
-	$parser parse [format {<?xml version="1.0"?>
-<root><![CDATA[%s]]></root>} \\]
-
-	set result
-    } -cleanup $CLEANUP -result [format %s \\]
-
-    # Test case from bug #130127 reported by rnurmi at users.sourceforge.net
-
-    test cdata-3.3 {CDATA with Tcl regular expression} -setup $SETUP -body {
-	$parser parse [format {<root><![CDATA[NOWRAP
-ALIGN=LEFT>([^<]*)[^%sn]*>([^<]*)</A>[^%sn]*>([-+][0-9]*%s.[0-9][0-9]|-)[^%sn]*>([0-9]*%s.[0-9][0-9])[^%sn]*>([0-9]*%s.[0-9][0-9])[^%sn]*>([0-9]*%s.[0-9][0-9])[^%sn]*>([0-9]*%s.[0-9][0-9])[^%sn]*>([0-9]*%s.[0-9][0-9])[^%sn]*>([0-9]+)[^%sn]*%s>([0-9]*)%s.[0-9][0-9])]]></root>} \\ \\ \\ \\ \\ \\ \\ \\ \\ \\ \\ \\ \\ \\ \\ \\ \\]
-
-	set result
-    } -cleanup $CLEANUP -result [format {NOWRAP
-ALIGN=LEFT>([^<]*)[^%sn]*>([^<]*)</A>[^%sn]*>([-+][0-9]*%s.[0-9][0-9]|-)[^%sn]*>([0-9]*%s.[0-9][0-9])[^%sn]*>([0-9]*%s.[0-9][0-9])[^%sn]*>([0-9]*%s.[0-9][0-9])[^%sn]*>([0-9]*%s.[0-9][0-9])[^%sn]*>([0-9]*%s.[0-9][0-9])[^%sn]*>([0-9]+)[^%sn]*%s>([0-9]*)%s.[0-9][0-9])} \\ \\ \\ \\ \\ \\ \\ \\ \\ \\ \\ \\ \\ \\ \\ \\ \\]
-
-    test cdata-4.1 {CDATA section with entity reference} -setup $SETUP -body {
-	$parser parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test><![CDATA[no entity <references>]]></Test>}
-	list $result $element
-    } -cleanup $CLEANUP -result {{no entity <references>} 0}
-
-    cleanupTests
-}
-
-namespace delete ::xml::cdataTest
-
-return
diff --git a/tclxml-3.2/tests/tclxml/comment.test b/tclxml-3.2/tests/tclxml/comment.test
deleted file mode 100755
index a093394..0000000
--- a/tclxml-3.2/tests/tclxml/comment.test
+++ /dev/null
@@ -1,167 +0,0 @@
-# Features covered:  comments
-#
-# This file contains a collection of tests for the TclXML parser.
-# This file tests the parser's performance on comments.
-# Sourcing this file into Tcl runs the tests and generates output
-# for errors.  No output means no errors were found.
-#
-# Copyright (c) 1998-2003 Zveno Pty Ltd.
-#
-# $Id: comment.test,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require tcltest
-source [file join [tcltest::workingDirectory] tclxmlutils.tcl]
-
-testPackage $::tcltest::parser
-
-namespace eval ::xml::commentTest {
-    namespace import -force ::tcltest::*
-
-    variable SETUP {
-	variable result {}
-	variable comment {}
-	variable element 0
-
-	proc pcdata data {
-	    variable result
-	    append result $data
-	}
-	proc comment data {
-	    variable comment
-	    append comment $data
-	}
-	proc EStart {tagName attrList args} {
-	    variable element
-	    switch -- $tagName {
-		test -
-		Test {
-		}
-		default {
-		    incr element
-		}
-	    }
-	}
-	proc EStop {tagName args} {
-	}
-
-	set parser [xml::parser \
-	    -elementstartcommand [namespace code EStart] \
-	    -elementendcommand [namespace code EStop] \
-	    -characterdatacommand [namespace code pcdata] \
-	    -commentcommand [namespace code comment]]
-    }
-
-    variable CLEANUP {
-	catch {unset result}
-	catch {unset comment}
-	catch {unset element}
-	rename pcdata {}
-	rename comment {}
-	rename EStart {}
-	rename EStop {}
-	$parser free
-    }
-
-    test comment-1.1 {Simple comment} -setup $SETUP -body {
-	$parser parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test><!-- This is a comment --></Test>
-}
-	list $comment $result $element
-    } -cleanup $CLEANUP -result {{ This is a comment } {} 0}
-
-    test comment-1.2 {Simple comment, no white space} -setup $SETUP -body {
-	$parser parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test><!--This is a comment--></Test>
-}
-	list $comment $result $element
-    } -cleanup $CLEANUP -result {{This is a comment} {} 0}
-
-    test comment-1.3 {Simple comment, within PCDATA} -setup $SETUP -body {
-	$parser parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test>surrounding <!--This is a comment--> PCDATA</Test>
-}
-	list $comment $result $element
-    } -cleanup $CLEANUP -result {{This is a comment} {surrounding  PCDATA} 0}
-
-    test comment-1.4 {Simple comment, no white space} -setup $SETUP -body {
-	$parser parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test><!--comment--></Test>
-}
-	list $comment $result $element
-    } -cleanup $CLEANUP -result {comment {} 0}
-
-    test comment-1.5 {comment, with nested element} -setup $SETUP -body {
-	$parser parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test><!-- comment <!blah>--></Test>
-}
-	list $comment $result $element
-    } -cleanup $CLEANUP -result {{ comment <!blah>} {} 0}
-
-    test comment-2.1 {comment with an angle bracket} -setup $SETUP -body {
-	$parser parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test><!-- This is a > greater than sign --></Test>
-}
-	list $comment $result $element
-    } -cleanup $CLEANUP -result {{ This is a > greater than sign } {} 0}
-
-    test comment-2.2 {comment with multiple angle brackets} -setup $SETUP -body {
-	$parser parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test><!-- 
-  <Test>
-    <Element>
-      <Empty/>
-    </Element>
-  </Test>
- --></Test>
-}
-	list $comment $result $element
-    } -cleanup $CLEANUP -result {{ 
-  <Test>
-    <Element>
-      <Empty/>
-    </Element>
-  </Test>
- } {} 0}
-
-    variable SETUP2 {
-	eval $SETUP
-	variable commentData [format {
-    <question title="This is <okay>, right?" />
-    <question title="Is <this> bogus?" />
-    <section title="This is a problem%s" />
-  } \}]
-    }
-    variable CLEANUP2 {
-	eval $CLEANUP
-	unset commentData
-    }
-
-    test comment-2.3 {comment with entities} -setup $SETUP2 -body {
-	$parser parse "<?xml version='1.0'?>
-<!DOCTYPE test SYSTEM 'test.dtd'>
-<test>
-
-<author>
-<organization/>
-</author>
-
-<!--${commentData}-->
-</test>"
-
-	list [string equal $comment $commentData] [string trim $result] $element
-    } -cleanup $CLEANUP2 -result [list 1 {} 2]
-
-
-    cleanupTests
-}
-
-namespace delete ::xml::commentTest
-
-return
diff --git a/tclxml-3.2/tests/tclxml/decls.test b/tclxml-3.2/tests/tclxml/decls.test
deleted file mode 100644
index 08b9df8..0000000
--- a/tclxml-3.2/tests/tclxml/decls.test
+++ /dev/null
@@ -1,353 +0,0 @@
-# Features covered:  Declarations
-#
-# This file contains a collection of tests for the TclXML parser.
-# This file tests the parser's performance on markup declarations.
-# Sourcing this file into Tcl runs the tests and generates output
-# for errors.  No output means no errors were found.
-#
-# Copyright (c) 2008 Explain
-# http://www.explain.com.au/
-# Copyright (c) 2000-2004 Zveno Pty Ltd.
-#
-# $Id: decls.test,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require tcltest
-source [file join [tcltest::workingDirectory] tclxmlutils.tcl]
-
-testPackage $::tcltest::parser
-
-namespace eval ::xml::declsTest {
-    namespace import -force ::tcltest::*
-
-    variable SETUP {
-	catch {unset elements}
-	variable elements
-	array set elements {}
-	catch {unset attrs}
-	variable attrs
-	array set attrs {}
-	catch {unset entities}
-	variable entities
-	array set entities {}
-	catch {unset externals}
-	variable externals
-	array set externals {}
-	catch {unset cdata}
-	variable cdata {}
-
-	proc elementDecl {name cmodel} {
-	    variable elements
-	    set elements($name) $cmodel
-	}
-	proc attlistDecl {name attName type default dfltValue} {
-	    variable attrs
-	    lappend attrs($name/$attName) $type $default $dfltValue
-	}
-	proc entityDecl {name args} {
-	    variable entities
-	    switch [llength $args] {
-		1 {
-		    set entities($name) [lindex $args 0]
-	 	}
-		2 {
-		    set externals($name) $args
-		}
-		default {
-		    error "wrong number of arguments"
-		}
-	    }
-	}
-	proc CData data {
-	    variable cdata
-	    append cdata [string trim $data]
-	}
-
-	set parser [xml::parser \
-		-elementdeclcommand [namespace code elementDecl] \
-		-attlistdeclcommand [namespace code attlistDecl] \
-		-entitydeclcommand [namespace code entityDecl]]
-
-    }
-    variable CLEANUP {
-	catch {unset elements}
-	catch {unset attrs}
-	catch {unset entities}
-	catch {unset externals}
-	catch {unset cdata}
-	rename elementDecl {}
-	rename attlistDecl {}
-	rename entityDecl {}
-	rename CData {}
-	$parser free
-    }
-
-    # Internal DTD subset
-
-    test decls-1.1 {element declaration} -setup $SETUP -constraints {!xml_libxml2} -body {
-	$parser parse {<?xml version="1.0"?>
-<!DOCTYPE Test [
-<!ELEMENT Test (#PCDATA)>
-]>
-<Test></Test>
-}
-
-	array get elements
-    } -cleanup $CLEANUP -result {Test (#PCDATA)}
-
-    test decls-2.1 {attribute list declaration, implied} -setup $SETUP -constraints {!xml_libxml2} -body {
-	$parser parse {<?xml version='1.0'?>
-<!DOCTYPE Test [
-<!ELEMENT Test (#PCDATA)>
-<!ATTLIST Test
-	test CDATA #IMPLIED>
-]>
-<Test test="value"/>}
-
-	array get attrs
-    } -cleanup $CLEANUP -result {Test/test {CDATA #IMPLIED {}}}
-
-    test decls-2.2 {attribute list declaration, enum} -setup $SETUP -constraints {!xml_libxml2} -body {
-	$parser parse {<?xml version='1.0'?>
-<!DOCTYPE Test [
-<!ELEMENT Test (#PCDATA)>
-<!ATTLIST Test
-	test (LGL|OTH) "LGL">
-]>
-<Test test="value"/>}
-
-	array get attrs
-    } -cleanup $CLEANUP -result {Test/test {LGL|OTH {} LGL}}
-
-    # Disable this test for the moment
-    test decls-2.3 {attribute list declaration, error} -setup $SETUP -match regexp -constraints {disabled} -body {
-	expectError {
-	    $parser parse {<?xml version='1.0'?>
-<!DOCTYPE Test [
-<!ELEMENT Test (#PCDATA)>
-<!ATTLIST Test
-	test CDATA>
-]>
-<Test test="value"/>}}
-    } -cleanup $CLEANUP -result {(unexpected text)|(.*space-required.*)}
-
-    # Bug #714316
-    test decls-2.4 {attribute list declaration - multiple attribute definitions} -setup $SETUP -body {
-	$parser parse {<!DOCTYPE Test [
-<!ELEMENT Test (#PCDATA)>
-<!ATTLIST Test
-	test CDATA #IMPLIED
-	id ID #IMPLIED>
-]>
-<Test/>
-}
-	ok
-    } -cleanup $CLEANUP -result {}
-
-    test decls-3.1 {entity declarations} -setup $SETUP -constraints {!xml_libxml2} -body {
-	$parser parse {<?xml version='1.0'?>
-<!DOCTYPE Test [
-<!ENTITY testEnt "replacement text">
-<!ELEMENT Test (#PCDATA)>
-]>
-<Test/>}
-
-	array get entities
-    } -cleanup $CLEANUP -result {testEnt {replacement text}}
-
-    test decls-4.1 {parameter entity declarations} -setup $SETUP -constraints {!xml_libxml2 && !xml_tcl} -body {
-	expectError {
-	$parser parse {<?xml version='1.0'?>
-<!DOCTYPE Test [
-<!ENTITY % PEnt "<!ELEMENT Test (#PCDATA)>">
-%PEnt;
-]>
-<Test/>}
-	}
-	#list [array get entities] [array get elements]
-    } -cleanup $CLEANUP -result {{PEnt {<!ELEMENT Test (#PCDATA)>}} {Test (#PCDATA)}}
-
-    # Example from XML Rec. section 4.5
-    test decls-4.2 {parameter entity declarations} -setup $SETUP -constraints {!xml_libxml2} -body {
-	$parser parse {<?xml version='1.0'?>
-<!DOCTYPE Test [
-<!ENTITY % pub    "&#xc9;ditions Gallimard" >
-<!ENTITY   rights "All rights reserved" >
-<!ENTITY   book   "La Peste: Albert Camus,
-&#xA9; 1947 %pub;. &rights;" >
-
-<!ELEMENT Test EMPTY>
-]>
-<Test>&book;</Test>}
-
-	array get entities book
-    } -cleanup $CLEANUP -result [list book [format {La Peste: Albert Camus,
-%c 1947 %cditions Gallimard. &rights;} 169 201]]
-
-    # First example from XML Rec. appendix D
-    # This test requires a validating parser
-    test decls-4.3 {parameter entity declarations} -setup $SETUP -constraints {validating} -body {
-	$parser configure -validate 1
-	$parser parse {<?xml version='1.0'?>
-<!DOCTYPE Test [
-<!ENTITY Example "<p>An ampersand (&#38;) may be escaped
-numerically (&#38;#38;) or with a general entity
-(&amp;).</p>" >
-
-<!ELEMENT Test (#PCDATA|p)*>
-<!ELEMENT p (#PCDATA)>
-]>
-<Test>&Example;</Test>}
-
-	set cdata
-    } -cleanup $CLEANUP -result {An ampersand (&) may be escaped
-numerically (&) or with a general entity
-(&).}
-
-    # NB. entity.test tests entity replacement as well
-
-    # External entities
-
-    test decls-5.1 {external entity} -setup $SETUP -constraints {validating} -body {
-	$parser configure \
-		-validate 1 \
-		-baseuri file://[file join [pwd] decls.test]]
-	$parser parse {<?xml version='1.0'?>
-<!DOCTYPE Test SYSTEM "dtd-5.1.dtd">
-<Test/>}
-
-	array get elements
-    } -cleanup $CLEANUP -result {Test (#PCDATA)}
-
-    test decls-5.2 {external DTD subset} -setup $SETUP -constraints {validating} -body {
-	$parser configure \
-		-validate 1 \
-		-parameterentitydeclcommand entityDecl \
-		-baseuri file://[file join [pwd] decls.test]]
-	$parser parse {<?xml version='1.0'?>
-<!DOCTYPE Test SYSTEM "dtd-5.2.dtd">
-<Test/>}
-
-	list [array get elements] [array get entities]
-    } -cleanup $CLEANUP -result {{Test (#PCDATA)} {content (#PCDATA)}}
-
-    test decls-5.3 {external entity} -setup $SETUP -constraints {validating} -body {
-	$parser configure \
-		-validate 1 \
-		-parameterentitydeclcommand entityDecl \
-		-baseuri file://[file join [pwd] decls.test]]
-	$parser parse {<?xml version='1.0'?>
-<!DOCTYPE Test [
-<!ENTITY % module SYSTEM "dtd-5.2.dtd">
-%module;
-]>
-<Test/>}
-
-	list [array get elements] [array get entities] [array get externals]
-    } -cleanup $CLEANUP -result {{Test (#PCDATA)} {content (#PCDATA)} {module {dtd-5.2.dtd {}}}}
-
-    # Bug #676399
-    test decls-5.4 {external entity w/- baseuri} -constraints {validating && !xml_tcl} -setup {
-	set parser [::xml::parser -validate 1 -baseuri file://[file join [workingDirectory] decls.test]]
-    } -constraints {xml_tcl} -body {
-	$parser parse {<?xml version='1.0' encoding='ISO-8859-1'?>
-<!DOCTYPE foo SYSTEM "dtd-5.4.dtd">
-<foo/>
-}
-    } -cleanup {
-	$parser free
-    } -result {}
-
-    # Conditional Sections
-
-    test decls-6.1 {conditional section: include} -setup $SETUP -constraints {validating} -body {
-	$parser configure \
-		-validate 1 \
-		-baseuri file://[file join [pwd] decls.test]]
-	$parser parse {<?xml version='1.0'?>
-<!DOCTYPE Test SYSTEM "dtd-6.1.dtd">
-<Test/>}
-
-	array get elements
-    } -cleanup $CLEANUP -result {Test (#PCDATA)}
-
-    test decls-6.2 {conditional section: include, empty} -setup $SETUP -constraints {validating} -body {
-	$parser configure \
-		-validate 1 \
-		-baseuri file://[file join [pwd] decls.test]]
-	$parser parse {<?xml version='1.0'?>
-<!DOCTYPE Test SYSTEM "dtd-6.2.dtd">
-<Test/>}
-
-	array get elements
-    } -cleanup $CLEANUP -result {}
-    test decls-6.3 {conditional section: include, empty} -setup $SETUP -constraints {validating} -body {
-	$parser configure \
-		-validate 1 \
-		-baseuri file://[file join [pwd] decls.test]]
-	$parser parse {<?xml version='1.0'?>
-<!DOCTYPE Test SYSTEM "dtd-6.3.dtd">
-<Test/>}
-
-	array get elements
-    } -cleanup $CLEANUP -result {}
-
-    test decls-6.4 {conditional section: include, nested} -setup $SETUP -constraints {validating} -body {
-	$parser configure \
-		-validate 1 \
-		-baseuri file://[file join [pwd] decls.test]]
-	$parser parse {<?xml version='1.0'?>
-<!DOCTYPE Test SYSTEM "dtd-6.4.dtd">
-<Test/>}
-
-	array size elements
-    } -cleanup $CLEANUP -result 3
-
-    test decls-6.5 {conditional section: ignore} -setup $SETUP -constraints {validating} -body {
-	$parser configure \
-		-validate 1 \
-		-baseuri file://[file join [pwd] decls.test]]
-	$parser parse {<?xml version='1.0'?>
-<!DOCTYPE Test SYSTEM "dtd-6.5.dtd">
-<Test/>}
-
-	array size elements
-    } -cleanup $CLEANUP -result 0
-
-    test decls-6.6 {conditional section/PE combo} -setup $SETUP -constraints {validating} -body {
-	$parser configure \
-		-validate 1 \
-		-baseuri file://[file join [pwd] decls.test]]
-	$parser parse {<?xml version='1.0'?>
-<!DOCTYPE Test SYSTEM "dtd-6.6.dtd">
-<Test/>}
-
-	array size elements
-    } -cleanup $CLEANUP -result 2
-
-    test decls-7.1 {comment in DTD} -setup $SETUP -constraints !xml_libxml2 -body {
-	$parser parse {
-<!DOCTYPE Test [
-<!-- a simple comment -->
-<!ELEMENT Test (#PCDATA)>
-]>
-<Test></Test>
-}
-	array get elements
-    } -cleanup $CLEANUP -result {Test (#PCDATA)}
-
-    test decls-7.2 {complex comment in DTD} -setup $SETUP -constraints !xml_libxml2 -body {
-	$parser parse {
-<!DOCTYPE Test [
-<!-- <Type> </Type> -->
-<!ELEMENT Test (#PCDATA)>
-]>
-<Test></Test>
-}
-	array get elements
-    } -cleanup $CLEANUP -result {Test (#PCDATA)}
-
-    cleanupTests
-}
-
-namespace delete ::xml::declsTest
-return
diff --git a/tclxml-3.2/tests/tclxml/doctype.test b/tclxml-3.2/tests/tclxml/doctype.test
deleted file mode 100755
index af4be4e..0000000
--- a/tclxml-3.2/tests/tclxml/doctype.test
+++ /dev/null
@@ -1,71 +0,0 @@
-# Features covered:  Document Type Declaration
-#
-# This file contains a collection of tests for the TclXML parser.
-# This file tests the parser's performance on Document Type Declarations.
-# Sourcing this file into Tcl runs the tests and generates output
-# for errors.  No output means no errors were found.
-#
-# Copyright (c) 1998-2003 Zveno Pty Ltd.
-#
-# $Id: doctype.test,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require tcltest
-source [file join [tcltest::workingDirectory] tclxmlutils.tcl]
-
-testPackage $::tcltest::parser
-
-namespace eval ::xml::doctypeTest {
-    namespace import -force ::tcltest::*
-
-    variable SETUP {
-	variable result {}
-
-	proc doctype {name pub system dtd} {
-	    variable result
-	    lappend result $name $pub $system $dtd
-	}
-
-	set parser [xml::parser \
-		-doctypecommand [namespace code doctype]]
-    }
-    variable CLEANUP {
-	catch {unset result}
-	rename doctype {}
-	$parser free
-    }
-
-    test doctype-1.1 {Document Type Declaration: no internal DTD subset} -setup $SETUP -constraints !xml_libxml2 -body {
-	$parser parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test></Test>
-}
-	set result
-    } -cleanup $CLEANUP -result {Test {} {} {{}}}
-
-    test doctype-2.1 {Document Type Declaration: internal DTD subset} -setup $SETUP -constraints !xml_libxml2 -body {
-	$parser parse {<?xml version="1.0"?>
-<!DOCTYPE Test [<!ELEMENT Test EMPTY>]>
-<Test></Test>
-}
-	set result
-    } -cleanup $CLEANUP -result {Test {} {} {{<!ELEMENT Test EMPTY>}}}
-
-    test doctype-2.2 {Document Type Declaration: internal DTD subset} -setup $SETUP -constraints !xml_libxml2 -body {
-	$parser parse {<?xml version="1.0"?>
-<!DOCTYPE Test [
-    <!ELEMENT Test EMPTY>
-    <!ATTLIST Test id CDATA #IMPLIED>
-]>
-<Test></Test>
-}
-	set result
-    } -cleanup $CLEANUP -result {Test {} {} {{
-    <!ELEMENT Test EMPTY>
-    <!ATTLIST Test id CDATA #IMPLIED>
-}}}
-
-    cleanupTests
-}
-
-namespace delete ::xml::doctypeTest
-return
diff --git a/tclxml-3.2/tests/tclxml/dtd-5.1.dtd b/tclxml-3.2/tests/tclxml/dtd-5.1.dtd
deleted file mode 100644
index b6b7e66..0000000
--- a/tclxml-3.2/tests/tclxml/dtd-5.1.dtd
+++ /dev/null
@@ -1 +0,0 @@
-<!ELEMENT Test (#PCDATA)>
diff --git a/tclxml-3.2/tests/tclxml/dtd-5.2.dtd b/tclxml-3.2/tests/tclxml/dtd-5.2.dtd
deleted file mode 100644
index 8d9374c..0000000
--- a/tclxml-3.2/tests/tclxml/dtd-5.2.dtd
+++ /dev/null
@@ -1,2 +0,0 @@
-<!ENTITY % content "(#PCDATA)">
-<!ELEMENT Test %content;>
diff --git a/tclxml-3.2/tests/tclxml/dtd-5.4.dtd b/tclxml-3.2/tests/tclxml/dtd-5.4.dtd
deleted file mode 100644
index 8cd7a23..0000000
--- a/tclxml-3.2/tests/tclxml/dtd-5.4.dtd
+++ /dev/null
@@ -1 +0,0 @@
-<!ELEMENT foo (#PCDATA)> 
diff --git a/tclxml-3.2/tests/tclxml/dtd-6.1.dtd b/tclxml-3.2/tests/tclxml/dtd-6.1.dtd
deleted file mode 100644
index 8efdc87..0000000
--- a/tclxml-3.2/tests/tclxml/dtd-6.1.dtd
+++ /dev/null
@@ -1,3 +0,0 @@
-<![INCLUDE[
-<!ELEMENT Test (#PCDATA)>
-]]>
diff --git a/tclxml-3.2/tests/tclxml/dtd-6.2.dtd b/tclxml-3.2/tests/tclxml/dtd-6.2.dtd
deleted file mode 100644
index 3303e61..0000000
--- a/tclxml-3.2/tests/tclxml/dtd-6.2.dtd
+++ /dev/null
@@ -1 +0,0 @@
-<![INCLUDE[]]>
diff --git a/tclxml-3.2/tests/tclxml/dtd-6.3.dtd b/tclxml-3.2/tests/tclxml/dtd-6.3.dtd
deleted file mode 100644
index aa4acd2..0000000
--- a/tclxml-3.2/tests/tclxml/dtd-6.3.dtd
+++ /dev/null
@@ -1 +0,0 @@
-<![INCLUDE[ ]]>
diff --git a/tclxml-3.2/tests/tclxml/dtd-6.4.dtd b/tclxml-3.2/tests/tclxml/dtd-6.4.dtd
deleted file mode 100644
index 0d1c71b..0000000
--- a/tclxml-3.2/tests/tclxml/dtd-6.4.dtd
+++ /dev/null
@@ -1,5 +0,0 @@
-<![INCLUDE[
-<!ELEMENT Test (Test2)>
-<![INCLUDE[<!ELEMENT Test2 (Test3)>
-<!ELEMENT Test3 (#PCDATA)>]]>
-]]>
diff --git a/tclxml-3.2/tests/tclxml/dtd-6.5.dtd b/tclxml-3.2/tests/tclxml/dtd-6.5.dtd
deleted file mode 100644
index bd95090..0000000
--- a/tclxml-3.2/tests/tclxml/dtd-6.5.dtd
+++ /dev/null
@@ -1,5 +0,0 @@
-<![IGNORE[
-<!ELEMENT Test (#PCDATA)>
-<!ELEMENT Test1 (#PCDATA)>
-<!ELEMENT Test2 (#PCDATA)>
-]]>
diff --git a/tclxml-3.2/tests/tclxml/dtd-6.6.dtd b/tclxml-3.2/tests/tclxml/dtd-6.6.dtd
deleted file mode 100644
index 7a77c75..0000000
--- a/tclxml-3.2/tests/tclxml/dtd-6.6.dtd
+++ /dev/null
@@ -1,6 +0,0 @@
-<!ENTITY % module "INCLUDE">
-<![%module;[
-<!ELEMENT Test (#PCDATA)>
-]]>
-<!ELEMENT Test2 (#PCDATA)>
-
diff --git a/tclxml-3.2/tests/tclxml/element.test b/tclxml-3.2/tests/tclxml/element.test
deleted file mode 100755
index 965d687..0000000
--- a/tclxml-3.2/tests/tclxml/element.test
+++ /dev/null
@@ -1,121 +0,0 @@
-# Features covered:  Elements
-#
-# This file contains a collection of tests for the TclXML parser.
-# This file tests the parser's performance on elements.
-# Sourcing this file into Tcl runs the tests and generates output
-# for errors.  No output means no errors were found.
-#
-# Copyright (c) 2005 Explain
-# http://www.explain.com.au/
-# Copyright (c) 1999-2003 Zveno Pty Ltd.
-#
-# $Id: element.test,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require tcltest
-source [file join [tcltest::workingDirectory] tclxmlutils.tcl]
-
-testPackage $::tcltest::parser
-
-namespace eval ::xml::elementTest {
-    namespace import -force ::tcltest::*
-
-    variable SETUP {
-	variable started
-	array set started {}
-	variable ended
-	array set ended {}
-	variable elList {}
-
-	proc parray arrayName {
-	    upvar #0 $arrayName arr
-	    set result {}
-	    foreach key [lsort [array names $arrayName]] {
-		lappend result $key $arr($key)
-	    }
-	    return $result
-	}
-
-	proc Start {name atList args} {
-	    variable started
-	    array set opts $args
-	    if {![info exists started($name)]} {
-		set started($name) 1
-	    } else {
-		incr started($name)
-	    }
-	}
-	proc End {name args} {
-	    variable ended
-	    array set opts $args
-	    if {![info exists ended($name)]} {
-		set ended($name) 1
-	    } else {
-		incr ended($name)
-	    }
-	}
-
-	proc ElStart {name atList args} {
-	    variable elList
-	    array set opts {-empty 0}
-	    array set opts $args
-	    lappend elList start $name $opts(-empty)
-	}
-	proc ElEnd {name args} {
-	    variable elList
-	    array set opts {-empty 0}
-	    array set opts $args
-	    lappend elList end $name $opts(-empty)
-	}
-
-	set parser [xml::parser]
-    }
-    variable CLEANUP {
-	catch {unset started}
-	catch {unset ended}
-	catch {unset elList}
-	rename parray {}
-	rename Start {}
-	rename End {}
-	rename ElStart {}
-	rename ElEnd {}
-	$parser free
-    }
-
-    test element-1.1 {document element} -setup $SETUP -body {
-	$parser configure \
-		-elementstartcommand [namespace code Start] \
-		-elementendcommand [namespace code End]
-	$parser parse {<Test></Test>}
-	list [array get started] [array get ended]
-    } -cleanup $CLEANUP -result {{Test 1} {Test 1}}
-
-    test element-1.2 {distinct elements} -setup $SETUP -body {
-	$parser configure \
-		-elementstartcommand [namespace code Start] \
-		-elementendcommand [namespace code End]
-	$parser parse {<Test><Child1></Child1><Child2></Child2></Test>}
-	list [parray [namespace current]::started] [parray [namespace current]::ended]
-    } -cleanup $CLEANUP -result {{Child1 1 Child2 1 Test 1} {Child1 1 Child2 1 Test 1}}
-    # Test case for bug #1029795 reported by zugilio at users.sf.net
-    test element-1.3 {distinct empty elements} -setup $SETUP -body {
-	$parser configure \
-		-elementstartcommand [namespace code Start] \
-		-elementendcommand [namespace code End]
-	$parser parse {<Test><Child1/><Child2/></Test>}
-	list [parray [namespace current]::started] [parray [namespace current]::ended]
-    } -cleanup $CLEANUP -result {{Child1 1 Child2 1 Test 1} {Child1 1 Child2 1 Test 1}}
-
-    test element-2.1 {empty element} -setup $SETUP -constraints !xml_libxml2 -body {
-	$parser configure \
-		-reportempty 1 \
-		-elementstartcommand [namespace code ElStart] \
-		-elementendcommand [namespace code ElEnd]
-	$parser parse {<Test><Child1/></Test>}
-	set elList
-    } -cleanup $CLEANUP -result {start Test 0 start Child1 1 end Child1 1 end Test 0}
-
-    cleanupTests
-}
-
-namespace delete ::xml::elementTest
-return
diff --git a/tclxml-3.2/tests/tclxml/entity.test b/tclxml-3.2/tests/tclxml/entity.test
deleted file mode 100755
index 77bd0ca..0000000
--- a/tclxml-3.2/tests/tclxml/entity.test
+++ /dev/null
@@ -1,175 +0,0 @@
-# Features covered:  Entities
-#
-# This file contains a collection of tests for the TclXML parser.
-# This file tests the parser's performance on entities.
-# Sourcing this file into Tcl runs the tests and generates output
-# for errors.  No output means no errors were found.
-#
-# Copyright (c) 2008 Explain
-# http://www.explain.com.au/
-# Copyright (c) 1999-2003 Zveno Pty Ltd.
-#
-# $Id: entity.test,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require tcltest
-source [file join [tcltest::workingDirectory] tclxmlutils.tcl]
-
-testPackage $::tcltest::parser
-
-namespace eval ::xml::entityTest {
-    namespace import -force ::tcltest::*
-
-    variable SETUP {
-	variable elements 0
-	variable result {}
-	variable references {}
-
-	proc Start {name attrList args} {
-	    variable elements
-	    incr elements
-	}
-
-	proc pcdata text {
-	    variable result
-	    append result $text
-	}
-
-	proc EntityRef name {
-	    variable references
-	    variable result
-	    lappend references $name
-	    append result ##entityreference##
-	    return {}
-	}
-
-	set parser [xml::parser \
-		-characterdatacommand [namespace code pcdata]]
-    }
-    variable CLEANUP {
-	catch {unset elements}
-	catch {unset result}
-	catch {unset references}
-	rename EntityRef {}
-	rename Start {}
-	rename pcdata {}
-	$parser free
-    }
-
-    test entity-1.1 {parameter entity in document entity} -setup $SETUP -body {
-	$parser parse {<!DOCTYPE Test [
-<!ENTITY % Wrong "This is wrong">
-]>
-<Test>%wrong;</Test>}
-	set result
-    } -cleanup $CLEANUP -result {%wrong;}
-
-    test entity-1.2 {character entities in hex} -setup $SETUP -body {
-	$parser parse {<Test>&#x41;&#x3C;&#x3e;&#x24;&#x5B;&#x5D;</Test>}
-	set result
-    } -cleanup $CLEANUP -result {A<>$[]}
-
-    test entity-1.3 {character entities in decimal} -setup $SETUP -body {
-	$parser parse {<Test>A<>$[]</Test>}
-	set result
-    } -cleanup $CLEANUP -result {A<>$[]}
-
-    test entity-1.4 {illegal character entity} -setup $SETUP -match regexp -body {
-	expectError {
-	    $parser parse {<Test>&#blah;</Test>}
-	}
-    } -cleanup $CLEANUP -result {(invalid decimal value)|(malformed character entity)}
-
-    test entity-2.1 {predefined general entities} -setup $SETUP -body {
-	$parser parse {<Test><>&"'</Test>}
-	set result
-    } -cleanup $CLEANUP -result {<>&"'}
-
-    test entity-2.2 {undefined general entities - no callback} -setup $SETUP -match regexp -body {
-	expectError {
-	    $parser parse {<Test>&undefined;</Test>}
-	}
-    } -cleanup $CLEANUP -result {(Entity 'undefined' not defined)|(undefined entity reference)}
-
-    test entity-2.3 {undefined general entities - with callback} -setup $SETUP -constraints {!xml_libxml2} -match glob -body {
-	$parser configure \
-		-entityreferencecommand [namespace code EntityRef]
-	$parser parse {<Test>&undefined;</Test>}
-	list $result $references
-    } -cleanup $CLEANUP -result {*##entityreference##* undefined}
-
-    # This example is from the XML Recommendation, Appendix D p. 29.
-
-    variable example1_p_content {An ampersand (&) may be escaped
-numerically (&) or with a general entity
-(&).}
-
-    test entity-3.1 {replacement text with element markup} -setup $SETUP -constraints {!xml_libxml2} -body {
-	$parser configure \
-		-elementstartcommand [namespace code Start]
-	$parser parse {<!DOCTYPE Test [
-    <!ENTITY example "<p>An ampersand (&#38;) may be escaped
-numerically (&#38;#38;) or with a general entity
-(&amp;).</p>">
-]>
-<Test>&example;</Test>}
-	list $result $elements
-    } -cleanup $CLEANUP -result [list $example1_p_content 2]
-
-    test entity-4.1 {entity references} -setup $SETUP -constraints {!xml_libxml2} -body {
-	$parser configure \
-		-entityreferencecommand [namespace code EntityRef]
-	$parser parse {<Test>undefined &myentity; reference</Test>}
-	list $result $references
-    } -cleanup $CLEANUP -result {{undefined ##entityreference## reference} myentity}
-
-    # Test case from bug #431353 submitted by Shaun Lowry
-
-    test entity-5.1 {entity references w/- Tcl special characters} -setup $SETUP -body {
-	$parser parse [format {<?xml version="1.0" standalone="no"?>
-<!DOCTYPE MyDoc>
-<MyDoc>
-& %s
-</MyDoc>} \{]
-	set result
-    } -cleanup $CLEANUP -result [format {
-& %s
-} \{]
-
-    test entity-5.2 {entity references w/- Tcl special characters} -setup $SETUP -body {
-	$parser parse [format {<?xml version="1.0" standalone="no"?>
-<!DOCTYPE MyDoc>
-<MyDoc>
-& %s
-</MyDoc>} \[]
-	set result
-    } -cleanup $CLEANUP -result [format {
-& %s
-} \[]
-
-    test entity-5.3 {entity references w/- Tcl special characters} -setup $SETUP -body {
-	$parser parse [format {<?xml version="1.0" standalone="no"?>
-<!DOCTYPE MyDoc>
-<MyDoc>
-& %s
-</MyDoc>} \\]
-	set result
-    } -cleanup $CLEANUP -result [format {
-& %s
-} \\]
-
-    test entity-5.4 {entity references w/- Tcl special characters} -setup $SETUP -body {
-	$parser parse [format {<?xml version="1.0" standalone="no"?>
-<!DOCTYPE MyDoc>
-<MyDoc>
-& %s%s
-</MyDoc>} \\ \{]
-	set result
-    } -cleanup $CLEANUP -result [format {
-& %s%s
-} \\ \{]
-
-    cleanupTests
-}
-
-namespace delete ::xml::entityTest
-return
diff --git a/tclxml-3.2/tests/tclxml/license.terms b/tclxml-3.2/tests/tclxml/license.terms
deleted file mode 100755
index 54ab428..0000000
--- a/tclxml-3.2/tests/tclxml/license.terms
+++ /dev/null
@@ -1,39 +0,0 @@
-This software is copyrighted by the Regents of the University of
-California, Sun Microsystems, Inc., Scriptics Corporation,
-and other parties.  The following terms apply to all files associated
-with the software unless explicitly disclaimed in individual files.
-
-The authors hereby grant permission to use, copy, modify, distribute,
-and license this software and its documentation for any purpose, provided
-that existing copyright notices are retained in all copies and that this
-notice is included verbatim in any distributions. No written agreement,
-license, or royalty fee is required for any of the authorized uses.
-Modifications to this software may be copyrighted by their authors
-and need not follow the licensing terms described here, provided that
-the new terms are clearly indicated on the first page of each file where
-they apply.
-
-IN NO EVENT SHALL THE AUTHORS OR DISTRIBUTORS BE LIABLE TO ANY PARTY
-FOR DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES
-ARISING OUT OF THE USE OF THIS SOFTWARE, ITS DOCUMENTATION, OR ANY
-DERIVATIVES THEREOF, EVEN IF THE AUTHORS HAVE BEEN ADVISED OF THE
-POSSIBILITY OF SUCH DAMAGE.
-
-THE AUTHORS AND DISTRIBUTORS SPECIFICALLY DISCLAIM ANY WARRANTIES,
-INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY,
-FITNESS FOR A PARTICULAR PURPOSE, AND NON-INFRINGEMENT.  THIS SOFTWARE
-IS PROVIDED ON AN "AS IS" BASIS, AND THE AUTHORS AND DISTRIBUTORS HAVE
-NO OBLIGATION TO PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR
-MODIFICATIONS.
-
-GOVERNMENT USE: If you are acquiring this software on behalf of the
-U.S. government, the Government shall have only "Restricted Rights"
-in the software and related documentation as defined in the Federal 
-Acquisition Regulations (FARs) in Clause 52.227.19 (c) (2).  If you
-are acquiring the software on behalf of the Department of Defense, the
-software shall be classified as "Commercial Computer Software" and the
-Government shall have only "Restricted Rights" as defined in Clause
-252.227-7013 (c) (1) of DFARs.  Notwithstanding the foregoing, the
-authors grant the U.S. Government and others acting in its behalf
-permission to use and distribute the software in accordance with the
-terms specified in this license. 
diff --git a/tclxml-3.2/tests/tclxml/namespace.test b/tclxml-3.2/tests/tclxml/namespace.test
deleted file mode 100644
index f7ff972..0000000
--- a/tclxml-3.2/tests/tclxml/namespace.test
+++ /dev/null
@@ -1,110 +0,0 @@
-# Features covered:  XML Namespaces
-#
-# This file contains a collection of tests for the TclXML parser.
-# This file tests the parser's performance on XML namespaces.
-# Sourcing this file into Tcl runs the tests and generates output
-# for errors.  No output means no errors were found.
-#
-# Copyright (c) 2008 Explain
-# http://www.explain.com.au/
-# Copyright (c) 2000-2004 Zveno Pty Ltd.
-#
-# $Id: namespace.test,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require tcltest
-source [file join [tcltest::workingDirectory] tclxmlutils.tcl]
-
-testPackage $::tcltest::parser
-
-namespace eval ::xml::namespaceTest {
-    namespace import -force ::tcltest::*
-
-    variable SETUP {
-	variable result {}
-	variable nsdecls {}
-
-	proc keysort args {
-	    array set keyvalue $args
-	    set result {}
-	    foreach key [lsort [array names keyvalue]] {
-		lappend result $key $keyvalue($key)
-	    }
-	    return $result
-	}
-
-	proc EStart {tag attlist args} {
-	    variable result
-	    variable nsdecls
-
-	    array set extra $args
-
-	    catch {eval lappend nsdecls $extra(-namespacedecls)}
-
-	    if {[info exists extra(-namespace)]} {
-		lappend result $extra(-namespace)^$tag
-	    } else {
-		lappend result $tag
-	    }
-	}
-
-	set parser [xml::parser \
-		-elementstartcommand [namespace code EStart]]
-    }
-    variable CLEANUP {
-	catch {unset result}
-	catch {unset nsdecls}
-	rename keysort {}
-	rename EStart {}
-	$parser free
-    }
-
-    test ns-1.1 {Namespace declaration} -setup $SETUP -constraints {!xml_libxml2} -body {
-	$parser parse {<?xml version="1.0"?>
-<Test xmlns:test="http://tclxml.sf.net/Schemas"></Test>
-}
-	list $result $nsdecls
-    } -cleanup $CLEANUP -result {Test {http://tclxml.sf.net/Schemas test}}
-
-    test ns-1.2 {Multiple namespace declarations} -setup $SETUP -constraints {!xml_libxml2} -body {
-	$parser parse {<?xml version="1.0"?>
-<Test xmlns:test="http://tclxml.sf.net/Schemas"
-xmlns:x='urn:schema'></Test>
-}
-	list $result [eval keysort $nsdecls]
-    } -cleanup $CLEANUP -result {Test {http://tclxml.sf.net/Schemas test urn:schema x}}
-
-    test ns-1.3 {Default namespace declaration} -setup $SETUP -constraints {!xml_libxml2} -body {
-	$parser parse {<?xml version="1.0"?>
-<Test xmlns="http://tclxml.sf.net/Schemas"
-xmlns:x='urn:schema'></Test>
-}
-	list $result [eval keysort $nsdecls]
-    } -cleanup $CLEANUP -result {http://tclxml.sf.net/Schemas^Test {http://tclxml.sf.net/Schemas {} urn:schema x}}
-
-    test ns-1.4 {Default namespace declaration w/- separate usage} -setup $SETUP -constraints {!xml_libxml2} -body {
-	$parser parse {<?xml version="1.0"?>
-<x:Test xmlns="http://tclxml.sf.net/Schemas"
-xmlns:x='urn:schema'><Test/></x:Test>
-}
-	list $result [eval keysort $nsdecls]
-    } -cleanup $CLEANUP -result {{urn:schema^Test http://tclxml.sf.net/Schemas^Test} {http://tclxml.sf.net/Schemas {} urn:schema x}}
-
-    test ns-2.0 {Multiple namespace declarations, same prefix} -setup $SETUP -constraints {!xml_libxml2} -body {
-	$parser parse {<?xml version="1.0"?>
-<Test>
-  <x:Test xmlns:x="http://tclxml.sf.net/Schemas">
-    <x:y/>
-  </x:Test>
-  <x:Test xmlns:x='urn:schema'>
-    <x:z/>
-  </x:Test>
-</Test>
-}
-	list $result [eval keysort $nsdecls]
-    } -cleanup $CLEANUP -result {{Test http://tclxml.sf.net/Schemas^Test http://tclxml.sf.net/Schemas^y urn:schema^Test urn:schema^z} {http://tclxml.sf.net/Schemas x urn:schema x}}
-
-    cleanupTests
-}
-
-namespace delete ::xml::namespaceTest
-return
diff --git a/tclxml-3.2/tests/tclxml/parser.test b/tclxml-3.2/tests/tclxml/parser.test
deleted file mode 100755
index 3e0b7e4..0000000
--- a/tclxml-3.2/tests/tclxml/parser.test
+++ /dev/null
@@ -1,305 +0,0 @@
-# Features covered:  Parser functions
-#
-# This file contains a collection of tests for the TclXML parser.
-# This file tests the parser's basic functions.
-# Sourcing this file into Tcl runs the tests and generates output
-# for errors.  No output means no errors were found.
-#
-# Copyright (c) 1999-2004 Zveno Pty Ltd.
-#
-# $Id: parser.test,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require tcltest
-source [file join [tcltest::workingDirectory] tclxmlutils.tcl]
-
-testPackage $::tcltest::parser
-
-namespace eval ::xml::parserTest {
-    namespace import -force ::tcltest::*
-
-    variable SETUP {
-	variable started
-	array set started {}
-	variable ended
-	array set ended {}
-	variable elList {}
-	variable data {}
-
-	proc parray arrayName {
-	    upvar #0 $arrayName arr
-	    foreach key [lsort [array names $arrayName]] {
-		lappend result $key $arr($key)
-	    }
-	    return $result
-	}
-
-	proc Start {name atList args} {
-	    variable started
-	    array set opts $args
-	    array set atts $atList
-
-	    if {![info exists started($name)]} {
-		set started($name) 1
-	    } else {
-		incr started($name)
-	    }
-
-	    if {[info exists atts(class)]} {
-		switch $atts(class) {
-		    continue {
-			return -code continue
-		    }
-		    break {
-			return -code break
-		    }
-		    error {
-			return -code error "error condition in callback"
-		    }
-		    default {
-			return -code $atts(class) -errorcode $atts(class)
-		    }
-		}
-	    }
-	}
-
-	proc End {name args} {
-	    variable ended
-	    array set opts $args
-
-	    if {![info exists ended($name)]} {
-		set ended($name) 1
-	    } else {
-		incr ended($name)
-	    }
-	}
-	proc PI {name args} {
-	    return -code $name
-	}
-
-	proc ElStart {name atList args} {
-	    variable elList
-	    array set opts {-empty 0}
-	    array set opts $args
-	    lappend elList start $name $opts(-empty)
-	}
-	proc ElEnd {name args} {
-	    variable elList
-	    array set opts {-empty 0}
-	    array set opts $args
-	    lappend elList end $name $opts(-empty)
-	}
-	proc pcdata text {
-	    variable data
-	    append data $text
-	}
-    }
-    variable SETUP2 {
-	eval $SETUP
-	set p [::xml::parser -elementstartcommand [namespace code Start]]
-    }
-    variable CLEANUP {
-	catch {unset started}
-	catch {unset ended}
-	catch {unset elList}
-	catch {unset data}
-	rename parray {}
-	rename Start {}
-	rename End {}
-	rename PI {}
-	rename ElStart {}
-	rename ElEnd {}
-	rename pcdata {}
-	catch {$p free}
-    }
-
-    test parser-1.1 {parser creation} -setup $SETUP -body {
-	set p [::xml::parser]
-	list [regexp {^xmlparser[0-9]+$} $p] \
-		[string equal [info commands $p] $p]
-    } -cleanup $CLEANUP -result {1 1}
-
-    test parser-1.2 {parser creation, only options} -setup $SETUP -body {
-	set p [::xml::parser -elementstartcommand EStart]
-	list [regexp {^xmlparser[0-9]+$} $p] \
-		[string equal [info commands $p] $p]
-    } -cleanup $CLEANUP -result {1 1}
-
-    test parser-1.3 {parser creation, named} -body {
-	set result [::xml::parser testparser]
-	list $result [info commands testparser]
-    } -cleanup {
-	rename testparser {}
-    } -result {testparser testparser}
-
-    test parser-1.4 {parser creation, named with options} -body {
-	set result [::xml::parser testparser -elementstartcommand EStart]
-	list $result [info commands testparser]
-    } -cleanup {
-	rename testparser {}
-    } -result {testparser testparser}
-
-    test parser-1.5 {configure -baseuri} -body {
-	set parser [::xml::parser -baseuri file:///tmp/parser-1.5.test]
-	ok
-    } -cleanup {
-	$parser free
-    } -result {}
-
-    # Test break return code from callback
-
-    test parser-2.1 {break in callback} -setup $SETUP2 -body {
-	$p parse {<?xml version="1.0"?>
-<Test>
-<Element id="el1">Should see this data</Element>
-<Element class="break" id="el2">Should not see this data<Element id="el3"/></Element>
-<Element id='el4'>Should not see this data</Element>
-</Test>
-}
-	set started(Element)
-    } -cleanup $CLEANUP -result 2
-
-    test parser-2.2 {break in callback} -setup $SETUP2 -body {
-	$p parse {<?xml version="1.0"?>
-<Test>
-<Element>Should see this data</Element>
-<Element>Should see this data<Element class="break"/></Element>
-<Element>Should not see this data</Element>
-</Test>
-}
-	set started(Element)
-    } -cleanup $CLEANUP -result 3
-
-    test parser-2.3 {break in callback} -setup $SETUP2 -body {
-	$p parse {<?xml version="1.0"?>
-<Test>
-<Element>Should see this data</Element>
-<Element>Should see this data
-  <?break?>
-</Element>
-<Element>Should not see this data</Element>
-</Test>
-}
-	set started(Element)
-    } -cleanup $CLEANUP -result 3
-
-    test parser-3.1 {continue in callback} -setup $SETUP2 -body {
-	$p parse {<?xml version="1.0"?>
-<Test>
-<Element id='el1'>Should see this data</Element>
-<Element class="continue" id='el2'>Should not see this data
-  <Element id='el3'/>
-</Element>
-<Element id='el4'>Should see this data</Element>
-</Test>
-}
-	set started(Element)
-    } -cleanup $CLEANUP -result 3
-
-    test parser-3.2 {continue in callback} -setup $SETUP2 -body {
-	$p parse {<?xml version="1.0"?>
-<Test>
-<Element>Should see this data</Element>
-<Element>Should see this data
-  <Element class="continue">
-    Should not see this data
-    <Element/>
-  </Element>
-  Should see this data
-  <Element/>
-</Element>
-<Element>Should see this data</Element>
-</Test>
-}
-	set started(Element)
-    } -cleanup $CLEANUP -result 5
-
-    test parser-3.3 {continue in callback} -setup $SETUP2 -body {
-	$p parse {<?xml version="1.0"?>
-<Test>
-<Element>Should see this data</Element>
-<Element>Should see this data
-  <Element class="continue">
-    Should not see this data
-    <Element class="break"/>
-    break will have no effect
-  </Element>
-  Should see this data
-  <Element/>
-</Element>
-<Element>Should see this data</Element>
-</Test>
-}
-	set started(Element)
-    } -cleanup $CLEANUP -result 5
-
-    test parser-4.1 {error in callback} -setup $SETUP2 -body {
-	set result [catch {
-	    $p parse {<?xml version="1.0"?>
-<Test>
-<Element>Should see this data</Element>
-<Element class="error"/>
-<Element>Should not see this data</Element>
-</Test>
-}
-	}]
-	list $result $started(Element)
-    } -cleanup $CLEANUP -result {1 2}
-
-    # catch doesn't seem to return the actual error code
-    test parser-4.2 {error in callback} -setup $SETUP2 -body {
-	set errcode [catch {$p parse {<?xml version="1.0"?>
-<Test>
-<Element>Should see this data</Element>
-<Element class="13"/>
-<Element>Should not see this data</Element>
-</Test>
-}} result]
-	list $errcode $started(Element)
-    } -cleanup $CLEANUP -result {1 2}
-
-    test parser-5.0 {free parser} -body {
-	set p [::xml::parser]
-	$p free
-	info commands $p
-    } -result {}
-
-    # Test for bug #510418
-    test parser-5.1 {free in namespace} -body {
-	namespace eval ::xml::parserTest::test51 {
-	    set p [::xml::parser -elementstartcommand Foo]
-	    $p free
-	}
-    } -cleanup {
-	namespace delete ::xml::parserTest::test51
-    } -result {}
-
-    # Test for bug #510419
-    test parser-6.1 {reset parser instance} -setup $SETUP2 -body {
-	$p reset
-	$p parse {<Test/>}
-	set first $started(Test)
-
-	catch {unset started}
-	array set started {}
-	$p reset
-	$p parse {<Test><Test/></Test>}
-
-	list $first $started(Test)
-    } -cleanup $CLEANUP -result [list 1 2]
-
-    # Test for bug #579264
-    # libxml2 doesn't recognise ignorable whitespace unless validating
-    test parser-7.1 {-ignorewhitespace option} -setup $SETUP -constraints {!xml_libxml2} -body {
-	set p [::xml::parser -characterdatacommand [namespace code pcdata] -ignorewhitespace 1]
-	$p parse {<Test>
-  <Value/>
-</Test>
-}
-	string length $data
-    } -cleanup $CLEANUP -result 0
-
-    cleanupTests
-}
-
-namespace delete ::xml::parserTest
-return
diff --git a/tclxml-3.2/tests/tclxml/pcdata.test b/tclxml-3.2/tests/tclxml/pcdata.test
deleted file mode 100755
index bad563a..0000000
--- a/tclxml-3.2/tests/tclxml/pcdata.test
+++ /dev/null
@@ -1,126 +0,0 @@
-# Features covered:  PCDATA
-#
-# This file contains a collection of tests for the TclXML parser.
-# This file tests the parser's performance on PCDATA.
-# Sourcing this file into Tcl runs the tests and generates output
-# for errors.  No output means no errors were found.
-#
-# Copyright (c) 2005 Explain
-# http://www.explain.com.au/
-# Copyright (c) 1998-2004 Zveno Pty Ltd.
-#
-# $Id: pcdata.test,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require tcltest
-source [file join [tcltest::workingDirectory] tclxmlutils.tcl]
-
-testPackage $::tcltest::parser
-
-namespace eval ::xml::pcdataTest {
-    namespace import -force ::tcltest::*
-
-    variable SETUP {
-	variable result {}
-	variable pcdataCounter 0
-	variable element 0
-
-	proc pcdata data {
-	    variable result
-	    variable pcdataCounter
-
-	    append result $data
-	    incr pcdataCounter
-	}
-	proc EStart {tagName attrList args} {
-	    variable element
-	    switch -- $tagName {
-		Test {
-		}
-		default {
-		    incr element
-		}
-	    }
-	}
-	proc EStop {tagname args} {}
-
-	set parser [xml::parser \
-		-elementstartcommand [namespace code EStart] \
-		-elementendcommand [namespace code EStop] \
-		-characterdatacommand [namespace code pcdata]]
-    }
-    variable CLEANUP {
-	catch {unset result}
-	catch {unset pcdataCounter}
-	catch {unset element}
-	rename pcdata {}
-	rename EStart {}
-	rename EStop {}
-	$parser free
-    }
-
-    test pcdata-1.1 {Simple PCDATA} -setup $SETUP -body {
-	$parser parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test>This is PCDATA</Test>
-}
-	list $result $element
-    } -cleanup $CLEANUP -result {{This is PCDATA} 0}
-
-    test pcdata-1.2 {PCDATA section with Tcl specials} -setup $SETUP -body {
-	$parser parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test>Dollar $ backslash \ square brackets [ ] braces { }</Test>
-}
-	list $result $element
-    } -cleanup $CLEANUP -result {{Dollar $ backslash \ square brackets [ ] braces { }} 0}
-
-    # Requested by Marshall Rose, 20/3/1999
-    test pcdata-1.3 {PCDATA with no entity expansion} -setup $SETUP -match regexp -body {
-	$parser configure \
-		-defaultexpandinternalentities 0
-	$parser parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test>This is <PCDATA></Test>
-}
-	list $result $pcdataCounter
-    } -cleanup $CLEANUP -result {{This is (<|<)PCDATA(>|>)} 1}
-
-    # Test case from bug #468029 contributed by kenstir at users.sourceforge.net
-
-    test pcdata-1.4 {PCDATA with Tcl special character} -setup $SETUP -body {
-	$parser parse {<d>UPPER('new')$UPPER(TKT_STATE)</d>}
-	set result
-    } -cleanup $CLEANUP -result {UPPER('new')$UPPER(TKT_STATE)}
-
-    # Test case from bug #515972 contributed by kenstir at users.sourceforge.net
-    # Similar to #468029
-
-    test pcdata-1.5 {PCDATA with Tcl special character} -setup $SETUP -body {
-	$parser parse {<t>Welcome $to [\{]asd &asd f at af!a.htm</t>}
-	set result
-    } -cleanup $CLEANUP -result {Welcome $to [\{]asd &asd f at af!a.htm}
-
-    # Test case from bug #1040550 contributed by imamit at users.sf.net
-
-    test pcdata-1.6 {PCDATA with backslash characters} -setup $SETUP -body {
-	$parser parse [format {<t>%s%s( -type f -o -type d%s%s)</t>} \\ \\ \\ \\]
-	set result
-    } -cleanup $CLEANUP -result [format {%s%s( -type f -o -type d%s%s)} \\ \\ \\ \\]
-
-    test pcdata-2.1 {Bad PCDATA: illegal Unicode character} -setup $SETUP -match glob -body {
-	expectError {
-	    $parser parse [format {<t>Bad %s character</t>} \x04]
-	}
-    } -cleanup $CLEANUP -result *
-
-    test pcdata-2.2 {Bad PCDATA: entity resolves to illegal Unicode character} -setup $SETUP -match glob -body {
-	expectError {
-	    $parser parse {<t>Bad &#x4; character</t>}
-	}
-    } -cleanup $CLEANUP -result *
-
-    cleanupTests
-}
-
-namespace delete ::xml::pcdataTest
-return
diff --git a/tclxml-3.2/tests/tclxml/pi.test b/tclxml-3.2/tests/tclxml/pi.test
deleted file mode 100755
index 152bdac..0000000
--- a/tclxml-3.2/tests/tclxml/pi.test
+++ /dev/null
@@ -1,87 +0,0 @@
-# Features covered:  Processing Instructions
-#
-# This file contains a collection of tests for the TclXML parser.
-# This file tests the parser's performance on Processing Instructions.
-# Sourcing this file into Tcl runs the tests and generates output
-# for errors.  No output means no errors were found.
-#
-# Copyright (c) 1998-2004 Zveno Pty Ltd.
-#
-# $Id: pi.test,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require tcltest
-source [file join [tcltest::workingDirectory] tclxmlutils.tcl]
-
-testPackage $::tcltest::parser
-
-namespace eval ::xml::piTest {
-    namespace import -force ::tcltest::*
-
-    variable SETUP {
-	variable result {}
-
-	proc PI {target data args} {
-	    variable result
-	    lappend result $target $data
-	}
-
-	set parser [xml::parser \
-		-processinginstructioncommand [namespace code PI]]
-    }
-    variable CLEANUP {
-	catch {unset result}
-	$parser free
-    }
-
-    test pi-1.1 {PI} -setup $SETUP -body {
-	$parser parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test><?Test This is a processing instruction?></Test>
-}
-	set result
-    } -cleanup $CLEANUP -result {Test {This is a processing instruction}}
-
-    test pi-1.2 {PI: missing trailing ?} -setup $SETUP -match regexp -body {
-	expectError {
-	    $parser parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test><?Test This is a syntax error></Test>
-}
-	}
-    } -cleanup $CLEANUP -result {(PI: expected '\?' character)|(error:.*PI Test never end)|(.*processing-instruction-not-finished.*)}
-
-    # Test Tcl special characters in PI data.
-    # NB. Tets had to modified since the PI target must be
-    # an XML Name (reported by rolf at pointsman.de)
-
-    test pi-2.1 {PI with special characters} -setup $SETUP -body {
-	$parser parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test><?if [!VMLRender]?></Test>
-}
-	set result
-    } -cleanup $CLEANUP -result {if {[!VMLRender]}}
-
-    test pi-2.2 {PI target with special characters} -setup $SETUP -match regexp -body {
-	expectError {
-	    $parser parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test><?[if !VMLRender]?></Test>
-}
-	}
-    } -cleanup $CLEANUP -result {(illegal character.*in processing instruction target)|(no target name)}
-
-    test pi-2.3 {PI target with "xml"} -setup $SETUP -constraints {!xml_libxml2} -match glob -body {
-	expectError {
-	    $parser parse {<?xml version="1.0"?>
-<!DOCTYPE Test>
-<Test><?abxMLcl illegal?></Test>
-}
-	}
-    } -cleanup $CLEANUP -result {*characters "xml" not permitted*}
-
-    cleanupTests
-}
-
-namespace delete ::xml::piTest
-return
diff --git a/tclxml-3.2/tests/tclxml/tclxmlutils.tcl b/tclxml-3.2/tests/tclxml/tclxmlutils.tcl
deleted file mode 100644
index aabeac0..0000000
--- a/tclxml-3.2/tests/tclxml/tclxmlutils.tcl
+++ /dev/null
@@ -1,38 +0,0 @@
-# tclxmlutils.tcl --
-#
-# This script prepares the testing environment for TclXML.
-#
-# Copyright (c) 2008 Explain
-# http://www.explain.com.au/
-# Copyright (c) 2003 Zveno Pty Ltd.
-#
-# $Id: tclxmlutils.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require tcltest
-tcltest::Option -parser xml {
-    Selects the XML parser class.
-} AcceptAll parser
-
-source [file join [tcltest::workingDirectory] .. testutils.tcl]
-
-eval tcltest::configure $argv
-
-switch -- $tcltest::parser {
-    xml {
-	package require xml
-	switch [xml::parserclass info default] {
-	    libxml2 {
-		tcltest::testConstraint xml_libxml2 1
-	    }
-	    tcl {
-		tcltest::testConstraint xml_tcl 1
-	    }
-	}
-    }
-    libxml2 {
-	tcltest::testConstraint xml_libxml2 1
-    }
-    tclparser {
-	tcltest::testConstraint xml_tcl 1
-    }
-}
diff --git a/tclxml-3.2/tests/tclxml/xmldecl.test b/tclxml-3.2/tests/tclxml/xmldecl.test
deleted file mode 100644
index 9855c46..0000000
--- a/tclxml-3.2/tests/tclxml/xmldecl.test
+++ /dev/null
@@ -1,96 +0,0 @@
-# Features covered:  XML Declaration
-#
-# This file contains a collection of tests for the TclXML parser.
-# This file tests the parser's performance on XML Declarations.
-# Sourcing this file into Tcl runs the tests and generates output
-# for errors.  No output means no errors were found.
-#
-# Copyright (c) 2001-2003 Zveno Pty Ltd.
-#
-# $Id: xmldecl.test,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require tcltest
-source [file join [tcltest::workingDirectory] tclxmlutils.tcl]
-
-testPackage $::tcltest::parser
-
-namespace eval ::xml::xmldeclTest {
-    namespace import -force ::tcltest::*
-
-    variable SETUP {
-	variable result {}
-
-	proc xmldecl {version encoding standalone} {
-	    variable result
-	    lappend result $version $encoding $standalone
-	}
-
-	set parser [xml::parser \
-		-xmldeclcommand [namespace code xmldecl]]
-    }
-    variable CLEANUP {
-	catch {unset result}
-	rename xmldecl {}
-	$parser free
-    }
-
-    test xmldecl-1.1 {No XML Declaration} -setup $SETUP -body {
-	$parser parse {<Test/>}
-	set result
-    } -cleanup $CLEANUP -result {}
-
-    test xmldecl-1.2 {Simple XML Declaration} -setup $SETUP -constraints {!xml_libxml2} -body {
-	$parser parse {<?xml version='1.0'?>
-<Test/>
-}
-
-	set result
-    } -cleanup $CLEANUP -result [list 1.0 {} {}]
-
-    test xmldecl-1.3 {XML Declaration w/- encoding} -setup $SETUP -constraints {!xml_libxml2} -body {
-	$parser parse {<?xml version="1.0" encoding='utf-8'?>
-<Test/>
-}
-
-	set result
-    } -cleanup $CLEANUP -result [list 1.0 utf-8 {}]
-
-    test xmldecl-1.4 {XML Declaration w/- standalone} -setup $SETUP -constraints {!xml_libxml2} -body {
-	$parser parse {<?xml version="1.0" standalone='yes'?>
-<Test/>
-}
-
-	set result
-    } -cleanup $CLEANUP -result [list 1.0 {} yes]
-
-    test xmldecl-1.5 {XML Declaration w/- the lot} -setup $SETUP -constraints {!xml_libxml2} -body {
-	$parser parse {<?xml version='1.0' encoding="utf-8" standalone='yes'?>
-<Test/>
-}
-
-	set result
-    } -cleanup $CLEANUP -result [list 1.0 utf-8 yes]
-
-    # Test case from bug #434304 submitted by Cameron Laird
-
-    test xmldecl-2.1 {XML Declaration w/- whitespace} -setup $SETUP -constraints {!xml_libxml2} -body {
-	$parser parse {<?xml version = '1.0'?>
-<Test/>
-}
-
-	set result
-    } -cleanup $CLEANUP -result [list 1.0 {} {}]
-
-    test xmldecl-3.1 {XML Declaration w/- error} -setup $SETUP -match glob -body {
-	expectError {
-	    $parser parse {<?xml version = "1.0" foobar standalone='no'?>
-<Test/>
-}
-	}
-    } -cleanup $CLEANUP -result *
-
-    cleanupTests
-}
-
-namespace delete ::xml::xmldeclTest
-return
diff --git a/tclxml-3.2/tests/tclxml/xmltest.test b/tclxml-3.2/tests/tclxml/xmltest.test
deleted file mode 100755
index 1b0974f..0000000
--- a/tclxml-3.2/tests/tclxml/xmltest.test
+++ /dev/null
@@ -1,126 +0,0 @@
-# Features covered:  Conformance
-#
-# This file contains a collection of tests for the TclXML parser.
-# This file tests the parser's performance against the W3C/OASIS/NIST
-# XML Conformance Test Suite.
-#
-# NB. These tests only check acceptance/rejection of whole XML documents.
-# As such it is crude and does not test callback features.
-#
-# Sourcing this file into Tcl runs the tests and generates output
-# for errors.  No output means no errors were found.
-#
-# Copyright (c) 1999-2003 Zveno Pty Ltd.
-#
-# $Id: xmltest.test,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require tcltest
-source [file join [tcltest::workingDirectory] tclxmlutils.tcl]
-
-testPackage $::tcltest::parser
-
-namespace eval ::xml::xmltestTest {
-    namespace import -force ::tcltest::*
-
-    set testDir [file join [workingDirectory] XML-Test-Suite]
-    testConstraint xmltests [file exists $testDir]
-
-    variable SETUP {
-	proc ConfEStart {type attlist args} {
-	    variable base attrs pcdata
-
-	    catch {unset attrs}
-	    array set attr $attlist
-
-	    set pcdata {}
-
-	    switch -- $type {
-		TESTSUITE {
-		    puts $attr(PROFILE)
-		}
-		TESTCASES {
-		    puts $attr(PROFILE)
-		    lappend base $attr(xml:base)
-		}
-		TEST {
-		}
-	    }
-	}
-
-	proc ConfEEnd {name args} {
-	    variable base attrs pcdata
-
-	    switch -- $name {
-		TESTCASES {
-		    set base [lreplace $base end end]
-		}
-		TEST {
-
-		    switch -- $attr(TYPE) {
-			error -
-			not-wf {
-			    set expect error
-			}
-			default {
-			    # Skip validity tests - not yet supported
-			    return
-			}
-		    }
-
-		    set f [file join $base $attr(URI)]
-
-		    set ch [open $f]
-		    set data [read $ch]
-		    close $ch
-
-		    regsub -all [format {[ %s%s%s]+} \t \n \r] [string trim $pcdata] { } pcdata
-
-		    test xmltest-[lindex $base end]-$attr(ID) $pcdata -body {
-			set parser [xml::parser $attr(ID)]
-			if {[catch {$parser parse $data}]} {
-			    # Need to distinguish between not-wf, error and invalid
-			    set code error
-			} else {
-			    set code valid
-			}
-			$parser free
-			set $code
-		    } $expect
-		}
-	    }
-	}
-
-	proc ConfCDATA text {
-	    variable pcdata
-	    append pcdata $text
-	}
-    }
-
-    # Need a framework to test against each file: it's too time-
-    # consuming to setup a test proc for each one.
-
-    if {[testConstraint xmltests]} {
-	if {[catch {open [file join $testDir xmlconf xmlconf.xml]} ch]} {
-	    puts stderr "unable to open XML Test Suite configuration file: skipping tests"
-	    return
-	} else {
-
-	    set confXML [read $ch]
-	    close $ch
-
-	    set base [file join [pwd] XML-Test-Suite xmlconf]
-
-	    set confParser [::xml::parser \
-		-elementstartcommand [namespace code ConfEStart] \
-		-elementendcommand [namespace code ConfEEnd] \
-		-characterdatacommand [namespace code ConfPCDATA] \
-		-validate 1]
-	    $confParser parse $confXML
-	}
-    }
-
-    cleanupTests
-}
-
-namespace delete ::xml::xmltestTest
-return
diff --git a/tclxml-3.2/tests/tclxml/xpath.test b/tclxml-3.2/tests/tclxml/xpath.test
deleted file mode 100644
index 05223c9..0000000
--- a/tclxml-3.2/tests/tclxml/xpath.test
+++ /dev/null
@@ -1,124 +0,0 @@
-# Features covered:  XPath
-#
-# This file contains a collection of tests for the XPath parser.
-# Sourcing this file into Tcl runs the tests and generates output
-# for errors.  No output means no errors were found.
-#
-# Copyright (c) 1998-2003 Zveno Pty Ltd.
-#
-# $Id: xpath.test,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require tcltest
-source [file join [tcltest::workingDirectory] tclxmlutils.tcl]
-
-testPackage xpath
-
-namespace eval ::xml::xpathTest {
-    namespace import -force ::tcltest::*
-
-    # Full syntax tests
-
-    test xpath-1.1 {Location path} -body {
-	xpath::split child::para
-    } -result {{child para {}}}
-    test xpath-1.2 {Location path} -body {
-	xpath::split child::*
-    } -result {{child * {}}}
-    test xpath-1.3 {Location path} -body {
-	xpath::split child::text()
-    } -result {{child {text ()} {}}}
-    test xpath-1.4 {Location path} -body {
-	xpath::split child::node()
-    } -result {{child {node ()} {}}}
-    test xpath-1.5 {Location path} -body {
-	xpath::split attribute::name
-    } -result {{attribute name {}}}
-    test xpath-1.6 {Location path} -body {
-	xpath::split attribute::*
-    } -result {{attribute * {}}}
-    test xpath-1.7 {Location path} -body {
-	xpath::split descendant::para
-    } -result {{descendant para {}}}
-    test xpath-1.8 {Location path} -body {
-	xpath::split ancestor::div
-    } -result {{ancestor div {}}}
-    test xpath-1.9 {Location path} -body {
-	xpath::split ancestor-or-self::div
-    } -result {{ancestor-or-self div {}}}
-    test xpath-1.10 {Location path} -body {
-	xpath::split descendant-or-self::para
-    } -result {{descendant-or-self para {}}}
-    test xpath-1.11 {Location path} -body {
-	xpath::split self::para
-    } -result {{self para {}}}
-    test xpath-1.12 {Location path} -body {
-	xpath::split child::chapter/descendant::para
-    } -result {{child chapter {}} {descendant para {}}}
-    test xpath-1.13 {Location path} -body {
-	xpath::split child::*/child::para
-    } -result {{child * {}} {child para {}}}
-    test xpath-1.14 {Location path} -body {
-	xpath::split /
-    } -result {{}}
-    test xpath-1.15 {Location path} -body {
-	xpath::split /descendant::para
-    } -result {{} {descendant para {}}}
-    test xpath-1.16 {Location path} -body {
-	xpath::split /descendant::olist/child::item
-    } -result {{} {descendant olist {}} {child item {}}}
-    test xpath-1.17 {Location path} -body {
-	xpath::split {child::para[position()=1]}
-    } -result {{child para {{= {function position {}} {number 1}}}}}
-    test xpath-1.18 {Location path} -body {
-	xpath::split {child::para[position()=last()]}
-    } -result {{child para {{= {function position {}} {function last {}}}}}}
-    test xpath-1.19 {Location path} -body {
-	xpath::split {child::para[position()=last()-1]}
-    } -result {{child para {{expr - = {function position {}} {function last {}} {number 1}}}}}
-    test xpath-1.20 {Location path} -body {
-	xpath::split {child::para[position()=last()>1]}
-    } -result {{child para {{> = {function position {}} {function last {}} {number 1}}}}}
-    test xpath-1.21 {Location path} -body {
-	xpath::split {following-sibling::chapter[position()=1]}
-    } -result {{following-sibling chapter {{= {function position {}} {number 1}}}}}
-    test xpath-1.22 {Location path} -body {
-	xpath::split {/child::doc/child::chapter[position()=5]/child::section[position()=2]}
-    } -result {{} {child doc {}} {child chapter {{= {function position {}} {number 5}}}} {child section {{= {function position {}} {number 2}}}}}
-    test xpath-1.23 {Location path} -body {
-	xpath::split {child::para[attribute::type="warning"]}
-    } -result {{child para {{= {path {{attribute type {}}}} {literal warning}}}}}
-    test xpath-1.24 {Location path} -body {
-	xpath::split {child::para[attribute::type='warning'][position()=5]}
-    } -result {{child para {{= {path {{attribute type {}}}} {literal warning}} {= {function position {}} {number 5}}}}}
-    test xpath-1.25 {Location path} -body {
-	xpath::split {child::chapter[child::title='Introduction']}
-    } -result {{child chapter {{= {path {{child title {}}}} {literal Introduction}}}}}
-    test xpath-1.26 {Location path} -body {
-	xpath::split {child::chapter[child::title]}
-    } -result {{child chapter {{{path {{child title {}}}}}}}}
-    test xpath-1.27 {Location path} -body {
-	xpath::split {child::*[self::chapter or 
-self::appendix]}
-    } -result {{child * {{or {path {{self chapter {}}}} {path {{self appendix {}}}}}}}}
-    test xpath-1.28 {Location path} -body {
-	xpath::split {child::*[self::chapter/child::appendix]}
-    } -result {{child * {{{path {{self chapter {}} {child appendix {}}}}}}}}
-
-    # Abbreviated syntax tests
-
-    test xpath-2.1 {Abbreviated location path} -body {
-	xpath::split {/article/listitem[7]/itemizedlist/text()}
-    } -result {{} {child article {}} {child listitem {{= {function position {}} {number 7}}}} {child itemizedlist {}} {child {text ()} {}}}
-    test xpath-2.2 {Location step after predicate using location path} -body {
-	xpath::split {/article/listitem[@Id='xyz']/itemizedlist/text()}
-    } -result {{} {child article {}} {child listitem {{= {path {{attribute Id {}}}} {literal xyz}}}} {child itemizedlist {}} {child {text ()} {}}}
-    # Test for bug #568354 contributed by Marshall Rose
-    test xpath-2.3 {Location step with node type test in predicate} -body {
-	xpath::split {//key[text()="foo"]}
-    } -result {{} {descendant-or-self key {{= {path {child {text ()} {}}} {literal foo}}}}}
-
-    cleanupTests
-}
-
-namespace delete ::xml::xpathTest
-return
diff --git a/tclxml-3.2/tests/tclxslt/all.tcl b/tclxml-3.2/tests/tclxslt/all.tcl
deleted file mode 100755
index fd63cc8..0000000
--- a/tclxml-3.2/tests/tclxslt/all.tcl
+++ /dev/null
@@ -1,22 +0,0 @@
-# all.tcl --
-#
-# This file contains a support module to run all of the Tcl
-# tests.  It must be invoked using "source all.test" by 
-# a calling tcl script that has loaded the parser class it wishes to
-# test in this directory.
-#
-# Copyright (c) 2008 Explain
-# http://www.explain.com.au/
-# Copyright (c) 2003 Zveno Pty Ltd
-# Copyright (c) 1998-1999 by Scriptics Corporation.
-#
-# All rights reserved.
-# 
-# RCS: @(#) $Id: all.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require Tcl 8.4
-package require tcltest 2.2
-tcltest::configure -testdir [file dirname [file normalize [info script]]]
-eval tcltest::configure $argv
-
-tcltest::runAllTests
diff --git a/tclxml-3.2/tests/tclxslt/dummy.xml b/tclxml-3.2/tests/tclxslt/dummy.xml
deleted file mode 100644
index e15c12d..0000000
--- a/tclxml-3.2/tests/tclxslt/dummy.xml
+++ /dev/null
@@ -1,19 +0,0 @@
-<html><head>
-      <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-   <title>About Zveno</title><meta name="generator" content="DocBook XSL Stylesheets V1.29"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div id="c36b1" class="article"><div class="titlepage"><div><h1 class="title"><a name="c36b1b1"></a>About Zveno</h1></div><div><h3 class="author">Ms.
-       Polly Ball</h3></div><hr></div>Awesome!<p>
-	Zveno is a dedicated XML company, providing a comprehensive suite of services 
-	including consultancy, scheduled and in-house training and customised tools. Established 
-	in 1996, Zveno services a variety of clients worldwide. 
-	</p>Awesome!<p>
-	Our mission is to utilise the wealth of both open source and commercially produced 
-	packages to customise solutions to your XML requirements. Our dedicated vendor 
-	neutral stance coupled with our notably qualified staff, gives us a unique edge within the 
-	growing wealth of XML related companies operating today.    
-	</p>Awesome!<p>
-	Zveno offices are located in Canberra, ACT, Australia, and Perth, WA, Australia.  You may contact us:
-	</p><div class="itemizedlist"><ul><li>Awesome!<p><a name="c36b1b5b1"></a>by email <a href="#">info at zveno.com</a></p></li><li>Awesome!<p><a name="c36b1b5b2"></a>by phone +61 2 6242 4099</p></li><li>Awesome!<p><a name="c36b1b5b3"></a>by fax +61 2 6242 4099</p></li><li>Awesome!<p><a name="c36b1b5b4"></a>by snail mail</p><div class="address"><br>
-LPO Box A64 ANU<br>
-CanberraACT2601<br>
-Australia<br>
-	    </div></li></ul></div></div></body></html>
\ No newline at end of file
diff --git a/tclxml-3.2/tests/tclxslt/error.xml b/tclxml-3.2/tests/tclxslt/error.xml
deleted file mode 100644
index 6e69bfd..0000000
--- a/tclxml-3.2/tests/tclxslt/error.xml
+++ /dev/null
@@ -1,47 +0,0 @@
-<article>
-	<artheader>
-		<title>About Zveno</title>
-		<author>
-			<honorific>Ms</honorific>
-			<firstname>Polly</firstname>
-          		<surname>Ball</surname>
-		</author>
-
-	<para>
-	Zveno is a dedicated XML company, providing a comprehensive suite of services 
-	including consultancy, scheduled and in-house training and customised tools. Established 
-	in 1996, Zveno services a variety of clients worldwide. 
-	</para>
-
-	<para>
-	Our mission is to utilise the wealth of both open source and commercially produced 
-	packages to customise solutions to your XML requirements. Our dedicated vendor 
-	neutral stance coupled with our notably qualified staff, gives us a unique edge within the 
-	growing wealth of XML related companies operating today.    
-	</para>
-
-	<para>
-	Zveno offices are located in Canberra, ACT, Australia, and Perth, WA, Australia.  You may contact us:
-	</para>
-
-	<itemizedlist>
-	  <listitem>
-	    <para>by email <link type="email" ID="info">info at zveno.com</link></para>
-	  </listitem>
-	  <listitem>
-	    <para>by phone +61 2 6242 4099</para>
-	  </listitem>
-	  <listitem>
-	    <para>by fax +61 2 6242 4099</para>
-	  </listitem>
-	  <listitem>
-	    <para>by snail mail</para>
-	    <address>
-LPO Box A64 ANU
-<city>Canberra</city><state>ACT</state><postcode>2601</postcode>
-<country>Australia</country>
-	    </address>
-	  </listitem>
-	</itemizedlist>
-</article>
-
diff --git a/tclxml-3.2/tests/tclxslt/error.xsl b/tclxml-3.2/tests/tclxslt/error.xsl
deleted file mode 100644
index 74fc16e..0000000
--- a/tclxml-3.2/tests/tclxslt/error.xsl
+++ /dev/null
@@ -1,11 +0,0 @@
-<xsl:stylesheet version='1.0' xmlns:xsl='http://www.w3.org/1999/XSL/Transform'>
-
-  <xsl:template match="/">
-    <xsl:text>This should be an error</xsl:text>
-    <xsl:apply-templates match="whatever"/>
-  </xsl:template>
-
-  <xsl:template/>
-
-</xsl:stylesheet>
-
diff --git a/tclxml-3.2/tests/tclxslt/ext-test.tcl b/tclxml-3.2/tests/tclxslt/ext-test.tcl
deleted file mode 100644
index c1154ed..0000000
--- a/tclxml-3.2/tests/tclxslt/ext-test.tcl
+++ /dev/null
@@ -1,25 +0,0 @@
-# ext-test.tcl --
-#
-#	Implementation of test extension
-#
-# $Id: ext-test.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require xslt
-
-namespace eval extTest {
-    namespace export test
-}
-
-proc extTest::test args {
-    return "extTest::test passed [llength $args] arguments"
-}
-
-set ch [open ext-test.xsl]
-set xsl [read $ch]
-close $ch
-
-puts [list register extension]
-::xslt::extension add http://tclxml.sf.net/XSLT/Test ::extTest
-
-puts [list do transformation]
-::xslt::transform $xsl <Test/>
diff --git a/tclxml-3.2/tests/tclxslt/ext-test.xsl b/tclxml-3.2/tests/tclxslt/ext-test.xsl
deleted file mode 100644
index 60a2577..0000000
--- a/tclxml-3.2/tests/tclxslt/ext-test.xsl
+++ /dev/null
@@ -1,14 +0,0 @@
-<xsl:stylesheet version='1.0'
-	xmlns:xsl='http://www.w3.org/1999/XSL/Transform'
-	xmlns:ext='http://tclxml.sf.net/XSLT/Test'
-	extension-element-prefixes='ext'>
-
-  <xsl:output method='text'/>
-
-  <xsl:template match='/'>
-    <xsl:text>Test value: "</xsl:text>
-    <xsl:value-of select="ext:test('argument 1', 'argument 2')"/>
-    <xsl:text>"</xsl:text>
-  </xsl:template>
-
-</xsl:stylesheet>
diff --git a/tclxml-3.2/tests/tclxslt/extension.test b/tclxml-3.2/tests/tclxslt/extension.test
deleted file mode 100755
index 2bc53ad..0000000
--- a/tclxml-3.2/tests/tclxslt/extension.test
+++ /dev/null
@@ -1,141 +0,0 @@
-# Features covered:  XSLT Extensions
-#
-# This file contains a collection of tests for the TclXSLT package.
-# This file tests the parser's performance on tranformations.
-# Sourcing this file into Tcl runs the tests and generates output
-# for errors.  No output means no errors were found.
-#
-# Copyright (c) 2008 Explain
-# http://www.explain.com.au/
-# Copyright (c) 2001-2003 Zveno Pty Ltd.
-#
-# $Id: extension.test,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require tcltest
-source [file join [tcltest::workingDirectory] tclxsltutils.tcl]
-
-testPackage xslt
-
-namespace eval ::xslt::extensionTest {
-    namespace import -force ::tcltest::*
-
-    namespace eval ::xslt::extensionTest::exttest {
-	namespace export countargs
-    }
-
-    proc ::xslt::extensionTest::exttest::countargs args {
-	return [llength $args]
-    }
-
-    proc ::xslt::extensionTest::exttest::testnodes {ns args} {
-	variable nodenames
-
-	foreach node $ns {
-	    lappend nodenames [dom::node cget $node -nodeName]
-	}
-
-	return [lindex $ns end]
-    }
-
-    variable SETUP {
-	variable nodenames {}
-
-	xslt::extension add http://tclxml.sourceforge.net/schemas/exttest ::xslt::extensionTest::exttest
-
-	set srcdoc [dom::parse {<?xml version="1.0"?>
-<Test>
-  <value1>First value</value1>
-  <value2>Second value</value2>
-  <value3>Third value</value3>
-  <value4>
-    <para>Fourth</para>
-    <para>value</para>
-  </value4>
-</Test>
-}]
-    }
-    variable CLEANUP {
-	catch {unset nodenames}
-	xslt::extension remove http://tclxml.sourceforge.net/schemas/exttest
-	dom::destroy $srcdoc
-	dom::destroy $stydoc
-	rename $ssheet {}
-    }
-
-    test extension-1.1 {Register extension namespace} -body {
-	xslt::extension add http://tclxml.sourceforge.net/schemas/exttest ::exttest
-    } -cleanup {
-	xslt::extension remove http://tclxml.sourceforge.net/schemas/exttest
-    } -result {}
-    test extension-1.2 {Unregister extension namespace} -setup {
-	xslt::extension add http://tclxml.sourceforge.net/schemas/exttest ::exttest
-    } -body {
-	xslt::extension remove http://tclxml.sourceforge.net/schemas/exttest
-    } -result {}
-
-    test extension-2.1 {Extension function} -setup {
-	eval $SETUP
-	set stydoc [dom::parse {<xsl:stylesheet version='1.0'
-    xmlns:xsl='http://www.w3.org/1999/XSL/Transform'
-    xmlns:ext='http://tclxml.sourceforge.net/schemas/exttest'
-    extension-element-prefixes='ext'>
-  <xsl:output method='text'/>
-
-  <xsl:template match='/'>
-    <xsl:variable name='value' select='ext:countargs("arg1", "arg2")'/>
-    <xsl:value-of select='$value'/>
-  </xsl:template>
-
-</xsl:stylesheet>
-}]
-	set ssheet [xslt::compile $stydoc]
-    } -body {
-	set result [$ssheet transform $srcdoc]
-	dom::serialize $result -method text
-    } -cleanup $CLEANUP -result 2
-
-    test extension-2.2 {Extension function, no args} -setup {
-	eval $SETUP
-	set stydoc [dom::parse {<xsl:stylesheet version='1.0'
-    xmlns:xsl='http://www.w3.org/1999/XSL/Transform'
-    xmlns:ext='http://tclxml.sourceforge.net/schemas/exttest'
-    extension-element-prefixes='ext'>
-  <xsl:output method='text'/>
-
-  <xsl:template match='/'>
-    <xsl:variable name='value' select='ext:countargs()'/>
-    <xsl:value-of select='$value'/>
-  </xsl:template>
-
-</xsl:stylesheet>
-}]
-	set ssheet [xslt::compile $stydoc]
-    } -body {
-	set result [$ssheet transform $srcdoc]
-	dom::serialize $result -method text
-    } -cleanup $CLEANUP -result 0
-
-    test extension-2.3 {pass nodeset to function, return nodeset} -setup {
-	eval $SETUP
-	set stydoc [dom::parse {<xsl:stylesheet version='1.0'
-    xmlns:xsl='http://www.w3.org/1999/XSL/Transform'
-    xmlns:ext='http://tclxml.sourceforge.net/schemas/exttest'
-    extension-element-prefixes='ext'>
-  <xsl:output method='text'/>
-  <xsl:template match='/Test'>
-    <xsl:value-of select='ext:testnodes(*)/preceding-sibling::*[1]'/>
-  </xsl:template>
-
-</xsl:stylesheet>
-}]
-	set ssheet [xslt::compile $stydoc]
-    } -body {
-	set result [$ssheet transform $srcdoc]
-	list [dom::serialize $result -method text] $::xslt::extensionTest::exttest::nodenames
-    } -cleanup $CLEANUP -result {{Third value} {value1 value2 value3 value4}}
-
-    cleanupTests
-}
-
-namespace delete ::xslt::extensionTest
-return
diff --git a/tclxml-3.2/tests/tclxslt/included.xsl b/tclxml-3.2/tests/tclxslt/included.xsl
deleted file mode 100644
index be0908b..0000000
--- a/tclxml-3.2/tests/tclxslt/included.xsl
+++ /dev/null
@@ -1,4 +0,0 @@
-<xsl:stylesheet version='1.0'
-  xmlns:xsl='http://www.w3.org/1999/XSL/Transform'>
-  <xsl:param name='included' select="'include me'"/>
-</xsl:stylesheet>
\ No newline at end of file
diff --git a/tclxml-3.2/tests/tclxslt/tclxsltutils.tcl b/tclxml-3.2/tests/tclxslt/tclxsltutils.tcl
deleted file mode 100644
index 8a47207..0000000
--- a/tclxml-3.2/tests/tclxslt/tclxsltutils.tcl
+++ /dev/null
@@ -1,16 +0,0 @@
-# tclxmlutils.tcl --
-#
-# This script prepares the testing environment for TclXML.
-#
-# Copyright (c) 2008 Explain
-# http://www.explain.com.au/
-# Copyright (c) 2003 Zveno Pty Ltd.
-#
-# $Id: tclxsltutils.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require tcltest
-
-source [file join [tcltest::workingDirectory] .. testutils.tcl]
-
-eval tcltest::configure $argv
-
diff --git a/tclxml-3.2/tests/tclxslt/test.xml b/tclxml-3.2/tests/tclxslt/test.xml
deleted file mode 100644
index c561d48..0000000
--- a/tclxml-3.2/tests/tclxslt/test.xml
+++ /dev/null
@@ -1,48 +0,0 @@
-<article>
-	<artheader>
-		<title>About Zveno</title>
-		<author>
-			<honorific>Ms</honorific>
-			<firstname>Polly</firstname>
-          		<surname>Ball</surname>
-		</author>
-	</artheader>
-
-	<para>
-	Zveno is a dedicated XML company, providing a comprehensive suite of services 
-	including consultancy, scheduled and in-house training and customised tools. Established 
-	in 1996, Zveno services a variety of clients worldwide. 
-	</para>
-
-	<para>
-	Our mission is to utilise the wealth of both open source and commercially produced 
-	packages to customise solutions to your XML requirements. Our dedicated vendor 
-	neutral stance coupled with our notably qualified staff, gives us a unique edge within the 
-	growing wealth of XML related companies operating today.    
-	</para>
-
-	<para>
-	Zveno offices are located in Canberra, ACT, Australia, and Perth, WA, Australia.  You may contact us:
-	</para>
-
-	<itemizedlist>
-	  <listitem>
-	    <para>by email <link type="email" ID="info">info at zveno.com</link></para>
-	  </listitem>
-	  <listitem>
-	    <para>by phone +61 2 6242 4099</para>
-	  </listitem>
-	  <listitem>
-	    <para>by fax +61 2 6242 4099</para>
-	  </listitem>
-	  <listitem>
-	    <para>by snail mail</para>
-	    <address>
-LPO Box A64 ANU
-<city>Canberra</city><state>ACT</state><postcode>2601</postcode>
-<country>Australia</country>
-	    </address>
-	  </listitem>
-	</itemizedlist>
-</article>
-
diff --git a/tclxml-3.2/tests/tclxslt/test.xsl b/tclxml-3.2/tests/tclxslt/test.xsl
deleted file mode 100644
index f48c872..0000000
--- a/tclxml-3.2/tests/tclxslt/test.xsl
+++ /dev/null
@@ -1,11 +0,0 @@
-<xsl:stylesheet version='1.0' xmlns:xsl='http://www.w3.org/1999/XSL/Transform'>
-
-  <xsl:import href='docbook/html/docbook.xsl'/>
-
-  <xsl:template match="para">
-    <xsl:text>Awesome!</xsl:text>
-    <xsl:apply-imports/>
-  </xsl:template>
-
-</xsl:stylesheet>
-
diff --git a/tclxml-3.2/tests/tclxslt/test2-1.mod b/tclxml-3.2/tests/tclxslt/test2-1.mod
deleted file mode 100644
index 3afa41a..0000000
--- a/tclxml-3.2/tests/tclxslt/test2-1.mod
+++ /dev/null
@@ -1,2 +0,0 @@
-Here is some content
-
diff --git a/tclxml-3.2/tests/tclxslt/test2.xml b/tclxml-3.2/tests/tclxslt/test2.xml
deleted file mode 100644
index 3ea4d71..0000000
--- a/tclxml-3.2/tests/tclxslt/test2.xml
+++ /dev/null
@@ -1,7 +0,0 @@
-<!DOCTYPE article [
-  <!ENTITY ext SYSTEM "test2-1.mod">
-]>
-<article>
-  &ext;
-</article>
-
diff --git a/tclxml-3.2/tests/tclxslt/testAB.xml b/tclxml-3.2/tests/tclxslt/testAB.xml
deleted file mode 100644
index c9692e3..0000000
--- a/tclxml-3.2/tests/tclxslt/testAB.xml
+++ /dev/null
@@ -1,4 +0,0 @@
-<Test>
-  <para>Main test document</para>
-</Test>
-
diff --git a/tclxml-3.2/tests/tclxslt/testutils.tcl b/tclxml-3.2/tests/tclxslt/testutils.tcl
deleted file mode 100644
index ed152f7..0000000
--- a/tclxml-3.2/tests/tclxslt/testutils.tcl
+++ /dev/null
@@ -1,181 +0,0 @@
-#
-# testutils.tcl --
-#
-# 	Auxilliary utilities for use with the tcltest package.
-# 	Author: Joe English <jenglish at flightlab.com>
-# 	Version: 1.1
-#
-# This file is hereby placed in the public domain.
-#
-
-variable tracing 0		;# Set to '1' to enable the 'trace' command
-variable tracingErrors 0	;# If set, 'expectError' prints error messages
-
-# ok --
-#	Returns an empty string.
-#	May be used as the last statement in test scripts 
-#	that are only evaluated for side-effects or in cases
-#	where you just want to make sure that an operation succeeds
-#
-proc ok {} { return {} }
-
-# result result --
-#	Just returns $result
-#
-proc result {result} { return $result }
-
-# tracemsg msg --
-#	Prints tracing message if $::tracing is nonzero.
-#
-proc tracemsg {string} {
-    if {$::tracing} {
-	puts $::tcltest::outputChannel $string
-    }
-}
-
-# assert expr ?msg? --
-#	Evaluates 'expr' and signals an error
-#	if the condition is not true.
-#
-proc assert {expr {message ""}} {
-    if {![uplevel 1 [list expr $expr]]} {
-	return -code error "Assertion {$expr} failed:\n$message"
-    }
-}
-
-# expectError script  ? pattern ? --
-#	Evaluate 'script', which is expected to fail
-#	with an error message matching 'pattern'.
-#
-#	Returns the error message if the script 'correctly' fails,
-#	raises an error otherwise
-
-proc expectError {script {pattern "*"}} {
-    set rc [catch [list uplevel 1 $script] result]
-    if {$::tracingErrors} {
-	puts stderr "==> [string replace $result 70 end ...]"
-    }
-    set rmsg [string replace $result 40 end ...]
-    if {$rc != 1} {
-	return -code error \
-	    "Expected error, got '$rmsg' (rc=$rc)"
-    }
-    return $result
-}
-
-# comparenodes
-#	Compares two nodes, taking implementations into account
-
-proc comparenodes {node1 node2} {
-    if {[::tcltest::testConstraint dom_libxml2] || [::tcltest::testConstraint dom_tcl]} {
-	::dom::node isSameNode $node1 $node2
-    } else {
-	return [expr ![string compare $node1 $node2]]
-    }
-}
-
-# nodelist list1 list2
-#	Compares two lists of DOM nodes, in an ordered fashion.
-#	NB. the node identities are compared, not their tokens.
-
-proc nodelist {list1 list2} {
-    if {[llength $list1] != [llength $list2]} {
-	return 0
-    }
-    foreach node1 $list1 node2 $list2 {
-	if {![comparenodes $node1 $node2]} {
-	    return 0
-	}
-    }
-    return 1
-}
-
-# nodeset set1 set2
-#	Compares two sets of DOM nodes, in an unordered fashion.
-#	NB. the node identities are compared, not their tokens.
-
-proc nodeset {set1 set2} {
-    if {[llength $set1] != [llength $set2]} {
-	return 0
-    }
-    foreach node1 [lsort $set1] node2 [lsort $set2] {
-	if {![comparenodes $node1 $node2]} {
-	    return 0
-	}
-    }
-    return 1
-}
-
-# checkTree doc list
-#	Tests that a DOM tree has a structure specified as a Tcl list
-
-proc checkTree {node spec} {
-    foreach child [dom::node children $node] specchild $spec {
-	switch [lindex $specchild 0] {
-	    element {
-		if {[dom::node cget $child -nodeType] != "element"} {
-		    return 0
-		}
-		if {[dom::node cget $child -nodeName] != [lindex $specchild 1]} {
-		    return 0
-		}
-		foreach {name value} [lindex $specchild 2] {
-		    if {[dom::element getAttribute $child $name] != $value} {
-			return 0
-		    }
-		}
-		set result [checkTree $child [lindex $specchild 3]]
-		if {!$result} {
-		    return 0
-		}
-	    }
-	    pi {
-		if {[dom::node cget $child -nodeType] != "processingInstruction"} {
-		    return 0
-		}
-		if {[dom::node cget $child -nodeName] != [lindex $specchild 1]} {
-		    return 0
-		}
-	    }
-	    dtd {
-		if {[dom::node cget $child -nodeType] != "dtd"} {
-		    return 0
-		}
-	    }
-	    text {
-		if {[dom::node cget $child -nodeType] != "textNode"} {
-		    return 0
-		}
-		if {[dom::node cget $child -nodeValue] != [lindex $specchild 1]} {
-		    return 0
-		}
-	    }
-	    default {
-	    }
-	}
-    }
-
-    return 1
-}
-
-# testPackage package ?version?
-#	Loads specified package with 'package require $package $version',
-#	then prints message describing how the package was loaded.
-#
-#	This is useful when you've got several versions of a
-#	package to lying around and want to make sure you're 
-#	testing the right one.
-#
-
-proc testPackage {package {version ""}} {
-    if {![catch "package present $package $version"]} { return }
-    set rc [catch "package require $package $version" result]
-    if {$rc} { return -code $rc $result }
-    set version $result
-    set loadScript [package ifneeded $package $version]
-    puts $::tcltest::outputChannel \
-	"Loaded $package version $version via {$loadScript}"
-    return;
-}
-
-#*EOF*
diff --git a/tclxml-3.2/tests/tclxslt/transform-1.3-result.html b/tclxml-3.2/tests/tclxslt/transform-1.3-result.html
deleted file mode 100644
index b4bf794..0000000
--- a/tclxml-3.2/tests/tclxslt/transform-1.3-result.html
+++ /dev/null
@@ -1,142 +0,0 @@
-<html>
-<head>
-<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
-<title>Zveno - XML Specialists</title>
-<meta name="description" content="Zveno website entrance page">
-<script language="JavaScript">
-<!--
-<!--hide this script from non-javascript-enabled browsers
-
-/* Functions that swaps images. */
-
-/* Functions that handle preload. */
-
-// stop hiding -->
-
-function MM_preloadImages() { //v3.0
-  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
-    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
-    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
-}
-
-function MM_swapImgRestore() { //v3.0
-  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
-}
-
-function MM_findObj(n, d) { //v3.0
-  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
-    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
-  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
-  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document); return x;
-}
-
-function MM_swapImage() { //v3.0
-  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
-   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
-}
-//-->
-	</script>
-</head>
-<body bgcolor="#ffffff" onLoad="MM_preloadImages('images/funkyfront/saucer_f2.gif','images/funkyfront/rocketroll_f2.gif','images/funkyfront/xmlnav_f2.gif','images/funkyfront/toolsnav_f2.gif','images/funkyfront/toolsroll_f2.gif','images/funkyfront/trainingnav_f2.gif','images/funkyfront/trainingroll_f2.gif','images/funkyfront/buildingnav_f2.gif','images/funkyfront/buildingroll_f2.gif','images/funkyfront/zvenolink_f2.gif','images/funkyfront/xmlink_f2.gif','images/funkyfront/aboutroll_f2.gif')">
-<table width="100%" border="0" cellspacing="0" cellpadding="0" height="90%"><tr><td>
-<table border="0" cellpadding="0" cellspacing="0" width="610" align="center">
-<tr>
-<td><img src="images/funkyfront/shim.gif" width="106" height="1" border="0"></td>
-<td><img src="images/funkyfront/shim.gif" width="21" height="1" border="0"></td>
-<td><img src="images/funkyfront/shim.gif" width="13" height="1" border="0"></td>
-<td><img src="images/funkyfront/shim.gif" width="41" height="1" border="0"></td>
-<td><img src="images/funkyfront/shim.gif" width="53" height="1" border="0"></td>
-<td><img src="images/funkyfront/shim.gif" width="32" height="1" border="0"></td>
-<td><img src="images/funkyfront/shim.gif" width="20" height="1" border="0"></td>
-<td><img src="images/funkyfront/shim.gif" width="29" height="1" border="0"></td>
-<td><img src="images/funkyfront/shim.gif" width="39" height="1" border="0"></td>
-<td><img src="images/funkyfront/shim.gif" width="16" height="1" border="0"></td>
-<td><img src="images/funkyfront/shim.gif" width="35" height="1" border="0"></td>
-<td><img src="images/funkyfront/shim.gif" width="19" height="1" border="0"></td>
-<td><img src="images/funkyfront/shim.gif" width="74" height="1" border="0"></td>
-<td><img src="images/funkyfront/shim.gif" width="32" height="1" border="0"></td>
-<td><img src="images/funkyfront/shim.gif" width="80" height="1" border="0"></td>
-<td><img src="images/funkyfront/shim.gif" width="1" height="1" border="0"></td>
-</tr>
-<tr valign="top">
-<td rowspan="5" colspan="2"><a onMouseOver="MM_swapImage('saucer','','images/funkyfront/saucer_f2.gif',1);" href="zveno_information/about-zveno.html"><img name="logo" src="images/funkyfront/logo.gif" width="127" height="103" border="0"></a></td>
-<td colspan="6"><a onMouseOver="MM_swapImage('rocketroll','','images/funkyfront/rocketroll_f2.gif',1);" href="zveno_information/about-zveno.html"><img name="xmlspecialist" src="images/funkyfront/xmlspecialist.gif" width="188" height="35" border="0"></a></td>
-<td colspan="2"><a onMouseOut="MM_swapImgRestore()" onMouseOver="MM_swapImage('xmlnav','','images/funkyfront/xmlnav_f2.gif','saucer','','images/funkyfront/saucer_f2.gif',1);" href="zveno_information/xml-resources.html"><img name="xmlnav" src="images/funkyfront/xmlnav.gif" width="55" height="35" border="0"></a></td>
-<td colspan="2"><a onMouseOut="MM_swapImgRestore()" onMouseOver="MM_swapImage('toolsnav','','images/funkyfront/toolsnav_f2.gif','toolsroll','','images/funkyfront/toolsroll_f2.gif',1);" href="open_source/"><img name="toolsnav" src="images/funkyfront/toolsnav.gif" width="54" height="35" border="0"></a></td>
-<td><a onMouseOut="MM_swapImgRestore()" onMouseOver="MM_swapImage('trainingnav','','images/funkyfront/trainingnav_f2.gif','trainingroll','','images/funkyfront/trainingroll_f2.gif',1);" href="courses/"><img name="trainingnav" src="images/funkyfront/trainingnav.gif" width="74" height="35" border="0"></a></td>
-<td colspan="2"><a onMouseOut="MM_swapImgRestore()" onMouseOver="MM_swapImage('buildingnav','','images/funkyfront/buildingnav_f2.gif','buildingroll','','images/funkyfront/buildingroll_f2.gif',1)" href="zveno_information/about-zveno.html"><img name="buildingnav" src="images/funkyfront/buildingnav.gif" width="112" height="35" border="0"></a></td>
-<td><img src="images/funkyfront/shim.gif" width="1" height="35" border="0"></td>
-</tr>
-<tr valign="top">
-<td rowspan="3"><img name="home_r02_c03" src="images/funkyfront/home_r02_c03.gif" width="13" height="36" border="0"></td>
-<td><img name="home_r02_c04" src="images/funkyfront/home_r02_c04.gif" width="41" height="7" border="0"></td>
-<td rowspan="2" colspan="11"><img name="home_r02_c05" src="images/funkyfront/home_r02_c05.gif" width="429" height="23" border="0"></td>
-<td><img src="images/funkyfront/shim.gif" width="1" height="7" border="0"></td>
-</tr>
-<tr valign="top">
-<td><a onMouseOut="MM_swapImgRestore()" onMouseOver="MM_swapImage('zvenolink','','images/funkyfront/zvenolink_f2.gif',1);" href="zveno_information/about-zveno.html"><img name="zvenolink" src="images/funkyfront/zvenolink.gif" width="41" height="16" border="0"></a></td>
-<td><img src="images/funkyfront/shim.gif" width="1" height="16" border="0"></td>
-</tr>
-<tr valign="top">
-<td colspan="2"><img name="home_r04_c04" src="images/funkyfront/home_r04_c04.gif" width="94" height="13" border="0"></td>
-<td><a onMouseOut="MM_swapImgRestore()" onMouseOver="MM_swapImage('xmlink','','images/funkyfront/xmlink_f2.gif',1);" href="zveno_information/xml-resources.html"><img name="xmlink" src="images/funkyfront/xmlink.gif" width="32" height="13" border="0"></a></td>
-<td colspan="9"><img name="home_r04_c07" src="images/funkyfront/home_r04_c07.gif" width="344" height="13" border="0"></td>
-<td><img src="images/funkyfront/shim.gif" width="1" height="13" border="0"></td>
-</tr>
-<tr valign="top">
-<td colspan="13"><img name="home_r05_c03" src="images/funkyfront/home_r05_c03.gif" width="483" height="32" border="0"></td>
-<td><img src="images/funkyfront/shim.gif" width="1" height="32" border="0"></td>
-</tr>
-<tr valign="top">
-<td colspan="6"><img name="home_r06_c01" src="images/funkyfront/home_r06_c01.gif" width="266" height="47" border="0"></td>
-<td rowspan="2" colspan="3"><img name="rocketroll" src="images/funkyfront/rocketroll.gif" width="88" height="84" border="0"></td>
-<td rowspan="2" colspan="6"><img name="home_r06_c10" src="images/funkyfront/home_r06_c10.gif" width="256" height="84" border="0"></td>
-<td><img src="images/funkyfront/shim.gif" width="1" height="47" border="0"></td>
-</tr>
-<tr valign="top">
-<td rowspan="2" colspan="6"><a onMouseOver="MM_swapImage('aboutroll','','images/funkyfront/aboutroll_f2.gif',1);" href="zveno_information/about-zveno.html"><img name="aboutroll" src="images/funkyfront/aboutroll.gif" width="266" height="54" border="0"></a></td>
-<td><img src="images/funkyfront/shim.gif" width="1" height="37" border="0"></td>
-</tr>
-<tr valign="top">
-<td colspan="2"><img name="home_r08_c07" src="images/funkyfront/home_r08_c07.gif" width="49" height="17" border="0"></td>
-<td rowspan="3" colspan="6"><a onMouseOver="MM_swapImage('toolsroll','','images/funkyfront/toolsroll_f2.gif',1);" href="open_source/"><img name="toolsroll" src="images/funkyfront/toolsroll.gif" width="215" height="64" border="0"></a></td>
-<td rowspan="3"><img name="home_r08_c15" src="images/funkyfront/home_r08_c15.gif" width="80" height="64" border="0"></td>
-<td><img src="images/funkyfront/shim.gif" width="1" height="17" border="0"></td>
-</tr>
-<tr valign="top">
-<td colspan="8"><img name="home_r09_c01" src="images/funkyfront/home_r09_c01.gif" width="315" height="33" border="0"></td>
-<td><img src="images/funkyfront/shim.gif" width="1" height="33" border="0"></td>
-</tr>
-<tr valign="top">
-<td rowspan="2"><img name="home_r10_c01" src="images/funkyfront/home_r10_c01.gif" width="106" height="39" border="0"></td>
-<td rowspan="3" colspan="6"><a onMouseOver="MM_swapImage('trainingroll','','images/funkyfront/trainingroll_f2.gif',1);" href="courses/"><img name="trainingroll" src="images/funkyfront/trainingroll.gif" width="180" height="86" border="0"></a></td>
-<td><img name="home_r10_c08" src="images/funkyfront/home_r10_c08.gif" width="29" height="14" border="0"></td>
-<td><img src="images/funkyfront/shim.gif" width="1" height="14" border="0"></td>
-</tr>
-<tr valign="top">
-<td rowspan="2" colspan="4"><img name="home_r11_c08" src="images/funkyfront/home_r11_c08.gif" width="119" height="72" border="0"></td>
-<td rowspan="3" colspan="4"><a onMouseOver="MM_swapImage('buildingroll','','images/funkyfront/buildingroll_f2.gif',1);" href="zveno_information/about-zveno.html"><img name="buildingroll" src="images/funkyfront/buildingroll.gif" width="205" height="92" border="0"></a></td>
-<td><img src="images/funkyfront/shim.gif" width="1" height="25" border="0"></td>
-</tr>
-<tr valign="top">
-<td rowspan="3"><a onMouseOut="MM_swapImgRestore()" onMouseOver="MM_swapImage('saucer','','images/funkyfront/saucer_f2.gif',1);" href="zveno_information/about-zveno.html"><img name="saucer" src="images/funkyfront/saucer.gif" width="106" height="109" border="0"></a></td>
-<td><img src="images/funkyfront/shim.gif" width="1" height="47" border="0"></td>
-</tr>
-<tr valign="top">
-<td rowspan="2" colspan="10"><img name="home_r13_c02" src="images/funkyfront/home_r13_c02.gif" width="299" height="62" border="0"></td>
-<td><img src="images/funkyfront/shim.gif" width="1" height="20" border="0"></td>
-</tr>
-<tr valign="top">
-<td colspan="4"><img name="home_r14_c12" src="images/funkyfront/home_r14_c12.gif" width="205" height="42" border="0"></td>
-<td><img src="images/funkyfront/shim.gif" width="1" height="42" border="0"></td>
-</tr>
-</table>
-<div align="center"></div>
-</td></tr></table>
-<p> </p>
-<p> </p>
-<p> </p>
-<p> </p>
-<p> </p>
-</body>
-</html>
diff --git a/tclxml-3.2/tests/tclxslt/transform-1.3.xml b/tclxml-3.2/tests/tclxslt/transform-1.3.xml
deleted file mode 100644
index e207da6..0000000
--- a/tclxml-3.2/tests/tclxslt/transform-1.3.xml
+++ /dev/null
@@ -1,16 +0,0 @@
-<article>
-
-  <artheader>
-    <title>Zveno - XML Specialists</title>
-    <description>Zveno website entrance page</description>
-  </artheader>
-
-  <section role="links">
-    <AboutZveno>zveno_information/about-zveno.html</AboutZveno>
-    <XMLSpecialist>zveno_information/about-zveno.html</XMLSpecialist>
-    <XMLNav>zveno_information/xml-resources.html</XMLNav>
-    <Tools>open_source/</Tools>
-    <Training>courses/</Training>
-    <Consulting>zveno_information/about-zveno.html</Consulting>
-  </section>
-</article>
diff --git a/tclxml-3.2/tests/tclxslt/transform-1.3.xsl b/tclxml-3.2/tests/tclxslt/transform-1.3.xsl
deleted file mode 100644
index bb99370..0000000
--- a/tclxml-3.2/tests/tclxslt/transform-1.3.xsl
+++ /dev/null
@@ -1 +0,0 @@
-<?xml version='1.0'?>
<xsl:stylesheet version='1.0'
	xmlns:xsl='http://www.w3.org/1999/XSL/Transform'>

<!-- entrance.xsl
   -
   -	Creates the Zveno 'entrance' page.
   -
   -	This page has little content, but is rich in links.
   -
   - Copyright (c) 2001 Zveno Pty Ltd
   - http://www.zveno.com/
   -
   - $Id: transform-1.3.xsl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
  -->

<xsl:output method="html" indent="yes"/>

<xsl:template match="/">

  <html>
    <head>
      <title><xsl:value-of select="//article/artheader/title"/></title>

      <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"/>
      <meta name="description">
	<xsl:attribute name="content">
	  <xsl:value-of select="//article/artheader/description"/>
	</xsl:attribute>
      </meta>

<script language="JavaScript">
<!--
<!--hide this script from non-javascript-enabled browsers

/* Functions that swaps images. */

/* Functions that handle preload. */

// stop hiding -->

function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function MM_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}

function MM_findObj(n, d) { //v3.0
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document); return x;
}

function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}
//-->
	</script>

      </head>

      <body bgcolor="#ffffff" onLoad="MM_preloadImages('images/funkyfront/saucer_f2.gif','images/funkyfront/rocketroll_f2.gif','images/funkyfront/xmlnav_f2.gif','images/funkyfront/toolsnav_f2.gif','images/funkyfront/toolsroll_f2.gif','images/funkyfront/trainingnav_f2.gif','images/funkyfront/trainingroll_f2.gif','images/funkyfront/buildingnav_f2.gif','images/funkyfront/buildingroll_f2.gif','images/funkyfront/zvenolink_f2.gif','images/funkyfront/xmlink_f2.gif','images/funkyfront/aboutroll_f2.gif')">

	<!-- Image with table --> 
	<table width="100%" border="0" cellspacing="0" cellpadding="0" height="90%">
	  <tr>
	    <td>
	      <table border="0" cellpadding="0" cellspacing="0" width="610" align="center">
	        <!-- fwtable fwsrc="home5.png" fwbase="home.gif" --> 
	        <tr> <!-- Shim row, height 1. --> 
	          <td><img src="images/funkyfront/shim.gif" width="106" height="1" border="0"/></td>
	          <td><img src="images/funkyfront/shim.gif" width="21" height="1" border="0"/></td>
	          <td><img src="images/funkyfront/shim.gif" width="13" height="1" border="0"/></td>
	          <td><img src="images/funkyfront/shim.gif" width="41" height="1" border="0"/></td>
	          <td><img src="images/funkyfront/shim.gif" width="53" height="1" border="0"/></td>
	          <td><img src="images/funkyfront/shim.gif" width="32" height="1" border="0"/></td>
	          <td><img src="images/funkyfront/shim.gif" width="20" height="1" border="0"/></td>
	          <td><img src="images/funkyfront/shim.gif" width="29" height="1" border="0"/></td>
	          <td><img src="images/funkyfront/shim.gif" width="39" height="1" border="0"/></td>
	          <td><img src="images/funkyfront/shim.gif" width="16" height="1" border="0"/></td>
	          <td><img src="images/funkyfront/shim.gif" width="35" height="1" border="0"/></td>
	          <td><img src="images/funkyfront/shim.gif" width="19" height="1" border="0"/></td>
	          <td><img src="images/funkyfront/shim.gif" width="74" height="1" border="0"/></td>
	          <td><img src="images/funkyfront/shim.gif" width="32" height="1" border="0"/></td>
	          <td><img src="images/funkyfront/shim.gif" width="80" height="1" border="0"/></td>
	          <td><img src="images/funkyfront/shim.gif" width="1" height="1" border="0"/></td>
	        </tr>
	        <tr valign="top"><!-- row 1 --> 
	          <td rowspan="5" colspan="2">
		    <a onMouseOver="MM_swapImage('saucer','','images/funkyfront/saucer_f2.gif',1);" >
		      <xsl:attribute name="href">
			<xsl:value-of select="//article/section[@role='links']/AboutZveno"/>
		      </xsl:attribute>
		      <img name="logo" src="images/funkyfront/logo.gif" width="127" height="103" border="0"/>
		    </a>
		  </td>
	          <td colspan="6">
		    <a onMouseOver="MM_swapImage('rocketroll','','images/funkyfront/rocketroll_f2.gif',1);">
		      <xsl:attribute name="href">
			<xsl:value-of select="//article/section[@role='links']/XMLSpecialist"/>
		      </xsl:attribute>
		      <img name="xmlspecialist" src="images/funkyfront/xmlspecialist.gif" width="188" height="35" border="0"/>
		    </a>
		  </td>
	          <td colspan="2">
		    <a onMouseOut="MM_swapImgRestore()"  onMouseOver="MM_swapImage('xmlnav','','images/funkyfront/xmlnav_f2.gif','saucer','','images/funkyfront/saucer_f2.gif',1);" >
		      <xsl:attribute name="href">
			<xsl:value-of select="//article/section[@role='links']/XMLNav"/>
		      </xsl:attribute>
		      <img name="xmlnav" src="images/funkyfront/xmlnav.gif" width="55" height="35" border="0"/>
		    </a>
		  </td>
	          <td colspan="2">
		    <a onMouseOut="MM_swapImgRestore()"  onMouseOver="MM_swapImage('toolsnav','','images/funkyfront/toolsnav_f2.gif','toolsroll','','images/funkyfront/toolsroll_f2.gif',1);" >
		      <xsl:attribute name="href">
			<xsl:value-of select="//article/section[@role='links']/Tools"/>
		      </xsl:attribute>
		      <img name="toolsnav" src="images/funkyfront/toolsnav.gif" width="54" height="35" border="0"/>
		    </a>
		  </td>
	          <td>
		    <a onMouseOut="MM_swapImgRestore()"  onMouseOver="MM_swapImage('trainingnav','','images/funkyfront/trainingnav_f2.gif','trainingroll','','images/funkyfront/trainingroll_f2.gif',1);" >
		      <xsl:attribute name="href">
			<xsl:value-of select="//article/section[@role='links']/Training"/>
		      </xsl:attribute>
		      <img name="trainingnav" src="images/funkyfront/trainingnav.gif" width="74" height="35" border="0"/>
		    </a>
		  </td>
	          <td colspan="2">
		    <a onMouseOut="MM_swapImgRestore()"  onMouseOver="MM_swapImage('buildingnav','','images/funkyfront/buildingnav_f2.gif','buildingroll','','images/funkyfront/buildingroll_f2.gif',1)" >
		      <xsl:attribute name="href">
			<xsl:value-of select="//article/section[@role='links']/Consulting"/>
		      </xsl:attribute>
		      <img name="buildingnav" src="images/funkyfront/buildingnav.gif" width="112" height="35" border="0"/>
		    </a>
		  </td>
	          <td><img src="images/funkyfront/shim.gif" width="1" height="35" border="0"/></td>
	        </tr>
	        <tr valign="top"><!-- row 2 --> 
	          <td rowspan="3"><img name="home_r02_c03" src="images/funkyfront/home_r02_c03.gif" width="13" height="36" border="0"/></td>
	          <td><img name="home_r02_c04" src="images/funkyfront/home_r02_c04.gif" width="41" height="7" border="0"/></td>
	          <td rowspan="2" colspan="11"><img name="home_r02_c05" src="images/funkyfront/home_r02_c05.gif" width="429" height="23" border="0"/></td>
	          <td><img src="images/funkyfront/shim.gif" width="1" height="7" border="0"/></td>
	        </tr>
	        <tr valign="top"><!-- row 3 --> 
	          <td>
		    <a onMouseOut="MM_swapImgRestore()"  onMouseOver="MM_swapImage('zvenolink','','images/funkyfront/zvenolink_f2.gif',1);" >
		      <xsl:attribute name="href">
			<xsl:value-of select="//article/section[@role='links']/AboutZveno"/>
		      </xsl:attribute>
		      <img name="zvenolink" src="images/funkyfront/zvenolink.gif" width="41" height="16" border="0"/>
		    </a>
		  </td>
	          <td><img src="images/funkyfront/shim.gif" width="1" height="16" border="0"/></td>
	        </tr>
	        <tr valign="top"><!-- row 4 --> 
	          <td colspan="2"><img name="home_r04_c04" src="images/funkyfront/home_r04_c04.gif" width="94" height="13" border="0"/></td>
	          <td>
		    <a onMouseOut="MM_swapImgRestore()"  onMouseOver="MM_swapImage('xmlink','','images/funkyfront/xmlink_f2.gif',1);" >
		      <xsl:attribute name="href">
			<xsl:value-of select="//article/section[@role='links']/XMLNav"/>
		      </xsl:attribute>
		      <img name="xmlink" src="images/funkyfront/xmlink.gif" width="32" height="13" border="0"/>
		    </a>
		  </td>
	          <td colspan="9"><img name="home_r04_c07" src="images/funkyfront/home_r04_c07.gif" width="344" height="13" border="0"/></td>
	          <td><img src="images/funkyfront/shim.gif" width="1" height="13" border="0"/></td>
	        </tr>
	        <tr valign="top"><!-- row 5 --> 
	          <td colspan="13"><img name="home_r05_c03" src="images/funkyfront/home_r05_c03.gif" width="483" height="32" border="0"/></td>
	          <td><img src="images/funkyfront/shim.gif" width="1" height="32" border="0"/></td>
	        </tr>
	        <tr valign="top"><!-- row 6 --> 
	          <td colspan="6"><img name="home_r06_c01" src="images/funkyfront/home_r06_c01.gif" width="266" height="47" border="0"/></td>
	          <td rowspan="2" colspan="3"><img name="rocketroll" src="images/funkyfront/rocketroll.gif" width="88" height="84" border="0"/></td>
	          <td rowspan="2" colspan="6"><img name="home_r06_c10" src="images/funkyfront/home_r06_c10.gif" width="256" height="84" border="0"/></td>
	          <td><img src="images/funkyfront/shim.gif" width="1" height="47" border="0"/></td>
	        </tr>
	        <tr valign="top"><!-- row 7 --> 
	          <td rowspan="2" colspan="6">
		    <a onMouseOver="MM_swapImage('aboutroll','','images/funkyfront/aboutroll_f2.gif',1);" >
		      <xsl:attribute name="href">
			<xsl:value-of select="//article/section[@role='links']/AboutZveno"/>
		      </xsl:attribute>
		      <img name="aboutroll" src="images/funkyfront/aboutroll.gif" width="266" height="54" border="0"/>
		    </a>
		  </td>
	          <td><img src="images/funkyfront/shim.gif" width="1" height="37" border="0"/></td>
	        </tr>
	        <tr valign="top"><!-- row 8 --> 
	          <td colspan="2"><img name="home_r08_c07" src="images/funkyfront/home_r08_c07.gif" width="49" height="17" border="0"/></td>
	          <td rowspan="3" colspan="6">
		    <a onMouseOver="MM_swapImage('toolsroll','','images/funkyfront/toolsroll_f2.gif',1);" >
		      <xsl:attribute name="href">
			<xsl:value-of select="//article/section[@role='links']/Tools"/>
		      </xsl:attribute>
		      <img name="toolsroll" src="images/funkyfront/toolsroll.gif" width="215" height="64" border="0"/>
		    </a>
		  </td>
	          <td rowspan="3"><img name="home_r08_c15" src="images/funkyfront/home_r08_c15.gif" width="80" height="64" border="0"/></td>
	          <td><img src="images/funkyfront/shim.gif" width="1" height="17" border="0"/></td>
	        </tr>
	        <tr valign="top"><!-- row 9 --> 
	          <td colspan="8"><img name="home_r09_c01" src="images/funkyfront/home_r09_c01.gif" width="315" height="33" border="0"/></td>
	          <td><img src="images/funkyfront/shim.gif" width="1" height="33" border="0"/></td>
	        </tr>
	        <tr valign="top"><!-- row 10 --> 
	          <td rowspan="2"><img name="home_r10_c01" src="images/funkyfront/home_r10_c01.gif" width="106" height="39" border="0"/></td>
	          <td rowspan="3" colspan="6">
		    <a onMouseOver="MM_swapImage('trainingroll','','images/funkyfront/trainingroll_f2.gif',1);" >
		      <xsl:attribute name="href">
			<xsl:value-of select="//article/section[@role='links']/Training"/>
		      </xsl:attribute>
		      <img name="trainingroll" src="images/funkyfront/trainingroll.gif" width="180" height="86" border="0"/>
		    </a>
		  </td>
	          <td><img name="home_r10_c08" src="images/funkyfront/home_r10_c08.gif" width="29" height="14" border="0"/></td>
	          <td><img src="images/funkyfront/shim.gif" width="1" height="14" border="0"/></td>
	        </tr>
	        <tr valign="top"><!-- row 11 --> 
	          <td rowspan="2" colspan="4"><img name="home_r11_c08" src="images/funkyfront/home_r11_c08.gif" width="119" height="72" border="0"/></td>
	          <td rowspan="3" colspan="4">
		    <a onMouseOver="MM_swapImage('buildingroll','','images/funkyfront/buildingroll_f2.gif',1);" >
		      <xsl:attribute name="href">
			<xsl:value-of select="//article/section[@role='links']/Consulting"/>
		      </xsl:attribute>
		      <img name="buildingroll" src="images/funkyfront/buildingroll.gif" width="205" height="92" border="0"/>
		    </a>
		  </td>
	          <td><img src="images/funkyfront/shim.gif" width="1" height="25" border="0"/></td>
	        </tr>
	        <tr valign="top"><!-- row 12 --> 
	          <td rowspan="3">
		    <a onMouseOut="MM_swapImgRestore()"  onMouseOver="MM_swapImage('saucer','','images/funkyfront/saucer_f2.gif',1);" >
		      <xsl:attribute name="href">
			<xsl:value-of select="//article/section[@role='links']/AboutZveno"/>
		      </xsl:attribute>
		      <img name="saucer" src="images/funkyfront/saucer.gif" width="106" height="109" border="0"/>
		    </a>
		  </td>
	          <td><img src="images/funkyfront/shim.gif" width="1" height="47" border="0"/></td>
	        </tr>
	        <tr valign="top"><!-- row 13 --> 
	          <td rowspan="2" colspan="10"><img name="home_r13_c02" src="images/funkyfront/home_r13_c02.gif" width="299" height="62" border="0"/></td>
	          <td><img src="images/funkyfront/shim.gif" width="1" height="20" border="0"/></td>
	        </tr>
	        <tr valign="top"><!-- row 14 --> 
	          <td colspan="4"><img name="home_r14_c12" src="images/funkyfront/home_r14_c12.gif" width="205" height="42" border="0"/></td>
	          <td><img src="images/funkyfront/shim.gif" width="1" height="42" border="0"/></td>
	        </tr>
	      </table>
	      <div align="center"></div>
	    </td>
	  </tr>
	</table>
	<p><xsl:text disable-output-escaping="yes">&nbsp;</xsl:text></p>
	<p><xsl:text disable-output-escaping="yes">&nbsp;</xsl:text></p>
	<p><xsl:text disable-output-escaping="yes">&nbsp;</xsl:text></p>
	<p><xsl:text disable-output-escaping="yes">&nbsp;</xsl:text></p>
	<p><xsl:text disable-output-escaping="yes">&nbsp;</xsl:text></p>

      </body>
    </html>
  </xsl:template>
</xsl:stylesheet>


\ No newline at end of file
diff --git a/tclxml-3.2/tests/tclxslt/transform.test b/tclxml-3.2/tests/tclxslt/transform.test
deleted file mode 100755
index c51d607..0000000
--- a/tclxml-3.2/tests/tclxslt/transform.test
+++ /dev/null
@@ -1,322 +0,0 @@
-# Features covered:  XSLT Transformations
-#
-# This file contains a collection of tests for the TclXSLT package.
-# This file tests the parser's performance on tranformations.
-# Sourcing this file into Tcl runs the tests and generates output
-# for errors.  No output means no errors were found.
-#
-# Copyright (c) 2008 Explain
-# http://www.explain.com.au/
-# Copyright (c) 2001-2003 Zveno Pty Ltd.
-#
-# $Id: transform.test,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-package require tcltest
-source [file join [tcltest::workingDirectory] tclxsltutils.tcl]
-
-testPackage xslt
-
-namespace eval ::xslt::transformTest {
-    namespace import -force ::tcltest::*
-
-    variable SETUP {
-	variable style1 [dom::parse {<xsl:stylesheet version="1.0"
-		xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
-
-	  <xsl:output method="text"/>
-
-	  <xsl:template match="/">
-	    <xsl:value-of select='name(/*)'/>
-	  </xsl:template>
-
-	</xsl:stylesheet>
-	}]
-	set xml1 [dom::parse <Test/>]
-	set xml2 [dom::parse <AnotherTest/>]
-    }
-    variable SETUP2 {
-	eval $SETUP
-	set ssheet [xslt::compile $style1]
-    }
-    variable CLEANUP {
-	dom::destroy $style1
-	dom::destroy $xml1
-	dom::destroy $xml2
-    }
-    variable CLEANUP2 {
-	eval $CLEANUP
-	rename $ssheet {}
-    }
-
-    test transform-1.1 {Compile and destroy stylesheet} -setup $SETUP -body {
-	set s1 [xslt::compile $style1]
-	rename $s1 {}
-    } -cleanup $CLEANUP -result {}
-
-    test transform-1.2 {Compile stylesheet} -setup $SETUP -body {
-	variable s1 [xslt::compile $style1]
-	string equal [info commands $s1] {}
-    } -cleanup {
-	eval $CLEANUP
-	rename $s1 {}
-    } -result 0
-
-    test transform-1.3 {-method option, default} -setup {
-	set stydoc [dom::parse {<xsl:stylesheet version='1.0'
-xmlns:xsl='http://www.w3.org/1999/XSL/Transform'>
-</xsl:stylesheet>
-}]
-	set ssheet [xslt::compile $stydoc]
-    } -body {
-	$ssheet cget -method
-    } -cleanup {
-	dom::destroy $stydoc
-	rename $ssheet {}
-    } -result {}
-    test transform-1.4 {-method option, text} -setup $SETUP2 -body {
-	$ssheet cget -method
-    } -cleanup $CLEANUP2 -result text
-    test transform-1.5 {-method option, html} -setup {
-	set stydoc [dom::parse {<xsl:stylesheet version='1.0'
-xmlns:xsl='http://www.w3.org/1999/XSL/Transform'>
-  <xsl:output method='html'/>
-</xsl:stylesheet>
-}]
-	set ssheet [xslt::compile $stydoc]
-    } -body {
-	$ssheet cget -method
-    } -cleanup {
-	dom::destroy $stydoc
-	rename $ssheet {}
-    } -result html
-    test transform-1.5 {-method option, xml} -setup {
-	set stydoc [dom::parse {<xsl:stylesheet version='1.0'
-xmlns:xsl='http://www.w3.org/1999/XSL/Transform'>
-  <xsl:output method='xml'/>
-</xsl:stylesheet>
-}]
-	set ssheet [xslt::compile $stydoc]
-    } -body {
-	$ssheet cget -method
-    } -cleanup {
-	dom::destroy $stydoc
-	rename $ssheet {}
-    } -result xml
-    test transform-1.6 {configure -method} -match glob -setup {
-	set stydoc [dom::parse {<xsl:stylesheet version='1.0'
-xmlns:xsl='http://www.w3.org/1999/XSL/Transform'>
-  <xsl:output method='xml'/>
-</xsl:stylesheet>
-}]
-	set ssheet [xslt::compile $stydoc]
-    } -body {
-	expectError {
-	    $ssheet configure -method html
-	}
-    } -cleanup {
-	dom::destroy $stydoc
-	rename $ssheet {}
-    } -result {*read-only*}
-    test transform-1.7 {error: too many arguments} -setup $SETUP -match glob -body {
-	expectError {
-	    ::xslt::compile $style1 somethingelse
-	}
-    } -cleanup $CLEANUP -result {wrong # args*}
-
-    # In-memory tests
-
-    test transform-2.1 {Single, simple XSLT Transformation} -setup $SETUP2 -body {
-	set result [$ssheet transform $xml1]
-	dom::serialize $result -method text
-    } -cleanup $CLEANUP2 -result {Test}
-
-    test transform-2.2 {Multiple simple XSLT Transformations} -setup $SETUP2 -body {
-	set result1 [$ssheet transform $xml1]
-	set result2 [$ssheet transform $xml2]
-	list [::dom::serialize $result1 -method text] \
-		[::dom::serialize $result2 -method text]
-    } -cleanup $CLEANUP2 -result [list Test AnotherTest]
-
-    test transform-2.3 {Complex XSLT Transformation} -setup {
-	set ch [open [file join [workingDirectory] transform-1.3.xsl]]
-	set ssheetdoc [::dom::parse [read $ch]]
-	close $ch
-
-	set ch [open [file join [workingDirectory] transform-1.3.xml]]
-	set source [::dom::parse [read $ch]]
-	close $ch
-
-	set ch [open [file join [workingDirectory] transform-1.3-result.html]]
-	set expectedxml [read $ch]
-	close $ch
-    } -body {
-	set ssheet [xslt::compile $ssheetdoc]
-	set result [$ssheet transform $source]
-	string equal [dom::serialize $result -method html] $expectedxml
-    } -cleanup {
-	dom::destroy $ssheetdoc
-	dom::destroy $source
-	dom::destroy $result
-	rename $ssheet {}
-	catch {unset expectedxml}
-    } -result 1
-
-    # Parameters
-
-    test transform-5.1 {Pass parameters} -setup {
-	eval $SETUP
-	set styledoc [::dom::parse {<xsl:stylesheet
-    version="1.0"
-    xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
-
-  <xsl:output method="text"/>
-
-  <xsl:param name="test">wrong value</xsl:param>
-
-  <xsl:template match="/">
-    <xsl:value-of select="$test"/>
-  </xsl:template>
-
-</xsl:stylesheet>
-}]
-	set style [xslt::compile $styledoc]
-    } -body {
-	set result [$style transform $xml1 test {'correct value'}]
-	::dom::serialize $result -method text
-    } -cleanup {
-	eval $CLEANUP
-	dom::destroy $styledoc
-	dom::destroy $result
-	rename $style {}
-    } -result {correct value}
-
-    test transform-5.2 {Pass parameter, calculate result} -setup {
-	# Create a large source document
-	set sourcexml {<?xml version="1.0"?>
-<Test>
-}
-	for {set i 0} {$i < 1000} {incr i} {
-	    append sourcexml "  <value/>\n"
-	}
-	append sourcexml {
-</Test>
-}
-	set source [::dom::parse $sourcexml]
-	set styledoc [::dom::parse {<xsl:stylesheet
-    version="1.0"
-    xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
-
-  <xsl:output method="text"/>
-  <xsl:strip-space elements='*'/>
-
-  <xsl:param name="test" select="'10'"/>
-
-  <xsl:template match="value">
-    <!--
-    <xsl:message>Processing value <xsl:value-of select="position()"/></xsl:message>
-    -->
-    <xsl:call-template name="recurse">
-      <xsl:with-param name="value" select="$test"/>
-    </xsl:call-template>
-  </xsl:template>
-
-  <xsl:template name="recurse">
-    <xsl:param name="value" select="'0'"/>
-
-    <xsl:choose>
-      <xsl:when test="$value = 0">
-      </xsl:when>
-      <xsl:otherwise>
-	<xsl:text>ooooXXXXoooo</xsl:text>
-	<xsl:call-template name="recurse">
-	  <xsl:with-param name="value" select="$value - 1"/>
-	</xsl:call-template>
-      </xsl:otherwise>
-    </xsl:choose>
-  </xsl:template>
-
-</xsl:stylesheet>
-}]
-	set style [xslt::compile $styledoc]
-    } -body {
-	set result [$style transform $source test '2']
-	expr {[string length [dom::serialize $result -method text]] == 1000 * 2 * [string length "ooooXXXXoooo"]}
-    } -cleanup {
-	unset sourcexml
-	dom::destroy $source
-	dom::destroy $styledoc
-	dom::destroy $result
-	rename $style {}
-    } -result 1
-
-    test transform-5.3 {get parameters} -setup {
-	set stydoc [dom::parse {<xsl:stylesheet version='1.0'
-xmlns:xsl='http://www.w3.org/1999/XSL/Transform'>
-
-  <xsl:param name='firstParameter' select='"firstValue"'/>
-  <xsl:param name='secondParameter'>
-    second value
-  </xsl:param>
-  <xsl:variable name='thirdVariable' select='"thirdValue"'/>
-
-</xsl:stylesheet>
-}]
-	set style [xslt::compile $stydoc]
-    } -body {
-	$style get parameters
-    } -cleanup {
-	dom::destroy $stydoc
-	rename $style {}
-    } -result {{firstParameter {} {"firstValue"}} {secondParameter {} {}}}
-
-    test transform-6.1 {-message} -setup {
-	variable msg {}
-	proc message text {
-	    variable msg
-	    append msg $text
-	}
-	set src [dom::parse <Test>value</Test>]
-	set stydoc [dom::parse {<xsl:stylesheet
-    version="1.0"
-    xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
-
-  <xsl:template match='/'>
-    <xsl:message>Testing message command</xsl:message>
-  </xsl:template>
-
-</xsl:stylesheet>
-}]
-	set ssheet [xslt::compile $stydoc]
-    } -body {
-	$ssheet configure -messagecommand [namespace code message]
-	set result [$ssheet transform $src]
-	set msg
-    } -cleanup {
-	dom::destroy $src
-	dom::destroy $stydoc
-	rename $ssheet {}
-	catch {unset msg}
-    } -result {Testing message command
-}
-
-    test transform-7.1 {error while compiling} -match glob -setup {
-	set srcdoc [dom::parse <Test>whatever</Test>]
-	set stydoc [dom::parse {
-<xsl:stylesheet version='1.0'
-  xmlns:xsl='http://www.w3.org/not/the/XSLT/namespace/URI'>
-</xsl:stylesheet>
-}]
-    } -body {
-	expectError {
-	    xslt::compile $stydoc
-	}
-    } -cleanup {
-	dom::destroy $srcdoc
-	dom::destroy $stydoc
-    } -result {*document is not a stylesheet*}
-
-    cleanupTests
-}
-
-namespace delete ::xslt::transformTest
-return
diff --git a/tclxml-3.2/tests/testutils.tcl b/tclxml-3.2/tests/testutils.tcl
deleted file mode 100644
index 1d323a2..0000000
--- a/tclxml-3.2/tests/testutils.tcl
+++ /dev/null
@@ -1,215 +0,0 @@
-# testutils.tcl --
-#
-# 	Auxilliary utilities for use with the tcltest package.
-# 	Author: Joe English <jenglish at flightlab.com>
-# 	Version: 1.1
-#
-# This file is hereby placed in the public domain.
-#
-# $Id: testutils.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-variable tracing 0		;# Set to '1' to enable the 'trace' command
-variable tracingErrors 0	;# If set, 'expectError' prints error messages
-
-# ok --
-#	Returns an empty string.
-#	May be used as the last statement in test scripts 
-#	that are only evaluated for side-effects or in cases
-#	where you just want to make sure that an operation succeeds
-#
-proc ok {} { return {} }
-
-# result result --
-#	Just returns $result
-#
-proc result {result} { return $result }
-
-# tracemsg msg --
-#	Prints tracing message if $::tracing is nonzero.
-#
-proc tracemsg {string} {
-    if {$::tracing} {
-	puts $::tcltest::outputChannel $string
-    }
-}
-
-# assert expr ?msg? --
-#	Evaluates 'expr' and signals an error
-#	if the condition is not true.
-#
-proc assert {expr {message ""}} {
-    if {![uplevel 1 [list expr $expr]]} {
-	return -code error "Assertion {$expr} failed:\n$message"
-    }
-}
-
-# expectError script  ? pattern ? --
-#	Evaluate 'script', which is expected to fail
-#	with an error message matching 'pattern'.
-#
-#	Returns the error message if the script 'correctly' fails,
-#	raises an error otherwise
-
-proc expectError {script {pattern "*"}} {
-    set rc [catch [list uplevel 1 $script] result]
-    if {$::tracingErrors} {
-	puts stderr "==> [string replace $result 70 end ...]"
-    }
-    set rmsg [string replace $result 40 end ...]
-    if {$rc != 1} {
-	return -code error \
-	    "Expected error, got '$rmsg' (rc=$rc)"
-    }
-    return $result
-}
-
-# sortedarray --
-#
-#	Return the contents of an array, sorted by index
-
-proc sortedarray arrName {
-    upvar 1 $arrName thearray
-
-    set result {}
-    foreach idx [lsort [array names thearray]] {
-	lappend result $idx $thearray($idx)
-    }
-
-    return $result
-}
-
-# compareNodes
-#	Compares two nodes, taking implementations into account
-
-proc compareNodes {node1 node2} {
-    if {[::tcltest::testConstraint dom_libxml2] || [::tcltest::testConstraint dom_tcl]} {
-	::dom::node isSameNode $node1 $node2
-    } else {
-	return [expr ![string compare $node1 $node2]]
-    }
-}
-
-# compareNodeList list1 list2
-#	Compares two lists of DOM nodes, in an ordered fashion.
-#	NB. the node identities are compared, not their tokens.
-
-proc compareNodeList {list1 list2} {
-    if {[llength $list1] != [llength $list2]} {
-	return 0
-    }
-    foreach node1 $list1 node2 $list2 {
-	if {![compareNodes $node1 $node2]} {
-	    return 0
-	}
-    }
-    return 1
-}
-
-# compareNodeset set1 set2
-#	Compares two sets of DOM nodes, in an unordered fashion.
-#	NB. the node identities are compared, not their tokens.
-
-proc compareNodeset {set1 set2} {
-    if {[llength $set1] != [llength $set2]} {
-	return 0
-    }
-    foreach node1 [lsort $set1] node2 [lsort $set2] {
-	if {![compareNodes $node1 $node2]} {
-	    return 0
-	}
-    }
-    return 1
-}
-
-# checkTree doc list
-#	Tests that a DOM tree has a structure specified as a Tcl list
-
-proc checkTree {node spec {checktype 1}} {
-    if {[dom::node cget $node -nodeType] == "document"} {
-	if {$checktype} {
-	    if {[lindex [lindex $spec 0] 0] == "doctype"} {
-		set doctype [dom::document cget $node -doctype]
-		if {[dom::node cget $doctype -nodeType] != "documentType"} {
-		    return 0
-		}
-		if {[dom::documenttype cget $doctype -name] != [lindex [lindex $spec 0] 1]} {
-		    return 0
-		}
-		# Should also check external identifiers and internal subset
-		set spec [lrange $spec 1 end]
-	    }
-	}
-    }
-    foreach child [dom::node children $node] specchild $spec {
-	switch [lindex $specchild 0] {
-	    element {
-		if {[dom::node cget $child -nodeType] != "element"} {
-		    return 0
-		}
-		if {[dom::node cget $child -nodeName] != [lindex $specchild 1]} {
-		    return 0
-		}
-		foreach {name value} [lindex $specchild 2] {
-		    if {[dom::element getAttribute $child $name] != $value} {
-			return 0
-		    }
-		}
-		set result [checkTree $child [lindex $specchild 3]]
-		if {!$result} {
-		    return 0
-		}
-	    }
-	    pi {
-		if {[dom::node cget $child -nodeType] != "processingInstruction"} {
-		    return 0
-		}
-		if {[dom::node cget $child -nodeName] != [lindex $specchild 1]} {
-		    return 0
-		}
-	    }
-	    dtd {
-		if {[dom::node cget $child -nodeType] != "dtd"} {
-		    return 0
-		}
-	    }
-	    text {
-		if {[dom::node cget $child -nodeType] != "textNode"} {
-		    return 0
-		}
-		if {[dom::node cget $child -nodeValue] != [lindex $specchild 1]} {
-		    return 0
-		}
-	    }
-	    default {
-	    }
-	}
-    }
-
-    return 1
-}
-
-# testPackage package ?version?
-#	Loads specified package with 'package require $package $version',
-#	then prints message describing how the package was loaded.
-#
-#	This is useful when you've got several versions of a
-#	package to lying around and want to make sure you're 
-#	testing the right one.
-#
-
-proc testPackage {package {version ""}} {
-    if {$package == "libxml2"} {
-	# "libxml2" is shorthand for xml::libxml2
-	set package xml::libxml2
-    }
-    if {![catch "package present $package $version"]} { return }
-    set rc [catch "package require $package $version" result]
-    if {$rc} { return -code $rc $result }
-    set version $result
-    set loadScript [package ifneeded $package $version]
-    puts $::tcltest::outputChannel \
-	"Loaded $package version $version via {$loadScript}"
-    return;
-}
-
-#*EOF*
diff --git a/tclxml-3.2/tools/genStubs.tcl b/tclxml-3.2/tools/genStubs.tcl
deleted file mode 100644
index d4ef368..0000000
--- a/tclxml-3.2/tools/genStubs.tcl
+++ /dev/null
@@ -1,894 +0,0 @@
-# genStubs.tcl --
-#
-#	This script generates a set of stub files for a given
-#	interface.  
-#	
-#
-# Copyright (c) 1998-1999 by Scriptics Corporation.
-# See the file "license.terms" for information on usage and redistribution
-# of this file, and for a DISCLAIMER OF ALL WARRANTIES.
-# 
-# RCS: @(#) $Id: genStubs.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-namespace eval genStubs {
-    # libraryName --
-    #
-    #	The name of the entire library.  This value is used to compute
-    #	the USE_*_STUB_PROCS macro and the name of the init file.
-
-    variable libraryName "UNKNOWN"
-
-    # interfaces --
-    #
-    #	An array indexed by interface name that is used to maintain
-    #   the set of valid interfaces.  The value is empty.
-
-    array set interfaces {}
-
-    # curName --
-    #
-    #	The name of the interface currently being defined.
-
-    variable curName "UNKNOWN"
-
-    # hooks --
-    #
-    #	An array indexed by interface name that contains the set of
-    #	subinterfaces that should be defined for a given interface.
-
-    array set hooks {}
-
-    # stubs --
-    #
-    #	This three dimensional array is indexed first by interface name,
-    #	second by platform name, and third by a numeric offset or the
-    #	constant "lastNum".  The lastNum entry contains the largest
-    #	numeric offset used for a given interface/platform combo.  Each
-    #	numeric offset contains the C function specification that
-    #	should be used for the given entry in the stub table.  The spec
-    #	consists of a list in the form returned by parseDecl.
-
-    array set stubs {}
-
-    # outDir --
-    #
-    #	The directory where the generated files should be placed.
-
-    variable outDir .
-}
-
-# genStubs::library --
-#
-#	This function is used in the declarations file to set the name
-#	of the library that the interfaces are associated with (e.g. "tcl").
-#	This value will be used to define the inline conditional macro.
-#
-# Arguments:
-#	name	The library name.
-#
-# Results:
-#	None.
-
-proc genStubs::library {name} {
-    variable libraryName $name
-}
-
-# genStubs::interface --
-#
-#	This function is used in the declarations file to set the name
-#	of the interface currently being defined.
-#
-# Arguments:
-#	name	The name of the interface.
-#
-# Results:
-#	None.
-
-proc genStubs::interface {name} {
-    variable curName $name
-    variable interfaces
-
-    set interfaces($name) {}
-    return
-}
-
-# genStubs::hooks --
-#
-#	This function defines the subinterface hooks for the current
-#	interface.
-#
-# Arguments:
-#	names	The ordered list of interfaces that are reachable through the
-#		hook vector.
-#
-# Results:
-#	None.
-
-proc genStubs::hooks {names} {
-    variable curName
-    variable hooks
-
-    set hooks($curName) $names
-    return
-}
-
-# genStubs::declare --
-#
-#	This function is used in the declarations file to declare a new
-#	interface entry.
-#
-# Arguments:
-#	index		The index number of the interface.
-#	platform	The platform the interface belongs to.  Should be one
-#			of generic, win, unix, or mac.
-#	decl		The C function declaration, or {} for an undefined
-#			entry.
-#
-# Results:
-#	None.
-
-proc genStubs::declare {args} {
-    variable stubs
-    variable curName
-
-    if {[llength $args] != 3} {
-	puts stderr "wrong # args: declare $args"
-    }
-    lassign $args index platformList decl
-
-    # Check for duplicate declarations, then add the declaration and
-    # bump the lastNum counter if necessary.
-
-    foreach platform $platformList {
-	if {[info exists stubs($curName,$platform,$index)]} {
-	    puts stderr "Duplicate entry: declare $args"
-	}
-    }
-    regsub -all "\[ \t\n\]+" [string trim $decl] " " decl
-    set decl [parseDecl $decl]
-
-    foreach platform $platformList {
-	if {$decl != ""} {
-	    set stubs($curName,$platform,$index) $decl
-	    if {![info exists stubs($curName,$platform,lastNum)] \
-		    || ($index > $stubs($curName,$platform,lastNum))} {
-		set stubs($curName,$platform,lastNum) $index
-	    }
-	}
-    }
-    return
-}
-
-# genStubs::rewriteFile --
-#
-#	This function replaces the machine generated portion of the
-#	specified file with new contents.  It looks for the !BEGIN! and
-#	!END! comments to determine where to place the new text.
-#
-# Arguments:
-#	file	The name of the file to modify.
-#	text	The new text to place in the file.
-#
-# Results:
-#	None.
-
-proc genStubs::rewriteFile {file text} {
-    if {![file exist $file]} {
-	puts stderr "Cannot find file: $file"
-	return
-    }
-    set in [open ${file} r]
-    set out [open ${file}.new w]
-
-    # Always write out the file with LF termination
-    fconfigure $out -translation lf
-
-    while {![eof $in]} {
-	set line [gets $in]
-	if {[regexp {!BEGIN!} $line]} {
-	    break
-	}
-	puts $out $line
-    }
-    puts $out "/* !BEGIN!: Do not edit below this line. */"
-    puts $out $text
-    while {![eof $in]} {
-	set line [gets $in]
-	if {[regexp {!END!} $line]} {
-	    break
-	}
-    }
-    puts $out "/* !END!: Do not edit above this line. */"
-    puts -nonewline $out [read $in]
-    close $in
-    close $out
-    file rename -force ${file}.new ${file}
-    return
-}
-
-# genStubs::addPlatformGuard --
-#
-#	Wrap a string inside a platform #ifdef.
-#
-# Arguments:
-#	plat	Platform to test.
-#
-# Results:
-#	Returns the original text inside an appropriate #ifdef.
-
-proc genStubs::addPlatformGuard {plat text} {
-    switch $plat {
-	win {
-	    return "#ifdef __WIN32__\n${text}#endif /* __WIN32__ */\n"
-	}
-	unix {
-	    return "#if !defined(__WIN32__) && !defined(MAC_TCL) /* UNIX */\n${text}#endif /* UNIX */\n"
-	}		    
-	mac {
-	    return "#ifdef MAC_TCL\n${text}#endif /* MAC_TCL */\n"
-	}
-    }
-    return "$text"
-}
-
-# genStubs::emitSlots --
-#
-#	Generate the stub table slots for the given interface.  If there
-#	are no generic slots, then one table is generated for each
-#	platform, otherwise one table is generated for all platforms.
-#
-# Arguments:
-#	name	The name of the interface being emitted.
-#	textVar	The variable to use for output.
-#
-# Results:
-#	None.
-
-proc genStubs::emitSlots {name textVar} {
-    variable stubs
-    upvar $textVar text
-
-    forAllStubs $name makeSlot 1 text {"    void *reserved$i;\n"}
-    return
-}
-
-# genStubs::parseDecl --
-#
-#	Parse a C function declaration into its component parts.
-#
-# Arguments:
-#	decl	The function declaration.
-#
-# Results:
-#	Returns a list of the form {returnType name args}.  The args
-#	element consists of a list of type/name pairs, or a single
-#	element "void".  If the function declaration is malformed
-#	then an error is displayed and the return value is {}.
-
-proc genStubs::parseDecl {decl} {
-    if {![regexp {^(.*)\((.*)\)$} $decl all prefix args]} {
-	puts stderr "Malformed declaration: $decl"
-	return
-    }
-    set prefix [string trim $prefix]
-    if {![regexp {^(.+[ ][*]*)([^ *]+)$} $prefix all rtype fname]} {
-	puts stderr "Bad return type: $decl"
-	return
-    }
-    set rtype [string trim $rtype]
-    foreach arg [split $args ,] {
-	lappend argList [string trim $arg]
-    }
-    if {![string compare [lindex $argList end] "..."]} {
-	if {[llength $argList] != 2} {
-	    puts stderr "Only one argument is allowed in varargs form: $decl"
-	}
-	set arg [parseArg [lindex $argList 0]]
-	if {$arg == "" || ([llength $arg] != 2)} {
-	    puts stderr "Bad argument: '[lindex $argList 0]' in '$decl'"
-	    return
-	}
-	set args [list TCL_VARARGS $arg]
-    } else {
-	set args {}
-	foreach arg $argList {
-	    set argInfo [parseArg $arg]
-	    if {![string compare $argInfo "void"]} {
-		lappend args "void"
-		break
-	    } elseif {[llength $argInfo] == 2 || [llength $argInfo] == 3} {
-		lappend args $argInfo
-	    } else {
-		puts stderr "Bad argument: '$arg' in '$decl'"
-		return
-	    }
-	}
-    }
-    return [list $rtype $fname $args]
-}
-
-# genStubs::parseArg --
-#
-#	This function parses a function argument into a type and name.
-#
-# Arguments:
-#	arg	The argument to parse.
-#
-# Results:
-#	Returns a list of type and name with an optional third array
-#	indicator.  If the argument is malformed, returns "".
-
-proc genStubs::parseArg {arg} {
-    if {![regexp {^(.+[ ][*]*)([^][ *]+)(\[\])?$} $arg all type name array]} {
-	if {$arg == "void"} {
-	    return $arg
-	} else {
-	    return
-	}
-    }
-    set result [list [string trim $type] $name]
-    if {$array != ""} {
-	lappend result $array
-    }
-    return $result
-}
-
-# genStubs::makeDecl --
-#
-#	Generate the prototype for a function.
-#
-# Arguments:
-#	name	The interface name.
-#	decl	The function declaration.
-#	index	The slot index for this function.
-#
-# Results:
-#	Returns the formatted declaration string.
-
-proc genStubs::makeDecl {name decl index} {
-    lassign $decl rtype fname args
-
-    append text "/* $index */\n"
-    set line "EXTERN $rtype"
-    set count [expr {2 - ([string length $line] / 8)}]
-    append line [string range "\t\t\t" 0 $count]
-    set pad [expr {24 - [string length $line]}]
-    if {$pad <= 0} {
-	append line " "
-	set pad 0
-    }
-    append line "$fname _ANSI_ARGS_("
-
-    set arg1 [lindex $args 0]
-    switch -exact $arg1 {
-	void {
-	    append line "(void)"
-	}
-	TCL_VARARGS {
-	    set arg [lindex $args 1]
-	    append line "TCL_VARARGS([lindex $arg 0],[lindex $arg 1])"
-	}
-	default {
-	    set sep "("
-	    foreach arg $args {
-		append line $sep
-		set next {}
-		append next [lindex $arg 0] " " [lindex $arg 1] \
-			[lindex $arg 2]
-		if {[string length $line] + [string length $next] \
-			+ $pad > 76} {
-		    append text $line \n
-		    set line "\t\t\t\t"
-		    set pad 28
-		}
-		append line $next
-		set sep ", "
-	    }
-	    append line ")"
-	}
-    }
-    append text $line
-    
-    append text ");\n"
-    return $text
-}
-
-# genStubs::makeMacro --
-#
-#	Generate the inline macro for a function.
-#
-# Arguments:
-#	name	The interface name.
-#	decl	The function declaration.
-#	index	The slot index for this function.
-#
-# Results:
-#	Returns the formatted macro definition.
-
-proc genStubs::makeMacro {name decl index} {
-    lassign $decl rtype fname args
-
-    set lfname [string tolower [string index $fname 0]]
-    append lfname [string range $fname 1 end]
-
-    set text "#ifndef $fname\n#define $fname"
-    set arg1 [lindex $args 0]
-    set argList ""
-    switch -exact $arg1 {
-	void {
-	    set argList "()"
-	}
-	TCL_VARARGS {
-	}
-	default {
-	    set sep "("
-	    foreach arg $args {
-		append argList $sep [lindex $arg 1]
-		set sep ", "
-	    }
-	    append argList ")"
-	}
-    }
-    append text " \\\n\t(${name}StubsPtr->$lfname)"
-    append text " /* $index */\n#endif\n"
-    return $text
-}
-
-# genStubs::makeStub --
-#
-#	Emits a stub function definition.
-#
-# Arguments:
-#	name	The interface name.
-#	decl	The function declaration.
-#	index	The slot index for this function.
-#
-# Results:
-#	Returns the formatted stub function definition.
-
-proc genStubs::makeStub {name decl index} {
-    lassign $decl rtype fname args
-
-    set lfname [string tolower [string index $fname 0]]
-    append lfname [string range $fname 1 end]
-
-    append text "/* Slot $index */\n" $rtype "\n" $fname
-
-    set arg1 [lindex $args 0]
-
-    if {![string compare $arg1 "TCL_VARARGS"]} {
-	lassign [lindex $args 1] type argName 
-	append text " TCL_VARARGS_DEF($type,$argName)\n\{\n"
-	append text "    " $type " var;\n    va_list argList;\n"
-	if {[string compare $rtype "void"]} {
-	    append text "    " $rtype " resultValue;\n"
-	}
-	append text "\n    var = (" $type ") TCL_VARARGS_START(" \
-		$type "," $argName ",argList);\n\n    "
-	if {[string compare $rtype "void"]} {
-	    append text "resultValue = "
-	}
-	append text "(" $name "StubsPtr->" $lfname "VA)(var, argList);\n"
-	append text "    va_end(argList);\n"
-	if {[string compare $rtype "void"]} {
-	    append text "return resultValue;\n"
-	}
-	append text "\}\n\n"
-	return $text
-    }
-
-    if {![string compare $arg1 "void"]} {
-	set argList "()"
-	set argDecls ""
-    } else {
-	set argList ""
-	set sep "("
-	foreach arg $args {
-	    append argList $sep [lindex $arg 1]
-	    append argDecls "    " [lindex $arg 0] " " \
-		    [lindex $arg 1] [lindex $arg 2] ";\n"
-	    set sep ", "
-	}
-	append argList ")"
-    }
-    append text $argList "\n" $argDecls "{\n    "
-    if {[string compare $rtype "void"]} {
-	append text "return "
-    }
-    append text "(" $name "StubsPtr->" $lfname ")" $argList ";\n}\n\n"
-    return $text
-}
-
-# genStubs::makeSlot --
-#
-#	Generate the stub table entry for a function.
-#
-# Arguments:
-#	name	The interface name.
-#	decl	The function declaration.
-#	index	The slot index for this function.
-#
-# Results:
-#	Returns the formatted table entry.
-
-proc genStubs::makeSlot {name decl index} {
-    lassign $decl rtype fname args
-
-    set lfname [string tolower [string index $fname 0]]
-    append lfname [string range $fname 1 end]
-
-    set text "    "
-    append text $rtype " (*" $lfname ") _ANSI_ARGS_("
-
-    set arg1 [lindex $args 0]
-    switch -exact $arg1 {
-	void {
-	    append text "(void)"
-	}
-	TCL_VARARGS {
-	    set arg [lindex $args 1]
-	    append text "TCL_VARARGS([lindex $arg 0],[lindex $arg 1])"
-	}
-	default {
-	    set sep "("
-	    foreach arg $args {
-		append text $sep [lindex $arg 0] " " [lindex $arg 1] \
-			[lindex $arg 2]
-		set sep ", "
-	    }
-	    append text ")"
-	}
-    }
-    
-    append text "); /* $index */\n"
-    return $text
-}
-
-# genStubs::makeInit --
-#
-#	Generate the prototype for a function.
-#
-# Arguments:
-#	name	The interface name.
-#	decl	The function declaration.
-#	index	The slot index for this function.
-#
-# Results:
-#	Returns the formatted declaration string.
-
-proc genStubs::makeInit {name decl index} {
-    append text "    " [lindex $decl 1] ", /* " $index " */\n"
-    return $text
-}
-
-# genStubs::forAllStubs --
-#
-#	This function iterates over all of the platforms and invokes
-#	a callback for each slot.  The result of the callback is then
-#	placed inside appropriate platform guards.
-#
-# Arguments:
-#	name		The interface name.
-#	slotProc	The proc to invoke to handle the slot.  It will
-#			have the interface name, the declaration,  and
-#			the index appended.
-#	onAll		If 1, emit the skip string even if there are
-#			definitions for one or more platforms.
-#	textVar		The variable to use for output.
-#	skipString	The string to emit if a slot is skipped.  This
-#			string will be subst'ed in the loop so "$i" can
-#			be used to substitute the index value.
-#
-# Results:
-#	None.
-
-proc genStubs::forAllStubs {name slotProc onAll textVar \
-	{skipString {"/* Slot $i is reserved */\n"}}} {
-    variable stubs
-    upvar $textVar text
-
-    set plats [array names stubs $name,*,lastNum]
-    if {[info exists stubs($name,generic,lastNum)]} {
-	# Emit integrated stubs block
-	set lastNum -1
-	foreach plat [array names stubs $name,*,lastNum] {
-	    if {$stubs($plat) > $lastNum} {
-		set lastNum $stubs($plat)
-	    }
-	}
-	for {set i 0} {$i <= $lastNum} {incr i} {
-	    set slots [array names stubs $name,*,$i]
-	    set emit 0
-	    if {[info exists stubs($name,generic,$i)]} {
-		if {[llength $slots] > 1} {
-		    puts stderr "platform entry duplicates generic entry: $i"
-		}
-		append text [$slotProc $name $stubs($name,generic,$i) $i]
-		set emit 1
-	    } elseif {[llength $slots] > 0} {
-		foreach plat {unix win mac} {
-		    if {[info exists stubs($name,$plat,$i)]} {
-			append text [addPlatformGuard $plat \
-				[$slotProc $name $stubs($name,$plat,$i) $i]]
-			set emit 1
-		    } elseif {$onAll} {
-			append text [eval {addPlatformGuard $plat} $skipString]
-			set emit 1
-		    }
-		}
-	    }
-	    if {$emit == 0} {
-		eval {append text} $skipString
-	    }
-	}
-	
-    } else {
-	# Emit separate stubs blocks per platform
-	foreach plat {unix win mac} {
-	    if {[info exists stubs($name,$plat,lastNum)]} {
-		set lastNum $stubs($name,$plat,lastNum)
-		set temp {}
-		for {set i 0} {$i <= $lastNum} {incr i} {
-		    if {![info exists stubs($name,$plat,$i)]} {
-			eval {append temp} $skipString
-		    } else {
-			append temp [$slotProc $name $stubs($name,$plat,$i) $i]
-		    }
-		}
-		append text [addPlatformGuard $plat $temp]
-	    }
-	}
-    }
-
-}
-
-# genStubs::emitDeclarations --
-#
-#	This function emits the function declarations for this interface.
-#
-# Arguments:
-#	name	The interface name.
-#	textVar	The variable to use for output.
-#
-# Results:
-#	None.
-
-proc genStubs::emitDeclarations {name textVar} {
-    variable stubs
-    upvar $textVar text
-
-    append text "\n/*\n * Exported function declarations:\n */\n\n"
-    forAllStubs $name makeDecl 0 text
-    return
-}
-
-# genStubs::emitMacros --
-#
-#	This function emits the inline macros for an interface.
-#
-# Arguments:
-#	name	The name of the interface being emitted.
-#	textVar	The variable to use for output.
-#
-# Results:
-#	None.
-
-proc genStubs::emitMacros {name textVar} {
-    variable stubs
-    variable libraryName
-    upvar $textVar text
-
-    set upName [string toupper $libraryName]
-    append text "\n#if defined(USE_${upName}_STUBS) && !defined(USE_${upName}_STUB_PROCS)\n"
-    append text "\n/*\n * Inline function declarations:\n */\n\n"
-    
-    forAllStubs $name makeMacro 0 text
-
-    append text "\n#endif /* defined(USE_${upName}_STUBS) && !defined(USE_${upName}_STUB_PROCS) */\n"
-    return
-}
-
-# genStubs::emitHeader --
-#
-#	This function emits the body of the <name>Decls.h file for
-#	the specified interface.
-#
-# Arguments:
-#	name	The name of the interface being emitted.
-#
-# Results:
-#	None.
-
-proc genStubs::emitHeader {name} {
-    variable outDir
-    variable hooks
-
-    set capName [string toupper [string index $name 0]]
-    append capName [string range $name 1 end]
-
-    emitDeclarations $name text
-
-    if {[info exists hooks($name)]} {
-	append text "\ntypedef struct ${capName}StubHooks {\n"
-	foreach hook $hooks($name) {
-	    set capHook [string toupper [string index $hook 0]]
-	    append capHook [string range $hook 1 end]
-	    append text "    struct ${capHook}Stubs *${hook}Stubs;\n"
-	}
-	append text "} ${capName}StubHooks;\n"
-    }
-    append text "\ntypedef struct ${capName}Stubs {\n"
-    append text "    int magic;\n"
-    append text "    struct ${capName}StubHooks *hooks;\n\n"
-
-    emitSlots $name text
-
-    append text "} ${capName}Stubs;\n"
-
-    append text "\n#ifdef __cplusplus\nextern \"C\" {\n#endif\n"
-    append text "extern ${capName}Stubs *${name}StubsPtr;\n"
-    append text "#ifdef __cplusplus\n}\n#endif\n"
-
-    emitMacros $name text
-
-    rewriteFile [file join $outDir ${name}Decls.h] $text
-    return
-}
-
-# genStubs::emitStubs --
-#
-#	This function emits the body of the <name>Stubs.c file for
-#	the specified interface.
-#
-# Arguments:
-#	name	The name of the interface being emitted.
-#
-# Results:
-#	None.
-
-proc genStubs::emitStubs {name} {
-    variable outDir
-
-    append text "\n/*\n * Exported stub functions:\n */\n\n"
-    forAllStubs $name makeStub 0 text
-
-    rewriteFile [file join $outDir ${name}Stubs.c] $text
-    return    
-}
-
-# genStubs::emitInit --
-#
-#	Generate the table initializers for an interface.
-#
-# Arguments:
-#	name		The name of the interface to initialize.
-#	textVar		The variable to use for output.
-#
-# Results:
-#	Returns the formatted output.
-
-proc genStubs::emitInit {name textVar} {
-    variable stubs
-    variable hooks
-    upvar $textVar text
-
-    set capName [string toupper [string index $name 0]]
-    append capName [string range $name 1 end]
-
-    if {[info exists hooks($name)]} {
- 	append text "\nstatic ${capName}StubHooks ${name}StubHooks = \{\n"
-	set sep "    "
-	foreach sub $hooks($name) {
-	    append text $sep "&${sub}Stubs"
-	    set sep ",\n    "
-	}
-	append text "\n\};\n"
-    }
-    append text "\n${capName}Stubs ${name}Stubs = \{\n"
-    append text "    TCL_STUB_MAGIC,\n"
-    if {[info exists hooks($name)]} {
-	append text "    &${name}StubHooks,\n"
-    } else {
-	append text "    NULL,\n"
-    }
-    
-    forAllStubs $name makeInit 1 text {"    NULL, /* $i */\n"}
-
-    append text "\};\n"
-    return
-}
-
-# genStubs::emitInits --
-#
-#	This function emits the body of the <name>StubInit.c file for
-#	the specified interface.
-#
-# Arguments:
-#	name	The name of the interface being emitted.
-#
-# Results:
-#	None.
-
-proc genStubs::emitInits {} {
-    variable hooks
-    variable outDir
-    variable libraryName
-    variable interfaces
-
-    # Assuming that dependencies only go one level deep, we need to emit
-    # all of the leaves first to avoid needing forward declarations.
-
-    set leaves {}
-    set roots {}
-    foreach name [lsort [array names interfaces]] {
-	if {[info exists hooks($name)]} {
-	    lappend roots $name
-	} else {
-	    lappend leaves $name
-	}
-    }
-    foreach name $leaves {
-	emitInit $name text
-    }
-    foreach name $roots {
-	emitInit $name text
-    }
-
-    rewriteFile [file join $outDir ${libraryName}StubInit.c] $text
-}
-
-# genStubs::init --
-#
-#	This is the main entry point.
-#
-# Arguments:
-#	None.
-#
-# Results:
-#	None.
-
-proc genStubs::init {} {
-    global argv argv0
-    variable outDir
-    variable interfaces
-
-    if {[llength $argv] < 2} {
-	puts stderr "usage: $argv0 outDir declFile ?declFile...?"
-	exit 1
-    }
-
-    set outDir [lindex $argv 0]
-
-    foreach file [lrange $argv 1 end] {
-	source $file
-    }
-
-    foreach name [lsort [array names interfaces]] {
-	puts "Emitting $name"
-	emitHeader $name
-    }
-
-    emitInits
-}
-
-# lassign --
-#
-#	This function emulates the TclX lassign command.
-#
-# Arguments:
-#	valueList	A list containing the values to be assigned.
-#	args		The list of variables to be assigned.
-#
-# Results:
-#	Returns any values that were not assigned to variables.
-
-proc lassign {valueList args} {
-  if {[llength $args] == 0} {
-      error "wrong # args: lassign list varname ?varname..?"
-  }
-
-  uplevel [list foreach $args $valueList {break}]
-  return [lrange $valueList [llength $args] end]
-}
-
-genStubs::init
diff --git a/tclxml-3.2/win/build.data b/tclxml-3.2/win/build.data
deleted file mode 100755
index 1a4072a..0000000
--- a/tclxml-3.2/win/build.data
+++ /dev/null
@@ -1,28 +0,0 @@
-# build.data --
-#
-
-    macro exec_prefix            {${prefix}}
-    macro program_transform_name {s,x,x,}
-    macro bindir                 {${exec_prefix}/bin}
-    macro sbindir                {${exec_prefix}/sbin}
-    macro libexecdir             {${exec_prefix}/libexec}
-    macro datadir                {${prefix}/share}
-    macro sysconfdir             {${prefix}/etc}
-    macro sharedstatedir         {${prefix}/com}
-    macro localstatedir          {${prefix}/var}
-    macro libdir                 {${exec_prefix}/lib}
-    macro includedir             {${prefix}/include}
-    macro infodir                {${prefix}/info}
-    macro mandir                 {${prefix}/man}
-
-    macro PACKAGE {tclxml}
-    macro VERSION {$::Installer::Version}
-
-    macro OBJEXT {obj}
-
-    macro RELPATH            {..}
-    macro TCLXML_LIB_FILE    {tclxml.dll}
-    macro expat_TCL_LIB_FILE {tclexpat.dll}
-    macro BUILD_expat        {yes}
-    macro expat_TCL_LIB_NAME {tclexpat}
-    macro BUILD_xerces       {no}
diff --git a/tclxml-3.2/win/makefile.vc b/tclxml-3.2/win/makefile.vc
deleted file mode 100644
index ae15eb8..0000000
--- a/tclxml-3.2/win/makefile.vc
+++ /dev/null
@@ -1,564 +0,0 @@
-# makefile.vc --                                               -*- Makefile -*-
-#
-# Microsoft Visual C++ makefile for use with nmake.exe v1.62+ (VC++ 5.0+)
-#
-# This makefile is based upon the Tcl 8.4 Makefile.vc and modified to 
-# make it suitable as a general package makefile. Look for the word EDIT
-# which marks sections that may need modification. As a minumum you will
-# need to change the PROJECT, DOTVERSION and DLLOBJS variables to values
-# relevant to your package.
-#
-# See the file "license.terms" for information on usage and redistribution
-# of this file, and for a DISCLAIMER OF ALL WARRANTIES.
-# 
-# Copyright (c) 1995-1996 Sun Microsystems, Inc.
-# Copyright (c) 1998-2000 Ajuba Solutions.
-# Copyright (c) 2001 ActiveState Corporation.
-# Copyright (c) 2001-2002 David Gravereaux.
-# Copyright (c) 2003 Pat Thoyts
-# Copyright (c) 2004 Zveno Pty Ltd
-#
-#-------------------------------------------------------------------------
-# RCS: @(#)$Id: makefile.vc,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-#-------------------------------------------------------------------------
-
-!if "$(MSVCDIR)" == ""
-MSG = ^
-You will need to run vcvars32.bat from Developer Studio, first, to setup^
-the environment.  Jump to this line to read the new instructions.
-!error $(MSG)
-!endif
-
-#------------------------------------------------------------------------------
-# HOW TO USE this makefile:
-#
-# 1)  It is now necessary to have %MSVCDir% set in the environment.  This is
-#     used  as a check to see if vcvars32.bat had been run prior to running
-#     nmake or during the installation of Microsoft Visual C++, MSVCDir had
-#     been set globally and the PATH adjusted.  Either way is valid.
-#
-#     You'll need to run vcvars32.bat contained in the MsDev's vc(98)/bin
-#     directory to setup the proper environment, if needed, for your current
-#     setup.  This is a needed bootstrap requirement and allows the swapping of
-#     different environments to be easier.
-#
-# 2)  To use the Platform SDK (not expressly needed), run setenv.bat after
-#     vcvars32.bat according to the instructions for it.  This can also turn on
-#     the 64-bit compiler, if your SDK has it.
-#
-# 3)  Targets are:
-#	all       -- Builds everything.
-#       <project> -- Builds the project (eg: nmake sample)
-#	test      -- Builds and runs the test suite.
-#	install   -- Installs the built binaries and libraries to $(INSTALLDIR)
-#		     in an appropriate subdirectory.
-#	clean/realclean/distclean -- varying levels of cleaning.
-#
-# 4)  Macros usable on the commandline:
-#	INSTALLDIR=<path>
-#		Sets where to install Tcl from the built binaries.
-#		C:\Progra~1\Tcl is assumed when not specified.
-#
-#	OPTS=static,msvcrt,staticpkg,threads,symbols,profile,loimpact,none
-#		Sets special options for the core.  The default is for none.
-#		Any combination of the above may be used (comma separated).
-#		'none' will over-ride everything to nothing.
-#
-#		static  =  Builds a static library of the core instead of a
-#			   dll.  The shell will be static (and large), as well.
-#		msvcrt  =  Effects the static option only to switch it from
-#			   using libcmt(d) as the C runtime [by default] to
-#			   msvcrt(d). This is useful for static embedding
-#			   support.
-#		staticpkg = Effects the static option only to switch
-#			   tclshXX.exe to have the dde and reg extension linked
-#			   inside it.
-#		threads =  Turns on full multithreading support.
-#		thrdalloc = Use the thread allocator (shared global free pool).
-#		symbols =  Adds symbols for step debugging.
-#		profile =  Adds profiling hooks.  Map file is assumed.
-#		loimpact =  Adds a flag for how NT treats the heap to keep memory
-#			   in use, low.  This is said to impact alloc performance.
-#
-#	STATS=memdbg,compdbg,none
-#		Sets optional memory and bytecode compiler debugging code added
-#		to the core.  The default is for none.  Any combination of the
-#		above may be used (comma separated).  'none' will over-ride
-#		everything to nothing.
-#
-#		memdbg   = Enables the debugging memory allocator.
-#		compdbg  = Enables byte compilation logging.
-#
-#	MACHINE=(IX86|IA64|ALPHA)
-#		Set the machine type used for the compiler, linker, and
-#		resource compiler.  This hook is needed to tell the tools
-#		when alternate platforms are requested.  IX86 is the default
-#		when not specified.
-#
-#	TMP_DIR=<path>
-#	OUT_DIR=<path>
-#		Hooks to allow the intermediate and output directories to be
-#		changed.  $(OUT_DIR) is assumed to be 
-#		$(BINROOT)\(Release|Debug) based on if symbols are requested.
-#		$(TMP_DIR) will de $(OUT_DIR)\<buildtype> by default.
-#
-#	TESTPAT=<file>
-#		Reads the tests requested to be run from this file.
-#
-#	CFG_ENCODING=encoding
-#		name of encoding for configuration information. Defaults
-#		to cp1252
-#
-# 5)  Examples:
-#
-#	Basic syntax of calling nmake looks like this:
-#	nmake [-nologo] -f makefile.vc [target|macrodef [target|macrodef] [...]]
-#
-#                        Standard (no frills)
-#       c:\tcl_src\win\>c:\progra~1\micros~1\vc98\bin\vcvars32.bat
-#       Setting environment for using Microsoft Visual C++ tools.
-#       c:\tcl_src\win\>nmake -f makefile.vc all
-#       c:\tcl_src\win\>nmake -f makefile.vc install INSTALLDIR=c:\progra~1\tcl
-#
-#                         Building for Win64
-#       c:\tcl_src\win\>c:\progra~1\micros~1\vc98\bin\vcvars32.bat
-#       Setting environment for using Microsoft Visual C++ tools.
-#       c:\tcl_src\win\>c:\progra~1\platfo~1\setenv.bat /pre64 /RETAIL
-#       Targeting Windows pre64 RETAIL
-#       c:\tcl_src\win\>nmake -f makefile.vc MACHINE=IA64
-#
-#------------------------------------------------------------------------------
-#==============================================================================
-###############################################################################
-#------------------------------------------------------------------------------
-
-!if !exist("makefile.vc")
-MSG = ^
-You must run this makefile only from the directory it is in.^
-Please `cd` to its location first.
-!error $(MSG)
-!endif
-
-#-------------------------------------------------------------------------
-# Project specific information (EDIT)
-#
-# You should edit this with the name and version of your project. This
-# information is used to generate the name of the package library and
-# it's install location.
-#
-# For example, the sample extension is  going to build sample04.dll and
-# would install it into $(INSTALLDIR)\lib\sample04
-#
-# You need to specify the object files that need to be linked into your
-# binary here.
-#
-#-------------------------------------------------------------------------
-
-PROJECT = Tclxml
-!include "rules.vc"
-
-DOTVERSION      = 3.1
-VERSION         = $(DOTVERSION:.=)
-STUBPREFIX      = $(PROJECT)stub
-
-#-- Use this line for VC++ 6.0
-#WSOCKLIB = "C:\Program Files\Microsoft Visual Studio\VC98\Lib\WSOCK32.LIB"
-#-- Use this line for VC++ .NET 2003
-WSOCKLIB = "C:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\PlatformSDK\Lib\WSOCK32.LIB"
-
-DLLOBJS = \
-	$(TMP_DIR)\tclxml.obj
-PRJSTUBOBJS = \
-	$(TMP_DIR)\tclxmlStubInit.obj \
-	$(TMP_DIR)\tclxmlStubLib.obj
-EXPATDLLOBJS = \
-	$(TMP_DIR)\tclexpat.obj \
-	$(TMP_DIR)\xmltok.obj \
-	$(TMP_DIR)\xmlrole.obj \
-	$(TMP_DIR)\xmlwf.obj \
-	$(TMP_DIR)\xmlfile.obj \
-	$(TMP_DIR)\codepage.obj \
-	$(TMP_DIR)\hashtable.obj \
-	$(TMP_DIR)\win32filemap.obj \
-	$(TMP_DIR)\xmlparse.obj
-LIBXML2DLLOBJS = \
-	$(TMP_DIR)\tcllibxml2.obj \
-	$(TMP_DIR)\docObj.obj
-LIBXML2STUBOBJS = \
-	$(TMP_DIR)\tcllibxml2StubInit.obj
-
-#-------------------------------------------------------------------------
-# Target names and paths ( shouldn't need changing )
-#-------------------------------------------------------------------------
-
-BINROOT		= .
-ROOT            = ..
-
-PRJIMPLIB	= $(OUT_DIR)\$(PROJECT)$(VERSION)$(SUFX).lib
-PRJLIBNAME	= $(PROJECT)$(VERSION)$(SUFX).$(EXT)
-PRJLIB		= $(OUT_DIR)\$(PRJLIBNAME)
-
-PRJSTUBLIBNAME	= $(STUBPREFIX)$(VERSION).lib
-PRJSTUBLIB	= $(OUT_DIR)\$(PRJSTUBLIBNAME)
-
-EXPATIMPLIB     = $(OUT_DIR)\expat$(VERSION)$(SUFX).lib
-EXPATLIBNAME    = expat$(VERSION)$(SUFX).$(EXT)
-EXPATLIB        = $(OUT_DIR)\$(EXPATLIBNAME)
-
-EXPATSTUBLIBNAME = expatstub$(VERSION).lib
-EXPATSTUBLIB    = $(OUT_DIR)\$(EXPATSTUBLIBNAME)
-
-LIBXML2IMPLIB   = $(OUT_DIR)\tcllibxml2$(VERSION)$(SUFX).lib
-LIBXML2LIBNAME  = tcllibxml2$(VERSION)$(SUFX).$(EXT)
-LIBXML2LIB      = $(OUT_DIR)\$(LIBXML2LIBNAME)
-
-LIBXML2STUBLIBNAME = tcllibxml2stub$(VERSION).lib
-LIBXML2STUBLIB  = $(OUT_DIR)\$(LIBXML2STUBLIBNAME)
-
-### Make sure we use backslash only.
-LIB_INSTALL_DIR		= $(_INSTALLDIR)\lib
-BIN_INSTALL_DIR		= $(_INSTALLDIR)\bin
-DOC_INSTALL_DIR		= $(_INSTALLDIR)\doc
-SCRIPT_INSTALL_DIR	= $(_INSTALLDIR)\lib\$(PROJECT)$(DOTVERSION)
-EXPAT_INSTALL_DIR       = $(_INSTALLDIR)\lib\Tclexpat$(DOTVERSION)
-LIBXML2_INSTALL_DIR     = $(_INSTALLDIR)\lib\Tcllibxml$(DOTVERSION)
-INCLUDE_INSTALL_DIR	= $(_INSTALLDIR)\include
-
-### The following paths CANNOT have spaces in them.
-GENERICDIR	= $(ROOT)
-EXPATDIR        = $(ROOT)\expat
-TCLLIBXML2DIR   = $(ROOT)\libxml2
-WINDIR		= $(ROOT)\win
-LIBDIR          = $(ROOT)\library
-DOCDIR		= $(ROOT)\doc
-TOOLSDIR	= $(ROOT)\tools
-COMPATDIR	= $(ROOT)\compat
-INCLUDEDIR      = $(ROOT)\include
-
-### Find a tclsh for testing and installation.
-!if !exist("$(TCLSH)")
-TCLSH           = $(BIN_INSTALL_DIR)\tclsh$(TCL_VERSION).exe
-!endif
-
-#---------------------------------------------------------------------
-# Compile flags
-#---------------------------------------------------------------------
-
-!if !$(DEBUG)
-!if $(OPTIMIZING)
-### This cranks the optimization level to maximize speed
-cdebug	= -O2 -Op -Gs
-!else
-cdebug	=
-!endif
-!else if "$(MACHINE)" == "IA64"
-### Warnings are too many, can't support warnings into errors.
-cdebug	= -Z7 -Od
-!else
-cdebug	= -Z7 -WX -Od
-!endif
-
-### Declarations common to all compiler options
-cflags = -nologo -c -W3 -YX -Fp$(TMP_DIR)^\
-
-!if $(PENT_0F_ERRATA)
-cflags = $(cflags) -QI0f
-!endif
-
-!if $(ITAN_B_ERRATA)
-cflags = $(cflags) -QIA64_Bx
-!endif
-
-!if $(MSVCRT)
-!if $(DEBUG)
-crt = -MDd
-!else
-crt = -MD
-!endif
-!else
-!if $(DEBUG)
-crt = -MTd
-!else
-crt = -MT
-!endif
-!endif
-
-#----------------------------------------------------------
-# TclXML/libxml2 needs libz, libiconv and libxml2 headers
-#----------------------------------------------------------
-
-!if !defined(LIBZDIR)
-MSG=^
-Don't know where libz is.  Set the LIBZDIR macro.
-!error $(MSG)
-!else
-_LIBZDIR = $(LIBZDIR:/=\)
-!if !exist("$(_LIBZDIR)\include\zlib.h")
-MSG=^
-Don't know where zlib.h is.  The LIBZDIR macro doesn't appear to be correct.
-!error $(MSG)
-!endif
-!endif
-
-!if !defined(LIBICONVDIR)
-MSG=^
-Don't know where libiconv is.  Set the LIBICONVDIR macro.
-!error $(MSG)
-!else
-_LIBICONVDIR = $(LIBICONVDIR:/=\)
-!if !exist("$(_LIBICONVDIR)\include\iconv.h")
-MSG=^
-Don't know where iconv.h is.  The LIBICONVDIR macro doesn't appear to be correct.
-!error $(MSG)
-!endif
-!endif
-
-!if !defined(LIBXML2DIR)
-MSG=^
-Don't know where libxml2 is.  Set the LIBXML2DIR macro.
-!error $(MSG)
-!else
-_LIBXML2DIR = $(LIBXML2DIR:/=\)
-!if !exist("$(_LIBXML2DIR)\include\libxml\tree.h")
-MSG=^
-Don't know where libxml2 tree.h is.  The LIBXML2DIR macro doesn't appear to be correct.
-!error $(MSG)
-!endif
-!endif
-
-TCL_INCLUDES	= -I"$(TCLDIR)\include" -I"$(WINDIR)" -I"$(GENERICDIR)"
-EXPAT_INCLUDES  = -I"$(EXPATDIR)\xmlparse" -I"$(EXPATDIR)\xmltok"
-LIBXML2_INCLUDES = -I"$(LIBZDIR)\include" -I"$(LIBICONVDIR)\include" -I"$(LIBXML2DIR)\include"
-BASE_CLFAGS	= $(cflags) $(cdebug) $(crt) $(TCL_INCLUDES) -I"..\include"
-CON_CFLAGS	= $(cflags) $(cdebug) $(crt) -DCONSOLE
-TCL_CFLAGS	= -DUSE_TCL_STUBS -DVERSION="\"$(DOTVERSION)\"" $(BASE_CLFAGS) $(OPTDEFINES)
-LIBXML2_CFLAGS  = -DTCLXML_LIBXML2_VERSION="\"$(DOTVERSION)\""
-
-#---------------------------------------------------------------------
-# Link flags
-#---------------------------------------------------------------------
-
-!if $(DEBUG)
-ldebug	= -debug:full -debugtype:cv
-!else
-ldebug	= -release -opt:ref -opt:icf,3
-!endif
-
-### Declarations common to all linker options
-lflags	= -nologo -machine:$(MACHINE) $(ldebug)
-
-!if $(PROFILE)
-lflags	= $(lflags) -profile
-!endif
-
-!if $(ALIGN98_HACK) && !$(STATIC_BUILD)
-### Align sections for PE size savings.
-lflags	= $(lflags) -opt:nowin98
-!else if !$(ALIGN98_HACK) && $(STATIC_BUILD)
-### Align sections for speed in loading by choosing the virtual page size.
-lflags	= $(lflags) -align:4096
-!endif
-
-!if $(LOIMPACT)
-lflags	= $(lflags) -ws:aggressive
-!endif
-
-dlllflags = $(lflags) -dll
-conlflags = $(lflags) -subsystem:console
-guilflags = $(lflags) -subsystem:windows
-baselibs   = $(TCLSTUBLIB)
-
-#---------------------------------------------------------------------
-# TclTest flags
-#---------------------------------------------------------------------
-
-!IF "$(TESTPAT)" != ""
-TESTFLAGS = -file $(TESTPAT)
-!ENDIF
-
-#---------------------------------------------------------------------
-# Project specific targets (EDIT)
-#---------------------------------------------------------------------
-
-all:	    setup $(PROJECT)
-$(PROJECT): setup $(PRJLIB) $(EXPATLIB) $(LIBXML2LIB)
-install:    install-binaries install-includes install-libraries install-docs
-
-
-test: setup $(PROJECT)
-	set TCL_LIBRARY=$(ROOT)/library
-!if "$(OS)" == "Windows_NT"  || "$(MSVCDIR)" == "IDE"
-	$(TCLSH) "$(ROOT)/tests/all.tcl" $(TESTFLAGS)
-!else
-	@echo Please wait while the tests are collected...
-	$(TCLSH) "$(ROOT)/tests/all.tcl" $(TESTFLAGS) > tests.log
-	type tests.log | more
-!endif
-
-setup:
-	@if not exist $(OUT_DIR)\nul mkdir $(OUT_DIR)
-	@if not exist $(TMP_DIR)\nul mkdir $(TMP_DIR)
-
-$(PRJLIB): $(DLLOBJS) $(PRJSTUBOBJS)
-	$(link32) $(dlllflags) -out:$@ $(baselibs) $(DLLOBJS) $(PRJSTUBOBJS)
-	- at del $*.exp
-
-$(EXPATLIB): $(EXPATDLLOBJS)
-	$(link32) $(dlllflags) -out:$@ $(baselibs) $(PRJIMPLIB) @<<
-$**
-<<
-	- at del $*.exp
-
-$(LIBXML2LIB): $(LIBXML2DLLOBJS)
-	$(link32) $(dlllflags) -out:$@ $(baselibs) $(PRJIMPLIB) $(LIBZDIR)\lib\zlib.lib $(LIBICONVDIR)\lib\iconv.lib $(LIBXML2DIR)\lib\libxml2.lib $(WSOCKLIB) @<<
-$**
-<<
-	- at del $*.exp
-
-$(PRJSTUBLIB): $(PRJSTUBOBJS)
-	$(lib32) -nologo -out:$@ $(PRJSTUBOBJS)
-$(EXPATSTUBLIB): $(EXPATSTUBOBJS)
-	$(lib32) -nologo -out:$@ $(EXPATSTUBOBJS)
-$(LIBXML2STUBLIB): $(LIBXML2STUBOBJS)
-	$(lib32) -nologo -out:$@ $(LIBXML2STUBOBJS)
-
-#---------------------------------------------------------------------
-# Special case object file targets
-#---------------------------------------------------------------------
-
-$(TMP_DIR)\tclxml.obj: $(GENERICDIR)\tclxml.c
-    $(cc32) $(TCL_CFLAGS) -DBUILD_$(PROJECT) -Fo$@ $?
-
-$(TMP_DIR)\tclexpat.obj: $(GENERICDIR)\tclexpat.c
-    $(cc32) $(TCL_CFLAGS) $(EXPAT_INCLUDES) -DBUILD_$(PROJECT) -Fo$@ $?
-
-$(TMP_DIR)\xmltok.obj: $(EXPATDIR)\xmltok\xmltok.c
-    $(cc32) $(TCL_CFLAGS) -DBUILD_$(PROJECT) -Fo$@ $?
-
-$(TMP_DIR)\xmlrole.obj: $(EXPATDIR)\xmltok\xmlrole.c
-    $(cc32) $(TCL_CFLAGS) -DBUILD_$(PROJECT) -Fo$@ $?
-
-$(TMP_DIR)\xmlwf.obj: $(EXPATDIR)\xmlwf\xmlwf.c
-    $(cc32) $(TCL_CFLAGS) $(EXPAT_INCLUDES) -DBUILD_$(PROJECT) -Fo$@ $?
-
-$(TMP_DIR)\xmlfile.obj: $(EXPATDIR)\xmlwf\xmlfile.c
-    $(cc32) $(TCL_CFLAGS) $(EXPAT_INCLUDES) -DBUILD_$(PROJECT) -Fo$@ $?
-
-$(TMP_DIR)\codepage.obj: $(EXPATDIR)\xmlwf\codepage.c
-    $(cc32) $(TCL_CFLAGS) -DBUILD_$(PROJECT) -Fo$@ $?
-
-$(TMP_DIR)\hashtable.obj: $(EXPATDIR)\xmlparse\hashtable.c
-    $(cc32) $(TCL_CFLAGS) $(EXPAT_INCLUDES) -DBUILD_$(PROJECT) -Fo$@ $?
-
-$(TMP_DIR)\win32filemap.obj: $(EXPATDIR)\xmlwf\win32filemap.c
-    $(cc32) $(TCL_CFLAGS) -DBUILD_$(PROJECT) -Fo$@ $?
-
-$(TMP_DIR)\xmlparse.obj: $(EXPATDIR)\xmlparse\xmlparse.c
-    $(cc32) $(TCL_CFLAGS) $(EXPAT_INCLUDES) -DBUILD_$(PROJECT) -Fo$@ $?
-
-$(TMP_DIR)\tcllibxml2.obj: $(TCLLIBXML2DIR)\tcllibxml2.c
-    $(cc32) $(TCL_CFLAGS) $(LIBXML2_CFLAGS) $(LIBXML2_INCLUDES) -DBUILD_TclXML_libxml2 -Fo$@ $?
-
-$(TMP_DIR)\docObj.obj: $(TCLLIBXML2DIR)\docObj.c
-    $(cc32) $(TCL_CFLAGS) $(LIBXML2_CFLAGS) $(LIBXML2_INCLUDES) -DBUILD_TclXML_libxml2 -Fo$@ $?
-
-$(TMP_DIR)\tcllibxml2StubInit.obj: $(TCLLIBXML2DIR)\tcllibxml2StubInit.c
-    $(cc32) $(TCL_CFLAGS) $(LIBXML2_CFLAGS) $(LIBXML2_INCLUDES) -DBUILD_TclXML_libxml2 -Fo$@ $?
-
-#---------------------------------------------------------------------
-# Implicit rules
-#---------------------------------------------------------------------
-
-{$(WINDIR)}.c{$(TMP_DIR)}.obj::
-    $(cc32) $(TCL_CFLAGS) -DBUILD_$(PROJECT) -Fo$(TMP_DIR)\ @<<
-$<
-<<
-
-{$(GENERICDIR)}.c{$(TMP_DIR)}.obj::
-    $(cc32) $(TCL_CFLAGS) -DBUILD_$(PROJECT) -Fo$(TMP_DIR)\ @<<
-$<
-<<
-
-{$(COMPATDIR)}.c{$(TMP_DIR)}.obj::
-    $(cc32) $(TCL_CFLAGS) -DBUILD_$(PROJECT) -Fo$(TMP_DIR)\ @<<
-$<
-<<
-
-{$(WINDIR)}.rc{$(TMP_DIR)}.res:
-	$(rc32) -fo $@ -r -i "$(GENERICDIR)" -D__WIN32__ \
-!if $(DEBUG)
-	-d DEBUG \
-!endif
-!if $(TCL_THREADS)
-	-d TCL_THREADS \
-!endif
-!if $(STATIC_BUILD)
-	-d STATIC_BUILD \
-!endif
-	$<
-
-.SUFFIXES:
-.SUFFIXES:.c .rc
-
-#---------------------------------------------------------------------
-# Installation. (EDIT)
-#
-# You may need to modify this section to reflect the final distribution
-# of your files and possibly to generate documentation.
-#
-#---------------------------------------------------------------------
-
-install-binaries: install-tclxml-binaries install-expat-binaries install-libxml2-binaries
-	@echo Installing to '$(SCRIPT_INSTALL_DIR)'
-
-install-tclxml-binaries:
-	@if not exist $(SCRIPT_INSTALL_DIR)\nul mkdir $(SCRIPT_INSTALL_DIR)
-	$(CPY) $(PRJLIB) $(SCRIPT_INSTALL_DIR)
-	$(CPY) $(PRJIMPLIB) $(SCRIPT_INSTALL_DIR)
-
-install-expat-binaries:
-	@if not exist $(EXPAT_INSTALL_DIR)\nul mkdir $(EXPAT_INSTALL_DIR)
-	$(CPY) $(EXPATLIB) $(EXPAT_INSTALL_DIR)
-	$(CPY) $(EXPATIMPLIB) $(EXPAT_INSTALL_DIR)
-	@echo package ifneeded xml::expat $(DOTVERSION)  [list load [file join $$dir $(EXPATLIBNAME)]] > $(EXPAT_INSTALL_DIR)\pkgIndex.tcl
-
-install-libxml2-binaries:
-	@if not exist $(LIBXML2_INSTALL_DIR)\nul mkdir $(LIBXML2_INSTALL_DIR)
-	$(CPY) $(LIBXML2LIB) $(LIBXML2_INSTALL_DIR)
-	$(CPY) $(LIBXML2IMPLIB) $(LIBXML2_INSTALL_DIR)
-	@echo package ifneeded xml::libxml2 $(DOTVERSION)  [list load [file join $$dir $(LIBXML2LIBNAME)] Tclxml_libxml2] > $(LIBXML2_INSTALL_DIR)\pkgIndex.tcl
-
-install-includes: install-tclxml-includes install-expat-includes install-libxml2-includes
-	@echo Installing to '$(INCLUDE_INSTALL_DIR)'
-	@if not exist $(INCLUDE_INSTALL_DIR)\nul mkdir $(INCLUDE_INSTALL_DIR)
-
-install-tclxml-includes:
-	@if not exist $(INCLUDE_INSTALL_DIR)\tclxml\nul mkdir $(INCLUDE_INSTALL_DIR)\tclxml
-	$(CPY) $(INCLUDEDIR)\tclxml\*.h $(INCLUDE_INSTALL_DIR)\tclxml
-
-install-expat-includes:
-
-install-libxml2-includes:
-	@if not exist $(INCLUDE_INSTALL_DIR)\tclxml-libxml2\nul mkdir $(INCLUDE_INSTALL_DIR)\tclxml-libxml2
-	$(CPY) $(INCLUDEDIR)\tclxml-libxml2\*.h $(INCLUDE_INSTALL_DIR)\tclxml-libxml2
-
-install-libraries:
-	@echo Installing to '$(SCRIPT_INSTALL_DIR)'
-	@if exist $(LIBDIR)\nul $(CPY) $(LIBDIR)\*.tcl $(SCRIPT_INSTALL_DIR)
-	$(TCLSH) $(WINDIR)\mkPkgIndex.tcl $(LIBDIR)\pkgIndex.tcl.in $(SCRIPT_INSTALL_DIR)\pkgIndex.tcl VERSION=$(DOTVERSION) Tclxml_LIB_FILE=$(PRJLIBNAME)
-
-install-docs:
-
-#---------------------------------------------------------------------
-# Clean up
-#---------------------------------------------------------------------
-
-clean:
-	@if exist $(TMP_DIR)\nul $(RMDIR) $(TMP_DIR)
-
-realclean: clean
-	@if exist $(OUT_DIR)\nul $(RMDIR) $(OUT_DIR)
-
-distclean: realclean
-	@if exist $(WINDIR)\nmakehlp.exe del $(WINDIR)\nmakehlp.exe
-	@if exist $(WINDIR)\nmakehlp.obj del $(WINDIR)\nmakehlp.obj
diff --git a/tclxml-3.2/win/mkPkgIndex.tcl b/tclxml-3.2/win/mkPkgIndex.tcl
deleted file mode 100644
index 63b8e12..0000000
--- a/tclxml-3.2/win/mkPkgIndex.tcl
+++ /dev/null
@@ -1,31 +0,0 @@
-# mkPkgIndex.tcl --
-#
-#	Helper script for non-TEA installion on Windows.
-#	This script resolves configure symbols.
-#
-# Copyright (c) 2003 Zveno Pty Ltd
-# http://www.zveno.com/
-#
-# See the file "LICENSE" in this distribution for information on usage and
-# redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
-#
-# $Id: mkPkgIndex.tcl,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-
-set infile [lindex $argv 0]
-set outfile [lindex $argv 1]
-
-set ch [open $infile]
-set script [read $ch]
-close $ch
-
-set ch [open $outfile w]
-
-foreach parameter [lrange $argv 2 end] {
-    regexp {^([^=]+)=(.*)$} $parameter dummy name value
-    regsub -all @${name}@ $script $value script
-}
-
-puts $ch $script
-close $ch
-
-exit 0
diff --git a/tclxml-3.2/win/nmakehlp.c b/tclxml-3.2/win/nmakehlp.c
deleted file mode 100644
index f8c7ea0..0000000
--- a/tclxml-3.2/win/nmakehlp.c
+++ /dev/null
@@ -1,297 +0,0 @@
-/* ----------------------------------------------------------------------------
- * nmakehlp.c --
- *
- *	This is used to fix limitations within nmake and the environment.
- *
- * Copyright (c) 2002 by David Gravereaux.
- *
- * See the file "license.terms" for information on usage and redistribution
- * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
- *
- * ----------------------------------------------------------------------------
- * RCS: @(#) $Id: nmakehlp.c,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
- * ----------------------------------------------------------------------------
- */
-#include <windows.h>
-#pragma comment (lib, "user32.lib")
-#pragma comment (lib, "kernel32.lib")
-
-/* protos */
-int CheckForCompilerFeature (const char *option);
-int CheckForLinkerFeature (const char *option);
-int IsIn (const char *string, const char *substring);
-DWORD WINAPI ReadFromPipe (LPVOID args);
-
-/* globals */
-typedef struct {
-    HANDLE pipe;
-    char buffer[1000];
-} pipeinfo;
-
-pipeinfo Out = {INVALID_HANDLE_VALUE, '\0'};
-pipeinfo Err = {INVALID_HANDLE_VALUE, '\0'};
-
-
-
-/* exitcodes: 0 == no, 1 == yes, 2 == error */
-int
-main (int argc, char *argv[])
-{
-    char msg[300];
-    DWORD dwWritten;
-    int chars;
-
-    if (argc > 1 && *argv[1] == '-') {
-	switch (*(argv[1]+1)) {
-	case 'c':
-	    if (argc != 3) {
-		chars = wsprintf(msg, "usage: %s -c <compiler option>\n"
-			"Tests for whether cl.exe supports an option\n"
-			"exitcodes: 0 == no, 1 == yes, 2 == error\n", argv[0]);
-		WriteFile(GetStdHandle(STD_ERROR_HANDLE), msg, chars, &dwWritten, NULL);
-		return 2;
-	    }
-	    return CheckForCompilerFeature(argv[2]);
-	case 'l':
-	    if (argc != 3) {
-		chars = wsprintf(msg, "usage: %s -l <linker option>\n"
-			"Tests for whether link.exe supports an option\n"
-			"exitcodes: 0 == no, 1 == yes, 2 == error\n", argv[0]);
-		WriteFile(GetStdHandle(STD_ERROR_HANDLE), msg, chars, &dwWritten, NULL);
-		return 2;
-	    }
-	    return CheckForLinkerFeature(argv[2]);
-	case 'f':
-	    if (argc == 2) {
-		chars = wsprintf(msg, "usage: %s -f <string> <substring>\n"
-		    "Find a substring within another\n"
-		    "exitcodes: 0 == no, 1 == yes, 2 == error\n", argv[0]);
-		WriteFile(GetStdHandle(STD_ERROR_HANDLE), msg, chars, &dwWritten, NULL);
-		return 2;
-	    } else if (argc == 3) {
-		/* if the string is blank, there is no match */
-		return 0;
-	    } else {
-		return IsIn(argv[2], argv[3]);
-	    }
-	}
-    }
-    chars = wsprintf(msg, "usage: %s -c|-l|-f ...\n"
-	    "This is a little helper app to equalize shell differences between WinNT and\n"
-	    "Win9x and get nmake.exe to accomplish its job.\n",
-	    argv[0]);
-    WriteFile(GetStdHandle(STD_ERROR_HANDLE), msg, chars, &dwWritten, NULL);
-    return 2;
-}
-
-int
-CheckForCompilerFeature (const char *option)
-{
-    STARTUPINFO si;
-    PROCESS_INFORMATION pi;
-    SECURITY_ATTRIBUTES sa;
-    DWORD threadID;
-    char msg[300];
-    BOOL ok;
-    HANDLE hProcess, h, pipeThreads[2];
-    char cmdline[100];
-
-    hProcess = GetCurrentProcess();
-
-    ZeroMemory(&pi, sizeof(PROCESS_INFORMATION));
-    ZeroMemory(&si, sizeof(STARTUPINFO));
-    si.cb = sizeof(STARTUPINFO);
-    si.dwFlags   = STARTF_USESTDHANDLES;
-    si.hStdInput = INVALID_HANDLE_VALUE;
-
-    ZeroMemory(&sa, sizeof(SECURITY_ATTRIBUTES));
-    sa.nLength = sizeof(SECURITY_ATTRIBUTES);
-    sa.lpSecurityDescriptor = NULL;
-    sa.bInheritHandle = FALSE;
-
-    /* create a non-inheritible pipe. */
-    CreatePipe(&Out.pipe, &h, &sa, 0);
-
-    /* dupe the write side, make it inheritible, and close the original. */
-    DuplicateHandle(hProcess, h, hProcess, &si.hStdOutput, 
-	    0, TRUE, DUPLICATE_SAME_ACCESS | DUPLICATE_CLOSE_SOURCE);
-
-    /* Same as above, but for the error side. */
-    CreatePipe(&Err.pipe, &h, &sa, 0);
-    DuplicateHandle(hProcess, h, hProcess, &si.hStdError, 
-	    0, TRUE, DUPLICATE_SAME_ACCESS | DUPLICATE_CLOSE_SOURCE);
-
-    /* base command line */
-    strcpy(cmdline, "cl.exe -nologo -c -TC -Fdtemp ");
-    /* append our option for testing */
-    strcat(cmdline, option);
-    /* filename to compile, which exists, but is nothing and empty. */
-    strcat(cmdline, " nul");
-
-    ok = CreateProcess(
-	    NULL,	    /* Module name. */
-	    cmdline,	    /* Command line. */
-	    NULL,	    /* Process handle not inheritable. */
-	    NULL,	    /* Thread handle not inheritable. */
-	    TRUE,	    /* yes, inherit handles. */
-	    DETACHED_PROCESS, /* No console for you. */
-	    NULL,	    /* Use parent's environment block. */
-	    NULL,	    /* Use parent's starting directory. */
-	    &si,	    /* Pointer to STARTUPINFO structure. */
-	    &pi);	    /* Pointer to PROCESS_INFORMATION structure. */
-
-    if (!ok) {
-	DWORD err = GetLastError();
-	int chars = wsprintf(msg, "Tried to launch: \"%s\", but got error [%u]: ", cmdline, err);
-
-	FormatMessage(FORMAT_MESSAGE_FROM_SYSTEM | FORMAT_MESSAGE_IGNORE_INSERTS |
-		FORMAT_MESSAGE_MAX_WIDTH_MASK, 0L, err, 0, (LPVOID) &msg[chars],
-		(300-chars), 0);
-	WriteFile(GetStdHandle(STD_ERROR_HANDLE), msg, strlen(msg), &err, NULL);
-	return 2;
-    }
-
-    /* close our references to the write handles that have now been inherited. */
-    CloseHandle(si.hStdOutput);
-    CloseHandle(si.hStdError);
-
-    WaitForInputIdle(pi.hProcess, 5000);
-    CloseHandle(pi.hThread);
-
-    /* start the pipe reader threads. */
-    pipeThreads[0] = CreateThread(NULL, 0, ReadFromPipe, &Out, 0, &threadID);
-    pipeThreads[1] = CreateThread(NULL, 0, ReadFromPipe, &Err, 0, &threadID);
-
-    /* block waiting for the process to end. */
-    WaitForSingleObject(pi.hProcess, INFINITE);
-    CloseHandle(pi.hProcess);
-
-    /* clean up temporary files before returning */
-    DeleteFile("temp.idb");
-    DeleteFile("temp.pdb");
-
-    /* wait for our pipe to get done reading, should it be a little slow. */
-    WaitForMultipleObjects(2, pipeThreads, TRUE, 500);
-    CloseHandle(pipeThreads[0]);
-    CloseHandle(pipeThreads[1]);
-
-    /* look for the commandline warning code in both streams. */
-    return !(strstr(Out.buffer, "D4002") != NULL || strstr(Err.buffer, "D4002") != NULL);
-}
-
-int
-CheckForLinkerFeature (const char *option)
-{
-    STARTUPINFO si;
-    PROCESS_INFORMATION pi;
-    SECURITY_ATTRIBUTES sa;
-    DWORD threadID;
-    char msg[300];
-    BOOL ok;
-    HANDLE hProcess, h, pipeThreads[2];
-    char cmdline[100];
-
-    hProcess = GetCurrentProcess();
-
-    ZeroMemory(&pi, sizeof(PROCESS_INFORMATION));
-    ZeroMemory(&si, sizeof(STARTUPINFO));
-    si.cb = sizeof(STARTUPINFO);
-    si.dwFlags   = STARTF_USESTDHANDLES;
-    si.hStdInput = INVALID_HANDLE_VALUE;
-
-    ZeroMemory(&sa, sizeof(SECURITY_ATTRIBUTES));
-    sa.nLength = sizeof(SECURITY_ATTRIBUTES);
-    sa.lpSecurityDescriptor = NULL;
-    sa.bInheritHandle = TRUE;
-
-    /* create a non-inheritible pipe. */
-    CreatePipe(&Out.pipe, &h, &sa, 0);
-
-    /* dupe the write side, make it inheritible, and close the original. */
-    DuplicateHandle(hProcess, h, hProcess, &si.hStdOutput, 
-	    0, TRUE, DUPLICATE_SAME_ACCESS | DUPLICATE_CLOSE_SOURCE);
-
-    /* Same as above, but for the error side. */
-    CreatePipe(&Err.pipe, &h, &sa, 0);
-    DuplicateHandle(hProcess, h, hProcess, &si.hStdError, 
-	    0, TRUE, DUPLICATE_SAME_ACCESS | DUPLICATE_CLOSE_SOURCE);
-
-    /* base command line */
-    strcpy(cmdline, "link.exe -nologo ");
-    /* append our option for testing */
-    strcat(cmdline, option);
-    /* filename to compile, which exists, but is nothing and empty. */
-//    strcat(cmdline, " nul");
-
-    ok = CreateProcess(
-	    NULL,	    /* Module name. */
-	    cmdline,	    /* Command line. */
-	    NULL,	    /* Process handle not inheritable. */
-	    NULL,	    /* Thread handle not inheritable. */
-	    TRUE,	    /* yes, inherit handles. */
-	    DETACHED_PROCESS, /* No console for you. */
-	    NULL,	    /* Use parent's environment block. */
-	    NULL,	    /* Use parent's starting directory. */
-	    &si,	    /* Pointer to STARTUPINFO structure. */
-	    &pi);	    /* Pointer to PROCESS_INFORMATION structure. */
-
-    if (!ok) {
-	DWORD err = GetLastError();
-	int chars = wsprintf(msg, "Tried to launch: \"%s\", but got error [%u]: ", cmdline, err);
-
-	FormatMessage(FORMAT_MESSAGE_FROM_SYSTEM | FORMAT_MESSAGE_IGNORE_INSERTS |
-		FORMAT_MESSAGE_MAX_WIDTH_MASK, 0L, err, 0, (LPVOID) &msg[chars],
-		(300-chars), 0);
-	WriteFile(GetStdHandle(STD_ERROR_HANDLE), msg, strlen(msg), &err, NULL);
-	return 2;
-    }
-
-    /* close our references to the write handles that have now been inherited. */
-    CloseHandle(si.hStdOutput);
-    CloseHandle(si.hStdError);
-
-    WaitForInputIdle(pi.hProcess, 5000);
-    CloseHandle(pi.hThread);
-
-    /* start the pipe reader threads. */
-    pipeThreads[0] = CreateThread(NULL, 0, ReadFromPipe, &Out, 0, &threadID);
-    pipeThreads[1] = CreateThread(NULL, 0, ReadFromPipe, &Err, 0, &threadID);
-
-    /* block waiting for the process to end. */
-    WaitForSingleObject(pi.hProcess, INFINITE);
-    CloseHandle(pi.hProcess);
-
-    /* wait for our pipe to get done reading, should it be a little slow. */
-    WaitForMultipleObjects(2, pipeThreads, TRUE, 500);
-    CloseHandle(pipeThreads[0]);
-    CloseHandle(pipeThreads[1]);
-
-    /* look for the commandline warning code in the stderr stream. */
-    return !(strstr(Out.buffer, "LNK1117") != NULL || strstr(Err.buffer, "LNK1117") != NULL);
-}
-
-DWORD WINAPI
-ReadFromPipe (LPVOID args)
-{
-    pipeinfo *pi = (pipeinfo *) args;
-    char *lastBuf = pi->buffer;
-    DWORD dwRead;
-    BOOL ok;
-
-again:
-    ok = ReadFile(pi->pipe, lastBuf, 25, &dwRead, 0L);
-    if (!ok || dwRead == 0) {
-	CloseHandle(pi->pipe);
-	return 0;
-    }
-    lastBuf += dwRead;
-    goto again;
-
-    return 0;  /* makes the compiler happy */
-}
-
-int
-IsIn (const char *string, const char *substring)
-{
-    return (strstr(string, substring) != NULL);
-}
diff --git a/tclxml-3.2/win/rules.vc b/tclxml-3.2/win/rules.vc
deleted file mode 100644
index a337669..0000000
--- a/tclxml-3.2/win/rules.vc
+++ /dev/null
@@ -1,376 +0,0 @@
-#------------------------------------------------------------------------------
-# rules.vc --
-#
-#	Microsoft Visual C++ makefile include for decoding the commandline
-#	macros.  This file does not need editing to build Tcl.
-#
-# See the file "license.terms" for information on usage and redistribution
-# of this file, and for a DISCLAIMER OF ALL WARRANTIES.
-# 
-# Copyright (c) 2001-2002 David Gravereaux.
-#
-#------------------------------------------------------------------------------
-# RCS: @(#) $Id: rules.vc,v 1.1.1.1 2009/01/16 22:11:49 joye Exp $
-#------------------------------------------------------------------------------
-
-!ifndef _RULES_VC
-_RULES_VC = 1
-
-cc32		= $(CC)   # built-in default.
-link32		= link
-lib32		= lib
-rc32		= $(RC)   # built-in default.
-
-!ifndef INSTALLDIR
-### Assume the normal default.
-_INSTALLDIR	= C:\Program Files\Tcl
-!else
-### Fix the path seperators.
-_INSTALLDIR	= $(INSTALLDIR:/=\)
-!endif
-
-!ifndef MACHINE
-MACHINE		= IX86
-!endif
-
-!ifndef CFG_ENCODING
-CFG_ENCODING	= \"cp1252\"
-!endif
-
-#----------------------------------------------------------
-# Set the proper copy method to avoid overwrite questions
-# to the user when copying files and selecting the right
-# "delete all" method.
-#----------------------------------------------------------
-
-!if "$(OS)" == "Windows_NT"
-RMDIR	= rmdir /S /Q
-!if ![ver | find "4.0" > nul]
-CPY	= echo y | xcopy /i
-!else
-CPY	= xcopy /i /y
-!endif
-!else
-CPY	= xcopy /i
-RMDIR	= deltree /Y
-!endif
-
-
-!message ===============================================================================
-
-#----------------------------------------------------------
-# build the helper app we need to overcome nmake's limiting
-# environment.
-#----------------------------------------------------------
-
-!if !exist(nmakehlp.exe)
-!if [$(cc32) -nologo -ML nmakehlp.c -link -subsystem:console > nul]
-!endif
-!endif
-
-#----------------------------------------------------------
-# Test for compiler features
-#----------------------------------------------------------
-
-### test for optimizations
-!if [nmakehlp -c -Otip]
-!message *** Compiler has 'Optimizations'
-OPTIMIZING	= 1
-!else
-!message *** Compiler doesn't have 'Optimizations'
-OPTIMIZING	= 0
-!endif
-
-!if "$(MACHINE)" == "IX86"
-### test for pentium errata
-!if [nmakehlp -c -QI0f]
-!message *** Compiler has 'Pentium 0x0f fix'
-PENT_0F_ERRATA	= 1
-!else
-!message *** Compiler doesn't have 'Pentium 0x0f fix'
-PENT_0F_ERRATA	= 0
-!endif
-### test for -align:4096, when align:512 will do.
-!if [nmakehlp -l -opt:nowin98]
-!message *** Linker has 'Win98 alignment problem'
-ALIGN98_HACK	= 1
-!else
-!message *** Linker doesn't have 'Win98 alignment problem'
-ALIGN98_HACK	= 0
-!endif
-!else
-PENT_0F_ERRATA	= 0
-ALIGN98_HACK	= 0
-!endif
-
-!if "$(MACHINE)" == "IA64"
-### test for Itanium errata
-!if [nmakehlp -c -QIA64_Bx]
-!message *** Compiler has 'B-stepping errata workarounds'
-ITAN_B_ERRATA	= 1
-!else
-!message *** Compiler doesn't have 'B-stepping errata workarounds'
-ITAN_B_ERRATA	= 0
-!endif
-!else
-ITAN_B_ERRATA	= 0
-!endif
-
-#----------------------------------------------------------
-# Decode the options requested.
-#----------------------------------------------------------
-
-!if "$(OPTS)" == "" || [nmakehlp -f "$(OPTS)" "none"]
-STATIC_BUILD	= 0
-TCL_THREADS	= 0
-DEBUG		= 0
-PROFILE		= 0
-MSVCRT		= 0
-LOIMPACT	= 0
-TCL_USE_STATIC_PACKAGES	= 0
-USE_THREAD_ALLOC = 0
-!else
-!if [nmakehlp -f $(OPTS) "static"]
-!message *** Doing static
-STATIC_BUILD	= 1
-!else
-STATIC_BUILD	= 0
-!endif
-!if [nmakehlp -f $(OPTS) "msvcrt"]
-!message *** Doing msvcrt
-MSVCRT		= 1
-!else
-MSVCRT		= 0
-!endif
-!if [nmakehlp -f $(OPTS) "staticpkg"]
-!message *** Doing staticpkg
-TCL_USE_STATIC_PACKAGES	= 1
-!else
-TCL_USE_STATIC_PACKAGES	= 0
-!endif
-!if [nmakehlp -f $(OPTS) "threads"]
-!message *** Doing threads
-TCL_THREADS	= 1
-!else
-TCL_THREADS	= 0
-!endif
-!if [nmakehlp -f $(OPTS) "symbols"]
-!message *** Doing symbols
-DEBUG		= 1
-!else
-DEBUG		= 0
-!endif
-!if [nmakehlp -f $(OPTS) "profile"]
-!message *** Doing profile
-PROFILE		= 1
-!else
-PROFILE		= 0
-!endif
-!if [nmakehlp -f $(OPTS) "loimpact"]
-!message *** Doing loimpact
-LOIMPACT	= 1
-!else
-LOIMPACT	= 0
-!endif
-!if [nmakehlp -f $(OPTS) "thrdalloc"]
-!message *** Doing thrdalloc
-USE_THREAD_ALLOC = 1
-!else
-USE_THREAD_ALLOC = 0
-!endif
-!endif
-
-
-!if !$(STATIC_BUILD)
-# Make sure we don't build overly fat DLLs.
-MSVCRT		= 1
-# We shouldn't statically put the extensions inside the shell when dynamic.
-TCL_USE_STATIC_PACKAGES = 0
-!endif
-
-
-#----------------------------------------------------------
-# Figure-out how to name our intermediate and output directories.
-# We wouldn't want different builds to use the same .obj files
-# by accident.
-#----------------------------------------------------------
-
-SUFX	    = tsgx
-
-!if $(DEBUG)
-BUILDDIRTOP = Debug
-DBGX	    = g
-!else
-BUILDDIRTOP = Release
-DBGX	    =
-SUFX	    = $(SUFX:g=)
-!endif
-
-TMP_DIRFULL = .\$(BUILDDIRTOP)\$(PROJECT)_ThreadedDynamicStaticX
-
-!if !$(STATIC_BUILD)
-TMP_DIRFULL = $(TMP_DIRFULL:Static=)
-SUFX	    = $(SUFX:s=)
-EXT	    = dll
-!if $(MSVCRT)
-TMP_DIRFULL = $(TMP_DIRFULL:X=)
-SUFX	    = $(SUFX:x=)
-!endif
-!else
-TMP_DIRFULL = $(TMP_DIRFULL:Dynamic=)
-EXT	    = lib
-!if !$(MSVCRT)
-TMP_DIRFULL = $(TMP_DIRFULL:X=)
-SUFX	    = $(SUFX:x=)
-!endif
-!endif
-
-!if !$(TCL_THREADS)
-TMP_DIRFULL = $(TMP_DIRFULL:Threaded=)
-SUFX	    = $(SUFX:t=)
-!endif
-
-!ifndef TMP_DIR
-TMP_DIR	    = $(TMP_DIRFULL)
-!ifndef OUT_DIR
-OUT_DIR	    = .\$(BUILDDIRTOP)
-!endif
-!else
-!ifndef OUT_DIR
-OUT_DIR	    = $(TMP_DIR)
-!endif
-!endif
-
-
-#----------------------------------------------------------
-# Decode the statistics requested.
-#----------------------------------------------------------
-
-!if "$(STATS)" == "" || [nmakehlp -f "$(STATS)" "none"]
-TCL_MEM_DEBUG	    = 0
-TCL_COMPILE_DEBUG   = 0
-!else
-!if [nmakehlp -f $(STATS) "memdbg"]
-!message *** Doing memdbg
-TCL_MEM_DEBUG	    = 1
-!else
-TCL_MEM_DEBUG	    = 0
-!endif
-!if [nmakehlp -f $(STATS) "compdbg"]
-!message *** Doing compdbg
-TCL_COMPILE_DEBUG   = 1
-!else
-TCL_COMPILE_DEBUG   = 0
-!endif
-!endif
-
-
-#----------------------------------------------------------
-# Set our defines now armed with our options.
-#----------------------------------------------------------
-
-OPTDEFINES	= -DTCL_CFGVAL_ENCODING=$(CFG_ENCODING)
-
-!if $(TCL_MEM_DEBUG)
-OPTDEFINES	= -DTCL_MEM_DEBUG
-!endif
-!if $(TCL_COMPILE_DEBUG)
-OPTDEFINES	= $(OPTDEFINES) -DTCL_COMPILE_DEBUG -DTCL_COMPILE_STATS
-!endif
-!if $(TCL_THREADS)
-OPTDEFINES	= $(OPTDEFINES) -DTCL_THREADS=1
-!if $(USE_THREAD_ALLOC)
-OPTDEFINES	= $(OPTDEFINES) -DUSE_THREAD_ALLOC=1
-!endif
-!endif
-!if $(STATIC_BUILD)
-OPTDEFINES	= $(OPTDEFINES) -DSTATIC_BUILD
-!endif
-
-!if $(DEBUG)
-OPTDEFINES	= $(OPTDEFINES) -DTCL_CFG_DEBUG
-!elseif $(OPTIMIZING)
-OPTDEFINES	= $(OPTDEFINES) -DTCL_CFG_OPTIMIZED
-!endif
-!if $(PROFILE)
-OPTDEFINES	= $(OPTDEFINES) -DTCL_CFG_PROFILED
-!endif
-!if "$(MACHINE)" == "IA64"
-OPTDEFINES	= $(OPTDEFINES) -DTCL_CFG_DO64BIT
-!endif
-
-
-#----------------------------------------------------------
-# Get common info used when building extensions.
-#----------------------------------------------------------
-
-!if "$(PROJECT)" != "tcl"
-
-!if !defined(TCLDIR)
-!if exist("$(_INSTALLDIR)\include\tcl.h")
-TCLINSTALL	= 1
-_TCLDIR		= $(_INSTALLDIR)
-!else
-MSG=^
-Don't know where tcl.h is.  Set the TCLDIR macro.
-!error $(MSG)
-!endif
-!else
-_TCLDIR	= $(TCLDIR:/=\)
-!if exist("$(_TCLDIR)\include\tcl.h")
-TCLINSTALL	= 1
-!elseif exist("$(_TCLDIR)\generic\tcl.h")
-TCLINSTALL	= 0
-!else
-MSG =^
-Don't know where tcl.h is.  The TCLDIR macro doesn't appear correct.
-!error $(MSG)
-!endif
-!endif
-
-### TODO: add a command to nmakehlp.c to grep for Tcl's version from tcl.h.
-### Because nmake can't return a string, we'll need to play games with return
-### codes.  It might look something like this:
-#!if [nmakehlp -g $(TCL.H)] == 81
-#TCL_DOTVERSION	= 8.1
-#!elseif [nmakehlp -g $(TCL.H)] == 82
-#TCL_DOTVERSION	= 8.2
-#...
-#!endif
-
-TCL_DOTVERSION	= 8.4
-TCL_VERSION	= $(TCL_DOTVERSION:.=)
-
-!if $(TCLINSTALL)
-TCLSH		= "$(_INSTALLDIR)\bin\tclsh$(TCL_VERSION)$(SUFX).exe"
-TCLSTUBLIB	= "$(_INSTALLDIR)\lib\tclstub$(TCL_VERSION).lib"
-TCLIMPLIB	= "$(_INSTALLDIR)\lib\tcl$(TCL_VERSION)$(SUFX).lib"
-TCL_LIBRARY	= $(_INSTALLDIR)\lib
-TCLREGLIB	= "$(_INSTALLDIR)\lib\tclreg11$(SUFX:t=).lib"
-TCLDDELIB	= "$(_INSTALLDIR)\lib\tcldde12$(SUFX:t=).lib"
-COFFBASE	= \must\have\tcl\sources\to\build\this\target
-TCLTOOLSDIR	= \must\have\tcl\sources\to\build\this\target
-!else
-TCLSH		= "$(_TCLDIR)\win\$(BUILDDIRTOP)\tclsh$(TCL_VERSION)$(SUFX).exe"
-TCLSTUBLIB	= "$(_TCLDIR)\win\$(BUILDDIRTOP)\tclstub$(TCL_VERSION).lib"
-TCLIMPLIB	= "$(_TCLDIR)\win\$(BUILDDIRTOP)\tcl$(TCL_VERSION)$(SUFX).lib"
-TCL_LIBRARY	= $(_TCLDIR)\library
-TCLREGLIB	= "$(_TCLDIR)\win\$(BUILDDIRTOP)\tclreg11$(SUFX:t=).lib"
-TCLDDELIB	= "$(_TCLDIR)\win\$(BUILDDIRTOP)\tcldde12$(SUFX:t=).lib"
-COFFBASE	= "$(_TCLDIR)\win\coffbase.txt"
-TCLTOOLSDIR	= $(_TCLDIR)\tools
-!endif
-
-!endif
-
-
-#----------------------------------------------------------
-# Display stats being used.
-#----------------------------------------------------------
-
-!message *** Intermediate directory will be '$(TMP_DIR)'
-!message *** Output directory will be '$(OUT_DIR)'
-!message *** Suffix for binaries will be '$(SUFX)'
-!message *** Optional defines are '$(OPTDEFINES)'
-
-!endif
diff --git a/tkcon-2.5/ChangeLog b/tkcon-2.5/ChangeLog
deleted file mode 100644
index 12a05fc..0000000
--- a/tkcon-2.5/ChangeLog
+++ /dev/null
@@ -1,504 +0,0 @@
-2008-02-07  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl (::tkcon::Bindings): prevent Expand virtual events
-	from triggering follow-on events (most important for <Tab>).
-	(::tkcon::Retrieve): remove extraneous http::geturl call.
-	
-2007-06-22  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl (::tkcon::EvalCmd): add OPT(resultfilter) and 'tkcon
-	resultfilter ?cmd?' to allow optional result filter command.
-	Command will be passed result code and data and must return what
-	tkcon will return to the user.  Command is run in attached slave.
-	Ensure that initial files are sources at level #0.
-	Convert args after (--|-argv|-args) into slave arguments and set
-	them as the main $::argv/$::argc for propagation.
-
-2007-06-21  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* docs/tkcon.1.man, docs/tkcon.n.man, docs/tkconrc.5.man (new): 
-	* docs/dump.n.man, docs/observe.n.man, docs/idebug.n.man (new): 
-	* index.html, docs/demopic.gif (removed), docs/demopic.png (new):
-	* docs/plugin.html, docs/start.html, docs/tkcon.html:
-	Updated docs and added doctools equivalents courtesy Sergei Golovan
-	* docs/style.css: updated stylesheet
-	
-2007-04-04  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	*** BUMPED TO VERSION 2.5 ***
-
-	* tkcon.tcl: ensure option overrides only effect tkcon and
-	subwidgets.
-	(edit): Add -wrap option to 'edit' command.
-	(::tkcon::AtSource): adjust argv0 existence check
-
-2006-09-05  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl (::tkcon::NewTab, ::tkcon::GetSlave): ensure that new
-	tabs in other toplevel tkcon windows are built in the correct
-	slave hierarchy.
-
-	* pkgIndex.tcl: sample pkgIndex.tcl that allows using tkcon as a
-	package.
-
-	* tkcon.tcl (::tkcon::InitSlave): adjust to make the first file
-	passed in to be argv0 in the slave
-
-2006-08-25  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl (tkcon): default wm protocol to hide tkcon when used
-	in embedded context.
-
-2006-08-23  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl: remove use of -exact in package require Tk
-
-2006-06-29  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl: updated to handle ttk scrollbars as well as other UI
-	cleanup.
-
-2006-06-15  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl: modify CVS location after SF changes
-
-	* README.txt: correct reference email address
-
-2006-02-28  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl (tkcon): update 'gets stdin' override (tkcon congets)
-	to support usage at script load time. (decoster)
-
-2006-01-25  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl (MenuConfigure): Fix ActiveTcl Help link when pointing
-	to a file with space in path. [Bug 1408425]
-	(::tkcon::Save, ::tkcon::Load): in VFS paths, use the X11 dialogs
-	that support viewing in VFS dirs.
-
-2005-09-12  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl (::tkcon::AtSource): do not require argv to be defined
-	(edit): enable text -undo in editor
-	(::tkcon::InitUI): shrink aqua resize control space alloted
-
-2005-07-14  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl: add ::tkcon::OPT(maxlinelen) (default 0 == unlimited)
-	and 'tkcon linelength ?value?' to optionally limit long result
-	lines.  True result is still captured in $_ (and 'puts $_' works).
-
-2005-05-25  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl (InitMenus): add ActiveTcl Help menu item, if AT Help
-	is found.
-
-2005-04-06  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl (ExpandXotcl): allow for xotcl method name expansion,
-	if you change ::tkcon::OPT(expandorder) to include Xotcl before
-	Procname
-
-2005-02-21  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl (::send::send): propagate -displayof to winfo interps
-	call. [Bug 1124369] (mbec)
-
-2004-11-17  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl (::tkcon::ExpandVariable): correct array keyname
-	expansion. [Bug 1004508] (bold)
-
-2004-11-12  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl (::tkcon::EvalSocket): pass sock arg. (allaert)
-
-2004-11-11  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl (::tkcon::DeleteTab): allow for exit code to be passed
-	when exit is aliased to DeleteTab. [Bug 1064462]
-	(::tkcon::Expect): graphicsSet isn't valid yet
-
-2004-10-10  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl (::tkcon::Highlight): use ctext for the 'edit' dialog
-	if available
-
-2004-07-26  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	**** TKCON 2.4 TAGGED FOR RELEASE ****
-
-	* index.html, docs/*.html: remove email links, update 2.4 info
-	* docs/plugin.html: update plugin page embed code
-
-2004-06-24  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl (DeleteTab, Destroy): improve the 'exit' handling so
-	that 'exit' in the first created tab doesn't do a full exit.
-	'exit' in the last tab of the first created console still exits
-	tkcon, fixing that requires a rearch of the console
-	creation/management.
-	(InitTab): Have the <Configure> binding only fire for the root
-	window, not for each tab.
-	(GotoTab): Keep tabs around - just raise/lower instead of grid
-	remove/add.  break on Next/Prev Tab binding to get focus right.
-	(Prompt): return if console w doesn't exist
-
-2004-06-10  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl: add [X] tab delete button and Console -> Delete Tab
-	menu item. [Bug 970785]
-
-2004-05-12  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl (observe): allow observe of 'proc'
-
-2004-03-20  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl (::tkcon::EvalSocketEvent): correctly handle socket
-	events after attachment changes
-
-2004-03-01  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl: correct 'exit' in extra tabs.
-	make tkconfixed font Courier -12 (was Courier 10), use it on unix.
-	Add extra space for OS X/Aqua in statusbar (for resize handle).
-	Only use -overrelief in 8.4
-
-2004-02-12  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl (::tkcon::InitUI): check existence of tcl_platform(os)
-	as it doesn't exist in the Tcl plugin.
-	Show Attach info in tab text, maintain namespace attachment
-	between console switches.
-	(::tkcon::InterpEval, Interps): beware safe interps with Tk
-
-2004-02-05  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl: brought code back to 8.0 compatability.
-	Use $_ as last cached result var (was ${}).
-	Ensure hoterrors garbage collection occurs across all tabs.
-
-2004-01-29  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl: first whack at tabbed consoles
-
-2004-01-28  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl: don't use menu tearoffs
-	remove recognizable email addresses from source
-	enabled more send variants (comm, dde, winsend) [bug 649257] (thoyts)
-	change Packages menu (that would be too large with many packages)
-	to a Manage Packages dialog.
-	tightened up Create Socket dialog, added <Escape> dismiss binding.
-	Moved source time initialization into ::tkcon::AtSource to guard
-	against leftover vars and just better encapsulate it.
-	(::tkcon::Retrieve): correct retrieve URL and add intelligence to
-	sense whether what we retrieved is correct before overwriting file.
-
-2003-11-18  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl (::tkcon::InitSlave): remove tk_library from the
-	seeded auto_path.  Do not add OPT(library) to auto_path if it is "".
-
-2003-11-04  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl (::tkcon::EvalSocketClosed): use tk_messageBox instead
-	of tk_dialog
-
-2003-10-06  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl (dir): use %9ld instead of %9d to support large files
-
-2003-04-08  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl (::tkcon::InitUI): WinCE code to resize the window to
-	fit on the small screen
-
-2003-03-31  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl (tkcon::Retrieve): correct the check for tkcon version
-	when retrieving from http.
-
-2003-02-20  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl (EvalCmd): set $:: (aka ${}) var to last command result.
-	(EvalOther): use tk_messageBox instead of tk_dialog
-	(Init): allow 'edit' to be overridden using OPT(edit)
-
-2003-01-13  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl: add tk appname alias in WWW plugin case.
-
-2002-10-08  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl (tcl_unknown): allow ::namespace (:'s) to be
-	recognized. (koloska)
-	(MainInit): add option for overriding exit command.
-	(InitUI): add option to control the wm protocol for WM_DELETE_WINDOW.
-
-2002-10-01  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl (InterpEval): correctly handle no args case.
-	(New): autoload tbcload when it exists.
-
-2002-06-22  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl: call Init with eval to break out argv into args.
-
-2002-06-04  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl (Init): convert env(home) from 'C:' to 'C:/' if necessary.
-
-2002-06-03  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl: fixed Retrieve to use the proxy info (Thoyts).
-	Added code so that tkcon.tcl can be sourced in and used like a
-	quasi-package.  Once sourced, you can do a 'package require tkcon'
-	(there is no pkgIndex.tcl for it), and the first 'tkcon show' will
-	initialize anything that is needed.
-	(observe): corrected variables tracing to not allow duplicates.
-	(dump): improved check for empty named arrays as well as locally
-	aliased vars in var dumps.
-	Use the 'fixed' font on unix by default.
-
-2002-02-22  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl (AddSlaveHistory): changed history to not add the
-	command if it is the same as the previous command (it will still
-	be evaluated).  (soderstrom)
-	Added panedwindow and labelframe as recognized Tk commands.
-
-2002-01-24  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	**** TKCON 2.3 RELEASE ****
-
-	* tkcon.tcl: bumped to v2.3
-
-2002-01-23  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* docs/procs.html:
-	* tkcon.tcl (what): changed to differentiate between 'array' and
-	'scalar' instead of just returning 'variable'.
-	(which): called what in uplevel to get scope right.
-
-2002-01-22  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl (ExpandPathname): use a safer regsub to first unescape
-	the str, then to protect it in the glob.
-	(dir): Use -directory arg in 8.3+ for better results.
-
-	* docs/idebug.html: added note about ? help at debug prompt.
-
-	* tkcon.tcl (dir): prevented possible 'divide by zero' error.
-	[Bug #496584]
-	(Expand*): fixed ExpandPathname to better handle spaced pathnames.
-	[Bug #497079]
-
-2001-12-14  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl: 'tkcon show' causes loss of focus on Windows, so an
-	extra focus to the console was added.
-
-2001-12-12  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl (EvalSocketEvent): changed EvalSocketClosed to only
-	occur after gets, then eof check. (Gerold Jury)
-
-2001-11-14  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl: added catch around file type call
-
-2001-10-14  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl (Init): corrected loading of rcfile when it was in a
-	path including spaces. (siltberg)
-	(About): clarified CVS info in about box.
-
-	* docs/start.html: correct old refs to TKCON var.
-
-2001-09-28  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl (ExpandPathname): recognize NT as a case *in*sensitive
-	file system for pathname expansion.
-
-2001-08-31  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl (InitSlave): propagate auto_path from master to slave.
-
-2001-08-24  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl (NewSocket, NewDisplay): when nothing is specified,
-	just return.
-	(Display): fixed connecting to interps on other displays.
-
-2001-08-22  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* docs/bindings.html: noted ^r/^s change. 
-
-	* tkcon.tcl (Event): changed event ^r/^s searching to search for
-	any matching substring, and blink the substring.
-	Added statusbar, default off (not much in status yet).
-
-2001-08-20  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl (EvalNamespace): fixed to work when attached to a
-	foreign interpreter. [Bug #453431]
-	Added fix that allows access to Tk privates in 8.4.  Still needs
-	a long-term fix. [Bug #450865] (porter)
-
-2001-08-03  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl (EvalCmd): protected against non-existent
-	tkPriv(mouseMoved) variable
-
-2001-07-05  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl (RetrieveFilter, RetrieveAuthentication): added
-	support for retrieving latest tkcon via a proxy. (Thoyts)
-
-2001-07-04  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl (tkcon): made tkcon console return whatever result it
-	received.  Fixed Bug #438281.
-
-2001-06-20  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	TKCON 2.2 RELEASE
-
-	* README.txt:
-	* index.html:
-	* docs/index.html: updated for 2.2 release
-
-	* tkcon.tcl (InitUI): moved wm protocol inside check to not run
-	under plugin.
-	(::tkcon::Retrieve): added a new method to allow tkcon to retrieve
-	the latest version of itself.
-
-2001-06-19  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl (dir): added fallback in generic dir command to not
-	require being run in tkcon.
-	(Init): Changed around how all options are initialized to allow
-	for tkcon embedders to set their own defaults.  Added a usehistory
-	PRIV key that tells us whether to load/save history files.  Added
-	showOnStartup PRIV key to control whether tkcon should deiconify
-	itself on startup.  Changed setting root to .tkcon to ensure that
-	root was just . before.
-
-2001-06-18  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl: (InitUI) added WM_DELETE_WINDOW hook to exit to
-	correctly deconstruct slave consoles.
-	(tkcon congets/getc) added tkcon show to ensure that tkcon would
-	be displayed when input is expected.
-	(GetSelection) new command to handle getting selection, this
-	supports the new UTF8_STRING type.
-	(InitMenus) added version check around Attach to Socket menu, as
-	8.3 is need for the file channels call.
-
-2001-05-28  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* docs/start.html: added note about ::tkcon::OPT(gets) var.
-	* docs/tkcon.html: improved docs for tkcon *get* methods.
-	* tkcon.tcl: reinstituted override of gets by default to use the
-	tkcon console based gets.
-
-	* tkcon.tcl (dump): corrected outputting local vars with dump.
-	Added RCS info to PRIV array and About box.
-	(tkcon congets) corrected congets to set the limit and insert
-	properly to return data without needing to call the prompt.
-	(tkcon set) corrected to return [array get] string for arrays,
-	and scalar value for vars.
-	Placed exact level value to all calls to uplevel and upvar.
-
-2001-05-17  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	* tkcon.tcl: make check for actual tkcon root existence to allow
-	for setting the var ($::tkcon::PRIV(root)) in controlling apps to
-	better control the root window.
-
-2001-05-04  Jeff Hobbs  <jeffh at ActiveState.com>
-
-	TKCON 2.1 RELEASE
-
-	* docs/style.css: new file for html files to use.
-	* README.txt:
-	* index.html:
-	* doc/*: updated for 2.1 release.
-
-	* tkcon.tcl: allowed 'tkcon font ...' and 'tkcon buffer ...' to
-	work before the main console have been created.
-	Changed "TkCon" -> "tkcon", updated for new release.
-
-2001-03-28  Jeff Hobbs  <jeffh at activestate.com>
-
-	* tkcon.tcl (::tkcon::Init): added safe interp check around 'cd'
-	call for Macs
-
-2000-10-30  Jeff Hobbs  <hobbs at ajubasolutions.com>
-
-	* tkcon.tcl (dir): fixed bug where permissions wouldn't print
-	correctly if user had no permissions. (kuchler)
-
-2000-10-18  Jeff Hobbs  <hobbs at ajubasolutions.com>
-
-	* tkcon.tcl (::tkcon::NamespacesList): corrected to not use window
-	starting with an uppercase letter (error). (reins)
-
-2000-09-27  Jeff Hobbs  <hobbs at scriptics.com>
-
-	* tkcon.tcl (::tkcon::About): added 'variable COLOR' decl (Zaers).
-
-2000-09-20  Jeff Hobbs  <hobbs at scriptics.com>
-
-	* tkcon.tcl (InitMenus): restricted the Attach Socket
-	functionality to Tcl 8.3+ due to use of [file channels].
-	(InitUI): fixed Configure binding to use correct namespace for OPT
-	(EvalSocket, EvalSend, EvalAttached): cleaned up to require that
-	they accept only one arg as the command string to be evaluated.
-	Prior behavior left some ambiguity as to what was eval'ed where.
-	EvalOther, EvalSlave may need some sanitation as well.
-	(EvalCmd): Changed EvalSocket functionality to have the \'s
-	substituted before sending data, to allow for special chars to be
-	added to the string.
-
-2000-09-19  Jeff Hobbs  <hobbs at scriptics.com>
-
-	* tkcon.tcl (::tkcon::InitUI): corrected plugin handling, as 'wm
-	withdraw' worked, but 'wm deiconify' was disallowed.
-
-	* docs/plugin.html: updated link to plugin source
-	* docs/changes.txt: noted that changes.txt is no longer updated in
-	favor of this ChangeLog
-
-	* index.html: updated page with sourceforge links
-	* index.html: added toplevel html index doc
-
-	* tkcon.tcl: updated v2.0 to v2.1 alpha version
-	All tkcon procedures have been namespaced, except for the ones
-	that are visible to the user.  TkCon has added the ability to
-	attach to other displays or a socket.
-
-	* tkcon.tcl: updated v1.6 to v2.0 version, tagged tkcon-2-0
-	This is the first version to require 8.0+ to run, although it
-	will still connect to older interps.
-
-	* tkcon.tcl: updated v1.5 to v1.6 version, tagged tkcon-1-6
-	* tkcon.tcl: updated v1.4 to v1.5 version, tagged tkcon-1-5
-	* tkcon.tcl: updated v1.3 to v1.4 version, tagged tkcon-1-4
-	* tkcon.tcl: updated v1.2 to v1.3 version, tagged tkcon-1-3
-	* tkcon.tcl: updated v1.1 to v1.2 version, tagged tkcon-1-2
-	* tkcon.tcl: updated v1.03 to v1.1 version, tagged tkcon-1-1
-	* tkcon.tcl: updated v1.02 to v1.03 version, tagged tkcon-1-03
-	* tkcon.tcl: updated v0.71 to v1.02 version, tagged tkcon-1-02
-	* tkcon.tcl: updated v0.69 to v0.71 version, tagged tkcon-0-71
-	* tkcon.tcl: updated v0.68 to v0.69 version, tagged tkcon-0-69
-	* tkcon.tcl: updated v0.67 to v0.68 version, tagged tkcon-0-68
-	* tkcon.tcl: updated v0.66 to v0.67 version, tagged tkcon-0-67
-	* tkcon.tcl: updated v0.65 to v0.66 version, tagged tkcon-0-66
-	* tkcon.tcl: updated v0.64 to v0.65 version, tagged tkcon-0-65
-	* tkcon.tcl: updated v0.63 to v0.64 version, tagged tkcon-0-64
-	* tkcon.tcl: updated v0.52 to v0.63 version, tagged tkcon-0-63
-
-	* ChangeLog: added a ChangeLog
diff --git a/tkcon-2.5/README.txt b/tkcon-2.5/README.txt
deleted file mode 100644
index 5be8838..0000000
--- a/tkcon-2.5/README.txt
+++ /dev/null
@@ -1,42 +0,0 @@
-WHAT:   Enhanced Tk Console for all Tk platforms
-
-WHERE:  http://tkcon.sourceforge.net/
-	http://www.purl.org/net/hobbs/tcl/script/
-
-REQUIREMENTS: Tcl/Tk 8.0+
-	Tested through Tcl/Tk 8.5.
-        tkcon is all Tcl/Tk code, no compiling required
-
-tkcon is a replacement for the standard console that comes with Tk (on
-Windows/Mac, but also works on Unix).  tkcon provides many more features
-than the standard console and works on all platforms where Tcl/Tk is
-available.  It is meant primarily to aid one when working with the little
-details inside tcl and tk and to give Unix users the GUI console provided
-by default in the Mac and Windows Tk.
-
-FEATURES:
-    Command history
-    Path (Unix style) / Proc / Variable name expansion
-    Multiple and tabbed consoles, each with its own state (via multiple
-        interpreters)
-    Captures stdout and stderr to console window (puts overridden)
-    Hot errors (click on error result to see stack trace)
-    Electric character matching (a la emacs)
-    Electric proc highlighting
-    Enhanced history searching
-    Configurable
-    Cut / Copy / Paste between windows (interoperates with native platform)
-    Communication between consoles and other Tk interpreters
-        (including non-tcl ones)
-    Works on all Tk platforms
-
-CONTACT: Jeffrey Hobbs, jeff at hobbs dot org
-
-GETTING STARTED:
-
-tkcon is a single drop-in file.  On Windows, I place this on the desktop
-and double-click on it instead of wish/tclsh.  On Unix and OS X, I place it
-in a directory on my path and run this instead of wish.
-
-Documentation can be reading by starting with index.html in the docs/
-subdirectory.  Happying Tcl'ing!
diff --git a/tkcon-2.5/docs/bindings.html b/tkcon-2.5/docs/bindings.html
deleted file mode 100755
index 33e892b..0000000
--- a/tkcon-2.5/docs/bindings.html
+++ /dev/null
@@ -1,154 +0,0 @@
-<HTML>
-<HEAD>
-<TITLE>tkcon: Special Bindings</TITLE>
-<LINK REL="STYLESHEET" TYPE="text/css" HREF="./style.css">
-</HEAD>
-
-<BODY BGCOLOR=#FFFFFF>
-
-<TABLE WIDTH=100% BORDER=0 CELLSPACING=2 CELLPADDING=0 BGCOLOR=#000000><TR><TD>
-<!-- start header info -->
-<TABLE WIDTH=100% BORDER=0 CELLSPACING=0 CELLPADDING=0 BGCOLOR=#FFFFFF>
-<TR>
-<TH><FONT SIZE=+3>tkcon: Special Bindings</FONT></TH>
-<TD align=right>
-<A href="http://tkcon.sourceforge.net/"> 
-<IMG src="http://sourceforge.net/sflogo.php?group_id=11462&type=1" width="88"
-height="31" border="0" alt="SourceForge Logo"></A>
-</TD>
-</TR>
-</TABLE>
-<!-- end header info -->
-
-</TD></TR><TR><TD>
-<!-- start main navigation table -->
-<TABLE BORDER=1 CELLPADDING=2 CELLSPACING=2 BGCOLOR=#CCCCCC width=100%>
-<TR>
-<TH CLASS="hi"><A HREF="index.html" CLASS="hi">Documentation</A></TH>
-<TH><A HREF="purpose.html">Purpose & Features</A></TH>
-<TH><A HREF="limits.html">Limitations</A></TH>
-<TH><A HREF="todo.html">To Do</A></TH>
-<TH><A HREF="license.terms">License</A></TH>
-</TR><TR>
-<TH COLSPAN=2><A HREF="plugin.html">Online Demo</A>
-(requires <A HREF="http://tcl.activestate.com/software/plugin/">Tk plugin</A>)</TH>
-<TH COLSPAN=3><A HREF="nontcl.html">Using TkCon with other Tk Languages</A></TH>
-</TR>
-</TABLE>
-<!-- end main navigation table -->
-</TD></TR><TR><TD>
-<!-- start secondary navigation table -->
-<TABLE BORDER=1 CELLPADDING=2 CELLSPACING=2 BGCOLOR=#BBBBBB width=100%>
-<TR>
-<TH><A HREF="start.html">Getting Started</A></TH>
-<TH CLASS="hi2"><A HREF="bindings.html" CLASS="hi2">Special Bindings</A></TH>
-<TH><A HREF="procs.html">Procedures</A></TH>
-<TH><A HREF="demopic.gif">Screenshot</A></TH>
-</TR>
-<TR>
-<TH><A HREF="dump.html"><CODE>dump</CODE></A></TH>
-<TH><A HREF="tkcon.html"><CODE>tkcon</CODE></A></TH>
-<TH><A HREF="idebug.html"><CODE>idebug</CODE></A></TH>
-<TH><A HREF="observe.html"><CODE>observe</CODE></A></TH>
-</TR>
-</TABLE>
-<!-- end secondary navigation table -->
-</TD></TR><TR><TD BGCOLOR=#FFFFFF>
-<DIV CLASS="indent">
- <P>
-Most of the bindings are the same as for the Text widget.  Some have been
-modified to make sure that the integrity of the console is maintained.
-Others have been added to enhance the usefulness of the console.  Only
-the modified or new bindings are listed here.
- <P>
-
-<DL compact>
-<DT> <B>Control-x</B> or <B>Cut</B> (on Sparc5 keyboards)
-<DD> Cut
-<DT> <B>Control-c</B> or <B>Copy</B> (on Sparc5 keyboards)
-<DD> Copy
-<DT> <B>Control-v</B> or <B>Paste</B> (on Sparc5 keyboards)
-<DD> Paste
-<DT> <B>Insert</B>
-<DD> Insert (duh).
- <P>
-<DT> <B>Up</B>
-<DD> Goes up one level in the commands line history when cursor is on the
-prompt line, otherwise it moves through the buffer
-<DT> <B>Down</B>
-<DD> Goes down one level in the commands line history when cursor is on the
-last line of the buffer, otherwise it moves through the buffer
-<DT> <B>Control-p</B>
-<DD> Goes up one level in the commands line history
-<DT> <B>Control-n</B>
-<DD> Goes down one level in the commands line history
- <P>
-<DT> <B>Tab</B>
-<DD> Tries to expand file path names, then variable names, then proc names.
-<DT> <B>Escape</B>
-<DD> Tries to expand file path names.
-<DT> <B>Control-P</B>
-<DD> Tries to expand procedure names.  The procedure names will be those
-that are actually in the attached interpreter (unless nontcl is specified,
-in which case it always does the lookup in the default slave interpreter).
-<DT> <B>Control-V</B>
-<DD> Tries to expand variable names (those returned by [info vars]).
-It's search behavior is like that for procedure names.
- <P>
-<DT> <B>Return</B> or <B>Enter</B>
-<DD> Evaluates the current command line if it is a complete command,
-otherwise it just goes to a new line
-<DT> <B>Control-a</B>
-<DD> Go to the beginning of the current command line
-<DT> <B>Control-l</B>
-<DD> Clear the entire console buffer
-<DT> <B>Control-r</B>
-<DD> Searches backwards in the history for any command that contains the
-string in the current command line.  Repeatable to search farther back.
-The matching substring off the found command will blink.
-<DT> <B>Control-s</B>
-<DD> As above, but searches forward (only useful if you searched too far back).
-<DT> <B>Control-t</B>
-<DD> Transposes characters
-<DT> <B>Control-u</B>
-<DD> Clear the current command line
-<DT> <B>Control-z</B>
-<DD> Saves current command line in a buffer that can be retrieved with 
-another <B>Control-z</B>.  If the current command line is empty, then any
-saved command is retrieved without being overwritten, otherwise the
-current contents get swapped with what's in the saved command buffer.
- <P>
-<DT> <B>Control-Key-1</B>
-<DD> Attaches console to the console's slave interpreter
-<DT> <B>Control-Key-2</B>
-<DD> Attaches console to the console's master interpreter
-<DT> <B>Control-Key-3</B>
-<DD> Attaches console to main TkCon interpreter
-<DT> <B>Control-A</B>
-<DD> Pops up the "About" dialog
-<DT> <B>Control-N</B>
-<DD> Creates a new console.  Each console has separate state, including
-it's own widget hierarchy (it's a slave interpreter).
-<DT> <B>Control-q</B>
-<DD> Close the current console OR Quit the program (depends on the value
-of TKCON(slaveexit)).
-<DT> <B>Control-w</B>
-<DD> Closes the current console.  Closing the main console will exit the
-program (something has to control all the slaves...)
-</DL>
-
-TkCon also has <B>electric bracing</B> (similar to that in emacs).  It will
-highlight matching pairs of {}'s, []'s, ()'s and ""'s.  For the first three,
-if there is no matching left element for the right, then it blinks the
-entire current command line.  For the double quote, if there is no proper
-match then it just blinks the current double quote character.  It does
-properly recognize most escaping (except escaped escapes), but does not look
-for commenting (why would you interactively put comments in?).
-</DIV>
-</TD></TR></TABLE>
-
-<HR NOSHADE SIZE=1>
-<ADDRESS><FONT SIZE=2>© Jeffrey Hobbs</FONT></ADDRESS>
-
-</BODY>
-</HTML>
diff --git a/tkcon-2.5/docs/changes.txt b/tkcon-2.5/docs/changes.txt
deleted file mode 100755
index b0c8ed6..0000000
--- a/tkcon-2.5/docs/changes.txt
+++ /dev/null
@@ -1,815 +0,0 @@
-ENHANCED TK CONSOLE changes
--------------------------------------------------------------------------
-Changes file begun Tue May  7 19:09:51 PDT 1996
-Newest changes at top of file.  Release dates between '----'s.
-Changes for a particular version are BELOW the release date line.
-
-Attribution for code is specified after change, a preceding slash
-indicates an idea/bug report attribution fixed by myself.  Where
-no attribution is made, assume (Hobbs).
--------------------------------------------------------------------------
-
-THIS FILE IS NO LONGER PERTINENT.
-
-All changes are now recorded in the ChangeLog.
-
----- March 31 1999 v1.6 ----
-
-Changed tkConInsert to not use catch (avoids any error generation).
-
-Changed if check on auto_load in tcl_unknown to an llength on the
-args (from [info tclversion]) as 8.0p0 also used just one arg.
-
-Added -exec command line arg, so that users could do the -exec ""
-trick (causes tkcon to skip multi-interpreter model) and makes it
-easier to drop tkcon as a console on extended wish executables.
-
-Changed handling of fixed font for all tkcon text widgets, adding
-new -font option, TKCON(font) var, and redoing 'tkcon font'.
-
-Added color,(disabled|cursor|bg) variables as per Becker's
-recommendations, allowing for old defaults.
-
-Changed multiple instances of string comparisons with llength,
-where appropriate.
-
-Changed dump proc to not try and auto_load a proc arg and improved
-recognition of procs in namespaces.
-
-Added new 'what' proc to environment that tells you what a string
-is recognized as.  Now used in various other procs.
-
-Improved hot errors to not pop up edit dialog when the mouse moved.
-
----- March 5 1999 v1.5 ----
-
-Expanded tkConSave to support use in 'edit'.
-
-Added tkConGarbageCollect proc for periodic cleanup tasks
-(currently, cleaning up error tags in the console widget),
-with new gc-delay TKCON var.
-
-Revised error handling (errors are now hot in the console).
-
-Changed tkConExpandPathname to recognise that NT for 8.1+ is
-case-sensitive, and to not change case for other Windows configs
-when no further expansion was made.
-
-Made changes to tkConEvalOther and the aliasing of tkConEvalAttached
-for "Main" for more accurate evaluation.
-
-Changed the conditional 'update' in tkcon_puts (that overrides the
-core puts) to 'update idletasks'.  This prevents problems with
-using puts in fileevent triggers and such.
-
-Added check to prevent lower-casing during pathname expansion when
-no further expansion can be made on a string.
-
-New auto-buffer (default 512 lines, set in TKCON(buffer)) for the
-console widget.  Set this ridiculously high if you liked the
-text widget holding all that data.  New tkcon buffer method to
-go with it.
-
-Rewrote edit command.  Previous version was mostly bogus when used
-outside the original slave.
-
-Change tkcon error to use updated 'edit' command.
-
-Massaged tkConEvalOther & tkConInterpEval.
-
-Fixed problem with Show Last Error where a TkCon generated error
-was always appearing (from Package Submenu) and moved it above
-the packages submenu.
-
-Removed auto_execok from the slaveprocs list.
-
-Removed slaveappalias as it didn't work correctly.  Made 'edit'
-a slavealias, with tkConAttach used to determine where it was
-called from
-
-Changed some regexps around to pass tclCheck's mistaken warnings
-(tclCheck's bad matching, not bad regexps).
-
-Changed dump to not try widgets before commands, as otherwise
-it won't automatically complain.
-
-Fixed pathname completion to only beep when trying to expand on a
-non-existent subdirectory (instead of throwing no-directory error).
-
-Fixed a few notes that TclPro's checker picked up (only one actual
-bug in the all switch of 'edit', otherwise it was mostly blowing
-wind...).  (lvirden)
-
----- February 17 1999 v1.4 ----
-
-Changed "changes" file to "changes.txt".
-
-Added edit/more/less proc that allows for the viewing/editing
-and returning back to the slave of vars/procs or files.
-
-Modified history to not got below 0.
-
-lremove extended with -pattern arg.
-
-Added code in tcl_unknown to ask about loading Tk when someone tries
-a Tk command without Tk being loaded.
-
-Had to change regexps because \E in Tcl8.1a2 was removed in 8.1b1 (arg!).
-
-Added "Make Xauth Secure" button for Unix. (heiko.federhenn at stest.ch)
-
-Fixed tkConInitInterp (used by "Send TkCon Commands") to reattach to
-the named namespace when appropriate.
-
-Fixed bug in popup-menu for Tk8 (bound to wrong toplevel).
-
-Fixed bug in tcl_unknown confusing auto_load between 8.0 and 7.x.
-
-Made Interp->Package menu more dynamic, so it recognizes changes in
-auto_path and updates itself when Interp is torn-off.
-
-Removed list from $new in exec redirect for tcl_unknown. (found by Imai)
-
-Changed package menu to handle multiple package versions.
-
-Added bogus package require statement to master and slaves to ensure
-that pkgIndex.tcl files were properly loaded into interps.
-
-If "Main" is passed to tkConAttachNamespace, it is interpreted as "::".
-
-Changed "Attach Namespace" menu to provide a listbox popup when
-more than $TKCON(maxmenu) namespaces are present.
-
----- June 1998 v1.3 ----
-
-fixed long-standing expr bug (missing '$') in tkConSafeBind - found
-by TclPro!
-
-took out the use of tkcon_gets because it only worked for global vars.
-
----- March 1998 v1.2 unreleased ----
-
-updated regexps in some places to support 8.1 regexps.
-
-dump now outputs only non-default options for widgets. (ridgway)
-
-Sorted output list for multiple tab matched items.
-
-Several minor changes for the plugin (user should see no difference).
-
-Known problems with dump command understanding namespaces have been
-fixed, but only for the 8.0 only version.
-
-Changed tkConTagProc to recognize ';' as not part of a proc name.
-
-Changed tkConNew to reuse slave numbers.
-
-Fixed problem with TKCON(exec) == {} (needed uplevel #0 instead of eval).
-
-On Mac, tries to source itself using -rsrc (8.0). (nijtmans)
-
-Changed to use 8.0 menu scheme if possible. (nijtmans)
-
-Changed tkConInitSlave and tkConNew to only set argv0 in new slave if it
-exists (it won't in the plugin).  (demailly)
-
-Changed tkConInit to only checkpoint state once if the slave interp
-and main interp are the same (TKCON(exec) == {}).
-
----- 08 October 1997 v1.1 ----
-
-For Tk8, made TkCon use a fixed font {Courier, size 10} if the current
-font is not of fixed type.
-
-Startup errors should now be found in the TkCon last error function.
-
-Changed the Triple-1 binding to not include last newline.
-
-Added fix to make sure that double-evaluation of the command line
-didn't occur (might occur for commands that used vwait or something).
-
-TKCON(errorInfo) is now set with all the errors that occur during start-up,
-so that you don't lose stack trace information.
-
----- July 03 1997 v1.03 ----
-
-Updated namespace eval stuff for Tk8.0b2.
-
-rewrote tkConSepCmd.
-
-ls is now "dir -full" by default.
-
-changed the puts renaming from tcl_puts to tkcon_tcl_puts (so that it
-specifies what renamed it).
-
-added variable highlighting to command highlighting as a background (so
-that a command and var can be seen for the same word).
-
-increased default history size to 48.
-
-Fixed problem where aliased exit couldn't take extra args.
-
-replaced old [tkcon gets] with a new UI version to be used with the new
-tkcon_gets that, like tkcon_puts, replaces the Tcl gets with a version that
-doesn't rely on stdin being present.  [tkcon gets] now accepts no args.
-	**** POTENTIAL INCOMPATIBILITY ****
-
----- June 10 1997 v1.02 ----
-
-Changed calculator mode commands to be put in the history (but the
-output still looks like an error).
-
-Fixed bug where "source" was assumed to work for primary interp,
-causing failure to load in Tk plugin.
-
-Fixed problem with the id'ing of the primary TkCon interpreter that would
-affect attaching to like named interps.
-
----- June 8 1997 v1.01 ----
-
-minor streamlining in tkConEvalCmd.
-
-added file menu and separated some items from console menu.
-
-added support for connecting directly to a namespace (itcl or Tcl8).
-
-Fixed several potential problems where args to tkConEvalAttached where
-not properly protected from eval.
-
-added slaveexit variable to allow for exit in slaves to be non-destructive,
-which is the new default.
-
-enhanced Tab binding, made Escape the default pathname-only expansion.
-
-enhanced dump and which commands.
-
-Removed auto_execok redefinition for Tcl7.5-.  TkCon is now intended to
-only run in Tcl7.6+ interpreters (though attaching to 7.5- is still OK).
-
-Added Load/Save menus and expanded Save functionality.
-
----- June 1 1997 v1.00 ----
-
-TkCon now use virtual events for bindings (REQUIRES TK4.2+) and changed
-Console to TkConsole (to not conflict with new Console megawidget).
-
-Updated tcl_unknown to match Tcl8's unknown.
-
-Changed handling of preferences directory for macintosh.
-	**** POTENTIAL INCOMPATIBILITY ****
-
-Changed tkCon global var to TKCON.
-	**** POTENTIAL INCOMPATIBILITY ****
-
-Changed colors to use absolute #RRGGBB format for color-name disadvantaged
-systems.
-
-Removed use of tkCon(font) variable.
-	**** POTENTIAL INCOMPATIBILITY ****
-
-Fixed procname expansion to work on/in namespaces.
-
-Fixed pathname expansion to expand on a directory.
-
-Fixed all if's to use {}s (better for Tcl8).
-
-Fixed potential paste problems, it now tries to get the general selection
-first, then the CLIPBOARD selection.
-
-Fixed problem with 'puts' being renamed too early.
-
-Added calcmode variable to allow typing expr commands write at the tkCon
-command line without always saying expr (handled in tkConEvalCmd).
-
----- no official release v0.72 ----
-
-Changed tkConAbout to use text widget so info could be selected.
-
-Fixed problem with pathname expansion on windows due to case insensitivity.
-(how can anyone work with such an insensitive OS?)
-
-Fixed off-by-one error in history substitution reported by
-<s-imai at lsi.tmg.nec.co.jp>.
-
-Fixed error in the handling of packages with a space in the name.
-
-Removed general return of output from rcfile, now only errors are returned.
-
-New tkConEvent proc to handle event movement, fixed search event problem
-where cached event would become incorrect.
-
-new blinkrange variable to change electric bracing style.
-
----- December 20th 1996 v0.71 ----
-
-changed to not use upvar for nested arrays (bad for Tcl8).
-
-catch package require statement for detecting loadable libraries.
-
----- November 15th 1996 v0.70 ----
-
-Fixed problem with virtual event C/C/P bindings. (reported by
-robin at jessikat.demon.co.uk)
-
----- November 15th 1996 v0.69 ----
-
-Added auto_execok to tkCon(slaveprocs), fixes "unknown" command bug.
-
-Fix for 'event' to work with plugin.  (nijtmans)
-
-Added '--' and '-filter' options to 'dump'.
-
----- November 13th 1996 v0.68 ----
-
-Added $tk_library to auto_path for safe slaves loading Tk. (nijtmans)
-
-Made "r" the default mode for tkConSafeOpen. (nijtmans)
-
-Changed global delcarations in tkConInit to avoid conflicts with
-Nijtmans' plus patch.
-
----- November 11th 1996 v0.67 ----
-
-Fixed weird backslashing in tkConSafeWindow
-
----- November 8th 1996 v0.66 ----
-
-Further changes for Tk plugin compatibility. (nijtmans)
-
----- November 7th 1996 v0.65 ----
-
-Started to add to plugin compatible code.  (nijtmans)
-
-Reworked tkConFind* to accept optional args.
-
-Added History menu which display last ten commands in history.
-
-Removed 'auto_execpath' and changed for new version of 'auto_execok' (in
-'which' and 'unknown'), which will be redefined when TkCon is run in Tcl7.5.
-
-The attached environment is now checkpointed at startup (by default
-this is the slave).
-
-Fixed 'dump var' to use list when printing out nested array elements
-
-Added 'update' to puts, as well as better error reporting for tcl_puts.
-(nijtmans)
-
-Improved bracing around elseif statements.
-
-Removed 'warn' alias from distribution.  Seemed superfluous.
-
-Added support for requiring Tk in Tcl8+.
-
-Made TkCon use tkCon(cols) and tkCon(rows) for startup text size.
-
----- September 30th 1996 v0.64 ----
-
-Changed the way 'idebug' integrates with TkCon.
-
-Changed to require Tk of version [expr $tcl_version-3.4].
-
-Fixed bug in observe_var (upvar shouldn't have had the \#0).
-
-Made Interp->Inspect menu disappear if TkConInspect package was not present.
-
-Made package handling only enabled for Tcl7.5+ interps and reworked
-how packages were recognized.
-
-! Removed virtual events from Console bindings so that they don't screw
-! up the Console bindings (temporary fix).
-
-Changed how initially loaded packages were detected. (nijtmans)
-
-Made all globals visible in tkConInit. (/nijtmans)
-
----- September 23rd 1996 v0.63 ----
-
-Changed 'tkConFindBox' to not screw up search string.
-
----- September 20th 1996 v0.62 ----
-
-Added option for automagically ignoring dead interpreter problems. (wart)
-
-Fixed bug for reattaching to default slave via menu. (wart)
-
-Changed how 'observe' spit out trace info for commands.
-
-Modified 'idebug' internals.
-
-Made 'idebug' create its own tkCon(exec) slave for maintaining history.
-
-Fixed long-standing bug in 'lremove' for -all switch.
-
-Made tkCon(SCRIPT) follow links to the true source script.
-
-Added 'idebug puts' and 'idebug echo' methods.
-
-Fixed 'idebug break' to not work at level 0.
-
-Removed line that could improperly set $name and placed a 'catch'
-around the 'interp alias' for 'ls' in tkConInitInterp.
-
-tkConInit(Slave|Interp) now just 'catch'es the renaming of puts.
-
-Added 'tkcon set' and 'tkcon upvar' methods. (nijtmans)
-
----- September 17th 1996 v0.61 ----
-
-Added 'idebug' interactive debugging proc based off Stephen Uhler's all-Tcl
-debugger (Oct'95 _Linux_Journal_).  Should work w/ or w/o TkCon.
-
-Added back accidental removal of 'ls' alias in slaves.
-
----- September 15th 1996 v0.60 ----
-
-Added 'tkcon find str' method and find box to TkCon.
-
-Added 'observe{_var}' command for simple tracing of vars/cmds with
-output in the TkCon console window.
-
-Reworked tkConFillAppsMenu to be more efficient and correct.
-
-Added 'echo' as an internal proc and included it in tkCon(slaveprocs).
-
-Removed tkCon(prompt2).
-
-Changed tkCon(lightcmd) default to 1 from 0.
-
-Improved 'tkcon error' to allow it to check the errorInfo of other apps.
-
-'dump var' now outputs nested array values. (loverso)
-
-Changed tkCon(Load|Save) to use the new Tk4.2 dialogs if available.
-
-Fixed tkConPrompt problem where marks were set incorrectly sometimes
-when it was called by an event (such as <Control-1>).
-
-Added bgerror to slaves and 'tkcon bgerror' method. (nijtmans)
-
-Added tcl_unknown along with other minor mods to get TkCon to work better
-with IncrTcl. (nijtmans)
-
-Made <Triple-1> binding not include the prompt.
-
-Add null Console bindings for the tkCon(root) bindings to avoid them
-getting generated spuriously. (Hobbs / Wart)
-
-Added -argv/-- command line option.  This has very limited use, but is very
-good for wrapping TkCon around an existing application which has it's own
-command line args.  It resets $argv in the main interpreter to what remains
-on the command line and TkCon ignores argv.  This carries over to any "New
-Consoles".
-
-Reintroduced state procedures, placed them in Interp menu.  These should
-only be used if you really understand what they do.
-
-Added 'dump command' method.  Usefulness over 'dump proc' is minimal.
-
-Tightened up the command line args, dropped several optional switches.
-
-Placed all the Console bindings into tkConBindings, which is called
-in tkConInitUI.
-
-Added 'tkConInitInterp' which places the tkCon shell commands (already
-available in any tkCon slave) in the interpreter.  It also rewires
-puts to send the result back to tkCon.
-
-Fixed dead attachment problem where attaching to another interp after
-being connected to a dead interp would munge the new interp's name. (H / Wart)
-
-Added 'tkConEvalOther' which evals in the named interpreter.
-
-Removed 'tkConCheckPackages'.  Package handling is now separated into the
-autoloading part in tkConInit and into tkConInterpMenu which determines
-available static libraries and packages for an interpreter.  Menus redesigned.
-
-Changed 'tkcon eval' to 'tkcon master' since eval gave the wrong connotation.
-
-Made '-nontcl' option take a TCL_BOOLEAN argument.
-
-Made 'which' return unknown commands as an error.
-
-Added button into the help window to send the help URL to netscape.
-
-Made history substitution spit out a correctly translated command if
-evaluation doesn't return an error.
-
-Changed history search to use the same event id as regular command line
-history.
-
-Added tkCon(meta) variable which varies the Meta definition based on the
-platform (Unix == Meta; Win == Alt; Mac == Command)
-
-Added 'dump widget' method.  Spits out current widget state as returned
-by '.widget configure'.
-
-Changed 'dump proc' and 'which' to try and auto_load an unknown procedure.
-
-Added 'tkcon history' command to return a source'able history stack.
-
-Fixed off-by-one error in tkConExpand (caused expansion to not work unless
-you were expanding the last thing on the line and also not if a special
-char was the first on the line).
-
-Fixed TkCon package handling to work properly for IncrTcl. (nijtmans)
-
----- July 31 1996 v0.52 ----
-
-Reversed changes file to have newest at top.
-
-Added 'tkcon version' command.
-
-Fixed scoping problem when attaching to the master interpreter of a
-particular console.
-
-Rewrote the expansion routines to handle spaces in names better (no longer
-requires the user to use grouping as it puts in '\ ' for spaces).
-
-Fixed off-by-one bug in tkConExpandBestMatch(2).
-
-Rewired attachments so that when 'send' is used to attach to an app and an
-error occurs, TkCon determines whether the app still exists to prevent
-multiple errors from arising due to a dead attachment.  If this occurs, it
-prompts the user on whether to return to the primary slave or to check
-periodically for the attached interpreter to come back.  tkConEvalSend was
-added to facilitate this.
-
-Command highlighting is now only attempted when a non-empty character is
-inserted into the command line (%A != {}).
-
-Added Ctrl-2 accelerator to get attach to master interpreter of a console
-and Ctrl-3 to get to attach to the Main interpreter.
-
-Made the attachment to Main set the tkCon(app) to Main (to get around the
-menu -value {} bug) and also set tkConEvalAttached alias to 'tkConMain eval'.
-
-Rewrote tkConPrompt to accept "pre" and "post" args to place before and
-after the prompt is printed.  pre is tagged stdout, post is tagged stdin.
-
-Rewrote 'dump var' to recognize nested arrays, but not output them
-(it's too complicated to do that in source'able form), as well as
-recognize empty arrays.
-
-Rewrote tkConEvalCmd to keep track of errorInfo when errors occur.
-
-Added 'tkcon error' to display the last errorInfo.
-
-Changed dumpproc and dumpvar to dump (proc|var) ...
-
-Added -root argument to set the tkCon(root) variable explicitly.
-
-Changed the -(slave)eval args to append to rather than set their vars
-so that they can be specified multiple times on the command line.
-
-Added a limit argument to tkConMatch{Quote,Pair}.
-
-Rewrote dumpvar to recognize a single array value name (ie: a(b)).
-
-Renamed default non-Unix resource filename from from tkcon.bat to tkcon.cfg.
-
-No longer 'catch' the renaming of puts in a slave, because we'd want to
-know if that threw an error, although it never should...
-
----- July 14 1996 v0.51 ----
-
-Removed tkConUsage since it was never called.
-
-Changed tkCon(Load|Save) to use tkFileSelect, if it exists.
-
-Added -load and -pkg equivalents for -package.
-
-Added Ctrl-Key-1 binding to reattach to primary slave.
-
-TkCon now will create itself in a different toplevel if there are already
-children of . when tkConInit is called.
-
-Changed tkConInitSlave not to overwrite tcl_puts in a slave if it exists.
-
-Created tkCon(slaveprocs) to identify what procs get dumped into a
-slave each time and tkCon(slavealias) to identify what will be
-aliased back into the main interpreter.
-
----- July 4 1996 v0.50 ----
-
-Number of history events to keep now set by tkCon(history).
-
-'unknown' reworked (yet again) to properly handle itself in either the slave
-or another interpreter.  History substition was moved into tkConEvalCmd and
-made an option (via tkCon(subhistory)).
-
-Inlined _dir into dir/ls.  It doesn't save any cycles, but it removes
-the need to manage _dir.
-
-Fixed 'dir/ls -f' to denote executable files with a *.
-
-Fixed dir/ls to not die on 'dir -f <pattern>'. (Thanks to steven at indra.com)
-
-Changed tkConExpand to stop at $ as well.
-
-Changed tkConTagProc binding from Console <KeyRelease> to PostCon <KeyPress>.
-It seems to miss a lot less now.
-
----- July 3 1996 v0.49 ----
-
-Slight mod to <BackSpace>.
-
-Fixed <Delete> binding to not allow deletions of pre-Prompt text when a
-selection is made.
-
-Fixed tkConEvalCmd to properly send commands to foreign interpreters even
-if $tkCon(nontcl) was set.
-
-Made tkConEvalAttached be some type of alias at all times.
-
-Changed 'slavescript' to 'slaveeval' and added an 'eval' option.
-
----- June 25 1996 v0.48 ----
-
-Fixed 'alias' problem with multiple args.
-
-Updated binding system to automatically set Console bindings to equivalent
-Text bindings, then redefine what we want.
-
-Updated tkConTagProc to eval in attached slaves.  This can make it
-really slow when attached to foreign interpreters.
-
----- June 25 1996 v0.47 ----
-
-Fixed tkConExpandBest* to be more accurate ([string first] is only valid
-for us when it returns 0).
-
-Updated tkConExpandPathname to work better for attached interpreters.
-
-Renamed tkExpand* to tkConExpand* (they'd become too TkCon oriented).
-
-Changed tkConEvalCmd to 'list' instead of 'concat' command for attached
-interpreters, and to ignore the whole thing if [string match {} $cmd].
-
-Removed many bindings that were exactly duplicated by "Text" binding.
-
-Added tkCon(blinktime) option to allow user to specify blink duration.
-Value must be at least 100 (millisecs).
-
-Removed tkConUpDownLine.  It never varied from tkTextUpDownLine.
-
-Improved package loading to handle bad pkgIndex.tcl entries.
-
----- June 21 1996 v0.46 ----
-
-Improved package loading to be correct.
-
-Made 'dir' more Mac/Windows friendly (I hope).
-
----- June 21 1996 v0.45 (skipped v0.44) ----
-
-Added "Non-Tcl Attachments" preference to disallow sends to interpreters
-which may not understand Tcl (ie - SchemeTk, PerlTk).
-
-Rewrote tkConCheckPackages to allow calling it without a widget reference.
-
-Updated tkConEvalCmd.
-
-Added tkConEvalAttached to evaluate more things in the right place.
-
-Rewrote tkConAttach to allow for attaching directly to slave interpreters
-(no send required).  "Attach Console" menu now lists all slave interpreters
-by slave path (with Tk interp name in ()s), separate from foreign interps.
-
-Add tkConInitSlave to create a TkCon slave.
-
-Renamed tkExpand* to tclExpand*.
-
-Updated 'dir' for better output.
-
-Added command line argument support, rearranged tkConInit to support it.
-
----- June 18 1996 v0.43 ----
-
-Fixed 'unknown' to work in both slave and master interpreter.
-
-Modified 'dir' to be dumpproc'ed into slave.
-
-Rewrote 'clear' to be dumpproc'ed as well.
-
-Fixed 'puts' bug for slaves.
-
----- June 17 1996 v0.42 ----
-
-Added extra loop to tkConCheckPackages to account for packages that may
-auto-load Tk itself (like Tix or Tksteal).
-
----- June 15 1996 v0.41 ----
-
-Added 'warn' as an alias back into the main interpreter.
-
-Fixed documentation leftovers (and updated upgrade.html) to include the
-move of the 'main' and 'slave' commands into 'tkcon'.
-
-Fixed problem in 'clear' command
-
----- June 14 1996 v0.40 Released ----
-
-OK, I need to add some MAJOR changes here...
-
-Added package handling.
-
-Moved to two-level interpreter model (master control/slave execution).
-
----- June 13 1996 v0.38 ----
-
-Fixed auto_execpath to work on windows
-
----- June 11 1996 v0.37 ----
-
-Improved 'tkConResource' to get the right script name on all platforms
-under all manner of circumstances
-
-Improved sourcing of tkCon resource file to not throw bogus errors
-
----- Jun 10 1996 v0.36 ----
-
-Fixed <Control-n> bug (incr $tkCon(event) --> incr tkCon(event))
-
----- June 8 1996 v0.35 ----
-
-Removed "Resource" from 'Edit' menu
-
-Rewrote 'clear' to accept percentage level
-
-Fixed <Control-s> forward history search bug
-
----- June 6 1996 v0.34 ----
-
-Added 'clean' alias to revert a slave to its "pristine" state
-
-Added tkConState* procs to monitor state and be able to revert it
-
-Enhanced 'which' and added an 'auto_execpath' proc.
-
-Removed all known global uses of 'tmp*' variables.
-
-Fixed problem in tkExpandPathname that munged pathnames with spaces.
-
-Fixed problem in many places where spaces in directories and command names
-might get things confused.
-
-Fixed problem with non-interactive slaves.
-
-Commented out binding that recreates a deleted console window.
-
-Add tclindex command.
-
-Added support for -full to ls/dir.
-
-Added command buffer save and command buffer search bindings.
-
-Added Prefs menu.
-
-Changed File menu name to Console.
-
-Removed 'Load/Save File' command from File menu (to easy to source) and
-added 'save' command.
-
-Changed dumpvar to use "array set ..." when outputting array values.
-
-Changed tkCon to use tkcon.rc on non-unix machines.
-
-Revamped tkConInit and source file to make sure nothing specific to tkCon
-was set until an Init proc was called.
-
----- May 10 1996 Made 0.27 Available to the public ----
-
----- May 8 1996 Released 0.26 Third semi-public release ----
-
-tkConNew now returns the name of the newly created interpreter.
-
-Added 'main' and 'slave' inter-console communication commands.  Also,
-all slave interpreters become commands in all slave consoles (make sure
-not to name procs "slave#") when created.  tkConOtherInterp proc added
-to handle the communication.
-
-Moved tkConDestroy and tkConNew into new proc tkConMainInit to prevent
-resourcing problems with slave interpreters
-
-Fixed 'puts' bug by removing all 'uplevel subst ...' and placing an
-'eval ...' at the beginning.
-
----- May 7 1996 Released 0.25 Second semi-public release ----
-
-Discovered bug in puts/output sequence - still searching
-
-Added unalias command, fixed alias command to not unalias commands if
-not enough args were passed
-
-Updated 'unknown' to mirror current tcl7.5 'unknown'
-
-Changed var names inside some procs
-
-Added comments to most procs
-
-Fixed off-by-one bug in tkExpandPathname
-
----- May 4 1996 Released 0.24 First semi-public release ----
-
-Changes file begun Tue May  7 19:09:51 PDT 1996
diff --git a/tkcon-2.5/docs/demopic.png b/tkcon-2.5/docs/demopic.png
deleted file mode 100644
index 799c09c..0000000
Binary files a/tkcon-2.5/docs/demopic.png and /dev/null differ
diff --git a/tkcon-2.5/docs/dump.html b/tkcon-2.5/docs/dump.html
deleted file mode 100755
index 4d5f027..0000000
--- a/tkcon-2.5/docs/dump.html
+++ /dev/null
@@ -1,100 +0,0 @@
-<HTML>
-<HEAD>
-<TITLE>tkcon: dump procedure</TITLE>
-<LINK REL="STYLESHEET" TYPE="text/css" HREF="./style.css">
-</HEAD>
-
-<BODY BGCOLOR=#FFFFFF>
-
-<TABLE WIDTH=100% BORDER=0 CELLSPACING=2 CELLPADDING=0 BGCOLOR=#000000><TR><TD>
-<!-- start header info -->
-<TABLE WIDTH=100% BORDER=0 CELLSPACING=0 CELLPADDING=0 BGCOLOR=#FFFFFF>
-<TR>
-<TH><FONT SIZE=+3>tkcon: <CODE>dump</CODE> procedure</FONT></TH>
-<TD align=right>
-<A href="http://tkcon.sourceforge.net/"> 
-<IMG src="http://sourceforge.net/sflogo.php?group_id=11462&type=1" width="88"
-height="31" border="0" alt="SourceForge Logo"></A>
-</TD>
-</TR>
-</TABLE>
-<!-- end header info -->
-
-</TD></TR><TR><TD>
-<!-- start main navigation table -->
-<TABLE BORDER=1 CELLPADDING=2 CELLSPACING=2 BGCOLOR=#CCCCCC width=100%>
-<TR>
-<TH CLASS="hi"><A HREF="index.html" CLASS="hi">Documentation</A></TH>
-<TH><A HREF="purpose.html">Purpose & Features</A></TH>
-<TH><A HREF="limits.html">Limitations</A></TH>
-<TH><A HREF="todo.html">To Do</A></TH>
-<TH><A HREF="license.terms">License</A></TH>
-</TR><TR>
-<TH COLSPAN=2><A HREF="plugin.html">Online Demo</A>
-(requires <A HREF="http://tcl.activestate.com/software/plugin/">Tk plugin</A>)</TH>
-<TH COLSPAN=3><A HREF="nontcl.html">Using TkCon with other Tk Languages</A></TH>
-</TR>
-</TABLE>
-<!-- end main navigation table -->
-</TD></TR><TR><TD>
-<!-- start secondary navigation table -->
-<TABLE BORDER=1 CELLPADDING=2 CELLSPACING=2 BGCOLOR=#BBBBBB width=100%>
-<TR>
-<TH><A HREF="start.html">Getting Started</A></TH>
-<TH><A HREF="bindings.html">Special Bindings</A></TH>
-<TH><A HREF="procs.html">Procedures</A></TH>
-<TH><A HREF="demopic.gif">Screenshot</A></TH>
-</TR>
-<TR>
-<TH CLASS="hi2"><A HREF="dump.html" CLASS="hi2"><CODE>dump</CODE></A></TH>
-<TH><A HREF="tkcon.html"><CODE>tkcon</CODE></A></TH>
-<TH><A HREF="idebug.html"><CODE>idebug</CODE></A></TH>
-<TH><A HREF="observe.html"><CODE>observe</CODE></A></TH>
-</TR>
-</TABLE>
-<!-- end secondary navigation table -->
-</TD></TR><TR><TD BGCOLOR=#FFFFFF>
-<DIV CLASS="indent">
- <P>
-The <CODE>dump</CODE> command provides a way for the user to spit out
-state information about the interpreter in a Tcl readable (and human
-readable) form.  It takes the general form:
-
-<BLOCKQUOTE>
-<code>dump</code> <b>method</b> <i>?-nocomplain? ?-filter pattern? ?--?
-pattern ?pattern ...?</i>
-</BLOCKQUOTE>
-
-The patterns represent glob-style patterns (as in <code>string match pattern
-$str</code>).  <i>-nocomplain</i> will prevent <code>dump</code> from
-throwing an error if no items matched the pattern.  <i>-filter</i> is
-interpreted as appropriate for the method.  The various methods are:
-
-<DL>
-
-<DT> <CODE>dump <b>command</b></CODE> <i>args</i>
-<DD> Outputs one or more commands.
-
-<DT> <CODE>dump <b>procedure</b></CODE> <i>args</i>
-<DD> Outputs one or more procs in sourceable form.
-
-<DT> <CODE>dump <b>variable</b></CODE> <i>args</i>
-<DD> Outputs the values of variables in sourceable form.  Recognizes nested
-arrays.  The <i>-filter</i> pattern is used as to filter array element
-names and is interepreted as a glob pattern (defaults to {*}).
-It is passed down for nested arrays.
-
-<DT> <CODE>dump <b>widget</b></CODE> <i>args</i>
-<DD> Outputs one or more widgets by giving their configuration options.
-The <i>-filter</i> pattern is used as to filter the config options and
-is interpreted as a case insensitive regexp pattern (defaults to {.*})
-
-</DL>
-</DIV>
-</TD></TR></TABLE>
-
-<HR NOSHADE SIZE=1>
-<ADDRESS><FONT SIZE=2>© Jeffrey Hobbs</FONT></ADDRESS>
-
-</BODY>
-</HTML>
diff --git a/tkcon-2.5/docs/dump.n.man b/tkcon-2.5/docs/dump.n.man
deleted file mode 100644
index de2839f..0000000
--- a/tkcon-2.5/docs/dump.n.man
+++ /dev/null
@@ -1,60 +0,0 @@
-[comment {-*- tcl -*- dump manpage}]
-[manpage_begin dump n 2.5]
-[copyright {Jeffrey Hobbs <jeff at hobbs.org>}]
-[moddesc   {TkCon}]
-[titledesc {Dump information about Tcl interpreter in TkCon}]
-
-[description]
-[para]
-The dump command provides a way for the user to spit out state
-information about the interpreter in a Tcl readable
-(and human readable) form.
-It takes the general form:
-
-[list_begin definitions]
-
-[call [cmd dump] [arg method]\
-		 [opt [arg -nocomplain]]\
-		 [opt [arg "-filter pattern"]]\
-		 [opt [cmd --]]\
-		 [arg pattern]\
-		 [opt [arg "pattern ..."]]]
-
-[list_end]
-
-[para]
-The patterns represent glob-style patterns (as in [cmd string] [arg {match pattern $str}]).
-[arg -nocomplain] will prevent dump from throwing an error if no items
-matched the pattern.
-[arg -filter] is interpreted as appropriate for the method.
-The various methods are:
-
-[list_begin definitions]
-
-[lst_item "[cmd dump] [arg command] [arg args]"]
-Outputs one or more commands.
-
-[lst_item "[cmd dump] [arg procedure] [arg args]"]
-Outputs one or more procs in sourceable form.
-
-[lst_item "[cmd dump] [arg variable] [arg args]"]
-Outputs the values of variables in sourceable form.
-Recognizes nested arrays.
-The -filter pattern is used as to filter array element
-names and is interepreted as a glob pattern (defaults to {*}).
-It is passed down for nested arrays.
-
-[lst_item "[cmd dump] [arg widget] [arg args]"]
-Outputs one or more widgets by giving their configuration options.
-The -filter pattern is used as to filter the config options and
-is interpreted as a case insensitive regexp pattern (defaults to {.*}).
-
-[list_end]
-
-[see_also [cmd tkcon](1)]
-[see_also [cmd tkconrc](5) [cmd tkcon](n) [cmd idebug](n)]
-[see_also [cmd observe](n)]
-[keywords Tk console dump]
-
-[manpage_end]
-
diff --git a/tkcon-2.5/docs/idebug.html b/tkcon-2.5/docs/idebug.html
deleted file mode 100755
index de604a8..0000000
--- a/tkcon-2.5/docs/idebug.html
+++ /dev/null
@@ -1,125 +0,0 @@
-<HTML>
-<HEAD>
-<TITLE>tkcon: idebug procedure</TITLE>
-<LINK REL="STYLESHEET" TYPE="text/css" HREF="./style.css">
-</HEAD>
-
-<BODY BGCOLOR=#FFFFFF>
-
-<TABLE WIDTH=100% BORDER=0 CELLSPACING=2 CELLPADDING=0 BGCOLOR=#000000><TR><TD>
-<!-- start header info -->
-<TABLE WIDTH=100% BORDER=0 CELLSPACING=0 CELLPADDING=0 BGCOLOR=#FFFFFF>
-<TR>
-<TH><FONT SIZE=+3>tkcon: <CODE>idebug</CODE> procedure</FONT></TH>
-<TD align=right>
-<A href="http://tkcon.sourceforge.net/"> 
-<IMG src="http://sourceforge.net/sflogo.php?group_id=11462&type=1" width="88"
-height="31" border="0" alt="SourceForge Logo"></A>
-</TD>
-</TR>
-</TABLE>
-<!-- end header info -->
-
-</TD></TR><TR><TD>
-<!-- start main navigation table -->
-<TABLE BORDER=1 CELLPADDING=2 CELLSPACING=2 BGCOLOR=#CCCCCC width=100%>
-<TR>
-<TH CLASS="hi"><A HREF="index.html" CLASS="hi">Documentation</A></TH>
-<TH><A HREF="purpose.html">Purpose & Features</A></TH>
-<TH><A HREF="limits.html">Limitations</A></TH>
-<TH><A HREF="todo.html">To Do</A></TH>
-<TH><A HREF="license.terms">License</A></TH>
-</TR><TR>
-<TH COLSPAN=2><A HREF="plugin.html">Online Demo</A>
-(requires <A HREF="http://tcl.activestate.com/software/plugin/">Tk plugin</A>)</TH>
-<TH COLSPAN=3><A HREF="nontcl.html">Using TkCon with other Tk Languages</A></TH>
-</TR>
-</TABLE>
-<!-- end main navigation table -->
-</TD></TR><TR><TD>
-<!-- start secondary navigation table -->
-<TABLE BORDER=1 CELLPADDING=2 CELLSPACING=2 BGCOLOR=#BBBBBB width=100%>
-<TR>
-<TH><A HREF="start.html">Getting Started</A></TH>
-<TH><A HREF="bindings.html">Special Bindings</A></TH>
-<TH><A HREF="procs.html">Procedures</A></TH>
-<TH><A HREF="demopic.gif">Screenshot</A></TH>
-</TR>
-<TR>
-<TH><A HREF="dump.html"><CODE>dump</CODE></A></TH>
-<TH><A HREF="tkcon.html"><CODE>tkcon</CODE></A></TH>
-<TH CLASS="hi2"><A HREF="idebug.html" CLASS="hi2"><CODE>idebug</CODE></A></TH>
-<TH><A HREF="observe.html"><CODE>observe</CODE></A></TH>
-</TR>
-</TABLE>
-<!-- end secondary navigation table -->
-</TD></TR><TR><TD BGCOLOR=#FFFFFF>
-<DIV CLASS="indent">
- <P>
-The <B>idebug</B> command provides an interactive debugging environment for
-procedures via TkCon.  You can place <code>idebug break</code> commands
-into your procedure to create breakpoints.  It will pop up the TkCon
-console and put you into a "debugging" mode.  The <code>body, show &
-trace</code> methods are intended for internal use only.
- <P>
-
-This procedure works for minimal debugging sessions.  Comments are
-encouraged.
-
-<DL>
-
-<DT> <CODE>idebug <b>body</b></CODE> <I>?level?</I>
-<DD> Prints out the body of the command (if it is a procedure) at the
-specified level.  <i>level</i> defaults to the current level.
-
-<DT> <CODE>idebug <b>break</b></CODE> <I>?id?</I>
-<DD> Creates a breakpoint within a procedure.  This will only trigger if
-idebug is on and the id matches the pattern.  If so, TkCon will pop to the
-front with the prompt changed to an idebug prompt.  You are given the basic
-ability to observe the call stack an query/set variables or execute Tcl
-commands at any level.  A separate history is maintained in debugging mode.
-To see the special commands available at the debug prompt, type <B>?</B>
-and hit return.
-
-<DT> <CODE>idebug {echo ?id?}</CODE> <I>?args?</I>
-<DD> Behaves just like <code>echo</code>, but only triggers when idebug is
-on.  You can specify an optional id to further restrict triggering.  If no
-id is specified, it defaults to the name of the command in which the call
-was made.
-
-<DT> <CODE>idebug <b>id</b></CODE> <I>?id?</I>
-<DD> Query or set the idebug id.  This id is used by other idebug methods
-to determine if they should trigger or not.  The idebug id can be a glob
-pattern and defaults to *.
-
-<DT> <CODE>idebug <b>off</b></CODE>
-<DD> Turns idebug off.
-
-<DT> <CODE>idebug <b>on</b></CODE> <I>?id?</I>
-<DD> Turns idebug on.  If <i>id</i> is specified, it sets the id to it.
-
-<DT> <CODE>idebug {puts ?id?}</CODE> <I>args</I>
-<DD> Behaves just like <code>puts</code>, but only triggers when idebug is
-on.  You can specify an optional id to further restrict triggering.  If no
-id is specified, it defaults to the name of the command in which the call
-was made.
-
-<DT> <CODE>idebug <b>show</b></CODE> <I>type ?level? ?VERBOSE?</I>
-<DD> <i>type</i> must be one of vars, locals or globals.  This method
-will output the variables/locals/globals present in a particular level.
-If VERBOSE is added, then it actually 'dump's out the values as well.
-<i>level</i> defaults to the level in which this method was called.
-
-<DT> <CODE>idebug <b>trace</b></CODE> <I>?level?</I>
-<DD> Prints out the stack trace from the specified level up to the top
-level.  <i>level</i> defaults to the current level.
-
-</DL>
-</DIV>
-</TD></TR></TABLE>
-
-<HR NOSHADE SIZE=1>
-<ADDRESS><FONT SIZE=2>© Jeffrey Hobbs</FONT></ADDRESS>
-
-</BODY>
-</HTML>
diff --git a/tkcon-2.5/docs/idebug.n.man b/tkcon-2.5/docs/idebug.n.man
deleted file mode 100644
index 1547081..0000000
--- a/tkcon-2.5/docs/idebug.n.man
+++ /dev/null
@@ -1,83 +0,0 @@
-[comment {-*- tcl -*- idebug manpage}]
-[manpage_begin idebug n 2.5]
-[copyright {Jeffrey Hobbs <jeff at hobbs.org>}]
-[moddesc   {TkCon}]
-[titledesc {Interactive debugging environment in TkCon}]
-
-[description]
-[para]
-The idebug command provides an interactive debugging
-environment for procedures via TkCon.
-You can place idebug break commands into your procedure
-to create breakpoints.
-It will pop up the TkCon console and put you into a
-"debugging" mode.
-The [arg body], [arg show] & [arg trace] methods are
-intended for internal use only.
-
-This procedure works for minimal debugging sessions.
-Comments are encouraged.
-
-[list_begin definitions]
-
-[call [cmd idebug] [arg body] [opt [arg level]]]
-Prints out the body of the command (if it is a procedure)
-at the specified level.
-level defaults to the current level.
-
-[call [cmd idebug] [arg break] [opt [arg id]]]
-Creates a breakpoint within a procedure.
-This will only trigger if idebug is on and the [arg id] matches the pattern.
-If so, TkCon will pop to the front with the prompt changed
-to an idebug prompt.
-You are given the basic ability to observe the call stack
-an query/set variables or execute Tcl commands at any level.
-A separate history is maintained in debugging mode.
-To see the special commands available at the debug prompt,
-type ? and hit return.
-
-[call [cmd idebug] \{[arg "[arg echo] [opt [arg id]]"]\} [opt [arg args]]]
-Behaves just like [cmd echo], but only triggers when idebug is on.
-You can specify an optional [arg id] to further restrict triggering.
-If no id is specified, it defaults to the name of the command
-in which the call was made.
-
-[call [cmd idebug] [arg id] [opt [arg id]]]
-Query or set the idebug id.
-This id is used by other idebug methods to determine if
-they should trigger or not.
-The idebug id can be a glob pattern and defaults to *.
-
-[call [cmd idebug] [arg off]]
-Turns idebug off.
-
-[call [cmd idebug] [arg on] [opt [arg id]]]
-Turns idebug on.
-If [arg id] is specified, it sets the id to it.
-
-[call [cmd idebug] \{[arg "[arg puts] [opt [arg id]]"]\} [arg args]]
-Behaves just like [cmd puts], but only triggers when idebug is on.
-You can specify an optional [arg id] to further restrict triggering.
-If no id is specified, it defaults to the name of the
-command in which the call was made.
-
-[call [cmd idebug] [arg show] [arg type] [opt [arg level]] [opt [arg VERBOSE]]]
-type must be one of vars, locals or globals.
-This method will output the variables/locals/globals present
-in a particular level.
-If [arg VERBOSE] is added, then it actually [cmd dump]s out the values as well.
-level defaults to the level in which this method was called.
-
-[call [cmd idebug] [arg trace] [opt [arg level]]]
-Prints out the stack trace from the specified level up to the top level.
-level defaults to the current level.
-
-[list_end]
-
-[see_also [cmd tkcon](1)]
-[see_also [cmd tkconrc](5) [cmd tkcon](n) [cmd dump](n)]
-[see_also [cmd observe](n)]
-[keywords Tk console debug]
-
-[manpage_end]
-
diff --git a/tkcon-2.5/docs/index.html b/tkcon-2.5/docs/index.html
deleted file mode 100755
index 14ee891..0000000
--- a/tkcon-2.5/docs/index.html
+++ /dev/null
@@ -1,81 +0,0 @@
-<HTML>
-<HEAD>
-<TITLE>tkcon: Documentation</TITLE>
-<LINK REL="STYLESHEET" TYPE="text/css" HREF="./style.css">
-</HEAD>
-
-<BODY BGCOLOR=#FFFFFF>
-
-<TABLE WIDTH=100% BORDER=0 CELLSPACING=2 CELLPADDING=0 BGCOLOR=#000000><TR><TD>
-<!-- start header info -->
-<TABLE WIDTH=100% BORDER=0 CELLSPACING=0 CELLPADDING=0 BGCOLOR=#FFFFFF>
-<TR>
-<TD><FONT SIZE=+3><B>tkcon Documentation</B> (June 2001)</FONT></TD>
-<TD align=right>
-<A href="http://tkcon.sourceforge.net/"> 
-<IMG src="http://sourceforge.net/sflogo.php?group_id=11462&type=1" width="88"
-height="31" border="0" alt="SourceForge Logo"></A>
-</TD>
-</TR>
-</TABLE>
-<!-- end header info -->
-
-</TD></TR><TR><TD>
-<!-- start main navigation table -->
-<TABLE BORDER=1 CELLPADDING=2 CELLSPACING=2 BGCOLOR=#CCCCCC width=100%>
-<TR>
-<TH CLASS="hi"><A HREF="index.html" CLASS="hi">Documentation</A></TH>
-<TH><A HREF="purpose.html">Purpose & Features</A></TH>
-<TH><A HREF="limits.html">Limitations</A></TH>
-<TH><A HREF="todo.html">To Do</A></TH>
-<TH><A HREF="license.terms">License</A></TH>
-</TR><TR>
-<TH COLSPAN=2><A HREF="plugin.html">Online Demo</A>
-(requires <A HREF="http://tcl.activestate.com/software/plugin/">Tk plugin</A>)</TH>
-<TH COLSPAN=3><A HREF="nontcl.html">Using TkCon with other Tk Languages</A></TH>
-</TR>
-</TABLE>
-<!-- end main navigation table -->
-
-</TD></TR><TR><TD BGCOLOR=#FFFFFF>
-<DIV CLASS="indent">
-
-<!--
-<H4><A HREF="ftp://tkcon.sourceforge.net/pub/tkcon/">Release Archives</A> (ftp)</H4>
--->
-
-<H4><A
-HREF="http://sourceforge.net/project/showfiles.php?group_id=11462">Release
-Archives</A> (high speed server)</H4>
-
-<H4><A HREF="demopic.gif">Screenshot</A></H4>
-
-Please <B>read the following pages carefully</B> to fully understand the
-features AND limitations of TkCon.  I'm always open to suggestions for
-improvement.
- <P>
-</DIV>
-</TD></TR><TR><TD>
-
-<TABLE BORDER=1 CELLPADDING=2 CELLSPACING=2 BGCOLOR=#CCCCCC width=100%>
-<TR>
-<TH><A HREF="start.html">Getting Started</A></TD>
-<TH><A HREF="bindings.html">Special Bindings</A></TH>
-<TH><A HREF="procs.html">tkcon Procedures</A></TH>
-<TH><A HREF="demopic.gif">Screenshot</A></TH>
-</TR>
-<TR>
-<TH><A HREF="dump.html"><CODE>dump</CODE> proc</A></TH>
-<TH><A HREF="tkcon.html"><CODE>tkcon</CODE> proc</A></TH>
-<TH><A HREF="idebug.html"><CODE>idebug</CODE> proc</A></TH>
-<TH><A HREF="observe.html"><CODE>observe</CODE> proc</A></TH>
-</TR>
-</TABLE>
-
-</TD></TR></TABLE>
-
-<HR NOSHADE SIZE=1>
-<ADDRESS><FONT SIZE=2>© Jeffrey Hobbs</FONT></ADDRESS>
-
-</BODY>
-</HTML>
diff --git a/tkcon-2.5/docs/license.terms b/tkcon-2.5/docs/license.terms
deleted file mode 100755
index 9fe8d9a..0000000
--- a/tkcon-2.5/docs/license.terms
+++ /dev/null
@@ -1,38 +0,0 @@
-		   * COPYRIGHT AND LICENSE TERMS *
-
-This software is copyrighted by Jeffrey Hobbs <jeff and hobbs org>.  The
-following terms apply to all files associated with the software unless
-explicitly disclaimed in individual files.
-
-The authors hereby grant permission to use, copy, modify, distribute, and
-license this software and its documentation for any purpose, provided that
-existing copyright notices are retained in all copies and that this notice
-is included verbatim in any distributions.  No written agreement, license,
-or royalty fee is required for any of the authorized uses.
-
-IN NO EVENT SHALL THE AUTHORS OR DISTRIBUTORS BE LIABLE TO ANY PARTY FOR
-DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES ARISING OUT
-OF THE USE OF THIS SOFTWARE, ITS DOCUMENTATION, OR ANY DERIVATIVES THEREOF,
-EVEN IF THE AUTHORS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
-THE AUTHORS AND DISTRIBUTORS SPECIFICALLY DISCLAIM ANY WARRANTIES,
-INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY,
-FITNESS FOR A PARTICULAR PURPOSE, AND NON-INFRINGEMENT.  THIS SOFTWARE IS
-PROVIDED ON AN "AS IS" BASIS, AND THE AUTHORS AND DISTRIBUTORS HAVE NO
-OBLIGATION TO PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR
-MODIFICATIONS.
-
-RESTRICTED RIGHTS: Use, duplication or disclosure by the U.S. government
-is subject to the restrictions as set forth in subparagraph (c) (1) (ii)
-of the Rights in Technical Data and Computer Software Clause as DFARS
-252.227-7013 and FAR 52.227-19.
-
-SPECIAL NOTES:
-
-This software is also falls under the bourbon_ware clause v2:
-
- This software is free, but should you find this software useful in your
- daily work and would like to compensate the author, donations in the form
- of aged bourbon and scotch are welcome by the author.  The user may feel
- exempt from this clause if they are below drinking age or think the author
- has already partaken of too many drinks.
diff --git a/tkcon-2.5/docs/limits.html b/tkcon-2.5/docs/limits.html
deleted file mode 100755
index e9fd0dc..0000000
--- a/tkcon-2.5/docs/limits.html
+++ /dev/null
@@ -1,76 +0,0 @@
-<HTML>
-<HEAD>
-<TITLE>tkcon: Limitations</TITLE>
-<LINK REL="STYLESHEET" TYPE="text/css" HREF="./style.css">
-</HEAD>
-
-<BODY BGCOLOR=#FFFFFF>
-
-<TABLE WIDTH=100% BORDER=0 CELLSPACING=2 CELLPADDING=0 BGCOLOR=#000000><TR><TD>
-<!-- start header info -->
-<TABLE WIDTH=100% BORDER=0 CELLSPACING=0 CELLPADDING=0 BGCOLOR=#FFFFFF>
-<TR>
-<TH><FONT SIZE=+3>tkcon: Limitations</FONT></TH>
-<TD align=right>
-<A href="http://tkcon.sourceforge.net/"> 
-<IMG src="http://sourceforge.net/sflogo.php?group_id=11462&type=1" width="88"
-height="31" border="0" alt="SourceForge Logo"></A>
-</TD>
-</TR>
-</TABLE>
-<!-- end header info -->
-
-</TD></TR><TR><TD>
-<!-- start main navigation table -->
-<TABLE BORDER=1 CELLPADDING=2 CELLSPACING=2 BGCOLOR=#CCCCCC width=100%>
-<TR>
-<TH><A HREF="index.html">Documentation</A></TH>
-<TH><A HREF="purpose.html">Purpose & Features</A></TH>
-<TH CLASS="hi"><A HREF="limits.html" CLASS="hi">Limitations</A></TH>
-<TH><A HREF="todo.html">To Do</A></TH>
-<TH><A HREF="license.terms">License</A></TH>
-</TR><TR>
-<TH COLSPAN=2><A HREF="plugin.html">Online Demo</A>
-(requires <A HREF="http://www.tcl.tk/software/plugin/">Tk plugin</A>)</TH>
-<TH COLSPAN=3><A HREF="nontcl.html">Using TkCon with other Tk Languages</A></TH>
-</TR>
-</TABLE>
-<!-- end main navigation table -->
-
-</TD></TR><TR><TD BGCOLOR=#FFFFFF>
-<DIV CLASS="indent">
-<H3>Limitations:</H3>
-
-TkCon requires Tk8.0+.  Since TkCon is meant to behave like the original Tk
-console, it does not separate itself from the environment (it does not use
-send to function, except when attached to foreign Tk interpreters).  This
-means that it can be can be altered or destroyed by any sourced
-applications, and it will respond to an application's 'exit' call by
-exiting (by default, slave consoles will only close themselves instead of
-exiting the entire TkCon environment).  However, the widget tree of TkCon
-is hidden from the user environment.
- <P>
-
-Since TkCon is built for cross-platform capability, <font color=#FF0000>in
-Unix/Windows environments it does not have tty/shell behavior</font>.  This
-means programs like <CODE>vi</CODE> and <CODE>less</CODE> (those that rely
-on tty/shell settings) will not function appropriately (currently they may
-hang TkCon).  Programs like <CODE>ls</CODE> and <CODE>more</CODE> will just
-spit output to the TkCon screen without any special control or formatting
-(note that <CODE>ls</CODE> has been rewritten for TkCon).  You also do not
-get any job (process) control outside of what tcl normally can provide.
-Currently there is no way to handle <CODE>stdin</CODE> input.
- <P>
-
-When connecting to non-Tcl Tk interpreters (ie - PerlTk, SchemeTk, ...),
-you must use the syntax of the target environment.  See my
-<A HREF="nontcl.html">notes on using other Tk-embedded languages</A> for
-more info.
-</DIV>
-</TD></TR></TABLE>
-
-<HR NOSHADE SIZE=1>
-<ADDRESS><FONT SIZE=2>© Jeffrey Hobbs</FONT></ADDRESS>
-
-</BODY>
-</HTML>
diff --git a/tkcon-2.5/docs/nontcl.html b/tkcon-2.5/docs/nontcl.html
deleted file mode 100755
index 02e86f3..0000000
--- a/tkcon-2.5/docs/nontcl.html
+++ /dev/null
@@ -1,75 +0,0 @@
-<HTML>
-<HEAD>
-<TITLE>tkcon for Non-Tcl Users</TITLE>
-<LINK REL="STYLESHEET" TYPE="text/css" HREF="./style.css">
-</HEAD>
-
-<BODY BGCOLOR=#FFFFFF>
-
-<TABLE WIDTH=100% BORDER=0 CELLSPACING=2 CELLPADDING=0 BGCOLOR=#000000><TR><TD>
-<!-- start header info -->
-<TABLE WIDTH=100% BORDER=0 CELLSPACING=0 CELLPADDING=0 BGCOLOR=#FFFFFF>
-<TR>
-<TH><FONT SIZE=+3>tkcon: Non-Tcl Usage</FONT></TH>
-<TD align=right>
-<A href="http://tkcon.sourceforge.net/"> 
-<IMG src="http://sourceforge.net/sflogo.php?group_id=11462&type=1" width="88"
-height="31" border="0" alt="SourceForge Logo"></A>
-</TD>
-</TR>
-</TABLE>
-<!-- end header info -->
-
-</TD></TR><TR><TD>
-<!-- start main navigation table -->
-<TABLE BORDER=1 CELLPADDING=2 CELLSPACING=2 BGCOLOR=#CCCCCC width=100%>
-<TR>
-<TH><A HREF="index.html">Documentation</A></TH>
-<TH><A HREF="purpose.html">Purpose & Features</A></TH>
-<TH><A HREF="limits.html">Limitations</A></TH>
-<TH><A HREF="todo.html">To Do</A></TH>
-<TH><A HREF="license.terms">License</A></TH>
-</TR><TR>
-<TH COLSPAN=2><A HREF="plugin.html">Online Demo</A>
-(requires <A HREF="http://www.tcl.tk/software/plugin/">Tk plugin</A>)</TH>
-<TH COLSPAN=3 CLASS="hi"><A HREF="nontcl.html" CLASS="hi">Using TkCon with other Tk Languages</A></TH>
-</TR>
-</TABLE>
-<!-- end main navigation table -->
-
-</TD></TR><TR><TD BGCOLOR=#FFFFFF>
-<DIV CLASS="indent">
-<I>This document is for those users who are trying to use TkCon with a
-non-Tcl based Tk language (ie - SchemeTk, PerlTk, PythonTk...).</I>
- <P>
-
-TkCon requires <A HREF="http://tcl.activestate.com/">Tcl/Tk 8.0+</A> to
-run.  However, it can attach to any language with Tk4+
-embedded into it with the use of the Tk 'send' command.  I have been able
-to succesfully talk to SchemeTk-3.0 and Perl/Tk.  When using TkCon attached
-to these interpreters, you must remember to talk to the connected
-interpreter in its language.
- <P>
-I welcome further comments from users of Tk-embedded languages on their
-experiences or ideas.  Of course, you can always try to port TkCon in full
-to your language.  I'd like to see the results from any such efforts.
- <P>
-
-<H3>Special Language Notes:</H3>
-
-<H4>Perl Tk</H4>
-
-Read the man page on Perl/Tk's send command.  You have to define Tk::Receive
-before it will work.
-<A HREF="mailto:lusol at turkey.cc.lehigh.edu">Stephen Lidie
-(lusol at Turkey.CC.Lehigh.EDU)</A> contributed
-a <A HREF="perl.txt">companion Perl/Tk program</A> that does the trick with
-some extras.
-</DIV>
-</TD></TR></TABLE>
-
-<HR NOSHADE SIZE=1>
-<ADDRESS><FONT SIZE=2>© Jeffrey Hobbs</FONT></ADDRESS>
-
-</BODY>
-</HTML>
diff --git a/tkcon-2.5/docs/observe.html b/tkcon-2.5/docs/observe.html
deleted file mode 100755
index 34d72cb..0000000
--- a/tkcon-2.5/docs/observe.html
+++ /dev/null
@@ -1,104 +0,0 @@
-<HTML>
-<HEAD>
-<TITLE>tkcon: observe procedure</TITLE>
-<LINK REL="STYLESHEET" TYPE="text/css" HREF="./style.css">
-</HEAD>
-
-<BODY BGCOLOR=#FFFFFF>
-
-<TABLE WIDTH=100% BORDER=0 CELLSPACING=2 CELLPADDING=0 BGCOLOR=#000000><TR><TD>
-<!-- start header info -->
-<TABLE WIDTH=100% BORDER=0 CELLSPACING=0 CELLPADDING=0 BGCOLOR=#FFFFFF>
-<TR>
-<TH><FONT SIZE=+3>tkcon: <CODE>observe</CODE> procedure</FONT></TH>
-<TD align=right>
-<A href="http://tkcon.sourceforge.net/"> 
-<IMG src="http://sourceforge.net/sflogo.php?group_id=11462&type=1" width="88"
-height="31" border="0" alt="SourceForge Logo"></A>
-</TD>
-</TR>
-</TABLE>
-<!-- end header info -->
-
-</TD></TR><TR><TD>
-<!-- start main navigation table -->
-<TABLE BORDER=1 CELLPADDING=2 CELLSPACING=2 BGCOLOR=#CCCCCC width=100%>
-<TR>
-<TH CLASS="hi"><A HREF="index.html" CLASS="hi">Documentation</A></TH>
-<TH><A HREF="purpose.html">Purpose & Features</A></TH>
-<TH><A HREF="limits.html">Limitations</A></TH>
-<TH><A HREF="todo.html">To Do</A></TH>
-<TH><A HREF="license.terms">License</A></TH>
-</TR><TR>
-<TH COLSPAN=2><A HREF="plugin.html">Online Demo</A>
-(requires <A HREF="http://tcl.activestate.com/software/plugin/">Tk plugin</A>)</TH>
-<TH COLSPAN=3><A HREF="nontcl.html">Using TkCon with other Tk Languages</A></TH>
-</TR>
-</TABLE>
-<!-- end main navigation table -->
-</TD></TR><TR><TD>
-<!-- start secondary navigation table -->
-<TABLE BORDER=1 CELLPADDING=2 CELLSPACING=2 BGCOLOR=#BBBBBB width=100%>
-<TR>
-<TH><A HREF="start.html">Getting Started</A></TH>
-<TH><A HREF="bindings.html">Special Bindings</A></TH>
-<TH><A HREF="procs.html">Procedures</A></TH>
-<TH><A HREF="demopic.gif">Screenshot</A></TH>
-</TR>
-<TR>
-<TH><A HREF="dump.html"><CODE>dump</CODE></A></TH>
-<TH><A HREF="tkcon.html"><CODE>tkcon</CODE></A></TH>
-<TH><A HREF="idebug.html"><CODE>idebug</CODE></A></TH>
-<TH CLASS="hi2"><A HREF="observe.html" CLASS="hi2"><CODE>observe</CODE></A></TH>
-</TR>
-</TABLE>
-<!-- end secondary navigation table -->
-</TD></TR><TR><TD BGCOLOR=#FFFFFF>
-<DIV CLASS="indent">
- <P>
-This command provides runtime debugging output for variables and commands
-without the need to edit your code.  For variables, the underlying mechanism
-uses <code>trace</code> and <code>dump var</code>.  For commands, it renames
-the observed procedure and uses a special wrapper procedure.  <b><font
-color="#FF0000">WARNING:</font></b> using this procedure after checkpointing
-state will result in major problems if you clean state because the renamed
-(true) commands will be lost.
- <P>
-
-This procedure is experimental.  Comments are encouraged.
-
-<DL>
-
-<DT> <CODE>observe <b>command</b></CODE> <I>cmdname ?maxlevel?</I>
-<DD> This will create a wrapper command which prints out (using
-<code>dump</code>) the call stack to the console.  <i>maxlevel</i>
-represents the maximum number of levels of the call stack which will be
-printed (defaults to 4).
-
-<DT> <CODE>observe <b>cdelete</b></CODE> <I>cmdname</I>
-<DD> Removes the wrapper around an observed command.
-
-<DT> <CODE>observe <b>cinfo</b></CODE> <I>cmdname</I>
-<DD> Prints out useless info.
-
-<DT> <CODE>observe <b>variable</b></CODE> <I>varname operation ?args?</I>
-<DD> Currently a wrapper around trace that uses <code>dump</code> to
-print out the value of the named variable whenever the specified operation
-on that variable occurs (must be read, write or unset).
-
-<DT> <CODE>observe <b>vdelete</b></CODE> <I>varname operation</I>
-<DD> Deletes the trace wrapper around the named variable.
-
-<DT> <CODE>observe <b>vinfo</b></CODE> <I>varname</I>
-<DD> Prints out trace info about the named variable.
-
-</DL>
-</DIV>
-</TD></TR></TABLE>
-
-<HR NOSHADE SIZE=1>
-<ADDRESS><FONT SIZE=2>©
-Jeffrey Hobbs</FONT></ADDRESS>
-
-</BODY>
-</HTML>
diff --git a/tkcon-2.5/docs/observe.n.man b/tkcon-2.5/docs/observe.n.man
deleted file mode 100644
index d9630ba..0000000
--- a/tkcon-2.5/docs/observe.n.man
+++ /dev/null
@@ -1,55 +0,0 @@
-[comment {-*- tcl -*- observe manpage}]
-[manpage_begin observe n 2.5]
-[copyright {Jeffrey Hobbs <jeff at hobbs.org>}]
-[moddesc   {TkCon}]
-[titledesc {Runtime debugging output in TkCon}]
-
-[description]
-[para]
-This command provides runtime debugging output for variables
-and commands without the need to edit your code.
-For variables, the underlying mechanism uses [cmd trace] and [cmd dump] var.
-For commands, it renames the observed procedure and uses a
-special wrapper procedure.
-WARNING: using this procedure after checkpointing state will
-result in major problems if you clean state because the
-renamed (true) commands will be lost.
-
-[para]
-This procedure is experimental.
-Comments are encouraged.
-
-[list_begin definitions]
-
-[call [cmd observe] [arg command] [arg cmdname] [opt [arg maxlevel]]]
-This will create a wrapper command which prints out (using [cmd dump])
-the call stack to the console.
-maxlevel represents the maximum number of levels of the call
-stack which will be printed (defaults to 4).
-
-[call [cmd observe] [arg cdelete] [arg cmdname]]
-Removes the wrapper around an observed command.
-
-[call [cmd observe] [arg cinfo] [arg cmdname]]
-Prints out useless info.
-
-[call [cmd observe] [arg variable] [arg varname] [arg operation] [opt [arg args]]]
-Currently a wrapper around trace that uses [cmd dump] to print out
-the value of the named variable whenever the specified
-operation on that variable occurs (must be [arg read], [arg write] or [arg unset]).
-
-[call [cmd observe] [arg vdelete] [arg varname] [arg operation]]
-Deletes the trace wrapper around the named variable.
-
-[call [cmd observe] [arg vinfo] [arg varname]]
-Prints out trace info about the named variable.
-
-[list_end]
-
-[see_also [cmd tkcon](1)]
-[see_also [cmd tkconrc](5) [cmd tkcon](n) [cmd dump](n)]
-[see_also [cmd idebug](n)]
-[keywords Tk console debug]
-
-[manpage_end]
-
diff --git a/tkcon-2.5/docs/perl.txt b/tkcon-2.5/docs/perl.txt
deleted file mode 100755
index 37463b5..0000000
--- a/tkcon-2.5/docs/perl.txt
+++ /dev/null
@@ -1,109 +0,0 @@
-#!/usr/local/bin/perl -w
- 
-# tkcon.pl - a Perl/Tk	"shell" companion for tkcon.tcl.
-#
-# Variable $MW is an object reference to the main window, from which you can
-# create and manipulate child widgets.	Variable names beginning with an
-# underscore are reserved for this application.
-#
-# Stephen O. Lidie, 96/08/25
- 
-require 5.002;
-use English;
-use Tk;
-use Tk::Pretty qw(Pretty);
-use Tk::Dialog;
-use strict;
-use subs qw(doit tkcon);
-my($MW, $_TKCON, $_VERSION, $_HELP, $_SHELL, $_TAB, $_PARA, @_ERRORS, $_MES);
- 
-tkcon;				# main
- 
-sub doit {
- 
-    # Eval some code without use strict constraints.
- 
-    my($code) = @ARG;
- 
-    {
-	no strict;
-	if ($_MES) {
-	    $_MES->packForget;
-	    $_MES->destroy;
-	    $_MES = 0;
-	}
-	@_ERRORS = ();
-	$SIG{'__WARN__'} = sub {push @_ERRORS, @ARG};
-	my $_res = eval $code;
-	push @_ERRORS, $EVAL_ERROR if $EVAL_ERROR;
-	push @_ERRORS, $_res;
-    }
- 
-} # end doit
- 
-sub tkcon {
- 
-    # Nothing fancy here, just create the main window and the help dialog
-    # object, and display a pointer to the help.
- 
-    $_TKCON = 'tkcon.pl';
-    $_VERSION = '0.2';
-    $_SHELL = '/bin/sh';
-    $_SHELL = $ENV{'SHELL'} if $ENV{'SHELL'};
-    $_TAB = 0;
-    $_PARA = '';
- 
-    $MW = MainWindow->new;
-    $MW->title($_TKCON);
-    $MW->iconname($_TKCON);
-    $_HELP = $MW->Dialog(
-	-title	    => "$_TKCON Help",
-	-font	    => 'fixed',
-	-wraplength => '6i',
-	-justify    => 'left',
-	-text	    =>
-	    "?	  - this text.\n" .
-	    "|	  - pass arguments to your shell (default /bin/sh).\n" .
-	    "p	  - use Tk::Pretty to \"pretty-print\" arguments.\n" .
-	    "+	  - a tab starts/stops multiline input mode.\n" .
-	    "exit - quit $_TKCON.\n" .
-	    "\nOther input is assumed to be a Perl/Tk command.\n" .
-	    "\n\$MW is the MainWindow.\n",
-			 );
-    $_HELP->configure(-foreground => 'blue');
-    $_MES = $MW->Label(-text => "\nEnter ? for help.\n")->pack;
-    MainLoop;
- 
-} # end tkcon
- 
-sub Tk::Receive {
- 
-    shift();
-    $ARG = shift();
-    if (/^\?(.*)/) {		# help
-	$_HELP->Show;
-    } elsif (/^\|(.*)/) {	# bang
-	@_ERRORS = ();
-	push @_ERRORS, `$_SHELL -c $1 2>&1`;
-    } elsif (/^\+$/) {
-	$_TAB++;
-	if ($_TAB % 2) {
-	    @_ERRORS = ();
-	    $_PARA = '';
-	    push @_ERRORS, '+';
-	} else {
-	    doit $_PARA;
-	}
-    } else {			# Perl/Tk command
-	$ARG = "Pretty($1)" if (/^p\s(.*)$/);
-	if ($_TAB % 2) {
-	    $_PARA .= $ARG;
-	    push @_ERRORS, '+';
-	} else {
-	    doit $ARG;
-	}
-    } # ifend
- 
-    return @_ERRORS;
- 
-} # end Tk::Receive
diff --git a/tkcon-2.5/docs/plugin.html b/tkcon-2.5/docs/plugin.html
deleted file mode 100755
index 1cc1896..0000000
--- a/tkcon-2.5/docs/plugin.html
+++ /dev/null
@@ -1,113 +0,0 @@
-<HTML>
-<HEAD>
-<TITLE>tkcon: Tcl Plugin Stripped Demo</TITLE>
-<LINK REL="STYLESHEET" TYPE="text/css" HREF="./style.css">
-</HEAD>
-
-<BODY>
-
-<TABLE WIDTH=100% BORDER=0 CELLSPACING=2 CELLPADDING=0 BGCOLOR=#000000><TR><TD>
-<!-- start header info -->
-<TABLE WIDTH=100% BORDER=0 CELLSPACING=0 CELLPADDING=0 BGCOLOR=#FFFFFF>
-<TR>
-<TD><FONT SIZE=+3><B>tkcon Documentation</B> (May 2001)</FONT></TD>
-<TD align=right>
-<A href="http://tkcon.sourceforge.net/"> 
-<IMG src="http://sourceforge.net/sflogo.php?group_id=11462&type=1" width="88"
-height="31" border="0" alt="SourceForge Logo"></A>
-</TD>
-</TR>
-</TABLE>
-<!-- end header info -->
-
-</TD></TR><TR><TD>
-<!-- start main navigation table -->
-<TABLE BORDER=1 CELLPADDING=2 CELLSPACING=2 BGCOLOR=#CCCCCC width=100%>
-<TR>
-<TH><A HREF="index.html">Documentation</A></TH>
-<TH><A HREF="purpose.html">Purpose & Features</A></TH>
-<TH><A HREF="limits.html">Limitations</A></TH>
-<TH><A HREF="todo.html">To Do</A></TH>
-<TH><A HREF="license.terms">License</A></TH>
-</TR><TR>
-<TH COLSPAN=2 CLASS="hi"><A HREF="plugin.html" CLASS="hi">Online Demo</A>
-(requires <A HREF="http://www.tcl.tk/software/plugin/">Tk plugin</A>)</TH>
-<TH COLSPAN=3><A HREF="nontcl.html">Using TkCon with other Tk Languages</A></TH>
-</TR>
-</TABLE>
-<!-- end main navigation table -->
-
-</TD></TR><TR><TD BGCOLOR=#FFFFFF>
-<DIV CLASS="indent">
-<P>
-This is the full tkcon script when run inside the plugin.  It feels like a
-stripped down version of tkcon, but the only limitations are those
-established by the plugin.  You can test the basic console features and get
-a feel for the mutli-color output.  Below the demo are some ideas to try
-out.  v2+ of the plugin is distributed with a megawidget version of tkcon for
-debugging tclets.  The demo below uses the CVS head of tkcon.
-
-<P>
-  <OBJECT
-        ID="PluginHostCtrl"
-        CLASSID="CLSID:14E78123-A693-4F27-B6EE-DDDE18F93D3A"
-        WIDTH="600"
-        HEIGHT="350"
->
-          <PARAM name="type" value="application/x-tcl"/>
-          <PARAM name="pluginspage" value="http://www.tcl.tk/software/plugin/"/>
-          <PARAM name="src"  value="http://tkcon.cvs.sourceforge.net/tkcon/tkcon/tkcon.tcl?rev=HEAD&content-type=application/x-tcl"/>
-
-        <EMBED
-          TYPE="application/x-tcl"
-          PLUGINSPAGE="http://www.tcl.tk/software/plugin/"
-          FRAMEBORDER="NO"
-          WIDTH="600"
-          HEIGHT="350"
-          SRC="http://tkcon.cvs.sourceforge.net/tkcon/tkcon/tkcon.tcl?rev=HEAD&content-type=application/x-tcl"
-        >
-        </EMBED>
-  </OBJECT>
-</P>
-
-Have a look at some of the features: (culled from the
-<A HREF="index.html">tkcon documentation</A>)
-<UL>
-<LI> <B>Variable / Path / Procedure Name Expansion.</B>  Type in
-<CODE>set tc</CODE> at the prompt.  Hit <I><Control-Shift-V></I>.
-<CODE>set tcl_</CODE> should now be visible.
-Hit <I><Control-Shift-V></I> again.  You should see the rest of
-the completions printed out for you.  Works the same for procedures
-and files paths (file access restricted from plugin).  Works properly
-when spaces or other funny characters are including in the name.
-
-<LI> <B>Command Highlighting.</B> Note that <CODE>set</CODE> should be in
-green, denoting it is a recognized command in that interpreter.
-
-<LI> <B>Electric Character Matching.</B>  Watch while you type the
-following: <CODE>proc foo { a b } { puts [list $a $b] }</CODE>.  Did you
-notice the blink matching of the braces?  Yes, it's smart.
-
-<LI> <B>Command History.</B>  Use the Up/Down arrows or
-<I><Control-p></I>/<I><Control-n></I> to peruse the command
-history.  <I><Control-r></I>/<I><Control-s></I> Actually
-does command history matching (like tcsh or other advanced Unix shells).
-
-<LI> <B>Useful Colorization.</B> Having defined <CODE>foo</CODE> above, type
-in <CODE>foo hey</CODE>.  Note that the error comes back in red.  Go up one
-in the command history and add <CODE> you</CODE> and see that regular
-stdout output comes through in blue (the colors are configurable).
-
-<LI> <B>Cut/Copy/Paste.</B>  You should be able to do that between outside
-windows and TkCon.  The default keys are
-<I><Control-x></I>/<I><Control-c></I>/<I><Control-v></I>.
-
-</UL>
-</DIV>
-</TD></TR></TABLE>
-
-<HR NOSHADE SIZE=1>
-<ADDRESS><FONT SIZE=2>© Jeffrey Hobbs</FONT></ADDRESS>
-
-</BODY>
-</HTML>
diff --git a/tkcon-2.5/docs/procs.html b/tkcon-2.5/docs/procs.html
deleted file mode 100755
index 12b1925..0000000
--- a/tkcon-2.5/docs/procs.html
+++ /dev/null
@@ -1,167 +0,0 @@
-<HTML>
-<HEAD>
-<TITLE>tkcon: Procedures</TITLE>
-<LINK REL="STYLESHEET" TYPE="text/css" HREF="./style.css">
-</HEAD>
-
-<BODY BGCOLOR=#FFFFFF>
-
-<TABLE WIDTH=100% BORDER=0 CELLSPACING=2 CELLPADDING=0 BGCOLOR=#000000><TR><TD>
-<!-- start header info -->
-<TABLE WIDTH=100% BORDER=0 CELLSPACING=0 CELLPADDING=0 BGCOLOR=#FFFFFF>
-<TR>
-<TH><FONT SIZE=+3>tkcon: Procedures</FONT></TH>
-<TD align=right>
-<A href="http://tkcon.sourceforge.net/"> 
-<IMG src="http://sourceforge.net/sflogo.php?group_id=11462&type=1" width="88"
-height="31" border="0" alt="SourceForge Logo"></A>
-</TD>
-</TR>
-</TABLE>
-<!-- end header info -->
-
-</TD></TR><TR><TD>
-<!-- start main navigation table -->
-<TABLE BORDER=1 CELLPADDING=2 CELLSPACING=2 BGCOLOR=#CCCCCC width=100%>
-<TR>
-<TH CLASS="hi"><A HREF="index.html" CLASS="hi">Documentation</A></TH>
-<TH><A HREF="purpose.html">Purpose & Features</A></TH>
-<TH><A HREF="limits.html">Limitations</A></TH>
-<TH><A HREF="todo.html">To Do</A></TH>
-<TH><A HREF="license.terms">License</A></TH>
-</TR><TR>
-<TH COLSPAN=2><A HREF="plugin.html">Online Demo</A>
-(requires <A HREF="http://tcl.activestate.com/software/plugin/">Tk plugin</A>)</TH>
-<TH COLSPAN=3><A HREF="nontcl.html">Using TkCon with other Tk Languages</A></TH>
-</TR>
-</TABLE>
-<!-- end main navigation table -->
-</TD></TR><TR><TD>
-<!-- start secondary navigation table -->
-<TABLE BORDER=1 CELLPADDING=2 CELLSPACING=2 BGCOLOR=#BBBBBB width=100%>
-<TR>
-<TH><A HREF="start.html">Getting Started</A></TH>
-<TH><A HREF="bindings.html">Special Bindings</A></TH>
-<TH CLASS="hi2"><A HREF="procs.html" CLASS="hi2">Procedures</A></TH>
-<TH><A HREF="demopic.gif">Screenshot</A></TH>
-</TR>
-<TR>
-<TH><A HREF="dump.html"><CODE>dump</CODE></A></TH>
-<TH><A HREF="tkcon.html"><CODE>tkcon</CODE></A></TH>
-<TH><A HREF="idebug.html"><CODE>idebug</CODE></A></TH>
-<TH><A HREF="observe.html"><CODE>observe</CODE></A></TH>
-</TR>
-</TABLE>
-<!-- end secondary navigation table -->
-</TD></TR><TR><TD BGCOLOR=#FFFFFF>
-<DIV CLASS="indent">
- <P>
-There are several new procedures introduced in TkCon to improve
-productivity and/or account for lost functionality in the Tcl environment
-that users are used to in native environments.  There are also some
-redefined procedures.  Here is a non-comprehensive list:
-
-<DL COMPACT>
-
-<DT> <B>alias</B> <I>?sourceCmd targetCmd ?arg arg ...??</I>
-<DD> Simple alias mechanism.  It will overwrite existing commands.
-When called without args, it returns current aliases.  Note that TkCon
-makes some aliases for you (in slaves).
-<font color=#FF0000>Don't delete those</font>.
-
-<DT> <B>clear</B> <I>?percentage?</I>
-<DD> Clears the text widget.  Same as the <Control-l> binding, except
-this will accept a percentage of the buffer to clear (1-100, 100 default).
-
-<DT> <B>dir</B> <i>?-all? ?-full? ?-long? ?pattern pattern ...?</i>
-<DD> Cheap way to get directory listings.  Uses glob style pattern matching.
-
-<DT> <B>dump</B> <I>type ?-nocomplain? ?-filter pattern? ?--?
-pattern ?pattern ...?</I>
-<DD> The <CODE>dump</CODE> command provides a way for the user to spit out
-state information about the interpreter in a Tcl readable (and human
-readable) form.
-See <a href="dump.html">further <B>dump</B> docs</a> for details.
-
-<DT> <B>echo</B> <I>?arg arg ...?</I>
-<DD> Concatenates the args and spits the result to the console (stdout).
-
-<DT> <B>edit</B> <I>?-type type? ?-find str? ?-attach interp?</I> arg
-<font size=-1 color=#990033>NEW in v1.4, still under construction</font>
-<DD> Opens an editor with the data from <I>arg</I>.  The optional <I>type</I>
-argument can be one of: <I>proc</I>, <I>var</I> or <I>file</I>.  For
-proc or var, the <I>arg</I> may be a pattern.
-
-<DT> <B>idebug</B> <I>command ?args?</I>
-<DD> Interactive debugging command.
-See <a href="idebug.html">further <B>idebug</B> docs</a> for details.
-
-<DT> <B>lremove</B> <I>?-all? ?-regexp -glob? list items</I>
-<DD> Removes one or more items from a list and returns the new list.  If
-<I>-all</I> is specified, it removes all instances of each item in the
-list.  If <I>-regexp</I> or <I>-glob</I> is specified, it interprets each
-item in the items list as a regexp or glob pattern to match against.
-
-<DT> <B>less</B>
-<DD> Aliased to <B>edit</B>.
-
-<DT> <B>ls</B>
-<DD> Aliased to <B>dir -full</B>.
-
-<DT> <B>more</B>
-<DD> Aliased to <B>edit</B>.
-
-<DT> <B>observe</B> <I>type ?args?</I>
-<DD> This command provides passive runtime debugging output for variables
-and commands.
-See <a href="observe.html">further <B>observe</B> docs</a> for details.
-
-<DT> <B>puts</B> (same options as always)
-<DD> Redefined to put the output into TkCon
-
-<DT> <B>tkcon</B> <I>method ?args?</I>
-<DD> Multi-purpose command.
-See <a href="tkcon.html">further <B>tkcon</B> docs</a> for details.
-
-<DT> <B>tclindex</B> <I>?-extensions patternlist? ?-index TCL_BOOLEAN?
-?-package TCL_BOOLEAN? ?dir1 dir2 ...?</I>
-<DD> Convenience proc to update the tclIndex (controlled by -index switch)
-and/or pkgIndex.tcl (controlled by -package switch) file in the named
-directories based on the given pattern for files.  It defaults to creating
-the tclIndex but not the pkgIndex.tcl file, with the directory defaulting
-to [pwd].  The extension defaults to *.tcl, with *.[info sharelibextension]
-added when -package is true.
-
-<DT> <B>unalias</B> <I>cmd</I>
-<DD> unaliases command
-
-<DT> <B>what</B> <i>string</i>
-<DD> The <CODE>what</CODE> command will identify the word given in
-<i>string</i> in the Tcl environment and return a list of types that
-it was recognized as.  Possible types are: alias, procedure, command,
-array variable, scalar variable, directory, file, widget, and executable.
-Used by procedures <CODE>dump</CODE> and <CODE>which</CODE>.
-
-<DT> <B>which</B> <i>command</i>
-<DD> Like the 'which' command of Unix shells, this will tell you if a
-particular command is known, and if so, whether it is internal or external
-to the interpreter.  If it is an internal command and there is a slot in
-auto_index for it, it tells you the file that auto_index would load.  This
-does not necessarily mean that that is where the file came from, but if it
-were not in the interpreter previously, then that is where the command was
-found.
-
-</DL>
-
-There are several procedures that I use as helpers that some may find
-helpful in there coding (ie - expanding pathnames).  Feel free to lift
-them from the code (but do assign proper attribution).
-</DIV>
-</TD></TR></TABLE>
-
-<HR NOSHADE SIZE=1>
-<ADDRESS><FONT SIZE=2>©
-Jeffrey Hobbs</FONT></ADDRESS>
-
-</BODY>
-</HTML>
diff --git a/tkcon-2.5/docs/purpose.html b/tkcon-2.5/docs/purpose.html
deleted file mode 100755
index 1d5a087..0000000
--- a/tkcon-2.5/docs/purpose.html
+++ /dev/null
@@ -1,87 +0,0 @@
-<HTML>
-<HEAD>
-<TITLE>tkcon: Purpose & Features</TITLE>
-<LINK REL="STYLESHEET" TYPE="text/css" HREF="./style.css">
-</HEAD>
-
-<BODY BGCOLOR=#FFFFFF>
-
-<TABLE WIDTH=100% BORDER=0 CELLSPACING=2 CELLPADDING=0 BGCOLOR=#000000><TR><TD>
-<!-- start header info -->
-<TABLE WIDTH=100% BORDER=0 CELLSPACING=0 CELLPADDING=0 BGCOLOR=#FFFFFF>
-<TR>
-<TD><FONT SIZE=+3><B>tkcon: Purpose & Features</B></FONT></TD>
-<TD align=right>
-<A href="http://tkcon.sourceforge.net/"> 
-<IMG src="http://sourceforge.net/sflogo.php?group_id=11462&type=1" width="88"
-height="31" border="0" alt="SourceForge Logo"></A>
-</TD>
-</TR>
-</TABLE>
-<!-- end header info -->
-
-</TD></TR><TR><TD>
-<!-- start main navigation table -->
-<TABLE BORDER=1 CELLPADDING=2 CELLSPACING=2 BGCOLOR=#CCCCCC width=100%>
-<TR>
-<TH><A HREF="index.html">Documentation</A></TH>
-<TH CLASS="hi"><A HREF="purpose.html" CLASS="hi">Purpose & Features</A></TH>
-<TH><A HREF="limits.html">Limitations</A></TH>
-<TH><A HREF="todo.html">To Do</A></TH>
-<TH><A HREF="license.terms">License</A></TH>
-</TR><TR>
-<TH COLSPAN=2><A HREF="plugin.html">Online Demo</A>
-(requires <A HREF="http://tcl.activestate.com/software/plugin/">Tk plugin</A>)</TH>
-<TH COLSPAN=3><A HREF="nontcl.html">Using TkCon with other Tk Languages</A></TH>
-</TR>
-</TABLE>
-<!-- end main navigation table -->
-
-</TD></TR><TR><TD BGCOLOR=#FFFFFF>
-<DIV CLASS="indent">
-
-<H3>Purpose:</H3>
-
-tkcon is a replacement for the standard console that comes with Tk (on
-Windows/Mac, but also works on Unix).  The console itself provides
-<i>many</i> more features than the standard console.  tkcon works on all
-platforms where Tcl/Tk is available.  It is meant primarily to aid one when
-working with the little details inside tcl and tk, giving Unix users the GUI
-console provided by default in the Mac and Windows Tk.  It's also not a bad
-replacement for the default MS-DOS shell (although it needs lots of fine
-tuning).
- <P>
-See <A HREF="limits.html">Limitations</A> for a good idea of what
-tkcon <B>can't</B> do for you.
-
-<H3>Features:</H3>
-
-Just in case you don't run across them while playing, here are some of the
-extras in tkcon:
-<UL>
-<LI> Command history
-<LI> Path (Unix style) / Proc / Variable name expansion
-<LI> Multiple consoles, each with its own state (via multiple interpreters)
-<LI> Captures <CODE>stdout</CODE> and <CODE>stderr</CODE> to console window
-<LI> Electric character matching (a la emacs)
-<LI> Electric proc highlighting
-<LI> Enhanced history searching
-<LI> Configurable
-<LI> Cut / Copy / Paste between windows
-<LI> Communication between consoles and other Tk interpreters (including
-non-tcl ones)
-<LI> Hot Errors (click on error result to see stack trace)
-<LI> Works on all Tk platforms
-</UL>
-
-Read the <A HREF="index.html">documentation</A> for how to take advantage
-of these features.
-</DIV>
-</TD></TR></TABLE>
-
-<HR NOSHADE SIZE=1>
-<ADDRESS><FONT SIZE=2>©
-Jeffrey Hobbs</FONT></ADDRESS>
-
-</BODY>
-</HTML>
diff --git a/tkcon-2.5/docs/start.html b/tkcon-2.5/docs/start.html
deleted file mode 100755
index 901f326..0000000
--- a/tkcon-2.5/docs/start.html
+++ /dev/null
@@ -1,358 +0,0 @@
-<HTML>
-<HEAD>
-<TITLE>tkcon: Getting Started</TITLE>
-<LINK REL="STYLESHEET" TYPE="text/css" HREF="./style.css">
-</HEAD>
-
-<BODY BGCOLOR=#FFFFFF>
-
-<TABLE WIDTH=100% BORDER=0 CELLSPACING=2 CELLPADDING=0 BGCOLOR=#000000><TR><TD>
-<!-- start header info -->
-<TABLE WIDTH=100% BORDER=0 CELLSPACING=0 CELLPADDING=0 BGCOLOR=#FFFFFF>
-<TR>
-<TH><FONT SIZE=+3>tkcon: Getting Started</FONT></TH>
-<TD align=right>
-<A href="http://tkcon.sourceforge.net/"> 
-<IMG src="http://sourceforge.net/sflogo.php?group_id=11462&type=1" width="88"
-height="31" border="0" alt="SourceForge Logo"></A>
-</TD>
-</TR>
-</TABLE>
-<!-- end header info -->
-
-</TD></TR><TR><TD>
-<!-- start main navigation table -->
-<TABLE BORDER=1 CELLPADDING=2 CELLSPACING=2 BGCOLOR=#CCCCCC width=100%>
-<TR>
-<TH CLASS="hi"><A HREF="index.html" CLASS="hi">Documentation</A></TH>
-<TH><A HREF="purpose.html">Purpose & Features</A></TH>
-<TH><A HREF="limits.html">Limitations</A></TH>
-<TH><A HREF="todo.html">To Do</A></TH>
-<TH><A HREF="license.terms">License</A></TH>
-</TR><TR>
-<TH COLSPAN=2><A HREF="plugin.html">Online Demo</A>
-(requires <A HREF="http://tcl.activestate.com/software/plugin/">Tk plugin</A>)</TH>
-<TH COLSPAN=3><A HREF="nontcl.html">Using TkCon with other Tk Languages</A></TH>
-</TR>
-</TABLE>
-<!-- end main navigation table -->
-</TD></TR><TR><TD>
-<!-- start secondary navigation table -->
-<TABLE BORDER=1 CELLPADDING=2 CELLSPACING=2 BGCOLOR=#BBBBBB width=100%>
-<TR>
-<TH CLASS="hi2"><A HREF="start.html" CLASS="hi2">Getting Started</A></TH>
-<TH><A HREF="bindings.html">Special Bindings</A></TH>
-<TH><A HREF="procs.html">Procedures</A></TH>
-<TH><A HREF="demopic.gif">Screenshot</A></TH>
-</TR>
-<TR>
-<TH><A HREF="dump.html"><CODE>dump</CODE></A></TH>
-<TH><A HREF="tkcon.html"><CODE>tkcon</CODE></A></TH>
-<TH><A HREF="idebug.html"><CODE>idebug</CODE></A></TH>
-<TH><A HREF="observe.html"><CODE>observe</CODE></A></TH>
-</TR>
-</TABLE>
-<!-- end secondary navigation table -->
-</TD></TR><TR><TD BGCOLOR=#FFFFFF>
-<DIV CLASS="indent">
-<H3>Resource File:</H3>
-
-TkCon will search for a resource file in "<CODE>$env(HOME)/.tkconrc</CODE>"
-(Unix), "<CODE>$env(HOME)/tkcon.cfg</CODE>" (Windows) or
-"<CODE>$env(PREF_FOLDER)/tkcon.cfg</CODE>" (Macintosh).  On DOS machines,
-"<CODE>$env(HOME)</CODE>" usually refers to "<CODE>C:\</CODE>".  TkCon
-never sources the "<CODE>~/.wishrc</CODE>" file.  The resource file is
-sourced by each new instance of the console.  An example resource file is
-provided below.
-
-<H3>Command Line Arguments</H3>
-
-Except for <CODE>-rcfile</CODE>, command line arguments are handled after
-the TkCon resource file is sourced, but before the slave interpreter or the
-TkCon user interface is initialized.  <CODE>-rcfile</CODE> is handled right
-before it would be sourced, allowing you to specify any alternate file.
-Command line arguments are passed to each new console and will be evaluated
-by each.  To prevent this from happening, you have to say
-<CODE>tkcon main set argv {}; tkcon main set argc 0</CODE>.
- <P>
-For these options, any unique substring is allowed.
-
-<DL>
-
-<DT> <CODE>-argv</CODE> (also <CODE>--</CODE>)
-<DD> Causes TkCon to stop evaluating arguments and set the remaining args to
-be argv/argc (with <CODE>--</CODE> prepended).  This carries over for any
-further consoles.  This is meant only for wrapping TkCon around programs
-that require their own arguments.
-
-<DT> <CODE>-color-<color></CODE> <I>color</I>
-<DD> Sets the requested color type to the specified color for tkcon.
-See the <B>Variables</B> section for the recognized
-<i><color></i> names.
-
-<DT> <CODE>-eval</CODE> (also <CODE>-main</CODE> or <CODE>-e</CODE>)
-<DD> A tcl script to eval in each main interpreter.  This is evaluated
-after the resource file is loaded and the slave interpreter is created.
-Multiple <CODE>-eval</CODE> switches will be recognized (in order).
-
-<DT> <CODE>-exec</CODE> <I>slavename</I>
-<DD> Sets the named slave that tkcon operates in.  In general, this is only
-useful to set to "" (empty), indicating to tkcon to avoid the
-multi-interpreter model and operate in the main environment.  When this is
-empty, any further arguments will be only used in the first tkcon console
-and not passed onto further new consoles.  This is useful when using tkcon
-as a console for extended wish executables that don't load there commands
-into slave interpreters.
-
-<DT> <CODE>-font</CODE> <I>font</I>
-<DD> Sets the font that tkcon uses for its text windows.  If this isn't
-a fixed width font, tkcon will override it.
-
-<DT> <CODE>-nontcl</CODE> <I>TCL_BOOLEAN</I>
-<DD> Sets <CODE>::tkcon::OPT(nontcl)</CODE> to <I>TCL_BOOLEAN</I>.  Needed
-when attaching to non-Tcl interpreters.
-
-<DT> <CODE>-package</CODE> <I>package_name</I> (also <CODE>-load</CODE>)
-<DD> Packages to automatically load into the slave interpreters (ie - "Tk").
-
-<DT> <CODE>-rcfile</CODE> <I>filename</I>
-<DD> Specify an alternate tkcon resource file name.
-
-<DT> <CODE>-root</CODE> <I>widgetname</I>
-<DD> Makes the named widget the root name of all consoles (ie - .tkcon).
-
-<DT> <CODE>-slave</CODE> <I>tcl_script</I>
-<DD> A tcl script to eval in each slave interpreter.  This will append
-the one specified in the tkcon resource file, if any.
-
-</DL>
-
-Some examples of tkcon command line startup situations:
-<DL>
-
-<DT> <CODE>megawish tkcon.tcl -exec "" -root .tkcon mainfile.tcl</CODE>
-<DD> Use tkcon as a console for your megawish application.  You can avoid
-starting the line with <CODE>megawish</CODE> if that is the default wish
-that tkcon would use.  The <CODE>-root</CODE> ensures that tkcon will not
-conflict with the 
-
-<DT> <CODE>tkcon.tcl -font "Courier 12" -load Tk</CODE>
-<DD> Use the courier font for tkcon and always load Tk in slave
-interpreters at startup.
-
-<DT> <CODE>tkcon.tcl -rcfile ~/.wishrc -color,bg white</CODE>
-<DD> Use the <CODE>~/.wishrc</CODE> file as the resource file, and
-a white background for tkcon's text widgets.
-
-</DL>
-
-<H3>Variables:</H3>
-
-Certain variables in TkCon can be modified to suit your needs.  It's
-easiest to do this in the resource file, but you can do it when time the
-program is running (and some can be changed via the Prefs menu).  All these
-are part of the master interpreter's <code>::tkcon</code> namespace.  The
-modifiable array variables are <CODE>::tkcon::COLOR</CODE> and
-<CODE>::tkcon::OPT</CODE>.  You can call '<CODE>tkcon set
-::tkcon::COLOR</CODE>' when the program is running to check its state.
-Here is an explanation of certain variables you might change or use:
-
-<DL>
-
-<DT> <CODE>::tkcon::COLOR(bg)</CODE>
-<DD> The background color for tkcon text widgets.
-Defaults to the operating system default (determined at startup).
-
-<DT> <CODE>::tkcon::COLOR(blink)</CODE>
-<DD> The background color of the electric brace highlighting, if on.
-Defaults to <font color=#FFFF00>yellow</font>.
-
-<DT> <CODE>::tkcon::COLOR(cursor)</CODE>
-<DD> The background color for the insertion cursor in tkcon.
-Defaults to <font color=#000000>black</font>.
-
-<DT> <CODE>::tkcon::COLOR(disabled)</CODE>
-<DD> The foreground color for disabled menu items.
-Defaults to <font color=#4D4D4D>dark grey</font>.
-
-<DT> <CODE>::tkcon::COLOR(proc)</CODE>
-<DD> The foreground color of a recognized proc, if command highlighting is on.
-Defaults to <font color=#008800>dark green</font>.
-
-<DT> <CODE>::tkcon::COLOR(var)</CODE>
-<DD> The background color of a recognized var, if command highlighting is on.
-Defaults to <font color=#FFC0D0>pink</font>.
-
-<DT> <CODE>::tkcon::COLOR(prompt)</CODE>
-<DD> The foreground color of the prompt as output in the console.
-Defaults to <font color=#8F4433>brown</font>.
-
-<DT> <CODE>::tkcon::COLOR(stdin)</CODE>
-<DD> The foreground color of the stdin for the console.
-Defaults to <font color=#000000>black</font>.
-
-<DT> <CODE>::tkcon::COLOR(stdout)</CODE>
-<DD> The foreground color of the stdout as output in the console.
-Defaults to <font color=#0000FF>blue</font>.
-
-<DT> <CODE>::tkcon::COLOR(stderr)</CODE>
-<DD> The foreground color of stderr as output in the console.
-Defaults to <font color=#FF0000>red</font>.
- <P>
-
-<DT> <CODE>::tkcon::OPT(autoload)</CODE>
-<DD> Packages to automatically load into the slave interpreter (ie - 'Tk').
-This is a list.  Defaults to {} (none).
-
-<DT> <CODE>::tkcon::OPT(blinktime)</CODE>
-<DD> The amount of time (in millisecs) that braced sections should
-<I>blink</I> for.  Defaults to 500 (.5 secs), must be at least 100.
-
-<DT> <CODE>::tkcon::OPT(blinkrange)</CODE>
-<DD> Whether to blink the entire range for electric brace matching or to
-just blink the actual matching braces (respectively 1 or 0, defaults to 1).
-
-<DT> <CODE>::tkcon::OPT(buffer)</CODE>
-<DD> The size of the console scroll buffer (in lines).
-Defaults to 512.
-
-<DT> <CODE>::tkcon::OPT(calcmode)</CODE>
-<DD> Whether to allow <CODE>expr</CODE> commands to be run at the command
-line without prefixing them with <CODE>expr</CODE> (just a convenience).
-
-<DT> <CODE>::tkcon::OPT(cols)</CODE>
-<DD> Number of columns for the console to start out with.  Defaults to 80.
-
-<DT> <CODE>::tkcon::OPT(dead)</CODE>
-<DD> What to do with dead connected interpreters.  If <CODE>dead</CODE>
-is <i>leave</i>, TkCon automatically exits the dead interpreter.  If
-<CODE>dead</CODE> is <i>ignore</i> then it remains attached waiting for
-the interpreter to reappear.  Otherwise TkCon will prompt you.
-
-<DT> <CODE>::tkcon::OPT(exec)</CODE>
-<DD> This corresponds to the <CODE>-exec</CODE> option above
-
-<DT> <CODE>::tkcon::OPT(font)</CODE>
-<DD> Font to use for tkcon text widgets (also specified with -font).
-Defaults to the system default, or a fixed width equivalent.
-
-<DT> <CODE>::tkcon::OPT(gets)</CODE>
-<DD> Controls whether tkcon will overload the gets command to work with
-tkcon.  The valid values are: <code>congets</code> (the default), which
-will redirect <code>stdin</code> requests to the tkcon window;
-<code>gets</code>, which will pop up a dialog to get input; and {} (empty
-string) which tells tkcon not to overload gets.  This value must be set at
-startup to alter tkcon's behavior.
-
-<DT> <CODE>::tkcon::OPT(history)</CODE>
-<DD> The size of the history list to keep.  Defaults to 48.
-
-<DT> <CODE>::tkcon::OPT(hoterrors)</CODE>
-<DD> Whether hot errors are enabled or not.  When enabled, errors that
-are returned to the console are marked with a link to the error info
-that will pop up in an minimal editor.  This requires more memory because
-each error that occurs will maintain bindings for this feature, as long
-as the error is in the text widget.  Defaults to on.
-
-<DT> <CODE>::tkcon::OPT(library)</CODE>
-<DD> The path to any tcl library directories (these are appended to the
-auto_path when the after the resource file is loaded in).
-
-<DT> <CODE>::tkcon::OPT(lightbrace)</CODE>
-<DD> Whether to use the brace highlighting feature or not
-(respectively 1 or 0, defaults to 1).
-
-<DT> <CODE>::tkcon::OPT(lightcmd)</CODE>
-<DD> Whether to use the command highlighting feature or not
-(respectively 1 or 0, defaults to 1).
-
-<DT> <CODE>::tkcon::OPT(maineval)</CODE>
-<DD> A tcl script to execute in the main interpreter after the slave
-interpreter is created and the user interface is initialized.
-
-<DT> <CODE>::tkcon::OPT(maxlinelen)</CODE>
-<DD> A number that specifies the limit of long result lines.
-True result is still captured in $_ (and 'puts $_' works).
-Defaults to 0 (unlimited).
-
-<DT> <CODE>::tkcon::OPT(maxmenu)</CODE>
-<DD> A number that specifies the maximum number of packages to show
-vertically in the Interp->Packages menu before breaking into
-another column.  Defaults to 15.
-
-<DT> <CODE>::tkcon::OPT(nontcl)</CODE>
-<DD> For those who might be using non-Tcl based Tk attachments, set this
-to 1.  It prevents TkCon from trying to evaluate its own Tcl code in an
-attached interpreter.  Also see my <A HREF="nontcl.html">notes for non-Tcl
-based Tk interpreters</A>.
-
-<DT> <CODE>::tkcon::OPT(prompt1)</CODE>
-<DD> Like tcl_prompt1, except it doesn't require you use '<CODE>puts</CODE>'.
-No equivalent for tcl_prompt2 is available (it's unnecessary IMHO).
-<BR>Defaults to {([file tail [pwd]]) [history nextid] % }.
-
-<DT> <CODE>::tkcon::OPT(rows)</CODE>
-<DD> Number of rows for the console to start out with.  Defaults to 20.
-
-<DT> <CODE>::tkcon::OPT(scollypos)</CODE>
-<DD> Y scrollbar position.  Valid values are <CODE>left</CODE> or
-<CODE>right</CODE>.  Defaults to <CODE>left</CODE>.
-
-<DT> <CODE>::tkcon::OPT(showmenu)</CODE>
-<DD> Show the menubar on startup (1 or 0, defaults to 1).
-
-<DT> <CODE>::tkcon::OPT(showmultiple)</CODE>
-<DD> Show multiple matches for path/proc/var name expansion
-(1 or 0, defaults to 1).
-
-<DT> <CODE>::tkcon::OPT(slaveeval)</CODE>
-<DD> A tcl script to execute in each slave interpreter right after it's
-created.  This allows the user to have user defined info always available
-in a slave.  Example:
-<PRE>	set ::tkcon::OPT(slaveeval) {
-		proc foo args { puts $args }
-		lappend auto_path .
-	}</PRE>
-
-<DT> <CODE>::tkcon::OPT(slaveexit)</CODE>
-<DD> Allows the prevention of <CODE>exit</CODE> in slaves from exitting
-the entire application.  If it is equal to <CODE>exit</CODE>, exit will
-exit as usual, otherwise it will just close down that interpreter (and
-any children).  Defaults to <VAR>close</VAR>.
-
-<DT> <CODE>::tkcon::OPT(subhistory)</CODE>
-<DD> Allow history substitution to occur (0 or 1, defaults to 1).  The
-history list is maintained in a single interpreter per TkCon console
-instance.  Thus you have history which can range over a series of attached
-interpreters.
-</DL>
-
- <P>
-
-An <b>example TkCon resource file</b> might look like:
-
-<PRE style="color: #883333">######################################################
-## My TkCon Resource File
- 
-# Use a fixed default font
-#tkcon font fixed; # valid on unix
-#tkcon font systemfixed; # valid on win
-tkcon font Courier 12; # valid everywhere
-
-# Keep 50 commands in history
-set ::tkcon::OPT(history) 50
-
-# Use a pink prompt
-set ::tkcon::COLOR(prompt) pink
-######################################################</PRE>
-
- <p>
-</DIV>
-</TD></TR></TABLE>
-
-<HR NOSHADE SIZE=1>
-<ADDRESS><FONT SIZE=2>©
-Jeffrey Hobbs</FONT></ADDRESS>
-
-</BODY>
-</HTML>
diff --git a/tkcon-2.5/docs/style.css b/tkcon-2.5/docs/style.css
deleted file mode 100644
index 7aee5e8..0000000
--- a/tkcon-2.5/docs/style.css
+++ /dev/null
@@ -1,50 +0,0 @@
-body, div, p, th, td, li, dd, ul, ol, dl, dt, blockquote {
-	font-family:	Arial, Helvetica, sans-serif;
-}
-body {
-	background-color:  #FFFFFF;
-	font-size:         12px;
-	line-height:       1.25;
-	letter-spacing:    .2px;
-}
-th {
-	font-style: 	bold;
-	text-align:	left;
-}
-a { text-decoration: none }
-.hi, .hi2 {
-	font-weight:	bold;
-	color:		#B82619;
-	background:	#FFFFCC;
-	text-decoration: none;
-}
-.hi2 {	background:	#CCFFCC; }
-.indent { margin:	3px; }
-
-/* general styles */	
-.heading { 
-	font-size: 	14px;
-	font-weight: 	bold;
-	color: 		#B82619;
-}
-.subheading { 
-	font-weight: 	bold;
-	color: 		#B82619;
-}
-
-.err { 
-	font-weight:	bold;
-	color:		#B82619;
-}
-.smallText{
-	font-size: 10px;
-}
-.notsosmallText {
-	font-size: 11px;
-}
-
-/* unordered list without bullets */
-ul.sans { 
-	list-style-type: none;
-	list-style-postition: inside;
-}
diff --git a/tkcon-2.5/docs/tkcon.1.man b/tkcon-2.5/docs/tkcon.1.man
deleted file mode 100644
index 038adf9..0000000
--- a/tkcon-2.5/docs/tkcon.1.man
+++ /dev/null
@@ -1,369 +0,0 @@
-[comment {-*- tcl -*- tkcon manpage}]
-[manpage_begin tkcon 1 2.5]
-[copyright {Jeffrey Hobbs (jeff at hobbs.org)}]
-[moddesc   {TkCon}]
-[titledesc {Tk console replacement}]
-
-[description]
-[para]
-TkCon is a replacement for the standard console that comes with Tk
-(on Windows/Mac, but also works on Unix).
-The console itself provides many more features than the standard
-console.
-TkCon works on all platforms where Tcl/Tk is available.
-It is meant primarily to aid one when working with the little
-details inside Tcl and Tk, giving Unix users the GUI console
-provided by default in the Mac and Windows Tk.
-
-[list_begin definitions]
-[call [cmd tkcon] [lb]\{[arg option] [arg value] | [arg tcl_script]\} ...[rb]]
-[list_end]
-
-[section OPTIONS]
-[para]
-Except for [cmd -rcfile], command line arguments are handled after
-the TkCon resource file is sourced, but before the slave
-interpreter or the TkCon user interface is initialized.
-
-[para]
-[cmd -rcfile] is handled right before it would be sourced,
-allowing you to specify any alternate file.
-Command line arguments are passed to each new console and
-will be evaluated by each.
-To prevent this from happening, you have to say
-
-[example_begin]
-tkcon main set argv {}; tkcon main set argc 0
-[example_end]
-
-[para]
-For these options, any unique substring is allowed.
-
-[list_begin definitions]
-[lst_item "[cmd -argv] (also [cmd --])"]
-Causes TkCon to stop evaluating arguments and set the remaining
-args to be argv/argc (with [cmd --] prepended).
-This carries over for any further consoles.
-This is meant only for wrapping TkCon
-around programs that require their own arguments.
-
-[lst_item "[cmd -color-<color>] [arg color]"]
-Sets the requested color type to the specified color for tkcon.
-See [cmd tkconrc](5) for the recognized [cmd <color>] names.
-
-[lst_item "[cmd -eval] [arg tcl_script] (also [cmd -main] or [cmd -e])"]
-A Tcl script to eval in each main interpreter.
-This is evaluated after the resource file is loaded and the
-slave interpreter is created.
-Multiple [cmd -eval] switches will be recognized (in order).
-
-[lst_item "[cmd -exec] [arg slavename]"]
-Sets the named slave that tkcon operates in.
-In general, this is only useful to set to [arg {""}] (empty),
-indicating to tkcon to avoid the multi-interpreter model and
-operate in the main environment.
-When this is empty, any further arguments will be only used
-in the first tkcon console and not passed onto further new consoles.
-This is useful when using tkcon as a console for extended wish
-executables that don't load there commands into slave interpreters.
-
-[lst_item "[cmd -font] [arg font]"]
-Sets the font that tkcon uses for its text windows.
-If this isn't a fixed width font, tkcon will override it.
-
-[lst_item "[cmd -nontcl] [arg TCL_BOOLEAN]"]
-Sets [cmd ::tkcon::OPT(nontcl)] to [arg TCL_BOOLEAN] (see
-[cmd tkconrc](5)).
-Needed when attaching to non-Tcl interpreters.
-
-[lst_item "[cmd -package] [arg package_name] (also [cmd -load])"]
-Packages to automatically load into the slave interpreters (i.e. "Tk").
-
-[lst_item "[cmd -rcfile] [arg filename]"]
-Specify an alternate tkcon resource file name.
-
-[lst_item "[cmd -root] [arg widgetname]"]
-Makes the named widget the root name of all consoles (i.e. .tkcon).
-
-[lst_item "[cmd -slave] [arg tcl_script]"]
-A Tcl script to eval in each slave interpreter.
-This will append the one specified in the tkcon resource file, if any.
-
-[list_end]
-
-[section {KEY BINDINGS}]
-[para]
-Most of the bindings are the same as for the [cmd text] widget.
-Some have been modified to make sure that the integrity of the
-console is maintained.
-Others have been added to enhance the usefulness of the console.
-Only the modified or new bindings are listed here.
-
-[list_begin definitions]
-
-[lst_item "[cmd Control-x] or [cmd Cut] (on Sparc5 keyboards)"]
-Cut.
-
-[lst_item "[cmd Control-c] or [cmd Copy] (on Sparc5 keyboards)"]
-Copy.
-
-[lst_item "[cmd Control-v] or [cmd Paste] (on Sparc5 keyboards)"]
-Paste.
-
-[lst_item [cmd Insert]]
-Insert (duh).
-
-[lst_item [cmd Up]]
-Goes up one level in the commands line history when cursor is on
-the prompt line, otherwise it moves through the buffer.
-
-[lst_item [cmd Down]]
-Goes down one level in the commands line history when cursor
-is on the last line of the buffer, otherwise it moves through the buffer.
-
-[lst_item [cmd Control-p]]
-Goes up one level in the commands line history.
-
-[lst_item [cmd Control-n]]
-Goes down one level in the commands line history.
-
-[lst_item [cmd Tab]]
-Tries to expand file path names, then variable names, then proc names.
-
-[lst_item [cmd Escape]]
-Tries to expand file path names.
-
-[lst_item [cmd Control-P]]
-Tries to expand procedure names.
-The procedure names will be those that are actually in the attached
-interpreter (unless nontcl is specified, in which case it always
-does the lookup in the default slave interpreter).
-
-[lst_item [cmd Control-V]]
-Tries to expand variable names (those returned by [lb]info vars[rb]).
-It's search behavior is like that for procedure names.
-
-[lst_item "[cmd Return] or [cmd Enter]"]
-Evaluates the current command line if it is a complete command,
-otherwise it just goes to a new line.
-
-[lst_item [cmd Control-a]]
-Go to the beginning of the current command line.
-
-[lst_item [cmd Control-l]]
-Clear the entire console buffer.
-
-[lst_item [cmd Control-r]]
-Searches backwards in the history for any command that contains
-the string in the current command line.
-Repeatable to search farther back.
-The matching substring off the found command will blink.
-
-[lst_item [cmd Control-s]]
-As above, but searches forward (only useful if you searched too far back).
-
-[lst_item [cmd Control-t]]
-Transposes characters.
-
-[lst_item [cmd Control-u]]
-Clears the current command line.
-
-[lst_item [cmd Control-z]]
-Saves current command line in a buffer that can be retrieved
-with another [cmd Control-z].
-If the current command line is empty, then any saved command
-is retrieved without being overwritten, otherwise the current
-contents get swapped with what's in the saved command buffer.
-
-[lst_item [cmd Control-Key-1]]
-Attaches console to the console's slave interpreter.
-
-[lst_item [cmd Control-Key-2]]
-Attaches console to the console's master interpreter.
-
-[lst_item [cmd Control-Key-3]]
-Attaches console to main TkCon interpreter.
-
-[lst_item [cmd Control-A]]
-Pops up the "About" dialog.
-
-[lst_item [cmd Control-N]]
-Creates a new console. Each console has separate state, including
-it's own widget hierarchy (it's a slave interpreter).
-
-[lst_item [cmd Control-q]]
-Close the current console OR Quit the program (depends on the
-value of [cmd ::tkcon::TKCON(slaveexit)]).
-
-[lst_item [cmd Control-w]]
-Closes the current console.
-Closing the main console will exit the program (something has
-to control all the slaves...).
-
-[list_end]
-
-[para]
-TkCon also has electric bracing (similar to that in emacs).
-It will highlight matching pairs of {}'s, [lb][rb]'s, ()'s and ""'s.
-For the first three, if there is no matching left element for the right,
-then it blinks the entire current command line.
-For the double quote, if there is no proper match then it just blinks
-the current double quote character.
-It does properly recognize most escaping (except escaped escapes),
-but does not look for commenting (why would you interactively
-put comments in?).
-
-[section COMMANDS]
-[para]
-There are several new procedures introduced in TkCon to improve
-productivity and/or account for lost functionality in the Tcl
-environment that users are used to in native environments.
-There are also some redefined procedures.
-Here is a non-comprehensive list:
-
-[list_begin definitions]
-
-[lst_item "[cmd alias] ?[arg sourceCmd] [arg targetCmd] ?[arg arg] [arg arg] ...??"]
-Simple alias mechanism.
-It will overwrite existing commands.
-When called without args, it returns current aliases.
-Note that TkCon makes some aliases for you (in slaves).
-Don't delete those.
-
-[lst_item "[cmd clear] ?[arg percentage]?"]
-Clears the text widget.
-Same as the <[cmd Control-l]> binding, except this will accept a
-percentage of the buffer to clear (1-100, 100 default).
-
-[lst_item "[cmd dir] ?[arg -all]? ?[arg -full]? ?[arg -long]?\
-	  ?[arg pattern] [arg pattern] ...?"]
-Cheap way to get directory listings.
-Uses glob style pattern matching.
-
-[lst_item "[cmd dump] [arg type] ?[arg -nocomplain]? ?[arg {-filter pattern}]?\
-	  ?[cmd --]? [arg pattern] ?[arg pattern] ...?"]
-The dump command provides a way for the user to spit out state
-information about the interpreter in a Tcl readable (and
-human readable) form.
-See [cmd dump](n) for details.
-
-[lst_item "[cmd echo] ?[arg arg] [arg arg] ...?"]
-Concatenates the args and spits the result to the console (stdout).
-
-[lst_item "[cmd edit] ?[arg {-type type}]? ?[arg {-find str}]?\
-	  ?[arg {-attach interp}]? [arg arg]"]
-Opens an editor with the data from arg.
-The optional type argument can be one of: [arg proc], [arg var] or [arg file].
-For proc or var, the arg may be a pattern.
-
-[lst_item "[cmd idebug] [arg command] ?[arg args]?"]
-Interactive debugging command.
-See [cmd idebug](n) for details.
-
-[lst_item "[cmd lremove] ?[arg -all]? ?[arg -regexp] [arg -glob]?\
-	  [arg list] [arg items]"]
-Removes one or more items from a list and returns the new list.
-If [arg -all] is specified, it removes all instances of each item
-in the list.
-If [arg -regexp] or [arg -glob] is specified, it interprets each item in
-the items list as a regexp or glob pattern to match against.
-
-[lst_item [cmd less]]
-Aliased to [cmd edit].
-
-[lst_item [cmd ls]]
-Aliased to [cmd dir] [arg -full].
-
-[lst_item [cmd more]]
-Aliased to [cmd edit].
-
-[lst_item "[cmd observe] [arg type] ?[arg args]?"]
-This command provides passive runtime debugging output for
-variables and commands.
-See [cmd observe](n) for details.
-
-[lst_item "[cmd puts] (same options as always)"]
-Redefined to put the output into TkCon.
-
-[lst_item "[cmd tkcon] [arg method] ?[arg args]?"]
-Multi-purpose command.
-See [cmd tkcon](n) for details.
-
-[lst_item "[cmd tclindex] [arg {?-extensions patternlist? ?-index TCL_BOOLEAN?\
-	  ?-package TCL_BOOLEAN? ?dir1 dir2 ...?}]"]
-Convenience proc to update the [file tclIndex] (controlled by [arg -index] switch)
-and/or [file pkgIndex.tcl] (controlled by [arg -package] switch) file in the named
-directories based on the given pattern for files.
-It defaults to creating the [file tclIndex] but not the [file pkgIndex.tcl] file,
-with the directory defaulting to [lb]pwd[rb].
-The extension defaults to *.tcl, with *.[lb]info sharelibextension[rb]
-added when [arg -package] is true.
-
-[lst_item "[cmd unalias] [arg cmd]"]
-unaliases command.
-
-[lst_item "[cmd what] [arg string]"]
-The what command will identify the word given in string in
-the Tcl environment and return a list of types that it was recognized as.
-Possible types are: alias, procedure, command, array variable,
-scalar variable, directory, file, widget, and executable.
-Used by procedures dump and which.
-
-[lst_item "[cmd which] [arg command]"]
-Like the [syscmd which] command of Unix shells, this will tell you if a
-particular command is known, and if so, whether it is internal or
-external to the interpreter.
-If it is an internal command and there is a slot in [cmd auto_index] for it,
-it tells you the file that [cmd auto_index] would load.
-This does not necessarily mean that that is where the file came from,
-but if it were not in the interpreter previously, then that
-is where the command was found.
-
-[list_end]
-
-[para]
-There are several procedures that I use as helpers that some may find
-helpful in there coding (i.e. expanding pathnames). Feel free to lift
-them from the code (but do assign proper attribution).
-
-[section EXAMLPES]
-[para]
-Some examples of tkcon command line startup situations:
-
-[example_begin]
-[cmd megawish] /usr/bin/tkcon [cmd -exec] "" [cmd -root] .tkcon [arg mainfile.tcl]
-[example_end]
-
-Use tkcon as a console for your [cmd megawish] application.
-You can avoid starting the line with megawish if that is the
-default [cmd wish] that TkCon would use.
-The [cmd -root] ensures that tkcon will not conflict with the
-application root window.
-
-[example_begin]
-[cmd tkcon] [cmd -font] "Courier 12" [cmd -load] Tk
-[example_end]
-
-Use the courier font for TkCon and always load Tk in slave
-interpreters at startup.
-
-[example_begin]
-[cmd tkcon] [cmd -rcfile] ~/.wishrc [cmd -color-bg] white
-[example_end]
-
-Use the ~/.wishrc file as the resource file, and a white
-background for TkCon's text widgets.
-
-[section FILES]
-TkCon will search for a resource file in [file ~/.tkconrc].
-TkCon never sources the [file ~/.wishrc] file.
-The resource file is sourced by each new instance of the console.
-An example resource file is provided in [cmd tkconrc](5).
-
-[see_also [cmd tkconrc](5)]
-[see_also [cmd dump](n) [cmd tkcon](n) [cmd idebug](n)]
-[see_also [cmd observe](n) [cmd text](n)]
-[keywords Tk console]
-
-[manpage_end]
-
diff --git a/tkcon-2.5/docs/tkcon.html b/tkcon-2.5/docs/tkcon.html
deleted file mode 100755
index 9fe5753..0000000
--- a/tkcon-2.5/docs/tkcon.html
+++ /dev/null
@@ -1,184 +0,0 @@
-<HTML>
-<HEAD>
-<TITLE>tkcon: tkcon procedure</TITLE>
-<LINK REL="STYLESHEET" TYPE="text/css" HREF="./style.css">
-</HEAD>
-
-<BODY BGCOLOR=#FFFFFF>
-
-<TABLE WIDTH=100% BORDER=0 CELLSPACING=2 CELLPADDING=0 BGCOLOR=#000000><TR><TD>
-<!-- start header info -->
-<TABLE WIDTH=100% BORDER=0 CELLSPACING=0 CELLPADDING=0 BGCOLOR=#FFFFFF>
-<TR>
-<TH><FONT SIZE=+3>tkcon: <CODE>tkcon</CODE> procedure</FONT></TH>
-<TD align=right>
-<A href="http://tkcon.sourceforge.net/"> 
-<IMG src="http://sourceforge.net/sflogo.php?group_id=11462&type=1" width="88"
-height="31" border="0" alt="SourceForge Logo"></A>
-</TD>
-</TR>
-</TABLE>
-<!-- end header info -->
-
-</TD></TR><TR><TD>
-<!-- start main navigation table -->
-<TABLE BORDER=1 CELLPADDING=2 CELLSPACING=2 BGCOLOR=#CCCCCC width=100%>
-<TR>
-<TH CLASS="hi"><A HREF="index.html" CLASS="hi">Documentation</A></TH>
-<TH><A HREF="purpose.html">Purpose & Features</A></TH>
-<TH><A HREF="limits.html">Limitations</A></TH>
-<TH><A HREF="todo.html">To Do</A></TH>
-<TH><A HREF="license.terms">License</A></TH>
-</TR><TR>
-<TH COLSPAN=2><A HREF="plugin.html">Online Demo</A>
-(requires <A HREF="http://tcl.activestate.com/software/plugin/">Tk plugin</A>)</TH>
-<TH COLSPAN=3><A HREF="nontcl.html">Using TkCon with other Tk Languages</A></TH>
-</TR>
-</TABLE>
-<!-- end main navigation table -->
-</TD></TR><TR><TD>
-<!-- start secondary navigation table -->
-<TABLE BORDER=1 CELLPADDING=2 CELLSPACING=2 BGCOLOR=#BBBBBB width=100%>
-<TR>
-<TH><A HREF="start.html">Getting Started</A></TH>
-<TH><A HREF="bindings.html">Special Bindings</A></TH>
-<TH><A HREF="procs.html">Procedures</A></TH>
-<TH><A HREF="demopic.gif">Screenshot</A></TH>
-</TR>
-<TR>
-<TH><A HREF="dump.html"><CODE>dump</CODE></A></TH>
-<TH CLASS="hi2"><A HREF="tkcon.html" CLASS="hi2"><CODE>tkcon</CODE></A></TH>
-<TH><A HREF="idebug.html"><CODE>idebug</CODE></A></TH>
-<TH><A HREF="observe.html"><CODE>observe</CODE></A></TH>
-</TR>
-</TABLE>
-<!-- end secondary navigation table -->
-</TD></TR><TR><TD BGCOLOR=#FFFFFF>
-<DIV CLASS="indent">
- <P>
-This provides lots of useful control over a console:
-
-<DL>
-
-<DT> <CODE>tkcon <b>attach</b></CODE> <I>interpreter</I>
-<DD> Attaches tkcon to the named interpreter.  The name must be that
-returned by <CODE>[tk appname]</CODE> or a valid path to a slave
-interpreter.  It's best to use this via the <CODE>Console->Attach
-Console</CODE> menu.
-
-<DT> <CODE>tkcon <b>buffer</b></CODE> ?<I>size</I>?
-<DD> Sets or queries the allowed size of the console text widget in lines.
-The text widget will automatically delete leading lines once this number
-has been exceeded (read: this is the scroll buffer size).
-
-<DT> <CODE>tkcon <b>bgerror</b></CODE> ?<I>msg errorInfo</I>?
-<DD> Does bgerror stuff in the tkcon master interpreter.
-
-<DT> <CODE>tkcon <b>close</b></CODE> or <CODE>tkcon <b>destroy</b></CODE>
-<DD> Destroys this tkcon widget.
-
-<DT> <CODE>tkcon <b>congets</b></CODE>
-<DD> Behaves like the traditional Tcl <code>gets</code>, but instead of
-using <code>stdin</code>, it uses the tkcon console window.  By default,
-tkcon replaces the standard gets with this command.  This behavior can be
-controlled by altering the <code>::tkcon::OPT(gets)</code> parameter at
-startup.  This should not be called directly - instead rely on the
-overloaded <code>gets</code>, which has support for the optional varName
-parameter.
-
-<DT> <CODE>tkcon <b>console</b></CODE> <I>args</I>
-<DD> Passes the args to the tkcon text widget (the console).
-
-<DT> <CODE>tkcon <b>error</b></CODE>
-<DD> Pops up a dialog that gives the user a full trace of the last error
-received in the tkcon console.
-
-<DT> <CODE>tkcon <b>find</b></CODE> <I>string ?-case TCL_BOOLEAN
--regexp TCL_BOOLEAN?</I>
-<DD> Highlights all instances of <I>string</I> in the console.  If the string
-is empty, it clears any previous highlighting.
-
-<DT> <CODE>tkcon <b>font</b></CODE> ?<I>fontname</I>?
-<DD> Sets or returns the font used by tkcon text widgets.
-
-<DT> <CODE>tkcon <b>gets</b></CODE>
-<DD> Behaves like the traditional Tcl <code>gets</code>, but instead of
-needing <code>stdin</code>, it pops a dialog box up for the user.  The
-overloaded <code>gets</code> has support for the optional varName parameter.
-
-<DT> <CODE>tkcon <b>getcommand</b></CODE>
-<DD> A variation of the <CODE><b>congets</b></CODE> method that requires a
-full command to be input before returning.
-
-<DT> <CODE>tkcon <b>hide</b></CODE>
-<DD> Withdraw the tkcon display from the screen (make sure you have
-a way to get it back).
-
-<DT> <CODE>tkcon <b>history</b></CODE> ?<i>-newline</i>?
-<DD> Displays the tkcon history in sourceable form.  If <i>-newline</i> is
-specified, it separates each command by an extra newline.
-
-<DT> <CODE>tkcon <b>iconify</b></CODE>
-<DD> Iconifies the tkcon display.
-
-<DT> <CODE>tkcon <b>linelength</b></CODE> ?<i>value</i>?
-<DD> Sets or displays the number that specifies the limit of long result lines.
-True result is still captured in $_ (and 'puts $_' works).
-
-<DT> <CODE>tkcon <b>load</b></CODE> <I>filename</I>
-<DD> Sources named file into the slave interpreter.  If no filename is
-given, it will attempt to call <CODE>tk_getOpenFile</CODE> to pop up the
-file select box.
-
-<DT> <CODE>tkcon <b>main</b></CODE> ?<I>arg arg ...</I>?
-<DD> Passes the args to the main tkcon interpreter to be evaluated and
-returns the result.
-
-<DT> <CODE>tkcon <b>master</b></CODE> <I>args</I>
-<DD> Passes the args to the master interpreter to be evaluated and
-returns the result.
-
-<DT> <CODE>tkcon <b>new</b></CODE>
-<DD> Creates a new tkcon widget.
-
-<DT> <CODE>tkcon <b>save</b></CODE> ?<I>filename</I> ?<I>type</I>??
-<DD> Saves the console buffer to the given filename.  If no filename is
-given, it will attempt to call <CODE>tk_getSaveFile</CODE> to pop up the
-file select box.  If no type is given, a dialog will ask you to specify
-what portion of the text you want to save.
-
-<DT> <CODE>tkcon <b>set</b></CODE> <I>var ?value?</I>
-<DD> Queries or sets a master interpreter variable.
-
-<DT> <CODE>tkcon <b>append</b></CODE> <I>var ?value?</I>
-<DD> Like set, but uses <CODE>append</CODE> on the variable.
-
-<DT> <CODE>tkcon <b>lappend</b></CODE> <I>var ?value?</I>
-<DD> Like set, but uses <CODE>lappend</CODE> on the variable.
-
-<DT> <CODE>tkcon <b>show</b></CODE> or <CODE>tkcon deiconify</CODE>
-<DD> Redisplays tkcon on the screen.
-
-<DT> <CODE>tkcon <b>slave</b></CODE> ?<I>slavename ?arg arg ...?</I>?
-<DD> If called with no args, it returns the name of all the tkcon
-interpreters.  Otherwise given an interp name it passes the args
-to the named interpreter to be evaluated and returns the result.
-If no args are passed, then it returns the <CODE>[tk appname]</CODE>
-of that interpreter.
-
-<DT> <CODE>tkcon <b>title</b></CODE> ?<I>title</I>?
-<DD> Sets or returns the title for tkcon.
-
-<DT> <CODE>tkcon <b>version</b></CODE>
-<DD> Returns of version of tkcon.
-
-</DL>
-</DIV>
-</TD></TR></TABLE>
-
-<HR NOSHADE SIZE=1>
-<ADDRESS><FONT SIZE=2>©
-Jeffrey Hobbs</FONT></ADDRESS>
-
-</BODY>
-</HTML>
diff --git a/tkcon-2.5/docs/tkcon.n.man b/tkcon-2.5/docs/tkcon.n.man
deleted file mode 100644
index 0f7f3a1..0000000
--- a/tkcon-2.5/docs/tkcon.n.man
+++ /dev/null
@@ -1,135 +0,0 @@
-[comment {-*- tcl -*- tkcon manpage}]
-[manpage_begin tkcon n 2.5]
-[copyright {Jeffrey Hobbs <jeff at hobbs.org>}]
-[moddesc   {TkCon}]
-[titledesc {Controlling TkCon console}]
-
-[description]
-[para]
-This provides lots of useful control over a console:
-
-[list_begin definitions]
-
-[call [cmd tkcon] [arg attach] [arg interpreter]]
-Attaches tkcon to the named interpreter.
-The name must be that returned by [lb][cmd tk] [arg appname][rb] or a valid
-path to a slave interpreter.
-It's best to use this via the [arg {Console->Attach Console}] menu.
-
-[call [cmd tkcon] [arg buffer] [opt [arg size]]]
-Sets or queries the allowed size of the console text widget in lines.
-The text widget will automatically delete leading lines once this
-number has been exceeded (read: this is the scroll buffer size).
-
-[call [cmd tkcon] [arg bgerror] [opt "[arg msg] [arg errorInfo]"]]
-Does bgerror stuff in the tkcon master interpreter.
-
-[call [cmd tkcon] [arg close] or [cmd tkcon] [arg destroy]]
-Destroys this tkcon widget.
-
-[call [cmd tkcon] [arg congets]]
-Behaves like the traditional Tcl gets, but instead of using stdin,
-it uses the tkcon console window.
-By default, tkcon replaces the standard gets with this command.
-This behavior can be controlled by altering the [cmd ::tkcon::OPT(gets)]
-parameter at startup.
-This should not be called directly - instead rely on the overloaded
-gets, which has support for the optional varName parameter.
-
-[call [cmd tkcon] [arg console] [arg args]]
-Passes the args to the tkcon text widget (the console).
-
-[call [cmd tkcon] [arg error]]
-Pops up a dialog that gives the user a full trace of the
-last error received in the tkcon console.
-
-[call [cmd tkcon] [arg find] [arg string]\
-      [opt "[arg -case] [arg TCL_BOOLEAN] [arg -regexp] [arg TCL_BOOLEAN]"]]
-Highlights all instances of string in the console.
-If the string is empty, it clears any previous highlighting.
-
-[call [cmd tkcon] [arg font] [opt [arg fontname]]]
-Sets or returns the font used by tkcon text widgets.
-
-[call [cmd tkcon] [arg gets]]
-Behaves like the traditional Tcl gets, but instead of needing
-stdin, it pops a dialog box up for the user.
-The overloaded gets has support for the optional varName parameter.
-
-[call [cmd tkcon] [arg getcommand]]
-A variation of the congets method that requires a full
-command to be input before returning.
-
-[call [cmd tkcon] [arg hide]]
-Withdraw the tkcon display from the screen (make sure you
-have a way to get it back).
-
-[call [cmd tkcon] [arg history] [opt [arg -newline]]]
-Displays the tkcon history in sourceable form.
-If [arg -newline] is specified, it separates each command by
-an extra newline.
-
-[call [cmd tkcon] [arg iconify]]
-Iconifies the tkcon display.
-
-[call [cmd tkcon] [arg linelength] [opt [arg value]]]
-Sets or displays the number that specifies the limit of long result lines.
-True result is still captured in $_ (and 'puts $_' works).
-
-[call [cmd tkcon] [arg load] [arg filename]]
-Sources named file into the slave interpreter.
-If no filename is given, it will attempt to call
-[cmd tk_getOpenFile] to pop up the file select box.
-
-[call [cmd tkcon] [arg main] [opt "[arg arg] [arg arg] [arg ...]"]]
-Passes the args to the main tkcon interpreter to be
-evaluated and returns the result.
-
-[call [cmd tkcon] [arg master] [arg args]]
-Passes the args to the master interpreter to be evaluated
-and returns the result.
-
-[call [cmd tkcon] [arg new]]
-Creates a new tkcon widget.
-
-[call [cmd tkcon] [arg save] [opt "[arg filename] [opt [arg type]]"]]
-Saves the console buffer to the given filename.
-If no filename is given, it will attempt to call
-[cmd tk_getSaveFile] to pop up the file select box.
-If no type is given, a dialog will ask you to specify
-what portion of the text you want to save.
-
-[call [cmd tkcon] [arg set] [arg var] [opt [arg value]]]
-Queries or sets a master interpreter variable.
-
-[call [cmd tkcon] [arg append] [arg var] [opt [arg value]]]
-Like set, but uses append on the variable.
-
-[call [cmd tkcon] [arg lappend] [arg var] [opt [arg value]]]
-Like set, but uses lappend on the variable.
-
-[call [cmd tkcon] [arg show] or [cmd tkcon] [arg deiconify]]
-Redisplays tkcon on the screen.
-
-[call [cmd tkcon] [arg slave] [opt "[arg slavename] [opt [arg {arg arg ...}]]"]]
-If called with no args, it returns the name of all the tkcon interpreters.
-Otherwise given an interp name it passes the args to the named interpreter
-to be evaluated and returns the result.
-If no args are passed, then it returns the [lb][cmd tk] [arg appname][rb] of that
-interpreter.
-
-[call [cmd tkcon] [arg title] [opt [arg title]]]
-Sets or returns the title for tkcon.
-
-[call [cmd tkcon] [arg version]]
-Returns of version of tkcon.
-
-[list_end]
-
-[see_also [cmd tkcon](1)]
-[see_also [cmd tkconrc](5) [cmd tkcon](n) [cmd dump](n)]
-[see_also [cmd observe](n)]
-[keywords Tk console debug]
-
-[manpage_end]
-
diff --git a/tkcon-2.5/docs/tkconrc.5.man b/tkcon-2.5/docs/tkconrc.5.man
deleted file mode 100644
index 4fe040b..0000000
--- a/tkcon-2.5/docs/tkconrc.5.man
+++ /dev/null
@@ -1,249 +0,0 @@
-[comment {-*- tcl -*- tkconrc manpage}]
-[manpage_begin tkconrc 5 2.5]
-[copyright {Jeffrey Hobbs <jeff at hobbs.org>}]
-[moddesc   {TkCon}]
-[titledesc {TkCon resource file}]
-
-[description]
-[para]
-TkCon will search for a resource file in [file ~/.tkconrc].
-TkCon never sources the [file ~/.wishrc] file.
-The resource file is sourced by each new instance of the console.
-An example resource file is provided below.
-
-[para]
-The file itself is a Tcl script, so it is required that the
-file conforms to Tcl script conventions.
-
-[section VARIABLES]
-[para]
-Certain variables in TkCon can be modified to suit your needs.
-It's easiest to do this in the resource file, but you can do
-it when time the program is running (and some can be changed
-via the [arg Prefs] menu).
-All these are part of the master interpreter's [cmd ::tkcon]
-namespace.
-The modifiable array variables are [cmd ::tkcon::COLOR] and
-[cmd ::tkcon::OPT].
-You can call
-
-[example_begin]
-tkcon set ::tkcon::COLOR
-[example_end]
-
-when the program is running to check its state.
-Here is an explanation of certain variables you
-might change or use:
-
-[list_begin definitions]
-
-[lst_item [cmd ::tkcon::COLOR(bg)]]
-The background color for tkcon text widgets.
-Defaults to the operating system default (determined at startup).
-
-[lst_item [cmd ::tkcon::COLOR(blink)]]
-The background color of the electric brace highlighting, if on.
-Defaults to yellow.
-
-[lst_item [cmd ::tkcon::COLOR(cursor)]]
-The background color for the insertion cursor in tkcon.
-Defaults to black.
-
-[lst_item [cmd ::tkcon::COLOR(disabled)]]
-The foreground color for disabled menu items.
-Defaults to dark grey.
-
-[lst_item [cmd ::tkcon::COLOR(proc)]]
-The foreground color of a recognized proc, if command highlighting is on.
-Defaults to dark green.
-
-[lst_item [cmd ::tkcon::COLOR(var)]]
-The background color of a recognized var, if command highlighting is on.
-Defaults to pink.
-
-[lst_item [cmd ::tkcon::COLOR(prompt)]]
-The foreground color of the prompt as output in the console.
-Defaults to brown.
-
-[lst_item [cmd ::tkcon::COLOR(stdin)]]
-The foreground color of the stdin for the console.
-Defaults to black.
-
-[lst_item [cmd ::tkcon::COLOR(stdout)]]
-The foreground color of the stdout as output in the console.
-Defaults to blue.
-
-[lst_item [cmd ::tkcon::COLOR(stderr)]]
-The foreground color of stderr as output in the console.
-Defaults to red.
-
-[lst_item [cmd ::tkcon::OPT(autoload)]]
-Packages to automatically load into the slave interpreter (i.e. 'Tk').
-This is a list.
-Defaults to {} (none).
-
-[lst_item [cmd ::tkcon::OPT(blinktime)]]
-The amount of time (in millisecs) that braced sections should blink for.
-Defaults to 500 (0.5 secs), must be at least 100.
-
-[lst_item [cmd ::tkcon::OPT(blinkrange)]]
-Whether to blink the entire range for electric brace matching
-or to just blink the actual matching braces (respectively 1 or 0,
-defaults to 1).
-
-[lst_item [cmd ::tkcon::OPT(buffer)]]
-The size of the console scroll buffer (in lines).
-Defaults to 512.
-
-[lst_item [cmd ::tkcon::OPT(calcmode)]]
-Whether to allow expr commands to be run at the command line
-without prefixing them with expr (just a convenience).
-
-[lst_item [cmd ::tkcon::OPT(cols)]]
-Number of columns for the console to start out with.
-Defaults to 80.
-
-[lst_item [cmd ::tkcon::OPT(dead)]]
-What to do with dead connected interpreters.
-If dead is leave, TkCon automatically exits the dead interpreter.
-If dead is ignore then it remains attached waiting for the
-interpreter to reappear.
-Otherwise TkCon will prompt you.
-
-[lst_item [cmd ::tkcon::OPT(exec)]]
-This corresponds to the [cmd -exec] tkcon option (see [cmd tkcon](1)).
-
-[lst_item [cmd ::tkcon::OPT(font)]]
-Font to use for tkcon text widgets (also specified with [cmd -font] option).
-Defaults to the system default, or a fixed width equivalent.
-
-[lst_item [cmd ::tkcon::OPT(gets)]]
-Controls whether tkcon will overload the gets command to work with tkcon.
-The valid values are: congets (the default), which will redirect
-stdin requests to the tkcon window; gets, which will pop up a dialog to
-get input; and {} (empty string) which tells tkcon not to overload gets.
-This value must be set at startup to alter tkcon's behavior.
-
-[lst_item [cmd ::tkcon::OPT(history)]]
-The size of the history list to keep.
-Defaults to 48.
-
-[lst_item [cmd ::tkcon::OPT(hoterrors)]]
-Whether hot errors are enabled or not.
-When enabled, errors that are returned to the console are marked
-with a link to the error info that will pop up in an minimal editor.
-This requires more memory because each error that occurs will
-maintain bindings for this feature, as long as the error
-is in the text widget.
-Defaults to on.
-
-[lst_item [cmd ::tkcon::OPT(library)]]
-The path to any tcl library directories (these are appended
-to the [cmd auto_path] when the after the resource file is loaded in).
-
-[lst_item [cmd ::tkcon::OPT(lightbrace)]]
-Whether to use the brace highlighting feature or not
-(respectively 1 or 0, defaults to 1).
-
-[lst_item [cmd ::tkcon::OPT(lightcmd)]]
-Whether to use the command highlighting feature or not
-(respectively 1 or 0, defaults to 1).
-
-[lst_item [cmd ::tkcon::OPT(maineval)]]
-A tcl script to execute in the main interpreter after the
-slave interpreter is created and the user interface is initialized.
-
-[lst_item [cmd ::tkcon::OPT(maxlinelen)]]
-A number that specifies the limit of long result lines.
-True result is still captured in $_ (and 'puts $_' works).
-Defaults to 0 (unlimited).
-
-[lst_item [cmd ::tkcon::OPT(maxmenu)]]
-A number that specifies the maximum number of packages to
-show vertically in the [arg Interp->Packages] menu before breaking
-into another column.
-Defaults to 15.
-
-[lst_item [cmd ::tkcon::OPT(nontcl)]]
-For those who might be using non-Tcl based Tk attachments, set this to 1.
-It prevents TkCon from trying to evaluate its own Tcl
-code in an attached interpreter.
-Also see my notes for non-Tcl based Tk interpreters.
-
-[lst_item [cmd ::tkcon::OPT(prompt1)]]
-Like [cmd tcl_prompt1], except it doesn't require you use [cmd puts].
-No equivalent for [cmd tcl_prompt2] is available (it's unnecessary IMHO).
-Defaults to {([lb]file tail [lb]pwd[rb][rb]) [lb]history nextid[rb] % }.
-
-[lst_item [cmd ::tkcon::OPT(rows)]]
-Number of rows for the console to start out with.
-Defaults to 20.
-
-[lst_item [cmd ::tkcon::OPT(scollypos)]]
-Y scrollbar position.
-Valid values are left or right.
-Defaults to right.
-
-[lst_item [cmd ::tkcon::OPT(showmenu)]]
-Show the menubar on startup (1 or 0, defaults to 1).
-
-[lst_item [cmd ::tkcon::OPT(showmultiple)]]
-Show multiple matches for path/proc/var name expansion (1 or 0,
-defaults to 1).
-
-[lst_item [cmd ::tkcon::OPT(slaveeval)]]
-A tcl script to execute in each slave interpreter right after it's created.
-This allows the user to have user defined info always available in a slave.
-
-[nl]
-Example:
-
-[example_begin]
-set ::tkcon::OPT(slaveeval) {
-    proc foo args { puts $args }
-    lappend auto_path .
-}
-[example_end]
-
-[lst_item [cmd ::tkcon::OPT(slaveexit)]]
-Allows the prevention of exit in slaves from exitting the entire application.
-If it is equal to exit, exit will exit as usual, otherwise it will just close
-down that interpreter (and any children).
-Defaults to close.
-
-[lst_item [cmd ::tkcon::OPT(subhistory)]]
-Allow history substitution to occur (0 or 1, defaults to 1).
-The history list is maintained in a single interpreter per TkCon console
-instance.
-Thus you have history which can range over a series of attached interpreters.
-
-[list_end]
-
-[section EXAMPLES]
-[para]
-An example TkCon resource file might look like:
-
-[example_begin]
-######################################################
-## My TkCon Resource File
-
-# Use a fixed default font
-#tkcon font fixed; # valid on unix
-#tkcon font systemfixed; # valid on win
-tkcon font Courier 12; # valid everywhere
-
-# Keep 50 commands in history
-set ::tkcon::OPT(history) 50
-
-# Use a pink prompt
-set ::tkcon::COLOR(prompt) pink
-######################################################
-[example_end]
-
-[see_also [cmd tkcon](1)]
-[see_also [cmd dump](n) [cmd tkcon](n) [cmd idebug](n)]
-[see_also [cmd observe](n)]
-[keywords Tk console]
-
-[manpage_end]
-
diff --git a/tkcon-2.5/docs/todo.html b/tkcon-2.5/docs/todo.html
deleted file mode 100755
index f9c2b3a..0000000
--- a/tkcon-2.5/docs/todo.html
+++ /dev/null
@@ -1,99 +0,0 @@
-<HTML>
-<HEAD>
-<TITLE>tkcon: To Do Ideas</TITLE>
-<LINK REL="STYLESHEET" TYPE="text/css" HREF="./style.css">
-</HEAD>
-
-<BODY BGCOLOR=#FFFFFF>
-
-<TABLE WIDTH=100% BORDER=0 CELLSPACING=2 CELLPADDING=0 BGCOLOR=#000000><TR><TD>
-<!-- start header info -->
-<TABLE WIDTH=100% BORDER=0 CELLSPACING=0 CELLPADDING=0 BGCOLOR=#FFFFFF>
-<TR>
-<TH><FONT SIZE=+3>tkcon: To Do Ideas</FONT></TH>
-<TD align=right>
-<A href="http://tkcon.sourceforge.net/"> 
-<IMG src="http://sourceforge.net/sflogo.php?group_id=11462&type=1" width="88"
-height="31" border="0" alt="SourceForge Logo"></A>
-</TD>
-</TR>
-</TABLE>
-<!-- end header info -->
-
-</TD></TR><TR><TD>
-<!-- start main navigation table -->
-<TABLE BORDER=1 CELLPADDING=2 CELLSPACING=2 BGCOLOR=#CCCCCC width=100%>
-<TR>
-<TH><A HREF="index.html">Documentation</A></TH>
-<TH><A HREF="purpose.html">Purpose & Features</A></TH>
-<TH><A HREF="limits.html">Limitations</A></TH>
-<TH CLASS="hi"><A HREF="todo.html" CLASS="hi">To Do</A></TH>
-<TH><A HREF="license.terms">License</A></TH>
-</TR><TR>
-<TH COLSPAN=2><A HREF="plugin.html">Online Demo</A>
-(requires <A HREF="http://tcl.activestate.com/software/plugin/">Tk plugin</A>)</TH>
-<TH COLSPAN=3><A HREF="nontcl.html">Using TkCon with other Tk Languages</A></TH>
-</TR>
-</TABLE>
-<!-- end main navigation table -->
-
-</TD></TR><TR><TD BGCOLOR=#FFFFFF>
-<DIV CLASS="indent">
-<H3>Future Ideas</H3>
-
-<UL>
-<LI> Add encoding auto-conversion to exec commands
-<LI> keep history file, also keep history of sourced files
-<LI> <PRE>set mimetype(extension,au) "audio/u-law"
-set mimetype(extension,wav) "audio/wave"
-set mimetype(extension,mid) "audio/midi"
-/etc/magic
-proc run {file} {
-    global mimetype
-
-    if {[file executable $file]} {
-        exec $file
-        return
-    }
-
-    catch {set mimetype $mimetype(extension,[file extension $file])}
-
-    if {![info exists mimetype]} {
-        set mimetype $mimetype(magic,[exec /bin/file $file])
-    }
-
-    exec $mimetype(application,$mimetype) $file
-}</PRE>
-
-<LI> Add socket level communication model
-<LI> Enhance the true debugging capabilities - I'm looking at
-tcl-debug and into what I can adopt from the tkInspect philosophy.
-<LI> I'm taking ideas...
-</UL>
-
-<H3>Known Bugs/Quirks</H3>
-
-<UL>
-<LI> Command highlighting isn't perfect because I try to make it too
-efficient.
-<LI> All interpreters have the same current working directory.  This is
-a limitation of tcl.
-<LI> You can't 'attach' on machines where <CODE>send</CODE> does not exist.
-<A HREF="http://www.osf.org/~loverso/">John Loverso</A> has a comm.tcl
-replacement.
-In any case, you can still attach to internal interpreters and namespaces.
-<LI> Need to clean up checkpointed states when the associated interp dies.
-Works with slaves, but not foreign interps.
-<LI> Can't identify non-Tcl or pre-Tk4 interpreters automagically...
-<LI> You tell me...
-</UL>
-
-</DIV>
-</TD></TR></TABLE>
-
-<HR NOSHADE SIZE=1>
-<ADDRESS><FONT SIZE=2>©
-Jeffrey Hobbs</FONT></ADDRESS>
-
-</BODY>
-</HTML>
diff --git a/tkcon-2.5/extra/console1_1.tcl b/tkcon-2.5/extra/console1_1.tcl
deleted file mode 100644
index 78975f0..0000000
--- a/tkcon-2.5/extra/console1_1.tcl
+++ /dev/null
@@ -1,2209 +0,0 @@
-##
-## Copyright 1996-1997 Jeffrey Hobbs
-##
-## source standard_disclaimer.tcl
-## source beer_ware.tcl
-##
-## Based off previous work for TkCon
-##
-
-##------------------------------------------------------------------------
-## PROCEDURE
-##	console
-##
-## DESCRIPTION
-##	Implements a console mega-widget
-##
-## ARGUMENTS
-##	console <window pathname> <options>
-##
-## OPTIONS
-##	(Any toplevel widget option may be used in addition to these)
-##
-##  -blinkcolor color			DEFAULT: yellow
-##	Specifies the background blink color for brace highlighting.
-##	This doubles as the highlight color for the find box.
-##
-##  -blinkrange TCL_BOOLEAN		DEFAULT: 1
-##	When doing electric brace matching, specifies whether to blink
-##	the entire range or just the matching braces.
-##
-##  -proccolor color			DEFAULT: darkgreen
-##	Specifies the color to highlight recognized procs.
-##
-##  -promptcolor color			DEFAULT: brown
-##	Specifies the prompt color.
-##
-##  -stdincolor color			DEFAULT: black
-##	Specifies the color for "stdin".
-##	This doubles as the console foreground color.
-##
-##  -stdoutcolor color			DEFAULT: blue
-##	Specifies the color for "stdout".
-##
-##  -stderrcolor color			DEFAULT: red
-##	Specifies the color for "stderr".
-##
-##  -blinktime delay			DEFAULT: 500
-##	For electric brace matching, specifies the amount of time to
-##	blink the background for.
-##
-##  -cols ##				DEFAULT: 80
-##	Specifies the startup width of the console.
-##
-##  -grabputs TCL_BOOLEAN		DEFAULT: 1
-##	Whether this console should grab the "puts" default output
-##
-##  -lightbrace TCL_BOOLEAN		DEFAULT: 1
-##	Specifies whether to activate electric brace matching.
-##
-##  -lightcmd TCL_BOOLEAN		DEFAULT: 1
-##	Specifies whether to highlight recognized commands.
-##
-##  -rows ##				DEFAULT: 20
-##	Specifies the startup height of the console.
-##
-##  -scrollypos left|right		DEFAULT: right
-##	Specified position of the console scrollbar relative to the text.
-##
-##  -showmultiple TCL_BOOLEAN		DEFAULT: 1
-##	For file/proc/var completion, specifies whether to display
-##	completions when multiple choices are possible.
-##
-##  -showmenu TCL_BOOLEAN		DEFAULT: 1
-##	Specifies whether to show the menubar.
-##
-##  -subhistory TCL_BOOLEAN		DEFAULT: 1
-##	Specifies whether to allow substitution in the history.
-##
-## RETURNS: the window pathname
-##
-## BINDINGS (these are the bindings for Console, used in the text widget)
-##
-## <<Console_ExpandFile>>	<Key-Tab>
-## <<Console_ExpandProc>>	<Control-Shift-Key-P>
-## <<Console_ExpandVar>>	<Control-Shift-Key-V>
-## <<Console_Tab>>		<Control-Key-i>
-## <<Console_Eval>>		<Key-Return> <Key-KP_Enter>
-##
-## <<Console_Clear>>		<Control-Key-l>
-## <<Console_KillLine>>		<Control-Key-k>
-## <<Console_Transpose>>	<Control-Key-t>
-## <<Console_ClearLine>>	<Control-Key-u>
-## <<Console_SaveCommand>>	<Control-Key-z>
-##
-## <<Console_Previous>>		<Key-Up>
-## <<Console_Next>>		<Key-Down>
-## <<Console_NextImmediate>>	<Control-Key-n>
-## <<Console_PreviousImmediate>>	<Control-Key-p>
-## <<Console_PreviousSearch>>	<Control-Key-r>
-## <<Console_NextSearch>>	<Control-Key-s>
-##
-## <<Console_Exit>>		<Control-Key-q>
-## <<Console_New>>		<Control-Key-N>
-## <<Console_Close>>		<Control-Key-w>
-## <<Console_About>>		<Control-Key-A>
-## <<Console_Help>>		<Control-Key-H>
-## <<Console_Find>>		<Control-Key-F>
-##
-## METHODS
-##	These are the methods that the console megawidget recognizes.
-##
-## configure ?option? ?value option value ...?
-## cget option
-##	Standard tk widget routines.
-##
-## load ?filename?
-##	Loads the named file into the current interpreter.
-##	If no file is specified, it pops up the file requester.
-##
-## save ?filename?
-##	Saves the console buffer to the named file.
-##	If no file is specified, it pops up the file requester.
-##
-## clear ?percentage?
-##	Clears a percentage of the console buffer (1-100).  If no
-##	percentage is specified, the entire buffer is cleared.
-##
-## error
-##	Displays the last error in the interpreter in a dialog box.
-##
-## hide
-##	Withdraws the console from the screen
-##
-## history ?-newline?
-##	Prints out the history without numbers (basically providing a
-##	list of the commands you've used).
-##
-## show
-##	Deiconifies and raises the console
-##
-## subwidget widget
-##	Returns the true widget path of the specified widget.  Valid
-##	widgets are console, scrolly, menubar.
-##
-## NAMESPACE & STATE
-##	The megawidget creates a global array with the classname, and a
-## global array which is the name of each megawidget created.  The latter
-## array is deleted when the megawidget is destroyed.
-##	The procedure console and those beginning with Console are
-## used.  Also, when a widget is created, commands named .$widgetname
-## and Console$widgetname are created.
-##
-## EXAMPLE USAGE:
-##
-## console .con -rows 24 -showmenu false
-##
-##------------------------------------------------------------------------
-
-package require Tk
-
-proc megawidget {CLASS} {
-  upvar \#0 $CLASS class
-
-  foreach o [array names class -*] {
-    foreach {name cname val} $class($o) {
-      if [string match -* $name] continue
-      option add *$CLASS.$name [uplevel \#0 [list subst $val]] widgetDefault
-    }
-  }
-  set class(class) $CLASS
-
-  bind $CLASS <Destroy> "catch {${CLASS}_destroy %W}"
-
-  ;proc $CLASS:eval {w method args} {
-    upvar \#0 $w data
-    set class [winfo class $w]
-    if [string match {} [set arg [info command ${class}_$method]]] {
-      set arg [info command ${class}_$method*]
-    }
-    set num [llength $arg]
-    if {$num==1} {
-      return [uplevel $arg [list $w] $args]
-    } elseif {$num} {
-      return -code error "ambiguous option \"$method\""
-    } elseif {[catch {uplevel [list $data(cmd) $method] $args} err]} {
-      return -code error $err
-    } else {
-      return $err
-    }
-  }
-
-  ;proc ${CLASS}_destroy w {
-    upvar \#0 $w data
-    catch { [winfo class $w]:destroy $w }
-    catch { rename $w {} }
-    catch { rename $data(cmd) {} }
-    catch { unset data }
-  }
-
-  ;proc ${CLASS}_cget {w args} {
-    if {[llength $args] != 1} {
-      return -code error "wrong \# args: should be \"$w cget option\""
-    }
-    upvar \#0 $w data [winfo class $w] class
-    if {[info exists class($args)] && [string match -* $class($args)]} {
-      set args $class($args)
-    }
-    if [string match {} [set arg [array names data $args]]] {
-      set arg [array names data ${args}*]
-    }
-    set num [llength $arg]
-    if {$num==1} {
-      return $data($arg)
-    } elseif {$num} {
-      return -code error "ambiguous option \"$args\""
-    } elseif {[catch {$data(cmd) cget $args} err]} {
-      return -code error $err
-    } else {
-      return $err
-    }
-  }
-
-  ;proc ${CLASS}_configure {w args} {
-    upvar \#0 $w data [winfo class $w] class
-
-    set num [llength $args]
-    if {$num==1} {
-      if {[info exists class($args)] && [string match -* $class($args)]} {
-	set args $class($args)
-      }
-      if [string match {} [set arg [array names data $args]]] {
-	set arg [array names data ${args}*]
-      }
-      set num [llength $arg]
-      if {$num==1} {
-	return [list $arg $class($arg) $data($arg)]
-      } elseif {$num} {
-	return -code error "ambiguous option \"$args\""
-      } elseif {[catch {$data(cmd) config $args} err]} {
-	return -code error $err
-      } else {
-	return $err
-      }
-    } elseif {$num} {
-      for {set i 0} {$i<$num} {incr i} {
-	set key [lindex $args $i]
-	if {[info exists class($key)] && [string match -* $class($key)]} {
-	  set key $class($key)
-	}
-	if [string match {} [set arg [array names data $key]]] {
-	  set arg [array names data $key*]
-	}
-	set val [lindex $args [incr i]]
-	set len [llength $arg]
-	if {$len==1} {
-	  $class(class):configure $w $arg $val
-	} elseif {$len} {
-	  return -code error "ambiguous option \"$args\""
-	} elseif {[catch {$data(cmd) configure $key $val} err]} {
-	  return -code error $err
-	}
-      }
-      return
-    } else {
-      set conf [$data(cmd) config]
-      foreach i [array names data -*] {
-	lappend conf "$i $class($i) [list $data($i)]"
-      }
-      return [lsort $conf]
-    }
-  }
-
-  ;proc $CLASS:configure {w key value}  {
-    puts "$w: $key configured to [list $value]"
-  }
-
-  return $CLASS
-}
-
-foreach pkg [info loaded {}] {
-  set file [lindex $pkg 0]
-  set name [lindex $pkg 1]
-  if {![catch {set version [package require $name]}]} {
-    if {[string match {} [package ifneeded $name $version]]} {
-      package ifneeded $name $version "load [list $file $name]"
-    }
-  }
-}
-catch {unset file name version}
-
-set Console(WWW) [info exists embed_args]
-
-array set Console {
-  -blinkcolor	{blinkColor	BlinkColor	yellow}
-  -blinkrange	{blinkRange	BlinkRange	1}
-  -proccolor	{procColor	ProcColor	darkgreen}
-  -promptcolor	{promptColor	PromptColor	brown}
-  -stdincolor	{stdinColor	StdinColor	black}
-  -stdoutcolor	{stdoutColor	StdoutColor	blue}
-  -stderrcolor	{stderrColor	StderrColor	red}
-
-  -blinktime	{blinkTime	BlinkTime	500}
-  -cols		{columns	Columns		80}
-  -grabputs	{grabPuts	GrabPuts	0}
-  -lightbrace	{lightBrace	LightBrace	1}
-  -lightcmd	{lightCmd	LightCmd	1}
-  -rows		{rows		Rows		20}
-  -scrollypos	{scrollYPos	ScrollYPos	right}
-  -showmultiple	{showMultiple	ShowMultiple	1}
-  -showmenu	{showMenu	ShowMenu	1}
-  -subhistory	{subhistory	SubHistory	1}
-
-  active	{}
-  version	1.2
-  release	{February 1997}
-  contact	{jhobbs at cs.uoregon.edu}
-  docs		{http://www.sunlabs.com/tcl/plugin/}
-  slavealias	{ console }
-  slaveprocs	{ alias dir dump lremove puts echo unknown tcl_unknown which }
-}
-
-if [string compare unix $tcl_platform(platform)] {
-  set Console(-font) {font	Font	{Courier 14}}
-} else {
-  set Console(-font) {font	Font	fixed}
-}
-
-if $Console(WWW) {
-  set Console(-prompt) {prompt	Prompt	{\[history nextid\] % }}
-} else {
-  set Console(-prompt) {prompt	Prompt	\
-      {(\[file tail \[pwd\]\]) \[history nextid\] % }}
-}
-
-megawidget Console
-
-## console -
-# ARGS:	w	- widget pathname of the Console console
-#	args
-# Calls:	ConsoleInitUI
-# Outputs:	errors found in Console resource file
-##
-proc console {W args} {
-  set CLASS Console
-  upvar \#0 $W data $CLASS class
-  if {[winfo exists $W]} {
-    catch {eval destroy [winfo children $W]}
-  } else {
-    toplevel $W -class $CLASS
-  }
-  wm withdraw $W
-  wm title $W "Console $class(version)"
-
-  ## User definable options
-  foreach o [array names class -*] {
-    if [string match -* $class($o)] continue
-    set data($o) [option get $W [lindex $class($o) 0] $CLASS]
-  }
-
-  global auto_path tcl_pkgPath tcl_interactive
-  set tcl_interactive 1
-
-  ## Private variables
-  array set data {
-    appname {} cmdbuf {} cmdsave {} errorInfo {}
-    event 1 histid 0 find {} find,case 0 find,reg 0
-  }
-  array set data [list class $CLASS cmd $CLASS$W \
-      menubar	$W.bar \
-      console	$W.text \
-      scrolly	$W.sy \
-      ]
-
-  rename $W $data(cmd)
-  if {[string comp {} $args] && \
-      [catch {eval ${CLASS}_configure $W $args} err]} {
-    catch {destroy $W}
-    catch {unset data}
-    return -code error $err
-  }
-  ;proc $W args "eval $CLASS:eval [list $W] \$args"
-
-  if {![info exists tcl_pkgPath]} {
-    set dir [file join [file dirname [info nameofexec]] lib]
-    if [string comp {} [info commands @scope]] {
-      set dir [file join $dir itcl]
-    }
-    catch {source [file join $dir pkgIndex.tcl]}
-  }
-  catch {tclPkgUnknown dummy-name dummy-version}
-
-  ## Menus
-  frame $data(menubar) -relief raised -bd 2
-  set c [text $data(console) -font $data(-font) -wrap char -setgrid 1 \
-      -yscrollcomm [list $W.sy set] -foreground $data(-stdincolor) \
-      -width $data(-cols) -height $data(-rows)]
-  bindtags $W [list $W all]
-  bindtags $c [list $c PreCon Console PostCon $W all]
-  scrollbar $data(scrolly) -takefocus 0 -bd 1 -command "$c yview"
-
-  ConsoleInitMenus $W
-
-  if $data(-showmenu) { pack $data(menubar) -fill x }
-  pack $data(scrolly) -side $data(-scrollypos) -fill y
-  pack $c -fill both -expand 1
-
-  Console:prompt $W "console display active\n"
-
-  foreach col {prompt stdout stderr stdin proc} {
-    $c tag configure $col -foreground $data(-${col}color)
-  }
-  $c tag configure blink -background $data(-blinkcolor)
-  $c tag configure find -background $data(-blinkcolor)
-
-  bind $c <Configure> {
-    set W [winfo toplevel %W]
-    scan [wm geometry $W] "%%dx%%d" $W\(-cols\) $W\(-rows\)
-  }
-  wm deiconify $W
-  focus -force $c
-
-  return $W
-}
-
-;proc Console:configure { W key val } {
-  upvar \#0 $W data
-  global Console
-
-  set truth {^(1|yes|true|on)$}
-  switch -- $key {
-    -blinkcolor		{
-      $data(console) tag config blink -background $val
-      $data(console) tag config find -background $val
-    }
-    -proccolor		{ $data(console) tag config proc   -foreground $val }
-    -promptcolor	{ $data(console) tag config prompt -foreground $val }
-    -stdincolor		{
-      $data(console) tag config stdin  -foreground $val
-      $data(console) config -foreground $val
-    }
-    -stdoutcolor	{ $data(console) tag config stdout -foreground $val }
-    -stderrcolor	{ $data(console) tag config stderr -foreground $val }
-
-    -blinktime		{
-      if ![regexp {[0-9]+} $val] {
-	return -code error "$key option requires an integer value"
-      }
-    }
-    -cols		{
-      if [winfo exists $data(console)] { $data(console) config -width $val }
-    }
-    -font		{ $data(console) config -font $val }
-    -grabputs		{
-      set val [regexp -nocase $truth $val]
-      if $val {
-	set Console(active) [linsert $Console(active) 0 $W]
-      } else {
-	set Console(active) [lremove -all $Console(active) $W]
-      }
-    }
-    -lightbrace		{ set val [regexp -nocase $truth $val] }
-    -lightcmd		{ set val [regexp -nocase $truth $val] }
-    -prompt		{
-      if [catch {uplevel \#0 [list subst $val]} err] {
-	return -code error "\"$val\" threw an error:\n$err"
-      }
-    }
-    -rows		{
-      if [winfo exists $data(console)] { $data(console) config -height $val }
-    }
-    -scrollypos		{
-      if [regexp {^(left|right)$} $val junk val] {
-	if [winfo exists $data(scrolly)] {
-	  pack config $data(scrolly) -side $val
-	}
-      } else {
-	return -code error "bad option \"$val\": must be left or right"
-      }
-    }
-    -showmultiple	{ set val [regexp -nocase $truth $val] }
-    -showmenu		{
-      set val [regexp -nocase $truth $val]
-      if [winfo exists $data(menubar)] {
-	if $val {
-	  pack $data(menubar) -fill x -before $data(console) \
-	      -before $data(scrolly)
-	} else { pack forget $data(menubar) }
-      }
-    }
-    -subhistory		{ set val [regexp -nocase $truth $val] }
-  }
-  set data($key) $val
-}
-
-;proc Console:destroy W {
-  global Console
-  set Console(active) [lremove $Console(active) $W]
-}
-
-## ConsoleEval - evaluates commands input into console window
-## This is the first stage of the evaluating commands in the console.
-## They need to be broken up into consituent commands (by ConsoleCmdSep) in
-## case a multiple commands were pasted in, then each is eval'ed (by
-## ConsoleEvalCmd) in turn.  Any uncompleted command will not be eval'ed.
-# ARGS:	w	- console text widget
-# Calls:	ConsoleCmdGet, ConsoleCmdSep, ConsoleEvalCmd
-## 
-;proc ConsoleEval {w} {
-  ConsoleCmdSep [ConsoleCmdGet $w] cmds cmd
-  $w mark set insert end-1c
-  $w insert end \n
-  if [llength $cmds] {
-    foreach c $cmds {ConsoleEvalCmd $w $c}
-    $w insert insert $cmd {}
-  } elseif {[info complete $cmd] && ![regexp {[^\\]\\$} $cmd]} {
-    ConsoleEvalCmd $w $cmd
-  }
-  $w see insert
-}
-
-## ConsoleEvalCmd - evaluates a single command, adding it to history
-# ARGS:	w	- console text widget
-# 	cmd	- the command to evaluate
-# Calls:	Console:prompt
-# Outputs:	result of command to stdout (or stderr if error occured)
-# Returns:	next event number
-## 
-;proc ConsoleEvalCmd {w cmd} {
-  ## HACK to get $W as we need it
-  set W [winfo parent $w]
-  upvar \#0 $W data
-
-  $w mark set output end
-  if [string comp {} $cmd] {
-    set err 0
-    if $data(-subhistory) {
-      set ev [ConsoleEvalSlave history nextid]
-      incr ev -1
-      if {[string match !! $cmd]} {
-	set err [catch {ConsoleEvalSlave history event $ev} cmd]
-	if !$err {$w insert output $cmd\n stdin}
-      } elseif {[regexp {^!(.+)$} $cmd dummy event]} {
-	## Check last event because history event is broken
-	set err [catch {ConsoleEvalSlave history event $ev} cmd]
-	if {!$err && ![string match ${event}* $cmd]} {
-	  set err [catch {ConsoleEvalSlave history event $event} cmd]
-	}
-	if !$err {$w insert output $cmd\n stdin}
-      } elseif {[regexp {^\^([^^]*)\^([^^]*)\^?$} $cmd dummy old new]} {
-	if ![set err [catch {ConsoleEvalSlave history event $ev} cmd]] {
-	  regsub -all -- $old $cmd $new cmd
-	  $w insert output $cmd\n stdin
-	}
-      }
-    }
-    if $err {
-      $w insert output $cmd\n stderr
-    } else {
-      if [string match {} $data(appname)] {
-	if [catch {ConsoleEvalSlave eval $cmd} res] {
-	  set data(errorInfo) [ConsoleEvalSlave set errorInfo]
-	  set err 1
-	}
-      } else {
-	if [catch [list ConsoleEvalAttached $cmd] res] {
-	  if [catch {ConsoleEvalAttached set errorInfo} err] {
-	    set data(errorInfo) {Error attempting to retrieve errorInfo}
-	  } else {
-	    set data(errorInfo) $err
-	  }
-	  set err 1
-	}
-      }
-      ConsoleEvalSlave history add $cmd
-      if $err {
-	$w insert output $res\n stderr
-      } elseif {[string comp {} $res]} {
-	$w insert output $res\n stdout
-      }
-    }
-  }
-  Console:prompt $W
-  set data(event) [ConsoleEvalSlave history nextid]
-}
-
-## ConsoleEvalSlave - evaluates the args in the associated slave
-## args should be passed to this procedure like they would be at
-## the command line (not like to 'eval').
-# ARGS:	args	- the command and args to evaluate
-##
-;proc ConsoleEvalSlave {args} {
-  uplevel \#0 $args
-}
-
-## ConsoleEvalAttached
-##
-;proc ConsoleEvalAttached {args} {
-  eval uplevel \#0 $args
-}
-
-## ConsoleCmdGet - gets the current command from the console widget
-# ARGS:	w	- console text widget
-# Returns:	text which compromises current command line
-## 
-;proc ConsoleCmdGet w {
-  if [string match {} [$w tag nextrange prompt limit end]] {
-    $w tag add stdin limit end-1c
-    return [$w get limit end-1c]
-  }
-}
-
-## ConsoleCmdSep - separates multiple commands into a list and remainder
-# ARGS:	cmd	- (possible) multiple command to separate
-# 	list	- varname for the list of commands that were separated.
-#	rmd	- varname of any remainder (like an incomplete final command).
-#		If there is only one command, it's placed in this var.
-# Returns:	constituent command info in varnames specified by list & rmd.
-## 
-;proc ConsoleCmdSep {cmd ls rmd} {
-  upvar $ls cmds $rmd tmp
-
-  set tmp {}
-  set cmds {}
-  foreach cmd [split [set cmd] \n] {
-    if [string comp {} $tmp] {
-      append tmp \n$cmd
-    } else {
-      append tmp $cmd
-    }
-    if {[info complete $tmp] && ![regexp {[^\\]\\$} $tmp]} {
-      lappend cmds $tmp
-      set tmp {}
-    }
-  }
-  if {[string comp {} [lindex $cmds end]] && [string match {} $tmp]} {
-    set tmp [lindex $cmds end]
-    set cmds [lreplace $cmds end end]
-  }
-}
-
-## Console:prompt - displays the prompt in the console widget
-# ARGS:	w	- console text widget
-# Outputs:	prompt (specified in data(-prompt)) to console
-## 
-;proc Console:prompt {W {pre {}} {post {}} {prompt {}}} {
-  upvar \#0 $W data
-
-  set w $data(console)
-  if [string comp {} $pre] { $w insert end $pre stdout }
-  set i [$w index end-1c]
-  if [string comp {} $data(appname)] {
-    $w insert end ">$data(appname)< " prompt
-  }
-  if [string comp {} $prompt] {
-    $w insert end $prompt prompt
-  } else {
-    $w insert end [ConsoleEvalSlave subst $data(-prompt)] prompt
-  }
-  $w mark set output $i
-  $w mark set insert end
-  $w mark set limit insert
-  $w mark gravity limit left
-  if [string comp {} $post] { $w insert end $post stdin }
-  $w see end
-}
-
-## ConsoleAbout - gives about info for Console
-## 
-;proc ConsoleAbout W {
-  global Console
-
-  set w $W.about
-  if [winfo exists $w] {
-    wm deiconify $w
-  } else {
-    toplevel $w
-    wm title $w "About Console v$Console(version)"
-    button $w.b -text Dismiss -command [list wm withdraw $w]
-    text $w.text -height 8 -bd 1 -width 60
-    pack $w.b -fill x -side bottom
-    pack $w.text -fill both -side left -expand 1
-    $w.text tag config center -justify center
-    $w.text tag config title -justify center -font {Courier 18 bold}
-    $w.text insert 1.0 "About Console v$Console(version)\n\n" title \
-	"Copyright 1995-1997 Jeffrey Hobbs, $Console(contact)\
-	\nhttp://www.cs.uoregon.edu/~jhobbs/\
-	\nRelease Date: v$Console(version), $Console(release)\
-	\nDocumentation available at:\n$Console(docs)" center
-  }
-}
-
-## ConsoleInitMenus - inits the menubar and popup for the console
-# ARGS:	W	- console
-## 
-;proc ConsoleInitMenus {W} {
-  upvar \#0 $W data
-
-  set w    $data(menubar)
-  set text $data(console)
-
-  if [catch {menu $w.pop -tearoff 0}] {
-    label $w.label -text "Menus not available in plugin mode"
-    pack $w.label
-    return
-  }
-  bind [winfo toplevel $w] <Button-3> "tk_popup $w.pop %X %Y"
-
-  pack [menubutton $w.con  -text "Console"  -un 0 -menu $w.con.m] -side left
-  $w.pop add cascade -label "Console" -un 0 -menu $w.pop.con
-
-  pack [menubutton $w.edit -text "Edit"     -un 0 -menu $w.edit.m] -side left
-  $w.pop add cascade -label "Edit"    -un 0 -menu $w.pop.edit
-
-  pack [menubutton $w.pref -text "Prefs"    -un 0 -menu $w.pref.m] -side left
-  $w.pop add cascade -label "Prefs"   -un 0 -menu $w.pop.pref
-
-  pack [menubutton $w.hist -text "History"  -un 0 -menu $w.hist.m] -side left
-  $w.pop add cascade -label "History"   -un 0 -menu $w.pop.hist
-
-  pack [menubutton $w.help -text "Help"     -un 0 -menu $w.help.m] -side right
-  $w.pop add cascade -label "Help"    -un 0 -menu $w.pop.help
-
-  ## Console Menu
-  ##
-  foreach m [list [menu $w.con.m -disabledfore $data(-promptcolor)] \
-		 [menu $w.pop.con -disabledfore $data(-promptcolor)]] {
-    $m add command -label "Console $W" -state disabled
-    $m add command -label "Close Console " -un 0 \
-	-acc [event info <<Console_Close>>] -com [list destroy $W]
-    $m add command -label "Clear Console " -un 1 \
-	-acc [event info <<Console_Clear>>] -com [list Console_clear $W]
-    $m add separator
-    $m add command -label "Quit" -un 0 -acc [event info <<Console_Exit>>] \
-	-command exit
-  }
-
-  ## Edit Menu
-  ##
-  foreach m [list [menu $w.edit.m] [menu $w.pop.edit]] {
-    $m add command -label "Cut"   -un 1 \
-	-acc [lindex [event info <<Cut>>] 0] \
-	-command [list ConsoleCut $text]
-    $m add command -label "Copy"  -un 1 \
-	-acc [lindex [event info <<Copy>>] 0] \
-	-command [list ConsoleCopy $text]
-    $m add command -label "Paste" -un 0 \
-	-acc [lindex [event info <<Paste>>] 0] \
-	-command [list ConsolePaste $text]
-    $m add separator
-    $m add command -label "Find"  -un 0 -acc [event info <<Console_Find>>] \
-	-command [list ConsoleFindBox $W]
-  }
-
-  ## Prefs Menu
-  ##
-  foreach m [list [menu $w.pref.m] [menu $w.pop.pref]] {
-    $m add checkbutton -label "Brace Highlighting"    -var $W\(-lightbrace\)
-    $m add checkbutton -label "Command Highlighting"  -var $W\(-lightcmd\)
-    $m add checkbutton -label "History Substitution"  -var $W\(-subhistory\)
-    $m add checkbutton -label "Show Multiple Matches" -var $W\(-showmultiple\)
-    $m add checkbutton -label "Show Menubar"	      -var $W\(-showmenu\) \
-	-command "Console:configure $W -showmenu \[set $W\(-showmenu\)\]"
-    $m add cascade -label Scrollbar -un 0 -menu $m.scroll
-
-    ## Scrollbar Menu
-    ##
-    set m [menu $m.scroll -tearoff 0]
-    $m add radio -label "Left" -var $W\(-scrollypos\) -value left \
-	-command [list Console:configure $W -scrollypos left]
-    $m add radio -label "Right" -var $W\(-scrollypos\) -value right \
-	-command [list Console:configure $W -scrollypos right]
-  }
-
-  ## History Menu
-  ##
-  foreach m [list $w.hist.m $w.pop.hist] {
-    menu $m -disabledfore $data(-promptcolor) \
-	-postcommand [list ConsoleHistoryMenu $W $m]
-  }
-
-  ## Help Menu
-  ##
-  foreach m [list [menu $w.help.m] [menu $w.pop.help]] {
-    $m config -disabledfore $data(-promptcolor)
-    $m add command -label "About " -un 0 -acc [event info <<Console_About>>] \
-	-command [list ConsoleAbout $W]
-  }
-
-  bind $W <<Console_Exit>>	exit
-  #bind $W <<Console_New>>	ConsoleNew
-  bind $W <<Console_Close>>	[list destroy $W]
-  bind $W <<Console_About>>	[list ConsoleAbout $W]
-  bind $W <<Console_Help>>	[list ConsoleHelp $W]
-  bind $W <<Console_Find>>	[list ConsoleFindBox $W]
-
-  ## Menu items need null PostCon bindings to avoid the TagProc
-  ##
-  foreach ev [bind $W] {
-    bind PostCon $ev {
-      # empty
-    }
-  }
-}
-
-## ConsoleHistoryMenu - dynamically build the menu for attached interpreters
-##
-# ARGS:	w	- menu widget
-##
-;proc ConsoleHistoryMenu {W w} {
-  upvar \#0 $W data
-
-  if ![winfo exists $w] return
-  set id [ConsoleEvalSlave history nextid]
-  if {$data(histid)==$id} return
-  set data(histid) $id
-  $w delete 0 end
-  set con $data(console)
-  while {($id>$data(histid)-10) && \
-      ![catch {ConsoleEvalSlave history event [incr id -1]} tmp]} {
-    set lbl [lindex [split $tmp "\n"] 0]
-    if {[string len $lbl]>32} { set lbl [string range $tmp 0 30]... }
-    $w add command -label "$id: $lbl" -command "
-    $con delete limit end
-    $con insert limit [list $tmp]
-    $con see end
-    ConsoleEval $con
-    "
-  }
-}
-
-## ConsoleFindBox - creates minimal dialog interface to ConsoleFind
-# ARGS:	w	- text widget
-#	str	- optional seed string for data(find)
-##
-;proc ConsoleFindBox {W {str {}}} {
-  upvar \#0 $W data
-
-  set t $data(console)
-  set base $W.find
-  if ![winfo exists $base] {
-    toplevel $base
-    wm withdraw $base
-    wm title $base "Console Find"
-
-    pack [frame $base.f] -fill x -expand 1
-    label $base.f.l -text "Find:"
-    entry $base.f.e -textvar $W\(find\)
-    pack [frame $base.opt] -fill x
-    checkbutton $base.opt.c -text "Case Sensitive" -variable $W\(find,case\)
-    checkbutton $base.opt.r -text "Use Regexp" -variable $W\(find,reg\)
-    pack $base.f.l -side left
-    pack $base.f.e $base.opt.c $base.opt.r -side left -fill both -expand 1
-    pack [frame $base.sep -bd 2 -relief sunken -height 4] -fill x
-    pack [frame $base.btn] -fill both
-    button $base.btn.fnd -text "Find" -width 6
-    button $base.btn.clr -text "Clear" -width 6
-    button $base.btn.dis -text "Dismiss" -width 6
-    eval pack [winfo children $base.btn] -padx 4 -pady 2 -side left -fill both
-
-    focus $base.f.e
-
-    bind $base.f.e <Return> [list $base.btn.fnd invoke]
-    bind $base.f.e <Escape> [list $base.btn.dis invoke]
-  }
-  $base.btn.fnd config -command "Console_find $W \$data(find) \
-      -case \$data(find,case) -reg \$data(find,reg)"
-  $base.btn.clr config -command "
-  $t tag remove find 1.0 end
-  set data(find) {}
-  "
-  $base.btn.dis config -command "
-  $t tag remove find 1.0 end
-  wm withdraw $base
-  "
-  if [string comp {} $str] {
-    set data(find) $str
-    $base.btn.fnd invoke
-  }
-
-  if {[string comp normal [wm state $base]]} {
-    wm deiconify $base
-  } else { raise $base }
-  $base.f.e select range 0 end
-}
-
-## Console_find - searches in text widget for $str and highlights it
-## If $str is empty, it just deletes any highlighting
-# ARGS: W	- console widget
-#	str	- string to search for
-#	-case	TCL_BOOLEAN	whether to be case sensitive	DEFAULT: 0
-#	-regexp	TCL_BOOLEAN	whether to use $str as pattern	DEFAULT: 0
-##
-;proc ConsoleFind {W str args} {
-  upvar \#0 $W data
-  set t $data(console)
-  $t tag remove find 1.0 end
-  set truth {^(1|yes|true|on)$}
-  set opts  {}
-  foreach {key val} $args {
-    switch -glob -- $key {
-      -c* { if [regexp -nocase $truth $val] { set case 1 } }
-      -r* { if [regexp -nocase $truth $val] { lappend opts -regexp } }
-      default { return -code error "Unknown option $key" }
-    }
-  }
-  if ![info exists case] { lappend opts -nocase }
-  if [string match {} $str] return
-  $t mark set findmark 1.0
-  while {[string comp {} [set ix [eval $t search $opts -count numc -- \
-      [list $str] findmark end]]]} {
-    $t tag add find $ix ${ix}+${numc}c
-    $t mark set findmark ${ix}+1c
-  }
-  catch {$t see find.first}
-  return [expr [llength [$t tag ranges find]]/2]
-}
-
-## Console:savecommand - saves a command in a buffer for later retrieval
-#
-##
-;proc Console:savecommand {w} {
-  upvar \#0 [winfo parent $w] data
-
-  set tmp $data(cmdsave)
-  set data(cmdsave) [ConsoleCmdGet $w]
-  if {[string match {} $data(cmdsave)]} {
-    set data(cmdsave) $tmp
-  } else {
-    $w delete limit end-1c
-  }
-  $w insert limit $tmp
-  $w see end
-}
-
-## Console_load - sources a file into the console
-# ARGS:	fn	- (optional) filename to source in
-# Returns:	selected filename ({} if nothing was selected)
-## 
-;proc Console_load {W {fn {}}} {
-  if {[string match {} $fn] &&
-      ([catch {tk_getOpenFile} fn] || [string match {} $fn])} return
-  ConsoleEvalAttached [list source $fn]
-}
-
-## Console_save - saves the console buffer to a file
-## This does not eval in a slave because it's not necessary
-# ARGS:	w	- console text widget
-# 	fn	- (optional) filename to save to
-## 
-;proc Console_save {W {fn {}}} {
-  upvar \#0 $W data
-
-  if {[string match {} $fn] &&
-      ([catch {tk_getSaveFile} fn] || [string match {} $fn])} return
-  if [catch {open $fn w} fid] {
-    return -code error "Save Error: Unable to open '$fn' for writing\n$fid"
-  }
-  puts $fid [$data(console) get 1.0 end-1c]
-  close $fid
-}
-
-## clear - clears the buffer of the console (not the history though)
-## 
-;proc Console_clear {W {pcnt 100}} {
-  upvar \#0 $W data
-
-  set data(tmp) [ConsoleCmdGet $data(console)]
-  if {![regexp {^[0-9]*$} $pcnt] || $pcnt < 1 || $pcnt > 100} {
-    return -code error \
-	"invalid percentage to clear: must be 1-100 (100 default)"
-  } elseif {$pcnt == 100} {
-    $data(console) delete 1.0 end
-  } else {
-    set tmp [expr $pcnt/100.0*[$data(console) index end]]
-    $data(console) delete 1.0 "$tmp linestart"
-  }
-  Console:prompt $W {} $data(tmp)
-}
-
-;proc Console_error {W} {
-  ## Outputs stack caused by last error.
-  upvar \#0 $W data
-  set info $data(errorInfo)
-  if [string match {} $info] { set info {errorInfo empty} }
-  catch {destroy $W.error}
-  set w [toplevel $W.error]
-  wm title $w "Console Last Error"
-  button $w.close -text Dismiss -command [list destroy $w]
-  scrollbar $w.sy -takefocus 0 -bd 1 -command [list $w.text yview]
-  text $w.text -font $data(-font) -yscrollcommand [list $w.sy set]
-  pack $w.close -side bottom -fill x
-  pack $w.sy -side right -fill y
-  pack $w.text -fill both -expand 1
-  $w.text insert 1.0 $info
-  $w.text config -state disabled
-}
-
-## Console_event - searches for history based on a string
-## Search forward (next) if $int>0, otherwise search back (prev)
-# ARGS:	W	- console widget
-##
-;proc Console_event {W int {str {}}} {
-  upvar \#0 $W data
-
-  if !$int return
-  set w $data(console)
-
-  set nextid [ConsoleEvalSlave history nextid]
-  if [string comp {} $str] {
-    ## String is not empty, do an event search
-    set event $data(event)
-    if {$int < 0 && $event == $nextid} { set data(cmdbuf) $str }
-    set len [string len $data(cmdbuf)]
-    incr len -1
-    if {$int > 0} {
-      ## Search history forward
-      while {$event < $nextid} {
-	if {[incr event] == $nextid} {
-	  $w delete limit end
-	  $w insert limit $data(cmdbuf)
-	  break
-	} elseif {![catch {ConsoleEvalSlave history event $event} res] \
-	    && ![string comp $data(cmdbuf) [string range $res 0 $len]]} {
-	  $w delete limit end
-	  $w insert limit $res
-	  break
-	}
-      }
-      set data(event) $event
-    } else {
-      ## Search history reverse
-      while {![catch {ConsoleEvalSlave history event [incr event -1]} res]} {
-	if {![string comp $data(cmdbuf) [string range $res 0 $len]]} {
-	  $w delete limit end
-	  $w insert limit $res
-	  set data(event) $event
-	  break
-	}
-      }
-    } 
-  } else {
-    ## String is empty, just get next/prev event
-    if {$int > 0} {
-      ## Goto next command in history
-      if {$data(event) < $nextid} {
-	$w delete limit end
-	if {[incr data(event)] == $nextid} {
-	  $w insert limit $data(cmdbuf)
-	} else {
-	  $w insert limit [ConsoleEvalSlave history event $data(event)]
-	}
-      }
-    } else {
-      ## Goto previous command in history
-      if {$data(event) == $nextid} { set data(cmdbuf) [ConsoleCmdGet $w] }
-      if [catch {ConsoleEvalSlave history event [incr data(event) -1]} res] {
-	incr data(event)
-      } else {
-	$w delete limit end
-	$w insert limit $res
-      }
-    }
-  }
-  $w mark set insert end
-  $w see end
-}
-
-;proc Console_history {W args} {
-  set sub {\2}
-  if [string match -n* $args] { append sub "\n" }
-  set h [ConsoleEvalSlave history]
-  regsub -all "( *\[0-9\]+  |\t)(\[^\n\]*\n?)" $h $sub h
-  return $h
-}
-
-;proc Console_hide {W} {
-  wm withdraw $W
-}
-
-;proc Console_show {W} {
-  wm deiconify $W
-  raise $W
-}
-
-##
-## Some procedures to make up for lack of built-in shell commands
-##
-
-## puts
-## This allows me to capture all stdout/stderr to the console window
-# ARGS:	same as usual	
-# Outputs:	the string with a color-coded text tag
-## 
-if ![catch {rename puts tcl_puts}] {
-  ;proc puts args {
-    global Console
-    set w [lindex $Console(active) 0].text
-    if {[llength $Console(active)] && [winfo exists $w]} {
-      set len [llength $args]
-      if {$len==1} {
-	eval $w insert output $args stdout {\n} stdout
-	$w see output
-      } elseif {$len==2 && \
-	  [regexp {(stdout|stderr|-nonewline)} [lindex $args 0] junk tmp]} {
-	if [string comp $tmp -nonewline] {
-	  eval $w insert output [lreplace $args 0 0] $tmp {\n} $tmp
-	} else {
-	  eval $w insert output [lreplace $args 0 0] stdout
-	}
-	$w see output
-      } elseif {$len==3 && \
-	  [regexp {(stdout|stderr)} [lreplace $args 2 2] junk tmp]} {
-	if [string comp [lreplace $args 1 2] -nonewline] {
-	  eval $w insert output [lrange $args 1 1] $tmp
-	} else {
-	  eval $w insert output [lreplace $args 0 1] $tmp
-	}
-	$w see output
-      } else {
-	global errorCode errorInfo
-	if [catch "tcl_puts $args" msg] {
-	  regsub tcl_puts $msg puts msg
-	  regsub -all tcl_puts $errorInfo puts errorInfo
-	  error $msg
-	}
-	return $msg
-      }
-      if $len update
-    } else {
-      global errorCode errorInfo
-      if [catch "tcl_puts $args" msg] {
-	regsub tcl_puts $msg puts msg
-	regsub -all tcl_puts $errorInfo puts errorInfo
-	error $msg
-      }
-      return $msg
-    }
-  }
-}
-
-## echo
-## Relaxes the one string restriction of 'puts'
-# ARGS:	any number of strings to output to stdout
-##
-proc echo args { puts [concat $args] }
-
-## alias - akin to the csh alias command
-## If called with no args, then it dumps out all current aliases
-## If called with one arg, returns the alias of that arg (or {} if none)
-# ARGS:	newcmd	- (optional) command to bind alias to
-# 	args	- command and args being aliased
-## 
-proc alias {{newcmd {}} args} {
-  if [string match {} $newcmd] {
-    set res {}
-    foreach a [interp aliases] {
-      lappend res [list $a -> [interp alias {} $a]]
-    }
-    return [join $res \n]
-  } elseif {[string match {} $args]} {
-    interp alias {} $newcmd
-  } else {
-    eval interp alias [list {} $newcmd {}] $args
-  }
-}
-
-## dump - outputs variables/procedure/widget info in source'able form.
-## Accepts glob style pattern matching for the names
-# ARGS:	type	- type of thing to dump: must be variable, procedure, widget
-# OPTS: -nocomplain
-#		don't complain if no vars match something
-#	-filter pattern
-#		specifies a glob filter pattern to be used by the variable
-#		method as an array filter pattern (it filters down for
-#		nested elements) and in the widget method as a config
-#		option filter pattern
-#	--	forcibly ends options recognition
-# Returns:	the values of the requested items in a 'source'able form
-## 
-proc dump {type args} {
-  set whine 1
-  set code  ok
-  while {[string match -* $args]} {
-    switch -glob -- [lindex $args 0] {
-      -n* { set whine 0; set args [lreplace $args 0 0] }
-      -f* { set fltr [lindex $args 1]; set args [lreplace $args 0 1] }
-      --  { set args [lreplace $args 0 0]; break }
-      default { return -code error "unknown option \"[lindex $args 0]\"" }
-    }
-  }
-  if {$whine && [string match {} $args]} {
-    return -code error "wrong \# args: [lindex [info level 0] 0]\
-	?-nocomplain? ?-filter pattern? ?--? pattern ?pattern ...?"
-  }
-  set res {}
-  switch -glob -- $type {
-    c* {
-      # command
-      # outpus commands by figuring out, as well as possible, what it is
-      # this does not attempt to auto-load anything
-      foreach arg $args {
-	if [string comp {} [set cmds [info comm $arg]]] {
-	  foreach cmd [lsort $cmds] {
-	    if {[lsearch -exact [interp aliases] $cmd] > -1} {
-	      append res "\#\# ALIAS:   $cmd => [interp alias {} $cmd]\n"
-	    } elseif {[string comp {} [info procs $cmd]]} {
-	      if {[catch {dump p -- $cmd} msg] && $whine} { set code error }
-	      append res $msg\n
-	    } else {
-	      append res "\#\# COMMAND: $cmd\n"
-	    }
-	  }
-	} elseif $whine {
-	  append res "\#\# No known command $arg\n"
-	  set code error
-	}
-      }
-    }
-    v* {
-      # variable
-      # outputs variables value(s), whether array or simple.
-      if ![info exists fltr] { set fltr * }
-      foreach arg $args {
-	if {[string match {} [set vars [uplevel info vars [list $arg]]]]} {
-	  if {[uplevel info exists $arg]} {
-	    set vars $arg
-	  } elseif $whine {
-	    append res "\#\# No known variable $arg\n"
-	    set code error
-	    continue
-	  } else continue
-	}
-	foreach var [lsort $vars] {
-	  upvar $var v
-	  if {[array exists v]} {
-	    set nest {}
-	    append res "array set $var \{\n"
-	    foreach i [lsort [array names v $fltr]] {
-	      upvar 0 v\($i\) __ary
-	      if {[array exists __ary]} {
-		append nest "\#\# NESTED ARRAY ELEMENT: $i\n"
-		append nest "upvar 0 [list $var\($i\)] __ary;\
-		    [dump v -filter $fltr __ary]\n"
-	      } else {
-		append res "    [list $i]\t[list $v($i)]\n"
-	      }
-	    }
-	    append res "\}\n$nest"
-	  } else {
-	    append res [list set $var $v]\n
-	  }
-	}
-      }
-    }
-    p* {
-      # procedure
-      foreach arg $args {
-	if {[string comp {} [set ps [info proc $arg]]] ||
-	    ([auto_load $arg] &&
-	     [string comp {} [set ps [info proc $arg]]])} {
-	  foreach p [lsort $ps] {
-	    set as {}
-	    foreach a [info args $p] {
-	      if {[info default $p $a tmp]} {
-		lappend as [list $a $tmp]
-	      } else {
-		lappend as $a
-	      }
-	    }
-	    append res [list proc $p $as [info body $p]]\n
-	  }
-	} elseif $whine {
-	  append res "\#\# No known proc $arg\n"
-	  set code error
-	}
-      }
-    }
-    w* {
-      # widget
-      ## The user should have Tk loaded
-      if [string match {} [info command winfo]] {
-	return -code error "winfo not present, cannot dump widgets"
-      }
-      if ![info exists fltr] { set fltr .* }
-      foreach arg $args {
-	if [string comp {} [set ws [info command $arg]]] {
-	  foreach w [lsort $ws] {
-	    if [winfo exists $w] {
-	      if [catch {$w configure} cfg] {
-		append res "\#\# Widget $w does not support configure method"
-		set code error
-	      } else {
-		append res "\#\# [winfo class $w] $w\n$w configure"
-		foreach c $cfg {
-		  if {[llength $c] != 5} continue
-		  if {[regexp -nocase -- $fltr $c]} {
-		    append res " \\\n\t[list [lindex $c 0] [lindex $c 4]]"
-		  }
-		}
-		append res \n
-	      }
-	    }
-	  }
-	} elseif $whine {
-	  append res "\#\# No known widget $arg\n"
-	  set code error
-	}
-      }
-    }
-    default {
-      return -code error "bad [lindex [info level 0] 0] option\
-	\"$type\":\ must be procedure, variable, widget"
-    }
-  }
-  return -code $code [string trimr $res \n]
-}
-
-## which - tells you where a command is found
-# ARGS:	cmd	- command name
-# Returns:	where command is found (internal / external / unknown)
-## 
-proc which cmd {
-  if {[string comp {} [info commands $cmd]] ||
-      ([auto_load $cmd] && [string comp {} [info commands $cmd]])} {
-    if {[lsearch -exact [interp aliases] $cmd] > -1} {
-      return "$cmd:\taliased to [alias $cmd]"
-    } elseif {[string comp {} [info procs $cmd]]} {
-      return "$cmd:\tinternal proc"
-    } else {
-      return "$cmd:\tinternal command"
-    }
-  } elseif {[string comp {} [auto_execok $cmd]]} {
-    return [auto_execok $cmd]
-  } else {
-    return -code error "$cmd:\tunknown command"
-  }
-}
-
-## dir - directory list
-# ARGS:	args	- names/glob patterns of directories to list
-# OPTS:	-all	- list hidden files as well (Unix dot files)
-#	-long	- list in full format "permissions size date filename"
-#	-full	- displays / after directories and link paths for links
-# Returns:	a directory listing
-## 
-proc dir {args} {
-  array set s {
-    all 0 full 0 long 0
-    0 --- 1 --x 2 -w- 3 -wx 4 r-- 5 r-x 6 rw- 7 rwx
-  }
-  while {[string match \-* [lindex $args 0]]} {
-    set str [lindex $args 0]
-    set args [lreplace $args 0 0]
-    switch -glob -- $str {
-      -a* {set s(all) 1} -f* {set s(full) 1}
-      -l* {set s(long) 1} -- break
-      default {
-	return -code error \
-	    "unknown option \"$str\", should be one of: -all, -full, -long"
-      }
-    }
-  }
-  set sep [string trim [file join . .] .]
-  if [string match {} $args] { set args . }
-  foreach arg $args {
-    if {[file isdir $arg]} {
-      set arg [string trimr $arg $sep]$sep
-      if $s(all) {
-	lappend out [list $arg [lsort [glob -nocomplain -- $arg.* $arg*]]]
-      } else {
-	lappend out [list $arg [lsort [glob -nocomplain -- $arg*]]]
-      }
-    } else {
-      lappend out [list [file dirname $arg]$sep \
-		       [lsort [glob -nocomplain -- $arg]]]
-    }
-  }
-  if $s(long) {
-    set old [clock scan {1 year ago}]
-    set fmt "%s%9d %s %s\n"
-    foreach o $out {
-      set d [lindex $o 0]
-      append res $d:\n
-      foreach f [lindex $o 1] {
-	file lstat $f st
-	set f [file tail $f]
-	if $s(full) {
-	  switch -glob $st(type) {
-	    d* { append f $sep }
-	    l* { append f "@ -> [file readlink $d$sep$f]" }
-	    default { if [file exec $d$sep$f] { append f * } }
-	  }
-	}
-	if [string match file $st(type)] {
-	  set mode -
-	} else {
-	  set mode [string index $st(type) 0]
-	}
-	foreach j [split [format %o [expr $st(mode)&0777]] {}] {
-	  append mode $s($j)
-	}
-	if {$st(mtime)>$old} {
-	  set cfmt {%b %d %H:%M}
-	} else {
-	  set cfmt {%b %d  %Y}
-	}
-	append res [format $fmt $mode $st(size) \
-			[clock format $st(mtime) -format $cfmt] $f]
-      }
-      append res \n
-    }
-  } else {
-    foreach o $out {
-      set d [lindex $o 0]
-      append res $d:\n
-      set i 0
-      foreach f [lindex $o 1] {
-	if {[string len [file tail $f]] > $i} {
-	  set i [string len [file tail $f]]
-	}
-      }
-      set i [expr $i+2+$s(full)]
-      ## This gets the number of cols in the Console console widget
-      set j [expr 64/$i]
-      set k 0
-      foreach f [lindex $o 1] {
-	set f [file tail $f]
-	if $s(full) {
-	  switch -glob [file type $d$sep$f] {
-	    d* { append f $sep }
-	    l* { append f @ }
-	    default { if [file exec $d$sep$f] { append f * } }
-	  }
-	}
-	append res [format "%-${i}s" $f]
-	if {[incr k]%$j == 0} {set res [string trimr $res]\n}
-      }
-      append res \n\n
-    }
-  }
-  return [string trimr $res]
-}
-interp alias {} ls {} dir
-
-## lremove - remove items from a list
-# OPTS:	-all	remove all instances of each item
-# ARGS:	l	a list to remove items from
-#	args	items to remove
-##
-proc lremove {args} {
-  set all 0
-  if [string match \-a* [lindex $args 0]] {
-    set all 1
-    set args [lreplace $args 0 0]
-  }
-  set l [lindex $args 0]
-  eval append is [lreplace $args 0 0]
-  foreach i $is {
-    if {[set ix [lsearch -exact $l $i]] == -1} continue
-    set l [lreplace $l $ix $ix]
-    if $all {
-      while {[set ix [lsearch -exact $l $i]] != -1} {
-	set l [lreplace $l $ix $ix]
-      }
-    }
-  }
-  return $l
-}
-
-## Unknown changed to get output into Console window
-# unknown:
-# Invoked automatically whenever an unknown command is encountered.
-# Works through a list of "unknown handlers" that have been registered
-# to deal with unknown commands.  Extensions can integrate their own
-# handlers into the "unknown" facility via "unknown_handle".
-#
-# If a handler exists that recognizes the command, then it will
-# take care of the command action and return a valid result or a
-# Tcl error.  Otherwise, it should return "-code continue" (=2)
-# and responsibility for the command is passed to the next handler.
-#
-# Arguments:
-# args -	A list whose elements are the words of the original
-#		command, including the command name.
-
-proc unknown args {
-    global unknown_handler_order unknown_handlers errorInfo errorCode
-
-    #
-    # Be careful to save error info now, and restore it later
-    # for each handler.  Some handlers generate their own errors
-    # and disrupt handling.
-    #
-    set savedErrorCode $errorCode
-    set savedErrorInfo $errorInfo
-
-    if {![info exists unknown_handler_order] || ![info exists unknown_handlers]} {
-	set unknown_handlers(tcl) tcl_unknown
-	set unknown_handler_order tcl
-    }
-
-    foreach handler $unknown_handler_order {
-        set status [catch {uplevel $unknown_handlers($handler) $args} result]
-
-        if {$status == 1} {
-            #
-            # Strip the last five lines off the error stack (they're
-            # from the "uplevel" command).
-            #
-            set new [split $errorInfo \n]
-            set new [join [lrange $new 0 [expr [llength $new] - 6]] \n]
-            return -code $status -errorcode $errorCode \
-                -errorinfo $new $result
-
-        } elseif {$status != 4} {
-            return -code $status $result
-        }
-
-        set errorCode $savedErrorCode
-        set errorInfo $savedErrorInfo
-    }
-
-    set name [lindex $args 0]
-    return -code error "invalid command name \"$name\""
-}
-
-# tcl_unknown:
-# Invoked when a Tcl command is invoked that doesn't exist in the
-# interpreter:
-#
-#	1. See if the autoload facility can locate the command in a
-#	   Tcl script file.  If so, load it and execute it.
-#	2. If the command was invoked interactively at top-level:
-#	    (a) see if the command exists as an executable UNIX program.
-#		If so, "exec" the command.
-#	    (b) see if the command requests csh-like history substitution
-#		in one of the common forms !!, !<number>, or ^old^new.  If
-#		so, emulate csh's history substitution.
-#	    (c) see if the command is a unique abbreviation for another
-#		command.  If so, invoke the command.
-#
-# Arguments:
-# args -	A list whose elements are the words of the original
-#		command, including the command name.
-
-proc tcl_unknown args {
-  global auto_noexec auto_noload env unknown_pending tcl_interactive Console
-  global errorCode errorInfo
-
-  # Save the values of errorCode and errorInfo variables, since they
-  # may get modified if caught errors occur below.  The variables will
-  # be restored just before re-executing the missing command.
-
-  set savedErrorCode $errorCode
-  set savedErrorInfo $errorInfo
-  set name [lindex $args 0]
-  if ![info exists auto_noload] {
-    #
-    # Make sure we're not trying to load the same proc twice.
-    #
-    if [info exists unknown_pending($name)] {
-      unset unknown_pending($name)
-      if {[array size unknown_pending] == 0} {
-	unset unknown_pending
-      }
-      return -code error "self-referential recursion in \"unknown\" for command \"$name\"";
-    }
-    set unknown_pending($name) pending;
-    set ret [catch {auto_load $name} msg]
-    unset unknown_pending($name);
-    if $ret {
-      return -code $ret -errorcode $errorCode \
-	  "error while autoloading \"$name\": $msg"
-    }
-    if ![array size unknown_pending] {
-      unset unknown_pending
-    }
-    if $msg {
-      set errorCode $savedErrorCode
-      set errorInfo $savedErrorInfo
-      set code [catch {uplevel $args} msg]
-      if {$code ==  1} {
-	#
-	# Strip the last five lines off the error stack (they're
-	# from the "uplevel" command).
-	#
-
-	set new [split $errorInfo \n]
-	set new [join [lrange $new 0 [expr [llength $new] - 6]] \n]
-	return -code error -errorcode $errorCode \
-	    -errorinfo $new $msg
-      } else {
-	return -code $code $msg
-      }
-    }
-  }
-  if {[info level] == 1 && [string match {} [info script]] \
-	  && [info exists tcl_interactive] && $tcl_interactive} {
-    if ![info exists auto_noexec] {
-      set new [auto_execok $name]
-      if {$new != ""} {
-	set errorCode $savedErrorCode
-	set errorInfo $savedErrorInfo
-	return [uplevel exec [list $new] [lrange $args 1 end]]
-	#return [uplevel exec >&@stdout <@stdin $new [lrange $args 1 end]]
-      }
-    }
-    set errorCode $savedErrorCode
-    set errorInfo $savedErrorInfo
-    ##
-    ## History substitution moved into ConsoleEvalCmd
-    ##
-    set cmds [info commands $name*]
-    if {[llength $cmds] == 1} {
-      return [uplevel [lreplace $args 0 0 $cmds]]
-    }
-    if {[llength $cmds]} {
-      if {$name == ""} {
-	return -code error "empty command name \"\""
-      } else {
-	return -code error \
-	    "ambiguous command name \"$name\": [lsort $cmds]"
-      }
-    }
-  }
-  return -code continue
-}
-
-switch -glob $tcl_platform(platform) {
-  win* { set META Alt }
-  mac* { set META Command }
-  default { set META Meta }
-}
-
-# ConsoleClipboardKeysyms --
-# This procedure is invoked to identify the keys that correspond to
-# the "copy", "cut", and "paste" functions for the clipboard.
-#
-# Arguments:
-# copy -	Name of the key (keysym name plus modifiers, if any,
-#		such as "Meta-y") used for the copy operation.
-# cut -		Name of the key used for the cut operation.
-# paste -	Name of the key used for the paste operation.
-
-;proc ConsoleClipboardKeysyms {copy cut paste} {
-  bind Console <$copy>	{ConsoleCopy %W}
-  bind Console <$cut>		{ConsoleCut %W}
-  bind Console <$paste>	{ConsolePaste %W}
-}
-
-;proc ConsoleCut w {
-  if [string match $w [selection own -displayof $w]] {
-    clipboard clear -displayof $w
-    catch {
-      clipboard append -displayof $w [selection get -displayof $w]
-      if [$w compare sel.first >= limit] {$w delete sel.first sel.last}
-    }
-  }
-}
-;proc ConsoleCopy w {
-  if [string match $w [selection own -displayof $w]] {
-    clipboard clear -displayof $w
-    catch {clipboard append -displayof $w [selection get -displayof $w]}
-  }
-}
-
-;proc ConsolePaste w {
-  if ![catch {selection get -displayof $w -selection CLIPBOARD} tmp] {
-    if [$w compare insert < limit] {$w mark set insert end}
-    $w insert insert $tmp
-    $w see insert
-    if [string match *\n* $tmp] {ConsoleEval $w}
-  }
-}
-
-## Get all Text bindings into Console except Unix cut/copy/paste
-## and newline insertion
-foreach ev [lremove [bind Text] {<Control-Key-y> <Control-Key-w> \
-    <Meta-Key-w> <Control-Key-o> <Control-Key-v> <Control-Key-c> \
-    <Control-Key-x>}] {
-  bind Console $ev [bind Text $ev]
-}
-
-foreach {ev key} {
-  <<Console_Previous>>		<Key-Up>
-  <<Console_Next>>		<Key-Down>
-  <<Console_NextImmediate>>	<Control-Key-n>
-  <<Console_PreviousImmediate>>	<Control-Key-p>
-  <<Console_PreviousSearch>>	<Control-Key-r>
-  <<Console_NextSearch>>	<Control-Key-s>
-
-  <<Console_ExpandFile>>	<Key-Tab>
-  <<Console_ExpandProc>>	<Control-Shift-Key-P>
-  <<Console_ExpandVar>>		<Control-Shift-Key-V>
-  <<Console_Tab>>		<Control-Key-i>
-  <<Console_Eval>>		<Key-Return>
-  <<Console_Eval>>		<Key-KP_Enter>
-
-  <<Console_Clear>>		<Control-Key-l>
-  <<Console_KillLine>>		<Control-Key-k>
-  <<Console_Transpose>>		<Control-Key-t>
-  <<Console_ClearLine>>		<Control-Key-u>
-  <<Console_SaveCommand>>	<Control-Key-z>
-
-  <<Console_Exit>>	<Control-Key-q>
-  <<Console_New>>	<Control-Key-N>
-  <<Console_Close>>	<Control-Key-w>
-  <<Console_About>>	<Control-Key-A>
-  <<Console_Help>>	<Control-Key-H>
-  <<Console_Find>>	<Control-Key-F>
-} {
-  event add $ev $key
-  bind Console $key {}
-}
-catch {unset ev key}
-
-## Redefine for Console what we need
-##
-event delete <<Paste>> <Control-V>
-ConsoleClipboardKeysyms <Copy> <Cut> <Paste>
-
-bind Console <Insert> {catch {ConsoleInsert %W [selection get -displayof %W]}}
-
-bind Console <Triple-1> {+
-catch {
-  eval %W tag remove sel [%W tag nextrange prompt sel.first sel.last]
-  %W mark set insert sel.first
-}
-}
-
-bind Console <<Console_ExpandFile>> {
-  if [%W compare insert > limit] {Console:expand %W path}
-  break
-}
-bind Console <<Console_ExpandProc>> {
-  if [%W compare insert > limit] {Console:expand %W proc}
-}
-bind Console <<Console_ExpandVar>> {
-  if [%W compare insert > limit] {Console:expand %W var}
-}
-bind Console <<Console_Tab>> {
-  if [%W compare insert >= limit] {
-    ConsoleInsert %W \t
-  }
-}
-bind Console <<Console_Eval>> {
-  ConsoleEval %W
-}
-bind Console <Delete> {
-  if {[string comp {} [%W tag nextrange sel 1.0 end]] \
-      && [%W compare sel.first >= limit]} {
-    %W delete sel.first sel.last
-  } elseif {[%W compare insert >= limit]} {
-    %W delete insert
-    %W see insert
-  }
-}
-bind Console <BackSpace> {
-  if {[string comp {} [%W tag nextrange sel 1.0 end]] \
-      && [%W compare sel.first >= limit]} {
-    %W delete sel.first sel.last
-  } elseif {[%W compare insert != 1.0] && [%W compare insert > limit]} {
-    %W delete insert-1c
-    %W see insert
-  }
-}
-bind Console <Control-h> [bind Console <BackSpace>]
-
-bind Console <KeyPress> {
-  ConsoleInsert %W %A
-}
-
-bind Console <Control-a> {
-  if [%W compare {limit linestart} == {insert linestart}] {
-    tkTextSetCursor %W limit
-  } else {
-    tkTextSetCursor %W {insert linestart}
-  }
-}
-bind Console <Control-d> {
-  if [%W compare insert < limit] break
-  %W delete insert
-}
-bind Console <<Console_KillLine>> {
-  if [%W compare insert < limit] break
-  if [%W compare insert == {insert lineend}] {
-    %W delete insert
-  } else {
-    %W delete insert {insert lineend}
-  }
-}
-bind Console <<Console_Clear>> {
-  Console_clear [winfo parent %W]
-}
-bind Console <<Console_Previous>> {
-  if [%W compare {insert linestart} != {limit linestart}] {
-    tkTextSetCursor %W [tkTextUpDownLine %W -1]
-  } else {
-    Console_event [winfo parent %W] -1
-  }
-}
-bind Console <<Console_Next>> {
-  if [%W compare {insert linestart} != {end-1c linestart}] {
-    tkTextSetCursor %W [tkTextUpDownLine %W 1]
-  } else {
-    Console_event [winfo parent %W] 1
-  }
-}
-bind Console <<Console_NextImmediate>> {
-  Console_event [winfo parent %W] 1
-}
-bind Console <<Console_PreviousImmediate>> {
-  Console_event [winfo parent %W] -1
-}
-bind Console <<Console_PreviousSearch>> {
-  Console_event [winfo parent %W] -1 [ConsoleCmdGet %W]
-}
-bind Console <<Console_NextSearch>> {
-  Console_event [winfo parent %W] 1 [ConsoleCmdGet %W]
-}
-bind Console <<Console_Transpose>> {
-  ## Transpose current and previous chars
-  if [%W compare insert > limit] { tkTextTranspose %W }
-}
-bind Console <<Console_ClearLine>> {
-  ## Clear command line (Unix shell staple)
-  %W delete limit end
-}
-bind Console <<Console_SaveCommand>> {
-  ## Save command buffer (swaps with current command)
-  Console:savecommand %W
-}
-catch {bind Console <Key-Page_Up>   { tkTextScrollPages %W -1 }}
-catch {bind Console <Key-Prior>     { tkTextScrollPages %W -1 }}
-catch {bind Console <Key-Page_Down> { tkTextScrollPages %W 1 }}
-catch {bind Console <Key-Next>      { tkTextScrollPages %W 1 }}
-bind Console <$META-d> {
-  if [%W compare insert >= limit] {
-    %W delete insert {insert wordend}
-  }
-}
-bind Console <$META-BackSpace> {
-  if [%W compare {insert -1c wordstart} >= limit] {
-    %W delete {insert -1c wordstart} insert
-  }
-}
-bind Console <$META-Delete> {
-  if [%W compare insert >= limit] {
-    %W delete insert {insert wordend}
-  }
-}
-bind Console <ButtonRelease-2> {
-  if {(!$tkPriv(mouseMoved) || $tk_strictMotif) \
-      && ![catch {selection get -displayof %W} tkPriv(junk)]} {
-    if [%W compare @%x,%y < limit] {
-      %W insert end $tkPriv(junk)
-    } else {
-      %W insert @%x,%y $tkPriv(junk)
-    }
-    if [string match *\n* $tkPriv(junk)] {ConsoleEval %W}
-  }
-}
-
-##
-## End Console bindings
-##
-
-##
-## Bindings for doing special things based on certain keys
-##
-bind PostCon <Key-parenright> {
-  if [string comp \\ [%W get insert-2c]] { ConsoleMatchPair %W \( \) limit }
-}
-bind PostCon <Key-bracketright> {
-  if [string comp \\ [%W get insert-2c]] { ConsoleMatchPair %W \[ \] limit }
-}
-bind PostCon <Key-braceright> {
-  if [string comp \\ [%W get insert-2c]] { ConsoleMatchPair %W \{ \} limit }
-}
-bind PostCon <Key-quotedbl> {
-  if [string comp \\ [%W get insert-2c]] { ConsoleMatchQuote %W limit }
-}
-
-bind PostCon <KeyPress> {
-  if [string comp {} %A] { ConsoleTagProc %W }
-}
-
-
-## ConsoleTagProc - tags a procedure in the console if it's recognized
-## This procedure is not perfect.  However, making it perfect wastes
-## too much CPU time...  Also it should check the existence of a command
-## in whatever is the connected slave, not the master interpreter.
-##
-;proc ConsoleTagProc w {
-  upvar \#0 [winfo parent $w] data
-  if !$data(-lightcmd) return
-  set i [$w index "insert-1c wordstart"]
-  set j [$w index "insert-1c wordend"]
-  if {[string comp {} \
-	   [ConsoleEvalAttached info command [list [$w get $i $j]]]]} {
-    $w tag add proc $i $j
-  } else {
-    $w tag remove proc $i $j
-  }
-}
-
-## ConsoleMatchPair - blinks a matching pair of characters
-## c2 is assumed to be at the text index 'insert'.
-## This proc is really loopy and took me an hour to figure out given
-## all possible combinations with escaping except for escaped \'s.
-## It doesn't take into account possible commenting... Oh well.  If
-## anyone has something better, I'd like to see/use it.  This is really
-## only efficient for small contexts.
-# ARGS:	w	- console text widget
-# 	c1	- first char of pair
-# 	c2	- second char of pair
-# Calls:	Console:blink
-## 
-;proc ConsoleMatchPair {w c1 c2 {lim 1.0}} {
-  upvar \#0 [winfo parent $w] data
-  if {!$data(-lightbrace) || $data(-blinktime)<100} return
-  if [string comp {} [set ix [$w search -back $c1 insert $lim]]] {
-    while {[string match {\\} [$w get $ix-1c]] &&
-	   [string comp {} [set ix [$w search -back $c1 $ix-1c $lim]]]} {}
-    set i1 insert-1c
-    while {[string comp {} $ix]} {
-      set i0 $ix
-      set j 0
-      while {[string comp {} [set i0 [$w search $c2 $i0 $i1]]]} {
-	append i0 +1c
-	if {[string match {\\} [$w get $i0-2c]]} continue
-	incr j
-      }
-      if {!$j} break
-      set i1 $ix
-      while {$j && [string comp {} [set ix [$w search -back $c1 $ix $lim]]]} {
-	if {[string match {\\} [$w get $ix-1c]]} continue
-	incr j -1
-      }
-    }
-    if [string match {} $ix] { set ix [$w index $lim] }
-  } else { set ix [$w index $lim] }
-  if $data(-blinkrange) {
-    Console:blink $w $data(-blinktime) $ix [$w index insert]
-  } else {
-    Console:blink $w $data(-blinktime) $ix $ix+1c \
-	[$w index insert-1c] [$w index insert]
-  }
-}
-
-## ConsoleMatchQuote - blinks between matching quotes.
-## Blinks just the quote if it's unmatched, otherwise blinks quoted string
-## The quote to match is assumed to be at the text index 'insert'.
-# ARGS:	w	- console text widget
-# Calls:	Console:blink
-## 
-;proc ConsoleMatchQuote {w {lim 1.0}} {
-  upvar \#0 [winfo parent $w] data
-  if {!$data(-lightbrace) || $data(-blinktime)<100} return
-  set i insert-1c
-  set j 0
-  while {[string comp {} [set i [$w search -back \" $i $lim]]]} {
-    if {[string match {\\} [$w get $i-1c]]} continue
-    if {!$j} {set i0 $i}
-    incr j
-  }
-  if [expr $j%2] {
-    if $data(-blinkrange) {
-      Console:blink $w $data(-blinktime) $i0 [$w index insert]
-    } else {
-      Console:blink $w $data(-blinktime) $i0 $i0+1c \
-	  [$w index insert-1c] [$w index insert]
-    }
-  } else {
-    Console:blink $w $data(-blinktime) [$w index insert-1c] [$w index insert]
-  }
-}
-
-## Console:blink - blinks between 2 indices for a specified duration.
-# ARGS:	w	- console text widget
-#	delay	- millisecs to blink for
-# 	args	- indices of regions to blink
-# Outputs:	blinks selected characters in $w
-## 
-;proc Console:blink {w delay args} {
-  eval $w tag add blink $args
-  after $delay eval $w tag remove blink $args
-  return
-}
-
-
-## ConsoleInsert
-## Insert a string into a text console at the point of the insertion cursor.
-## If there is a selection in the text, and it covers the point of the
-## insertion cursor, then delete the selection before inserting.
-# ARGS:	w	- text window in which to insert the string
-# 	s	- string to insert (usually just a single char)
-# Outputs:	$s to text widget
-## 
-;proc ConsoleInsert {w s} {
-  if {[string match {} $s] || [string match disabled [$w cget -state]]} {
-    return
-  }
-  if [$w comp insert < limit] {
-    $w mark set insert end
-  }
-  catch {
-    if {[$w comp sel.first <= insert] && [$w comp sel.last >= insert]} {
-      $w delete sel.first sel.last
-    }
-  }
-  $w insert insert $s
-  $w see insert
-}
-
-## Console:expand - 
-# ARGS:	w	- text widget in which to expand str
-# 	type	- type of expansion (path / proc / variable)
-# Calls:	ConsoleExpand(Pathname|Procname|Variable)
-# Outputs:	The string to match is expanded to the longest possible match.
-#		If data(-showmultiple) is non-zero and the user longest match
-#		equaled the string to expand, then all possible matches are
-#		output to stdout.  Triggers bell if no matches are found.
-# Returns:	number of matches found
-## 
-;proc Console:expand {w type} {
-  set exp "\[^\\]\[ \t\n\r\[\{\"\$]"
-  set tmp [$w search -back -regexp $exp insert-1c limit-1c]
-  if [string compare {} $tmp] {append tmp +2c} else {set tmp limit}
-  if [$w compare $tmp >= insert] return
-  set str [$w get $tmp insert]
-  switch -glob $type {
-    pa* { set res [ConsoleExpandPathname $str] }
-    pr* { set res [ConsoleExpandProcname $str] }
-    v*  { set res [ConsoleExpandVariable $str] }
-    default {set res {}}
-  }
-  set len [llength $res]
-  if $len {
-    $w delete $tmp insert
-    $w insert $tmp [lindex $res 0]
-    if {$len > 1} {
-      upvar \#0 [winfo parent $w] data
-      if {$data(-showmultiple) && ![string comp [lindex $res 0] $str]} {
-	puts stdout [lreplace $res 0 0]
-      }
-    }
-  } else bell
-  return [incr len -1]
-}
-
-## ConsoleExpandPathname - expand a file pathname based on $str
-## This is based on UNIX file name conventions
-# ARGS:	str	- partial file pathname to expand
-# Calls:	ConsoleExpandBestMatch
-# Returns:	list containing longest unique match followed by all the
-#		possible further matches
-## 
-;proc ConsoleExpandPathname str {
-  set pwd [ConsoleEvalAttached pwd]
-  if [catch {ConsoleEvalAttached [list cd [file dirname $str]]} err] {
-    return -code error $err
-  }
-  if [catch {lsort [ConsoleEvalAttached glob [file tail $str]*]} m] {
-    set match {}
-  } else {
-    if {[llength $m] > 1} {
-      set tmp [ConsoleExpandBestMatch $m [file tail $str]]
-      if [string match ?*/* $str] {
-	set tmp [file dirname $str]/$tmp
-      } elseif {[string match /* $str]} {
-	set tmp /$tmp
-      }
-      regsub -all { } $tmp {\\ } tmp
-      set match [linsert $m 0 $tmp]
-    } else {
-      ## This may look goofy, but it handles spaces in path names
-      eval append match $m
-      if [file isdir $match] {append match /}
-      if [string match ?*/* $str] {
-	set match [file dirname $str]/$match
-      } elseif {[string match /* $str]} {
-	set match /$match
-      }
-      regsub -all { } $match {\\ } match
-      ## Why is this one needed and the ones below aren't!!
-      set match [list $match]
-    }
-  }
-  ConsoleEvalAttached [list cd $pwd]
-  return $match
-}
-
-## ConsoleExpandProcname - expand a tcl proc name based on $str
-# ARGS:	str	- partial proc name to expand
-# Calls:	ConsoleExpandBestMatch
-# Returns:	list containing longest unique match followed by all the
-#		possible further matches
-## 
-;proc ConsoleExpandProcname str {
-  set match [ConsoleEvalAttached info commands $str*]
-  if {[llength $match] > 1} {
-    regsub -all { } [ConsoleExpandBestMatch $match $str] {\\ } str
-    set match [linsert $match 0 $str]
-  } else {
-    regsub -all { } $match {\\ } match
-  }
-  return $match
-}
-
-## ConsoleExpandVariable - expand a tcl variable name based on $str
-# ARGS:	str	- partial tcl var name to expand
-# Calls:	ConsoleExpandBestMatch
-# Returns:	list containing longest unique match followed by all the
-#		possible further matches
-## 
-;proc ConsoleExpandVariable str {
-  if [regexp {([^\(]*)\((.*)} $str junk ary str] {
-    ## Looks like they're trying to expand an array.
-    set match [ConsoleEvalAttached array names $ary $str*]
-    if {[llength $match] > 1} {
-      set vars $ary\([ConsoleExpandBestMatch $match $str]
-      foreach var $match {lappend vars $ary\($var\)}
-      return $vars
-    } else {set match $ary\($match\)}
-    ## Space transformation avoided for array names.
-  } else {
-    set match [ConsoleEvalAttached info vars $str*]
-    if {[llength $match] > 1} {
-      regsub -all { } [ConsoleExpandBestMatch $match $str] {\\ } str
-      set match [linsert $match 0 $str]
-    } else {
-      regsub -all { } $match {\\ } match
-    }
-  }
-  return $match
-}
-
-## ConsoleExpandBestMatch2 - finds the best unique match in a list of names
-## Improves upon the speed of the below proc only when $l is small
-## or $e is {}.  $e is extra for compatibility with proc below.
-# ARGS:	l	- list to find best unique match in
-# Returns:	longest unique match in the list
-## 
-;proc ConsoleExpandBestMatch2 {l {e {}}} {
-  set s [lindex $l 0]
-  if {[llength $l]>1} {
-    set i [expr [string length $s]-1]
-    foreach l $l {
-      while {$i>=0 && [string first $s $l]} {
-	set s [string range $s 0 [incr i -1]]
-      }
-    }
-  }
-  return $s
-}
-
-## ConsoleExpandBestMatch - finds the best unique match in a list of names
-## The extra $e in this argument allows us to limit the innermost loop a
-## little further.  This improves speed as $l becomes large or $e becomes long.
-# ARGS:	l	- list to find best unique match in
-# 	e	- currently best known unique match
-# Returns:	longest unique match in the list
-## 
-;proc ConsoleExpandBestMatch {l {e {}}} {
-  set ec [lindex $l 0]
-  if {[llength $l]>1} {
-    set e  [string length $e]; incr e -1
-    set ei [string length $ec]; incr ei -1
-    foreach l $l {
-      while {$ei>=$e && [string first $ec $l]} {
-	set ec [string range $ec 0 [incr ei -1]]
-      }
-    }
-  }
-  return $ec
-}
-
-
-## ConsoleResource - re'source's this script into current console
-## Meant primarily for my development of this program.  It follows
-## links until the ultimate source is found.
-## 
-set Console(SCRIPT) [info script]
-if !$Console(WWW) {
-  while {[string match link [file type $Console(SCRIPT)]]} {
-    set link [file readlink $Console(SCRIPT)]
-    if [string match relative [file pathtype $link]] {
-      set Console(SCRIPT) [file join [file dirname $Console(SCRIPT)] $link]
-    } else {
-      set Console(SCRIPT) $link
-    }
-  }
-  catch {unset link}
-  if [string match relative [file pathtype $Console(SCRIPT)]] {
-    set Console(SCRIPT) [file join [pwd] $Console(SCRIPT)]
-  }
-}
-
-;proc Console:resource {} {
-  global Console
-  uplevel \#0 [list source $Console(SCRIPT)]
-}
-
-catch {destroy .c}
-console .c
-wm iconify .c
-wm title .c "Tcl Plugin Console"
-wm geometry .c +10+10
diff --git a/tkcon-2.5/extra/stripped.tcl b/tkcon-2.5/extra/stripped.tcl
deleted file mode 100755
index 64ef1f5..0000000
--- a/tkcon-2.5/extra/stripped.tcl
+++ /dev/null
@@ -1,1083 +0,0 @@
-#!/bin/sh
-# \
-exec wish4.1 "$0" ${1+"$@"}
-
-#
-## stripped.tcl
-## Stripped down version of Tk Console Widget, part of the VerTcl system
-## Stripped to work with Netscape Tk Plugin.
-##
-## Copyright (c) 1995,1996 by Jeffrey Hobbs
-## jhobbs at cs.uoregon.edu, http://www.cs.uoregon.edu/~jhobbs/
-## source standard_disclaimer.tcl
-
-if {[info tclversion] < 7.5} {
-  error "TkCon requires at least the stable version of tcl7.5/tk4.1"
-}
-
-## tkConInit - inits tkCon
-# ARGS:	root	- widget pathname of the tkCon console root
-#	title	- title for the console root and main (.) windows
-# Calls:	tkConInitUI
-# Outputs:	errors found in tkCon resource file
-##
-proc tkConInit {{title Main}} {
-  global tkCon tcl_platform env auto_path tcl_interactive
-
-  set tcl_interactive 1
-
-  array set tkCon {
-    color,blink		yellow
-    color,proc		darkgreen
-    color,prompt	brown
-    color,stdin		black
-    color,stdout	blue
-    color,stderr	red
-
-    blinktime		500
-    font		fixed
-    lightbrace		1
-    lightcmd		1
-    prompt1		{[history nextid] % }
-    prompt2		{[history nextid] cont > }
-    showmultiple	1
-    slavescript		{}
-
-    cmd {} cmdbuf {} cmdsave {} event 1 svnt 1 cols 80 rows 24
-
-    version	{0.5x Stripped}
-    base	.console
-  }
-
-  if [string comp $tcl_platform(platform) unix] {
-    array set tkCon {
-      font	{Courier 12 {}}
-    }
-  }
-
-  tkConInitUI $title
-
-  interp alias {} clean {} tkConStateRevert tkCon
-  tkConStateCheckpoint tkCon
-}
-
-## tkConInitUI - inits UI portion (console) of tkCon
-## Creates all elements of the console window and sets up the text tags
-# ARGS:	title	- title for the console root and main (.) windows
-# Calls:	tkConInitMenus, tkConPrompt
-##
-proc tkConInitUI {title} {
-  global tkCon
-
-  set root $tkCon(base)
-  if [string match $root .] { set w {} } else { set w [frame $root] }
-
-  set tkCon(console) [text $w.text -font $tkCon(font) -wrap char \
-      -yscrollcommand "$w.sy set" -setgrid 1 -foreground $tkCon(color,stdin)]
-  bindtags $w.text "$w.text PreCon Console PostCon $root all"
-  set tkCon(scrolly) [scrollbar $w.sy \
-      -command "$w.text yview" -takefocus 0 -bd 1]
-
-  pack $w.sy -side left -fill y
-  set tkCon(scrollypos) left
-  pack $w.text -fill both -expand 1
-
-  $w.text insert insert "$title console display active\n" stdout
-  tkConPrompt $w.text
-
-  foreach col {prompt stdout stderr stdin proc} {
-    $w.text tag configure $col -foreground $tkCon(color,$col)
-  }
-  $w.text tag configure blink -background $tkCon(color,blink)
-
-  pack $root -fill both -expand 1
-  focus $w.text
-}
-
-## tkConEval - evaluates commands input into console window
-## This is the first stage of the evaluating commands in the console.
-## They need to be broken up into consituent commands (by tkConCmdSep) in
-## case a multiple commands were pasted in, then each is eval'ed (by
-## tkConEvalCmd) in turn.  Any uncompleted command will not be eval'ed.
-# ARGS:	w	- console text widget
-# Calls:	tkConCmdGet, tkConCmdSep, tkConEvalCmd
-## 
-proc tkConEval {w} {
-  global tkCon
-  tkConCmdSep [tkConCmdGet $w] cmds tkCon(cmd)
-  $w mark set insert end-1c
-  $w insert end \n
-  if [llength $cmds] {
-    foreach cmd $cmds {tkConEvalCmd $w $cmd}
-    $w insert insert $tkCon(cmd) {}
-  } elseif {[info complete $tkCon(cmd)] && ![regexp {[^\\]\\$} $tkCon(cmd)]} {
-    tkConEvalCmd $w $tkCon(cmd)
-  }
-  $w see insert
-}
-
-## tkConEvalCmd - evaluates a single command, adding it to history
-# ARGS:	w	- console text widget
-# 	cmd	- the command to evaluate
-# Calls:	tkConPrompt
-# Outputs:	result of command to stdout (or stderr if error occured)
-# Returns:	next event number
-## 
-proc tkConEvalCmd {w cmd} {
-  global tkCon
-  $w mark set output end
-  if [catch {uplevel \#0 history add [list $cmd] exec} result] {
-    $w insert output $result\n stderr
-  } elseif [string comp {} $result] {
-    $w insert output $result\n stdout
-  }
-  tkConPrompt $w
-  set tkCon(svnt) [set tkCon(event) [history nextid]]
-}
-
-## tkConCmdGet - gets the current command from the console widget
-# ARGS:	w	- console text widget
-# Returns:	text which compromises current command line
-## 
-proc tkConCmdGet w {
-  if [string match {} [set ix [$w tag nextrange prompt limit end]]] {
-    $w tag add stdin limit end-1c
-    return [$w get limit end-1c]
-  }
-}
-
-## tkConCmdSep - separates multiple commands into a list and remainder
-# ARGS:	cmd	- (possible) multiple command to separate
-# 	list	- varname for the list of commands that were separated.
-#	rmd	- varname of any remainder (like an incomplete final command).
-#		If there is only one command, it's placed in this var.
-# Returns:	constituent command info in varnames specified by list & rmd.
-## 
-proc tkConCmdSep {cmd ls rmd} {
-  upvar $ls cmds $rmd tmp
-  set tmp {}
-  set cmds {}
-  foreach cmd [split [set cmd] \n] {
-    if [string comp {} $tmp] {
-      append tmp \n$cmd
-    } else {
-      append tmp $cmd
-    }
-    if {[info complete $tmp] && ![regexp {[^\\]\\$} $tmp]} {
-      lappend cmds $tmp
-      set tmp {}
-    }
-  }
-  if {[string comp {} [lindex $cmds end]] && [string match {} $tmp]} {
-    set tmp [lindex $cmds end]
-    set cmds [lreplace $cmds end end]
-  }
-}
-
-## tkConPrompt - displays the prompt in the console widget
-# ARGS:	w	- console text widget
-# Outputs:	prompt (specified in tkCon(prompt1)) to console
-## 
-proc tkConPrompt w {
-  global tkCon env
-  set i [$w index end-1c]
-  $w insert end [subst $tkCon(prompt1)] prompt
-  $w mark set output $i
-  $w mark set limit insert
-  $w mark gravity limit left
-}
-
-## tkConStateCheckpoint - checkpoints the current state of the system
-## This allows you to return to this state with tkConStateRevert
-# ARGS:	ary	an array into which several elements are stored:
-#			commands  - the currently defined commands
-#			variables - the current global vars
-#		This is the array you would pass to tkConRevertState
-##
-proc tkConStateCheckpoint {ary} {
-  global tkCon
-  upvar $ary a
-  set a(commands)  [uplevel \#0 info commands *]
-  set a(variables) [uplevel \#0 info vars *]
-  return
-}
-
-## tkConStateCompare - compare two states and output difference
-# ARGS:	ary1	an array with checkpointed state
-#	ary2	a second array with checkpointed state
-# Outputs:
-##
-proc tkConStateCompare {ary1 ary2} {
-  upvar $ary1 a1 $ary2 a2
-  puts "Commands unique to $ary1:\n[lremove $a1(commands) $a2(commands)]"
-  puts "Commands unique to $ary2:\n[lremove $a2(commands) $a1(commands)]"
-  puts "Variables unique to $ary1:\n[lremove $a1(variables) $a2(variables)]"
-  puts "Variables unique to $ary2:\n[lremove $a2(variables) $a1(variables)]"
-}
-
-## tkConStateRevert - reverts interpreter to a previous state
-# ARGS:	ary	an array with checkpointed state
-##
-proc tkConStateRevert {ary} {
-  upvar $ary a
-  tkConStateCheckpoint tmp
-  foreach i [lremove $tmp(commands) $a(commands)] { catch "rename $i {}" }
-  foreach i [lremove $tmp(variables) $a(variables)] { uplevel \#0 unset $i }
-}
-
-##
-## Some procedures to make up for lack of built-in shell commands
-##
-
-## puts
-## This allows me to capture all stdout/stderr to the console window
-# ARGS:	same as usual	
-# Outputs:	the string with a color-coded text tag
-## 
-catch {rename puts tcl_puts}
-proc puts args {
-  set len [llength $args]
-  if {$len==1} {
-    eval tkcon console insert output $args stdout {\n} stdout
-    tkcon console see output
-  } elseif {$len==2 &&
-    [regexp {(stdout|stderr|-nonewline)} [lindex $args 0] junk tmp]} {
-    if [string comp $tmp -nonewline] {
-      eval tkcon console insert output [lreplace $args 0 0] $tmp {\n} $tmp
-    } else {
-      eval tkcon console insert output [lreplace $args 0 0] stdout
-    }
-    tkcon console see output
-  } elseif {$len==3 &&
-    [regexp {(stdout|stderr)} [lreplace $args 2 2] junk tmp]} {
-    if [string comp [lreplace $args 1 2] -nonewline] {
-      eval tkcon console insert output [lrange $args 1 1] $tmp
-    } else {
-      eval tkcon console insert output [lreplace $args 0 1] $tmp
-    }
-    tkcon console see output
-  } else {
-    eval tcl_puts $args
-  }
-}
-
-## alias - akin to the csh alias command
-## If called with no args, then it prints out all current aliases
-## If called with one arg, returns the alias of that arg (or {} if none)
-# ARGS:	newcmd	- (optional) command to bind alias to
-# 	args	- command and args being aliased
-## 
-proc alias {{newcmd {}} args} {
-  if [string match $newcmd {}] {
-    set res {}
-    foreach a [interp aliases] {
-      lappend res [list $a: [interp alias {} $a]]
-    }
-    return [join $res \n]
-  } elseif {[string match {} $args]} {
-    interp alias {} $newcmd
-  } else {
-    eval interp alias {{}} $newcmd {{}} $args
-  }
-}
-
-## unalias - unaliases an alias'ed command
-# ARGS:	cmd	- command to unbind as an alias
-## 
-proc unalias {cmd} {
-  interp alias {} $cmd {}
-}
-
-## tkcon - command that allows control over the console
-# ARGS:	totally variable, see internal comments
-## 
-proc tkcon {args} {
-  global tkCon
-  switch -- [lindex $args 0] {
-    clean {
-      ## 'cleans' the interpreter - reverting to original tkCon state
-      tkConStateRevert tkCon
-    }
-    console {
-      ## Passes the args to the text widget of the console.
-      eval $tkCon(console) [lreplace $args 0 0]
-    }
-    font {
-      ## "tkcon font ?fontname?".  Sets the font of the console
-      if [string comp {} [lindex $args 1]] {
-	return [$tkCon(console) config -font [lindex $args 1]]
-      } else {
-	return [$tkCon(console) config -font]
-      }
-    }
-    version {
-      return $tkCon(version)
-    }
-    default {
-      ## tries to determine if the command exists, otherwise throws error
-      set cmd [lindex $args 0]
-      set cmd tkCon[string toup [string index $cmd 0]][string range $cmd 1 end]
-      if [string match $cmd [info command $cmd]] {
-	eval $cmd [lreplace $args 0 0]
-      } else {
-	error "bad option \"[lindex $args 0]\": must be attach,\
-		clean, console, font"
-      }
-    }
-  }
-}
-
-## clear - clears the buffer of the console (not the history though)
-## This is executed in the parent interpreter
-## 
-proc clear {{pcnt 100}} {
-  if {![regexp {^[0-9]*$} $pcnt] || $pcnt < 1 || $pcnt > 100} {
-    error "invalid percentage to clear: must be 1-100 (100 default)"
-  } elseif {$pcnt == 100} {
-    tkcon console delete 1.0 end
-  } else {
-    set tmp [expr $pcnt/100.0*[tkcon console index end]]
-    tkcon console delete 1.0 "$tmp linestart"
-  }
-}
-
-## dump - outputs variables/procedure/widget info in source'able form.
-## Accepts glob style pattern matching for the names
-# ARGS:	type	- type of thing to dump: must be variable, procedure, widget
-# OPTS: -nocomplain	don't complain if no vars match something
-# Returns:	the values of the variables in a 'source'able form
-## 
-proc dump {type args} {
-  set whine 1
-  set code ok
-  if [string match \-n* [lindex $args 0]] {
-    set whine 0
-    set args [lreplace $args 0 0]
-  }
-  if {$whine && [string match {} $args]} {
-    error "wrong \# args: [lindex [info level 0] 0] ?-nocomplain? pattern ?pattern ...?"
-  }
-  set res {}
-  switch -glob -- $type {
-    v* {
-      # variable
-      # outputs variables value(s), whether array or simple.
-      foreach arg $args {
-	if {[string match {} [set vars [uplevel info vars [list $arg]]]]} {
-	  if {[uplevel info exists $arg]} {
-	    set vars $arg
-	  } elseif $whine {
-	    append res "\#\# No known variable $arg\n"
-	    set code error
-	    continue
-	  } else continue
-	}
-	foreach var [lsort $vars] {
-	  upvar $var v
-	  if {[array exists v]} {
-	    append res "array set $var \{\n"
-	    foreach i [lsort [array names v]] {
-	      upvar 0 v\($i\) w
-	      if {[array exists w]} {
-		append res "    [list $i {NESTED VAR ERROR}]\n"
-		if $whine { set code error }
-	      } else {
-		append res "    [list $i $v($i)]\n"
-	      }
-	    }
-	    append res "\}\n"
-	  } else {
-	    append res [list set $var $v]\n
-	  }
-	}
-      }
-    }
-    p* {
-      # procedure
-      foreach arg $args {
-	if {[string comp {} [set ps [info proc $arg]]]} {
-	  foreach p [lsort $ps] {
-	    set as {}
-	    foreach a [info args $p] {
-	      if {[info default $p $a tmp]} {
-		lappend as [list $a $tmp]
-	      } else {
-		lappend as $a
-	      }
-	    }
-	    append res [list proc $p $as [info body $p]]\n
-	  }
-	} elseif $whine {
-	  append res "\#\# No known proc $arg\n"
-	}
-      }
-    }
-    w* {
-      # widget
-    }
-    default {
-      return -code error "bad [lindex [info level 0] 0] option\
-	\"[lindex $args 0]\":\ must be procedure, variable, widget"
-    }
-  }
-  return -code $code [string trimr $res \n]
-}
-
-## which - tells you where a command is found
-# ARGS:	cmd	- command name
-# Returns:	where command is found (internal / external / unknown)
-## 
-proc which cmd {
-  if [string comp {} [info commands $cmd]] {
-    if {[lsearch -exact [interp aliases] $cmd] > -1} {
-      return "$cmd:\taliased to [alias $cmd]"
-    } elseif [string comp {} [info procs $cmd]] {
-      return "$cmd:\tinternal proc"
-    } else {
-      return "$cmd:\tinternal command"
-    }
-  } else {
-    return "$cmd:\tunknown command"
-  }
-}
-
-## lremove - remove items from a list
-# OPTS:	-all	remove all instances of each item
-# ARGS:	l	a list to remove items from
-#	is	a list of items to remove
-##
-proc lremove {args} {
-  set all 0
-  if [string match \-a* [lindex $args 0]] {
-    set all 1
-    set args [lreplace $args 0 0]
-  }
-  set l [lindex $args 0]
-  eval append is [lreplace $args 0 0]
-  foreach i $is {
-    if {[set ix [lsearch -exact $l $i]] == -1} continue
-    set l [lreplace $l $ix $ix]
-    if $all {
-      while {[set ix [lsearch -exact $l $i]] != -1} {
-	set l [lreplace $l $i $i]
-      }
-    }
-  }
-  return $l
-}
-
-
-## Unknown changed to get output into tkCon window
-## See $tcl_library/init.tcl for an explanation
-##
-proc unknown args {
-  global auto_noexec auto_noload env unknown_pending tcl_interactive tkCon
-  global errorCode errorInfo
-
-  # Save the values of errorCode and errorInfo variables, since they
-  # may get modified if caught errors occur below.  The variables will
-  # be restored just before re-executing the missing command.
-
-  set savedErrorCode $errorCode
-  set savedErrorInfo $errorInfo
-  set name [lindex $args 0]
-  if ![info exists auto_noload] {
-    #
-    # Make sure we're not trying to load the same proc twice.
-    #
-    if [info exists unknown_pending($name)] {
-      unset unknown_pending($name)
-      if {[array size unknown_pending] == 0} {
-	unset unknown_pending
-      }
-      return -code error "self-referential recursion in \"unknown\" for command \"$name\"";
-    }
-    set unknown_pending($name) pending;
-    set ret [catch {auto_load $name} msg]
-    unset unknown_pending($name);
-    if {$ret != 0} {
-      return -code $ret -errorcode $errorCode \
-	  "error while autoloading \"$name\": $msg"
-    }
-    if ![array size unknown_pending] {
-      unset unknown_pending
-    }
-    if $msg {
-      set errorCode $savedErrorCode
-      set errorInfo $savedErrorInfo
-      set code [catch {uplevel $args} msg]
-      if {$code ==  1} {
-	#
-	# Strip the last five lines off the error stack (they're
-	# from the "uplevel" command).
-	#
-
-	set new [split $errorInfo \n]
-	set new [join [lrange $new 0 [expr [llength $new] - 6]] \n]
-	return -code error -errorcode $errorCode \
-	    -errorinfo $new $msg
-      } else {
-	return -code $code $msg
-      }
-    }
-  }
-  if {[info level] == 1 && [string match {} [info script]] \
-	  && [info exists tcl_interactive] && $tcl_interactive} {
-    if ![info exists auto_noexec] {
-      if [auto_execok $name] {
-	set errorCode $savedErrorCode
-	set errorInfo $savedErrorInfo
-	return [uplevel exec $args]
-	#return [uplevel exec >&@stdout <@stdin $args]
-      }
-    }
-    set errorCode $savedErrorCode
-    set errorInfo $savedErrorInfo
-    if {[string match $name !!]} {
-      catch {set tkCon(cmd) [history event]}
-      return [uplevel {history redo}]
-    } elseif [regexp {^!(.+)$} $name dummy event] {
-      catch {set tkCon(cmd) [history event $event]}
-      return [uplevel [list history redo $event]]
-    } elseif [regexp {^\^([^^]*)\^([^^]*)\^?$} $name dummy old new] {
-      catch {set tkCon(cmd) [history substitute $old $new]}
-      return [uplevel [list history substitute $old $new]]
-    }
-    set cmds [info commands $name*]
-    if {[llength $cmds] == 1} {
-      return [uplevel [lreplace $args 0 0 $cmds]]
-    } elseif {[llength $cmds]} {
-      if {$name == ""} {
-	return -code error "empty command name \"\""
-      } else {
-	return -code error \
-	    "ambiguous command name \"$name\": [lsort $cmds]"
-      }
-    }
-  }
-  return -code error "invalid command name \"$name\""
-}
-
-
-# tkConClipboardKeysyms --
-# This procedure is invoked to identify the keys that correspond to
-# the "copy", "cut", and "paste" functions for the clipboard.
-#
-# Arguments:
-# copy -	Name of the key (keysym name plus modifiers, if any,
-#		such as "Meta-y") used for the copy operation.
-# cut -		Name of the key used for the cut operation.
-# paste -	Name of the key used for the paste operation.
-
-proc tkConCut w {
-  if [string match $w [selection own -displayof $w]] {
-    clipboard clear -displayof $w
-    catch {
-      clipboard append -displayof $w [selection get -displayof $w]
-      if [$w compare sel.first >= limit] {$w delete sel.first sel.last}
-    }
-  }
-}
-proc tkConCopy w {
-  if [string match $w [selection own -displayof $w]] {
-    clipboard clear -displayof $w
-    catch {clipboard append -displayof $w [selection get -displayof $w]}
-  }
-}
-
-proc tkConPaste w {
-  if ![catch {selection get -displayof $w -selection CLIPBOARD} tmp] {
-    if [$w compare insert < limit] {$w mark set insert end}
-    $w insert insert $tmp
-    $w see insert
-    if [string match *\n* $tmp] {tkConEval $w}
-  }
-}
-
-proc tkConClipboardKeysyms {copy cut paste} {
-  bind Console <$copy>	{tkConCopy %W}
-  bind Console <$cut>	{tkConCut %W}
-  bind Console <$paste>	{tkConPaste %W}
-}
-
-## Get all Text bindings into Console
-##
-foreach ev [lremove [bind Text] {<Control-Key-y> <Control-Key-w> \
-				     <Meta-Key-w> <Control-Key-o>}] {
-  bind Console $ev [bind Text $ev]
-}
-unset ev
-
-## Redefine for Console what we need
-##
-tkConClipboardKeysyms F16 F20 F18
-tkConClipboardKeysyms Control-c Control-x Control-v
-
-bind Console <Insert> {catch {tkConInsert %W [selection get -displayof %W]}}
-
-bind Console <Up> {
-  if [%W compare {insert linestart} != {limit linestart}] {
-    tkTextSetCursor %W [tkTextUpDownLine %W -1]
-  } else {
-    if {$tkCon(event) == [history nextid]} {
-      set tkCon(cmdbuf) [tkConCmdGet %W]
-    }
-    if [catch {history event [incr tkCon(event) -1]} tkCon(tmp)] {
-      incr tkCon(event)
-    } else {
-      %W delete limit end
-      %W insert limit $tkCon(tmp)
-      %W see end
-    }
-  }
-}
-bind Console <Down> {
-  if [%W compare {insert linestart} != {end-1c linestart}] {
-    tkTextSetCursor %W [tkTextUpDownLine %W 1]
-  } else {
-    if {$tkCon(event) < [history nextid]} {
-      %W delete limit end
-      if {[incr tkCon(event)] == [history nextid]} {
-	%W insert limit $tkCon(cmdbuf)
-      } else {
-	%W insert limit [history event $tkCon(event)]
-      }
-      %W see end
-    }
-  }
-}
-bind Console <Control-P> {
-  if [%W compare insert > limit] {tkConExpand %W proc}
-}
-bind Console <Control-V> {
-  if [%W compare insert > limit] {tkConExpand %W var}
-}
-bind Console <Control-i> {
-  if [%W compare insert >= limit] {
-    tkConInsert %W \t
-  }
-}
-bind Console <Return> {
-  tkConEval %W
-}
-bind Console <KP_Enter> [bind Console <Return>]
-bind Console <Delete> {
-  if {[string comp {} [%W tag nextrange sel 1.0 end]] \
-	  && [%W compare sel.first >= limit]} {
-    %W delete sel.first sel.last
-  } elseif [%W compare insert >= limit] {
-    %W delete insert
-    %W see insert
-  }
-}
-bind Console <BackSpace> {
-  if {[string comp {} [%W tag nextrange sel 1.0 end]] \
-	  && [%W compare sel.first >= limit]} {
-    %W delete sel.first sel.last
-  } elseif {[%W compare insert != 1.0] && [%W compare insert-1c >= limit]} {
-    %W delete insert-1c
-    %W see insert
-  }
-}
-bind Console <Control-h> [bind Console <BackSpace>]
-
-bind Console <KeyPress> {
-  tkConInsert %W %A
-}
-
-bind Console <Control-a> {
-  if [%W compare {limit linestart} == {insert linestart}] {
-    tkTextSetCursor %W limit
-  } else {
-    tkTextSetCursor %W {insert linestart}
-  }
-}
-bind Console <Control-d> {
-  if [%W compare insert < limit] break
-  %W delete insert
-}
-bind Console <Control-k> {
-  if [%W compare insert < limit] break
-  if [%W compare insert == {insert lineend}] {
-    %W delete insert
-  } else {
-    %W delete insert {insert lineend}
-  }
-}
-bind Console <Control-l> {
-  ## Clear console buffer, without losing current command line input
-  set tkCon(tmp) [tkConCmdGet %W]
-  clear
-  tkConPrompt
-  tkConInsert %W $tkCon(tmp)
-}
-bind Console <Control-n> {
-  ## Goto next command in history
-  if {$tkCon(event) < [history nextid]} {
-    %W delete limit end
-    if {[incr tkCon(event)] == [history nextid]} {
-      %W insert limit $tkCon(cmdbuf)
-    } else {
-      %W insert limit [history event $tkCon(event)]
-    }
-    %W see end
-  }
-}
-bind Console <Control-p> {
-  ## Goto previous command in history
-  if {$tkCon(event) == [history nextid]} {
-    set tkCon(cmdbuf) [tkConCmdGet %W]
-  }
-  if [catch {history event [incr tkCon(event) -1]} tkCon(tmp)] {
-    incr tkCon(event)
-  } else {
-    %W delete limit end
-    %W insert limit $tkCon(tmp)
-    %W see end
-  }
-}
-bind Console <Control-r> {
-  ## Search history reverse
-  if {$tkCon(svnt) == [history nextid]} {
-    set tkCon(cmdbuf) [tkConCmdGet %W]
-  }
-  set tkCon(tmp1) [string len $tkCon(cmdbuf)]
-  incr tkCon(tmp1) -1
-  while 1 {
-    if {[catch {history event [incr tkCon(svnt) -1]} tkCon(tmp)]} {
-      incr tkCon(svnt)
-      break
-    } elseif {![string comp $tkCon(cmdbuf) \
-	[string range $tkCon(tmp) 0 $tkCon(tmp1)]]} {
-      %W delete limit end
-      %W insert limit $tkCon(tmp)
-      break
-    }
-  }
-  %W see end
-}
-bind Console <Control-s> {
-  ## Search history forward
-  set tkCon(tmp1) [string len $tkCon(cmdbuf)]
-  incr tkCon(tmp1) -1
-  while {$tkCon(svnt) < [history nextid]} {
-    if {[incr tkCon(svnt)] == [history nextid]} {
-      %W delete limit end
-      %W insert limit $tkCon(cmdbuf)
-      break
-    } elseif {![catch {history event $tkCon(svnt)} tkCon(tmp)]
-	      && ![string comp $tkCon(cmdbuf) \
-		       [string range $tkCon(tmp) 0 $tkCon(tmp1)]]} {
-      %W delete limit end
-      %W insert limit $tkCon(tmp)
-      break
-    }
-  }
-  %W see end
-}
-bind Console <Control-t> {
-  ## Transpose current and previous chars
-  if [%W compare insert > limit] {
-    tkTextTranspose %W
-  }
-}
-bind Console <Control-u> {
-  ## Clear command line (Unix shell staple)
-  %W delete limit end
-}
-bind Console <Control-z> {
-  ## Save command buffer
-  set tkCon(tmp) $tkCon(cmdsave)
-  set tkCon(cmdsave) [tkConCmdGet %W]
-  if {[string match {} $tkCon(cmdsave)]} {
-    set tkCon(cmdsave) $tkCon(tmp)
-  } else {
-    %W delete limit end-1c
-  }
-  tkConInsert %W $tkCon(tmp)
-  %W see end
-}
-catch {bind Console <Key-Page_Up>   { tkTextScrollPages %W -1 }}
-catch {bind Console <Key-Prior>     { tkTextScrollPages %W -1 }}
-catch {bind Console <Key-Page_Down> { tkTextScrollPages %W 1 }}
-catch {bind Console <Key-Next>      { tkTextScrollPages %W 1 }}
-bind Console <Meta-d> {
-  if [%W compare insert >= limit] {
-    %W delete insert {insert wordend}
-  }
-}
-bind Console <Meta-BackSpace> {
-  if [%W compare {insert -1c wordstart} >= limit] {
-    %W delete {insert -1c wordstart} insert
-  }
-}
-bind Console <Meta-Delete> {
-  if [%W compare insert >= limit] {
-    %W delete insert {insert wordend}
-  }
-}
-bind Console <ButtonRelease-2> {
-  if {(!$tkPriv(mouseMoved) || $tk_strictMotif) \
-	  && ![catch {selection get -displayof %W} tkCon(tmp)]} {
-    if [%W compare @%x,%y < limit] {
-      %W insert end $tkCon(tmp)
-    } else {
-      %W insert @%x,%y $tkCon(tmp)
-    }
-    if [string match *\n* $tkCon(tmp)] {tkConEval %W}
-  }
-}
-
-##
-## End weird bindings
-##
-
-##
-## PostCon bindings, for doing special things based on certain keys
-##
-bind PostCon <Key-parenright> {
-  if {$tkCon(lightbrace) && $tkCon(blinktime)>99 &&
-      [string comp \\ [%W get insert-2c]]} {
-    tkConMatchPair %W \( \)
-  }
-}
-bind PostCon <Key-bracketright> {
-  if {$tkCon(lightbrace) && $tkCon(blinktime)>99 &&
-      [string comp \\ [%W get insert-2c]]} {
-    tkConMatchPair %W \[ \]
-  }
-}
-bind PostCon <Key-braceright> {
-  if {$tkCon(lightbrace) && $tkCon(blinktime)>99 &&
-      [string comp \\ [%W get insert-2c]]} {
-    tkConMatchPair %W \{ \}
-  }
-}
-bind PostCon <Key-quotedbl> {
-  if {$tkCon(lightbrace) && $tkCon(blinktime)>99 &&
-      [string comp \\ [%W get insert-2c]]} {
-    tkConMatchQuote %W
-  }
-}
-
-bind PostCon <KeyPress> {
-  if {$tkCon(lightcmd) && [string comp {} %A]} { tkConTagProc %W }
-}
-
-## tkConTagProc - tags a procedure in the console if it's recognized
-## This procedure is not perfect.  However, making it perfect wastes
-## too much CPU time...  Also it should check the existence of a command
-## in whatever is the connected slave, not the master interpreter.
-##
-proc tkConTagProc w {
-  set i [$w index "insert-1c wordstart"]
-  set j [$w index "insert-1c wordend"]
-  if {[string comp {} [info command [list [$w get $i $j]]]]} {
-    $w tag add proc $i $j
-  } else {
-    $w tag remove proc $i $j
-  }
-}
-
-
-## tkConMatchPair - blinks a matching pair of characters
-## c2 is assumed to be at the text index 'insert'.
-## This proc is really loopy and took me an hour to figure out given
-## all possible combinations with escaping except for escaped \'s.
-## It doesn't take into account possible commenting... Oh well.  If
-## anyone has something better, I'd like to see/use it.  This is really
-## only efficient for small contexts.
-# ARGS:	w	- console text widget
-# 	c1	- first char of pair
-# 	c2	- second char of pair
-# Calls:	tkConBlink
-## 
-proc tkConMatchPair {w c1 c2} {
-  if [string comp {} [set ix [$w search -back $c1 insert limit]]] {
-    while {[string match {\\} [$w get $ix-1c]] &&
-	   [string comp {} [set ix [$w search -back $c1 $ix-1c limit]]]} {}
-    set i1 insert-1c
-    while {[string comp {} $ix]} {
-      set i0 $ix
-      set j 0
-      while {[string comp {} [set i0 [$w search $c2 $i0 $i1]]]} {
-	append i0 +1c
-	if {[string match {\\} [$w get $i0-2c]]} continue
-	incr j
-      }
-      if {!$j} break
-      set i1 $ix
-      while {$j &&
-	     [string comp {} [set ix [$w search -back $c1 $ix limit]]]} {
-	if {[string match {\\} [$w get $ix-1c]]} continue
-	incr j -1
-      }
-    }
-    if [string match {} $ix] { set ix [$w index limit] }
-  } else { set ix [$w index limit] }
-  tkConBlink $w $ix [$w index insert]
-}
-
-## tkConMatchQuote - blinks between matching quotes.
-## Blinks just the quote if it's unmatched, otherwise blinks quoted string
-## The quote to match is assumed to be at the text index 'insert'.
-# ARGS:	w	- console text widget
-# Calls:	tkConBlink
-## 
-proc tkConMatchQuote w {
-  set i insert-1c
-  set j 0
-  while {[string comp {} [set i [$w search -back \" $i limit]]]} {
-    if {[string match {\\} [$w get $i-1c]]} continue
-    if {!$j} {set i0 $i}
-    incr j
-  }
-  if [expr $j%2] {
-    tkConBlink $w $i0 [$w index insert]
-  } else {
-    tkConBlink $w [$w index insert-1c] [$w index insert]
-  }
-}
-
-## tkConBlink - blinks between 2 indices for a specified duration.
-# ARGS:	w	- console text widget
-# 	i1	- start index to blink region
-# 	i2	- end index of blink region
-# 	dur	- duration in usecs to blink for
-# Outputs:	blinks selected characters in $w
-## 
-proc tkConBlink {w i1 i2} {
-  global tkCon
-  $w tag add blink $i1 $i2
-  after $tkCon(blinktime) $w tag remove blink $i1 $i2
-  return
-}
-
-
-## tkConInsert
-## Insert a string into a text at the point of the insertion cursor.
-## If there is a selection in the text, and it covers the point of the
-## insertion cursor, then delete the selection before inserting.
-# ARGS:	w	- text window in which to insert the string
-# 	s	- string to insert (usually just a single char)
-# Outputs:	$s to text widget
-## 
-proc tkConInsert {w s} {
-  if {[string match {} $s] || [string match disabled [$w cget -state]]} {
-    return
-  }
-  if [$w comp insert < limit] {
-    $w mark set insert end
-  }
-  catch {
-    if {[$w comp sel.first <= insert] && [$w comp sel.last >= insert]} {
-      $w delete sel.first sel.last
-    }
-  }
-  $w insert insert $s
-  $w see insert
-}
-
-## tkConExpand - 
-# ARGS:	w	- text widget in which to expand str
-# 	type	- type of expansion (path / proc / variable)
-# Calls:	tkConExpand(Pathname|Procname|Variable)
-# Outputs:	The string to match is expanded to the longest possible match.
-#		If tkCon(showmultiple) is non-zero and the user longest match
-#		equaled the string to expand, then all possible matches are
-#		output to stdout.  Triggers bell if no matches are found.
-# Returns:	number of matches found
-## 
-proc tkConExpand {w type} {
-  set exp "\[^\\]\[ \t\n\r\[\{\"\$]"
-  set tmp [$w search -back -regexp $exp insert-1c limit-1c]
-  if [string compare {} $tmp] {append tmp +2c} else {set tmp limit}
-  if [$w compare $tmp >= insert] return
-  set str [$w get $tmp insert]
-  switch -glob $type {
-    pr* {set res [tkConExpandProcname $str]}
-    v*  {set res [tkConExpandVariable $str]}
-    default {set res {}}
-  }
-  set len [llength $res]
-  if $len {
-    $w delete $tmp insert
-    $w insert $tmp [lindex $res 0]
-    if {$len > 1} {
-      global tkCon
-      if {$tkCon(showmultiple) && [string match [lindex $res 0] $str]} {
-	puts stdout [lreplace $res 0 0]
-      }
-    }
-  }
-  return [incr len -1]
-}
-
-## tkConExpandProcname - expand a tcl proc name based on $str
-# ARGS:	str	- partial proc name to expand
-# Calls:	tkConExpandBestMatch
-# Returns:	list containing longest unique match followed by all the
-#		possible further matches
-## 
-proc tkConExpandProcname str {
-  set match [info commands $str*]
-  if {[llength $match] > 1} {
-    regsub -all { } [tkConExpandBestMatch $match $str] {\\ } str
-    set match [linsert $match 0 $str]
-  } else {
-    regsub -all { } $match {\\ } match
-  }
-  return $match
-}
-
-## tkConExpandVariable - expand a tcl variable name based on $str
-# ARGS:	str	- partial tcl var name to expand
-# Calls:	tkConExpandBestMatch
-# Returns:	list containing longest unique match followed by all the
-#		possible further matches
-## 
-proc tkConExpandVariable str {
-  if [regexp {([^\(]*)\((.*)} $str junk ary str] {
-    set match [uplevel \#0 array names $ary $str*]
-    if {[llength $match] > 1} {
-      set vars $ary\([tkConExpandBestMatch $match $str]
-      foreach var $match {lappend vars $ary\($var\)}
-      return $vars
-    } else {set match $ary\($match\)}
-  } else {
-    set match [uplevel \#0 info vars $str*]
-    if {[llength $match] > 1} {
-      regsub -all { } [tkConExpandBestMatch $match $str] {\\ } str
-      set match [linsert $match 0 $str]
-    } else {
-      regsub -all { } $match {\\ } match
-    }
-  }
-  return $match
-}
-
-## tkConExpandBestMatch - finds the best unique match in a list of names
-## The extra $e in this argument allows us to limit the innermost loop a
-## little further.  This improves speed as $l becomes large or $e becomes long.
-# ARGS:	l	- list to find best unique match in
-# 	e	- currently best known unique match
-# Returns:	longest unique match in the list
-## 
-proc tkConExpandBestMatch {l {e {}}} {
-  set ec [lindex $l 0]
-  if {[llength $l]>1} {
-    set e  [string length $e]; incr e -1
-    set ei [string length $ec]; incr ei -1
-    foreach l $l {
-      while {$ei>=$e && [string first $ec $l]} {
-	set ec [string range $ec 0 [incr ei -1]]
-      }
-    }
-  }
-  return $ec
-}
-
-
-## Initialize only if we haven't yet
-##
-if [catch {winfo exists $tkCon(base)}] tkConInit
diff --git a/tkcon-2.5/index.html b/tkcon-2.5/index.html
deleted file mode 100755
index 247b4c2..0000000
--- a/tkcon-2.5/index.html
+++ /dev/null
@@ -1,73 +0,0 @@
-<HTML>
-<HEAD>
-<TITLE>Enhanced Tk Console: tkcon</TITLE>
-<LINK REL="STYLESHEET" TYPE="text/css" HREF="docs/style.css">
-</HEAD>
-
-<BODY BGCOLOR=#FFFFFF>
-
-<TABLE WIDTH=100% BORDER=0 CELLSPACING=2 CELLPADDING=0 BGCOLOR=#000000><TR><TD>
-<!-- start header info -->
-<TABLE WIDTH=100% BORDER=0 CELLSPACING=0 CELLPADDING=0 BGCOLOR=#FFFFFF>
-<TR>
-<TD><FONT SIZE=+3><B>Enhanced Tk Console: tkcon</B></FONT></TD>
-<TD align=right>
-<A href="http://sourceforge.net/projects/tkcon/"> 
-<IMG src="http://sourceforge.net/sflogo.php?group_id=11462&type=1" width="88"
-height="31" border="0" alt="SourceForge Logo"></A>
-</TD>
-</TR>
-</TABLE>
-<!-- end header info -->
-
-</TD></TR><TR><TD>
-
-<TABLE WIDTH=100% BORDER=1 CELLSPACING=2 CELLPADDING=2 BGCOLOR=#DDDDDD>
-<TR>
-
-<TH><A HREF="docs/index.html">Documentation</A></TH>
-<TH><A HREF="docs/demopic.png">Screenshot</A></TH>
-<TH><A HREF="docs/plugin.html">Online Demo!</A> (requires
-<A HREF="http://www.tcl.tk/software/plugin/">Tk plugin</A>)</TH>
-<TH><A HREF="docs/license.terms">License</A> </TH>
-
-</TR><TR>
-
-<TD COLSPAN=4>
-<A
-HREF="http://sourceforge.net/project/showfiles.php?group_id=11462"><B>Release
-Archives</B> (high speed server)</A>
-
-<P>
-<B><CODE STYLE="color: #990033;">Last full release:
-<A HREF="http://prdownloads.sourceforge.net/tkcon/tkcon-2.4.tar.gz">v2.4</A>,
-2004-07-24</CODE></B>
-</P>
-<P>
-You can grab the <A
-HREF="http://tkcon.cvs.sourceforge.net/tkcon/tkcon/tkcon.tcl?rev=HEAD">latest sources</A> from the
-<A HREF="http://tkcon.cvs.sourceforge.net/tkcon/tkcon/"><B>tkcon CVS repository</B></A>.
-</P>
-</TD>
-
-</TR>
-</TABLE>
-
-</TD></TR></TABLE>
-
-<P>
-tkcon is a replacement for the standard console that comes with Tk (on
-Windows/Mac, but also works on Unix).  The console itself provides
-<i>many</i> more features than the standard console.  tkcon works on all
-platforms where Tcl/Tk is available.  It is meant primarily to aid one when
-working with the little details inside tcl and tk, giving Unix users the GUI
-console provided by default in the Mac and Windows Tk.  It's also not a bad
-replacement for the default MS-DOS shell (although it needs lots of fine
-tuning).
-</P>
-
-<HR NOSHADE SIZE=1>
-<ADDRESS><FONT SIZE=2>© Jeffrey Hobbs (jeff at hobbs dot org)</FONT></ADDRESS>
-
-</BODY>
-</HTML>
diff --git a/tkcon-2.5/pkgIndex.tcl b/tkcon-2.5/pkgIndex.tcl
deleted file mode 100644
index 53be103..0000000
--- a/tkcon-2.5/pkgIndex.tcl
+++ /dev/null
@@ -1,11 +0,0 @@
-# pkgIndex.tcl to use tkcon as a package via 'package require tkcon'
-#
-# 'tkcon show' will do all that is necessary to display tkcon
-#
-# Defaults to:
-#  * the main interp as the "slave"
-#  * hiding tkcon when you click in the titlebar [X]
-#  * using '.tkcon' as the root toplevel
-#  * not displaying itself at 'package require' time
-#
-package ifneeded tkcon 2.5 [list source [file join $dir tkcon.tcl]]
diff --git a/tkcon-2.5/tkcon.tcl b/tkcon-2.5/tkcon.tcl
deleted file mode 100755
index feae4f6..0000000
--- a/tkcon-2.5/tkcon.tcl
+++ /dev/null
@@ -1,6385 +0,0 @@
-#!/bin/sh
-# \
-exec wish "$0" ${1+"$@"}
-
-#
-## tkcon.tcl
-## Enhanced Tk Console, part of the VerTcl system
-##
-## Originally based off Brent Welch's Tcl Shell Widget
-## (from "Practical Programming in Tcl and Tk")
-##
-## Thanks to the following (among many) for early bug reports & code ideas:
-## Steven Wahl, Jan Nijtmans, Mark Crimmins, Wart
-##
-## Copyright (c) 1995-2004 Jeffrey Hobbs, jeff(a)hobbs(.)org
-## Initiated: Thu Aug 17 15:36:47 PDT 1995
-##
-## source standard_disclaimer.tcl
-## source bourbon_ware.tcl
-##
-
-# Proxy support for retrieving the current version of Tkcon.
-#
-# Mon Jun 25 12:19:56 2001 - Pat Thoyts
-#
-# In your tkcon.cfg or .tkconrc file put your proxy details into the
-# `proxy' member of the `PRIV' array. e.g.:
-#
-#    set ::tkcon::PRIV(proxy) wwwproxy:8080
-#
-# If you want to be prompted for proxy authentication details (eg for
-# an NT proxy server) make the second element of this variable non-nil - eg:
-#
-#    set ::tkcon::PRIV(proxy) {wwwproxy:8080 1}
-#
-# Or you can set the above variable from within tkcon by calling 
-#
-#    tkcon master set ::tkcon:PRIV(proxy) wwwproxy:8080
-#
-
-if {$tcl_version < 8.0} {
-    return -code error "tkcon requires at least Tcl/Tk8"
-} else {
-    package require Tk
-}
-
-# We need to load some package to get what's available, and we
-# choose ctext because we'll use it if its available in the editor
-catch {package require ctext}
-foreach pkg [info loaded {}] {
-    set file [lindex $pkg 0]
-    set name [lindex $pkg 1]
-    if {![catch {set version [package require $name]}]} {
-	if {[string match {} [package ifneeded $name $version]]} {
-	    package ifneeded $name $version [list load $file $name]
-	}
-    }
-}
-catch {unset pkg file name version}
-
-# Tk 8.4 makes previously exposed stuff private.
-# FIX: Update tkcon to not rely on the private Tk code.
-#
-if {![llength [info globals tkPriv]]} {
-    ::tk::unsupported::ExposePrivateVariable tkPriv
-}
-foreach cmd {SetCursor UpDownLine Transpose ScrollPages} {
-    if {![llength [info commands tkText$cmd]]} {
-        ::tk::unsupported::ExposePrivateCommand tkText$cmd
-    }
-}
-
-# Initialize the ::tkcon namespace
-#
-namespace eval ::tkcon {
-    # when modifying this line, make sure that the auto-upgrade check
-    # for version still works.
-    variable VERSION "2.5"
-    # The OPT variable is an array containing most of the optional
-    # info to configure.  COLOR has the color data.
-    variable OPT
-    variable COLOR
-
-    # PRIV is used for internal data that only tkcon should fiddle with.
-    variable PRIV
-    set PRIV(WWW) [info exists embed_args]
-
-    variable EXPECT 0
-}
-
-## ::tkcon::Init - inits tkcon
-#
-# Calls:	::tkcon::InitUI
-# Outputs:	errors found in tkcon's resource file
-##
-proc ::tkcon::Init {args} {
-    variable VERSION
-    variable OPT
-    variable COLOR
-    variable PRIV
-    global tcl_platform env tcl_interactive errorInfo
-
-    set tcl_interactive 1
-    set argc [llength $args]
-
-    ##
-    ## When setting up all the default values, we always check for
-    ## prior existence.  This allows users who embed tkcon to modify
-    ## the initial state before tkcon initializes itself.
-    ##
-
-    # bg == {} will get bg color from the main toplevel (in InitUI)
-    foreach {key default} {
-	bg		{}
-	blink		\#FFFF00
-	cursor		\#000000
-	disabled	\#4D4D4D
-	proc		\#008800
-	var		\#FFC0D0
-	prompt		\#8F4433
-	stdin		\#000000
-	stdout		\#0000FF
-	stderr		\#FF0000
-    } {
-	if {![info exists COLOR($key)]} { set COLOR($key) $default }
-    }
-
-    # expandorder could also include 'Xotcl' (before Procname)
-    foreach {key default} {
-	autoload	{}
-	blinktime	500
-	blinkrange	1
-	buffer		512
-	maxlinelen	0
-	calcmode	0
-	cols		80
-	debugPrompt	{(level \#$level) debug [history nextid] > }
-	dead		{}
-	edit		edit
-	expandorder	{Pathname Variable Procname}
-	font		{}
-	history		48
-	hoterrors	1
-	library		{}
-	lightbrace	1
-	lightcmd	1
-	maineval	{}
-	maxmenu		18
-	nontcl		0
-	prompt1		{ignore this, it's set below}
-	rows		20
-	scrollypos	right
-	showmenu	1
-	showmultiple	1
-	showstatusbar	1
-	slaveeval	{}
-	slaveexit	close
-	subhistory	1
-	gc-delay	60000
-	gets		{congets}
-	overrideexit	1
-	usehistory	1
-	resultfilter	{}
-
-	exec		slave
-    } {
-	if {![info exists OPT($key)]} { set OPT($key) $default }
-    }
-
-    foreach {key default} {
-	app		{}
-	appname		{}
-	apptype		slave
-	namesp		::
-	cmd		{}
-	cmdbuf		{}
-	cmdsave		{}
-	event		1
-	deadapp		0
-	deadsock	0
-	debugging	0
-	displayWin	.
-	histid		0
-	find		{}
-	find,case	0
-	find,reg	0
-	errorInfo	{}
-	protocol	exit
-	showOnStartup	1
-	slaveprocs	{
-	    alias clear dir dump echo idebug lremove
-	    tkcon_puts tkcon_gets observe observe_var unalias which what
-	}
-	RCS		{RCS: @(#) $Id: tkcon.tcl,v 1.1.1.1 2008/03/27 21:39:47 joye Exp $}
-	HEADURL		{http://tkcon.cvs.sourceforge.net/tkcon/tkcon/tkcon.tcl?rev=HEAD}
-
-	docs		"http://tkcon.sourceforge.net/"
-	email		{jeff(a)hobbs(.)org}
-	root		.
-	uid		0
-	tabs		{}
-    } {
-	if {![info exists PRIV($key)]} { set PRIV($key) $default }
-    }
-    foreach {key default} {
-	slavealias	{ $OPT(edit) more less tkcon }
-    } {
-	if {![info exists PRIV($key)]} { set PRIV($key) [subst $default] }
-    }
-    set PRIV(version) $VERSION
-
-    if {[info exists PRIV(name)]} {
-	set title $PRIV(name)
-    } else {
-	MainInit
-	# some main initialization occurs later in this proc,
-	# to go after the UI init
-	set MainInit 1
-	set title Main
-    }
-
-    ## NOTES FOR STAYING IN PRIMARY INTERPRETER:
-    ##
-    ## If you set ::tkcon::OPT(exec) to {}, then instead of a multiple
-    ## interp model, you get tkcon operating in the main interp by default.
-    ## This can be useful when attaching to programs that like to operate
-    ## in the main interpter (for example, based on special wish'es).
-    ## You can set this from the command line with -exec ""
-    ## A side effect is that all tkcon command line args will be used
-    ## by the first console only.
-    #set OPT(exec) {}
-
-    if {$PRIV(WWW)} {
-	lappend PRIV(slavealias) history
-	set OPT(prompt1) {[history nextid] % }
-    } else {
-	lappend PRIV(slaveprocs) tcl_unknown unknown
-	set OPT(prompt1) {([file tail [pwd]]) [history nextid] % }
-    }
-
-    ## If we are using the default '.' toplevel, and there appear to be
-    ## children of '.', then make sure we use a disassociated toplevel.
-    if {$PRIV(root) == "." && [llength [winfo children .]]} {
-	set PRIV(root) .tkcon
-    }
-
-    ## Do platform specific configuration here, other than defaults
-    ### Use tkcon.cfg filename for resource filename on non-unix systems
-    ### Determine what directory the resource file should be in
-    switch $tcl_platform(platform) {
-	macintosh	{
-	    if {![interp issafe]} {cd [file dirname [info script]]}
-	    set envHome		PREF_FOLDER
-	    set rcfile		tkcon.cfg
-	    set histfile	tkcon.hst
-	    catch {console hide}
-	}
-	windows		{
-	    set envHome		HOME
-	    set rcfile		tkcon.cfg
-	    set histfile	tkcon.hst
-	}
-	unix		{
-	    set envHome		HOME
-	    set rcfile		.tkconrc
-	    set histfile	.tkcon_history
-	}
-    }
-    if {[info exists env($envHome)]} {
-	set home $env($envHome)
-	if {[file pathtype $home] == "volumerelative"} {
-	    # Convert 'C:' to 'C:/' if necessary, innocuous otherwise
-	    append home /
-	}
-	if {![info exists PRIV(rcfile)]} {
-	    set PRIV(rcfile)	[file join $home $rcfile]
-	}
-	if {![info exists PRIV(histfile)]} {
-	    set PRIV(histfile)	[file join $home $histfile]
-	}
-    }
-
-    ## Handle command line arguments before sourcing resource file to
-    ## find if resource file is being specified (let other args pass).
-    if {[set i [lsearch -exact $args -rcfile]] != -1} {
-	set PRIV(rcfile) [lindex $args [incr i]]
-    }
-
-    if {!$PRIV(WWW) && [file exists $PRIV(rcfile)]} {
-	set code [catch {uplevel \#0 [list source $PRIV(rcfile)]} err]
-    }
-
-    if {[info exists env(TK_CON_LIBRARY)]} {
-	lappend ::auto_path $env(TK_CON_LIBRARY)
-    } elseif {$OPT(library) != ""} {
-	lappend ::auto_path $OPT(library)
-    }
-
-    if {![info exists ::tcl_pkgPath]} {
-	set dir [file join [file dirname [info nameofexec]] lib]
-	if {[llength [info commands @scope]]} {
-	    set dir [file join $dir itcl]
-	}
-	catch {source [file join $dir pkgIndex.tcl]}
-    }
-    catch {tclPkgUnknown dummy-name dummy-version}
-
-    ## Handle rest of command line arguments after sourcing resource file
-    ## and slave is created, but before initializing UI or setting packages.
-    set slaveargs {}
-    set slavefiles {}
-    set slaveargv0 {}
-    set truth {^(1|yes|true|on)$}
-    for {set i 0} {$i < $argc} {incr i} {
-	set arg [lindex $args $i]
-	if {[string match {-*} $arg]} {
-	    set val [lindex $args [incr i]]
-	    ## Handle arg based options
-	    switch -glob -- $arg {
-		-- - -argv - -args {
-		    set slaveargs [concat $slaveargs [lrange $args $i end]]
-		    set ::argv $slaveargs
-		    set ::argc [llength $::argv]
-		    break
-		}
-		-color-*	{ set COLOR([string range $arg 7 end]) $val }
-		-exec		{ set OPT(exec) $val }
-		-main - -e - -eval	{ append OPT(maineval) \n$val\n }
-		-package - -load	{ lappend OPT(autoload) $val }
-		-slave		{ append OPT(slaveeval) \n$val\n }
-		-nontcl		{ set OPT(nontcl) [regexp -nocase $truth $val]}
-		-root		{ set PRIV(root) $val }
-		-font		{ set OPT(font) $val }
-		-rcfile	{}
-		default	{ lappend slaveargs $arg; incr i -1 }
-	    }
-	} elseif {[file isfile $arg]} {
-	    if {$i == 0} {
-		set slaveargv0 $arg
-	    }
-	    lappend slavefiles $arg
-	} else {
-	    lappend slaveargs $arg
-	}
-    }
-
-    ## Create slave executable
-    if {"" != $OPT(exec)} {
-	InitSlave $OPT(exec) $slaveargs $slaveargv0
-    } else {
-	set argc [llength $slaveargs]
-	set args $slaveargs
-	uplevel \#0 $slaveargs
-    }
-
-    # Try not to make tkcon override too many standard defaults, and only
-    # do it for the tkcon bits
-    set optclass [tk appname]$PRIV(root)
-    option add $optclass*Menu.tearOff 0
-    option add $optclass*Menu.borderWidth 1
-    option add $optclass*Menu.activeBorderWidth 1
-    if {$::tcl_version >= 8.4 && [tk windowingsystem] != "aqua"} {
-	option add $optclass*Scrollbar.borderWidth 1
-    }
-
-    ## Attach to the slave, EvalAttached will then be effective
-    Attach $PRIV(appname) $PRIV(apptype)
-    InitUI $title
-    if {"" != $OPT(exec)} {
-	# override exit to DeleteTab now that tab has been created
-	$OPT(exec) alias exit ::tkcon::DeleteTab $PRIV(curtab) $OPT(exec)
-    }
-
-    ## swap puts and gets with the tkcon versions to make sure all
-    ## input and output is handled by tkcon
-    if {![catch {rename ::puts ::tkcon_tcl_puts}]} {
-	interp alias {} ::puts {} ::tkcon_puts
-    }
-    if {($OPT(gets) != "") && ![catch {rename ::gets ::tkcon_tcl_gets}]} {
-	interp alias {} ::gets {} ::tkcon_gets
-    }
-
-    EvalSlave history keep $OPT(history)
-    if {[info exists MainInit]} {
-	# Source history file only for the main console, as all slave
-	# consoles will adopt from the main's history, but still
-	# keep separate histories
-	if {!$PRIV(WWW) && $OPT(usehistory) && [file exists $PRIV(histfile)]} {
-	    puts -nonewline "loading history file ... "
-	    # The history file is built to be loaded in and
-	    # understood by tkcon
-	    if {[catch {uplevel \#0 [list source $PRIV(histfile)]} herr]} {
-		puts stderr "error:\n$herr"
-		append PRIV(errorInfo) $errorInfo\n
-	    }
-	    set PRIV(event) [EvalSlave history nextid]
-	    puts "[expr {$PRIV(event)-1}] events added"
-	}
-    }
-
-    ## Autoload specified packages in slave
-    set pkgs [EvalSlave package names]
-    foreach pkg $OPT(autoload) {
-	puts -nonewline "autoloading package \"$pkg\" ... "
-	if {[lsearch -exact $pkgs $pkg]>-1} {
-	    if {[catch {EvalSlave package require [list $pkg]} pkgerr]} {
-		puts stderr "error:\n$pkgerr"
-		append PRIV(errorInfo) $errorInfo\n
-	    } else { puts "OK" }
-	} else {
-	    puts stderr "error: package does not exist"
-	}
-    }
-
-    ## Evaluate maineval in slave
-    if {[string compare {} $OPT(maineval)] && \
-	    [catch {uplevel \#0 $OPT(maineval)} merr]} {
-	puts stderr "error in eval:\n$merr"
-	append PRIV(errorInfo) $errorInfo\n
-    }
-
-    ## Source extra command line argument files into slave executable
-    foreach fn $slavefiles {
-	puts -nonewline "slave sourcing \"$fn\" ... "
-	if {[catch {EvalSlave uplevel \#0 [list source $fn]} fnerr]} {
-	    puts stderr "error:\n$fnerr"
-	    append PRIV(errorInfo) $errorInfo\n
-	} else { puts "OK" }
-    }
-
-    ## Evaluate slaveeval in slave
-    if {[string compare {} $OPT(slaveeval)] && \
-	    [catch {interp eval $OPT(exec) $OPT(slaveeval)} serr]} {
-	puts stderr "error in slave eval:\n$serr"
-	append PRIV(errorInfo) $errorInfo\n
-    }
-    ## Output any error/output that may have been returned from rcfile
-    if {[info exists code] && $code && [string compare {} $err]} {
-	puts stderr "error in $PRIV(rcfile):\n$err"
-	append PRIV(errorInfo) $errorInfo
-    }
-    if {[string compare {} $OPT(exec)]} {
-	StateCheckpoint [concat $PRIV(name) $OPT(exec)] slave
-    }
-    StateCheckpoint $PRIV(name) slave
-
-    puts "buffer line limit:\
-	[expr {$OPT(buffer)?$OPT(buffer):{unlimited}}]  \
-	max line length:\
-	[expr {$OPT(maxlinelen)?$OPT(maxlinelen):{unlimited}}]"
-
-    Prompt "$title console display active (Tcl$::tcl_patchLevel / Tk$::tk_patchLevel)\n"
-}
-
-## ::tkcon::InitSlave - inits the slave by placing key procs and aliases in it
-## It's arg[cv] are based on passed in options, while argv0 is the same as
-## the master.  tcl_interactive is the same as the master as well.
-# ARGS:	slave	- name of slave to init.  If it does not exist, it is created.
-#	args	- args to pass to a slave as argv/argc
-##
-proc ::tkcon::InitSlave {slave {slaveargs {}} {slaveargv0 {}}} {
-    variable OPT
-    variable COLOR
-    variable PRIV
-    global argv0 tcl_interactive tcl_library env auto_path tk_library
-
-    if {[string match {} $slave]} {
-	return -code error "Don't init the master interpreter, goofball"
-    }
-    if {![interp exists $slave]} { interp create $slave }
-    if {[interp eval $slave info command source] == ""} {
-	$slave alias source SafeSource $slave
-	$slave alias load SafeLoad $slave
-	$slave alias open SafeOpen $slave
-	$slave alias file file
-	interp eval $slave \
-	    [list set auto_path [lremove $auto_path $tk_library]]
-	interp eval $slave [dump var -nocomplain tcl_library env]
-	interp eval $slave { catch {source [file join $tcl_library init.tcl]} }
-	interp eval $slave { catch unknown }
-    }
-    # This will likely be overridden to call DeleteTab where possible
-    $slave alias exit exit
-    interp eval $slave {
-	# Do package require before changing around puts/gets
-	catch {set __tkcon_error ""; set __tkcon_error $errorInfo}
-	catch {package require bogus-package-name}
-	catch {rename ::puts ::tkcon_tcl_puts}
-	set errorInfo ${__tkcon_error}
-	unset __tkcon_error
-    }
-    foreach cmd $PRIV(slaveprocs) { $slave eval [dump proc $cmd] }
-    foreach cmd $PRIV(slavealias) { $slave alias $cmd $cmd }
-    interp alias $slave ::ls $slave ::dir -full
-    interp alias $slave ::puts $slave ::tkcon_puts
-    if {$OPT(gets) != ""} {
-	interp eval $slave { catch {rename ::gets ::tkcon_tcl_gets} }
-	interp alias $slave ::gets $slave ::tkcon_gets
-    }
-    if {$slaveargv0 != ""} {
-	# If tkcon was invoked with 1 or more filenames, then make the
-	# first filename argv0 in the slave, as tclsh/wish would do it.
-	interp eval $slave [list set argv0 $slaveargv0]
-    } else {
-	if {[info exists argv0]} {interp eval $slave [list set argv0 $argv0]}
-    }
-    interp eval $slave set tcl_interactive $tcl_interactive \; \
-	    set auto_path [list [lremove $auto_path $tk_library]] \; \
-	    set argc [llength $slaveargs] \; \
-	    set argv  [list $slaveargs] \; {
-	if {![llength [info command bgerror]]} {
-	    proc bgerror err {
-		global errorInfo
-		set body [info body bgerror]
-		rename ::bgerror {}
-		if {[auto_load bgerror]} { return [bgerror $err] }
-		proc bgerror err $body
-		tkcon bgerror $err $errorInfo
-	    }
-	}
-    }
-
-    foreach pkg [lremove [package names] Tcl] {
-	foreach v [package versions $pkg] {
-	    interp eval $slave [list package ifneeded $pkg $v \
-		    [package ifneeded $pkg $v]]
-	}
-    }
-}
-
-## ::tkcon::InitInterp - inits an interpreter by placing key
-## procs and aliases in it.
-# ARGS: name	- interp name
-#	type	- interp type (slave|interp)
-##
-proc ::tkcon::InitInterp {name type} {
-    variable OPT
-    variable PRIV
-
-    ## Don't allow messing up a local master interpreter
-    if {[string match namespace $type] || ([string match slave $type] && \
-	    [regexp {^([Mm]ain|Slave[0-9]+)$} $name])} return
-    set old [Attach]
-    set oldname $PRIV(namesp)
-    catch {
-	Attach $name $type
-	EvalAttached { catch {rename ::puts ::tkcon_tcl_puts} }
-	foreach cmd $PRIV(slaveprocs) { EvalAttached [dump proc $cmd] }
-	switch -exact $type {
-	    slave {
-		foreach cmd $PRIV(slavealias) {
-		    Main interp alias $name ::$cmd $PRIV(name) ::$cmd
-		}
-	    }
-	    interp {
-		set thistkcon [::send::appname]
-		foreach cmd $PRIV(slavealias) {
-		    EvalAttached "proc $cmd args { ::send::send [list $thistkcon] $cmd \$args }"
-		}
-	    }
-	}
-	## Catch in case it's a 7.4 (no 'interp alias') interp
-	EvalAttached {
-	    catch {interp alias {} ::ls {} ::dir -full}
-	    if {[catch {interp alias {} ::puts {} ::tkcon_puts}]} {
-		catch {rename ::tkcon_puts ::puts}
-	    }
-	}
-	if {$OPT(gets) != ""} {
-	    EvalAttached {
-		catch {rename ::gets ::tkcon_tcl_gets}
-		if {[catch {interp alias {} ::gets {} ::tkcon_gets}]} {
-		    catch {rename ::tkcon_gets ::gets}
-		}
-	    }
-	}
-	return
-    } {err}
-    eval Attach $old
-    AttachNamespace $oldname
-    if {[string compare {} $err]} { return -code error $err }
-}
-
-## ::tkcon::InitUI - inits UI portion (console) of tkcon
-## Creates all elements of the console window and sets up the text tags
-# ARGS:	root	- widget pathname of the tkcon console root
-#	title	- title for the console root and main (.) windows
-# Calls:	::tkcon::InitMenus, ::tkcon::Prompt
-##
-proc ::tkcon::InitUI {title} {
-    variable OPT
-    variable PRIV
-    variable COLOR
-
-    set root $PRIV(root)
-    if {[string match . $root]} { set w {} } else { set w [toplevel $root] }
-    if {!$PRIV(WWW)} {
-	wm withdraw $root
-	wm protocol $root WM_DELETE_WINDOW $PRIV(protocol)
-    }
-    set PRIV(base) $w
-
-    catch {font create tkconfixed -family Courier -size -12}
-    catch {font create tkconfixedbold -family Courier -size -12 -weight bold}
-
-    set PRIV(statusbar) [set sbar [frame $w.fstatus]]
-    set PRIV(tabframe)  [frame $sbar.tabs]
-    set PRIV(X) [button $sbar.deltab -text "X" -command ::tkcon::DeleteTab \
-		     -activeforeground red -fg red -font tkconfixedbold \
-		     -highlightthickness 0 -padx 2 -pady 0 -borderwidth 1 \
-		     -state disabled -relief flat -takefocus 0]
-    catch {$PRIV(X) configure -overrelief raised}
-    label $sbar.cursor -relief sunken -borderwidth 1 -anchor e -width 6 \
-	    -textvariable ::tkcon::PRIV(StatusCursor)
-    set padx [expr {![info exists ::tcl_platform(os)]
-		    || ![string match "Windows CE" $::tcl_platform(os)]}]
-    grid $PRIV(X) $PRIV(tabframe) $sbar.cursor -sticky news -padx $padx
-    grid configure $PRIV(tabframe) -sticky nsw
-    grid configure $PRIV(X) -pady 0 -padx 0
-    grid columnconfigure $sbar 1 -weight 1
-    grid rowconfigure $sbar 0 -weight 1
-    grid rowconfigure $PRIV(tabframe) 0 -weight 1
-    if {$::tcl_version >= 8.4 && [tk windowingsystem] == "aqua"} {
-	# resize control space
-	grid columnconfigure $sbar [lindex [grid size $sbar] 0] -minsize 16
-    }
-
-    ## Create console tab
-    set con [InitTab $w]
-    set PRIV(curtab) $con
-
-    # Only apply this for the first console
-    $con configure -setgrid 1 -width $OPT(cols) -height $OPT(rows)
-    bind $PRIV(root) <Configure> {
-	if {"%W" == $::tkcon::PRIV(root)} {
-	    scan [wm geometry [winfo toplevel %W]] "%%dx%%d" \
-		::tkcon::OPT(cols) ::tkcon::OPT(rows)
-	    if {[info exists ::tkcon::EXP(spawn_id)]} {
-		catch {stty rows $::tkcon::OPT(rows) columns \
-			   $::tkcon::OPT(cols) < $::tkcon::EXP(slave,name)}
-	    }
-	}
-    }
-
-    # scrollbar
-    set sy [scrollbar $w.sy -takefocus 0 -command [list $con yview]]
-    if {!$PRIV(WWW) && [string match "Windows CE" $::tcl_platform(os)]} {
-	$w.sy configure -width 10
-    }
-
-    $con configure -yscrollcommand [list $sy set]
-    set PRIV(console) $con
-    set PRIV(scrolly) $sy
-
-    ## Menus
-    ## catch against use in plugin
-    if {[catch {menu $w.mbar} PRIV(menubar)]} {
-	set PRIV(menubar) [frame $w.mbar -relief raised -borderwidth 1]
-    }
-
-    InitMenus $PRIV(menubar) $title
-    Bindings
-
-    if {$OPT(showmenu)} {
-	$root configure -menu $PRIV(menubar)
-    }
-
-    grid $con  -row 1 -column 1 -sticky news
-    grid $sy   -row 1 -column [expr {$OPT(scrollypos)=="left"?0:2}] -sticky ns
-    grid $sbar -row 2 -column 0 -columnspan 3 -sticky ew
-
-    grid columnconfigure $root 1 -weight 1
-    grid rowconfigure    $root 1 -weight 1
-
-    if {!$OPT(showstatusbar)} {
-	grid remove $sbar
-    }
-
-    if {!$PRIV(WWW)} {
-	wm title $root "tkcon $PRIV(version) $title"
-	if {$PRIV(showOnStartup)} { wm deiconify $root }
-    }
-    if {$PRIV(showOnStartup)} { focus -force $PRIV(console) }
-    if {$OPT(gc-delay)} {
-	after $OPT(gc-delay) ::tkcon::GarbageCollect
-    }
-}
-
-proc ::tkcon::InitTab {w} {
-    variable OPT
-    variable PRIV
-    variable COLOR
-    variable ATTACH
-
-    # text console
-    set con $w.tab[incr PRIV(uid)]
-    text $con -wrap char -foreground $COLOR(stdin) \
-	-insertbackground $COLOR(cursor) -borderwidth 1 -highlightthickness 0
-    $con mark set output 1.0
-    $con mark set limit 1.0
-    if {[string compare {} $COLOR(bg)]} {
-	$con configure -background $COLOR(bg)
-    }
-    set COLOR(bg) [$con cget -background]
-    if {[string compare {} $OPT(font)]} {
-	## Set user-requested font, if any
-	$con configure -font $OPT(font)
-    } elseif {[string compare unix $::tcl_platform(platform)]} {
-	## otherwise make sure the font is monospace
-	set font [$con cget -font]
-	if {![font metrics $font -fixed]} {
-	    $con configure -font tkconfixed
-	}
-    } else {
-	$con configure -font tkconfixed
-    }
-    set OPT(font) [$con cget -font]
-    bindtags $con [list $con TkConsole TkConsolePost $PRIV(root) all]
-
-    # scrollbar
-    if {!$PRIV(WWW)} {
-	if {[string match "Windows CE" $::tcl_platform(os)]} {
-	    font configure tkconfixed -family Tahoma -size 8
-	    $con configure -font tkconfixed -borderwidth 0 -padx 0 -pady 0
-	    set cw [font measure tkconfixed "0"]
-	    set ch [font metrics tkconfixed -linespace]
-	    set sw [winfo screenwidth $con]
-	    set sh [winfo screenheight $con]
-	    # We need the magic hard offsets until I find a way to
-	    # correctly assume size
-	    if {$cw*($OPT(cols)+2) > $sw} {
-		set OPT(cols) [expr {($sw / $cw) - 2}]
-	    }
-	    if {$ch*($OPT(rows)+3) > $sh} {
-		set OPT(rows) [expr {($sh / $ch) - 3}]
-	    }
-	    # Place it so that the titlebar underlaps the CE titlebar
-	    wm geometry $PRIV(root) +0+0
-	}
-    }
-    $con configure -height $OPT(rows) -width $OPT(cols)
-
-    foreach col {prompt stdout stderr stdin proc} {
-	$con tag configure $col -foreground $COLOR($col)
-    }
-    $con tag configure var -background $COLOR(var)
-    $con tag raise sel
-    $con tag configure blink -background $COLOR(blink)
-    $con tag configure find -background $COLOR(blink)
-
-    set ATTACH($con) [Attach]
-    set rb [radiobutton $PRIV(tabframe).cb[winfo name $con] -takefocus 0 \
-		-textvariable ::tkcon::ATTACH($con) \
-		-selectcolor white -relief sunken \
-		-indicatoron 0 -padx 0 -pady 0 -borderwidth 1 \
-		-variable ::tkcon::PRIV(curtab) -value $con \
-		-command [list ::tkcon::GotoTab $con]]
-    if {$::tcl_version >= 8.4} {
-	$rb configure -offrelief flat -overrelief raised
-    }
-    grid $rb -row 0 -column [lindex [grid size $PRIV(tabframe)] 0] -sticky ns
-    grid $con -row 1 -column 1 -sticky news
-
-    lappend PRIV(tabs) $con
-    return $con
-}
-
-proc ::tkcon::GotoTab {con} {
-    variable PRIV
-    variable ATTACH
-
-    set numtabs [llength $PRIV(tabs)]
-    #if {$numtabs == 1} { return }
-
-    if {[regexp {^[0-9]+$} $con]} {
-	set curtab [lsearch -exact $PRIV(tabs) $PRIV(console)]
-	set nexttab [expr {$curtab + $con}]
-	if {$nexttab >= $numtabs} {
-	    set nexttab 0
-	} elseif {$nexttab < 0} {
-	    set nexttab "end"
-	}
-	set con [lindex $PRIV(tabs) $nexttab]
-    } elseif {$con == $PRIV(console)} {
-	return
-    }
-
-    # adjust console
-    if {[winfo exists $PRIV(console)]} {
-	lower $PRIV(console)
-	$PRIV(console) configure -yscrollcommand {}
-	set ATTACH($PRIV(console)) [Attach]
-    }
-    set PRIV(console) $con
-    $con configure -yscrollcommand [list $PRIV(scrolly) set]
-    $PRIV(scrolly) configure -command [list $con yview]
-
-    # adjust attach
-    eval [linsert $ATTACH($con) 0 Attach]
-
-    set PRIV(curtab) $con
-
-    raise $con
-
-    if {[$con compare 1.0 == end-1c]} {
-	Prompt
-    }
-
-    # set StatusCursor
-    set PRIV(StatusCursor) [$con index insert]
-
-    focus -force $con
-}
-
-proc ::tkcon::NewTab {{con {}}} {
-    variable PRIV
-    variable ATTACH
-
-    set con   [InitTab $PRIV(base)]
-    set slave [GetSlave]
-    InitSlave $slave
-    $slave alias exit ::tkcon::DeleteTab $con $slave
-    if {$PRIV(name) != ""} {
-	set ATTACH($con) [list [list $PRIV(name) $slave] slave]
-    } else {
-	set ATTACH($con) [list $slave slave]
-    }
-    $PRIV(X) configure -state normal
-    MenuConfigure Console "Delete Tab" -state normal
-    GotoTab $con
-}
-
-# The extra code arg is for the alias of exit to this function
-proc ::tkcon::DeleteTab {{con {}} {slave {}} {code 0}} {
-    variable PRIV
-
-    set numtabs [llength $PRIV(tabs)]
-    if {$numtabs <= 2} {
-	$PRIV(X) configure -state disabled
-	MenuConfigure Console "Delete Tab" -state disabled
-    }
-    if {$numtabs == 1} {
-	# in the master, it should do the right thing
-	# currently the first master still exists - need rearch to fix
-	exit
-	# we might end up here, depending on how exit is rerouted
-	return
-    }
-
-    if {$con == ""} {
-	set con $PRIV(console)
-    }
-    catch {unset ATTACH($con)}
-    set curtab  [lsearch -exact $PRIV(tabs) $con]
-    set PRIV(tabs) [lreplace $PRIV(tabs) $curtab $curtab]
-
-    set numtabs [llength $PRIV(tabs)]
-    set nexttab $curtab
-    if {$nexttab >= $numtabs} {
-	set nexttab end
-    }
-    set nexttab [lindex $PRIV(tabs) $nexttab]
-
-    GotoTab $nexttab
-
-    if {$slave != "" && $slave != $::tkcon::OPT(exec)} {
-	interp delete $slave
-    }
-    destroy $PRIV(tabframe).cb[winfo name $con]
-    destroy $con
-}
-
-## ::tkcon::GarbageCollect - do various cleanup ops periodically to our setup
-##
-proc ::tkcon::GarbageCollect {} {
-    variable OPT
-    variable PRIV
-
-    foreach w $PRIV(tabs) {
-	if {[winfo exists $w]} {
-	    ## Remove error tags that no longer span anything
-	    ## Make sure the tag pattern matches the unique tag prefix
-	    foreach tag [$w tag names] {
-		if {[string match _tag* $tag]
-		    && ![llength [$w tag ranges $tag]]} {
-		    $w tag delete $tag
-		}
-	    }
-	}
-    }
-    if {$OPT(gc-delay)} {
-	after $OPT(gc-delay) ::tkcon::GarbageCollect
-    }
-}
-
-## ::tkcon::Eval - evaluates commands input into console window
-## This is the first stage of the evaluating commands in the console.
-## They need to be broken up into consituent commands (by ::tkcon::CmdSep) in
-## case a multiple commands were pasted in, then each is eval'ed (by
-## ::tkcon::EvalCmd) in turn.  Any uncompleted command will not be eval'ed.
-# ARGS:	w	- console text widget
-# Calls:	::tkcon::CmdGet, ::tkcon::CmdSep, ::tkcon::EvalCmd
-## 
-proc ::tkcon::Eval {w} {
-    set incomplete [CmdSep [CmdGet $w] cmds last]
-    $w mark set insert end-1c
-    $w insert end \n
-    if {[llength $cmds]} {
-	foreach c $cmds {EvalCmd $w $c}
-	$w insert insert $last {}
-    } elseif {!$incomplete} {
-	EvalCmd $w $last
-    }
-    if {[winfo exists $w]} {
-	$w see insert
-    }
-}
-
-## ::tkcon::EvalCmd - evaluates a single command, adding it to history
-# ARGS:	w	- console text widget
-# 	cmd	- the command to evaluate
-# Calls:	::tkcon::Prompt
-# Outputs:	result of command to stdout (or stderr if error occured)
-# Returns:	next event number
-## 
-proc ::tkcon::EvalCmd {w cmd} {
-    variable OPT
-    variable PRIV
-
-    $w mark set output end
-    if {[string compare {} $cmd]} {
-	set code 0
-	if {$OPT(subhistory)} {
-	    set ev [EvalSlave history nextid]
-	    incr ev -1
-	    ## FIX: calcmode doesn't work with requesting history events
-	    if {[string match !! $cmd]} {
-		set code [catch {EvalSlave history event $ev} cmd]
-		if {!$code} {$w insert output $cmd\n stdin}
-	    } elseif {[regexp {^!(.+)$} $cmd dummy event]} {
-		## Check last event because history event is broken
-		set code [catch {EvalSlave history event $ev} cmd]
-		if {!$code && ![string match ${event}* $cmd]} {
-		    set code [catch {EvalSlave history event $event} cmd]
-		}
-		if {!$code} {$w insert output $cmd\n stdin}
-	    } elseif {[regexp {^\^([^^]*)\^([^^]*)\^?$} $cmd dummy old new]} {
-		set code [catch {EvalSlave history event $ev} cmd]
-		if {!$code} {
-		    regsub -all -- $old $cmd $new cmd
-		    $w insert output $cmd\n stdin
-		}
-	    } elseif {$OPT(calcmode) && ![catch {expr $cmd} err]} {
-		AddSlaveHistory $cmd
-		set cmd $err
-		set code -1
-	    }
-	}
-	if {$code} {
-	    $w insert output $cmd\n stderr
-	} else {
-	    ## We are about to evaluate the command, so move the limit
-	    ## mark to ensure that further <Return>s don't cause double
-	    ## evaluation of this command - for cases like the command
-	    ## has a vwait or something in it
-	    $w mark set limit end
-	    if {$OPT(nontcl) && [string match interp $PRIV(apptype)]} {
-		set code [catch {EvalSend $cmd} res]
-		if {$code == 1} {
-		    set PRIV(errorInfo) "Non-Tcl errorInfo not available"
-		}
-	    } elseif {[string match socket $PRIV(apptype)]} {
-		set code [catch {EvalSocket $cmd} res]
-		if {$code == 1} {
-		    set PRIV(errorInfo) "Socket-based errorInfo not available"
-		}
-	    } else {
-		set code [catch {EvalAttached $cmd} res]
-		if {$code == 1} {
-		    if {[catch {EvalAttached [list set errorInfo]} err]} {
-			set PRIV(errorInfo) "Error getting errorInfo:\n$err"
-		    } else {
-			set PRIV(errorInfo) $err
-		    }
-		}
-	    }
-	    if {![winfo exists $w]} {
-		# early abort - must be a deleted tab
-		return
-	    }
-	    AddSlaveHistory $cmd
-	    # Run any user defined result filter command.  The command is
-	    # passed result code and data.
-	    if {[llength $OPT(resultfilter)]} {
-		set cmd [linsert $OPT(resultfilter) end $code $res]
-		if {[catch {EvalAttached $cmd} res2]} {
-		    $w insert output "Filter failed: $res2" stderr \n stdout
-		} else {
-		    set res $res2
-		}
-	    }
-	    catch {EvalAttached [list set _ $res]}
-	    set maxlen $OPT(maxlinelen)
-	    set trailer ""
-	    if {($maxlen > 0) && ([string length $res] > $maxlen)} {
-		# If we exceed maximum desired output line length, truncate
-		# the result and add "...+${num}b" in error coloring
-		set trailer ...+[expr {[string length $res]-$maxlen}]b
-		set res [string range $res 0 $maxlen]
-	    }
-	    if {$code} {
-		if {$OPT(hoterrors)} {
-		    set tag [UniqueTag $w]
-		    $w insert output $res [list stderr $tag] \n$trailer stderr
-		    $w tag bind $tag <Enter> \
-			    [list $w tag configure $tag -under 1]
-		    $w tag bind $tag <Leave> \
-			    [list $w tag configure $tag -under 0]
-		    $w tag bind $tag <ButtonRelease-1> \
-			    "if {!\[info exists tkPriv(mouseMoved)\] || !\$tkPriv(mouseMoved)} \
-			    {[list $OPT(edit) -attach [Attach] -type error -- $PRIV(errorInfo)]}"
-		} else {
-		    $w insert output $res\n$trailer stderr
-		}
-	    } elseif {[string compare {} $res]} {
-		$w insert output $res stdout $trailer stderr \n stdout
-	    }
-	}
-    }
-    Prompt
-    set PRIV(event) [EvalSlave history nextid]
-}
-
-## ::tkcon::EvalSlave - evaluates the args in the associated slave
-## args should be passed to this procedure like they would be at
-## the command line (not like to 'eval').
-# ARGS:	args	- the command and args to evaluate
-##
-proc ::tkcon::EvalSlave args {
-    interp eval $::tkcon::OPT(exec) $args
-}
-
-## ::tkcon::EvalOther - evaluate a command in a foreign interp or slave
-## without attaching to it.  No check for existence is made.
-# ARGS:	app	- interp/slave name
-#	type	- (slave|interp)
-##
-proc ::tkcon::EvalOther { app type args } {
-    if {[string compare slave $type]==0} {
-	return [Slave $app $args]
-    } else {
-	return [uplevel 1 ::send::send [list $app] $args]
-    }
-}
-
-## ::tkcon::AddSlaveHistory - 
-## Command is added to history only if different from previous command.
-## This also doesn't cause the history id to be incremented, although the
-## command will be evaluated.
-# ARGS: cmd	- command to add
-##
-proc ::tkcon::AddSlaveHistory cmd {
-    set ev [EvalSlave history nextid]
-    incr ev -1
-    set code [catch {EvalSlave history event $ev} lastCmd]
-    if {$code || [string compare $cmd $lastCmd]} {
-	EvalSlave history add $cmd
-    }
-}
-
-## ::tkcon::EvalSend - sends the args to the attached interpreter
-## Varies from 'send' by determining whether attachment is dead
-## when an error is received
-# ARGS:	cmd	- the command string to send across
-# Returns:	the result of the command
-##
-proc ::tkcon::EvalSend cmd {
-    variable OPT
-    variable PRIV
-
-    if {$PRIV(deadapp)} {
-	if {[lsearch -exact [::send::interps] $PRIV(app)]<0} {
-	    return
-	} else {
-	    set PRIV(appname) [string range $PRIV(appname) 5 end]
-	    set PRIV(deadapp) 0
-	    Prompt "\n\"$PRIV(app)\" alive\n" [CmdGet $PRIV(console)]
-	}
-    }
-    set code [catch {::send::send -displayof $PRIV(displayWin) $PRIV(app) $cmd} result]
-    if {$code && [lsearch -exact [::send::interps] $PRIV(app)]<0} {
-	## Interpreter disappeared
-	if {[string compare leave $OPT(dead)] && \
-		([string match ignore $OPT(dead)] || \
-		     [tk_messageBox -title "Dead Attachment" -type yesno \
-			  -icon info -message \
-			  "\"$PRIV(app)\" appears to have died.\
-		\nReturn to primary slave interpreter?"]=="no")} {
-	    set PRIV(appname) "DEAD:$PRIV(appname)"
-	    set PRIV(deadapp) 1
-	} else {
-	    set err "Attached Tk interpreter \"$PRIV(app)\" died."
-	    Attach {}
-	    set PRIV(deadapp) 0
-	    EvalSlave set errorInfo $err
-	}
-	Prompt \n [CmdGet $PRIV(console)]
-    }
-    return -code $code $result
-}
-
-## ::tkcon::EvalSocket - sends the string to an interpreter attached via
-## a tcp/ip socket
-##
-## In the EvalSocket case, ::tkcon::PRIV(app) is the socket id
-##
-## Must determine whether socket is dead when an error is received
-# ARGS:	cmd	- the data string to send across
-# Returns:	the result of the command
-##
-proc ::tkcon::EvalSocket cmd {
-    variable OPT
-    variable PRIV
-    global tcl_version
-
-    if {$PRIV(deadapp)} {
-	if {![info exists PRIV(app)] || \
-		[catch {eof $PRIV(app)} eof] || $eof} {
-	    return
-	} else {
-	    set PRIV(appname) [string range $PRIV(appname) 5 end]
-	    set PRIV(deadapp) 0
-	    Prompt "\n\"$PRIV(app)\" alive\n" [CmdGet $PRIV(console)]
-	}
-    }
-    # Sockets get \'s interpreted, so that users can
-    # send things like \n\r or explicit hex values
-    set cmd [subst -novariables -nocommands $cmd]
-    #puts [list $PRIV(app) $cmd]
-    set code [catch {puts $PRIV(app) $cmd ; flush $PRIV(app)} result]
-    if {$code && [eof $PRIV(app)]} {
-	## Interpreter died or disappeared
-	puts "$code eof [eof $PRIV(app)]"
-	EvalSocketClosed $PRIV(app)
-    }
-    return -code $code $result
-}
-
-## ::tkcon::EvalSocketEvent - fileevent command for an interpreter attached
-## via a tcp/ip socket
-## Must determine whether socket is dead when an error is received
-# ARGS:	args	- the args to send across
-# Returns:	the result of the command
-##
-proc ::tkcon::EvalSocketEvent {sock} {
-    variable PRIV
-
-    if {[gets $sock line] == -1} {
-	if {[eof $sock]} {
-	    EvalSocketClosed $sock
-	}
-	return
-    }
-    puts $line
-}
-
-## ::tkcon::EvalSocketClosed - takes care of handling a closed eval socket
-##
-# ARGS:	args	- the args to send across
-# Returns:	the result of the command
-##
-proc ::tkcon::EvalSocketClosed {sock} {
-    variable OPT
-    variable PRIV
-
-    catch {close $sock}
-    if {![string match $sock $PRIV(app)]} {
-	# If we are not still attached to that socket, just return.
-	# Might be nice to tell the user the socket closed ...
-	return
-    }
-    if {[string compare leave $OPT(dead)] && \
-	    ([string match ignore $OPT(dead)] || \
-		 [tk_messageBox -title "Dead Attachment" -type yesno \
-		      -icon question \
-		      -message "\"$PRIV(app)\" appears to have died.\
-	    \nReturn to primary slave interpreter?"] == "no")} {
-	set PRIV(appname) "DEAD:$PRIV(appname)"
-	set PRIV(deadapp) 1
-    } else {
-	set err "Attached Tk interpreter \"$PRIV(app)\" died."
-	Attach {}
-	set PRIV(deadapp) 0
-	EvalSlave set errorInfo $err
-    }
-    Prompt \n [CmdGet $PRIV(console)]
-}
-
-## ::tkcon::EvalNamespace - evaluates the args in a particular namespace
-## This is an override for ::tkcon::EvalAttached for when the user wants
-## to attach to a particular namespace of the attached interp
-# ARGS:	attached	
-#	namespace	the namespace to evaluate in
-#	args		the args to evaluate
-# RETURNS:	the result of the command
-##
-proc ::tkcon::EvalNamespace { attached namespace args } {
-    if {[llength $args]} {
-	uplevel \#0 $attached \
-		[list [concat [list namespace eval $namespace] $args]]
-    }
-}
-
-
-## ::tkcon::Namespaces - return all the namespaces descendent from $ns
-##
-#
-##
-proc ::tkcon::Namespaces {{ns ::} {l {}}} {
-    if {[string compare {} $ns]} { lappend l $ns }
-    foreach i [EvalAttached [list namespace children $ns]] {
-	set l [Namespaces $i $l]
-    }
-    return $l
-}
-
-## ::tkcon::CmdGet - gets the current command from the console widget
-# ARGS:	w	- console text widget
-# Returns:	text which compromises current command line
-## 
-proc ::tkcon::CmdGet w {
-    if {![llength [$w tag nextrange prompt limit end]]} {
-	$w tag add stdin limit end-1c
-	return [$w get limit end-1c]
-    }
-}
-
-## ::tkcon::CmdSep - separates multiple commands into a list and remainder
-# ARGS:	cmd	- (possible) multiple command to separate
-# 	list	- varname for the list of commands that were separated.
-#	last	- varname of any remainder (like an incomplete final command).
-#		If there is only one command, it's placed in this var.
-# Returns:	constituent command info in varnames specified by list & rmd.
-## 
-proc ::tkcon::CmdSep {cmd list last} {
-    upvar 1 $list cmds $last inc
-    set inc {}
-    set cmds {}
-    foreach c [split [string trimleft $cmd] \n] {
-	if {[string compare $inc {}]} {
-	    append inc \n$c
-	} else {
-	    append inc [string trimleft $c]
-	}
-	if {[info complete $inc] && ![regexp {[^\\]\\$} $inc]} {
-	    if {[regexp "^\[^#\]" $inc]} {lappend cmds $inc}
-	    set inc {}
-	}
-    }
-    set i [string compare $inc {}]
-    if {!$i && [string compare $cmds {}] && ![string match *\n $cmd]} {
-	set inc [lindex $cmds end]
-	set cmds [lreplace $cmds end end]
-    }
-    return $i
-}
-
-## ::tkcon::CmdSplit - splits multiple commands into a list
-# ARGS:	cmd	- (possible) multiple command to separate
-# Returns:	constituent commands in a list
-## 
-proc ::tkcon::CmdSplit {cmd} {
-    set inc {}
-    set cmds {}
-    foreach cmd [split [string trimleft $cmd] \n] {
-	if {[string compare {} $inc]} {
-	    append inc \n$cmd
-	} else {
-	    append inc [string trimleft $cmd]
-	}
-	if {[info complete $inc] && ![regexp {[^\\]\\$} $inc]} {
-	    #set inc [string trimright $inc]
-	    if {[regexp "^\[^#\]" $inc]} {lappend cmds $inc}
-	    set inc {}
-	}
-    }
-    if {[regexp "^\[^#\]" $inc]} {lappend cmds $inc}
-    return $cmds
-}
-
-## ::tkcon::UniqueTag - creates a uniquely named tag, reusing names
-## Called by ::tkcon::EvalCmd
-# ARGS:	w	- text widget
-# Outputs:	tag name guaranteed unique in the widget
-## 
-proc ::tkcon::UniqueTag {w} {
-    set tags [$w tag names]
-    set idx 0
-    while {[lsearch -exact $tags _tag[incr idx]] != -1} {}
-    return _tag$idx
-}
-
-## ::tkcon::ConstrainBuffer - This limits the amount of data in the text widget
-## Called by ::tkcon::Prompt and in tkcon proc buffer/console switch cases
-# ARGS:	w	- console text widget
-#	size	- # of lines to constrain to
-# Outputs:	may delete data in console widget
-## 
-proc ::tkcon::ConstrainBuffer {w size} {
-    if {$size && ([$w index end] > $size)} {
-	$w delete 1.0 [expr {int([$w index end])-$size}].0
-    }
-}
-
-## ::tkcon::Prompt - displays the prompt in the console widget
-# ARGS:	w	- console text widget
-# Outputs:	prompt (specified in ::tkcon::OPT(prompt1)) to console
-## 
-proc ::tkcon::Prompt {{pre {}} {post {}} {prompt {}}} {
-    variable OPT
-    variable PRIV
-
-    set w $PRIV(console)
-    if {![winfo exists $w]} { return }
-    if {[string compare {} $pre]} { $w insert end $pre stdout }
-    set i [$w index end-1c]
-    if {!$OPT(showstatusbar)} {
-	if {[string compare {} $PRIV(appname)]} {
-	    $w insert end ">$PRIV(appname)< " prompt
-	}
-	if {[string compare :: $PRIV(namesp)]} {
-	    $w insert end "<$PRIV(namesp)> " prompt
-	}
-    }
-    if {[string compare {} $prompt]} {
-	$w insert end $prompt prompt
-    } else {
-	$w insert end [EvalSlave subst $OPT(prompt1)] prompt
-    }
-    $w mark set output $i
-    $w mark set insert end
-    $w mark set limit insert
-    $w mark gravity limit left
-    if {[string compare {} $post]} { $w insert end $post stdin }
-    ConstrainBuffer $w $OPT(buffer)
-    set ::tkcon::PRIV(StatusCursor) [$w index insert]
-    $w see end
-}
-proc ::tkcon::RePrompt {{pre {}} {post {}} {prompt {}}} {
-    # same as prompt, but does nothing for those actions where we
-    # only wanted to refresh the prompt on attach change when the
-    # statusbar is showing (which carries that info instead)
-    variable OPT
-    if {!$OPT(showstatusbar)} {
-	Prompt $pre $post $prompt
-    }
-}
-
-## ::tkcon::About - gives about info for tkcon
-## 
-proc ::tkcon::About {} {
-    variable OPT
-    variable PRIV
-    variable COLOR
-
-    set w $PRIV(base).about
-    if {![winfo exists $w]} {
-	global tk_patchLevel tcl_patchLevel tcl_version
-	toplevel $w
-	wm withdraw $w
-	wm transient $w $PRIV(root)
-	wm group $w $PRIV(root)
-	wm title $w "About tkcon v$PRIV(version)"
-	wm resizable $w 0 0
-	button $w.b -text Dismiss -command [list wm withdraw $w]
-	text $w.text -height 9 -width 60 \
-		-foreground $COLOR(stdin) \
-		-background $COLOR(bg) \
-		-font $OPT(font) -borderwidth 1 -highlightthickness 0
-	grid $w.text -sticky news
-	grid $w.b -sticky se -padx 6 -pady 4
-	$w.text tag config center -justify center
-	$w.text tag config title -justify center -font {Courier -18 bold}
-	# strip down the RCS info displayed in the about box
-	regexp {,v ([0-9\./: ]*)} $PRIV(RCS) -> RCS
-	$w.text insert 1.0 "About tkcon v$PRIV(version)" title \
-		"\n\nCopyright 1995-2002 Jeffrey Hobbs, $PRIV(email)\
-		\nRelease Info: v$PRIV(version), CVS v$RCS\
-		\nDocumentation available at:\n$PRIV(docs)\
-		\nUsing: Tcl v$tcl_patchLevel / Tk v$tk_patchLevel" center
-	$w.text config -state disabled
-	bind $w <Escape> [list destroy $w]
-    }
-    wm deiconify $w
-}
-
-## ::tkcon::InitMenus - inits the menubar and popup for the console
-# ARGS:	w	- console text widget
-## 
-proc ::tkcon::InitMenus {w title} {
-    variable OPT
-    variable PRIV
-    variable COLOR
-    global tcl_platform
-
-    if {[catch {menu $w.pop}]} {
-	label $w.label -text "Menus not available in plugin mode"
-	grid $w.label -sticky ew
-	return
-    }
-    menu $w.context -disabledforeground $COLOR(disabled)
-    set PRIV(context) $w.context
-    set PRIV(popup) $w.pop
-
-    proc MenuButton {w m l} {
-	$w add cascade -label $m -underline 0 -menu $w.$l
-	return $w.$l
-    }
-    proc MenuConfigure {m l args} {
-	variable PRIV
-	eval [list $PRIV(menubar).[string tolower $m] entryconfigure $l] $args
-	eval [list $PRIV(popup).[string tolower $m] entryconfigure $l] $args
-    }
-
-    foreach m [list File Console Edit Interp Prefs History Help] {
- 	set l [string tolower $m]
- 	MenuButton $w $m $l
- 	$w.pop add cascade -label $m -underline 0 -menu $w.pop.$l
-    }
-
-    ## File Menu
-    ##
-    foreach m [list [menu $w.file -disabledforeground $COLOR(disabled)] \
-	    [menu $w.pop.file -disabledforeground $COLOR(disabled)]] {
-	$m add command -label "Load File" -underline 0 -command ::tkcon::Load
-	$m add cascade -label "Save ..."  -underline 0 -menu $m.save
-	$m add separator
-	$m add command -label "Quit" -underline 0 -accel Ctrl-q -command exit
-
-	## Save Menu
-	##
-	set s $m.save
-	menu $s -disabledforeground $COLOR(disabled)
-	$s add command -label "All"	-underline 0 \
-		-command {::tkcon::Save {} all}
-	$s add command -label "History"	-underline 0 \
-		-command {::tkcon::Save {} history}
-	$s add command -label "Stdin"	-underline 3 \
-		-command {::tkcon::Save {} stdin}
-	$s add command -label "Stdout"	-underline 3 \
-		-command {::tkcon::Save {} stdout}
-	$s add command -label "Stderr"	-underline 3 \
-		-command {::tkcon::Save {} stderr}
-    }
-
-    ## Console Menu
-    ##
-    foreach m [list [menu $w.console -disabledfore $COLOR(disabled)] \
-	    [menu $w.pop.console -disabledfore $COLOR(disabled)]] {
-	$m add command -label "$title Console"	-state disabled
-	$m add command -label "New Console"	-underline 0 -accel Ctrl-N \
-		-command ::tkcon::New
-	$m add command -label "New Tab"		-underline 4 -accel Ctrl-T \
-		-command ::tkcon::NewTab
-	$m add command -label "Delete Tab"	-underline 0 \
-		-command ::tkcon::DeleteTab -state disabled
-	$m add command -label "Close Console"	-underline 0 -accel Ctrl-w \
-		-command ::tkcon::Destroy
-	$m add command -label "Clear Console"	-underline 1 -accel Ctrl-l \
-		-command { clear; ::tkcon::Prompt }
-	if {[string match unix $tcl_platform(platform)]} {
-	    $m add separator
-	    $m add command -label "Make Xauth Secure" -und 5 \
-		    -command ::tkcon::XauthSecure
-	}
-	$m add separator
-	$m add cascade -label "Attach To ..." -underline 0 -menu $m.attach
-
-	## Attach Console Menu
-	##
-	set sub [menu $m.attach -disabledforeground $COLOR(disabled)]
-	$sub add cascade -label "Interpreter" -underline 0 -menu $sub.apps
-	$sub add cascade -label "Namespace"   -underline 0 -menu $sub.name
-
-	## Attach Console Menu
-	##
-	menu $sub.apps -disabledforeground $COLOR(disabled) \
-		-postcommand [list ::tkcon::AttachMenu $sub.apps]
-
-	## Attach Namespace Menu
-	##
-	menu $sub.name -disabledforeground $COLOR(disabled) \
-		-postcommand [list ::tkcon::NamespaceMenu $sub.name]
-
-	if {$::tcl_version >= 8.3} {
-	    ## Attach Socket Menu
-	    ##
-	    # This uses [file channels] to create the menu, so we only
-	    # want it for newer versions of Tcl.
-	    $sub add cascade -label "Socket" -underline 0 -menu $sub.sock
-	    menu $sub.sock -disabledforeground $COLOR(disabled) \
-		    -postcommand [list ::tkcon::SocketMenu $sub.sock]
-	}
-
-	if {![string compare "unix" $tcl_platform(platform)]} {
-	    ## Attach Display Menu
-	    ##
-	    $sub add cascade -label "Display" -underline 0 -menu $sub.disp
-	    menu $sub.disp -disabledforeground $COLOR(disabled) \
-		    -postcommand [list ::tkcon::DisplayMenu $sub.disp]
-	}
-    }
-
-    ## Edit Menu
-    ##
-    set text $PRIV(console)
-    foreach m [list [menu $w.edit] [menu $w.pop.edit]] {
-	$m add command -label "Cut"   -underline 2 -accel Ctrl-x \
-		-command [list ::tkcon::Cut $text]
-	$m add command -label "Copy"  -underline 0 -accel Ctrl-c \
-		-command [list ::tkcon::Copy $text]
-	$m add command -label "Paste" -underline 0 -accel Ctrl-v \
-		 -command [list ::tkcon::Paste $text]
-	$m add separator
-	$m add command -label "Find"  -underline 0 -accel Ctrl-F \
-		-command [list ::tkcon::FindBox $text]
-    }
-
-    ## Interp Menu
-    ##
-    foreach m [list $w.interp $w.pop.interp] {
-	menu $m -disabledforeground $COLOR(disabled) \
-		-postcommand [list ::tkcon::InterpMenu $m]
-    }
-
-    ## Prefs Menu
-    ##
-    foreach m [list [menu $w.prefs] [menu $w.pop.prefs]] {
-	$m add check -label "Brace Highlighting" \
-		-underline 0 -variable ::tkcon::OPT(lightbrace)
-	$m add check -label "Command Highlighting" \
-		-underline 0 -variable ::tkcon::OPT(lightcmd)
-	$m add check -label "History Substitution" \
-		-underline 0 -variable ::tkcon::OPT(subhistory)
-	$m add check -label "Hot Errors" \
-		-underline 4 -variable ::tkcon::OPT(hoterrors)
-	$m add check -label "Non-Tcl Attachments" \
-		-underline 0 -variable ::tkcon::OPT(nontcl)
-	$m add check -label "Calculator Mode" \
-		-underline 1 -variable ::tkcon::OPT(calcmode)
-	$m add check -label "Show Multiple Matches" \
-		-underline 0 -variable ::tkcon::OPT(showmultiple)
-	$m add check -label "Show Menubar" \
-		-underline 5 -variable ::tkcon::OPT(showmenu) \
-		-command {$::tkcon::PRIV(root) configure -menu [expr \
-		{$::tkcon::OPT(showmenu) ? $::tkcon::PRIV(menubar) : {}}]}
-	$m add check -label "Show Statusbar" \
-	    -underline 5 -variable ::tkcon::OPT(showstatusbar) \
-	    -command {
-		if {$::tkcon::OPT(showstatusbar)} {
-		    grid $::tkcon::PRIV(statusbar)
-		} else { grid remove $::tkcon::PRIV(statusbar) }
-	    }
-	$m add cascade -label "Scrollbar" -underline 2 -menu $m.scroll
-
-	## Scrollbar Menu
-	##
-	set m [menu $m.scroll]
-	$m add radio -label "Left" -value left \
-		-variable ::tkcon::OPT(scrollypos) \
-		-command { grid configure $::tkcon::PRIV(scrolly) -column 0 }
-	$m add radio -label "Right" -value right \
-		-variable ::tkcon::OPT(scrollypos) \
-		-command { grid configure $::tkcon::PRIV(scrolly) -column 2 }
-    }
-
-    ## History Menu
-    ##
-    foreach m [list $w.history $w.pop.history] {
-	menu $m -disabledforeground $COLOR(disabled) \
-		-postcommand [list ::tkcon::HistoryMenu $m]
-    }
-
-    ## Help Menu
-    ##
-    foreach m [list [menu $w.help] [menu $w.pop.help]] {
-	$m add command -label "About " -underline 0 -accel Ctrl-A \
-		-command ::tkcon::About
-	$m add command -label "Retrieve Latest Version" -underline 0 \
-		-command ::tkcon::Retrieve
-	if {![catch {package require ActiveTcl} ver]} {
-	    set cmd ""
-	    if {$tcl_platform(platform) == "windows"} {
-		package require registry
-		set ver [join [lrange [split $ver .] 0 3] .]
-		set key {HKEY_LOCAL_MACHINE\SOFTWARE\ActiveState\ActiveTcl}
-		if {![catch {registry get "$key\\$ver\\Help" ""} help]
-		    && [file exists $help]} {
-		    set cmd [list exec $::env(COMSPEC) /c start {} $help]
-		}
-	    } elseif {$tcl_platform(os) == "Darwin"} {
-		set ver ActiveTcl-[join [lrange [split $ver .] 0 1] .]
-		set rsc "/Library/Frameworks/Tcl.framework/Resources"
-		set help "$rsc/English.lproj/$ver/index.html"
-		if {[file exists $help]} {
-		    set cmd [list exec open $help]
-		}
-	    } elseif {$tcl_platform(platform) == "unix"} {
-		set help [file dirname [info nameofexe]]
-		append help /../html/index.html
-		if {[file exists $help]} {
-		    set cmd [list puts "Start $help"]
-		}
-	    }
-	    if {$cmd != ""} {
-		$m add separator
-		$m add command -label "ActiveTcl Help" -underline 10 \
-		    -command $cmd
-	    }
-	}
-    }
-}
-
-## ::tkcon::HistoryMenu - dynamically build the menu for attached interpreters
-##
-# ARGS:	m	- menu widget
-##
-proc ::tkcon::HistoryMenu m {
-    variable PRIV
-
-    if {![winfo exists $m]} return
-    set id [EvalSlave history nextid]
-    if {$PRIV(histid)==$id} return
-    set PRIV(histid) $id
-    $m delete 0 end
-    while {($id>1) && ($id>$PRIV(histid)-10) && \
-	    ![catch {EvalSlave history event [incr id -1]} tmp]} {
-	set lbl $tmp
-	if {[string len $lbl]>32} { set lbl [string range $tmp 0 28]... }
-	$m add command -label "$id: $lbl" -command "
-	$::tkcon::PRIV(console) delete limit end
-	$::tkcon::PRIV(console) insert limit [list $tmp]
-	$::tkcon::PRIV(console) see end
-	::tkcon::Eval $::tkcon::PRIV(console)"
-    }
-}
-
-## ::tkcon::InterpMenu - dynamically build the menu for attached interpreters
-##
-# ARGS:	w	- menu widget
-##
-proc ::tkcon::InterpMenu w {
-    variable OPT
-    variable PRIV
-    variable COLOR
-
-    if {![winfo exists $w]} return
-    $w delete 0 end
-    foreach {app type} [Attach] break
-    $w add command -label "[string toupper $type]: $app" -state disabled
-    if {($OPT(nontcl) && [string match interp $type]) || $PRIV(deadapp)} {
-	$w add separator
-	$w add command -state disabled -label "Communication disabled to"
-	$w add command -state disabled -label "dead or non-Tcl interps"
-	return
-    }
-
-    ## Show Last Error
-    ##
-    $w add separator
-    $w add command -label "Show Last Error" \
-	    -command [list tkcon error $app $type]
-
-    ## Packages Cascaded Menu
-    ##
-    $w add separator
-    $w add command -label "Manage Packages" -underline 0 \
-	-command [list ::tkcon::InterpPkgs $app $type]
-
-    ## State Checkpoint/Revert
-    ##
-    $w add separator
-    $w add command -label "Checkpoint State" \
-	    -command [list ::tkcon::StateCheckpoint $app $type]
-    $w add command -label "Revert State" \
-	    -command [list ::tkcon::StateRevert $app $type]
-    $w add command -label "View State Change" \
-	    -command [list ::tkcon::StateCompare $app $type]
-
-    ## Init Interp
-    ##
-    $w add separator
-    $w add command -label "Send tkcon Commands" \
-	    -command [list ::tkcon::InitInterp $app $type]
-}
-
-## ::tkcon::PkgMenu - fill in  in the applications sub-menu
-## with a list of all the applications that currently exist.
-##
-proc ::tkcon::InterpPkgs {app type} {
-    variable PRIV
-
-    set t $PRIV(base).interppkgs
-    if {![winfo exists $t]} {
-	toplevel $t
-	wm withdraw $t
-	wm title $t "$app Packages"
-	wm transient $t $PRIV(root)
-	wm group $t $PRIV(root)
-	bind $t <Escape> [list destroy $t]
-
-	label $t.ll -text "Loadable:" -anchor w
-	label $t.lr -text "Loaded:" -anchor w
-	listbox $t.loadable -font tkconfixed -background white -borderwidth 1 \
-	    -yscrollcommand [list $t.llsy set] -selectmode extended
-	listbox $t.loaded -font tkconfixed -background white -borderwidth 1 \
-	    -yscrollcommand [list $t.lrsy set]
-	scrollbar $t.llsy -command [list $t.loadable yview]
-	scrollbar $t.lrsy -command [list $t.loaded yview]
-	button $t.load -borderwidth 1 -text ">>" \
-	    -command [list ::tkcon::InterpPkgLoad $app $type $t.loadable]
-	if {$::tcl_version >= 8.4} {
-	    $t.load configure -relief flat -overrelief raised
-	}
-
-	set f [frame $t.btns]
-	button $f.refresh -width 8 -text "Refresh" -command [info level 0]
-	button $f.dismiss -width 8 -text "Dismiss" -command [list destroy $t]
-	grid $f.refresh $f.dismiss -padx 4 -pady 3 -sticky ew
-
-	grid $t.ll x x $t.lr x -sticky ew
-	grid $t.loadable $t.llsy $t.load $t.loaded $t.lrsy -sticky news
-	grid $t.btns -sticky e -columnspan 5
-	grid columnconfigure $t {0 3} -weight 1
-	grid rowconfigure $t 1 -weight 1
-	grid configure $t.load -sticky ""
-
-	bind $t.loadable <Double-1> "[list $t.load invoke]; break"
-    }
-    $t.loaded delete 0 end
-    $t.loadable delete 0 end
-
-    # just in case stuff has been added to the auto_path
-    # we have to make sure that the errorInfo doesn't get screwed up
-    EvalAttached {
-	set __tkcon_error $errorInfo
-	catch {package require bogus-package-name}
-	set errorInfo ${__tkcon_error}
-	unset __tkcon_error
-    }
-    # get all packages loaded into current interp
-    foreach pkg [EvalAttached [list info loaded {}]] {
-	set pkg [lindex $pkg 1]
-	set loaded($pkg) [package provide $pkg]
-    }
-    # get all package names currently visible
-    foreach pkg [lremove [EvalAttached {package names}] Tcl] {
-	set version [EvalAttached [list package provide $pkg]]
-	if {[string compare {} $version]} {
-	    set loaded($pkg) $version
-	} elseif {![info exists loaded($pkg)]} {
-	    set loadable($pkg) package
-	}
-    }
-    # get packages that are loaded in any interp
-    foreach pkg [EvalAttached {info loaded}] {
-	set pkg [lindex $pkg 1]
-	if {![info exists loaded($pkg)] && ![info exists loadable($pkg)]} {
-	    set loadable($pkg) load
-	}
-    }
-    foreach pkg [lsort -dictionary [array names loadable]] {
-	foreach v [EvalAttached [list package version $pkg]] {
-	    $t.loadable insert end [list $pkg $v "($loadable($pkg))"]
-	}
-    }
-    foreach pkg [lsort -dictionary [array names loaded]] {
-	$t.loaded insert end [list $pkg $loaded($pkg)]
-    }
-
-    wm deiconify $t
-    raise $t
-}
-
-proc ::tkcon::InterpPkgLoad {app type lb} {
-    # load the lb entry items into the interp
-    foreach sel [$lb curselection] {
-	foreach {pkg ver method} [$lb get $sel] { break }
-	if {$method == "(package)"} {
-	    set code [catch {::tkcon::EvalOther $app $type \
-				 package require $pkg $ver} msg]
-	} elseif {$method == "(load)"} {
-	    set code [catch {::tkcon::EvalOther $app $type load {} $pkg} msg]
-	} else {
-	    set code 1
-	    set msg "Incorrect entry in Loadable selection"
-	}
-	if {$code} {
-	    tk_messageBox -icon error -title "Error requiring $pkg" -type ok \
-		-message "Error requiring $pkg $ver:\n$msg\n$::errorInfo"
-	}
-    }
-    # refresh package list
-    InterpPkgs $app $type
-}
-
-## ::tkcon::AttachMenu - fill in  in the applications sub-menu
-## with a list of all the applications that currently exist.
-##
-proc ::tkcon::AttachMenu m {
-    variable OPT
-    variable PRIV
-
-    array set interps [set tmp [Interps]]
-    foreach {i j} $tmp { set tknames($j) {} }
-
-    $m delete 0 end
-    set cmd {::tkcon::RePrompt \n [::tkcon::CmdGet $::tkcon::PRIV(console)]}
-    $m add radio -label {None (use local slave) } -accel Ctrl-1 \
-	    -variable ::tkcon::PRIV(app) \
-	    -value [concat $::tkcon::PRIV(name) $::tkcon::OPT(exec)] \
-	    -command "::tkcon::Attach {}; $cmd"
-    $m add separator
-    $m add command -label "Foreign Tk Interpreters" -state disabled
-    foreach i [lsort [lremove [::send::interps] [array names tknames]]] {
-	$m add radio -label $i -variable ::tkcon::PRIV(app) -value $i \
-		-command "::tkcon::Attach [list $i] interp; $cmd"
-    }
-    $m add separator
-
-    $m add command -label "tkcon Interpreters" -state disabled
-    foreach i [lsort [array names interps]] {
-	if {[string match {} $interps($i)]} { set interps($i) "no Tk" }
-	if {[regexp {^Slave[0-9]+} $i]} {
-	    set opts [list -label "$i ($interps($i))" \
-		    -variable ::tkcon::PRIV(app) -value $i \
-		    -command "::tkcon::Attach [list $i] slave; $cmd"]
-	    if {[string match $PRIV(name) $i]} {
-		append opts " -accel Ctrl-2"
-	    }
-	    eval $m add radio $opts
-	} else {
-	    set name [concat Main $i]
-	    if {[string match Main $name]} {
-		$m add radio -label "$name ($interps($i))" -accel Ctrl-3 \
-			-variable ::tkcon::PRIV(app) -value Main \
-			-command "::tkcon::Attach [list $name] slave; $cmd"
-	    } else {
-		$m add radio -label "$name ($interps($i))" \
-			-variable ::tkcon::PRIV(app) -value $i \
-			-command "::tkcon::Attach [list $name] slave; $cmd"
-	    }
-	}
-    }
-}
-
-## Displays Cascaded Menu
-##
-proc ::tkcon::DisplayMenu m {
-    $m delete 0 end
-    set cmd {::tkcon::RePrompt \n [::tkcon::CmdGet $::tkcon::PRIV(console)]}
-
-    $m add command -label "New Display" -command ::tkcon::NewDisplay
-    foreach disp [Display] {
-	$m add separator
-	$m add command -label $disp -state disabled
-	set res [Display $disp]
-	set win [lindex $res 0]
-	foreach i [lsort [lindex $res 1]] {
-	    $m add radio -label $i -variable ::tkcon::PRIV(app) -value $i \
-		    -command "::tkcon::Attach [list $i] [list dpy:$win]; $cmd"
-	}
-    }
-}
-
-## Sockets Cascaded Menu
-##
-proc ::tkcon::SocketMenu m {
-    $m delete 0 end
-    set cmd {::tkcon::RePrompt \n [::tkcon::CmdGet $::tkcon::PRIV(console)]}
-
-    $m add command -label "Create Connection" \
-	    -command "::tkcon::NewSocket; $cmd"
-    foreach sock [file channels sock*] {
-	$m add radio -label $sock -variable ::tkcon::PRIV(app) -value $sock \
-		-command "::tkcon::Attach $sock socket; $cmd"
-    }
-}
-
-## Namepaces Cascaded Menu
-##
-proc ::tkcon::NamespaceMenu m {
-    variable PRIV
-    variable OPT
-
-    $m delete 0 end
-    if {($PRIV(deadapp) || [string match socket $PRIV(apptype)] || \
-	    ($OPT(nontcl) && [string match interp $PRIV(apptype)]))} {
-	$m add command -label "No Namespaces" -state disabled
-	return
-    }
-
-    ## Same command as for ::tkcon::AttachMenu items
-    set cmd {::tkcon::RePrompt \n [::tkcon::CmdGet $::tkcon::PRIV(console)]}
-
-    set names [lsort [Namespaces ::]]
-    if {[llength $names] > $OPT(maxmenu)} {
-	$m add command -label "Attached to $PRIV(namesp)" -state disabled
-	$m add command -label "List Namespaces" \
-		-command [list ::tkcon::NamespacesList $names]
-    } else {
-	foreach i $names {
-	    if {[string match :: $i]} {
-		$m add radio -label "Main" -value $i \
-			-variable ::tkcon::PRIV(namesp) \
-			-command "::tkcon::AttachNamespace [list $i]; $cmd"
-	    } else {
-		$m add radio -label $i -value $i \
-			-variable ::tkcon::PRIV(namesp) \
-			-command "::tkcon::AttachNamespace [list $i]; $cmd"
-	    }
-	}
-    }
-}
-
-## Namepaces List 
-##
-proc ::tkcon::NamespacesList {names} {
-    variable PRIV
-
-    set f $PRIV(base).namespaces
-    catch {destroy $f}
-    toplevel $f
-    listbox $f.names -width 30 -height 15 -selectmode single \
-	-yscrollcommand [list $f.scrollv set] \
-	-xscrollcommand [list $f.scrollh set] \
-	-background white -borderwidth 1
-    scrollbar $f.scrollv -command [list $f.names yview]
-    scrollbar $f.scrollh -command [list $f.names xview] -orient horizontal
-    frame $f.buttons
-    button $f.cancel -text "Cancel" -command [list destroy $f]
-
-    grid $f.names $f.scrollv -sticky nesw
-    grid $f.scrollh -sticky ew
-    grid $f.buttons -sticky nesw
-    grid $f.cancel -in $f.buttons -pady 6
-
-    grid columnconfigure $f 0 -weight 1
-    grid rowconfigure $f  0 -weight 1
-    #fill the listbox
-    foreach i $names {
-	if {[string match :: $i]} {
-	    $f.names insert 0 Main
-	} else {
-	    $f.names insert end $i
-	}
-    }
-    #Bindings
-    bind $f.names <Double-1> {
-	## Catch in case the namespace disappeared on us
-	catch { ::tkcon::AttachNamespace [%W get [%W nearest %y]] }
-	::tkcon::RePrompt "\n" [::tkcon::CmdGet $::tkcon::PRIV(console)]
-	destroy [winfo toplevel %W]
-    }
-}
-
-# ::tkcon::XauthSecure --
-#
-#   This removes all the names in the xhost list, and secures
-#   the display for Tk send commands.  Of course, this prevents
-#   what might have been otherwise allowable X connections
-#
-# Arguments:
-#   none
-# Results:
-#   Returns nothing
-#
-proc ::tkcon::XauthSecure {} {
-    global tcl_platform
-
-    if {[string compare unix $tcl_platform(platform)]} {
-	# This makes no sense outside of Unix
-	return
-    }
-    set hosts [exec xhost]
-    # the first line is info only
-    foreach host [lrange [split $hosts \n] 1 end] {
-	exec xhost -$host
-    }
-    exec xhost -
-    tk_messageBox -title "Xhost secured" -message "Xhost secured" -icon info
-}
-
-## ::tkcon::FindBox - creates minimal dialog interface to ::tkcon::Find
-# ARGS:	w	- text widget
-#	str	- optional seed string for ::tkcon::PRIV(find)
-##
-proc ::tkcon::FindBox {w {str {}}} {
-    variable PRIV
-
-    set base $PRIV(base).find
-    if {![winfo exists $base]} {
-	toplevel $base
-	wm withdraw $base
-	wm title $base "tkcon Find"
-
-	pack [frame $base.f] -fill x -expand 1
-	label $base.f.l -text "Find:"
-	entry $base.f.e -textvariable ::tkcon::PRIV(find)
-	pack [frame $base.opt] -fill x
-	checkbutton $base.opt.c -text "Case Sensitive" \
-		-variable ::tkcon::PRIV(find,case)
-	checkbutton $base.opt.r -text "Use Regexp" \
-	    -variable ::tkcon::PRIV(find,reg)
-	pack $base.f.l -side left
-	pack $base.f.e $base.opt.c $base.opt.r -side left -fill both -expand 1
-	pack [frame $base.sep -borderwidth 2 -relief sunken -height 4] -fill x
-	pack [frame $base.btn] -fill both
-	button $base.btn.fnd -text "Find" -width 6
-	button $base.btn.clr -text "Clear" -width 6
-	button $base.btn.dis -text "Dismiss" -width 6
-	eval pack [winfo children $base.btn] -padx 4 -pady 2 \
-		-side left -fill both
-
-	focus $base.f.e
-
-	bind $base.f.e <Return> [list $base.btn.fnd invoke]
-	bind $base.f.e <Escape> [list $base.btn.dis invoke]
-    }
-    $base.btn.fnd config -command "::tkcon::Find [list $w] \$::tkcon::PRIV(find) \
-	    -case \$::tkcon::PRIV(find,case) -reg \$::tkcon::PRIV(find,reg)"
-    $base.btn.clr config -command "
-    [list $w] tag remove find 1.0 end
-    set ::tkcon::PRIV(find) {}
-    "
-    $base.btn.dis config -command "
-    [list $w] tag remove find 1.0 end
-    wm withdraw [list $base]
-    "
-    if {[string compare {} $str]} {
-	set PRIV(find) $str
-	$base.btn.fnd invoke
-    }
-
-    if {[string compare normal [wm state $base]]} {
-	wm deiconify $base
-    } else { raise $base }
-    $base.f.e select range 0 end
-}
-
-## ::tkcon::Find - searches in text widget $w for $str and highlights it
-## If $str is empty, it just deletes any highlighting
-# ARGS: w	- text widget
-#	str	- string to search for
-#	-case	TCL_BOOLEAN	whether to be case sensitive	DEFAULT: 0
-#	-regexp	TCL_BOOLEAN	whether to use $str as pattern	DEFAULT: 0
-##
-proc ::tkcon::Find {w str args} {
-    $w tag remove find 1.0 end
-    set truth {^(1|yes|true|on)$}
-    set opts  {}
-    foreach {key val} $args {
-	switch -glob -- $key {
-	    -c* { if {[regexp -nocase $truth $val]} { set case 1 } }
-	    -r* { if {[regexp -nocase $truth $val]} { lappend opts -regexp } }
-	    default { return -code error "Unknown option $key" }
-	}
-    }
-    if {![info exists case]} { lappend opts -nocase }
-    if {[string match {} $str]} return
-    $w mark set findmark 1.0
-    while {[string compare {} [set ix [eval $w search $opts -count numc -- \
-	    [list $str] findmark end]]]} {
-	$w tag add find $ix ${ix}+${numc}c
-	$w mark set findmark ${ix}+1c
-    }
-    $w tag configure find -background $::tkcon::COLOR(blink)
-    catch {$w see find.first}
-    return [expr {[llength [$w tag ranges find]]/2}]
-}
-
-## ::tkcon::Attach - called to attach tkcon to an interpreter
-# ARGS:	name	- application name to which tkcon sends commands
-#		  This is either a slave interperter name or tk appname.
-#	type	- (slave|interp) type of interpreter we're attaching to
-#		  slave means it's a tkcon interpreter
-#		  interp means we'll need to 'send' to it.
-# Results:	::tkcon::EvalAttached is recreated to evaluate in the
-#		appropriate interpreter
-##
-proc ::tkcon::Attach {{name <NONE>} {type slave} {ns {}}} {
-    variable PRIV
-    variable OPT
-    variable ATTACH
-
-    if {[llength [info level 0]] == 1} {
-	# no args were specified, return the attach info instead
-	return [AttachId]
-    }
-    set path [concat $PRIV(name) $OPT(exec)]
-
-    set PRIV(displayWin) .
-    if {[string match namespace $type]} {
-	return [uplevel 1 ::tkcon::AttachNamespace $name]
-    } elseif {[string match dpy:* $type]} {
-	set PRIV(displayWin) [string range $type 4 end]
-    } elseif {[string match sock* $type]} {
-	global tcl_version
-	if {[catch {eof $name} res]} {
-	    return -code error "No known channel \"$name\""
-	} elseif {$res} {
-	    catch {close $name}
-	    return -code error "Channel \"$name\" returned EOF"
-	}
-	set app $name
-	set type socket
-    } elseif {[string compare {} $name]} {
-	array set interps [Interps]
-	if {[string match {[Mm]ain} [lindex $name 0]]} {
-	    set name [lrange $name 1 end]
-	}
-	if {[string match $path $name]} {
-	    set name {}
-	    set app $path
-	    set type slave
-	} elseif {[info exists interps($name)]} {
-	    if {[string match {} $name]} { set name Main; set app Main }
-	    set type slave
-	} elseif {[interp exists $name]} {
-	    set name [concat $PRIV(name) $name]
-	    set type slave
-	} elseif {[interp exists [concat $OPT(exec) $name]]} {
-	    set name [concat $path $name]
-	    set type slave
-	} elseif {[lsearch -exact [::send::interps] $name] > -1} {
-	    if {[EvalSlave info exists tk_library] \
-		    && [string match $name [EvalSlave tk appname]]} {
-		set name {}
-		set app $path
-		set type slave
-	    } elseif {[set i [lsearch -exact \
-		    [Main set ::tkcon::PRIV(interps)] $name]] != -1} {
-		set name [lindex [Main set ::tkcon::PRIV(slaves)] $i]
-		if {[string match {[Mm]ain} $name]} { set app Main }
-		set type slave
-	    } else {
-		set type interp
-	    }
-	} else {
-	    return -code error "No known interpreter \"$name\""
-	}
-    } else {
-	set app $path
-    }
-    if {![info exists app]} { set app $name }
-    array set PRIV [list app $app appname $name apptype $type deadapp 0]
-
-    ## ::tkcon::EvalAttached - evaluates the args in the attached interp
-    ## args should be passed to this procedure as if they were being
-    ## passed to the 'eval' procedure.  This procedure is dynamic to
-    ## ensure evaluation occurs in the right interp.
-    # ARGS:	args	- the command and args to evaluate
-    ##
-    set PRIV(namesp) ::
-    set namespOK 0
-    switch -glob -- $type {
-	slave {
-	    if {[string match {} $name]} {
-		interp alias {} ::tkcon::EvalAttached {} \
-			::tkcon::EvalSlave uplevel \#0
-	    } elseif {[string match Main $PRIV(app)]} {
-		interp alias {} ::tkcon::EvalAttached {} ::tkcon::Main
-	    } elseif {[string match $PRIV(name) $PRIV(app)]} {
-		interp alias {} ::tkcon::EvalAttached {} uplevel \#0
-	    } else {
-		interp alias {} ::tkcon::EvalAttached {} \
-			::tkcon::Slave $::tkcon::PRIV(app)
-	    }
-	    set namespOK 1
-	}
-	sock* {
-	    interp alias {} ::tkcon::EvalAttached {} \
-		    ::tkcon::EvalSlave uplevel \#0
-	    # The file event will just puts whatever data is found
-	    # into the interpreter
-	    fconfigure $name -buffering line -blocking 0
-	    fileevent $name readable [list ::tkcon::EvalSocketEvent $name]
-	}
-	dpy:* -
-	interp {
-	    if {$OPT(nontcl)} {
-		interp alias {} ::tkcon::EvalAttached {} ::tkcon::EvalSlave
-	    } else {
-		interp alias {} ::tkcon::EvalAttached {} ::tkcon::EvalSend
-		set namespOK 1
-	    }
-	}
-	default {
-	    return -code error "[lindex [info level 0] 0] did not specify\
-		    a valid type: must be slave or interp"
-	}
-    }
-    if {![string match {} $ns] && $namespOK} {
-	AttachNamespace $ns
-    }
-    return [AttachId]
-}
-
-proc ::tkcon::AttachId {} {
-    # return Attach info in a form that Attach accepts again
-    variable PRIV
-
-    if {[string match {} $PRIV(appname)]} {
-	variable OPT
-	set appname [concat $PRIV(name) $OPT(exec)]
-    } else {
-	set appname $PRIV(appname)
-    }
-    set id [list $appname $PRIV(apptype)]
-    # only display ns info if it isn't "::" as that is what is also
-    # used to indicate no eval in namespace
-    if {![string match :: $PRIV(namesp)]} { lappend id $PRIV(namesp) }
-    if {[info exists PRIV(console)]} {
-	variable ATTACH
-	set ATTACH($PRIV(console)) $id
-    }
-    return $id
-}
-
-## ::tkcon::AttachNamespace - called to attach tkcon to a namespace
-# ARGS:	name	- namespace name in which tkcon should eval commands
-# Results:	::tkcon::EvalAttached will be modified
-##
-proc ::tkcon::AttachNamespace { name } {
-    variable PRIV
-    variable OPT
-
-    # We could enable 'socket' bound Tcl interps, but we'd have to create
-    # a return listening socket
-    if {($OPT(nontcl) && [string match interp $PRIV(apptype)]) \
-	    || [string match socket $PRIV(apptype)] \
-	    || $PRIV(deadapp)} {
-	return -code error "can't attach to namespace in attached environment"
-    }
-    if {[string match Main $name]} {set name ::}
-    if {[string compare {} $name] && \
-	    [lsearch [Namespaces ::] $name] == -1} {
-	return -code error "No known namespace \"$name\""
-    }
-    if {[regexp {^(|::)$} $name]} {
-	## If name=={} || ::, we want the primary namespace
-	set alias [interp alias {} ::tkcon::EvalAttached]
-	if {[string match ::tkcon::EvalNamespace* $alias]} {
-	    eval [list interp alias {} ::tkcon::EvalAttached {}] \
-		    [lindex $alias 1]
-	}
-	set name ::
-    } else {
-	interp alias {} ::tkcon::EvalAttached {} ::tkcon::EvalNamespace \
-		[interp alias {} ::tkcon::EvalAttached] [list $name]
-    }
-    set PRIV(namesp) $name
-    return [AttachId]
-}
-
-## ::tkcon::NewSocket - called to create a socket to connect to
-# ARGS:	none
-# Results:	It will create a socket, and attach if requested
-##
-proc ::tkcon::NewSocket {} {
-    variable PRIV
-
-    set t $PRIV(base).newsock
-    if {![winfo exists $t]} {
-	toplevel $t
-	wm withdraw $t
-	wm title $t "tkcon Create Socket"
-	label $t.lhost -text "Host: "
-	entry $t.host -width 16 -takefocus 1
-	label $t.lport -text "Port: "
-	entry $t.port -width 4 -takefocus 1
-	button $t.ok -text "OK" -command {set ::tkcon::PRIV(grab) 1} -width 4 \
-	    -takefocus 1
-	bind $t.host <Return> [list focus $t.port]
-	bind $t.port <Return> [list focus $t.ok]
-	bind $t.ok   <Return> [list $t.ok invoke]
-	grid $t.lhost $t.host $t.lport $t.port $t.ok -sticky ew
-	grid configure $t.ok -padx 4 -pady 2
-	grid columnconfig $t 1 -weight 1
-	grid rowconfigure $t 1 -weight 1
-	wm transient $t $PRIV(root)
-	wm group $t $PRIV(root)
-	wm geometry $t +[expr {([winfo screenwidth $t]-[winfo \
-		reqwidth $t]) / 2}]+[expr {([winfo \
-		screenheight $t]-[winfo reqheight $t]) / 2}]
-	bind $t <Escape> [list destroy $t]
-    }
-    #$t.host delete 0 end
-    #$t.port delete 0 end
-    wm deiconify $t
-    raise $t
-    grab $t
-    focus $t.host
-    vwait ::tkcon::PRIV(grab)
-    grab release $t
-    wm withdraw $t
-    set host [$t.host get]
-    set port [$t.port get]
-    if {$host == ""} { return }
-    if {[catch {
-	set sock [socket $host $port]
-    } err]} {
-	tk_messageBox -title "Socket Connection Error" \
-		-message "Unable to connect to \"$host:$port\":\n$err" \
-		-icon error -type ok
-    } else {
-	Attach $sock socket
-    }
-}
-
-## ::tkcon::Load - sources a file into the console
-## The file is actually sourced in the currently attached's interp
-# ARGS:	fn	- (optional) filename to source in
-# Returns:	selected filename ({} if nothing was selected)
-## 
-proc ::tkcon::Load { {fn ""} } {
-    set types {
-	{{Tcl Files}	{.tcl .tk}}
-	{{Text Files}	{.txt}}
-	{{All Files}	*}
-    }
-    # Allow for VFS directories, use Tk dialogs automatically when in
-    # VFS-based areas
-    set check [expr {$fn == "" ? [pwd] : $fn}]
-    if {$::tcl_version >= 8.4 && [lindex [file system $check] 0] == "tclvfs"} {
-	set opencmd [list ::tk::dialog::file:: open]
-    } else {
-	set opencmd [list tk_getOpenFile]
-    }
-    if {
-	[string match {} $fn] &&
-	([catch {tk_getOpenFile -filetypes $types \
-	    -title "Source File"} fn] || [string match {} $fn])
-    } { return }
-    EvalAttached [list source $fn]
-}
-
-## ::tkcon::Save - saves the console or other widget buffer to a file
-## This does not eval in a slave because it's not necessary
-# ARGS:	w	- console text widget
-# 	fn	- (optional) filename to save to
-## 
-proc ::tkcon::Save { {fn ""} {type ""} {opt ""} {mode w} } {
-    variable PRIV
-
-    if {![regexp -nocase {^(all|history|stdin|stdout|stderr|widget)$} $type]} {
-	array set s { 0 All 1 History 2 Stdin 3 Stdout 4 Stderr 5 Cancel }
-	## Allow user to specify what kind of stuff to save
-	set type [tk_dialog $PRIV(base).savetype "Save Type" \
-		"What part of the text do you want to save?" \
-		questhead 0 $s(0) $s(1) $s(2) $s(3) $s(4) $s(5)]
-	if {$type == 5 || $type == -1} return
-	set type $s($type)
-    }
-    # Allow for VFS directories, use Tk dialogs automatically when in
-    # VFS-based areas
-    set check [expr {$opt == "" ? [pwd] : $opt}]
-    if {$::tcl_version >= 8.4 && [lindex [file system $check] 0] == "tclvfs"} {
-	set savecmd [list ::tk::dialog::file:: save]
-    } else {
-	set savecmd [list tk_getSaveFile]
-    }
-    if {[string match {} $fn]} {
-	set types {
-	    {{Tcl Files}	{.tcl .tk}}
-	    {{Text Files}	{.txt}}
-	    {{All Files}	*}
-	}
-	if {[catch {eval $savecmd [list -defaultextension .tcl \
-				       -filetypes $types \
-				       -title "Save $type"]} fn]
-	     || [string match {} $fn]} return
-    }
-    set type [string tolower $type]
-    switch $type {
-	stdin -	stdout - stderr {
-	    set data {}
-	    foreach {first last} [$PRIV(console) tag ranges $type] {
-		lappend data [$PRIV(console) get $first $last]
-	    }
-	    set data [join $data \n]
-	}
-	history		{ set data [tkcon history] }
-	all - default	{ set data [$PRIV(console) get 1.0 end-1c] }
-	widget		{
-	    set data [$opt get 1.0 end-1c]
-	}
-    }
-    if {[catch {open $fn $mode} fid]} {
-	return -code error "Save Error: Unable to open '$fn' for writing\n$fid"
-    }
-    puts -nonewline $fid $data
-    close $fid
-}
-
-## ::tkcon::MainInit
-## This is only called for the main interpreter to include certain procs
-## that we don't want to include (or rather, just alias) in slave interps.
-##
-proc ::tkcon::MainInit {} {
-    variable PRIV
-    variable OPT
-
-    if {![info exists PRIV(slaves)]} {
-	array set PRIV [list slave 0 slaves Main name {} \
-		interps [list [tk appname]]]
-    }
-    interp alias {} ::tkcon::Main {} ::tkcon::InterpEval Main
-    interp alias {} ::tkcon::Slave {} ::tkcon::InterpEval
-
-    proc ::tkcon::GetSlave {{slave {}}} {
-	set i 0
-	while {[Slave $slave [list interp exists Slave[incr i]]]} {
-	    # oh my god, an empty loop!
-	}
-	set interp [Slave $slave [list interp create Slave$i]]
-	return $interp
-    }
-
-    ## ::tkcon::New - create new console window
-    ## Creates a slave interpreter and sources in this script.
-    ## All other interpreters also get a command to eval function in the
-    ## new interpreter.
-    ## 
-    proc ::tkcon::New {} {
-	variable PRIV
-	global argv0 argc argv
-
-	set tmp [GetSlave]
-	lappend PRIV(slaves) $tmp
-	load {} Tk $tmp
-	# If we have tbcload, then that should be autoloaded into slaves.
-	set idx [lsearch [info loaded] "* Tbcload"]
-	if {$idx != -1} { catch {load {} Tbcload $tmp} }
-	lappend PRIV(interps) [$tmp eval [list tk appname \
-		"[tk appname] $tmp"]]
-	if {[info exists argv0]} {$tmp eval [list set argv0 $argv0]}
-	if {[info exists argc]}  {$tmp eval [list set argc $argc]}
-	if {[info exists argv]}  {$tmp eval [list set argv $argv]}
-	$tmp eval [list namespace eval ::tkcon {}]
-	$tmp eval [list set ::tkcon::PRIV(name) $tmp]
-	$tmp eval [list set ::tkcon::PRIV(SCRIPT) $::tkcon::PRIV(SCRIPT)]
-	$tmp alias exit				::tkcon::Exit $tmp
-	$tmp alias ::tkcon::Destroy		::tkcon::Destroy $tmp
-	$tmp alias ::tkcon::New			::tkcon::New
-	$tmp alias ::tkcon::GetSlave		::tkcon::GetSlave $tmp
-	$tmp alias ::tkcon::Main		::tkcon::InterpEval Main
-	$tmp alias ::tkcon::Slave		::tkcon::InterpEval
-	$tmp alias ::tkcon::Interps		::tkcon::Interps
-	$tmp alias ::tkcon::NewDisplay		::tkcon::NewDisplay
-	$tmp alias ::tkcon::Display		::tkcon::Display
-	$tmp alias ::tkcon::StateCheckpoint	::tkcon::StateCheckpoint
-	$tmp alias ::tkcon::StateCleanup	::tkcon::StateCleanup
-	$tmp alias ::tkcon::StateCompare	::tkcon::StateCompare
-	$tmp alias ::tkcon::StateRevert		::tkcon::StateRevert
-	$tmp eval {
-	    if [catch {source -rsrc tkcon}] { source $::tkcon::PRIV(SCRIPT) }
-	}
-	return $tmp
-    }
-
-    ## ::tkcon::Exit - full exit OR destroy slave console
-    ## This proc should only be called in the main interpreter from a slave.
-    ## The master determines whether we do a full exit or just kill the slave.
-    ## 
-    proc ::tkcon::Exit {slave args} {
-	variable PRIV
-	variable OPT
-
-	## Slave interpreter exit request
-	if {[string match exit $OPT(slaveexit)]
-	    || [llength $PRIV(interps)] == 1} {
-	    ## Only exit if it specifically is stated to do so, or this
-	    ## is the last interp
-	    uplevel 1 exit $args
-	} else {
-	    ## Otherwise we will delete the slave interp and associated data
-	    Destroy $slave
-	}
-    }
-
-    ## ::tkcon::Destroy - destroy console window
-    ## This proc should only be called by the main interpreter.  If it is
-    ## called from there, it will ask before exiting tkcon.  All others
-    ## (slaves) will just have their slave interpreter deleted, closing them.
-    ## 
-    proc ::tkcon::Destroy {{slave {}}} {
-	variable PRIV
-
-	# Just close on the last one
-	if {[llength $PRIV(interps)] == 1} { exit }
-	if {"" == $slave} {
-	    ## Main interpreter close request
-	    if {[tk_messageBox -parent $PRIV(root) -title "Quit tkcon?" \
-		     -message "Close all windows and exit tkcon?" \
-		     -icon question -type yesno] == "yes"} { exit }
-	    return
-	} elseif {$slave == $::tkcon::OPT(exec)} {
-	    set name  [tk appname]
-	    set slave "Main"
-	} else {
-	    ## Slave interpreter close request
-	    set name [InterpEval $slave]
-	    interp delete $slave
-	}
-	set PRIV(interps) [lremove $PRIV(interps) [list $name]]
-	set PRIV(slaves)  [lremove $PRIV(slaves) [list $slave]]
-	StateCleanup $slave
-    }
-
-    if {$OPT(overrideexit)} {
-	## We want to do a couple things before exiting...
-	if {[catch {rename ::exit ::tkcon::FinalExit} err]} {
-	    puts stderr "tkcon might panic:\n$err"
-	}
-	proc ::exit args {
-	    if {$::tkcon::OPT(usehistory)} {
-		if {[catch {open $::tkcon::PRIV(histfile) w} fid]} {
-		    puts stderr "unable to save history file:\n$fid"
-		    # pause a moment, because we are about to die finally...
-		    after 1000
-		} else {
-		    set max [::tkcon::EvalSlave history nextid]
-		    set id [expr {$max - $::tkcon::OPT(history)}]
-		    if {$id < 1} { set id 1 }
-		    ## FIX: This puts history in backwards!!
-		    while {($id < $max) && ![catch \
-			    {::tkcon::EvalSlave history event $id} cmd]} {
-			if {[string compare {} $cmd]} {
-			    puts $fid "::tkcon::EvalSlave\
-				    history add [list $cmd]"
-			}
-			incr id
-		    }
-		    close $fid
-		}
-	    }
-	    uplevel 1 ::tkcon::FinalExit $args
-	}
-    }
-
-    ## ::tkcon::InterpEval - passes evaluation to another named interpreter
-    ## If the interpreter is named, but no args are given, it returns the
-    ## [tk appname] of that interps master (not the associated eval slave).
-    ##
-    proc ::tkcon::InterpEval {{slave {}} args} {
-	variable PRIV
-
-	if {[llength [info level 0]] == 1} {
-	    # no args given
-	    return $PRIV(slaves)
-	} elseif {[string match {[Mm]ain} $slave]} {
-	    set slave {}
-	}
-	if {[llength $args]} {
-	    return [interp eval $slave uplevel \#0 $args]
-	} else {
-	    # beware safe interps with Tk
-	    if {[interp eval $slave {llength [info commands tk]}]} {
-		if {[catch {interp eval $slave tk appname} name]} {
-		    return "safetk"
-		}
-		return $name
-	    }
-	}
-    }
-
-    proc ::tkcon::Interps {{ls {}} {interp {}}} {
-	if {[string match {} $interp]} {
-	    lappend ls {} [tk appname]
-	}
-	foreach i [interp slaves $interp] {
-	    if {[string compare {} $interp]} { set i "$interp $i" }
-	    if {[string compare {} [interp eval $i package provide Tk]]} {
-		# beware safe interps with Tk
-		if {[catch {interp eval $i tk appname} name]} {
-		    set name {}
-		}
-		lappend ls $i $name
-	    } else {
-		lappend ls $i {}
-	    }
-	    set ls [Interps $ls $i]
-	}
-	return $ls
-    }
-
-    proc ::tkcon::Display {{disp {}}} {
-	variable DISP
-
-	set res {}
-	if {$disp != ""} {
-	    if {![info exists DISP($disp)]} { return }
-	    return [list $DISP($disp) [winfo interps -displayof $DISP($disp)]]
-	}
-	return [lsort -dictionary [array names DISP]]
-    }
-
-    proc ::tkcon::NewDisplay {} {
-	variable PRIV
-	variable DISP
-
-	set t $PRIV(base).newdisp
-	if {![winfo exists $t]} {
-	    toplevel $t
-	    wm withdraw $t
-	    wm title $t "tkcon Attach to Display"
-	    label $t.gets -text "New Display: "
-	    entry $t.data -width 32
-	    button $t.ok -text "OK" -command {set ::tkcon::PRIV(grab) 1}
-	    bind $t.data <Return> [list $t.ok invoke]
-	    bind $t.ok   <Return> [list $t.ok invoke]
-	    grid $t.gets $t.data -sticky ew
-	    grid $t.ok   -	 -sticky ew
-	    grid columnconfig $t 1 -weight 1
-	    grid rowconfigure $t 1 -weight 1
-	    wm transient $t $PRIV(root)
-	    wm geometry $t +[expr {([winfo screenwidth $t]-[winfo \
-		    reqwidth $t]) / 2}]+[expr {([winfo \
-		    screenheight $t]-[winfo reqheight $t]) / 2}]
-	}
-	$t.data delete 0 end
-	wm deiconify $t
-	raise $t
-	grab $t
-	focus $t.data
-	vwait ::tkcon::PRIV(grab)
-	grab release $t
-	wm withdraw $t
-	set disp [$t.data get]
-	if {$disp == ""} { return }
-	regsub -all {\.} [string tolower $disp] ! dt
-	set dt $PRIV(base).$dt
-	destroy $dt
-	if {[catch {
-	    toplevel $dt -screen $disp
-	    set interps [winfo interps -displayof $dt]
-	    if {![llength $interps]} {
-		error "No other Tk interpreters on $disp"
-	    }
-	    ::send::send -displayof $dt [lindex $interps 0] [list info tclversion]
-	} err]} {
-	    global env
-	    if {[info exists env(DISPLAY)]} {
-		set myd $env(DISPLAY)
-	    } else {
-		set myd "myDisplay:0"
-	    }
-	    tk_messageBox -title "Display Connection Error" \
-		    -message "Unable to connect to \"$disp\":\n$err\
-		    \nMake sure you have xauth-based permissions\
-		    (xauth add $myd . `mcookie`), and xhost is disabled\
-		    (xhost -) on \"$disp\"" \
-		    -icon error -type ok
-	    destroy $dt
-	    return
-	}
-	set DISP($disp) $dt
-	wm withdraw $dt
-	bind $dt <Destroy> [subst {catch {unset ::tkcon::DISP($disp)}}]
-	tk_messageBox -title "$disp Connection" \
-		-message "Connected to \"$disp\", found:\n[join $interps \n]" \
-		-type ok
-    }
-
-    ##
-    ## The following state checkpoint/revert procedures are very sketchy
-    ## and prone to problems.  They do not track modifications to currently
-    ## existing procedures/variables, and they can really screw things up
-    ## if you load in libraries (especially Tk) between checkpoint and
-    ## revert.  Only with this knowledge in mind should you use these.
-    ##
-
-    ## ::tkcon::StateCheckpoint - checkpoints the current state of the system
-    ## This allows you to return to this state with ::tkcon::StateRevert
-    # ARGS:
-    ##
-    proc ::tkcon::StateCheckpoint {app type} {
-	variable CPS
-	variable PRIV
-
-	if {[info exists CPS($type,$app,cmd)] && \
-		[tk_dialog $PRIV(base).warning "Overwrite Previous State?" \
-		"Are you sure you want to lose previously checkpointed\
-		state of $type \"$app\"?" questhead 1 "Do It" "Cancel"]} return
-	set CPS($type,$app,cmd) [EvalOther $app $type info commands *]
-	set CPS($type,$app,var) [EvalOther $app $type info vars *]
-	return
-    }
-
-    ## ::tkcon::StateCompare - compare two states and output difference
-    # ARGS:
-    ##
-    proc ::tkcon::StateCompare {app type {verbose 0}} {
-	variable CPS
-	variable PRIV
-	variable OPT
-	variable COLOR
-
-	if {![info exists CPS($type,$app,cmd)]} {
-	    return -code error \
-		    "No previously checkpointed state for $type \"$app\""
-	}
-	set w $PRIV(base).compare
-	if {[winfo exists $w]} {
-	    $w.text config -state normal
-	    $w.text delete 1.0 end
-	} else {
-	    toplevel $w
-	    frame $w.btn
-	    scrollbar $w.sy -command [list $w.text yview]
-	    text $w.text -yscrollcommand [list $w.sy set] -height 12 \
-		    -foreground $COLOR(stdin) \
-		    -background $COLOR(bg) \
-		    -insertbackground $COLOR(cursor) \
-		    -font $OPT(font) -borderwidth 1 -highlightthickness 0
-	    pack $w.btn -side bottom -fill x
-	    pack $w.sy -side right -fill y
-	    pack $w.text -fill both -expand 1
-	    button $w.btn.close -text "Dismiss" -width 11 \
-		    -command [list destroy $w]
-	    button $w.btn.check  -text "Recheckpoint" -width 11
-	    button $w.btn.revert -text "Revert" -width 11
-	    button $w.btn.expand -text "Verbose" -width 11
-	    button $w.btn.update -text "Update" -width 11
-	    pack $w.btn.check $w.btn.revert $w.btn.expand $w.btn.update \
-		    $w.btn.close -side left -fill x -padx 4 -pady 2 -expand 1
-	    $w.text tag config red -foreground red
-	}
-	wm title $w "Compare State: $type [list $app]"
-
-	$w.btn.check config \
-		-command "::tkcon::StateCheckpoint [list $app] $type; \
-		::tkcon::StateCompare [list $app] $type $verbose"
-	$w.btn.revert config \
-		-command "::tkcon::StateRevert [list $app] $type; \
-		::tkcon::StateCompare [list $app] $type $verbose"
-	$w.btn.update config -command [info level 0]
-	if {$verbose} {
-	    $w.btn.expand config -text Brief \
-		    -command [list ::tkcon::StateCompare $app $type 0]
-	} else {
-	    $w.btn.expand config -text Verbose \
-		    -command [list ::tkcon::StateCompare $app $type 1]
-	}
-	## Don't allow verbose mode unless 'dump' exists in $app
-	## We're assuming this is tkcon's dump command
-	set hasdump [llength [EvalOther $app $type info commands dump]]
-	if {$hasdump} {
-	    $w.btn.expand config -state normal
-	} else {
-	    $w.btn.expand config -state disabled
-	}
-
-	set cmds [lremove [EvalOther $app $type info commands *] \
-		$CPS($type,$app,cmd)]
-	set vars [lremove [EvalOther $app $type info vars *] \
-		$CPS($type,$app,var)]
-
-	if {$hasdump && $verbose} {
-	    set cmds [EvalOther $app $type eval dump c -nocomplain $cmds]
-	    set vars [EvalOther $app $type eval dump v -nocomplain $vars]
-	}
-	$w.text insert 1.0 "NEW COMMANDS IN \"$app\":\n" red \
-		$cmds {} "\n\nNEW VARIABLES IN \"$app\":\n" red $vars {}
-
-	raise $w
-	$w.text config -state disabled
-    }
-
-    ## ::tkcon::StateRevert - reverts interpreter to previous state
-    # ARGS:
-    ##
-    proc ::tkcon::StateRevert {app type} {
-	variable CPS
-	variable PRIV
-
-	if {![info exists CPS($type,$app,cmd)]} {
-	    return -code error \
-		    "No previously checkpointed state for $type \"$app\""
-	}
-	if {![tk_dialog $PRIV(base).warning "Revert State?" \
-		"Are you sure you want to revert the state in $type \"$app\"?"\
-		questhead 1 "Do It" "Cancel"]} {
-	    foreach i [lremove [EvalOther $app $type info commands *] \
-		    $CPS($type,$app,cmd)] {
-		catch {EvalOther $app $type rename $i {}}
-	    }
-	    foreach i [lremove [EvalOther $app $type info vars *] \
-		    $CPS($type,$app,var)] {
-		catch {EvalOther $app $type unset $i}
-	    }
-	}
-    }
-
-    ## ::tkcon::StateCleanup - cleans up state information in master array
-    #
-    ##
-    proc ::tkcon::StateCleanup {args} {
-	variable CPS
-
-	if {![llength $args]} {
-	    foreach state [array names CPS slave,*] {
-		if {![interp exists [string range $state 6 end]]} {
-		    unset CPS($state)
-		}
-	    }
-	} else {
-	    set app  [lindex $args 0]
-	    set type [lindex $args 1]
-	    if {[regexp {^(|slave)$} $type]} {
-		foreach state [array names CPS "slave,$app\[, \]*"] {
-		    if {![interp exists [string range $state 6 end]]} {
-			unset CPS($state)
-		    }
-		}
-	    } else {
-		catch {unset CPS($type,$app)}
-	    }
-	}
-    }
-}
-
-## ::tkcon::Event - get history event, search if string != {}
-## look forward (next) if $int>0, otherwise look back (prev)
-# ARGS:	W	- console widget
-##
-proc ::tkcon::Event {int {str {}}} {
-    if {!$int} return
-
-    variable PRIV
-    set w $PRIV(console)
-
-    set nextid [EvalSlave history nextid]
-    if {[string compare {} $str]} {
-	## String is not empty, do an event search
-	set event $PRIV(event)
-	if {$int < 0 && $event == $nextid} { set PRIV(cmdbuf) $str }
-	set len [string len $PRIV(cmdbuf)]
-	incr len -1
-	if {$int > 0} {
-	    ## Search history forward
-	    while {$event < $nextid} {
-		if {[incr event] == $nextid} {
-		    $w delete limit end
-		    $w insert limit $PRIV(cmdbuf)
-		    break
-		} elseif {
-		    ![catch {EvalSlave history event $event} res] &&
-		    [set p [string first $PRIV(cmdbuf) $res]] > -1
-		} {
-		    set p2 [expr {$p + [string length $PRIV(cmdbuf)]}]
-		    $w delete limit end
-		    $w insert limit $res
-		    Blink $w "limit + $p c" "limit + $p2 c"
-		    break
-		}
-	    }
-	    set PRIV(event) $event
-	} else {
-	    ## Search history reverse
-	    while {![catch {EvalSlave history event [incr event -1]} res]} {
-		if {[set p [string first $PRIV(cmdbuf) $res]] > -1} {
-		    set p2 [expr {$p + [string length $PRIV(cmdbuf)]}]
-		    $w delete limit end
-		    $w insert limit $res
-		    set PRIV(event) $event
-		    Blink $w "limit + $p c" "limit + $p2 c"
-		    break
-		}
-	    }
-	}
-    } else {
-	## String is empty, just get next/prev event
-	if {$int > 0} {
-	    ## Goto next command in history
-	    if {$PRIV(event) < $nextid} {
-		$w delete limit end
-		if {[incr PRIV(event)] == $nextid} {
-		    $w insert limit $PRIV(cmdbuf)
-		} else {
-		    $w insert limit [EvalSlave history event $PRIV(event)]
-		}
-	    }
-	} else {
-	    ## Goto previous command in history
-	    if {$PRIV(event) == $nextid} {
-		set PRIV(cmdbuf) [CmdGet $w]
-	    }
-	    if {[catch {EvalSlave history event [incr PRIV(event) -1]} res]} {
-		incr PRIV(event)
-	    } else {
-		$w delete limit end
-		$w insert limit $res
-	    }
-	}
-    }
-    $w mark set insert end
-    $w see end
-}
-
-## ::tkcon::Highlight - magic highlighting
-## beware: voodoo included
-# ARGS:
-##
-proc ::tkcon::Highlight {w type} {
-    variable COLOR
-    variable OPT
-
-    switch -exact $type {
-	"error" { HighlightError $w }
-	"tcl" - "test" {
-	    if {[winfo class $w] != "Ctext"} { return }
-
-	    foreach {app type} [tkcon attach] {break}
-	    set cmds [::tkcon::EvalOther $app $type info commands]
-
-	    set classes [list \
-		 [list comment ClassForRegexp "^\\s*#\[^\n\]*" $COLOR(stderr)] \
-		 [list var     ClassWithOnlyCharStart "\$" $COLOR(stdout)] \
-		 [list syntax  ClassForSpecialChars "\[\]{}\"" $COLOR(prompt)] \
-		 [list command Class $cmds $COLOR(proc)] \
-		]
-
-	    # Remove all highlight classes from a widget
-	    ctext::clearHighlightClasses $w
-	    foreach class $classes {
-		foreach {cname ctype cptn ccol} $class break
-		ctext::addHighlight$ctype $w $cname $ccol $cptn
-	    }
-	    $w highlight 1.0 end
-	}
-    }
-}
-
-## ::tkcon::HighlightError - magic error highlighting
-## beware: voodoo included
-# ARGS:
-##
-proc ::tkcon::HighlightError w {
-    variable COLOR
-    variable OPT
-
-    ## do voodoo here
-    set app [Attach]
-    # we have to pull the text out, because text regexps are screwed on \n's.
-    set info [$w get 1.0 end-1c]
-    # Check for specific line error in a proc
-    set exp(proc) "\"(\[^\"\]+)\"\n\[\t \]+\\\(procedure \"(\[^\"\]+)\""
-    # Check for too few args to a proc
-    set exp(param) "parameter \"(\[^\"\]+)\" to \"(\[^\"\]+)\""
-    set start 1.0
-    while {
-	[regexp -indices -- $exp(proc) $info junk what cmd] ||
-	[regexp -indices -- $exp(param) $info junk what cmd]
-    } {
-	foreach {w0 w1} $what {c0 c1} $cmd {break}
-	set what [string range $info $w0 $w1]
-	set cmd  [string range $info $c0 $c1]
-	if {[string match *::* $cmd]} {
-	    set res [uplevel 1 ::tkcon::EvalOther $app namespace eval \
-		    [list [namespace qualifiers $cmd] \
-		    [list info procs [namespace tail $cmd]]]]
-	} else {
-	    set res [uplevel 1 ::tkcon::EvalOther $app info procs [list $cmd]]
-	}
-	if {[llength $res]==1} {
-	    set tag [UniqueTag $w]
-	    $w tag add $tag $start+${c0}c $start+1c+${c1}c
-	    $w tag configure $tag -foreground $COLOR(stdout)
-	    $w tag bind $tag <Enter> [list $w tag configure $tag -under 1]
-	    $w tag bind $tag <Leave> [list $w tag configure $tag -under 0]
-	    $w tag bind $tag <ButtonRelease-1> "if {!\$tkPriv(mouseMoved)} \
-		    {[list $OPT(edit) -attach $app -type proc -find $what -- $cmd]}"
-	}
-	set info [string range $info $c1 end]
-	set start [$w index $start+${c1}c]
-    }
-    ## Next stage, check for procs that start a line
-    set start 1.0
-    set exp(cmd) "^\"\[^\" \t\n\]+"
-    while {
-	[string compare {} [set ix \
-		[$w search -regexp -count numc -- $exp(cmd) $start end]]]
-    } {
-	set start [$w index $ix+${numc}c]
-	# +1c to avoid the first quote
-	set cmd [$w get $ix+1c $start]
-	if {[string match *::* $cmd]} {
-	    set res [uplevel 1 ::tkcon::EvalOther $app namespace eval \
-		    [list [namespace qualifiers $cmd] \
-		    [list info procs [namespace tail $cmd]]]]
-	} else {
-	    set res [uplevel 1 ::tkcon::EvalOther $app info procs [list $cmd]]
-	}
-	if {[llength $res]==1} {
-	    set tag [UniqueTag $w]
-	    $w tag add $tag $ix+1c $start
-	    $w tag configure $tag -foreground $COLOR(proc)
-	    $w tag bind $tag <Enter> [list $w tag configure $tag -under 1]
-	    $w tag bind $tag <Leave> [list $w tag configure $tag -under 0]
-	    $w tag bind $tag <ButtonRelease-1> "if {!\$tkPriv(mouseMoved)} \
-		    {[list $OPT(edit) -attach $app -type proc -- $cmd]}"
-	}
-    }
-}
-
-proc ::tkcon::ExpectInit {{termcap 1} {terminfo 1}} {
-    global env
-
-    if {$termcap} {
-	set env(TERM) "tt"
-	set env(TERMCAP) {tt:
- :ks=\E[KS:
- :ke=\E[KE:
- :cm=\E[%d;%dH:
- :up=\E[A:
- :nd=\E[C:
- :cl=\E[H\E[J:
- :do=^J:
- :so=\E[7m:
- :se=\E[m:
- :k1=\EOP:
- :k2=\EOQ:
- :k3=\EOR:
- :k4=\EOS:
- :k5=\EOT:
- :k6=\EOU:
- :k7=\EOV:
- :k8=\EOW:
- :k9=\EOX:
-    }
-    }
-
-    if {$terminfo} {
-	set env(TERM) "tkterm"
-	if {![info exists env(TEMP)]} { set env(TEMP) /tmp }
-	set env(TERMINFO) $env(TEMP)
-
-	set ttsrc [file join $env(TEMP) tt.src]
-	set file [open $ttsrc w]
-	puts $file {tkterm|Don Libes' tk text widget terminal emulator,
- smkx=\E[KS,
- rmkx=\E[KE,
- cup=\E[%p1%d;%p2%dH,
- cuu1=\E[A,
- cuf1=\E[C,
- clear=\E[H\E[J,
- ind=\n,
- cr=\r,
- smso=\E[7m,
- rmso=\E[m,
- kf1=\EOP,
- kf2=\EOQ,
- kf3=\EOR,
- kf4=\EOS,
- kf5=\EOT,
- kf6=\EOU,
- kf7=\EOV,
- kf8=\EOW,
- kf9=\EOX,
-    }
-	close $file
-
-	if {[catch {exec tic $ttsrc} msg]} {
-	    return -code error \
-		"tic failed, you may not have terminfo support:\n$msg"
-	}
-
-	file delete $ttsrc
-    }
-}
-
-# term_exit is called if the spawned process exits
-proc ::tkcon::term_exit {w} {
-    variable EXP
-    catch {exp_close -i $EXP(spawn_id)}
-    set EXP(forever) 1
-    unset EXP
-}
-
-# term_chars_changed is called after every change to the displayed chars
-# You can use if you want matches to occur in the background (a la bind)
-# If you want to test synchronously, then just do so - you don't need to
-# redefine this procedure.
-proc ::tkcon::term_chars_changed {w args} {
-}
-
-# term_cursor_changed is called after the cursor is moved
-proc ::tkcon::term_cursor_changed {w args} {
-}
-
-proc ::tkcon::term_update_cursor {w args} {
-    variable OPT
-    variable EXP
-
-    $w mark set insert $EXP(row).$EXP(col)
-    $w see insert
-    term_cursor_changed $w
-}
-
-proc ::tkcon::term_clear {w args} {
-    $w delete 1.0 end
-    term_init $w
-}
-
-proc ::tkcon::term_init {w args} {
-    variable OPT
-    variable EXP
-
-    # initialize it with blanks to make insertions later more easily
-    set blankline [string repeat " " $OPT(cols)]\n
-    for {set i 1} {$i <= $OPT(rows)} {incr i} {
-	$w insert $i.0 $blankline
-    }
-
-    set EXP(row) 1
-    set EXP(col) 0
-
-    $w mark set insert $EXP(row).$EXP(col)
-}
-
-proc ::tkcon::term_down {w args} {
-    variable OPT
-    variable EXP
-
-    if {$EXP(row) < $OPT(rows)} {
-	incr EXP(row)
-    } else {
-	# already at last line of term, so scroll screen up
-	$w delete 1.0 2.0
-
-	# recreate line at end
-	$w insert end [string repeat " " $OPT(cols)]\n
-    }
-}
-
-proc ::tkcon::term_insert {w s} {
-    variable OPT
-    variable EXP
-
-    set chars_rem_to_write [string length $s]
-    set space_rem_on_line  [expr {$OPT(cols) - $EXP(col)}]
-
-    set tag_action [expr {$EXP(standout) ? "add" : "remove"}]
-
-    ##################
-    # write first line
-    ##################
-
-    if {$chars_rem_to_write > $space_rem_on_line} {
-	set chars_to_write $space_rem_on_line
-	set newline 1
-    } else {
-	set chars_to_write $chars_rem_to_write
-	set newline 0
-    }
-
-    $w delete $EXP(row).$EXP(col) \
-	$EXP(row).[expr {$EXP(col) + $chars_to_write}]
-    $w insert $EXP(row).$EXP(col) \
-	[string range $s 0 [expr {$space_rem_on_line-1}]]
-
-    $w tag $tag_action standout $EXP(row).$EXP(col) \
-	$EXP(row).[expr {$EXP(col) + $chars_to_write}]
-
-    # discard first line already written
-    incr chars_rem_to_write -$chars_to_write
-    set s [string range $s $chars_to_write end]
-
-    # update EXP(col)
-    incr EXP(col) $chars_to_write
-    # update EXP(row)
-    if {$newline} { term_down $w }
-
-    ##################
-    # write full lines
-    ##################
-    while {$chars_rem_to_write >= $OPT(cols)} {
-	$w delete $EXP(row).0 $EXP(row).end
-	$w insert $EXP(row).0 [string range $s 0 [expr {$OPT(cols)-1}]]
-	$w tag $tag_action standout $EXP(row).0 $EXP(row).end
-
-	# discard line from buffer
-	set s [string range $s $OPT(cols) end]
-	incr chars_rem_to_write -$OPT(cols)
-
-	set EXP(col) 0
-	term_down $w
-    }
-
-    #################
-    # write last line
-    #################
-
-    if {$chars_rem_to_write} {
-	$w delete $EXP(row).0 $EXP(row).$chars_rem_to_write
-	$w insert $EXP(row).0 $s
-	$w tag $tag_action standout $EXP(row).0 $EXP(row).$chars_rem_to_write
-	set EXP(col) $chars_rem_to_write
-    }
-
-    term_chars_changed $w
-}
-
-proc ::tkcon::Expect {cmd} {
-    variable OPT
-    variable PRIV
-    variable EXP
-
-    set EXP(standout) 0
-    set EXP(row) 0
-    set EXP(col) 0
-
-    set env(LINES)   $OPT(rows)
-    set env(COLUMNS) $OPT(cols)
-
-    ExpectInit
-    log_user 0
-    set ::stty_init "-tabs"
-    uplevel \#0 [linsert $cmd 0 spawn]
-    set EXP(spawn_id) $::spawn_id
-    if {[info exists ::spawn_out(slave,name)]} {
-	set EXP(slave,name) $::spawn_out(slave,name)
-	catch {stty rows $OPT(rows) columns $OPT(cols) < $::spawn_out(slave,name)}
-    }
-    if {[string index $cmd end] == "&"} {
-	set cmd expect_background
-    } else {
-	set cmd expect
-    }
-    bind $PRIV(console) <Meta-KeyPress> {
-	if {"%A" != ""} {
-	    exp_send -i $::tkcon::EXP(spawn_id) "\033%A"
-	    break
-	}
-    }
-    bind $PRIV(console) <KeyPress> {
-	exp_send -i $::tkcon::EXP(spawn_id) -- %A
-	break
-    }
-    bind $PRIV(console) <Control-space>	{exp_send -null}
-    set code [catch {
-	term_init $PRIV(console)
-	while {[info exists EXP(spawn_id)]} {
-	$cmd {
-	    -i $::tkcon::EXP(spawn_id)
-	    -re "^\[^\x01-\x1f\]+" {
-		# Text
-		::tkcon::term_insert $::tkcon::PRIV(console) \
-		    $expect_out(0,string)
-		::tkcon::term_update_cursor $::tkcon::PRIV(console)
-	    } "^\r" {
-		# (cr,) Go to beginning of line
-		update idle
-		set ::tkcon::EXP(col) 0
-		::tkcon::term_update_cursor $::tkcon::PRIV(console)
-	    } "^\n" {
-		# (ind,do) Move cursor down one line
-		if {$::tcl_platform(platform) eq "windows"} {
-		    # Windows seems to get the LF without the CR
-		    update idle
-		    set ::tkcon::EXP(col) 0
-		}
-		::tkcon::term_down $::tkcon::PRIV(console)
-		::tkcon::term_update_cursor $::tkcon::PRIV(console)
-	    } "^\b" {
-		# Backspace nondestructively
-		incr ::tkcon::EXP(col) -1
-		::tkcon::term_update_cursor $::tkcon::PRIV(console)
-	    } "^\a" {
-		bell
-	    } "^\t" {
-		# Tab, shouldn't happen
-		send_error "got a tab!?"
-	    } eof {
-		::tkcon::term_exit $::tkcon::PRIV(console)
-	    } "^\x1b\\\[A" {
-		# Cursor Up (cuu1,up)
-		incr ::tkcon::EXP(row) -1
-		::tkcon::term_update_cursor $::tkcon::PRIV(console)
-	    } "^\x1b\\\[B" {
-		# Cursor Down
-		incr ::tkcon::EXP(row)
-		::tkcon::term_update_cursor $::tkcon::PRIV(console)
-	    } "^\x1b\\\[C" {
-		# Cursor Right (cuf1,nd)
-		incr ::tkcon::EXP(col)
-		::tkcon::term_update_cursor $::tkcon::PRIV(console)
-	    } "^\x1b\\\[D" {
-		# Cursor Left
-		incr ::tkcon::EXP(col)
-		::tkcon::term_update_cursor $::tkcon::PRIV(console)
-	    } "^\x1b\\\[H" {
-		# Cursor Home
-	    } -re "^\x1b\\\[(\[0-9\]*);(\[0-9\]*)H" {
-		# (cup,cm) Move to row y col x
-		set ::tkcon::EXP(row) [expr {$expect_out(1,string)+1}]
-		set ::tkcon::EXP(col) $expect_out(2,string)
-		::tkcon::term_update_cursor $::tkcon::PRIV(console)
-	    } "^\x1b\\\[H\x1b\\\[J" {
-		# (clear,cl) Clear screen
-		::tkcon::term_clear $::tkcon::PRIV(console)
-		::tkcon::term_update_cursor $::tkcon::PRIV(console)
-	    } "^\x1b\\\[7m" {
-		# (smso,so) Begin standout mode
-		set ::tkcon::EXP(standout) 1
-	    } "^\x1b\\\[m" {
-		# (rmso,se) End standout mode
-		set ::tkcon::EXP(standout) 0
-	    } "^\x1b\\\[KS" {
-		# (smkx,ks) start keyboard-transmit mode
-		# terminfo invokes these when going in/out of graphics mode
-		# In graphics mode, we should have no scrollbars
-		#graphicsSet 1
-	    } "^\x1b\\\[KE" {
-		# (rmkx,ke) end keyboard-transmit mode
-		# Out of graphics mode, we should have scrollbars
-		#graphicsSet 0
-	    }
-	}
-	}
-	#vwait ::tkcon::EXP(forever)
-    } err]
-    bind $PRIV(console) <Meta-KeyPress> {}
-    bind $PRIV(console) <KeyPress>      {}
-    bind $PRIV(console) <Control-space>	{}
-    catch {unset EXP}
-    if {$code} {
-	return -code $code -errorinfo $::errorInfo $err
-    }
-}
-
-## tkcon - command that allows control over the console
-## This always exists in the main interpreter, and is aliased into
-## other connected interpreters
-# ARGS:	totally variable, see internal comments
-## 
-proc tkcon {cmd args} {
-    variable ::tkcon::PRIV
-    variable ::tkcon::OPT
-    global errorInfo
-
-    switch -glob -- $cmd {
-	buf* {
-	    ## 'buffer' Sets/Query the buffer size
-	    if {[llength $args]} {
-		if {[regexp {^[1-9][0-9]*$} $args]} {
-		    set OPT(buffer) $args
-		    # catch in case the console doesn't exist yet
-		    catch {::tkcon::ConstrainBuffer $PRIV(console) \
-			    $OPT(buffer)}
-		} else {
-		    return -code error "buffer must be a valid integer"
-		}
-	    }
-	    return $OPT(buffer)
-	}
-	linelen* {
-	    ## 'linelength' Sets/Query the maximum line length
-	    if {[llength $args]} {
-		if {[regexp {^-?[0-9]+$} $args]} {
-		    set OPT(maxlinelen) $args
-		} else {
-		    return -code error "buffer must be a valid integer"
-		}
-	    }
-	    return $OPT(maxlinelen)
-	}
-	bg* {
-	    ## 'bgerror' Brings up an error dialog
-	    set errorInfo [lindex $args 1]
-	    bgerror [lindex $args 0]
-	}
-	cl* {
-	    ## 'close' Closes the console
-	    ::tkcon::Destroy
-	}
-	cons* {
-	    ## 'console' - passes the args to the text widget of the console.
-	    set result [uplevel 1 $PRIV(console) $args]
-	    ::tkcon::ConstrainBuffer $PRIV(console) $OPT(buffer)
-	    return $result
-	}
-	congets {
-	    ## 'congets' a replacement for [gets stdin]
-	    # Use the 'gets' alias of 'tkcon_gets' command instead of
-	    # calling the *get* methods directly for best compatability
-	    if {[llength $args]} {
-		return -code error "wrong # args: must be \"tkcon congets\""
-	    }
-	    tkcon show
-	    set old [bind TkConsole <<TkCon_Eval>>]
-	    bind TkConsole <<TkCon_Eval>> { set ::tkcon::PRIV(wait) 0 }
-	    set w $PRIV(console)
-	    # Make sure to move the limit to get the right data
-	    $w mark set limit end-1c
-	    $w mark gravity limit left
-	    $w mark set insert end
-	    $w see end
-	    vwait ::tkcon::PRIV(wait)
-	    set line [::tkcon::CmdGet $w]
-	    $w insert end \n
-	    bind TkConsole <<TkCon_Eval>> $old
-	    return $line
-	}
-	exp* {
-	    ::tkcon::Expect [lindex $args 0]
-	}
-	getc* {
-	    ## 'getcommand' a replacement for [gets stdin]
-	    ## This forces a complete command to be input though
-	    if {[llength $args]} {
-		return -code error "wrong # args: must be \"tkcon getcommand\""
-	    }
-	    tkcon show
-	    set old [bind TkConsole <<TkCon_Eval>>]
-	    bind TkConsole <<TkCon_Eval>> { set ::tkcon::PRIV(wait) 0 }
-	    set w $PRIV(console)
-	    # Make sure to move the limit to get the right data
-	    $w mark set insert end
-	    $w mark set limit insert
-	    $w see end
-	    vwait ::tkcon::PRIV(wait)
-	    set line [::tkcon::CmdGet $w]
-	    $w insert end \n
-	    while {![info complete $line] || [regexp {[^\\]\\$} $line]} {
-		vwait ::tkcon::PRIV(wait)
-		set line [::tkcon::CmdGet $w]
-		$w insert end \n
-		$w see end
-	    }
-	    bind TkConsole <<TkCon_Eval>> $old
-	    return $line
-	}
-	get - gets {
-	    ## 'gets' - a replacement for [gets stdin]
-	    ## This pops up a text widget to be used for stdin (local grabbed)
-	    if {[llength $args]} {
-		return -code error "wrong # args: should be \"tkcon gets\""
-	    }
-	    set t $PRIV(base).gets
-	    if {![winfo exists $t]} {
-		toplevel $t
-		wm withdraw $t
-		wm title $t "tkcon gets stdin request"
-		label $t.gets -text "\"gets stdin\" request:"
-		text $t.data -width 32 -height 5 -wrap none \
-			-xscrollcommand [list $t.sx set] \
-			-yscrollcommand [list $t.sy set] -borderwidth 1
-		scrollbar $t.sx -orient h -takefocus 0 -highlightthickness 0 \
-			-command [list $t.data xview]
-		scrollbar $t.sy -orient v -takefocus 0 -highlightthickness 0 \
-			-command [list $t.data yview]
-		button $t.ok -text "OK" -command {set ::tkcon::PRIV(grab) 1}
-		bind $t.ok <Return> { %W invoke }
-		grid $t.gets -		-sticky ew
-		grid $t.data $t.sy	-sticky news
-		grid $t.sx		-sticky ew
-		grid $t.ok   -		-sticky ew
-		grid columnconfig $t 0 -weight 1
-		grid rowconfig    $t 1 -weight 1
-		wm transient $t $PRIV(root)
-		wm geometry $t +[expr {([winfo screenwidth $t]-[winfo \
-			reqwidth $t]) / 2}]+[expr {([winfo \
-			screenheight $t]-[winfo reqheight $t]) / 2}]
-	    }
-	    $t.data delete 1.0 end
-	    wm deiconify $t
-	    raise $t
-	    grab $t
-	    focus $t.data
-	    vwait ::tkcon::PRIV(grab)
-	    grab release $t
-	    wm withdraw $t
-	    return [$t.data get 1.0 end-1c]
-	}
-	err* {
-	    ## Outputs stack caused by last error.
-	    ## error handling with pizazz (but with pizza would be nice too)
-	    if {[llength $args]==2} {
-		set app  [lindex $args 0]
-		set type [lindex $args 1]
-		if {[catch {::tkcon::EvalOther $app $type set errorInfo} info]} {
-		    set info "error getting info from $type $app:\n$info"
-		}
-	    } else {
-		set info $PRIV(errorInfo)
-	    }
-	    if {[string match {} $info]} { set info "errorInfo empty" }
-	    ## If args is empty, the -attach switch just ignores it
-	    $OPT(edit) -attach $args -type error -- $info
-	}
-	fi* {
-	    ## 'find' string
-	    ::tkcon::Find $PRIV(console) $args
-	}
-	fo* {
-	    ## 'font' ?fontname? - gets/sets the font of the console
-	    if {[llength $args]} {
-		if {[info exists PRIV(console)] && \
-			[winfo exists $PRIV(console)]} {
-		    $PRIV(console) config -font $args
-		    set OPT(font) [$PRIV(console) cget -font]
-		} else {
-		    set OPT(font) $args
-		}
-	    }
-	    return $OPT(font)
-	}
-	hid* - with* {
-	    ## 'hide' 'withdraw' - hides the console.
-	    if {[info exists PRIV(root)] && [winfo exists $PRIV(root)]} {
-		wm withdraw $PRIV(root)
-	    }
-	}
-	his* {
-	    ## 'history'
-	    set sub {\2}
-	    if {[string match -new* $args]} { append sub "\n"}
-	    set h [::tkcon::EvalSlave history]
-	    regsub -all "( *\[0-9\]+  |\t)(\[^\n\]*\n?)" $h $sub h
-	    return $h
-	}
-	ico* {
-	    ## 'iconify' - iconifies the console with 'iconify'.
-	    if {[info exists PRIV(root)] && [winfo exists $PRIV(root)]} {
-		wm iconify $PRIV(root)
-	    }
-	}
-	mas* - eval {
-	    ## 'master' - evals contents in master interpreter
-	    uplevel \#0 $args
-	}
-	result* {
-	    ## 'resultfilter' Sets/queries the result filter command
-	    if {[llength $args]} {
-		set OPT(resultfilter) $args
-	    }
-	    return $OPT(resultfilter)
-	}
-	set {
-	    ## 'set' - set (or get, or unset) simple vars (not whole arrays)
-	    ## from the master console interpreter
-	    ## possible formats:
-	    ##    tkcon set <var>
-	    ##    tkcon set <var> <value>
-	    ##    tkcon set <var> <interp> <var1> <var2> w
-	    ##    tkcon set <var> <interp> <var1> <var2> u
-	    ##    tkcon set <var> <interp> <var1> <var2> r
-	    if {[llength $args]==5} {
-		## This is for use w/ 'tkcon upvar' and only works with slaves
-		foreach {var i var1 var2 op} $args break
-		if {[string compare {} $var2]} { append var1 "($var2)" }
-		switch $op {
-		    u { uplevel \#0 [list unset $var] }
-		    w {
-			return [uplevel \#0 [list set $var \
-				[interp eval $i [list set $var1]]]]
-		    }
-		    r {
-			return [interp eval $i [list set $var1 \
-				[uplevel \#0 [list set $var]]]]
-		    }
-		}
-	    } elseif {[llength $args] == 1} {
-		upvar \#0 [lindex $args 0] var
-		if {[array exists var]} {
-		    return [array get var]
-		} else {
-		    return $var
-		}
-	    }
-	    return [uplevel \#0 set $args]
-	}
-	append {
-	    ## Modify a var in the master environment using append
-	    return [uplevel \#0 append $args]
-	}
-	lappend {
-	    ## Modify a var in the master environment using lappend
-	    return [uplevel \#0 lappend $args]
-	}
-	sh* - dei* {
-	    ## 'show|deiconify' - deiconifies the console.
-	    if {![info exists PRIV(root)]} {
-		# We are likely in some embedded console configuration.
-		# Make default setup reflect that.
-		set PRIV(showOnStartup) 0
-		set PRIV(protocol) {tkcon hide}
-		set PRIV(root) .tkcon
-		set OPT(exec) ""
-	    }
-	    if {![winfo exists $PRIV(root)]} {
-		::tkcon::Init
-	    }
-	    wm deiconify $PRIV(root)
-	    raise $PRIV(root)
-	    focus -force $PRIV(console)
-	}
-	ti* {
-	    ## 'title' ?title? - gets/sets the console's title
-	    if {[llength $args]} {
-		return [wm title $PRIV(root) [join $args]]
-	    } else {
-		return [wm title $PRIV(root)]
-	    }
-	}
-	upv* {
-	    ## 'upvar' masterVar slaveVar
-	    ## link slave variable slaveVar to the master variable masterVar
-	    ## only works masters<->slave
-	    set masterVar [lindex $args 0]
-	    set slaveVar  [lindex $args 1]
-	    if {[info exists $masterVar]} {
-		interp eval $OPT(exec) \
-			[list set $slaveVar [set $masterVar]]
-	    } else {
-		catch {interp eval $OPT(exec) [list unset $slaveVar]}
-	    }
-	    interp eval $OPT(exec) \
-		    [list trace variable $slaveVar rwu \
-		    [list tkcon set $masterVar $OPT(exec)]]
-	    return
-	}
-	v* {
-	    return $PRIV(version)
-	}
-	default {
-	    ## tries to determine if the command exists, otherwise throws error
-	    set new ::tkcon::[string toupper \
-		    [string index $cmd 0]][string range $cmd 1 end]
-	    if {[llength [info command $new]]} {
-		uplevel \#0 $new $args
-	    } else {
-		return -code error "bad option \"$cmd\": must be\
-			[join [lsort [list attach close console destroy \
-			font hide iconify load main master new save show \
-			slave deiconify version title bgerror]] {, }]"
-	    }
-	}
-    }
-}
-
-##
-## Some procedures to make up for lack of built-in shell commands
-##
-
-## tkcon_puts -
-## This allows me to capture all stdout/stderr to the console window
-## This will be renamed to 'puts' at the appropriate time during init
-##
-# ARGS:	same as usual	
-# Outputs:	the string with a color-coded text tag
-## 
-proc tkcon_puts args {
-    set len [llength $args]
-    foreach {arg1 arg2 arg3} $args { break }
-
-    if {$len == 1} {
-	tkcon console insert output "$arg1\n" stdout
-    } elseif {$len == 2} {
-	if {![string compare $arg1 -nonewline]} {
-	    tkcon console insert output $arg2 stdout
-	} elseif {![string compare $arg1 stdout] \
-		|| ![string compare $arg1 stderr]} {
-	    tkcon console insert output "$arg2\n" $arg1
-	} else {
-	    set len 0
-	}
-    } elseif {$len == 3} {
-	if {![string compare $arg1 -nonewline] \
-		&& (![string compare $arg2 stdout] \
-		|| ![string compare $arg2 stderr])} {
-	    tkcon console insert output $arg3 $arg2
-	} elseif {(![string compare $arg1 stdout] \
-		|| ![string compare $arg1 stderr]) \
-		&& ![string compare $arg3 nonewline]} {
-	    tkcon console insert output $arg2 $arg1
-	} else {
-	    set len 0
-	}
-    } else {
-	set len 0
-    }
-
-    ## $len == 0 means it wasn't handled by tkcon above.
-    ##
-    if {$len == 0} {
-	global errorCode errorInfo
-	if {[catch "tkcon_tcl_puts $args" msg]} {
-	    regsub tkcon_tcl_puts $msg puts msg
-	    regsub -all tkcon_tcl_puts $errorInfo puts errorInfo
-	    return -code error $msg
-	}
-	return $msg
-    }
-
-    ## WARNING: This update should behave well because it uses idletasks,
-    ## however, if there are weird looping problems with events, or
-    ## hanging in waits, try commenting this out.
-    if {$len} {
-	tkcon console see output
-	update idletasks
-    }
-}
-
-## tkcon_gets -
-## This allows me to capture all stdin input without needing to stdin
-## This will be renamed to 'gets' at the appropriate time during init
-##
-# ARGS:		same as gets	
-# Outputs:	same as gets
-##
-proc tkcon_gets args {
-    set len [llength $args]
-    if {$len != 1 && $len != 2} {
-	return -code error \
-		"wrong # args: should be \"gets channelId ?varName?\""
-    }
-    if {[string compare stdin [lindex $args 0]]} {
-	return [uplevel 1 tkcon_tcl_gets $args]
-    }
-    set gtype [tkcon set ::tkcon::OPT(gets)]
-    if {$gtype == ""} { set gtype congets }
-    set data [tkcon $gtype]
-    if {$len == 2} {
-	upvar 1 [lindex $args 1] var
-	set var $data
-	return [string length $data]
-    }
-    return $data
-}
-
-## edit - opens a file/proc/var for reading/editing
-## 
-# Arguments:
-#   type	proc/file/var
-#   what	the actual name of the item
-# Returns:	nothing
-## 
-proc edit {args} {
-    array set opts {-find {} -type {} -attach {} -wrap {none}}
-    while {[string match -* [lindex $args 0]]} {
-	switch -glob -- [lindex $args 0] {
-	    -f*	{ set opts(-find) [lindex $args 1] }
-	    -a*	{ set opts(-attach) [lindex $args 1] }
-	    -t*	{ set opts(-type) [lindex $args 1] }
-	    -w*	{ set opts(-wrap) [lindex $args 1] }
-	    --	{ set args [lreplace $args 0 0]; break }
-	    default {return -code error "unknown option \"[lindex $args 0]\""}
-	}
-	set args [lreplace $args 0 1]
-    }
-    # determine who we are dealing with
-    if {[llength $opts(-attach)]} {
-	foreach {app type} $opts(-attach) {break}
-    } else {
-	foreach {app type} [tkcon attach] {break}
-    }
-
-    set word [lindex $args 0]
-    if {$opts(-type) == {}} {
-	if {[llength [::tkcon::EvalOther $app $type info commands [list $word]]]} {
-	    set opts(-type) "proc"
-	} elseif {[llength [::tkcon::EvalOther $app $type info vars [list $word]]]} {
-	    set opts(-type) "var"
-	} elseif {[::tkcon::EvalOther $app $type file isfile [list $word]]} {
-	    set opts(-type) "file"
-	}
-    }
-    if {$opts(-type) == {}} {
-	return -code error "unrecognized type '$word'"
-    }
-
-    # Create unique edit window toplevel
-    set w $::tkcon::PRIV(base).__edit
-    set i 0
-    while {[winfo exists $w[incr i]]} {}
-    append w $i
-    toplevel $w
-    wm withdraw $w
-    if {[string length $word] > 20} {
-	wm title $w "[string range $word 0 16]... - tkcon Edit"
-    } else {
-	wm title $w "$word - tkcon Edit"
-    }
-
-    if {[package provide ctext] != ""} {
-	set txt [ctext $w.text]
-    } else {
-	set txt [text $w.text]
-    }
-    $w.text configure -wrap $opts(-wrap) \
-	-xscrollcommand [list $w.sx set] \
-	-yscrollcommand [list $w.sy set] \
-	-foreground $::tkcon::COLOR(stdin) \
-	-background $::tkcon::COLOR(bg) \
-	-insertbackground $::tkcon::COLOR(cursor) \
-	-font $::tkcon::OPT(font) -borderwidth 1 -highlightthickness 0
-    catch {
-	# 8.4+ stuff
-	$w.text configure -undo 1
-    }
-    scrollbar $w.sx -orient h -command [list $w.text xview]
-    scrollbar $w.sy -orient v -command [list $w.text yview]
-
-    set menu [menu $w.mbar]
-    $w configure -menu $menu
-
-    ## File Menu
-    ##
-    set m [menu [::tkcon::MenuButton $menu File file]]
-    $m add command -label "Save As..."  -underline 0 \
-	-command [list ::tkcon::Save {} widget $w.text]
-    $m add command -label "Append To..."  -underline 0 \
-	-command [list ::tkcon::Save {} widget $w.text a+]
-    $m add separator
-    $m add command -label "Dismiss" -underline 0 -accel "Ctrl-w" \
-	-command [list destroy $w]
-    bind $w <Control-w>			[list destroy $w]
-    bind $w <$::tkcon::PRIV(meta)-w>	[list destroy $w]
-
-    ## Edit Menu
-    ##
-    set text $w.text
-    set m [menu [::tkcon::MenuButton $menu Edit edit]]
-    $m add command -label "Cut"   -under 2 \
-	-command [list tk_textCut $text]
-    $m add command -label "Copy"  -under 0 \
-	-command [list tk_textCopy $text]
-    $m add command -label "Paste" -under 0 \
-	-command [list tk_textPaste $text]
-    $m add separator
-    $m add command -label "Find" -under 0 \
-	-command [list ::tkcon::FindBox $text]
-
-    ## Send To Menu
-    ##
-    set m [menu [::tkcon::MenuButton $menu "Send To..." send]]
-    $m add command -label "Send To $app" -underline 0 \
-	-command "::tkcon::EvalOther [list $app] $type \
-		eval \[$w.text get 1.0 end-1c\]"
-    set other [tkcon attach]
-    if {[string compare $other [list $app $type]]} {
-	$m add command -label "Send To [lindex $other 0]" \
-	    -command "::tkcon::EvalOther $other \
-		    eval \[$w.text get 1.0 end-1c\]"
-    }
-
-    grid $w.text - $w.sy -sticky news
-    grid $w.sx - -sticky ew
-    grid columnconfigure $w 0 -weight 1
-    grid columnconfigure $w 1 -weight 1
-    grid rowconfigure $w 0 -weight 1
-
-    switch -glob -- $opts(-type) {
-	proc*	{
-	    $w.text insert 1.0 \
-		    [::tkcon::EvalOther $app $type dump proc [list $word]]
-	    after idle [::tkcon::Highlight $w.text tcl]
-	}
-	var*	{
-	    $w.text insert 1.0 \
-		    [::tkcon::EvalOther $app $type dump var [list $word]]
-	    after idle [::tkcon::Highlight $w.text tcl]
-	}
-	file	{
-	    $w.text insert 1.0 [::tkcon::EvalOther $app $type eval \
-		    [subst -nocommands {
-		set __tkcon(fid) [open {$word} r]
-		set __tkcon(data) [read \$__tkcon(fid)]
-		close \$__tkcon(fid)
-		after 1000 unset __tkcon
-		return \$__tkcon(data)
-	    }
-	    ]]
-	    after idle [::tkcon::Highlight $w.text \
-			    [string trimleft [file extension $word] .]]
-	}
-	error*	{
-	    $w.text insert 1.0 [join $args \n]
-	    after idle [::tkcon::Highlight $w.text error]
-	}
-	default	{
-	    $w.text insert 1.0 [join $args \n]
-	}
-    }
-    wm deiconify $w
-    focus $w.text
-    if {[string compare $opts(-find) {}]} {
-	::tkcon::Find $w.text $opts(-find) -case 1
-    }
-}
-interp alias {} ::more {} ::edit
-interp alias {} ::less {} ::edit
-
-## echo
-## Relaxes the one string restriction of 'puts'
-# ARGS:	any number of strings to output to stdout
-##
-proc echo args { puts stdout [concat $args] }
-
-## clear - clears the buffer of the console (not the history though)
-## This is executed in the parent interpreter
-## 
-proc clear {{pcnt 100}} {
-    if {![regexp {^[0-9]*$} $pcnt] || $pcnt < 1 || $pcnt > 100} {
-	return -code error \
-		"invalid percentage to clear: must be 1-100 (100 default)"
-    } elseif {$pcnt == 100} {
-	tkcon console delete 1.0 end
-    } else {
-	set tmp [expr {$pcnt/100.0*[tkcon console index end]}]
-	tkcon console delete 1.0 "$tmp linestart"
-    }
-}
-
-## alias - akin to the csh alias command
-## If called with no args, then it dumps out all current aliases
-## If called with one arg, returns the alias of that arg (or {} if none)
-# ARGS:	newcmd	- (optional) command to bind alias to
-# 	args	- command and args being aliased
-## 
-proc alias {{newcmd {}} args} {
-    if {[string match {} $newcmd]} {
-	set res {}
-	foreach a [interp aliases] {
-	    lappend res [list $a -> [interp alias {} $a]]
-	}
-	return [join $res \n]
-    } elseif {![llength $args]} {
-	interp alias {} $newcmd
-    } else {
-	eval interp alias [list {} $newcmd {}] $args
-    }
-}
-
-## unalias - unaliases an alias'ed command
-# ARGS:	cmd	- command to unbind as an alias
-## 
-proc unalias {cmd} {
-    interp alias {} $cmd {}
-}
-
-## dump - outputs variables/procedure/widget info in source'able form.
-## Accepts glob style pattern matching for the names
-#
-# ARGS:	type	- type of thing to dump: must be variable, procedure, widget
-#
-# OPTS: -nocomplain
-#		don't complain if no items of the specified type are found
-#	-filter pattern
-#		specifies a glob filter pattern to be used by the variable
-#		method as an array filter pattern (it filters down for
-#		nested elements) and in the widget method as a config
-#		option filter pattern
-#	--	forcibly ends options recognition
-#
-# Returns:	the values of the requested items in a 'source'able form
-## 
-proc dump {type args} {
-    set whine 1
-    set code  ok
-    if {![llength $args]} {
-	## If no args, assume they gave us something to dump and
-	## we'll try anything
-	set args $type
-	set type any
-    }
-    while {[string match -* [lindex $args 0]]} {
-	switch -glob -- [lindex $args 0] {
-	    -n* { set whine 0; set args [lreplace $args 0 0] }
-	    -f* { set fltr [lindex $args 1]; set args [lreplace $args 0 1] }
-	    --  { set args [lreplace $args 0 0]; break }
-	    default {return -code error "unknown option \"[lindex $args 0]\""}
-	}
-    }
-    if {$whine && ![llength $args]} {
-	return -code error "wrong \# args: [lindex [info level 0] 0] type\
-		?-nocomplain? ?-filter pattern? ?--? pattern ?pattern ...?"
-    }
-    set res {}
-    switch -glob -- $type {
-	c* {
-	    # command
-	    # outputs commands by figuring out, as well as possible, what it is
-	    # this does not attempt to auto-load anything
-	    foreach arg $args {
-		if {[llength [set cmds [info commands $arg]]]} {
-		    foreach cmd [lsort $cmds] {
-			if {[lsearch -exact [interp aliases] $cmd] > -1} {
-			    append res "\#\# ALIAS:   $cmd =>\
-				    [interp alias {} $cmd]\n"
-			} elseif {
-			    [llength [info procs $cmd]] ||
-			    ([string match *::* $cmd] &&
-			    [llength [namespace eval [namespace qual $cmd] \
-				    info procs [namespace tail $cmd]]])
-			} {
-			    if {[catch {dump p -- $cmd} msg] && $whine} {
-				set code error
-			    }
-			    append res $msg\n
-			} else {
-			    append res "\#\# COMMAND: $cmd\n"
-			}
-		    }
-		} elseif {$whine} {
-		    append res "\#\# No known command $arg\n"
-		    set code error
-		}
-	    }
-	}
-	v* {
-	    # variable
-	    # outputs variables value(s), whether array or simple.
-	    if {![info exists fltr]} { set fltr * }
-	    foreach arg $args {
-		if {![llength [set vars [uplevel 1 info vars [list $arg]]]]} {
-		    if {[uplevel 1 info exists $arg]} {
-			set vars $arg
-		    } elseif {$whine} {
-			append res "\#\# No known variable $arg\n"
-			set code error
-			continue
-		    } else { continue }
-		}
-		foreach var [lsort $vars] {
-		    if {[uplevel 1 [list info locals $var]] == ""} {
-			# use the proper scope of the var, but namespace which
-			# won't id locals or some upvar'ed vars correctly
-			set new [uplevel 1 \
-				[list namespace which -variable $var]]
-			if {$new != ""} {
-			    set var $new
-			}
-		    }
-		    upvar 1 $var v
-		    if {[array exists v] || [catch {string length $v}]} {
-			set nst {}
-			append res "array set [list $var] \{\n"
-			if {[array size v]} {
-			    foreach i \
-				    [lsort -dictionary [array names v $fltr]] {
-				upvar 0 v\($i\) __a
-				if {[array exists __a]} {
-				    append nst "\#\# NESTED ARRAY ELEM: $i\n"
-				    append nst "upvar 0 [list $var\($i\)] __a;\
-					    [dump v -filter $fltr __a]\n"
-				} else {
-				    append res "    [list $i]\t[list $v($i)]\n"
-				}
-			    }
-			} else {
-			    ## empty array
-			    append res "    empty array\n"
-			    if {$var == ""} {
-				append nst "unset (empty)\n"
-			    } else {
-				append nst "unset [list $var](empty)\n"
-			    }
-			}
-			append res "\}\n$nst"
-		    } else {
-			append res [list set $var $v]\n
-		    }
-		}
-	    }
-	}
-	p* {
-	    # procedure
-	    foreach arg $args {
-		if {
-		    ![llength [set procs [info proc $arg]]] &&
-		    ([string match *::* $arg] &&
-		    [llength [set ps [namespace eval \
-			    [namespace qualifier $arg] \
-			    info procs [namespace tail $arg]]]])
-		} {
-		    set procs {}
-		    set namesp [namespace qualifier $arg]
-		    foreach p $ps {
-			lappend procs ${namesp}::$p
-		    }
-		}
-		if {[llength $procs]} {
-		    foreach p [lsort $procs] {
-			set as {}
-			foreach a [info args $p] {
-			    if {[info default $p $a tmp]} {
-				lappend as [list $a $tmp]
-			    } else {
-				lappend as $a
-			    }
-			}
-			append res [list proc $p $as [info body $p]]\n
-		    }
-		} elseif {$whine} {
-		    append res "\#\# No known proc $arg\n"
-		    set code error
-		}
-	    }
-	}
-	w* {
-	    # widget
-	    ## The user should have Tk loaded
-	    if {![llength [info command winfo]]} {
-		return -code error "winfo not present, cannot dump widgets"
-	    }
-	    if {![info exists fltr]} { set fltr .* }
-	    foreach arg $args {
-		if {[llength [set ws [info command $arg]]]} {
-		    foreach w [lsort $ws] {
-			if {[winfo exists $w]} {
-			    if {[catch {$w configure} cfg]} {
-				append res "\#\# Widget $w\
-					does not support configure method"
-				set code error
-			    } else {
-				append res "\#\# [winfo class $w]\
-					$w\n$w configure"
-				foreach c $cfg {
-				    if {[llength $c] != 5} continue
-				    ## Check to see that the option does
-				    ## not match the default, then check
-				    ## the item against the user filter
-				    if {[string compare [lindex $c 3] \
-					    [lindex $c 4]] && \
-					    [regexp -nocase -- $fltr $c]} {
-					append res " \\\n\t[list [lindex $c 0]\
-						[lindex $c 4]]"
-				    }
-				}
-				append res \n
-			    }
-			}
-		    }
-		} elseif {$whine} {
-		    append res "\#\# No known widget $arg\n"
-		    set code error
-		}
-	    }
-	}
-	a* {
-	    ## see if we recognize it, other complain
-	    if {[regexp {(var|com|proc|widget)} \
-		    [set types [uplevel 1 what $args]]]} {
-		foreach type $types {
-		    if {[regexp {(var|com|proc|widget)} $type]} {
-			append res "[uplevel 1 dump $type $args]\n"
-		    }
-		}
-	    } else {
-		set res "dump was unable to resolve type for \"$args\""
-		set code error
-	    }
-	}
-	default {
-	    return -code error "bad [lindex [info level 0] 0] option\
-		    \"$type\": must be variable, command, procedure,\
-		    or widget"
-	}
-    }
-    return -code $code [string trimright $res \n]
-}
-
-## idebug - interactive debugger
-#
-# idebug body ?level?
-#
-#	Prints out the body of the command (if it is a procedure) at the
-#	specified level.  <i>level</i> defaults to the current level.
-#
-# idebug break
-#
-#	Creates a breakpoint within a procedure.  This will only trigger
-#	if idebug is on and the id matches the pattern.  If so, TkCon will
-#	pop to the front with the prompt changed to an idebug prompt.  You
-#	are given the basic ability to observe the call stack an query/set
-#	variables or execute Tcl commands at any level.  A separate history
-#	is maintained in debugging mode.
-#
-# idebug echo|{echo ?id?} ?args?
-#
-#	Behaves just like "echo", but only triggers when idebug is on.
-#	You can specify an optional id to further restrict triggering.
-#	If no id is specified, it defaults to the name of the command
-#	in which the call was made.
-#
-# idebug id ?id?
-#
-#	Query or set the idebug id.  This id is used by other idebug
-#	methods to determine if they should trigger or not.  The idebug
-#	id can be a glob pattern and defaults to *.
-#
-# idebug off
-#
-#	Turns idebug off.
-#
-# idebug on ?id?
-#
-#	Turns idebug on.  If 'id' is specified, it sets the id to it.
-#
-# idebug puts|{puts ?id?} args
-#
-#	Behaves just like "puts", but only triggers when idebug is on.
-#	You can specify an optional id to further restrict triggering.
-#	If no id is specified, it defaults to the name of the command
-#	in which the call was made.
-#
-# idebug show type ?level? ?VERBOSE?
-#
-#	'type' must be one of vars, locals or globals.  This method
-#	will output the variables/locals/globals present in a particular
-#	level.  If VERBOSE is added, then it actually 'dump's out the
-#	values as well.  'level' defaults to the level in which this
-#	method was called.
-#
-# idebug trace ?level?
-#
-#	Prints out the stack trace from the specified level up to the top
-#	level.  'level' defaults to the current level.
-#
-##
-proc idebug {opt args} {
-    global IDEBUG
-
-    if {![info exists IDEBUG(on)]} {
-	array set IDEBUG { on 0 id * debugging 0 }
-    }
-    set level [expr {[info level]-1}]
-    switch -glob -- $opt {
-	on	{
-	    if {[llength $args]} { set IDEBUG(id) $args }
-	    return [set IDEBUG(on) 1]
-	}
-	off	{ return [set IDEBUG(on) 0] }
-	id  {
-	    if {![llength $args]} {
-		return $IDEBUG(id)
-	    } else { return [set IDEBUG(id) $args] }
-	}
-	break {
-	    if {!$IDEBUG(on) || $IDEBUG(debugging) || \
-		    ([llength $args] && \
-		    ![string match $IDEBUG(id) $args]) || [info level]<1} {
-		return
-	    }
-	    set IDEBUG(debugging) 1
-	    puts stderr "idebug at level \#$level: [lindex [info level -1] 0]"
-	    set tkcon [llength [info command tkcon]]
-	    if {$tkcon} {
-		tkcon master eval set ::tkcon::OPT(prompt2) \$::tkcon::OPT(prompt1)
-		tkcon master eval set ::tkcon::OPT(prompt1) \$::tkcon::OPT(debugPrompt)
-		set slave [tkcon set ::tkcon::OPT(exec)]
-		set event [tkcon set ::tkcon::PRIV(event)]
-		tkcon set ::tkcon::OPT(exec) [tkcon master interp create debugger]
-		tkcon set ::tkcon::PRIV(event) 1
-	    }
-	    set max $level
-	    while 1 {
-		set err {}
-		if {$tkcon} {
-		    # tkcon's overload of gets is advanced enough to not need
-		    # this, but we get a little better control this way.
-		    tkcon evalSlave set level $level
-		    tkcon prompt
-		    set line [tkcon getcommand]
-		    tkcon console mark set output end
-		} else {
-		    puts -nonewline stderr "(level \#$level) debug > "
-		    gets stdin line
-		    while {![info complete $line]} {
-			puts -nonewline "> "
-			append line "\n[gets stdin]"
-		    }
-		}
-		if {[string match {} $line]} continue
-		set key [lindex $line 0]
-		if {![regexp {^([#-]?[0-9]+)} [lreplace $line 0 0] lvl]} {
-		    set lvl \#$level
-		}
-		set res {}; set c 0
-		switch -- $key {
-		    + {
-			## Allow for jumping multiple levels
-			if {$level < $max} {
-			    idebug trace [incr level] $level 0 VERBOSE
-			}
-		    }
-		    - {
-			## Allow for jumping multiple levels
-			if {$level > 1} {
-			    idebug trace [incr level -1] $level 0 VERBOSE
-			}
-		    }
-		    . { set c [catch {idebug trace $level $level 0 VERBOSE} res] }
-		    v { set c [catch {idebug show vars $lvl } res] }
-		    V { set c [catch {idebug show vars $lvl VERBOSE} res] }
-		    l { set c [catch {idebug show locals $lvl } res] }
-		    L { set c [catch {idebug show locals $lvl VERBOSE} res] }
-		    g { set c [catch {idebug show globals $lvl } res] }
-		    G { set c [catch {idebug show globals $lvl VERBOSE} res] }
-		    t { set c [catch {idebug trace 1 $max $level } res] }
-		    T { set c [catch {idebug trace 1 $max $level VERBOSE} res]}
-		    b { set c [catch {idebug body $lvl} res] }
-		    o { set res [set IDEBUG(on) [expr {!$IDEBUG(on)}]] }
-		    h - ?	{
-			puts stderr "    +		Move down in call stack
-    -		Move up in call stack
-    .		Show current proc name and params
-
-    v		Show names of variables currently in scope
-    V		Show names of variables currently in scope with values
-    l		Show names of local (transient) variables
-    L		Show names of local (transient) variables with values
-    g		Show names of declared global variables
-    G		Show names of declared global variables with values
-    t		Show a stack trace
-    T		Show a verbose stack trace
-
-    b		Show body of current proc
-    o		Toggle on/off any further debugging
-    c,q		Continue regular execution (Quit debugger)
-    h,?		Print this help
-    default	Evaluate line at current level (\#$level)"
-		    }
-		    c - q break
-		    default { set c [catch {uplevel \#$level $line} res] }
-		}
-		if {$tkcon} {
-		    tkcon set ::tkcon::PRIV(event) \
-			    [tkcon evalSlave eval history add [list $line]\
-			    \; history nextid]
-		}
-		if {$c} {
-		    puts stderr $res
-		} elseif {[string compare {} $res]} {
-		    puts $res
-		}
-	    }
-	    set IDEBUG(debugging) 0
-	    if {$tkcon} {
-		tkcon master interp delete debugger
-		tkcon master eval set ::tkcon::OPT(prompt1) \$::tkcon::OPT(prompt2)
-		tkcon set ::tkcon::OPT(exec) $slave
-		tkcon set ::tkcon::PRIV(event) $event
-		tkcon prompt
-	    }
-	}
-	bo* {
-	    if {[regexp {^([#-]?[0-9]+)} $args level]} {
-		return [uplevel $level {dump c -no [lindex [info level 0] 0]}]
-	    }
-	}
-	t* {
-	    if {[llength $args]<2} return
-	    set min [set max [set lvl $level]]
-	    set exp {^#?([0-9]+)? ?#?([0-9]+) ?#?([0-9]+)? ?(VERBOSE)?}
-	    if {![regexp $exp $args junk min max lvl verbose]} return
-	    for {set i $max} {
-		$i>=$min && ![catch {uplevel \#$i info level 0} info]
-	    } {incr i -1} {
-		if {$i==$lvl} {
-		    puts -nonewline stderr "* \#$i:\t"
-		} else {
-		    puts -nonewline stderr "  \#$i:\t"
-		}
-		set name [lindex $info 0]
-		if {[string compare VERBOSE $verbose] || \
-			![llength [info procs $name]]} {
-		    puts $info
-		} else {
-		    puts "proc $name {[info args $name]} { ... }"
-		    set idx 0
-		    foreach arg [info args $name] {
-			if {[string match args $arg]} {
-			    puts "\t$arg = [lrange $info [incr idx] end]"
-			    break
-			} else {
-			    puts "\t$arg = [lindex $info [incr idx]]"
-			}
-		    }
-		}
-	    }
-	}
-	s* {
-	    #var, local, global
-	    set level \#$level
-	    if {![regexp {^([vgl][^ ]*) ?([#-]?[0-9]+)? ?(VERBOSE)?} \
-		    $args junk type level verbose]} return
-	    switch -glob -- $type {
-		v* { set vars [uplevel $level {lsort [info vars]}] }
-		l* { set vars [uplevel $level {lsort [info locals]}] }
-		g* { set vars [lremove [uplevel $level {info vars}] \
-			[uplevel $level {info locals}]] }
-	    }
-	    if {[string match VERBOSE $verbose]} {
-		return [uplevel $level dump var -nocomplain $vars]
-	    } else {
-		return $vars
-	    }
-	}
-	e* - pu* {
-	    if {[llength $opt]==1 && [catch {lindex [info level -1] 0} id]} {
-		set id [lindex [info level 0] 0]
-	    } else {
-		set id [lindex $opt 1]
-	    }
-	    if {$IDEBUG(on) && [string match $IDEBUG(id) $id]} {
-		if {[string match e* $opt]} {
-		    puts [concat $args]
-		} else { eval puts $args }
-	    }
-	}
-	default {
-	    return -code error "bad [lindex [info level 0] 0] option \"$opt\",\
-		    must be: [join [lsort [list on off id break print body\
-		    trace show puts echo]] {, }]"
-	}
-    }
-}
-
-## observe - like trace, but not
-# ARGS:	opt	- option
-#	name	- name of variable or command
-##
-proc observe {opt name args} {
-    global tcl_observe
-    switch -glob -- $opt {
-	co* {
-	    if {[regexp {^(catch|lreplace|set|puts|for|incr|info|uplevel)$} \
-		    $name]} {
-		return -code error "cannot observe \"$name\":\
-			infinite eval loop will occur"
-	    }
-	    set old ${name}@
-	    while {[llength [info command $old]]} { append old @ }
-	    rename $name $old
-	    set max 4
-	    regexp {^[0-9]+} $args max
-	    # handle the observe'ing of 'proc'
-	    set proccmd "proc"
-	    if {[string match "proc" $name]} { set proccmd $old }
-	    ## idebug trace could be used here
-	    $proccmd $name args "
-	    for {set i \[info level\]; set max \[expr \[info level\]-$max\]} {
-		\$i>=\$max && !\[catch {uplevel \#\$i info level 0} info\]
-	    } {incr i -1} {
-		puts -nonewline stderr \"  \#\$i:\t\"
-		puts \$info
-	    }
-	    uplevel \[lreplace \[info level 0\] 0 0 $old\]
-	    "
-	    set tcl_observe($name) $old
-	}
-	cd* {
-	    if {[info exists tcl_observe($name)] && [catch {
-		rename $name {}
-		rename $tcl_observe($name) $name
-		unset tcl_observe($name)
-	    } err]} { return -code error $err }
-	}
-	ci* {
-	    ## What a useless method...
-	    if {[info exists tcl_observe($name)]} {
-		set i $tcl_observe($name)
-		set res "\"$name\" observes true command \"$i\""
-		while {[info exists tcl_observe($i)]} {
-		    append res "\n\"$name\" observes true command \"$i\""
-		    set i $tcl_observe($name)
-		}
-		return $res
-	    }
-	}
-	va* - vd* {
-	    set type [lindex $args 0]
-	    set args [lrange $args 1 end]
-	    if {![regexp {^[rwu]} $type type]} {
-		return -code error "bad [lindex [info level 0] 0] $opt type\
-			\"$type\", must be: read, write or unset"
-	    }
-	    if {![llength $args]} { set args observe_var }
-	    foreach c [uplevel 1 [list trace vinfo $name]] {
-		# don't double up on the traces
-		if {[list $type $args] == $c} { return }
-	    }
-	    uplevel 1 [list trace $opt $name $type $args]
-	}
-	vi* {
-	    uplevel 1 [list trace vinfo $name]
-	}
-	default {
-	    return -code error "bad [lindex [info level 0] 0] option\
-		    \"[lindex $args 0]\", must be: [join [lsort \
-		    [list command cdelete cinfo variable vdelete vinfo]] {, }]"
-	}
-    }
-}
-
-## observe_var - auxilary function for observing vars, called by trace
-## via observe
-# ARGS:	name	- variable name
-#	el	- array element name, if any
-#	op	- operation type (rwu)
-##
-proc observe_var {name el op} {
-    if {[string match u $op]} {
-	if {[string compare {} $el]} {
-	    puts "unset \"${name}($el)\""
-	} else {
-	    puts "unset \"$name\""
-	}
-    } else {
-	upvar 1 $name $name
-	if {[info exists ${name}($el)]} {
-	    puts [dump v ${name}($el)]
-	} else {
-	    puts [dump v $name]
-	}
-    }
-}
-
-## which - tells you where a command is found
-# ARGS:	cmd	- command name
-# Returns:	where command is found (internal / external / unknown)
-## 
-proc which cmd {
-    ## This tries to auto-load a command if not recognized
-    set types [uplevel 1 [list what $cmd 1]]
-    if {[llength $types]} {
-	set out {}
-	
-	foreach type $types {
-	    switch -- $type {
-		alias		{ set res "$cmd: aliased to [alias $cmd]" }
-		procedure	{ set res "$cmd: procedure" }
-		command		{ set res "$cmd: internal command" }
-		executable	{ lappend out [auto_execok $cmd] }
-		variable	{ lappend out "$cmd: $type" }
-	    }
-	    if {[info exists res]} {
-		global auto_index
-		if {[info exists auto_index($cmd)]} {
-		    ## This tells you where the command MIGHT have come from -
-		    ## not true if the command was redefined interactively or
-		    ## existed before it had to be auto_loaded.  This is just
-		    ## provided as a hint at where it MAY have come from
-		    append res " ($auto_index($cmd))"
-		}
-		lappend out $res
-		unset res
-	    }
-	}
-	return [join $out \n]
-    } else {
-	return -code error "$cmd: command not found"
-    }
-}
-
-## what - tells you what a string is recognized as
-# ARGS:	str	- string to id
-# Returns:	id types of command as list
-## 
-proc what {str {autoload 0}} {
-    set types {}
-    if {[llength [info commands $str]] || ($autoload && \
-	    [auto_load $str] && [llength [info commands $str]])} {
-	if {[lsearch -exact [interp aliases] $str] > -1} {
-	    lappend types "alias"
-	} elseif {
-	    [llength [info procs $str]] ||
-	    ([string match *::* $str] &&
-	    [llength [namespace eval [namespace qualifier $str] \
-		    info procs [namespace tail $str]]])
-	} {
-	    lappend types "procedure"
-	} else {
-	    lappend types "command"
-	}
-    }
-    if {[llength [uplevel 1 info vars $str]]} {
-	upvar 1 $str var
-	if {[array exists var]} {
-	    lappend types array variable
-	} else {
-	    lappend types scalar variable
-	}
-    }
-    if {[file isdirectory $str]} {
-	lappend types "directory"
-    }
-    if {[file isfile $str]} {
-	lappend types "file"
-    }
-    if {[llength [info commands winfo]] && [winfo exists $str]} {
-	lappend types "widget"
-    }
-    if {[string compare {} [auto_execok $str]]} {
-	lappend types "executable"
-    }
-    return $types
-}
-
-## dir - directory list
-# ARGS:	args	- names/glob patterns of directories to list
-# OPTS:	-all	- list hidden files as well (Unix dot files)
-#	-long	- list in full format "permissions size date filename"
-#	-full	- displays / after directories and link paths for links
-# Returns:	a directory listing
-## 
-proc dir {args} {
-    array set s {
-	all 0 full 0 long 0
-	0 --- 1 --x 2 -w- 3 -wx 4 r-- 5 r-x 6 rw- 7 rwx
-    }
-    while {[string match \-* [lindex $args 0]]} {
-	set str [lindex $args 0]
-	set args [lreplace $args 0 0]
-	switch -glob -- $str {
-	    -a* {set s(all) 1} -f* {set s(full) 1}
-	    -l* {set s(long) 1} -- break
-	    default {
-		return -code error "unknown option \"$str\",\
-			should be one of: -all, -full, -long"
-	    }
-	}
-    }
-    set sep [string trim [file join . .] .]
-    if {![llength $args]} { set args [list [pwd]] }
-    if {$::tcl_version >= 8.3} {
-	# Newer glob args allow safer dir processing.  The user may still
-	# want glob chars, but really only for file matching.
-	foreach arg $args {
-	    if {[file isdirectory $arg]} {
-		if {$s(all)} {
-		    lappend out [list $arg [lsort \
-			    [glob -nocomplain -directory $arg .* *]]]
-		} else {
-		    lappend out [list $arg [lsort \
-			    [glob -nocomplain -directory $arg *]]]
-		}
-	    } else {
-		set dir [file dirname $arg]
-		lappend out [list $dir$sep [lsort \
-			[glob -nocomplain -directory $dir [file tail $arg]]]]
-	    }
-	}
-    } else {
-	foreach arg $args {
-	    if {[file isdirectory $arg]} {
-		set arg [string trimright $arg $sep]$sep
-		if {$s(all)} {
-		    lappend out [list $arg [lsort [glob -nocomplain -- $arg.* $arg*]]]
-		} else {
-		    lappend out [list $arg [lsort [glob -nocomplain -- $arg*]]]
-		}
-	    } else {
-		lappend out [list [file dirname $arg]$sep \
-			[lsort [glob -nocomplain -- $arg]]]
-	    }
-	}
-    }
-    if {$s(long)} {
-	set old [clock scan {1 year ago}]
-	set fmt "%s%9ld %s %s\n"
-	foreach o $out {
-	    set d [lindex $o 0]
-	    append res $d:\n
-	    foreach f [lindex $o 1] {
-		file lstat $f st
-		set f [file tail $f]
-		if {$s(full)} {
-		    switch -glob $st(type) {
-			d* { append f $sep }
-			l* { append f "@ -> [file readlink $d$sep$f]" }
-			default { if {[file exec $d$sep$f]} { append f * } }
-		    }
-		}
-		if {[string match file $st(type)]} {
-		    set mode -
-		} else {
-		    set mode [string index $st(type) 0]
-		}
-		foreach j [split [format %03o [expr {$st(mode)&0777}]] {}] {
-		    append mode $s($j)
-		}
-		if {$st(mtime)>$old} {
-		    set cfmt {%b %d %H:%M}
-		} else {
-		    set cfmt {%b %d  %Y}
-		}
-		append res [format $fmt $mode $st(size) \
-			[clock format $st(mtime) -format $cfmt] $f]
-	    }
-	    append res \n
-	}
-    } else {
-	foreach o $out {
-	    set d [lindex $o 0]
-	    append res "$d:\n"
-	    set i 0
-	    foreach f [lindex $o 1] {
-		if {[string len [file tail $f]] > $i} {
-		    set i [string len [file tail $f]]
-		}
-	    }
-	    set i [expr {$i+2+$s(full)}]
-	    set j 80
-	    ## This gets the number of cols in the tkcon console widget
-	    if {[llength [info commands tkcon]]} {
-		set j [expr {[tkcon master set ::tkcon::OPT(cols)]/$i}]
-	    }
-	    set k 0
-	    foreach f [lindex $o 1] {
-		set f [file tail $f]
-		if {$s(full)} {
-		    switch -glob [file type $d$sep$f] {
-			d* { append f $sep }
-			l* { append f @ }
-			default { if {[file exec $d$sep$f]} { append f * } }
-		    }
-		}
-		append res [format "%-${i}s" $f]
-		if {$j == 0 || [incr k]%$j == 0} {
-		    set res [string trimright $res]\n
-		}
-	    }
-	    append res \n\n
-	}
-    }
-    return [string trimright $res]
-}
-interp alias {} ::ls {} ::dir -full
-
-## lremove - remove items from a list
-# OPTS:
-#   -all	remove all instances of each item
-#   -glob	remove all instances matching glob pattern
-#   -regexp	remove all instances matching regexp pattern
-# ARGS:	l	a list to remove items from
-#	args	items to remove (these are 'join'ed together)
-##
-proc lremove {args} {
-    array set opts {-all 0 pattern -exact}
-    while {[string match -* [lindex $args 0]]} {
-	switch -glob -- [lindex $args 0] {
-	    -a*	{ set opts(-all) 1 }
-	    -g*	{ set opts(pattern) -glob }
-	    -r*	{ set opts(pattern) -regexp }
-	    --	{ set args [lreplace $args 0 0]; break }
-	    default {return -code error "unknown option \"[lindex $args 0]\""}
-	}
-	set args [lreplace $args 0 0]
-    }
-    set l [lindex $args 0]
-    foreach i [join [lreplace $args 0 0]] {
-	if {[set ix [lsearch $opts(pattern) $l $i]] == -1} continue
-	set l [lreplace $l $ix $ix]
-	if {$opts(-all)} {
-	    while {[set ix [lsearch $opts(pattern) $l $i]] != -1} {
-		set l [lreplace $l $ix $ix]
-	    }
-	}
-    }
-    return $l
-}
-
-if {!$::tkcon::PRIV(WWW)} {;
-
-## Unknown changed to get output into tkcon window
-# unknown:
-# Invoked automatically whenever an unknown command is encountered.
-# Works through a list of "unknown handlers" that have been registered
-# to deal with unknown commands.  Extensions can integrate their own
-# handlers into the 'unknown' facility via 'unknown_handler'.
-#
-# If a handler exists that recognizes the command, then it will
-# take care of the command action and return a valid result or a
-# Tcl error.  Otherwise, it should return "-code continue" (=2)
-# and responsibility for the command is passed to the next handler.
-#
-# Arguments:
-# args -	A list whose elements are the words of the original
-#		command, including the command name.
-
-proc unknown args {
-    global unknown_handler_order unknown_handlers errorInfo errorCode
-
-    #
-    # Be careful to save error info now, and restore it later
-    # for each handler.  Some handlers generate their own errors
-    # and disrupt handling.
-    #
-    set savedErrorCode $errorCode
-    set savedErrorInfo $errorInfo
-
-    if {![info exists unknown_handler_order] || \
-	    ![info exists unknown_handlers]} {
-	set unknown_handlers(tcl) tcl_unknown
-	set unknown_handler_order tcl
-    }
-
-    foreach handler $unknown_handler_order {
-        set status [catch {uplevel 1 $unknown_handlers($handler) $args} result]
-
-        if {$status == 1} {
-            #
-            # Strip the last five lines off the error stack (they're
-            # from the "uplevel" command).
-            #
-            set new [split $errorInfo \n]
-            set new [join [lrange $new 0 [expr {[llength $new]-6}]] \n]
-            return -code $status -errorcode $errorCode \
-                -errorinfo $new $result
-
-        } elseif {$status != 4} {
-            return -code $status $result
-        }
-
-        set errorCode $savedErrorCode
-        set errorInfo $savedErrorInfo
-    }
-
-    set name [lindex $args 0]
-    return -code error "invalid command name \"$name\""
-}
-
-# tcl_unknown:
-# Invoked when a Tcl command is invoked that doesn't exist in the
-# interpreter:
-#
-#	1. See if the autoload facility can locate the command in a
-#	   Tcl script file.  If so, load it and execute it.
-#	2. If the command was invoked interactively at top-level:
-#	    (a) see if the command exists as an executable UNIX program.
-#		If so, "exec" the command.
-#	    (b) see if the command requests csh-like history substitution
-#		in one of the common forms !!, !<number>, or ^old^new.  If
-#		so, emulate csh's history substitution.
-#	    (c) see if the command is a unique abbreviation for another
-#		command.  If so, invoke the command.
-#
-# Arguments:
-# args -	A list whose elements are the words of the original
-#		command, including the command name.
-
-proc tcl_unknown args {
-    global auto_noexec auto_noload env unknown_pending tcl_interactive
-    global errorCode errorInfo
-
-    # If the command word has the form "namespace inscope ns cmd"
-    # then concatenate its arguments onto the end and evaluate it.
-
-    set cmd [lindex $args 0]
-    if {[regexp "^:*namespace\[ \t\n\]+inscope" $cmd] \
-	    && [llength $cmd] == 4} {
-        set arglist [lrange $args 1 end]
-	set ret [catch {uplevel 1 $cmd $arglist} result]
-        if {$ret == 0} {
-            return $result
-        } else {
-	    return -code $ret -errorcode $errorCode $result
-        }
-    }
-
-    # Save the values of errorCode and errorInfo variables, since they
-    # may get modified if caught errors occur below.  The variables will
-    # be restored just before re-executing the missing command.
-
-    set savedErrorCode $errorCode
-    set savedErrorInfo $errorInfo
-    set name [lindex $args 0]
-    if {![info exists auto_noload]} {
-	#
-	# Make sure we're not trying to load the same proc twice.
-	#
-	if {[info exists unknown_pending($name)]} {
-	    return -code error "self-referential recursion in \"unknown\" for command \"$name\""
-	}
-	set unknown_pending($name) pending
-	if {[llength [info args auto_load]]==1} {
-	    set ret [catch {auto_load $name} msg]
-	} else {
-	    set ret [catch {auto_load $name [uplevel 1 {namespace current}]} msg]
-	}
-	unset unknown_pending($name)
-	if {$ret} {
-	    return -code $ret -errorcode $errorCode \
-		    "error while autoloading \"$name\": $msg"
-	}
-	if {![array size unknown_pending]} { unset unknown_pending }
-	if {$msg} {
-	    set errorCode $savedErrorCode
-	    set errorInfo $savedErrorInfo
-	    set code [catch {uplevel 1 $args} msg]
-	    if {$code ==  1} {
-		#
-		# Strip the last five lines off the error stack (they're
-		# from the "uplevel" command).
-		#
-
-		set new [split $errorInfo \n]
-		set new [join [lrange $new 0 [expr {[llength $new]-6}]] \n]
-		return -code error -errorcode $errorCode \
-			-errorinfo $new $msg
-	    } else {
-		return -code $code $msg
-	    }
-	}
-    }
-    if {[info level] == 1 && [string match {} [info script]] \
-	    && [info exists tcl_interactive] && $tcl_interactive} {
-	if {![info exists auto_noexec]} {
-	    set new [auto_execok $name]
-	    if {[string compare {} $new]} {
-		set errorCode $savedErrorCode
-		set errorInfo $savedErrorInfo
-		if {[info exists ::tkcon::EXPECT] && $::tkcon::EXPECT && [package provide Expect] != ""} {
-		    return [tkcon expect [concat $new [lrange $args 1 end]]]
-		} else {
-		    return [uplevel 1 exec $new [lrange $args 1 end]]
-		}
-		#return [uplevel exec >&@stdout <@stdin $new [lrange $args 1 end]]
-	    }
-	}
-	set errorCode $savedErrorCode
-	set errorInfo $savedErrorInfo
-	##
-	## History substitution moved into ::tkcon::EvalCmd
-	##
-	if {[string compare $name "::"] == 0} {
-	    set name ""
-	}
-	if {$ret != 0} {
-	    return -code $ret -errorcode $errorCode \
-		"error in unknown while checking if \"$name\" is a unique command abbreviation: $msg"
-	}
-	set cmds [info commands $name*]
-	if {[llength $cmds] == 1} {
-	    return [uplevel 1 [lreplace $args 0 0 $cmds]]
-	}
-	if {[llength $cmds]} {
-	    if {$name == ""} {
-		return -code error "empty command name \"\""
-	    } else {
-		return -code error \
-			"ambiguous command name \"$name\": [lsort $cmds]"
-	    }
-	}
-	## We've got nothing so far
-	## Check and see if Tk wasn't loaded, but it appears to be a Tk cmd
-	if {![uplevel \#0 info exists tk_version]} {
-	    lappend tkcmds bell bind bindtags button \
-		    canvas checkbutton clipboard destroy \
-		    entry event focus font frame grab grid image \
-		    label labelframe listbox lower menu menubutton message \
-		    option pack panedwindow place radiobutton raise \
-		    scale scrollbar selection send spinbox \
-		    text tk tkwait toplevel winfo wm
-	    if {[lsearch -exact $tkcmds $name] >= 0 && \
-		    [tkcon master tk_messageBox -icon question -parent . \
-		    -title "Load Tk?" -type retrycancel -default retry \
-		    -message "This appears to be a Tk command, but Tk\
-		    has not yet been loaded.  Shall I retry the command\
-		    with loading Tk first?"] == "retry"} {
-		return [uplevel 1 "load {} Tk; $args"]
-	    }
-	}
-    }
-    return -code continue
-}
-
-} ; # end exclusionary code for WWW
-
-proc ::tkcon::Bindings {} {
-    variable PRIV
-    global tcl_platform tk_version
-
-    #-----------------------------------------------------------------------
-    # Elements of tkPriv that are used in this file:
-    #
-    # char -		Character position on the line;  kept in order
-    #			to allow moving up or down past short lines while
-    #			still remembering the desired position.
-    # mouseMoved -	Non-zero means the mouse has moved a significant
-    #			amount since the button went down (so, for example,
-    #			start dragging out a selection).
-    # prevPos -		Used when moving up or down lines via the keyboard.
-    #			Keeps track of the previous insert position, so
-    #			we can distinguish a series of ups and downs, all
-    #			in a row, from a new up or down.
-    # selectMode -	The style of selection currently underway:
-    #			char, word, or line.
-    # x, y -		Last known mouse coordinates for scanning
-    #			and auto-scanning.
-    #-----------------------------------------------------------------------
-
-    switch -glob $tcl_platform(platform) {
-	win*	{ set PRIV(meta) Alt }
-	mac*	{ set PRIV(meta) Command }
-	default	{ set PRIV(meta) Meta }
-    }
-
-    ## Get all Text bindings into TkConsole
-    foreach ev [bind Text] { bind TkConsole $ev [bind Text $ev] }
-    ## We really didn't want the newline insertion
-    bind TkConsole <Control-Key-o> {}
-
-    ## Now make all our virtual event bindings
-    foreach {ev key} [subst -nocommand -noback {
-	<<TkCon_Exit>>		<Control-q>
-	<<TkCon_New>>		<Control-N>
-	<<TkCon_NewTab>>	<Control-T>
-	<<TkCon_NextTab>>	<Control-Key-Tab>
-	<<TkCon_PrevTab>>	<Control-Shift-Key-Tab>
-	<<TkCon_Close>>		<Control-w>
-	<<TkCon_About>>		<Control-A>
-	<<TkCon_Help>>		<Control-H>
-	<<TkCon_Find>>		<Control-F>
-	<<TkCon_Slave>>		<Control-Key-1>
-	<<TkCon_Master>>	<Control-Key-2>
-	<<TkCon_Main>>		<Control-Key-3>
-	<<TkCon_Expand>>	<Key-Tab>
-	<<TkCon_ExpandFile>>	<Key-Escape>
-	<<TkCon_ExpandProc>>	<Control-P>
-	<<TkCon_ExpandVar>>	<Control-V>
-	<<TkCon_Tab>>		<Control-i>
-	<<TkCon_Tab>>		<$PRIV(meta)-i>
-	<<TkCon_Newline>>	<Control-o>
-	<<TkCon_Newline>>	<$PRIV(meta)-o>
-	<<TkCon_Newline>>	<Control-Key-Return>
-	<<TkCon_Newline>>	<Control-Key-KP_Enter>
-	<<TkCon_Eval>>		<Return>
-	<<TkCon_Eval>>		<KP_Enter>
-	<<TkCon_Clear>>		<Control-l>
-	<<TkCon_Previous>>	<Up>
-	<<TkCon_PreviousImmediate>>	<Control-p>
-	<<TkCon_PreviousSearch>>	<Control-r>
-	<<TkCon_Next>>		<Down>
-	<<TkCon_NextImmediate>>	<Control-n>
-	<<TkCon_NextSearch>>	<Control-s>
-	<<TkCon_Transpose>>	<Control-t>
-	<<TkCon_ClearLine>>	<Control-u>
-	<<TkCon_SaveCommand>>	<Control-z>
-	<<TkCon_Popup>>		<Button-3>
-    }] {
-	event add $ev $key
-	## Make sure the specific key won't be defined
-	bind TkConsole $key {}
-    }
-
-    ## Make the ROOT bindings
-    bind $PRIV(root) <<TkCon_Exit>>	exit
-    bind $PRIV(root) <<TkCon_New>>	{ ::tkcon::New }
-    bind $PRIV(root) <<TkCon_NewTab>>	{ ::tkcon::NewTab }
-    bind $PRIV(root) <<TkCon_NextTab>>	{ ::tkcon::GotoTab 1 ; break }
-    bind $PRIV(root) <<TkCon_PrevTab>>	{ ::tkcon::GotoTab -1 ; break }
-    bind $PRIV(root) <<TkCon_Close>>	{ ::tkcon::Destroy }
-    bind $PRIV(root) <<TkCon_About>>	{ ::tkcon::About }
-    bind $PRIV(root) <<TkCon_Help>>	{ ::tkcon::Help }
-    bind $PRIV(root) <<TkCon_Find>>	{ ::tkcon::FindBox $::tkcon::PRIV(console) }
-    bind $PRIV(root) <<TkCon_Slave>>	{
-	::tkcon::Attach {}
-	::tkcon::RePrompt "\n" [::tkcon::CmdGet $::tkcon::PRIV(console)]
-    }
-    bind $PRIV(root) <<TkCon_Master>>	{
-	if {[string compare {} $::tkcon::PRIV(name)]} {
-	    ::tkcon::Attach $::tkcon::PRIV(name)
-	} else {
-	    ::tkcon::Attach Main
-	}
-	::tkcon::RePrompt "\n" [::tkcon::CmdGet $::tkcon::PRIV(console)]
-    }
-    bind $PRIV(root) <<TkCon_Main>>	{
-	::tkcon::Attach Main
-	::tkcon::RePrompt "\n" [::tkcon::CmdGet $::tkcon::PRIV(console)]
-    }
-    bind $PRIV(root) <<TkCon_Popup>> {
-	::tkcon::PopupMenu %X %Y
-    }
-
-    ## Menu items need null TkConsolePost bindings to avoid the TagProc
-    ##
-    foreach ev [bind $PRIV(root)] {
-	bind TkConsolePost $ev {
-	    # empty
-	}
-    }
-
-
-    # ::tkcon::ClipboardKeysyms --
-    # This procedure is invoked to identify the keys that correspond to
-    # the copy, cut, and paste functions for the clipboard.
-    #
-    # Arguments:
-    # copy -	Name of the key (keysym name plus modifiers, if any,
-    #		such as "Meta-y") used for the copy operation.
-    # cut -		Name of the key used for the cut operation.
-    # paste -	Name of the key used for the paste operation.
-
-    proc ::tkcon::ClipboardKeysyms {copy cut paste} {
-	bind TkConsole <$copy>	{::tkcon::Copy %W}
-	bind TkConsole <$cut>	{::tkcon::Cut %W}
-	bind TkConsole <$paste>	{::tkcon::Paste %W}
-    }
-
-    proc ::tkcon::GetSelection {w} {
-	if {
-	    ![catch {selection get -displayof $w -type UTF8_STRING} txt] ||
-	    ![catch {selection get -displayof $w} txt] ||
-	    ![catch {selection get -displayof $w -selection CLIPBOARD} txt]
-	} {
-	    return $txt
-	}
-	return -code error "could not find default selection"
-    }
-
-    proc ::tkcon::Cut w {
-	if {[string match $w [selection own -displayof $w]]} {
-	    clipboard clear -displayof $w
-	    catch {
-		set txt [selection get -displayof $w]
-		clipboard append -displayof $w $txt
-		if {[$w compare sel.first >= limit]} {
-		    $w delete sel.first sel.last
-		}
-	    }
-	}
-    }
-    proc ::tkcon::Copy w {
-	if {[string match $w [selection own -displayof $w]]} {
-	    clipboard clear -displayof $w
-	    catch {
-		set txt [selection get -displayof $w]
-		clipboard append -displayof $w $txt
-	    }
-	}
-    }
-    proc ::tkcon::Paste w {
-	if {![catch {GetSelection $w} txt]} {
-	    catch {
-		if {[$w compare sel.first >= limit]} {
-		    $w delete sel.first sel.last
-		}
-	    }
-	    if {[$w compare insert < limit]} { $w mark set insert end }
-	    $w insert insert $txt
-	    $w see insert
-	    if {[string match *\n* $txt]} { ::tkcon::Eval $w }
-	}
-    }
-
-    ## Redefine for TkConsole what we need
-    ##
-    event delete <<Paste>> <Control-V>
-    ::tkcon::ClipboardKeysyms <Copy> <Cut> <Paste>
-
-    bind TkConsole <Insert> {
-	catch { ::tkcon::Insert %W [::tkcon::GetSelection %W] }
-    }
-
-    bind TkConsole <Triple-1> {+
-	catch {
-	    eval %W tag remove sel [%W tag nextrange prompt sel.first sel.last]
-	    eval %W tag remove sel sel.last-1c
-	    %W mark set insert sel.first
-	}
-    }
-
-    ## binding editor needed
-    ## binding <events> for .tkconrc
-
-    bind TkConsole <<TkCon_ExpandFile>> {
-	if {[%W compare insert > limit]} {::tkcon::Expand %W path}
-	break ; # could check "%K" == "Tab"
-    }
-    bind TkConsole <<TkCon_ExpandProc>> {
-	if {[%W compare insert > limit]} {::tkcon::Expand %W proc}
-	break ; # could check "%K" == "Tab"
-    }
-    bind TkConsole <<TkCon_ExpandVar>> {
-	if {[%W compare insert > limit]} {::tkcon::Expand %W var}
-	break ; # could check "%K" == "Tab"
-    }
-    bind TkConsole <<TkCon_Expand>> {
-	if {[%W compare insert > limit]} {::tkcon::Expand %W}
-	break ; # could check "%K" == "Tab"
-    }
-    bind TkConsole <<TkCon_Tab>> {
-	if {[%W compare insert >= limit]} {
-	    ::tkcon::Insert %W \t
-	}
-    }
-    bind TkConsole <<TkCon_Newline>> {
-	if {[%W compare insert >= limit]} {
-	    ::tkcon::Insert %W \n
-	}
-    }
-    bind TkConsole <<TkCon_Eval>> {
-	::tkcon::Eval %W
-    }
-    bind TkConsole <Delete> {
-	if {[llength [%W tag nextrange sel 1.0 end]] \
-		&& [%W compare sel.first >= limit]} {
-	    %W delete sel.first sel.last
-	} elseif {[%W compare insert >= limit]} {
-	    %W delete insert
-	    %W see insert
-	}
-    }
-    bind TkConsole <BackSpace> {
-	if {[llength [%W tag nextrange sel 1.0 end]] \
-		&& [%W compare sel.first >= limit]} {
-	    %W delete sel.first sel.last
-	} elseif {[%W compare insert != 1.0] && [%W compare insert > limit]} {
-	    %W delete insert-1c
-	    %W see insert
-	}
-    }
-    bind TkConsole <Control-h> [bind TkConsole <BackSpace>]
-
-    bind TkConsole <KeyPress> {
-	::tkcon::Insert %W %A
-    }
-
-    bind TkConsole <Control-a> {
-	if {[%W compare {limit linestart} == {insert linestart}]} {
-	    tkTextSetCursor %W limit
-	} else {
-	    tkTextSetCursor %W {insert linestart}
-	}
-    }
-    bind TkConsole <Key-Home> [bind TkConsole <Control-a>]
-    bind TkConsole <Control-d> {
-	if {[%W compare insert < limit]} break
-	%W delete insert
-    }
-    bind TkConsole <Control-k> {
-	if {[%W compare insert < limit]} break
-	if {[%W compare insert == {insert lineend}]} {
-	    %W delete insert
-	} else {
-	    %W delete insert {insert lineend}
-	}
-    }
-    bind TkConsole <<TkCon_Clear>> {
-	## Clear console buffer, without losing current command line input
-	set ::tkcon::PRIV(tmp) [::tkcon::CmdGet %W]
-	clear
-	::tkcon::Prompt {} $::tkcon::PRIV(tmp)
-    }
-    bind TkConsole <<TkCon_Previous>> {
-	if {[%W compare {insert linestart} != {limit linestart}]} {
-	    tkTextSetCursor %W [tkTextUpDownLine %W -1]
-	} else {
-	    ::tkcon::Event -1
-	}
-    }
-    bind TkConsole <<TkCon_Next>> {
-	if {[%W compare {insert linestart} != {end-1c linestart}]} {
-	    tkTextSetCursor %W [tkTextUpDownLine %W 1]
-	} else {
-	    ::tkcon::Event 1
-	}
-    }
-    bind TkConsole <<TkCon_NextImmediate>>  { ::tkcon::Event 1 }
-    bind TkConsole <<TkCon_PreviousImmediate>> { ::tkcon::Event -1 }
-    bind TkConsole <<TkCon_PreviousSearch>> {
-	::tkcon::Event -1 [::tkcon::CmdGet %W]
-    }
-    bind TkConsole <<TkCon_NextSearch>>	    {
-	::tkcon::Event 1 [::tkcon::CmdGet %W]
-    }
-    bind TkConsole <<TkCon_Transpose>>	{
-	## Transpose current and previous chars
-	if {[%W compare insert > "limit+1c"]} { tkTextTranspose %W }
-    }
-    bind TkConsole <<TkCon_ClearLine>> {
-	## Clear command line (Unix shell staple)
-	%W delete limit end
-    }
-    bind TkConsole <<TkCon_SaveCommand>> {
-	## Save command buffer (swaps with current command)
-	set ::tkcon::PRIV(tmp) $::tkcon::PRIV(cmdsave)
-	set ::tkcon::PRIV(cmdsave) [::tkcon::CmdGet %W]
-	if {[string match {} $::tkcon::PRIV(cmdsave)]} {
-	    set ::tkcon::PRIV(cmdsave) $::tkcon::PRIV(tmp)
-	} else {
-	    %W delete limit end-1c
-	}
-	::tkcon::Insert %W $::tkcon::PRIV(tmp)
-	%W see end
-    }
-    catch {bind TkConsole <Key-Page_Up>   { tkTextScrollPages %W -1 }}
-    catch {bind TkConsole <Key-Prior>     { tkTextScrollPages %W -1 }}
-    catch {bind TkConsole <Key-Page_Down> { tkTextScrollPages %W 1 }}
-    catch {bind TkConsole <Key-Next>      { tkTextScrollPages %W 1 }}
-    bind TkConsole <$PRIV(meta)-d> {
-	if {[%W compare insert >= limit]} {
-	    %W delete insert {insert wordend}
-	}
-    }
-    bind TkConsole <$PRIV(meta)-BackSpace> {
-	if {[%W compare {insert -1c wordstart} >= limit]} {
-	    %W delete {insert -1c wordstart} insert
-	}
-    }
-    bind TkConsole <$PRIV(meta)-Delete> {
-	if {[%W compare insert >= limit]} {
-	    %W delete insert {insert wordend}
-	}
-    }
-    bind TkConsole <ButtonRelease-2> {
-	if {
-	    (!$tkPriv(mouseMoved) || $tk_strictMotif) &&
-	    ![catch {::tkcon::GetSelection %W} ::tkcon::PRIV(tmp)]
-	} {
-	    if {[%W compare @%x,%y < limit]} {
-		%W insert end $::tkcon::PRIV(tmp)
-	    } else {
-		%W insert @%x,%y $::tkcon::PRIV(tmp)
-	    }
-	    if {[string match *\n* $::tkcon::PRIV(tmp)]} {::tkcon::Eval %W}
-	}
-    }
-
-    ##
-    ## End TkConsole bindings
-    ##
-
-    ##
-    ## Bindings for doing special things based on certain keys
-    ##
-    bind TkConsolePost <Key-parenright> {
-	if {$::tkcon::OPT(lightbrace) && $::tkcon::OPT(blinktime)>99 && \
-		[string compare \\ [%W get insert-2c]]} {
-	    ::tkcon::MatchPair %W \( \) limit
-	}
-	set ::tkcon::PRIV(StatusCursor) [%W index insert]
-    }
-    bind TkConsolePost <Key-bracketright> {
-	if {$::tkcon::OPT(lightbrace) && $::tkcon::OPT(blinktime)>99 && \
-		[string compare \\ [%W get insert-2c]]} {
-	    ::tkcon::MatchPair %W \[ \] limit
-	}
-	set ::tkcon::PRIV(StatusCursor) [%W index insert]
-    }
-    bind TkConsolePost <Key-braceright> {
-	if {$::tkcon::OPT(lightbrace) && $::tkcon::OPT(blinktime)>99 && \
-		[string compare \\ [%W get insert-2c]]} {
-	    ::tkcon::MatchPair %W \{ \} limit
-	}
-	set ::tkcon::PRIV(StatusCursor) [%W index insert]
-    }
-    bind TkConsolePost <Key-quotedbl> {
-	if {$::tkcon::OPT(lightbrace) && $::tkcon::OPT(blinktime)>99 && \
-		[string compare \\ [%W get insert-2c]]} {
-	    ::tkcon::MatchQuote %W limit
-	}
-	set ::tkcon::PRIV(StatusCursor) [%W index insert]
-    }
-
-    bind TkConsolePost <KeyPress> {
-	if {[winfo exists "%W"]} {
-	    if {$::tkcon::OPT(lightcmd) && [string compare {} %A]} {
-		::tkcon::TagProc %W
-	    }
-	    set ::tkcon::PRIV(StatusCursor) [%W index insert]
-	}
-    }
-
-    bind TkConsolePost <Button-1> {
-	set ::tkcon::PRIV(StatusCursor) [%W index insert]
-    }
-    bind TkConsolePost <B1-Motion> {
-	set ::tkcon::PRIV(StatusCursor) [%W index insert]
-    }
-
-}
-
-##
-# ::tkcon::PopupMenu - what to do when the popup menu is requested
-##
-proc ::tkcon::PopupMenu {X Y} {
-    variable PRIV
-    variable OPT
-
-    set w $PRIV(console)
-    if {[string compare $w [winfo containing $X $Y]]} {
-	tk_popup $PRIV(popup) $X $Y
-	return
-    }
-    set x [expr {$X-[winfo rootx $w]}]
-    set y [expr {$Y-[winfo rooty $w]}]
-    if {[llength [set tags [$w tag names @$x,$y]]]} {
-	if {[lsearch -exact $tags "proc"] >= 0} {
-	    lappend type "proc"
-	    foreach {first last} [$w tag prevrange proc @$x,$y] {
-		set word [$w get $first $last]; break
-	    }
-	}
-	if {[lsearch -exact $tags "var"] >= 0} {
-	    lappend type "var"
-	    foreach {first last} [$w tag prevrange var @$x,$y] {
-		set word [$w get $first $last]; break
-	    }
-	}
-    }
-    if {![info exists type]} {
-	set exp "(^|\[^\\\\\]\[ \t\n\r\])"
-	set exp2 "\[\[\\\\\\?\\*\]"
-	set i [$w search -backwards -regexp $exp @$x,$y "@$x,$y linestart"]
-	if {[string compare {} $i]} {
-	    if {![string match *.0 $i]} {append i +2c}
-	    if {[string compare {} \
-		    [set j [$w search -regexp $exp $i "$i lineend"]]]} {
-		append j +1c
-	    } else {
-		set j "$i lineend"
-	    }
-	    regsub -all $exp2 [$w get $i $j] {\\\0} word
-	    set word [string trim $word {\"$[]{}',?#*}]
-	    if {[llength [EvalAttached [list info commands $word]]]} {
-		lappend type "proc"
-	    }
-	    if {[llength [EvalAttached [list info vars $word]]]} {
-		lappend type "var"
-	    }
-	    if {[EvalAttached [list file isfile $word]]} {
-		lappend type "file"
-	    }
-	}
-    }
-    if {![info exists type] || ![info exists word]} {
-	tk_popup $PRIV(popup) $X $Y
-	return
-    }
-    $PRIV(context) delete 0 end
-    $PRIV(context) add command -label "$word" -state disabled
-    $PRIV(context) add separator
-    set app [Attach]
-    if {[lsearch $type proc] != -1} {
-	$PRIV(context) add command -label "View Procedure" \
-		-command [list $OPT(edit) -attach $app -type proc -- $word]
-    }
-    if {[lsearch $type var] != -1} {
-	$PRIV(context) add command -label "View Variable" \
-		-command [list $OPT(edit) -attach $app -type var -- $word]
-    }
-    if {[lsearch $type file] != -1} {
-	$PRIV(context) add command -label "View File" \
-		-command [list $OPT(edit) -attach $app -type file -- $word]
-    }
-    tk_popup $PRIV(context) $X $Y
-}
-
-## ::tkcon::TagProc - tags a procedure in the console if it's recognized
-## This procedure is not perfect.  However, making it perfect wastes
-## too much CPU time...
-##
-proc ::tkcon::TagProc w {
-    set exp "\[^\\\\\]\[\[ \t\n\r\;{}\"\$\]"
-    set i [$w search -backwards -regexp $exp insert-1c limit-1c]
-    if {[string compare {} $i]} {append i +2c} else {set i limit}
-    regsub -all "\[\[\\\\\\?\\*\]" [$w get $i "insert-1c wordend"] {\\\0} c
-    if {[llength [EvalAttached [list info commands $c]]]} {
-	$w tag add proc $i "insert-1c wordend"
-    } else {
-	$w tag remove proc $i "insert-1c wordend"
-    }
-    if {[llength [EvalAttached [list info vars $c]]]} {
-	$w tag add var $i "insert-1c wordend"
-    } else {
-	$w tag remove var $i "insert-1c wordend"
-    }
-}
-
-## ::tkcon::MatchPair - blinks a matching pair of characters
-## c2 is assumed to be at the text index 'insert'.
-## This proc is really loopy and took me an hour to figure out given
-## all possible combinations with escaping except for escaped \'s.
-## It doesn't take into account possible commenting... Oh well.  If
-## anyone has something better, I'd like to see/use it.  This is really
-## only efficient for small contexts.
-# ARGS:	w	- console text widget
-# 	c1	- first char of pair
-# 	c2	- second char of pair
-# Calls:	::tkcon::Blink
-## 
-proc ::tkcon::MatchPair {w c1 c2 {lim 1.0}} {
-    if {[string compare {} [set ix [$w search -back $c1 insert $lim]]]} {
-	while {
-	    [string match {\\} [$w get $ix-1c]] &&
-	    [string compare {} [set ix [$w search -back $c1 $ix-1c $lim]]]
-	} {}
-	set i1 insert-1c
-	while {[string compare {} $ix]} {
-	    set i0 $ix
-	    set j 0
-	    while {[string compare {} [set i0 [$w search $c2 $i0 $i1]]]} {
-		append i0 +1c
-		if {[string match {\\} [$w get $i0-2c]]} continue
-		incr j
-	    }
-	    if {!$j} break
-	    set i1 $ix
-	    while {$j && [string compare {} \
-		    [set ix [$w search -back $c1 $ix $lim]]]} {
-		if {[string match {\\} [$w get $ix-1c]]} continue
-		incr j -1
-	    }
-	}
-	if {[string match {} $ix]} { set ix [$w index $lim] }
-    } else { set ix [$w index $lim] }
-    if {$::tkcon::OPT(blinkrange)} {
-	Blink $w $ix [$w index insert]
-    } else {
-	Blink $w $ix $ix+1c [$w index insert-1c] [$w index insert]
-    }
-}
-
-## ::tkcon::MatchQuote - blinks between matching quotes.
-## Blinks just the quote if it's unmatched, otherwise blinks quoted string
-## The quote to match is assumed to be at the text index 'insert'.
-# ARGS:	w	- console text widget
-# Calls:	::tkcon::Blink
-## 
-proc ::tkcon::MatchQuote {w {lim 1.0}} {
-    set i insert-1c
-    set j 0
-    while {[string compare [set i [$w search -back \" $i $lim]] {}]} {
-	if {[string match {\\} [$w get $i-1c]]} continue
-	if {!$j} {set i0 $i}
-	incr j
-    }
-    if {$j&1} {
-	if {$::tkcon::OPT(blinkrange)} {
-	    Blink $w $i0 [$w index insert]
-	} else {
-	    Blink $w $i0 $i0+1c [$w index insert-1c] [$w index insert]
-	}
-    } else {
-	Blink $w [$w index insert-1c] [$w index insert]
-    }
-}
-
-## ::tkcon::Blink - blinks between n index pairs for a specified duration.
-# ARGS:	w	- console text widget
-# 	i1	- start index to blink region
-# 	i2	- end index of blink region
-# 	dur	- duration in usecs to blink for
-# Outputs:	blinks selected characters in $w
-## 
-proc ::tkcon::Blink {w args} {
-    eval [list $w tag add blink] $args
-    after $::tkcon::OPT(blinktime) [list $w] tag remove blink $args
-    return
-}
-
-
-## ::tkcon::Insert
-## Insert a string into a text console at the point of the insertion cursor.
-## If there is a selection in the text, and it covers the point of the
-## insertion cursor, then delete the selection before inserting.
-# ARGS:	w	- text window in which to insert the string
-# 	s	- string to insert (usually just a single char)
-# Outputs:	$s to text widget
-## 
-proc ::tkcon::Insert {w s} {
-    if {[string match {} $s] || [string match disabled [$w cget -state]]} {
-	return
-    }
-    variable EXP
-    if {[info exists EXP(spawn_id)]} {
-	exp_send -i $EXP(spawn_id) -- $s
-	return
-    }
-    if {[$w comp insert < limit]} {
-	$w mark set insert end
-    }
-    if {[llength [$w tag ranges sel]] && \
-	    [$w comp sel.first <= insert] && [$w comp sel.last >= insert]} {
-	$w delete sel.first sel.last
-    }
-    $w insert insert $s
-    $w see insert
-}
-
-## ::tkcon::Expand - 
-# ARGS:	w	- text widget in which to expand str
-# 	type	- type of expansion (path / proc / variable)
-# Calls:	::tkcon::Expand(Pathname|Procname|Variable)
-# Outputs:	The string to match is expanded to the longest possible match.
-#		If ::tkcon::OPT(showmultiple) is non-zero and the user longest
-#		match equaled the string to expand, then all possible matches
-#		are output to stdout.  Triggers bell if no matches are found.
-# Returns:	number of matches found
-## 
-proc ::tkcon::Expand {w {type ""}} {
-    set exp "\[^\\\\\]\[\[ \t\n\r\\\{\"$\]"
-    set tmp [$w search -backwards -regexp $exp insert-1c limit-1c]
-    if {[string compare {} $tmp]} {append tmp +2c} else {set tmp limit}
-    if {[$w compare $tmp >= insert]} return
-    set str [$w get $tmp insert]
-    switch -glob $type {
-	pa* { set res [ExpandPathname $str] }
-	pr* { set res [ExpandProcname $str] }
-	v*  { set res [ExpandVariable $str] }
-	default {
-	    set res {}
-	    foreach t $::tkcon::OPT(expandorder) {
-		if {![catch {Expand$t $str} res] && \
-			[string compare {} $res]} break
-	    }
-	}
-    }
-    set len [llength $res]
-    if {$len} {
-	$w delete $tmp insert
-	$w insert $tmp [lindex $res 0]
-	if {$len > 1} {
-	    if {$::tkcon::OPT(showmultiple) && \
-		    ![string compare [lindex $res 0] $str]} {
-		puts stdout [lsort [lreplace $res 0 0]]
-	    }
-	}
-    } else { bell }
-    return [incr len -1]
-}
-
-## ::tkcon::ExpandPathname - expand a file pathname based on $str
-## This is based on UNIX file name conventions
-# ARGS:	str	- partial file pathname to expand
-# Calls:	::tkcon::ExpandBestMatch
-# Returns:	list containing longest unique match followed by all the
-#		possible further matches
-## 
-proc ::tkcon::ExpandPathname str {
-    set pwd [EvalAttached pwd]
-    # Cause a string like {C:/Program\ Files/} to become "C:/Program Files/"
-    regsub -all {\\([][ ])} $str {\1} str
-    if {[catch {EvalAttached [list cd [file dirname $str]]} err]} {
-	return -code error $err
-    }
-    set dir [file tail $str]
-    ## Check to see if it was known to be a directory and keep the trailing
-    ## slash if so (file tail cuts it off)
-    if {[string match */ $str]} { append dir / }
-    # Create a safely glob-able name
-    regsub -all {([][])} $dir {\\\1} safedir
-    if {[catch {lsort [EvalAttached [list glob $safedir*]]} m]} {
-	set match {}
-    } else {
-	if {[llength $m] > 1} {
-	    global tcl_platform
-	    if {[string match windows $tcl_platform(platform)]} {
-		## Windows is screwy because it's case insensitive
-		set tmp [ExpandBestMatch [string tolower $m] \
-			[string tolower $dir]]
-		## Don't change case if we haven't changed the word
-		if {[string length $dir]==[string length $tmp]} {
-		    set tmp $dir
-		}
-	    } else {
-		set tmp [ExpandBestMatch $m $dir]
-	    }
-	    if {[string match */* $str]} {
-		set tmp [string trimright [file dirname $str] /]/$tmp
-	    }
-	    regsub -all {([^\\])([][ ])} $tmp {\1\\\2} tmp
-	    set match [linsert $m 0 $tmp]
-	} else {
-	    ## This may look goofy, but it handles spaces in path names
-	    eval append match $m
-	    if {[file isdirectory $match]} {append match /}
-	    if {[string match */* $str]} {
-		set match [string trimright [file dirname $str] /]/$match
-	    }
-	    regsub -all {([^\\])([][ ])} $match {\1\\\2} match
-	    ## Why is this one needed and the ones below aren't!!
-	    set match [list $match]
-	}
-    }
-    EvalAttached [list cd $pwd]
-    return $match
-}
-
-## ::tkcon::ExpandProcname - expand a tcl proc name based on $str
-# ARGS:	str	- partial proc name to expand
-# Calls:	::tkcon::ExpandBestMatch
-# Returns:	list containing longest unique match followed by all the
-#		possible further matches
-##
-proc ::tkcon::ExpandProcname str {
-    set match [EvalAttached [list info commands $str*]]
-    if {[llength $match] == 0} {
-	set ns [EvalAttached \
-		"namespace children \[namespace current\] [list $str*]"]
-	if {[llength $ns]==1} {
-	    set match [EvalAttached [list info commands ${ns}::*]]
-	} else {
-	    set match $ns
-	}
-    }
-    if {[llength $match] > 1} {
-	regsub -all {([^\\]) } [ExpandBestMatch $match $str] {\1\\ } str
-	set match [linsert $match 0 $str]
-    } else {
-	regsub -all {([^\\]) } $match {\1\\ } match
-    }
-    return $match
-}
-
-## ::tkcon::ExpandXotcl - expand an xotcl method name based on $str
-# ARGS:	str	- partial proc name to expand
-# Calls:	::tkcon::ExpandBestMatch
-# Returns:	list containing longest unique match followed by all the
-#		possible further matches
-##
-proc ::tkcon::ExpandXotcl str {
-    # in a first step, get the cmd to check, if we should handle subcommands
-    set cmd [::tkcon::CmdGet $::tkcon::PRIV(console)]
-    # Only do the xotcl magic if there are two cmds and xotcl is loaded
-    if {[llength $cmd] != 2
-	|| ![EvalAttached [list info exists ::xotcl::version]]} {
-	return
-    }
-    set obj [lindex $cmd 0]
-    set sub [lindex $cmd 1]
-    set match [EvalAttached [list $obj info methods $sub*]]
-    if {[llength $match] > 1} {
-	regsub -all {([^\\]) } [ExpandBestMatch $match $str] {\1\\ } str
-	set match [linsert $match 0 $str]
-    } else {
-	regsub -all {([^\\]) } $match {\1\\ } match
-    }
-    return $match
-}
-
-## ::tkcon::ExpandVariable - expand a tcl variable name based on $str
-# ARGS:	str	- partial tcl var name to expand
-# Calls:	::tkcon::ExpandBestMatch
-# Returns:	list containing longest unique match followed by all the
-#		possible further matches
-## 
-proc ::tkcon::ExpandVariable str {
-    if {[regexp {([^\(]*)\((.*)} $str junk ary str]} {
-	## Looks like they're trying to expand an array.
-	set match [EvalAttached [list array names $ary $str*]]
-	if {[llength $match] > 1} {
-	    set vars $ary\([ExpandBestMatch $match $str]
-	    foreach var $match {lappend vars $ary\($var\)}
-	    return $vars
-	} elseif {[llength $match] == 1} {
-	    set match $ary\($match\)
-	}
-	## Space transformation avoided for array names.
-    } else {
-	set match [EvalAttached [list info vars $str*]]
-	if {[llength $match] > 1} {
-	    regsub -all {([^\\]) } [ExpandBestMatch $match $str] {\1\\ } str
-	    set match [linsert $match 0 $str]
-	} else {
-	    regsub -all {([^\\]) } $match {\1\\ } match
-	}
-    }
-    return $match
-}
-
-## ::tkcon::ExpandBestMatch2 - finds the best unique match in a list of names
-## Improves upon the speed of the below proc only when $l is small
-## or $e is {}.  $e is extra for compatibility with proc below.
-# ARGS:	l	- list to find best unique match in
-# Returns:	longest unique match in the list
-## 
-proc ::tkcon::ExpandBestMatch2 {l {e {}}} {
-    set s [lindex $l 0]
-    if {[llength $l]>1} {
-	set i [expr {[string length $s]-1}]
-	foreach l $l {
-	    while {$i>=0 && [string first $s $l]} {
-		set s [string range $s 0 [incr i -1]]
-	    }
-	}
-    }
-    return $s
-}
-
-## ::tkcon::ExpandBestMatch - finds the best unique match in a list of names
-## The extra $e in this argument allows us to limit the innermost loop a
-## little further.  This improves speed as $l becomes large or $e becomes long.
-# ARGS:	l	- list to find best unique match in
-# 	e	- currently best known unique match
-# Returns:	longest unique match in the list
-## 
-proc ::tkcon::ExpandBestMatch {l {e {}}} {
-    set ec [lindex $l 0]
-    if {[llength $l]>1} {
-	set e  [string length $e]; incr e -1
-	set ei [string length $ec]; incr ei -1
-	foreach l $l {
-	    while {$ei>=$e && [string first $ec $l]} {
-		set ec [string range $ec 0 [incr ei -1]]
-	    }
-	}
-    }
-    return $ec
-}
-
-# Here is a group of functions that is only used when Tkcon is
-# executed in a safe interpreter. It provides safe versions of
-# missing functions. For example:
-#
-# - "tk appname" returns "tkcon.tcl" but cannot be set
-# - "toplevel" is equivalent to 'frame', only it is automatically
-#   packed.
-# - The 'source', 'load', 'open', 'file' and 'exit' functions are
-#   mapped to corresponding functions in the parent interpreter.
-#
-# Further on, Tk cannot be really loaded. Still the safe 'load'
-# provedes a speciall case. The Tk can be divided into 4 groups,
-# that each has a safe handling procedure.
-#
-# - "::tkcon::SafeItem" handles commands like 'button', 'canvas' ......
-#   Each of these functions has the window name as first argument.
-# - "::tkcon::SafeManage" handles commands like 'pack', 'place', 'grid',
-#   'winfo', which can have multiple window names as arguments.
-# - "::tkcon::SafeWindow" handles all windows, such as '.'. For every
-#   window created, a new alias is formed which also is handled by
-#   this function.
-# - Other (e.g. bind, bindtag, image), which need their own function.
-#
-## These functions courtesy Jan Nijtmans
-##
-if {![llength [info commands tk]]} {
-    proc tk {option args} {
-	if {![string match app* $option]} {
-	    error "wrong option \"$option\": should be appname"
-	}
-	return "tkcon.tcl"
-    }
-}
-
-if {![llength [info command toplevel]]} {
-    proc toplevel {name args} {
-	eval [linsert $args 0 frame $name]
-	grid $name -sticky news
-    }
-}
-
-proc ::tkcon::SafeSource {i f} {
-    set fd [open $f r]
-    set r [read $fd]
-    close $fd
-    if {[catch {interp eval $i $r} msg]} {
-	error $msg
-    }
-}
-
-proc ::tkcon::SafeOpen {i f {m r}} {
-    set fd [open $f $m]
-    interp transfer {} $fd $i
-    return $fd
-}
-
-proc ::tkcon::SafeLoad {i f p} {
-    global tk_version tk_patchLevel tk_library auto_path
-    if {[string compare $p Tk]} {
-	load $f $p $i
-    } else {
-	foreach command {button canvas checkbutton entry frame label
-	listbox message radiobutton scale scrollbar spinbox text toplevel} {
-	    $i alias $command ::tkcon::SafeItem $i $command
-	}
-	$i alias image ::tkcon::SafeImage $i
-	foreach command {pack place grid destroy winfo} {
-	    $i alias $command ::tkcon::SafeManage $i $command
-	}
-	if {[llength [info command event]]} {
-	    $i alias event ::tkcon::SafeManage $i $command
-	}
-	frame .${i}_dot -width 300 -height 300 -relief raised
-	pack .${i}_dot -side left
-	$i alias tk tk
-	$i alias bind ::tkcon::SafeBind $i
-	$i alias bindtags ::tkcon::SafeBindtags $i
-	$i alias . ::tkcon::SafeWindow $i {}
-	foreach var {tk_version tk_patchLevel tk_library auto_path} {
-	    $i eval [list set $var [set $var]]
-	}
-	$i eval {
-	    package provide Tk $tk_version
-	    if {[lsearch -exact $auto_path $tk_library] < 0} {
-		lappend auto_path $tk_library
-	    }
-	}
-	return ""
-    }
-}
-
-proc ::tkcon::SafeSubst {i a} {
-    set arg1 ""
-    foreach {arg value} $a {
-	if {![string compare $arg -textvariable] ||
-	![string compare $arg -variable]} {
-	    set newvalue "[list $i] $value"
-	    global $newvalue
-	    if {[interp eval $i info exists $value]} {
-		set $newvalue [interp eval $i set $value]
-	    } else {
-		catch {unset $newvalue}
-	    }
-	    $i eval trace variable $value rwu \{[list tkcon set $newvalue $i]\}
-	    set value $newvalue
-	} elseif {![string compare $arg -command]} {
-	    set value [list $i eval $value]
-	}
-	lappend arg1 $arg $value
-    }
-    return $arg1
-}
-
-proc ::tkcon::SafeItem {i command w args} {
-    set args [::tkcon::SafeSubst $i $args]
-    set code [catch "$command [list .${i}_dot$w] $args" msg]
-    $i alias $w ::tkcon::SafeWindow $i $w
-    regsub -all .${i}_dot $msg {} msg
-    return -code $code $msg
-}
-
-proc ::tkcon::SafeManage {i command args} {
-    set args1 ""
-    foreach arg $args {
-	if {[string match . $arg]} {
-	    set arg .${i}_dot
-	} elseif {[string match .* $arg]} {
-	    set arg ".${i}_dot$arg"
-	}
-	lappend args1 $arg
-    }
-    set code [catch "$command $args1" msg]
-    regsub -all .${i}_dot $msg {} msg
-    return -code $code $msg
-}
-
-#
-# FIX: this function doesn't work yet if the binding starts with '+'.
-#
-proc ::tkcon::SafeBind {i w args} {
-    if {[string match . $w]} {
-	set w .${i}_dot
-    } elseif {[string match .* $w]} {
-	set w ".${i}_dot$w"
-    }
-    if {[llength $args] > 1} {
-	set args [list [lindex $args 0] \
-		"[list $i] eval [list [lindex $args 1]]"]
-    }
-    set code [catch "bind $w $args" msg]
-    if {[llength $args] <2 && $code == 0} {
-	set msg [lindex $msg 3]
-    }
-    return -code $code $msg
-}
-
-proc ::tkcon::SafeImage {i option args} {
-    set code [catch "image $option $args" msg]
-    if {[string match cr* $option]} {
-	$i alias $msg $msg
-    }
-    return -code $code $msg
-}
-
-proc ::tkcon::SafeBindtags {i w {tags {}}} {
-    if {[string match . $w]} {
-	set w .${i}_dot
-    } elseif {[string match .* $w]} {
-	set w ".${i}_dot$w"
-    }
-    set newtags {}
-    foreach tag $tags {
-	if {[string match . $tag]} {
-	    lappend newtags .${i}_dot
-	} elseif {[string match .* $tag]} {
-	    lappend newtags ".${i}_dot$tag"
-	} else {
-	    lappend newtags $tag
-	}
-    }
-    if {[string match $tags {}]} {
-	set code [catch {bindtags $w} msg]
-	regsub -all \\.${i}_dot $msg {} msg
-    } else {
-	set code [catch {bindtags $w $newtags} msg]
-    }
-    return -code $code $msg
-}
-
-proc ::tkcon::SafeWindow {i w option args} {
-    if {[string match conf* $option] && [llength $args] > 1} {
-	set args [::tkcon::SafeSubst $i $args]
-    } elseif {[string match itemco* $option] && [llength $args] > 2} {
-	set args "[list [lindex $args 0]] [::tkcon::SafeSubst $i [lrange $args 1 end]]"
-    } elseif {[string match cr* $option]} {
-	if {[llength $args]%2} {
-	    set args "[list [lindex $args 0]] [::tkcon::SafeSubst $i [lrange $args 1 end]]"
-	} else {
-	    set args [::tkcon::SafeSubst $i $args]
-	}
-    } elseif {[string match bi* $option] && [llength $args] > 2} {
-	set args [list [lindex $args 0] [lindex $args 1] "[list $i] eval [list [lindex $args 2]]"]
-    }
-    set code [catch ".${i}_dot$w $option $args" msg]
-    if {$code} {
-	regsub -all .${i}_dot $msg {} msg
-    } elseif {[string match conf* $option] || [string match itemco* $option]} {
-	if {[llength $args] == 1} {
-	    switch -- $args {
-		-textvariable - -variable {
-		    set msg "[lrange $msg 0 3] [list [lrange [lindex $msg 4] 1 end]]"
-		}
-		-command - updatecommand {
-		    set msg "[lrange $msg 0 3] [list [lindex [lindex $msg 4] 2]]"
-		}
-	    }
-	} elseif {[llength $args] == 0} {
-	    set args1 ""
-	    foreach el $msg {
-		switch -- [lindex $el 0] {
-		    -textvariable - -variable {
-			set el "[lrange $el 0 3] [list [lrange [lindex $el 4] 1 end]]"
-		    }
-		    -command - updatecommand {
-			set el "[lrange $el 0 3] [list [lindex [lindex $el 4] 2]]"
-		    }
-		}
-		lappend args1 $el
-	    }
-	    set msg $args1
-	}
-    } elseif {[string match cg* $option] || [string match itemcg* $option]} {
-	switch -- $args {
-	    -textvariable - -variable {
-		set msg [lrange $msg 1 end]
-	    }
-	    -command - updatecommand {
-		set msg [lindex $msg 2]
-	    }
-	}
-    } elseif {[string match bi* $option]} {
-	if {[llength $args] == 2 && $code == 0} {
-	    set msg [lindex $msg 2]
-	}
-    }
-    return -code $code $msg
-}
-
-proc ::tkcon::RetrieveFilter {host} {
-    variable PRIV
-    set result {}
-    if {[info exists PRIV(proxy)]} {
-	if {![regexp "^(localhost|127\.0\.0\.1)" $host]} {
-	    set result [lrange [split [lindex $PRIV(proxy) 0] :] 0 1]
-	}
-    }
-    return $result
-}
-
-proc ::tkcon::RetrieveAuthentication {} {
-    package require Tk
-    if {[catch {package require base64}]} {
-        if {[catch {package require Trf}]} {
-            error "base64 support not available"
-        } else {
-            set local64 "base64 -mode enc"
-        }
-    } else {
-        set local64 "base64::encode"
-    }
-
-    set dlg [toplevel .auth]
-    wm title $dlg "Authenticating Proxy Configuration"
-    set f1 [frame ${dlg}.f1]
-    set f2 [frame ${dlg}.f2]
-    button $f2.b -text "OK" -command "destroy $dlg"
-    pack $f2.b -side right
-    label $f1.l2 -text "Username"
-    label $f1.l3 -text "Password"
-    entry $f1.e2 -textvariable "[namespace current]::conf_userid"
-    entry $f1.e3 -textvariable "[namespace current]::conf_passwd" -show *
-    grid $f1.l2 -column 0 -row 0 -sticky e
-    grid $f1.l3 -column 0 -row 1 -sticky e
-    grid $f1.e2 -column 1 -row 0 -sticky news
-    grid $f1.e3 -column 1 -row 1 -sticky news
-    grid columnconfigure $f1 1 -weight 1
-    pack $f2 -side bottom -fill x
-    pack $f1 -side top -anchor n -fill both -expand 1
-    tkwait window $dlg
-    set result {}
-    if {[info exists [namespace current]::conf_userid]} {
-	set data [subst $[namespace current]::conf_userid]
-	append data : [subst $[namespace current]::conf_passwd]
-	set data [$local64 $data]
-	set result [list "Proxy-Authorization" "Basic $data"]
-    }
-    unset [namespace current]::conf_passwd
-    return $result
-}
-
-proc ::tkcon::Retrieve {} {
-    # A little bit'o'magic to grab the latest tkcon from CVS and
-    # save it locally.  It doesn't support proxies though...
-    variable PRIV
-
-    set defExt ""
-    if {[string match "windows" $::tcl_platform(platform)]} {
-	set defExt ".tcl"
-    }
-    set file [tk_getSaveFile -title "Save Latest tkcon to ..." \
-	    -defaultextension $defExt \
-	    -initialdir  [file dirname $PRIV(SCRIPT)] \
-	    -initialfile [file tail $PRIV(SCRIPT)] \
-	    -parent $PRIV(root) \
-	    -filetypes {{"Tcl Files" {.tcl .tk}} {"All Files" {*.*}}}]
-    if {[string compare $file ""]} {
-	package require http 2
-	set headers {}
-	if {[info exists PRIV(proxy)]} {
-	    ::http::config -proxyfilter [namespace origin RetrieveFilter]
-	    if {[lindex $PRIV(proxy) 1] != {}} {
-		set headers [RetrieveAuthentication]
-	    }
-	}
-	set token [::http::geturl $PRIV(HEADURL) \
-		-headers $headers -timeout 30000]
-	::http::wait $token
-	set code [catch {
-	    set ncode [::http::ncode $token]
-	    if {$ncode != 200} {
-		return "expected http return code 200, received $ncode"
-	    }
-	    set status [::http::status $token]
-	    if {$status == "ok"} {
-		set data [::http::data $token]
-		regexp {Id: tkcon.tcl,v (\d+\.\d+)} $data -> rcsVersion
-		regexp {VERSION\s+"(\d+\.\d+[^\"]*)"} $data -> tkconVersion
-		if {(![info exists rcsVersion] || ![info exists tkconVersion])
-		    && [tk_messageBox -type yesno -icon warning \
-			    -parent $PRIV(root) \
-			    -title "Invalid tkcon source code" \
-			    -message "Source code retrieved does not appear\
-			to be correct.\nContinue with save to \"$file\"?"] \
-			== "no"} {
-		    return "invalid tkcon source code retrieved"
-		}
-		set fid [open $file w]
-		# We don't want newline mode to change
-		fconfigure $fid -translation binary
-		puts -nonewline $fid $data
-		close $fid
-	    } else {
-		return "expected http status ok, received $status"
-	    }
-	} err]
-	::http::cleanup $token
-	if {$code == 2} {
-	    tk_messageBox -type ok -icon info -parent $PRIV(root) \
-		    -title "Failed to retrieve source" \
-		    -message "Failed to retrieve latest tkcon source:\n$err\n$PRIV(HEADURL)"
-	} elseif {$code} {
-	    return -code error $err
-	} else {
-	    if {![info exists rcsVersion]}   { set rcsVersion   "UNKNOWN" }
-	    if {![info exists tkconVersion]} { set tkconVersion "UNKNOWN" }
-	    if {[tk_messageBox -type yesno -icon info -parent $PRIV(root) \
-		    -title "Retrieved tkcon v$tkconVersion, RCS $rcsVersion" \
-		    -message "Successfully retrieved tkcon v$tkconVersion,\
-		    RCS $rcsVersion.  Shall I resource (not restart) this\
-		    version now?"] == "yes"} {
-		set PRIV(SCRIPT) $file
-		set PRIV(version) $tkconVersion.$rcsVersion
-		::tkcon::Resource
-	    }
-	}
-    }
-}
-
-## 'send' package that handles multiple communication variants
-##
-# Try using Tk send first, then look for a winsend interp,
-# then try dde and finally have a go at comm
-namespace eval ::send {}
-proc ::send::send {args} {
-    set winfoInterpCmd [list ::winfo interps]
-    array set opts [list displayof {} async 0]
-    while {[string match -* [lindex $args 0]]} {
-	switch -exact -- [lindex $args 0] {
-	    -displayof {
-		set opts(displayof) [Pop args 1]
-		lappend winfoInterpCmd -displayof $opts(displayof)
-	    }
-	    -async     { set opts(async) 1 }
-	    -- { Pop args ; break }
-	    default {
-		return -code error "bad option \"[lindex $args 0]\":\
-		    should be -displayof, -async or --"
-	    }
-	}
-	Pop args
-    }
-    set app [Pop args]
-
-    if {[llength [info commands ::winfo]]
-	&& [lsearch -exact [eval $winfoInterpCmd] $app] > -1} {
-	set cmd [list ::send]
-	if {$opts(async) == 1} {lappend cmd -async}
-	if {$opts(displayof) != {}} {lappend cmd -displayof $opts(displayof)}
-	lappend cmd $app
-	eval $cmd $args
-    } elseif {[llength [info commands ::winsend]]
-	      && [lsearch -exact [::winsend interps] $app] > -1} {
-	eval [list ::winsend send $app] $args
-    } elseif {[llength [info commands ::dde]]
-	      && [lsearch -exact [dde services TclEval {}] \
-		      [list TclEval $app]] > -1} {
-	eval [list ::dde eval $app] $args
-    } elseif {[package provide comm] != {}
-	      && [regexp {^[0-9]+$} [lindex $app 0]]} {
-	#if {$opts(displayof) != {} && [llength $app] == 1} {
-	#    lappend app $opts(displayof)
-	#}
-	eval [list ::comm::comm send $app] $args
-    } else {
-	return -code error "bad interp: \"$app\" could not be found"
-    }
-}
-
-proc ::send::interps {args} {
-    set winfoInterpCmd [list ::winfo interps]
-    array set opts [list displayof {}]
-    while {[string match -* [lindex $args 0]]} {
-	switch -exact -- [lindex $args 0] {
-	    -displayof {
-		set opts(displayof) [Pop args 1]
-		lappend winfoInterpCmd -displayof $opts(displayof)
-	    }
-	    --	       { Pop args ; break }
-	    default {
-		return -code error "bad option \"[lindex $args 0]\":\
-		    should be -displayof or --"
-	    }
-	}
-	Pop args
-    }
-
-    set interps {}
-    if {[llength [info commands ::winfo]]} {
-	set interps [concat $interps [eval $winfoInterpCmd]]
-    }
-    if {[llength [info commands ::winsend]]} {
-	set interps [concat $interps [::winsend interps]]
-    }
-    if {[llength [info commands ::dde]]} {
-	set servers {}
-	foreach server [::dde services TclEval {}] {
-	    lappend servers [lindex $server 1]
-	}
-	set interps [concat $interps $servers]
-    }
-    if {[package provide comm] != {}} {
-	set interps [concat $interps [::comm::comm interps]]
-    }
-    return $interps
-}
-
-proc ::send::appname {args} {
-    set appname {}
-    if {[llength [info commands ::tk]]} {
-	set appname [eval ::tk appname $args]
-    }
-    if {[llength [info commands ::winsend]]} {
-	set appname [concat $appname [eval ::winsend appname $args]]
-    }
-    if {[llength [info commands ::dde]]} {
-	set appname [concat $appname [eval ::dde servername $args]]
-    }
-    # comm? can set port num and local/global interface.
-    return [lsort -unique $appname]
-}
-
-proc ::send::Pop {varname {nth 0}} {
-    upvar $varname args
-    set r [lindex $args $nth]
-    set args [lreplace $args $nth $nth]
-    return $r
-}
-##
-## end 'send' pacakge
-
-## special case 'tk appname' in Tcl plugin
-if {$::tkcon::PRIV(WWW)} {
-    rename tk ::tkcon::_tk
-    proc tk {cmd args} {
-	if {$cmd == "appname"} {
-	    return "tkcon/WWW"
-	} else {
-	    return [uplevel 1 ::tkcon::_tk [list $cmd] $args]
-	}
-    }
-}
-
-## ::tkcon::Resource - re'source's this script into current console
-## Meant primarily for my development of this program.  It follows
-## links until the ultimate source is found.
-##
-proc ::tkcon::Resource {} {
-    uplevel \#0 {
-	if {[catch {source -rsrc tkcon}]} { source $::tkcon::PRIV(SCRIPT) }
-    }
-    Bindings
-    InitSlave $::tkcon::OPT(exec)
-}
-
-## Initialize only if we haven't yet, and do other stuff that prepares to
-## run.  It only actually inits (and runs) tkcon if it is the main script.
-##
-proc ::tkcon::AtSource {} {
-    variable PRIV
-
-    # the info script assumes we always call this while being sourced
-    set PRIV(SCRIPT) [info script]
-    if {!$PRIV(WWW) && [string length $PRIV(SCRIPT)]} {
-	if {[info tclversion] >= 8.4} {
-	    set PRIV(SCRIPT) [file normalize $PRIV(SCRIPT)]
-	} else {
-	    # we use a catch here because some wrap apps choke on 'file type'
-	    # because TclpLstat wasn't wrappable until 8.4.
-	    catch {
-		while {[string match link [file type $PRIV(SCRIPT)]]} {
-		    set link [file readlink $PRIV(SCRIPT)]
-		    if {[string match relative [file pathtype $link]]} {
-			set PRIV(SCRIPT) \
-			    [file join [file dirname $PRIV(SCRIPT)] $link]
-		    } else {
-			set PRIV(SCRIPT) $link
-		    }
-		}
-		catch {unset link}
-		if {[string match relative [file pathtype $PRIV(SCRIPT)]]} {
-		    set PRIV(SCRIPT) [file join [pwd] $PRIV(SCRIPT)]
-		}
-	    }
-	}
-    }
-    # normalize argv0 if it was tkcon to ensure that we'll be able
-    # to load slaves correctly.
-    if {[info exists ::argv0] && [info script] == $::argv0} {
-	set ::argv0 $PRIV(SCRIPT)
-    }
-
-    if {(![info exists PRIV(root)] || ![winfo exists $PRIV(root)]) \
-	    && ([info exists ::argv0] && $PRIV(SCRIPT) == $::argv0)} {
-	global argv
-	if {[info exists argv]} {
-	    eval ::tkcon::Init $argv
-	} else {
-	    ::tkcon::Init
-	}
-    }
-}
-tkcon::AtSource
-
-package provide tkcon $::tkcon::VERSION

-- 
image display tool for astronomy



More information about the debian-science-commits mailing list