[xml/sgml-commit] r565 - in packages/libxslt: . trunk trunk/debian trunk/doc trunk/libexslt trunk/libxslt trunk/python trunk/python/tests trunk/tests trunk/tests/REC trunk/tests/REC1 trunk/tests/REC2 trunk/tests/XSLTMark trunk/tests/docbook trunk/tests/docs trunk/tests/documents trunk/tests/exslt trunk/tests/exslt/common trunk/tests/exslt/date trunk/tests/exslt/dynamic trunk/tests/exslt/functions trunk/tests/exslt/math trunk/tests/exslt/sets trunk/tests/exslt/strings trunk/tests/extensions trunk/tests/general trunk/tests/keys trunk/tests/multiple trunk/tests/namespaces trunk/tests/numbers trunk/tests/plugins trunk/tests/reports trunk/tests/xinclude trunk/tests/xmlspec trunk/xsltproc

Mike Hommey glandium at costa.debian.org
Thu Jun 8 22:29:40 UTC 2006


Author: glandium
Date: 2006-06-08 22:29:07 +0000 (Thu, 08 Jun 2006)
New Revision: 565

Modified:
   packages/libxslt/
   packages/libxslt/trunk/
   packages/libxslt/trunk/ChangeLog
   packages/libxslt/trunk/Makefile.in
   packages/libxslt/trunk/configure
   packages/libxslt/trunk/configure.in
   packages/libxslt/trunk/debian/changelog
   packages/libxslt/trunk/debian/control
   packages/libxslt/trunk/doc/API.html
   packages/libxslt/trunk/doc/FAQ.html
   packages/libxslt/trunk/doc/Makefile.in
   packages/libxslt/trunk/doc/bugs.html
   packages/libxslt/trunk/doc/contribs.html
   packages/libxslt/trunk/doc/docbook.html
   packages/libxslt/trunk/doc/docs.html
   packages/libxslt/trunk/doc/downloads.html
   packages/libxslt/trunk/doc/extensions.html
   packages/libxslt/trunk/doc/help.html
   packages/libxslt/trunk/doc/index.html
   packages/libxslt/trunk/doc/internals.html
   packages/libxslt/trunk/doc/intro.html
   packages/libxslt/trunk/doc/libxslt.xsa
   packages/libxslt/trunk/doc/news.html
   packages/libxslt/trunk/doc/python.html
   packages/libxslt/trunk/doc/xslt.html
   packages/libxslt/trunk/doc/xsltproc2.html
   packages/libxslt/trunk/libexslt/Makefile.in
   packages/libxslt/trunk/libexslt/exsltconfig.h
   packages/libxslt/trunk/libexslt/functions.c
   packages/libxslt/trunk/libxslt.spec
   packages/libxslt/trunk/libxslt.spec.in
   packages/libxslt/trunk/libxslt/Makefile.in
   packages/libxslt/trunk/libxslt/attributes.c
   packages/libxslt/trunk/libxslt/documents.c
   packages/libxslt/trunk/libxslt/extensions.c
   packages/libxslt/trunk/libxslt/extensions.h
   packages/libxslt/trunk/libxslt/imports.c
   packages/libxslt/trunk/libxslt/keys.c
   packages/libxslt/trunk/libxslt/namespaces.c
   packages/libxslt/trunk/libxslt/pattern.c
   packages/libxslt/trunk/libxslt/preproc.c
   packages/libxslt/trunk/libxslt/templates.c
   packages/libxslt/trunk/libxslt/transform.c
   packages/libxslt/trunk/libxslt/variables.c
   packages/libxslt/trunk/libxslt/xslt.c
   packages/libxslt/trunk/libxslt/xsltInternals.h
   packages/libxslt/trunk/libxslt/xsltconfig.h
   packages/libxslt/trunk/libxslt/xsltutils.c
   packages/libxslt/trunk/libxslt/xsltutils.h
   packages/libxslt/trunk/libxslt/xsltwin32config.h
   packages/libxslt/trunk/python/Makefile.in
   packages/libxslt/trunk/python/tests/Makefile.in
   packages/libxslt/trunk/tests/Makefile.in
   packages/libxslt/trunk/tests/REC/Makefile.in
   packages/libxslt/trunk/tests/REC1/Makefile.in
   packages/libxslt/trunk/tests/REC2/Makefile.in
   packages/libxslt/trunk/tests/XSLTMark/Makefile.in
   packages/libxslt/trunk/tests/docbook/Makefile.in
   packages/libxslt/trunk/tests/docs/Makefile.in
   packages/libxslt/trunk/tests/documents/Makefile.in
   packages/libxslt/trunk/tests/exslt/Makefile.in
   packages/libxslt/trunk/tests/exslt/common/Makefile.in
   packages/libxslt/trunk/tests/exslt/date/Makefile.in
   packages/libxslt/trunk/tests/exslt/dynamic/Makefile.in
   packages/libxslt/trunk/tests/exslt/functions/Makefile.in
   packages/libxslt/trunk/tests/exslt/math/Makefile.in
   packages/libxslt/trunk/tests/exslt/sets/Makefile.in
   packages/libxslt/trunk/tests/exslt/strings/Makefile.in
   packages/libxslt/trunk/tests/extensions/Makefile.in
   packages/libxslt/trunk/tests/general/Makefile.in
   packages/libxslt/trunk/tests/keys/Makefile.in
   packages/libxslt/trunk/tests/multiple/Makefile.in
   packages/libxslt/trunk/tests/namespaces/Makefile.in
   packages/libxslt/trunk/tests/numbers/Makefile.in
   packages/libxslt/trunk/tests/plugins/Makefile.in
   packages/libxslt/trunk/tests/reports/Makefile.in
   packages/libxslt/trunk/tests/xinclude/Makefile.in
   packages/libxslt/trunk/tests/xmlspec/Makefile.in
   packages/libxslt/trunk/xsltproc/Makefile.in
Log:
 r1086 at namakemono:  mh | 2006-06-08 23:47:09 +0200
 * New upstream release.
 * debian/control: Build depend on libxml2 >= 2.6.25, and adapt other
   dependencies accordingly.



Property changes on: packages/libxslt
___________________________________________________________________
Name: svk:merge
   - 85a06573-1206-0410-a182-ce9117885d71:/local/libxslt:284
a066b643-3b0a-0410-a6ba-ed4cca522822:/local/libxslt:1079
   + 85a06573-1206-0410-a182-ce9117885d71:/local/libxslt:284
a066b643-3b0a-0410-a6ba-ed4cca522822:/local/libxslt:1086


Property changes on: packages/libxslt/trunk
___________________________________________________________________
Name: svk:merge
   - a066b643-3b0a-0410-a6ba-ed4cca522822:/local/libxslt/branches/upstream/current:1048
a066b643-3b0a-0410-a6ba-ed4cca522822:/local/libxslt/trunk:1057
   + a066b643-3b0a-0410-a6ba-ed4cca522822:/local/libxslt/branches/upstream/current:1078
a066b643-3b0a-0410-a6ba-ed4cca522822:/local/libxslt/trunk:1057

Modified: packages/libxslt/trunk/ChangeLog
===================================================================
--- packages/libxslt/trunk/ChangeLog	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/ChangeLog	2006-06-08 22:29:07 UTC (rev 565)
@@ -1,3 +1,112 @@
+Tue Jun  6 17:16:33 CEST 2006 Daniel Veillard <daniel at veillard.com>
+
+	* configure.in libxslt.spec.in doc//*: preparing release of 1.1.17
+
+Tue Jun  6 11:44:34 CEST 2006 Kasimier Buchcik <libxml2-cvs at cazic.net>
+
+	* libxslt/attributes.c: Eliminated a tiny difference wrt to
+	  the old behaviour in the naming of newly generated ns-decls
+	  in xsltAttributeInternal().
+
+Thu Jun  1 15:06:31 CEST 2006 Daniel Veillard <daniel at veillard.com>
+
+	* configure.in: fix a problem in Python detection
+
+Thu Jun  1 13:58:19 CEST 2006 Kasimier Buchcik <libxml2-cvs at cazic.net>
+
+	* libxslt/attributes.c libxslt/variables.c
+	  libxslt/transform.c libxslt/xslt.c:
+	  Next step in the refactored code: enhanced xsl:attribute;
+	  enhanced xsltCopyProp.
+	  Added the creation of an XPath cache in
+	  xsltNewTransformContext().
+
+Wed May 31 22:32:44 CEST 2006 Kasimier Buchcik <libxml2-cvs at cazic.net>
+
+	* libxslt/transform.c: Fixed a difference in processing of
+	  xsl:value-of and  xsl:text wrt to merging of strings of
+	  output-escaped text-nodes. This difference made the
+	  optimized string-merging mechanism run out of sync, which
+	  led to segfaults in subsequent string reallocations. See
+	  bug #343411, reported by Grzegorz Kaczor.
+	* xslt.c: Added check for ctxt->internalized when we parse
+	  xsl:text and internalize the strings.
+
+Mon May 22 10:32:57 CEST 2006 Kasimier Buchcik <libxml2-cvs at cazic.net>
+
+	* libxslt/attributes.c libxslt/documents.c
+	  libxslt/extensions.c libxslt/keys.c libxslt/pattern.c
+	  libxslt/preproc.c libxslt/templates.c
+	  libxslt/transform.c libxslt/variables.c
+	  libxslt/xslt.c libxslt/xsltInternals.h:
+	  Next tiny step of refactoring - mostly bug fixes and
+	  cosmetic changes.
+	  Changes outside of the refactored code:
+	  1) Optimized xsl:attribute if the content consists of
+	   just 1 text node.
+	  2) Optimized computation of xsl:key. The keys will now be
+	   computed for a specific document not until the first call
+	   of a key() function; here only the keys with the specific
+	   name used by key() are computed. This means that this
+	   now avoids computation of all keys for all loaded
+	   input documents (even if no key() was called on them).
+	   One exception is the scenario where a key() is used in
+	   a template's match pattern; in this case all keys are
+	   computed for a document if there's a chance that
+	   a "keyed" template could match a node (this could still
+	   be optimized a bit).
+
+Mon May 15 22:32:13 CEST 2006 Kasimier Buchcik <libxml2-cvs at cazic.net>
+
+	* libxslt/namespaces.c libxslt/attributes.c:
+	  Fixed bug #302020, reported by Thomas Blatter.
+
+Fri May 12 23:23:06 CEST 2006 Kasimier Buchcik <libxml2-cvs at cazic.net>
+
+	* libxslt/documents.c libxslt/namespaces.c
+	  libxslt/preproc.c libxslt/transform.c
+	  libxslt/xslt.c libxslt/xsltInternals.h libxslt/xsltutils.c:
+	  Next step of refactoring. For more details see bug #341588.
+	  I applied the suggestion of Jerome Pesenti to the refactored
+	  (still IDFEDed out with XSLT_REFACTORED) code: The XPath
+	  compilation context (accessible via the compilation context)
+	  is now reused for compilation of expressions at
+	  compilation-time; this should reduce compilation time to 50%
+	  for avarage stylesheets.
+
+Thu May 11 22:12:22 CEST 2006 Kasimier Buchcik <libxml2-cvs at cazic.net>
+
+	* libxslt/extensions.c: Changed a comment to indicate that a
+	  specific bug was already fixed.
+	  
+Fri May  5 23:10:47 CEST 2006 Kasimier Buchcik <libxml2-cvs at cazic.net>
+
+	* libxslt/xsltInternals.h libxslt/attributes.c
+	  libxslt/documents.c libxslt/extensions.c
+	  libxslt/extensions.h libxslt/functions.c
+	  libxslt/imports.c libxslt/keys.c libxslt/preproc.c
+	  libxslt/transform.c libxslt/variables.c libxslt/xslt.c
+	  libxslt/xsltutils.c libxslt/xsltutils.h libexslt/functions.c:
+	  Next step of refactoring (plus some bug-fixes).
+	  For more details see #340780.
+
+Fri May  5 14:31:53 CEST 2006 Kasimier Buchcik <libxml2-cvs at cazic.net>
+
+	* tests/exslt/common/node-set.5.out
+	  tests/exslt/sets/difference.1.out
+	  tests/exslt/functions/function.6.out: Reverting the
+	  changes; I'll rather change the processing stylesheet
+	  documents in a way that they will produce the same results
+	  for broken and stricter whitespace-stripping.
+
+Thu May  4 22:55:26 CEST 2006 Kasimier Buchcik <libxml2-cvs at cazic.net>
+
+	* tests/exslt/common/node-set.5.out
+	  tests/exslt/sets/difference.1.out
+	  tests/exslt/functions/function.6.out: Changed regression test
+	  results (bug #340684). Those will now produce regression
+	  errors; so we need to fix the processor.
+
 Mon May  1 17:39:27 EDT 2006 Daniel Veillard <daniel at veillard.com>
 
 	* configure.in NEWS doc//*: preparing release of 1.1.16, updated and

Modified: packages/libxslt/trunk/Makefile.in
===================================================================
--- packages/libxslt/trunk/Makefile.in	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/Makefile.in	2006-06-08 22:29:07 UTC (rev 565)
@@ -122,6 +122,7 @@
 EXTRA_LIBS = @EXTRA_LIBS@
 F77 = @F77@
 FFLAGS = @FFLAGS@
+GREP = @GREP@
 HTML_DIR = @HTML_DIR@
 INSTALL_DATA = @INSTALL_DATA@
 INSTALL_PROGRAM = @INSTALL_PROGRAM@
@@ -207,12 +208,9 @@
 XSLT_INCLUDEDIR = @XSLT_INCLUDEDIR@
 XSLT_LIBDIR = @XSLT_LIBDIR@
 XSLT_LIBS = @XSLT_LIBS@
-ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_CXX = @ac_ct_CXX@
 ac_ct_F77 = @ac_ct_F77@
-ac_ct_RANLIB = @ac_ct_RANLIB@
-ac_ct_STRIP = @ac_ct_STRIP@
 am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
 am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
 am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@
@@ -229,23 +227,30 @@
 build_os = @build_os@
 build_vendor = @build_vendor@
 datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
 exec_prefix = @exec_prefix@
 host = @host@
 host_alias = @host_alias@
 host_cpu = @host_cpu@
 host_os = @host_os@
 host_vendor = @host_vendor@
+htmldir = @htmldir@
 includedir = @includedir@
 infodir = @infodir@
 install_sh = @install_sh@
 libdir = @libdir@
 libexecdir = @libexecdir@
+localedir = @localedir@
 localstatedir = @localstatedir@
 mandir = @mandir@
 mkdir_p = @mkdir_p@
 oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
 prefix = @prefix@
 program_transform_name = @program_transform_name@
+psdir = @psdir@
 pythondir = @pythondir@
 sbindir = @sbindir@
 sharedstatedir = @sharedstatedir@

Modified: packages/libxslt/trunk/configure
===================================================================
--- packages/libxslt/trunk/configure	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/configure	2006-06-08 22:29:07 UTC (rev 565)
@@ -1,8 +1,9 @@
 #! /bin/sh
 # Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.59.
+# Generated by GNU Autoconf 2.59e.
 #
-# Copyright (C) 2003 Free Software Foundation, Inc.
+# 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.
 ## --------------------- ##
@@ -16,11 +17,35 @@
   # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
   # is contrary to our usage.  Disable this feature.
   alias -g '${1+"$@"}'='"$@"'
-elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
-  set -o posix
+  setopt NO_GLOB_SUBST
+else
+  case `(set -o) 2>/dev/null` in *posix*) set -o posix;; esac
 fi
+BIN_SH=xpg4; export BIN_SH # for Tru64
 DUALCASE=1; export DUALCASE # for MKS sh
 
+
+# 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
@@ -29,8 +54,43 @@
 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.
-$as_unset ENV MAIL MAILPATH
+for as_var in ENV MAIL MAILPATH
+do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
+done
 PS1='$ '
 PS2='> '
 PS4='+ '
@@ -44,18 +104,19 @@
   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
+    ($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; then
+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
+if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
   as_basename=basename
 else
   as_basename=false
@@ -63,157 +124,386 @@
 
 
 # Name of the executable.
-as_me=`$as_basename "$0" ||
+as_me=`$as_basename -- "$0" ||
 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
 	 X"$0" : 'X\(//\)$' \| \
-	 X"$0" : 'X\(/\)$' \| \
-	 .     : '\(.\)' 2>/dev/null ||
+	 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
 echo X/"$0" |
-    sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
-  	  /^X\/\(\/\/\)$/{ s//\1/; q; }
-  	  /^X\/\(\/\).*/{ s//\1/; q; }
-  	  s/.*/./; q'`
+    sed '/^.*\/\([^/][^/]*\)\/*$/{
+	    s//\1/
+	    q
+	  }
+	  /^X\/\(\/\/\)$/{
+	    s//\1/
+	    q
+	  }
+	  /^X\/\(\/\).*/{
+	    s//\1/
+	    q
+	  }
+	  s/.*/./; q'`
 
+# CDPATH.
+$as_unset CDPATH
 
-# PATH needs CR, and LINENO needs CR and PATH.
-# 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
+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
+}
 
-  as_lineno_1=$LINENO
-  as_lineno_2=$LINENO
-  as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
-  test "x$as_lineno_1" != "x$as_lineno_2" &&
-  test "x$as_lineno_3"  = "x$as_lineno_2"  || {
-  # Find who we are.  Look in the path if we contain no path at all
-  # relative or not.
-  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
+exitcode=0
+if as_func_success; then
+  :
+else
+  exitcode=1
+  echo as_func_success failed.
+fi
 
-       ;;
-  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_me: error: cannot find myself; rerun with an absolute path" >&2
-   { (exit 1); exit 1; }; }
-  fi
-  case $CONFIG_SHELL in
-  '')
+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
+for as_dir in /usr/bin/posix$PATH_SEPARATOR/bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
 do
   IFS=$as_save_IFS
   test -z "$as_dir" && as_dir=.
-  for as_base in sh bash ksh sh5; do
-	 case $as_dir in
+  case $as_dir in
 	 /*)
-	   if ("$as_dir/$as_base" -c '
+	   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 which exist, to save several forks.
+	 if test -f "$as_shell" &&
+		{ ("$as_shell") 2> /dev/null <<\_ASEOF
+# Be Bourne compatible
+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
+BIN_SH=xpg4; export BIN_SH # for Tru64
+DUALCASE=1; export DUALCASE # for MKS sh
+
+:
+_ASEOF
+}; then
+  CONFIG_SHELL=$as_shell
+	       as_have_required=yes
+	       if { "$as_shell" 2> /dev/null <<\_ASEOF
+# Be Bourne compatible
+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
+BIN_SH=xpg4; export BIN_SH # for Tru64
+DUALCASE=1; export DUALCASE # for MKS sh
+
+:
+(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
-  as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
   test "x$as_lineno_1" != "x$as_lineno_2" &&
-  test "x$as_lineno_3"  = "x$as_lineno_2" ') 2>/dev/null; then
-	     $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
-	     $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
-	     CONFIG_SHELL=$as_dir/$as_base
-	     export CONFIG_SHELL
-	     exec "$CONFIG_SHELL" "$0" ${1+"$@"}
-	   fi;;
-	 esac
-       done
-done
-;;
-  esac
+  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 before each line; the second 'sed' does the real
-  # work.  The second script uses 'N' to pair each line-number line
-  # with the numbered line, and appends trailing '-' during
-  # substitution so that $LINENO is not a special case at line end.
+  # 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
-  # second 'sed' script.  Blame Lee E. McMahon for sed's syntax.  :-)
-  sed '=' <$as_myself |
+  # 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
-      s,$,-,
-      : loop
-      s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
+      :loop
+      s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
       t loop
-      s,-$,,
-      s,^['$as_cr_digits']*\n,,
+      s/-\n.*//
     ' >$as_me.lineno &&
-  chmod +x $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 sensible to this).
-  . ./$as_me.lineno
+  # original and so on.  Autoconf is especially sensitive to this).
+  . "./$as_me.lineno"
   # Exit status is that of the last command.
   exit
 }
 
 
-case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
-  *c*,-n*) ECHO_N= ECHO_C='
-' ECHO_T='	' ;;
-  *c*,*  ) ECHO_N=-n ECHO_C= ECHO_T= ;;
-  *)       ECHO_N= ECHO_C='\c' ECHO_T= ;;
+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; then
+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
-  # We could just check for DJGPP; but this test a) works b) is more generic
-  # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
-  if test -f conf$$.exe; then
-    # Don't use ln at all; we don't have any links
+  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'
-  else
-    as_ln_s='ln -s'
-  fi
 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$$.file
+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=:
@@ -222,7 +512,19 @@
   as_mkdir_p=false
 fi
 
-as_executable_p="test -f"
+# Find out whether ``test -x'' works.  Don't use a zero-byte file, as
+# systems may use methods other than mode bits to determine executability.
+cat >conf$$.file <<_ASEOF
+#! /bin/sh
+exit 0
+_ASEOF
+chmod +x conf$$.file
+if test -x conf$$.file >/dev/null 2>&1; then
+  as_executable_p="test -x"
+else
+  as_executable_p=:
+fi
+rm -f conf$$.file
 
 # 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'"
@@ -231,17 +533,8 @@
 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
 
 
-# IFS
-# We need space, tab and new line, in precisely that order.
-as_nl='
-'
-IFS=" 	$as_nl"
 
-# CDPATH.
-$as_unset CDPATH
 
-
-
 # Check that we are running under the correct shell.
 SHELL=${CONFIG_SHELL-/bin/sh}
 
@@ -395,29 +688,26 @@
 
 tagnames=${tagnames+${tagnames},}F77
 
+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`
 
-exec 6>&1
-
 #
 # 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}
 
-# Maximum number of lines to put in a shell here document.
-# This variable seems obsolete.  It should probably be removed, and
-# only ac_max_sed_lines should be used.
-: ${ac_max_here_lines=38}
-
 # Identity of this package.
 PACKAGE_NAME=
 PACKAGE_TARNAME=
@@ -454,18 +744,199 @@
 #endif
 #if HAVE_INTTYPES_H
 # include <inttypes.h>
-#else
-# if HAVE_STDINT_H
-#  include <stdint.h>
-# endif
 #endif
+#if HAVE_STDINT_H
+# include <stdint.h>
+#endif
 #if 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 datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS build build_cpu build_vendor build_os host host_cpu host_vendor host_os LIBXSLT_MAJOR_VERSION LIBXSLT_MINOR_VERSION LIBXSLT_MICRO_VERSION LIBXSLT_VERSION LIBXSLT_VERSION_INFO LIBXSLT_VERSION_NUMBER LIBXSLT_VERSION_EXTRA LIBXSLT_MAJOR_MINOR_VERSION LIBEXSLT_MAJOR_VERSION LIBEXSLT_MINOR_VERSION LIBEXSLT_MICRO_VERSION LIBEXSLT_VERSION LIBEXSLT_VERSION_INFO LIBEXSLT_VERSION_NUMBER LIBEXSLT_VERSION_EXTRA INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA CYGPATH_W PACKAGE VERSION ACLOCAL AUTOCONF AUTOMAKE AUTOHEADER MAKEINFO install_sh STRIP ac_ct_STRIP INSTALL_STRIP_PROGRAM mkdir_p AWK SET_MAKE am__leading_dot AMTAR am__tar am__untar MAINTAINER_MODE_TRUE MAINTAINER_MODE_FALSE MAINT HTML_DIR CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT DEPDIR am__include am__quote AMDEP_TRUE AMDEP_FALSE AMDEPBACKSLASH CCDEPMODE am__fastdepCC_TRUE am__fastdepCC_FALSE CPP RM MV TAR EGREP LN_S ECHO AR ac_ct_AR RANLIB ac_ct_RANLIB CXX CXXFLAGS ac_ct_CXX CXXDEPMODE am__fastdepCXX_TRUE am__fastdepCXX_FALSE CXXCPP F77 FFLAGS ac_ct_F77 LIBTOOL WITH_TRIO PERL WITH_PERL_TRUE WITH_PERL_FALSE PYTHON WITH_PYTHON_TRUE WITH_PYTHON_FALSE pythondir PYTHON_SUBDIR LIBGCRYPT_CONFIG WITH_CRYPTO LIBGCRYPT_CFLAGS LIBGCRYPT_LIBS STATIC_BINARIES WITH_XSLT_DEBUG WITH_MEM_DEBUG WITH_DEBUGGER_TRUE WITH_DEBUGGER_FALSE WITH_DEBUGGER LIBXML_SRC LIBXML_REQUIRED_VERSION WITH_MODULES WITH_MODULES_TRUE WITH_MODULES_FALSE LIBXSLT_DEFAULT_PLUGINS_PATH WIN32_EXTRA_LIBADD WIN32_EXTRA_LDFLAGS XSLTPROCDV PYTHONSODV XML_CONFIG LIBXML_LIBS LIBXML_CFLAGS PYTHON_VERSION PYTHON_INCLUDES PYTHON_SITE_PACKAGES XSLT_LIBDIR XSLT_INCLUDEDIR XSLT_LIBS EXSLT_LIBDIR EXSLT_INCLUDEDIR EXSLT_LIBS EXTRA_LIBS M_LIBS RELDATE LIBOBJS LTLIBOBJS'
+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
+build
+build_cpu
+build_vendor
+build_os
+host
+host_cpu
+host_vendor
+host_os
+LIBXSLT_MAJOR_VERSION
+LIBXSLT_MINOR_VERSION
+LIBXSLT_MICRO_VERSION
+LIBXSLT_VERSION
+LIBXSLT_VERSION_INFO
+LIBXSLT_VERSION_NUMBER
+LIBXSLT_VERSION_EXTRA
+LIBXSLT_MAJOR_MINOR_VERSION
+LIBEXSLT_MAJOR_VERSION
+LIBEXSLT_MINOR_VERSION
+LIBEXSLT_MICRO_VERSION
+LIBEXSLT_VERSION
+LIBEXSLT_VERSION_INFO
+LIBEXSLT_VERSION_NUMBER
+LIBEXSLT_VERSION_EXTRA
+INSTALL_PROGRAM
+INSTALL_SCRIPT
+INSTALL_DATA
+CYGPATH_W
+PACKAGE
+VERSION
+ACLOCAL
+AUTOCONF
+AUTOMAKE
+AUTOHEADER
+MAKEINFO
+install_sh
+STRIP
+INSTALL_STRIP_PROGRAM
+mkdir_p
+AWK
+SET_MAKE
+am__leading_dot
+AMTAR
+am__tar
+am__untar
+MAINTAINER_MODE_TRUE
+MAINTAINER_MODE_FALSE
+MAINT
+HTML_DIR
+CC
+CFLAGS
+LDFLAGS
+CPPFLAGS
+ac_ct_CC
+EXEEXT
+OBJEXT
+DEPDIR
+am__include
+am__quote
+AMDEP_TRUE
+AMDEP_FALSE
+AMDEPBACKSLASH
+CCDEPMODE
+am__fastdepCC_TRUE
+am__fastdepCC_FALSE
+CPP
+RM
+MV
+TAR
+GREP
+EGREP
+LN_S
+ECHO
+AR
+RANLIB
+CXX
+CXXFLAGS
+ac_ct_CXX
+CXXDEPMODE
+am__fastdepCXX_TRUE
+am__fastdepCXX_FALSE
+CXXCPP
+F77
+FFLAGS
+ac_ct_F77
+LIBTOOL
+WITH_TRIO
+PERL
+WITH_PERL_TRUE
+WITH_PERL_FALSE
+PYTHON
+WITH_PYTHON_TRUE
+WITH_PYTHON_FALSE
+pythondir
+PYTHON_SUBDIR
+LIBGCRYPT_CONFIG
+WITH_CRYPTO
+LIBGCRYPT_CFLAGS
+LIBGCRYPT_LIBS
+STATIC_BINARIES
+WITH_XSLT_DEBUG
+WITH_MEM_DEBUG
+WITH_DEBUGGER_TRUE
+WITH_DEBUGGER_FALSE
+WITH_DEBUGGER
+LIBXML_SRC
+LIBXML_REQUIRED_VERSION
+WITH_MODULES
+WITH_MODULES_TRUE
+WITH_MODULES_FALSE
+LIBXSLT_DEFAULT_PLUGINS_PATH
+WIN32_EXTRA_LIBADD
+WIN32_EXTRA_LDFLAGS
+XSLTPROCDV
+PYTHONSODV
+XML_CONFIG
+LIBXML_LIBS
+LIBXML_CFLAGS
+PYTHON_VERSION
+PYTHON_INCLUDES
+PYTHON_SITE_PACKAGES
+XSLT_LIBDIR
+XSLT_INCLUDEDIR
+XSLT_LIBS
+EXSLT_LIBDIR
+EXSLT_INCLUDEDIR
+EXSLT_LIBS
+EXTRA_LIBS
+M_LIBS
+RELDATE
+LIBOBJS
+LTLIBOBJS'
 ac_subst_files=''
+      ac_precious_vars='build_alias
+host_alias
+target_alias
+CC
+CFLAGS
+LDFLAGS
+CPPFLAGS
+CPP
+CXX
+CXXFLAGS
+CCC
+CXXCPP
+F77
+FFLAGS'
 
+
 # Initialize some variables set by options.
 ac_init_help=
 ac_init_version=false
@@ -491,34 +962,48 @@
 # 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'
-datadir='${prefix}/share'
+datarootdir='${prefix}/share'
+datadir='${datarootdir}'
 sysconfdir='${prefix}/etc'
 sharedstatedir='${prefix}/com'
 localstatedir='${prefix}/var'
-libdir='${exec_prefix}/lib'
 includedir='${prefix}/include'
 oldincludedir='/usr/include'
-infodir='${prefix}/info'
-mandir='${prefix}/man'
+docdir='${datarootdir}/doc/${PACKAGE}'
+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"
+    eval $ac_prev=\$ac_option
     ac_prev=
     continue
   fi
 
-  ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
+  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_option in
+  case $ac_dashdash$ac_option in
+  --)
+    ac_dashdash=yes ;;
 
   -bindir | --bindir | --bindi | --bind | --bin | --bi)
     ac_prev=bindir ;;
@@ -540,12 +1025,18 @@
   --config-cache | -C)
     cache_file=config.cache ;;
 
-  -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
+  -datadir | --datadir | --datadi | --datad)
     ac_prev=datadir ;;
-  -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
-  | --da=*)
+  -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.
@@ -553,8 +1044,18 @@
       { 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" ;;
+    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.
@@ -562,11 +1063,7 @@
       { echo "$as_me: error: invalid feature name: $ac_feature" >&2
    { (exit 1); exit 1; }; }
     ac_feature=`echo $ac_feature | sed 's/-/_/g'`
-    case $ac_option in
-      *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
-      *) ac_optarg=yes ;;
-    esac
-    eval "enable_$ac_feature='$ac_optarg'" ;;
+    eval enable_$ac_feature=\$ac_optarg ;;
 
   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
@@ -593,6 +1090,12 @@
   -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 ;;
@@ -617,13 +1120,16 @@
   | --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 | --local | --loca | --loc | --lo)
+  | --localstate | --localstat | --localsta | --localst | --locals)
     ac_prev=localstatedir ;;
   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
-  | --localstate=* | --localstat=* | --localsta=* | --localst=* \
-  | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
+  | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
     localstatedir=$ac_optarg ;;
 
   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
@@ -688,6 +1194,16 @@
   | --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 ;;
@@ -744,11 +1260,7 @@
       { echo "$as_me: error: invalid package name: $ac_package" >&2
    { (exit 1); exit 1; }; }
     ac_package=`echo $ac_package| sed 's/-/_/g'`
-    case $ac_option in
-      *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
-      *) ac_optarg=yes ;;
-    esac
-    eval "with_$ac_package='$ac_optarg'" ;;
+    eval with_$ac_package=\$ac_optarg ;;
 
   -without-* | --without-*)
     ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
@@ -757,7 +1269,7 @@
       { 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" ;;
+    eval with_$ac_package=no ;;
 
   --x)
     # Obsolete; use --with-x.
@@ -788,8 +1300,7 @@
     expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
       { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
    { (exit 1); exit 1; }; }
-    ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
-    eval "$ac_envvar='$ac_optarg'"
+    eval $ac_envvar=\$ac_optarg
     export $ac_envvar ;;
 
   *)
@@ -809,29 +1320,21 @@
    { (exit 1); exit 1; }; }
 fi
 
-# Be sure to have absolute paths.
-for ac_var in exec_prefix prefix
+# 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=$`echo $ac_var`
+  eval ac_val=\$$ac_var
   case $ac_val in
-    [\\/$]* | ?:[\\/]* | NONE | '' ) ;;
-    *)  { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
-   { (exit 1); exit 1; }; };;
+    [\\/$]* | ?:[\\/]* )  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
 
-# Be sure to have absolute paths.
-for ac_var in bindir sbindir libexecdir datadir sysconfdir sharedstatedir \
-	      localstatedir libdir includedir oldincludedir infodir mandir
-do
-  eval ac_val=$`echo $ac_var`
-  case $ac_val in
-    [\\/$]* | ?:[\\/]* ) ;;
-    *)  { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
-   { (exit 1); exit 1; }; };;
-  esac
-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.
@@ -856,94 +1359,76 @@
 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 its parent.
-  ac_confdir=`(dirname "$0") 2>/dev/null ||
+  # 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 ||
+	 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'`
+    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
+  if test ! -r "$srcdir/$ac_unique_file"; then
     srcdir=..
   fi
 else
   ac_srcdir_defaulted=no
 fi
-if test ! -r $srcdir/$ac_unique_file; then
-  if test "$ac_srcdir_defaulted" = yes; then
-    { echo "$as_me: error: cannot find sources ($ac_unique_file) in $ac_confdir or .." >&2
+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; }; }
-  else
-    { echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
+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; }; }
-  fi
+	pwd)`
+# When building in place, set srcdir=.
+if test "$ac_abs_confdir" = "$ac_pwd"; then
+  srcdir=.
 fi
-(cd $srcdir && test -r ./$ac_unique_file) 2>/dev/null ||
-  { echo "$as_me: error: sources are in $srcdir, but \`cd $srcdir' does not work" >&2
-   { (exit 1); exit 1; }; }
-srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'`
-ac_env_build_alias_set=${build_alias+set}
-ac_env_build_alias_value=$build_alias
-ac_cv_env_build_alias_set=${build_alias+set}
-ac_cv_env_build_alias_value=$build_alias
-ac_env_host_alias_set=${host_alias+set}
-ac_env_host_alias_value=$host_alias
-ac_cv_env_host_alias_set=${host_alias+set}
-ac_cv_env_host_alias_value=$host_alias
-ac_env_target_alias_set=${target_alias+set}
-ac_env_target_alias_value=$target_alias
-ac_cv_env_target_alias_set=${target_alias+set}
-ac_cv_env_target_alias_value=$target_alias
-ac_env_CC_set=${CC+set}
-ac_env_CC_value=$CC
-ac_cv_env_CC_set=${CC+set}
-ac_cv_env_CC_value=$CC
-ac_env_CFLAGS_set=${CFLAGS+set}
-ac_env_CFLAGS_value=$CFLAGS
-ac_cv_env_CFLAGS_set=${CFLAGS+set}
-ac_cv_env_CFLAGS_value=$CFLAGS
-ac_env_LDFLAGS_set=${LDFLAGS+set}
-ac_env_LDFLAGS_value=$LDFLAGS
-ac_cv_env_LDFLAGS_set=${LDFLAGS+set}
-ac_cv_env_LDFLAGS_value=$LDFLAGS
-ac_env_CPPFLAGS_set=${CPPFLAGS+set}
-ac_env_CPPFLAGS_value=$CPPFLAGS
-ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set}
-ac_cv_env_CPPFLAGS_value=$CPPFLAGS
-ac_env_CPP_set=${CPP+set}
-ac_env_CPP_value=$CPP
-ac_cv_env_CPP_set=${CPP+set}
-ac_cv_env_CPP_value=$CPP
-ac_env_CXX_set=${CXX+set}
-ac_env_CXX_value=$CXX
-ac_cv_env_CXX_set=${CXX+set}
-ac_cv_env_CXX_value=$CXX
-ac_env_CXXFLAGS_set=${CXXFLAGS+set}
-ac_env_CXXFLAGS_value=$CXXFLAGS
-ac_cv_env_CXXFLAGS_set=${CXXFLAGS+set}
-ac_cv_env_CXXFLAGS_value=$CXXFLAGS
-ac_env_CXXCPP_set=${CXXCPP+set}
-ac_env_CXXCPP_value=$CXXCPP
-ac_cv_env_CXXCPP_set=${CXXCPP+set}
-ac_cv_env_CXXCPP_value=$CXXCPP
-ac_env_F77_set=${F77+set}
-ac_env_F77_value=$F77
-ac_cv_env_F77_set=${F77+set}
-ac_cv_env_F77_value=$F77
-ac_env_FFLAGS_set=${FFLAGS+set}
-ac_env_FFLAGS_value=$FFLAGS
-ac_cv_env_FFLAGS_set=${FFLAGS+set}
-ac_cv_env_FFLAGS_value=$FFLAGS
+# 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.
@@ -972,9 +1457,6 @@
   -n, --no-create         do not create output files
       --srcdir=DIR        find the sources in DIR [configure dir or \`..']
 
-_ACEOF
-
-  cat <<_ACEOF
 Installation directories:
   --prefix=PREFIX         install architecture-independent files in PREFIX
 			  [$ac_default_prefix]
@@ -992,15 +1474,22 @@
   --bindir=DIR           user executables [EPREFIX/bin]
   --sbindir=DIR          system admin executables [EPREFIX/sbin]
   --libexecdir=DIR       program executables [EPREFIX/libexec]
-  --datadir=DIR          read-only architecture-independent data [PREFIX/share]
   --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]
-  --infodir=DIR          info documentation [PREFIX/info]
-  --mandir=DIR           man documentation [PREFIX/man]
+  --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/PACKAGE]
+  --htmldir=DIR          html documentation [DOCDIR]
+  --dvidir=DIR           dvi documentation [DOCDIR]
+  --pdfdir=DIR           pdf documentation [DOCDIR]
+  --psdir=DIR            ps documentation [DOCDIR]
 _ACEOF
 
   cat <<\_ACEOF
@@ -1027,10 +1516,8 @@
 			  (and sometimes confusing) to the casual installer
   --disable-dependency-tracking  speeds up one-time build
   --enable-dependency-tracking   do not reject slow dependency extractors
-  --enable-shared[=PKGS]
-                          build shared libraries [default=yes]
-  --enable-static[=PKGS]
-                          build static libraries [default=yes]
+  --enable-shared[=PKGS]  build shared libraries [default=yes]
+  --enable-static[=PKGS]  build static libraries [default=yes]
   --enable-fast-install[=PKGS]
                           optimize for fast installation [default=yes]
   --disable-libtool-lock  avoid locking (might break parallel builds)
@@ -1042,8 +1529,7 @@
   --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
   --with-pic              try to use only PIC/non-PIC objects [default=use
                           both]
-  --with-tags[=TAGS]
-                          include additional configurations [automatic]
+  --with-tags[=TAGS]      include additional configurations [automatic]
   --with-python=DIR    Build Python bindings if found
   --with-crypto           Add crypto support to exslt (on)
   --with-debug            Add the debugging code (on)
@@ -1060,8 +1546,8 @@
   CFLAGS      C compiler flags
   LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
               nonstandard directory <lib dir>
-  CPPFLAGS    C/C++ preprocessor flags, e.g. -I<include dir> if you have
-              headers in a nonstandard directory <include dir>
+  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
   CXX         C++ compiler command
   CXXFLAGS    C++ compiler flags
@@ -1073,118 +1559,86 @@
 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.
-  ac_popdir=`pwd`
   for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
-    test -d $ac_dir || continue
+    test -d "$ac_dir" || continue
     ac_builddir=.
 
-if test "$ac_dir" != .; then
+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=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
-else
-  ac_dir_suffix= ac_top_builddir=
-fi
+  # 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
-  .)  # No --srcdir option.  We are building in place.
+  .)  # We are building in place.
     ac_srcdir=.
-    if test -z "$ac_top_builddir"; then
-       ac_top_srcdir=.
-    else
-       ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
-    fi ;;
-  [\\/]* | ?:[\\/]* )  # Absolute path.
+    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 ;;
-  *) # Relative path.
-    ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
-    ac_top_srcdir=$ac_top_builddir$srcdir ;;
+    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
 
-# Do not use `cd foo && pwd` to compute absolute paths, because
-# the directories may not exist.
-case `pwd` in
-.) ac_abs_builddir="$ac_dir";;
-*)
-  case "$ac_dir" in
-  .) ac_abs_builddir=`pwd`;;
-  [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
-  *) ac_abs_builddir=`pwd`/"$ac_dir";;
-  esac;;
-esac
-case $ac_abs_builddir in
-.) ac_abs_top_builddir=${ac_top_builddir}.;;
-*)
-  case ${ac_top_builddir}. in
-  .) ac_abs_top_builddir=$ac_abs_builddir;;
-  [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
-  *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
-  esac;;
-esac
-case $ac_abs_builddir in
-.) ac_abs_srcdir=$ac_srcdir;;
-*)
-  case $ac_srcdir in
-  .) ac_abs_srcdir=$ac_abs_builddir;;
-  [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
-  *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
-  esac;;
-esac
-case $ac_abs_builddir in
-.) ac_abs_top_srcdir=$ac_top_srcdir;;
-*)
-  case $ac_top_srcdir in
-  .) ac_abs_top_srcdir=$ac_abs_builddir;;
-  [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
-  *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
-  esac;;
-esac
-
-    cd $ac_dir
-    # Check for guested configure; otherwise get Cygnus style 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
-    elif test -f $ac_srcdir/configure.ac ||
-	   test -f $ac_srcdir/configure.in; then
-      echo
-      $ac_configure --help
+    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
-    cd "$ac_popdir"
+    fi || ac_status=$?
+    cd "$ac_pwd" || { ac_status=$?; break; }
   done
 fi
 
-test -n "$ac_init_help" && exit 0
+test -n "$ac_init_help" && exit $ac_status
 if $ac_init_version; then
   cat <<\_ACEOF
+configure
+generated by GNU Autoconf 2.59e
 
-Copyright (C) 2003 Free Software Foundation, Inc.
+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 0
+  exit
 fi
-exec 5>config.log
-cat >&5 <<_ACEOF
+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 $as_me, which was
-generated by GNU Autoconf 2.59.  Invocation command line was
+generated by GNU Autoconf 2.59e.  Invocation command line was
 
   $ $0 $@
 
 _ACEOF
+exec 5>>config.log
 {
 cat <<_ASUNAME
 ## --------- ##
@@ -1203,7 +1657,7 @@
 /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`
-hostinfo               = `(hostinfo) 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`
@@ -1217,6 +1671,7 @@
   test -z "$as_dir" && as_dir=.
   echo "PATH: $as_dir"
 done
+IFS=$as_save_IFS
 
 } >&5
 
@@ -1238,7 +1693,6 @@
 ac_configure_args=
 ac_configure_args0=
 ac_configure_args1=
-ac_sep=
 ac_must_keep_next=false
 for ac_pass in 1 2
 do
@@ -1249,7 +1703,7 @@
     -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
@@ -1271,9 +1725,7 @@
 	  -* ) ac_must_keep_next=true ;;
 	esac
       fi
-      ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
-      # Get rid of the leading space.
-      ac_sep=" "
+      ac_configure_args="$ac_configure_args '$ac_arg'"
       ;;
     esac
   done
@@ -1284,8 +1736,8 @@
 # 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: Be sure not to use single quotes in there, as some shells,
-# such as our DU 5.0 friend, will then `close' the trap.
+# 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.
   {
@@ -1298,20 +1750,34 @@
 _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 `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
-    *ac_space=\ *)
+    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"
-      ;;
+	"s/'\''/'\''\\\\'\'''\''/g;
+	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
+      ;; #(
     *)
-      sed -n \
-	"s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
+      sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
       ;;
-    esac;
-}
+    esac |
+    sort
+)
     echo
 
     cat <<\_ASBOX
@@ -1322,22 +1788,28 @@
     echo
     for ac_var in $ac_subst_vars
     do
-      eval ac_val=$`echo $ac_var`
-      echo "$ac_var='"'"'$ac_val'"'"'"
+      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
-## ------------- ##
-## Output files. ##
-## ------------- ##
+## ------------------- ##
+## File substitutions. ##
+## ------------------- ##
 _ASBOX
       echo
       for ac_var in $ac_subst_files
       do
-	eval ac_val=$`echo $ac_var`
-	echo "$ac_var='"'"'$ac_val'"'"'"
+	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
@@ -1349,26 +1821,24 @@
 ## ----------- ##
 _ASBOX
       echo
-      sed "/^$/d" confdefs.h | sort
+      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 &&
-  rm -rf conftest* confdefs* conf$$* $ac_clean_files &&
+  rm -f core *.core core.conftest.* &&
+    rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
     exit $exit_status
-     ' 0
+' 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 -rf conftest* confdefs.h
-# AIX cpp loses on an empty file, so make sure it contains at least a newline.
-echo >confdefs.h
+rm -f -r conftest* confdefs.h
 
 # Predefined preprocessor variables.
 
@@ -1399,14 +1869,17 @@
 
 # Let the site file select an alternate cache file if it wants to.
 # Prefer explicitly selected file to automatically selected ones.
-if test -z "$CONFIG_SITE"; then
-  if test "x$prefix" != xNONE; then
-    CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
-  else
-    CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
-  fi
+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
-for ac_site_file in $CONFIG_SITE; do
+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;}
@@ -1422,8 +1895,8 @@
     { 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;;
+      [\\/]* | ?:[\\/]* ) . "$cache_file";;
+      *)                      . "./$cache_file";;
     esac
   fi
 else
@@ -1435,12 +1908,11 @@
 # Check that the precious variables saved in the cache have kept the same
 # value.
 ac_cache_corrupted=false
-for ac_var in `(set) 2>&1 |
-	       sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
+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"
+  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
@@ -1465,8 +1937,7 @@
   # 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=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
     *) ac_arg=$ac_var=$ac_new_val ;;
     esac
     case " $ac_configure_args " in
@@ -1483,11 +1954,6 @@
    { (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
 
 
 
@@ -1504,99 +1970,138 @@
 
 
 
+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_config_headers="$ac_config_headers config.h"
 
-          ac_config_headers="$ac_config_headers config.h"
-
 ac_aux_dir=
-for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
-  if test -f $ac_dir/install-sh; then
+for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; 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
+  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
+  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 $srcdir $srcdir/.. $srcdir/../.." >&5
-echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
+  { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" >&5
+echo "$as_me: error: cannot find install-sh or install.sh in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" >&2;}
    { (exit 1); exit 1; }; }
 fi
-ac_config_guess="$SHELL $ac_aux_dir/config.guess"
-ac_config_sub="$SHELL $ac_aux_dir/config.sub"
-ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
 
+# 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.
+
+
 # Make sure we can run config.sub.
-$ac_config_sub sun4 >/dev/null 2>&1 ||
-  { { echo "$as_me:$LINENO: error: cannot run $ac_config_sub" >&5
-echo "$as_me: error: cannot run $ac_config_sub" >&2;}
+$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
+  { { echo "$as_me:$LINENO: error: cannot run $SHELL $ac_aux_dir/config.sub" >&5
+echo "$as_me: error: cannot run $SHELL $ac_aux_dir/config.sub" >&2;}
    { (exit 1); exit 1; }; }
 
-echo "$as_me:$LINENO: checking build system type" >&5
-echo $ECHO_N "checking build system type... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking build system type" >&5
+echo $ECHO_N "checking build system type... $ECHO_C" >&6; }
 if test "${ac_cv_build+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_cv_build_alias=$build_alias
-test -z "$ac_cv_build_alias" &&
-  ac_cv_build_alias=`$ac_config_guess`
-test -z "$ac_cv_build_alias" &&
+  ac_build_alias=$build_alias
+test "x$ac_build_alias" = x &&
+  ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
+test "x$ac_build_alias" = x &&
   { { echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
 echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
    { (exit 1); exit 1; }; }
-ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
-  { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_build_alias failed" >&5
-echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed" >&2;}
+ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
+  { { echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&5
+echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&2;}
    { (exit 1); exit 1; }; }
 
 fi
-echo "$as_me:$LINENO: result: $ac_cv_build" >&5
-echo "${ECHO_T}$ac_cv_build" >&6
+{ echo "$as_me:$LINENO: result: $ac_cv_build" >&5
+echo "${ECHO_T}$ac_cv_build" >&6; }
+case $ac_cv_build in
+*-*-*) ;;
+*) { { echo "$as_me:$LINENO: error: invalid value of canonical build" >&5
+echo "$as_me: error: invalid value of canonical build" >&2;}
+   { (exit 1); exit 1; }; };;
+esac
 build=$ac_cv_build
-build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
-build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
-build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
+ac_save_IFS=$IFS; IFS='-'
+set x $ac_cv_build
+shift
+build_cpu=$1
+build_vendor=$2
+shift; shift
+# Remember, the first character of IFS is used to create $*,
+# except with old shells:
+build_os=$*
+IFS=$ac_save_IFS
+case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
 
 
-echo "$as_me:$LINENO: checking host system type" >&5
-echo $ECHO_N "checking host system type... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking host system type" >&5
+echo $ECHO_N "checking host system type... $ECHO_C" >&6; }
 if test "${ac_cv_host+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_cv_host_alias=$host_alias
-test -z "$ac_cv_host_alias" &&
-  ac_cv_host_alias=$ac_cv_build_alias
-ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
-  { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_host_alias failed" >&5
-echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
+  if test "x$host_alias" = x; then
+  ac_cv_host=$ac_cv_build
+else
+  ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
+    { { echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&5
+echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&2;}
    { (exit 1); exit 1; }; }
+fi
 
 fi
-echo "$as_me:$LINENO: result: $ac_cv_host" >&5
-echo "${ECHO_T}$ac_cv_host" >&6
+{ echo "$as_me:$LINENO: result: $ac_cv_host" >&5
+echo "${ECHO_T}$ac_cv_host" >&6; }
+case $ac_cv_host in
+*-*-*) ;;
+*) { { echo "$as_me:$LINENO: error: invalid value of canonical host" >&5
+echo "$as_me: error: invalid value of canonical host" >&2;}
+   { (exit 1); exit 1; }; };;
+esac
 host=$ac_cv_host
-host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
-host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
-host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
+ac_save_IFS=$IFS; IFS='-'
+set x $ac_cv_host
+shift
+host_cpu=$1
+host_vendor=$2
+shift; shift
+# Remember, the first character of IFS is used to create $*,
+# except with old shells:
+host_os=$*
+IFS=$ac_save_IFS
+case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
 
 
 
 LIBXSLT_MAJOR_VERSION=1
 LIBXSLT_MINOR_VERSION=1
-LIBXSLT_MICRO_VERSION=16
+LIBXSLT_MICRO_VERSION=17
 PACKAGE=libxslt
 LIBEXSLT_MAJOR_VERSION=0
 LIBEXSLT_MINOR_VERSION=8
 LIBEXSLT_MICRO_VERSION=13
-LIBXML_REQUIRED_VERSION=2.6.17 # if you need module support.
+LIBXML_REQUIRED_VERSION=2.6.25
 
 
 LIBXSLT_VERSION=$LIBXSLT_MAJOR_VERSION.$LIBXSLT_MINOR_VERSION.$LIBXSLT_MICRO_VERSION
@@ -1657,8 +2162,8 @@
 # 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
+{ 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
@@ -1680,7 +2185,7 @@
     # by default.
     for ac_prog in ginstall scoinst install; do
       for ac_exec_ext in '' $ac_executable_extensions; do
-	if $as_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
+	if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_executable_p "$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.
@@ -1699,21 +2204,22 @@
     ;;
 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.  We don't cache a
-    # path for INSTALL within a source directory, because that will
+    # 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 path is relative.
+    # 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
+{ 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.
@@ -1723,8 +2229,8 @@
 
 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
 
-echo "$as_me:$LINENO: checking whether build environment is sane" >&5
-echo $ECHO_N "checking whether build environment is sane... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking whether build environment is sane" >&5
+echo $ECHO_N "checking whether build environment is sane... $ECHO_C" >&6; }
 # Just in case
 sleep 1
 echo timestamp > conftest.file
@@ -1766,20 +2272,20 @@
 Check your system clock" >&2;}
    { (exit 1); exit 1; }; }
 fi
-echo "$as_me:$LINENO: result: yes" >&5
-echo "${ECHO_T}yes" >&6
+{ echo "$as_me:$LINENO: result: yes" >&5
+echo "${ECHO_T}yes" >&6; }
 test "$program_prefix" != NONE &&
-  program_transform_name="s,^,$program_prefix,;$program_transform_name"
+  program_transform_name="s&^&$program_prefix&;$program_transform_name"
 # Use a double $ so make ignores it.
 test "$program_suffix" != NONE &&
-  program_transform_name="s,\$,$program_suffix,;$program_transform_name"
+  program_transform_name="s&\$&$program_suffix&;$program_transform_name"
 # Double any \ or $.  echo might interpret backslashes.
 # By default was `s,x,x', remove it if useless.
 cat <<\_ACEOF >conftest.sed
 s/[\\$]/&&/g;s/;s,x,x,$//
 _ACEOF
 program_transform_name=`echo $program_transform_name | sed -f conftest.sed`
-rm conftest.sed
+rm -f conftest.sed
 
 # expand $ac_aux_dir to an absolute path
 am_aux_dir=`cd $ac_aux_dir && pwd`
@@ -1831,8 +2337,8 @@
 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
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
 if test "${ac_cv_prog_AWK+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -1845,54 +2351,57 @@
   IFS=$as_save_IFS
   test -z "$as_dir" && as_dir=.
   for ac_exec_ext in '' $ac_executable_extensions; do
-  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; }; then
     ac_cv_prog_AWK="$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
 AWK=$ac_cv_prog_AWK
 if test -n "$AWK"; then
-  echo "$as_me:$LINENO: result: $AWK" >&5
-echo "${ECHO_T}$AWK" >&6
+  { echo "$as_me:$LINENO: result: $AWK" >&5
+echo "${ECHO_T}$AWK" >&6; }
 else
-  echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
 fi
 
+
   test -n "$AWK" && break
 done
 
-echo "$as_me:$LINENO: checking whether ${MAKE-make} sets \$(MAKE)" >&5
-echo $ECHO_N "checking whether ${MAKE-make} sets \$(MAKE)... $ECHO_C" >&6
-set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,:./+-,___p_,'`
-if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
+{ 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 'ac_maketemp="$(MAKE)"'
+	@echo '@@@%%%=$(MAKE)=@@@%%%'
 _ACEOF
 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
-eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=`
-if test -n "$ac_maketemp"; then
-  eval ac_cv_prog_make_${ac_make}_set=yes
-else
-  eval ac_cv_prog_make_${ac_make}_set=no
-fi
+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 \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
-  echo "$as_me:$LINENO: result: yes" >&5
-echo "${ECHO_T}yes" >&6
+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
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
   SET_MAKE="MAKE=${MAKE-make}"
 fi
 
@@ -1963,8 +2472,8 @@
   if test -n "$ac_tool_prefix"; then
   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
 set dummy ${ac_tool_prefix}strip; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
 if test "${ac_cv_prog_STRIP+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -1977,32 +2486,34 @@
   IFS=$as_save_IFS
   test -z "$as_dir" && as_dir=.
   for ac_exec_ext in '' $ac_executable_extensions; do
-  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; }; then
     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
     break 2
   fi
 done
 done
+IFS=$as_save_IFS
 
 fi
 fi
 STRIP=$ac_cv_prog_STRIP
 if test -n "$STRIP"; then
-  echo "$as_me:$LINENO: result: $STRIP" >&5
-echo "${ECHO_T}$STRIP" >&6
+  { echo "$as_me:$LINENO: result: $STRIP" >&5
+echo "${ECHO_T}$STRIP" >&6; }
 else
-  echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
 fi
 
+
 fi
 if test -z "$ac_cv_prog_STRIP"; then
   ac_ct_STRIP=$STRIP
   # Extract the first word of "strip", so it can be a program name with args.
 set dummy strip; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+{ 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_STRIP+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -2015,27 +2526,41 @@
   IFS=$as_save_IFS
   test -z "$as_dir" && as_dir=.
   for ac_exec_ext in '' $ac_executable_extensions; do
-  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; }; then
     ac_cv_prog_ac_ct_STRIP="strip"
     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_ac_ct_STRIP" && ac_cv_prog_ac_ct_STRIP=":"
 fi
 fi
 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
 if test -n "$ac_ct_STRIP"; then
-  echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
-echo "${ECHO_T}$ac_ct_STRIP" >&6
+  { echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
+echo "${ECHO_T}$ac_ct_STRIP" >&6; }
 else
-  echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
 fi
 
-  STRIP=$ac_ct_STRIP
+  if test "x$ac_ct_STRIP" = x; then
+    STRIP=":"
+  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
+    STRIP=$ac_ct_STRIP
+  fi
 else
   STRIP="$ac_cv_prog_STRIP"
 fi
@@ -2056,19 +2581,19 @@
 
 
 
-echo "$as_me:$LINENO: checking whether to enable maintainer-specific portions of Makefiles" >&5
-echo $ECHO_N "checking whether to enable maintainer-specific portions of Makefiles... $ECHO_C" >&6
-    # Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
+{ echo "$as_me:$LINENO: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo $ECHO_N "checking whether to enable maintainer-specific portions of Makefiles... $ECHO_C" >&6; }
+    # Check whether --enable-maintainer-mode was given.
 if test "${enable_maintainer_mode+set}" = set; then
-  enableval="$enable_maintainer_mode"
-  USE_MAINTAINER_MODE=$enableval
+  enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval
 else
   USE_MAINTAINER_MODE=no
-fi;
-  echo "$as_me:$LINENO: result: $USE_MAINTAINER_MODE" >&5
-echo "${ECHO_T}$USE_MAINTAINER_MODE" >&6
+fi
 
+  { echo "$as_me:$LINENO: result: $USE_MAINTAINER_MODE" >&5
+echo "${ECHO_T}$USE_MAINTAINER_MODE" >&6; }
 
+
 if test $USE_MAINTAINER_MODE = yes; then
   MAINTAINER_MODE_TRUE=
   MAINTAINER_MODE_FALSE='#'
@@ -2082,11 +2607,11 @@
 
 
 
-# Check whether --with-html-dir or --without-html-dir was given.
+# Check whether --with-html-dir was given.
 if test "${with_html_dir+set}" = set; then
-  withval="$with_html_dir"
+  withval=$with_html_dir;
+fi
 
-fi;
 
 
 if test "x$with_html_dir" = "x" ; then
@@ -2099,7 +2624,7 @@
 
 DEPDIR="${am__leading_dot}deps"
 
-          ac_config_commands="$ac_config_commands depfiles"
+ac_config_commands="$ac_config_commands depfiles"
 
 
 am_make=${MAKE-make}
@@ -2109,8 +2634,8 @@
 .PHONY: am__doit
 END
 # If we don't find an include directive, just comment out the code.
-echo "$as_me:$LINENO: checking for style of include used by $am_make" >&5
-echo $ECHO_N "checking for style of include used by $am_make... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for style of include used by $am_make" >&5
+echo $ECHO_N "checking for style of include used by $am_make... $ECHO_C" >&6; }
 am__include="#"
 am__quote=
 _am_result=none
@@ -2137,15 +2662,15 @@
 fi
 
 
-echo "$as_me:$LINENO: result: $_am_result" >&5
-echo "${ECHO_T}$_am_result" >&6
+{ echo "$as_me:$LINENO: result: $_am_result" >&5
+echo "${ECHO_T}$_am_result" >&6; }
 rm -f confinc confmf
 
-# Check whether --enable-dependency-tracking or --disable-dependency-tracking was given.
+# Check whether --enable-dependency-tracking was given.
 if test "${enable_dependency_tracking+set}" = set; then
-  enableval="$enable_dependency_tracking"
+  enableval=$enable_dependency_tracking;
+fi
 
-fi;
 if test "x$enable_dependency_tracking" != xno; then
   am_depcomp="$ac_aux_dir/depcomp"
   AMDEPBACKSLASH='\'
@@ -2170,8 +2695,8 @@
 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
+{ 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
@@ -2184,32 +2709,34 @@
   IFS=$as_save_IFS
   test -z "$as_dir" && as_dir=.
   for ac_exec_ext in '' $ac_executable_extensions; do
-  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_executable_p "$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
+  { 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
+  { 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
+{ 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
@@ -2222,36 +2749,51 @@
   IFS=$as_save_IFS
   test -z "$as_dir" && as_dir=.
   for ac_exec_ext in '' $ac_executable_extensions; do
-  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_executable_p "$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
+  { 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
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
 fi
 
-  CC=$ac_ct_CC
+  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.
+          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
+{ 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
@@ -2264,74 +2806,34 @@
   IFS=$as_save_IFS
   test -z "$as_dir" && as_dir=.
   for ac_exec_ext in '' $ac_executable_extensions; do
-  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_executable_p "$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
+  { 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
+  { 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 "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_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 $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
-    ac_cv_prog_ac_ct_CC="cc"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
+
   fi
-done
-done
-
 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
-
-  CC=$ac_ct_CC
-else
-  CC="$ac_cv_prog_CC"
-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
+{ 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
@@ -2345,7 +2847,7 @@
   IFS=$as_save_IFS
   test -z "$as_dir" && as_dir=.
   for ac_exec_ext in '' $ac_executable_extensions; do
-  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_executable_p "$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
@@ -2356,6 +2858,7 @@
   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.
@@ -2373,22 +2876,23 @@
 fi
 CC=$ac_cv_prog_CC
 if test -n "$CC"; then
-  echo "$as_me:$LINENO: result: $CC" >&5
-echo "${ECHO_T}$CC" >&6
+  { 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
+  { 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
+  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
+{ 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
@@ -2401,36 +2905,38 @@
   IFS=$as_save_IFS
   test -z "$as_dir" && as_dir=.
   for ac_exec_ext in '' $ac_executable_extensions; do
-  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_executable_p "$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
+  { 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
+  { 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
+  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
+{ 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
@@ -2443,29 +2949,45 @@
   IFS=$as_save_IFS
   test -z "$as_dir" && as_dir=.
   for ac_exec_ext in '' $ac_executable_extensions; do
-  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_executable_p "$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
+  { 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
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
 fi
 
+
   test -n "$ac_ct_CC" && break
 done
 
-  CC=$ac_ct_CC
+  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
@@ -2478,21 +3000,35 @@
    { (exit 1); exit 1; }; }
 
 # Provide some information about the compiler.
-echo "$as_me:$LINENO:" \
-     "checking for C compiler version" >&5
+echo "$as_me:$LINENO: checking for C compiler version" >&5
 ac_compiler=`set X $ac_compile; echo $2`
-{ (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
-  (eval $ac_compiler --version </dev/null >&5) 2>&5
+{ (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); }
-{ (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
-  (eval $ac_compiler -v </dev/null >&5) 2>&5
+{ (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); }
-{ (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
-  (eval $ac_compiler -V </dev/null >&5) 2>&5
+{ (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); }
@@ -2517,46 +3053,70 @@
 # 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
+{ 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[^ ]*//'`
-if { (eval echo "$as_me:$LINENO: \"$ac_link_default\"") >&5
-  (eval $ac_link_default) 2>&5
+#
+# 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
-  # Find the output, starting from the most likely.  This scheme is
-# not robust to junk in `.', hence go to wildcards (a.*) only as a last
-# resort.
-
-# Be careful to initialize this variable, since it used to be cached.
-# Otherwise an old cache value of `no' led to `EXEEXT = no' in a Makefile.
-ac_cv_exeext=
-# b.out is created by i960 compilers.
-for ac_file in a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out
+  # 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 | *.o | *.obj )
+    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj )
 	;;
-    conftest.$ac_ext )
-	# This is the source file.
-	;;
     [ab].out )
 	# We found the default executable, but exeext='' is most
 	# certainly right.
 	break;;
     *.* )
-	ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
-	# FIXME: I believe we export ac_cv_exeext for Libtool,
-	# but it would be cool to find out if it's true.  Does anybody
-	# maintain Libtool? --akim.
-	export ac_cv_exeext
+        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
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
@@ -2569,19 +3129,23 @@
 fi
 
 ac_exeext=$ac_cv_exeext
-echo "$as_me:$LINENO: result: $ac_file" >&5
-echo "${ECHO_T}$ac_file" >&6
+{ echo "$as_me:$LINENO: result: $ac_file" >&5
+echo "${ECHO_T}$ac_file" >&6; }
 
-# Check the compiler produces executables we can run.  If not, either
+# 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
+{ 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'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -2600,22 +3164,27 @@
     fi
   fi
 fi
-echo "$as_me:$LINENO: result: yes" >&5
-echo "${ECHO_T}yes" >&6
+{ 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 the compiler produces executables we can run.  If not, either
+# 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 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 { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
-  (eval $ac_link) 2>&5
+{ 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
@@ -2626,9 +3195,8 @@
 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 | *.o | *.obj ) ;;
+    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
-	  export ac_cv_exeext
 	  break;;
     * ) break;;
   esac
@@ -2642,14 +3210,14 @@
 fi
 
 rm -f conftest$ac_cv_exeext
-echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
-echo "${ECHO_T}$ac_cv_exeext" >&6
+{ 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
+{ 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
@@ -2669,14 +3237,20 @@
 }
 _ACEOF
 rm -f conftest.o conftest.obj
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
-  (eval $ac_compile) 2>&5
+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 `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
+  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 ) ;;
+    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf ) ;;
     *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
        break;;
   esac
@@ -2694,12 +3268,12 @@
 
 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
+{ 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
+{ 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
@@ -2722,23 +3296,36 @@
 }
 _ACEOF
 rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
-  (eval $ac_compile) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest.$ac_objext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -2747,24 +3334,28 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-ac_compiler_gnu=no
+	ac_compiler_gnu=no
 fi
+
 rm -f 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
+{ 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
-CFLAGS="-g"
-echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
-echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
+{ 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
-  cat >conftest.$ac_ext <<_ACEOF
+  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
@@ -2780,23 +3371,36 @@
 }
 _ACEOF
 rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
-  (eval $ac_compile) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest.$ac_objext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -2805,12 +3409,131 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-ac_cv_prog_cc_g=no
+	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); } &&
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
+	 { ac_try='test -s conftest.$ac_objext'
+  { (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: 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); } &&
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
+	 { ac_try='test -s conftest.$ac_objext'
+  { (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_prog_cc_g=yes
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+
 fi
+
 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
 fi
-echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
-echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
+
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+fi
+
+rm -f 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
@@ -2826,12 +3549,12 @@
     CFLAGS=
   fi
 fi
-echo "$as_me:$LINENO: checking for $CC option to accept ANSI C" >&5
-echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
-if test "${ac_cv_prog_cc_stdc+set}" = set; then
+{ 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_stdc=no
+  ac_cv_prog_cc_c89=no
 ac_save_CC=$CC
 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
@@ -2865,10 +3588,10 @@
 /* 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 -std1 is added to get
+   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 -std1.  */
+   that's true only with -std.  */
 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
 
 int test (int i, double x);
@@ -2885,201 +3608,74 @@
   return 0;
 }
 _ACEOF
-# Don't try gcc -ansi; that turns off useful extensions and
-# breaks some systems' header files.
-# AIX			-qlanglvl=ansi
-# Ultrix and OSF/1	-std1
-# HP-UX 10.20 and later	-Ae
-# HP-UX older versions	-Aa -D_HPUX_SOURCE
-# SVR4			-Xc -D__EXTENSIONS__
-for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
+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 { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
-  (eval $ac_compile) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest.$ac_objext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
-  ac_cv_prog_cc_stdc=$ac_arg
-break
+  ac_cv_prog_cc_c89=$ac_arg
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
+
 fi
+
 rm -f conftest.err conftest.$ac_objext
+  test "x$ac_cv_prog_cc_c89" != "xno" && break
 done
-rm -f conftest.$ac_ext conftest.$ac_objext
+rm -f conftest.$ac_ext
 CC=$ac_save_CC
 
 fi
-
-case "x$ac_cv_prog_cc_stdc" in
-  x|xno)
-    echo "$as_me:$LINENO: result: none needed" >&5
-echo "${ECHO_T}none needed" >&6 ;;
+# 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; } ;;
   *)
-    echo "$as_me:$LINENO: result: $ac_cv_prog_cc_stdc" >&5
-echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
-    CC="$CC $ac_cv_prog_cc_stdc" ;;
+    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
 
-# Some people use a C++ compiler to compile C.  Since we use `exit',
-# in C++ we need to declare it.  In case someone uses the same compiler
-# for both compiling C and C++ we need to have the C++ compiler decide
-# the declaration of exit, since it's the most demanding environment.
-cat >conftest.$ac_ext <<_ACEOF
-#ifndef __cplusplus
-  choke me
-#endif
-_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; } &&
-	 { ac_try='test -s conftest.$ac_objext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; }; then
-  for ac_declaration in \
-   '' \
-   'extern "C" void std::exit (int) throw (); using std::exit;' \
-   'extern "C" void std::exit (int); using std::exit;' \
-   'extern "C" void exit (int) throw ();' \
-   'extern "C" void exit (int);' \
-   'void exit (int);'
-do
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-$ac_declaration
-#include <stdlib.h>
-int
-main ()
-{
-exit (42);
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; } &&
-	 { ac_try='test -s conftest.$ac_objext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; }; then
-  :
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
 
-continue
-fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-$ac_declaration
-int
-main ()
-{
-exit (42);
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; } &&
-	 { ac_try='test -s conftest.$ac_objext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; }; then
-  break
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
-done
-rm -f conftest*
-if test -n "$ac_declaration"; then
-  echo '#ifdef __cplusplus' >>confdefs.h
-  echo $ac_declaration      >>confdefs.h
-  echo '#endif'             >>confdefs.h
-fi
-
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
 ac_ext=c
 ac_cpp='$CPP $CPPFLAGS'
 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
@@ -3088,8 +3684,8 @@
 
 depcc="$CC"   am_compiler_list=
 
-echo "$as_me:$LINENO: checking dependency style of $depcc" >&5
-echo $ECHO_N "checking dependency style of $depcc... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking dependency style of $depcc" >&5
+echo $ECHO_N "checking dependency style of $depcc... $ECHO_C" >&6; }
 if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -3178,8 +3774,8 @@
 fi
 
 fi
-echo "$as_me:$LINENO: result: $am_cv_CC_dependencies_compiler_type" >&5
-echo "${ECHO_T}$am_cv_CC_dependencies_compiler_type" >&6
+{ echo "$as_me:$LINENO: result: $am_cv_CC_dependencies_compiler_type" >&5
+echo "${ECHO_T}$am_cv_CC_dependencies_compiler_type" >&6; }
 CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
 
 
@@ -3196,13 +3792,12 @@
 
 
 
-echo "$as_me:$LINENO: checking for library containing strerror" >&5
-echo $ECHO_N "checking for library containing strerror... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for library containing strerror" >&5
+echo $ECHO_N "checking for library containing strerror... $ECHO_C" >&6; }
 if test "${ac_cv_search_strerror+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
   ac_func_search_save_LIBS=$LIBS
-ac_cv_search_strerror=no
 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -3210,113 +3805,89 @@
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 
-/* Override any gcc2 internal prototype to avoid an error.  */
+/* 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
-/* We use char because int might match the return type of a gcc2
-   builtin and then its argument prototype would still apply.  */
 char strerror ();
 int
 main ()
 {
-strerror ();
+return strerror ();
   ;
   return 0;
 }
 _ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
-  (eval $ac_link) 2>conftest.er1
+for ac_lib in '' cposix; do
+  if test -z "$ac_lib"; then
+    ac_res="none required"
+  else
+    ac_res=-l$ac_lib
+    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
+  fi
+  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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest$ac_exeext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
-  ac_cv_search_strerror="none required"
+  ac_cv_search_strerror=$ac_res
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
+
 fi
+
 rm -f conftest.err conftest.$ac_objext \
-      conftest$ac_exeext conftest.$ac_ext
-if test "$ac_cv_search_strerror" = no; then
-  for ac_lib in cposix; do
-    LIBS="-l$ac_lib  $ac_func_search_save_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 gcc2 internal prototype to avoid an error.  */
-#ifdef __cplusplus
-extern "C"
-#endif
-/* We use char because int might match the return type of a gcc2
-   builtin and then its argument prototype would still apply.  */
-char strerror ();
-int
-main ()
-{
-strerror ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; } &&
-	 { ac_try='test -s conftest$ac_exeext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; }; then
-  ac_cv_search_strerror="-l$ac_lib"
-break
+      conftest$ac_exeext
+  if test "${ac_cv_search_strerror+set}" = set; then
+  break
+fi
+done
+if test "${ac_cv_search_strerror+set}" = set; then
+  :
 else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
+  ac_cv_search_strerror=no
 fi
-rm -f conftest.err conftest.$ac_objext \
-      conftest$ac_exeext conftest.$ac_ext
-  done
-fi
+rm conftest.$ac_ext
 LIBS=$ac_func_search_save_LIBS
 fi
-echo "$as_me:$LINENO: result: $ac_cv_search_strerror" >&5
-echo "${ECHO_T}$ac_cv_search_strerror" >&6
-if test "$ac_cv_search_strerror" != no; then
-  test "$ac_cv_search_strerror" = "none required" || LIBS="$ac_cv_search_strerror $LIBS"
+{ echo "$as_me:$LINENO: result: $ac_cv_search_strerror" >&5
+echo "${ECHO_T}$ac_cv_search_strerror" >&6; }
+ac_res=$ac_cv_search_strerror
+if test "$ac_res" != no; then
+  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
 
 fi
 
@@ -3328,8 +3899,8 @@
 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
+{ 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
@@ -3342,32 +3913,34 @@
   IFS=$as_save_IFS
   test -z "$as_dir" && as_dir=.
   for ac_exec_ext in '' $ac_executable_extensions; do
-  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_executable_p "$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
+  { 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
+  { 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
+{ 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
@@ -3380,36 +3953,51 @@
   IFS=$as_save_IFS
   test -z "$as_dir" && as_dir=.
   for ac_exec_ext in '' $ac_executable_extensions; do
-  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_executable_p "$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
+  { 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
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
 fi
 
-  CC=$ac_ct_CC
+  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.
+          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
+{ 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
@@ -3422,74 +4010,34 @@
   IFS=$as_save_IFS
   test -z "$as_dir" && as_dir=.
   for ac_exec_ext in '' $ac_executable_extensions; do
-  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_executable_p "$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
+  { 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
+  { 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 "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_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 $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
-    ac_cv_prog_ac_ct_CC="cc"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
+
   fi
-done
-done
-
 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
-
-  CC=$ac_ct_CC
-else
-  CC="$ac_cv_prog_CC"
-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
+{ 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
@@ -3503,7 +4051,7 @@
   IFS=$as_save_IFS
   test -z "$as_dir" && as_dir=.
   for ac_exec_ext in '' $ac_executable_extensions; do
-  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_executable_p "$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
@@ -3514,6 +4062,7 @@
   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.
@@ -3531,22 +4080,23 @@
 fi
 CC=$ac_cv_prog_CC
 if test -n "$CC"; then
-  echo "$as_me:$LINENO: result: $CC" >&5
-echo "${ECHO_T}$CC" >&6
+  { 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
+  { 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
+  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
+{ 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
@@ -3559,36 +4109,38 @@
   IFS=$as_save_IFS
   test -z "$as_dir" && as_dir=.
   for ac_exec_ext in '' $ac_executable_extensions; do
-  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_executable_p "$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
+  { 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
+  { 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
+  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
+{ 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
@@ -3601,29 +4153,45 @@
   IFS=$as_save_IFS
   test -z "$as_dir" && as_dir=.
   for ac_exec_ext in '' $ac_executable_extensions; do
-  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_executable_p "$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
+  { 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
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
 fi
 
+
   test -n "$ac_ct_CC" && break
 done
 
-  CC=$ac_ct_CC
+  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
@@ -3636,27 +4204,41 @@
    { (exit 1); exit 1; }; }
 
 # Provide some information about the compiler.
-echo "$as_me:$LINENO:" \
-     "checking for C compiler version" >&5
+echo "$as_me:$LINENO: checking for C compiler version" >&5
 ac_compiler=`set X $ac_compile; echo $2`
-{ (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
-  (eval $ac_compiler --version </dev/null >&5) 2>&5
+{ (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); }
-{ (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
-  (eval $ac_compiler -v </dev/null >&5) 2>&5
+{ (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); }
-{ (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
-  (eval $ac_compiler -V </dev/null >&5) 2>&5
+{ (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); }
 
-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
+{ 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
@@ -3679,23 +4261,36 @@
 }
 _ACEOF
 rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
-  (eval $ac_compile) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest.$ac_objext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -3704,24 +4299,28 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-ac_compiler_gnu=no
+	ac_compiler_gnu=no
 fi
+
 rm -f 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
+{ 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
-CFLAGS="-g"
-echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
-echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
+{ 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
-  cat >conftest.$ac_ext <<_ACEOF
+  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
@@ -3737,23 +4336,36 @@
 }
 _ACEOF
 rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
-  (eval $ac_compile) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest.$ac_objext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -3762,12 +4374,131 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-ac_cv_prog_cc_g=no
+	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); } &&
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
+	 { ac_try='test -s conftest.$ac_objext'
+  { (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: 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); } &&
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
+	 { ac_try='test -s conftest.$ac_objext'
+  { (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_prog_cc_g=yes
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+
 fi
+
 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
 fi
-echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
-echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
+
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+fi
+
+rm -f 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
@@ -3783,12 +4514,12 @@
     CFLAGS=
   fi
 fi
-echo "$as_me:$LINENO: checking for $CC option to accept ANSI C" >&5
-echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
-if test "${ac_cv_prog_cc_stdc+set}" = set; then
+{ 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_stdc=no
+  ac_cv_prog_cc_c89=no
 ac_save_CC=$CC
 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
@@ -3822,10 +4553,10 @@
 /* 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 -std1 is added to get
+   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 -std1.  */
+   that's true only with -std.  */
 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
 
 int test (int i, double x);
@@ -3842,201 +4573,74 @@
   return 0;
 }
 _ACEOF
-# Don't try gcc -ansi; that turns off useful extensions and
-# breaks some systems' header files.
-# AIX			-qlanglvl=ansi
-# Ultrix and OSF/1	-std1
-# HP-UX 10.20 and later	-Ae
-# HP-UX older versions	-Aa -D_HPUX_SOURCE
-# SVR4			-Xc -D__EXTENSIONS__
-for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
+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 { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
-  (eval $ac_compile) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest.$ac_objext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
-  ac_cv_prog_cc_stdc=$ac_arg
-break
+  ac_cv_prog_cc_c89=$ac_arg
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
+
 fi
+
 rm -f conftest.err conftest.$ac_objext
+  test "x$ac_cv_prog_cc_c89" != "xno" && break
 done
-rm -f conftest.$ac_ext conftest.$ac_objext
+rm -f conftest.$ac_ext
 CC=$ac_save_CC
 
 fi
-
-case "x$ac_cv_prog_cc_stdc" in
-  x|xno)
-    echo "$as_me:$LINENO: result: none needed" >&5
-echo "${ECHO_T}none needed" >&6 ;;
+# 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; } ;;
   *)
-    echo "$as_me:$LINENO: result: $ac_cv_prog_cc_stdc" >&5
-echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
-    CC="$CC $ac_cv_prog_cc_stdc" ;;
+    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
 
-# Some people use a C++ compiler to compile C.  Since we use `exit',
-# in C++ we need to declare it.  In case someone uses the same compiler
-# for both compiling C and C++ we need to have the C++ compiler decide
-# the declaration of exit, since it's the most demanding environment.
-cat >conftest.$ac_ext <<_ACEOF
-#ifndef __cplusplus
-  choke me
-#endif
-_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; } &&
-	 { ac_try='test -s conftest.$ac_objext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; }; then
-  for ac_declaration in \
-   '' \
-   'extern "C" void std::exit (int) throw (); using std::exit;' \
-   'extern "C" void std::exit (int); using std::exit;' \
-   'extern "C" void exit (int) throw ();' \
-   'extern "C" void exit (int);' \
-   'void exit (int);'
-do
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-$ac_declaration
-#include <stdlib.h>
-int
-main ()
-{
-exit (42);
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; } &&
-	 { ac_try='test -s conftest.$ac_objext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; }; then
-  :
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
 
-continue
-fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-$ac_declaration
-int
-main ()
-{
-exit (42);
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; } &&
-	 { ac_try='test -s conftest.$ac_objext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; }; then
-  break
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
-done
-rm -f conftest*
-if test -n "$ac_declaration"; then
-  echo '#ifdef __cplusplus' >>confdefs.h
-  echo $ac_declaration      >>confdefs.h
-  echo '#endif'             >>confdefs.h
-fi
-
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
 ac_ext=c
 ac_cpp='$CPP $CPPFLAGS'
 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
@@ -4045,8 +4649,8 @@
 
 depcc="$CC"   am_compiler_list=
 
-echo "$as_me:$LINENO: checking dependency style of $depcc" >&5
-echo $ECHO_N "checking dependency style of $depcc... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking dependency style of $depcc" >&5
+echo $ECHO_N "checking dependency style of $depcc... $ECHO_C" >&6; }
 if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -4135,8 +4739,8 @@
 fi
 
 fi
-echo "$as_me:$LINENO: result: $am_cv_CC_dependencies_compiler_type" >&5
-echo "${ECHO_T}$am_cv_CC_dependencies_compiler_type" >&6
+{ echo "$as_me:$LINENO: result: $am_cv_CC_dependencies_compiler_type" >&5
+echo "${ECHO_T}$am_cv_CC_dependencies_compiler_type" >&6; }
 CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
 
 
@@ -4165,8 +4769,8 @@
 # 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
+{ 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
@@ -4188,7 +4792,7 @@
     # by default.
     for ac_prog in ginstall scoinst install; do
       for ac_exec_ext in '' $ac_executable_extensions; do
-	if $as_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
+	if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_executable_p "$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.
@@ -4207,21 +4811,22 @@
     ;;
 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.  We don't cache a
-    # path for INSTALL within a source directory, because that will
+    # 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 path is relative.
+    # 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
+{ 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.
@@ -4236,8 +4841,8 @@
 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
+{ 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=
@@ -4271,8 +4876,13 @@
 #endif
 		     Syntax error
 _ACEOF
-if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
-  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+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
@@ -4297,9 +4907,10 @@
   # Broken: fails on valid input.
 continue
 fi
+
 rm -f conftest.err conftest.$ac_ext
 
-  # OK, works on sane cases.  Now check whether non-existent headers
+  # OK, works on sane cases.  Now check whether nonexistent headers
   # can be detected and how.
   cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
@@ -4309,8 +4920,13 @@
 /* end confdefs.h.  */
 #include <ac_nonexistent.h>
 _ACEOF
-if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
-  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+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
@@ -4337,6 +4953,7 @@
 ac_preproc_ok=:
 break
 fi
+
 rm -f conftest.err conftest.$ac_ext
 
 done
@@ -4354,8 +4971,8 @@
 else
   ac_cv_prog_CPP=$CPP
 fi
-echo "$as_me:$LINENO: result: $CPP" >&5
-echo "${ECHO_T}$CPP" >&6
+{ 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
@@ -4378,8 +4995,13 @@
 #endif
 		     Syntax error
 _ACEOF
-if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
-  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+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
@@ -4404,9 +5026,10 @@
   # Broken: fails on valid input.
 continue
 fi
+
 rm -f conftest.err conftest.$ac_ext
 
-  # OK, works on sane cases.  Now check whether non-existent headers
+  # OK, works on sane cases.  Now check whether nonexistent headers
   # can be detected and how.
   cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
@@ -4416,8 +5039,13 @@
 /* end confdefs.h.  */
 #include <ac_nonexistent.h>
 _ACEOF
-if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
-  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+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
@@ -4444,6 +5072,7 @@
 ac_preproc_ok=:
 break
 fi
+
 rm -f conftest.err conftest.$ac_ext
 
 done
@@ -4467,8 +5096,8 @@
 
 # Extract the first word of "rm", so it can be a program name with args.
 set dummy rm; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
 if test "${ac_cv_path_RM+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -4483,32 +5112,33 @@
   IFS=$as_save_IFS
   test -z "$as_dir" && as_dir=.
   for ac_exec_ext in '' $ac_executable_extensions; do
-  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; }; then
     ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext"
     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_path_RM" && ac_cv_path_RM="/bin/rm"
   ;;
 esac
 fi
 RM=$ac_cv_path_RM
-
 if test -n "$RM"; then
-  echo "$as_me:$LINENO: result: $RM" >&5
-echo "${ECHO_T}$RM" >&6
+  { echo "$as_me:$LINENO: result: $RM" >&5
+echo "${ECHO_T}$RM" >&6; }
 else
-  echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
 fi
 
+
 # Extract the first word of "mv", so it can be a program name with args.
 set dummy mv; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
 if test "${ac_cv_path_MV+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -4523,32 +5153,33 @@
   IFS=$as_save_IFS
   test -z "$as_dir" && as_dir=.
   for ac_exec_ext in '' $ac_executable_extensions; do
-  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; }; then
     ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext"
     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_path_MV" && ac_cv_path_MV="/bin/mv"
   ;;
 esac
 fi
 MV=$ac_cv_path_MV
-
 if test -n "$MV"; then
-  echo "$as_me:$LINENO: result: $MV" >&5
-echo "${ECHO_T}$MV" >&6
+  { echo "$as_me:$LINENO: result: $MV" >&5
+echo "${ECHO_T}$MV" >&6; }
 else
-  echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
 fi
 
+
 # Extract the first word of "tar", so it can be a program name with args.
 set dummy tar; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
 if test "${ac_cv_path_TAR+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -4563,47 +5194,195 @@
   IFS=$as_save_IFS
   test -z "$as_dir" && as_dir=.
   for ac_exec_ext in '' $ac_executable_extensions; do
-  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; }; then
     ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext"
     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_path_TAR" && ac_cv_path_TAR="/bin/tar"
   ;;
 esac
 fi
 TAR=$ac_cv_path_TAR
-
 if test -n "$TAR"; then
-  echo "$as_me:$LINENO: result: $TAR" >&5
-echo "${ECHO_T}$TAR" >&6
+  { echo "$as_me:$LINENO: result: $TAR" >&5
+echo "${ECHO_T}$TAR" >&6; }
 else
-  echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
 fi
 
 
 
-echo "$as_me:$LINENO: checking for egrep" >&5
-echo $ECHO_N "checking for egrep... $ECHO_C" >&6
-if test "${ac_cv_prog_egrep+set}" = set; then
+
+{ 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
-  if echo a | (grep -E '(a|b)') >/dev/null 2>&1
-    then ac_cv_prog_egrep='grep -E'
-    else ac_cv_prog_egrep='egrep'
+  # 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_executable_p "$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
-echo "$as_me:$LINENO: result: $ac_cv_prog_egrep" >&5
-echo "${ECHO_T}$ac_cv_prog_egrep" >&6
- EGREP=$ac_cv_prog_egrep
 
+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
 
-echo "$as_me:$LINENO: checking for ANSI C header files" >&5
-echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
+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_executable_p "$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
@@ -4627,23 +5406,36 @@
 }
 _ACEOF
 rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
-  (eval $ac_compile) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest.$ac_objext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -4652,8 +5444,9 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-ac_cv_header_stdc=no
+	ac_cv_header_stdc=no
 fi
+
 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
 
 if test $ac_cv_header_stdc = yes; then
@@ -4710,6 +5503,7 @@
 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))
@@ -4729,18 +5523,27 @@
   for (i = 0; i < 256; i++)
     if (XOR (islower (i), ISLOWER (i))
 	|| toupper (i) != TOUPPER (i))
-      exit(2);
-  exit (0);
+      return 2;
+  return 0;
 }
 _ACEOF
 rm -f conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
-  (eval $ac_link) 2>&5
+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'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -4753,12 +5556,14 @@
 ( exit $ac_status )
 ac_cv_header_stdc=no
 fi
-rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
+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
+{ 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
@@ -4767,10 +5572,9 @@
 
 fi
 
-# Check whether --enable-shared or --disable-shared was given.
+# Check whether --enable-shared was given.
 if test "${enable_shared+set}" = set; then
-  enableval="$enable_shared"
-  p=${PACKAGE-default}
+  enableval=$enable_shared; p=${PACKAGE-default}
     case $enableval in
     yes) enable_shared=yes ;;
     no) enable_shared=no ;;
@@ -4789,12 +5593,12 @@
     esac
 else
   enable_shared=yes
-fi;
+fi
 
-# Check whether --enable-static or --disable-static was given.
+
+# Check whether --enable-static was given.
 if test "${enable_static+set}" = set; then
-  enableval="$enable_static"
-  p=${PACKAGE-default}
+  enableval=$enable_static; p=${PACKAGE-default}
     case $enableval in
     yes) enable_static=yes ;;
     no) enable_static=no ;;
@@ -4813,12 +5617,12 @@
     esac
 else
   enable_static=yes
-fi;
+fi
 
-# Check whether --enable-fast-install or --disable-fast-install was given.
+
+# Check whether --enable-fast-install was given.
 if test "${enable_fast_install+set}" = set; then
-  enableval="$enable_fast_install"
-  p=${PACKAGE-default}
+  enableval=$enable_fast_install; p=${PACKAGE-default}
     case $enableval in
     yes) enable_fast_install=yes ;;
     no) enable_fast_install=no ;;
@@ -4837,10 +5641,11 @@
     esac
 else
   enable_fast_install=yes
-fi;
+fi
 
-echo "$as_me:$LINENO: checking for a sed that does not truncate output" >&5
-echo $ECHO_N "checking for a sed that does not truncate output... $ECHO_C" >&6
+
+{ echo "$as_me:$LINENO: checking for a sed that does not truncate output" >&5
+echo $ECHO_N "checking for a sed that does not truncate output... $ECHO_C" >&6; }
 if test "${lt_cv_path_SED+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -4893,22 +5698,22 @@
 fi
 
 SED=$lt_cv_path_SED
-echo "$as_me:$LINENO: result: $SED" >&5
-echo "${ECHO_T}$SED" >&6
+{ echo "$as_me:$LINENO: result: $SED" >&5
+echo "${ECHO_T}$SED" >&6; }
 
 
-# Check whether --with-gnu-ld or --without-gnu-ld was given.
+# Check whether --with-gnu-ld was given.
 if test "${with_gnu_ld+set}" = set; then
-  withval="$with_gnu_ld"
-  test "$withval" = no || with_gnu_ld=yes
+  withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
 else
   with_gnu_ld=no
-fi;
+fi
+
 ac_prog=ld
 if test "$GCC" = yes; then
   # Check if gcc -print-prog-name=ld gives a path.
-  echo "$as_me:$LINENO: checking for ld used by $CC" >&5
-echo $ECHO_N "checking for ld used by $CC... $ECHO_C" >&6
+  { echo "$as_me:$LINENO: checking for ld used by $CC" >&5
+echo $ECHO_N "checking for ld used by $CC... $ECHO_C" >&6; }
   case $host in
   *-*-mingw*)
     # gcc leaves a trailing carriage return which upsets mingw
@@ -4937,11 +5742,11 @@
     ;;
   esac
 elif test "$with_gnu_ld" = yes; then
-  echo "$as_me:$LINENO: checking for GNU ld" >&5
-echo $ECHO_N "checking for GNU ld... $ECHO_C" >&6
+  { echo "$as_me:$LINENO: checking for GNU ld" >&5
+echo $ECHO_N "checking for GNU ld... $ECHO_C" >&6; }
 else
-  echo "$as_me:$LINENO: checking for non-GNU ld" >&5
-echo $ECHO_N "checking for non-GNU ld... $ECHO_C" >&6
+  { echo "$as_me:$LINENO: checking for non-GNU ld" >&5
+echo $ECHO_N "checking for non-GNU ld... $ECHO_C" >&6; }
 fi
 if test "${lt_cv_path_LD+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -4974,17 +5779,17 @@
 
 LD="$lt_cv_path_LD"
 if test -n "$LD"; then
-  echo "$as_me:$LINENO: result: $LD" >&5
-echo "${ECHO_T}$LD" >&6
+  { echo "$as_me:$LINENO: result: $LD" >&5
+echo "${ECHO_T}$LD" >&6; }
 else
-  echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
 fi
 test -z "$LD" && { { echo "$as_me:$LINENO: error: no acceptable ld found in \$PATH" >&5
 echo "$as_me: error: no acceptable ld found in \$PATH" >&2;}
    { (exit 1); exit 1; }; }
-echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5
-echo $ECHO_N "checking if the linker ($LD) is GNU ld... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5
+echo $ECHO_N "checking if the linker ($LD) is GNU ld... $ECHO_C" >&6; }
 if test "${lt_cv_prog_gnu_ld+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -4998,20 +5803,20 @@
   ;;
 esac
 fi
-echo "$as_me:$LINENO: result: $lt_cv_prog_gnu_ld" >&5
-echo "${ECHO_T}$lt_cv_prog_gnu_ld" >&6
+{ echo "$as_me:$LINENO: result: $lt_cv_prog_gnu_ld" >&5
+echo "${ECHO_T}$lt_cv_prog_gnu_ld" >&6; }
 with_gnu_ld=$lt_cv_prog_gnu_ld
 
 
-echo "$as_me:$LINENO: checking for $LD option to reload object files" >&5
-echo $ECHO_N "checking for $LD option to reload object files... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for $LD option to reload object files" >&5
+echo $ECHO_N "checking for $LD option to reload object files... $ECHO_C" >&6; }
 if test "${lt_cv_ld_reload_flag+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
   lt_cv_ld_reload_flag='-r'
 fi
-echo "$as_me:$LINENO: result: $lt_cv_ld_reload_flag" >&5
-echo "${ECHO_T}$lt_cv_ld_reload_flag" >&6
+{ echo "$as_me:$LINENO: result: $lt_cv_ld_reload_flag" >&5
+echo "${ECHO_T}$lt_cv_ld_reload_flag" >&6; }
 reload_flag=$lt_cv_ld_reload_flag
 case $reload_flag in
 "" | " "*) ;;
@@ -5028,8 +5833,8 @@
     ;;
 esac
 
-echo "$as_me:$LINENO: checking for BSD-compatible nm" >&5
-echo $ECHO_N "checking for BSD-compatible nm... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for BSD-compatible nm" >&5
+echo $ECHO_N "checking for BSD-compatible nm... $ECHO_C" >&6; }
 if test "${lt_cv_path_NM+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -5077,23 +5882,23 @@
   test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm
 fi
 fi
-echo "$as_me:$LINENO: result: $lt_cv_path_NM" >&5
-echo "${ECHO_T}$lt_cv_path_NM" >&6
+{ echo "$as_me:$LINENO: result: $lt_cv_path_NM" >&5
+echo "${ECHO_T}$lt_cv_path_NM" >&6; }
 NM="$lt_cv_path_NM"
 
-echo "$as_me:$LINENO: checking whether ln -s works" >&5
-echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking whether ln -s works" >&5
+echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6; }
 LN_S=$as_ln_s
 if test "$LN_S" = "ln -s"; then
-  echo "$as_me:$LINENO: result: yes" >&5
-echo "${ECHO_T}yes" >&6
+  { echo "$as_me:$LINENO: result: yes" >&5
+echo "${ECHO_T}yes" >&6; }
 else
-  echo "$as_me:$LINENO: result: no, using $LN_S" >&5
-echo "${ECHO_T}no, using $LN_S" >&6
+  { echo "$as_me:$LINENO: result: no, using $LN_S" >&5
+echo "${ECHO_T}no, using $LN_S" >&6; }
 fi
 
-echo "$as_me:$LINENO: checking how to recognise dependent libraries" >&5
-echo $ECHO_N "checking how to recognise dependent libraries... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking how to recognise dependent libraries" >&5
+echo $ECHO_N "checking how to recognise dependent libraries... $ECHO_C" >&6; }
 if test "${lt_cv_deplibs_check_method+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -5268,8 +6073,8 @@
 esac
 
 fi
-echo "$as_me:$LINENO: result: $lt_cv_deplibs_check_method" >&5
-echo "${ECHO_T}$lt_cv_deplibs_check_method" >&6
+{ echo "$as_me:$LINENO: result: $lt_cv_deplibs_check_method" >&5
+echo "${ECHO_T}$lt_cv_deplibs_check_method" >&6; }
 file_magic_cmd=$lt_cv_file_magic_cmd
 deplibs_check_method=$lt_cv_deplibs_check_method
 test -z "$deplibs_check_method" && deplibs_check_method=unknown
@@ -5286,11 +6091,11 @@
 # Allow CC to be a program name with arguments.
 compiler=$CC
 
-# Check whether --enable-libtool-lock or --disable-libtool-lock was given.
+# Check whether --enable-libtool-lock was given.
 if test "${enable_libtool_lock+set}" = set; then
-  enableval="$enable_libtool_lock"
+  enableval=$enable_libtool_lock;
+fi
 
-fi;
 test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
 
 # Some flags need to be propagated to the compiler or linker for good
@@ -5317,7 +6122,7 @@
   ;;
 *-*-irix6*)
   # Find out which ABI we are using.
-  echo '#line 5320 "configure"' > conftest.$ac_ext
+  echo '#line 6125 "configure"' > conftest.$ac_ext
   if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
   (eval $ac_compile) 2>&5
   ac_status=$?
@@ -5402,8 +6207,8 @@
   # On SCO OpenServer 5, we need -belf to get full-featured binaries.
   SAVE_CFLAGS="$CFLAGS"
   CFLAGS="$CFLAGS -belf"
-  echo "$as_me:$LINENO: checking whether the C compiler needs -belf" >&5
-echo $ECHO_N "checking whether the C compiler needs -belf... $ECHO_C" >&6
+  { echo "$as_me:$LINENO: checking whether the C compiler needs -belf" >&5
+echo $ECHO_N "checking whether the C compiler needs -belf... $ECHO_C" >&6; }
 if test "${lt_cv_cc_needs_belf+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -5429,23 +6234,36 @@
 }
 _ACEOF
 rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
-  (eval $ac_link) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest$ac_exeext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -5454,8 +6272,9 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-lt_cv_cc_needs_belf=no
+	lt_cv_cc_needs_belf=no
 fi
+
 rm -f conftest.err conftest.$ac_objext \
       conftest$ac_exeext conftest.$ac_ext
      ac_ext=c
@@ -5465,8 +6284,8 @@
 ac_compiler_gnu=$ac_cv_c_compiler_gnu
 
 fi
-echo "$as_me:$LINENO: result: $lt_cv_cc_needs_belf" >&5
-echo "${ECHO_T}$lt_cv_cc_needs_belf" >&6
+{ echo "$as_me:$LINENO: result: $lt_cv_cc_needs_belf" >&5
+echo "${ECHO_T}$lt_cv_cc_needs_belf" >&6; }
   if test x"$lt_cv_cc_needs_belf" != x"yes"; then
     # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
     CFLAGS="$SAVE_CFLAGS"
@@ -5512,9 +6331,9 @@
 		  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 eval "test \"\${$as_ac_Header+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
 else
   cat >conftest.$ac_ext <<_ACEOF
@@ -5528,23 +6347,36 @@
 #include <$ac_header>
 _ACEOF
 rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
-  (eval $ac_compile) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest.$ac_objext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -5553,12 +6385,14 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-eval "$as_ac_Header=no"
+	eval "$as_ac_Header=no"
 fi
+
 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
 fi
-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
+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
@@ -5573,18 +6407,19 @@
 for ac_header in dlfcn.h
 do
 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
-if eval "test \"\${$as_ac_Header+set}\" = set"; then
-  echo "$as_me:$LINENO: checking for $ac_header" >&5
-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
-if eval "test \"\${$as_ac_Header+set}\" = set"; then
+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
-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
+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
+{ 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
@@ -5595,23 +6430,36 @@
 #include <$ac_header>
 _ACEOF
 rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
-  (eval $ac_compile) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest.$ac_objext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -5620,15 +6468,16 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-ac_header_compiler=no
+	ac_header_compiler=no
 fi
+
 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
-echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
-echo "${ECHO_T}$ac_header_compiler" >&6
+{ 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
+{ 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
@@ -5637,8 +6486,13 @@
 /* end confdefs.h.  */
 #include <$ac_header>
 _ACEOF
-if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
-  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+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
@@ -5662,9 +6516,10 @@
 
   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
+{ 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
@@ -5688,25 +6543,19 @@
 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;}
-    (
-      cat <<\_ASBOX
-## ------------------------------------------ ##
-## Report this to the AC_PACKAGE_NAME lists.  ##
-## ------------------------------------------ ##
-_ASBOX
-    ) |
-      sed "s/^/$as_me: WARNING:     /" >&2
+
     ;;
 esac
-echo "$as_me:$LINENO: checking for $ac_header" >&5
-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
-if eval "test \"\${$as_ac_Header+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
 else
   eval "$as_ac_Header=\$ac_header_preproc"
 fi
-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
+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
@@ -5718,18 +6567,22 @@
 
 done
 
-ac_ext=cc
+ac_ext=cpp
 ac_cpp='$CXXCPP $CPPFLAGS'
 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
-if test -n "$ac_tool_prefix"; then
-  for ac_prog in $CCC g++ c++ gpp aCC CC cxx cc++ cl FCC KCC RCC xlC_r xlC
+if test -z "$CXX"; then
+  if test -n "$CCC"; then
+    CXX=$CCC
+  else
+    if test -n "$ac_tool_prefix"; then
+  for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
   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
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
 if test "${ac_cv_prog_CXX+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -5742,36 +6595,38 @@
   IFS=$as_save_IFS
   test -z "$as_dir" && as_dir=.
   for ac_exec_ext in '' $ac_executable_extensions; do
-  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; }; then
     ac_cv_prog_CXX="$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
 CXX=$ac_cv_prog_CXX
 if test -n "$CXX"; then
-  echo "$as_me:$LINENO: result: $CXX" >&5
-echo "${ECHO_T}$CXX" >&6
+  { echo "$as_me:$LINENO: result: $CXX" >&5
+echo "${ECHO_T}$CXX" >&6; }
 else
-  echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
 fi
 
+
     test -n "$CXX" && break
   done
 fi
 if test -z "$CXX"; then
   ac_ct_CXX=$CXX
-  for ac_prog in $CCC g++ c++ gpp aCC CC cxx cc++ cl FCC KCC RCC xlC_r xlC
+  for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
 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
+{ 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_CXX+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -5784,55 +6639,85 @@
   IFS=$as_save_IFS
   test -z "$as_dir" && as_dir=.
   for ac_exec_ext in '' $ac_executable_extensions; do
-  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; }; then
     ac_cv_prog_ac_ct_CXX="$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_CXX=$ac_cv_prog_ac_ct_CXX
 if test -n "$ac_ct_CXX"; then
-  echo "$as_me:$LINENO: result: $ac_ct_CXX" >&5
-echo "${ECHO_T}$ac_ct_CXX" >&6
+  { echo "$as_me:$LINENO: result: $ac_ct_CXX" >&5
+echo "${ECHO_T}$ac_ct_CXX" >&6; }
 else
-  echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
 fi
 
+
   test -n "$ac_ct_CXX" && break
 done
-test -n "$ac_ct_CXX" || ac_ct_CXX="g++"
 
-  CXX=$ac_ct_CXX
+  if test "x$ac_ct_CXX" = x; then
+    CXX="g++"
+  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
+    CXX=$ac_ct_CXX
+  fi
 fi
 
-
+  fi
+fi
 # Provide some information about the compiler.
-echo "$as_me:$LINENO:" \
-     "checking for C++ compiler version" >&5
+echo "$as_me:$LINENO: checking for C++ compiler version" >&5
 ac_compiler=`set X $ac_compile; echo $2`
-{ (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
-  (eval $ac_compiler --version </dev/null >&5) 2>&5
+{ (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); }
-{ (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
-  (eval $ac_compiler -v </dev/null >&5) 2>&5
+{ (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); }
-{ (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
-  (eval $ac_compiler -V </dev/null >&5) 2>&5
+{ (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); }
 
-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
+{ 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_cxx_compiler_gnu+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -5855,23 +6740,36 @@
 }
 _ACEOF
 rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
-  (eval $ac_compile) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_cxx_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest.$ac_objext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -5880,24 +6778,28 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-ac_compiler_gnu=no
+	ac_compiler_gnu=no
 fi
+
 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
 ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
 
 fi
-echo "$as_me:$LINENO: result: $ac_cv_cxx_compiler_gnu" >&5
-echo "${ECHO_T}$ac_cv_cxx_compiler_gnu" >&6
+{ echo "$as_me:$LINENO: result: $ac_cv_cxx_compiler_gnu" >&5
+echo "${ECHO_T}$ac_cv_cxx_compiler_gnu" >&6; }
 GXX=`test $ac_compiler_gnu = yes && echo yes`
 ac_test_CXXFLAGS=${CXXFLAGS+set}
 ac_save_CXXFLAGS=$CXXFLAGS
-CXXFLAGS="-g"
-echo "$as_me:$LINENO: checking whether $CXX accepts -g" >&5
-echo $ECHO_N "checking whether $CXX accepts -g... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking whether $CXX accepts -g" >&5
+echo $ECHO_N "checking whether $CXX accepts -g... $ECHO_C" >&6; }
 if test "${ac_cv_prog_cxx_g+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  cat >conftest.$ac_ext <<_ACEOF
+  ac_save_cxx_werror_flag=$ac_cxx_werror_flag
+   ac_cxx_werror_flag=yes
+   ac_cv_prog_cxx_g=no
+   CXXFLAGS="-g"
+   cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
@@ -5913,23 +6815,36 @@
 }
 _ACEOF
 rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
-  (eval $ac_compile) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_cxx_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest.$ac_objext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -5938,69 +6853,53 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-ac_cv_prog_cxx_g=no
-fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-echo "$as_me:$LINENO: result: $ac_cv_prog_cxx_g" >&5
-echo "${ECHO_T}$ac_cv_prog_cxx_g" >&6
-if test "$ac_test_CXXFLAGS" = set; then
-  CXXFLAGS=$ac_save_CXXFLAGS
-elif test $ac_cv_prog_cxx_g = yes; then
-  if test "$GXX" = yes; then
-    CXXFLAGS="-g -O2"
-  else
-    CXXFLAGS="-g"
-  fi
-else
-  if test "$GXX" = yes; then
-    CXXFLAGS="-O2"
-  else
-    CXXFLAGS=
-  fi
-fi
-for ac_declaration in \
-   '' \
-   'extern "C" void std::exit (int) throw (); using std::exit;' \
-   'extern "C" void std::exit (int); using std::exit;' \
-   'extern "C" void exit (int) throw ();' \
-   'extern "C" void exit (int);' \
-   'void exit (int);'
-do
-  cat >conftest.$ac_ext <<_ACEOF
+	CXXFLAGS=""
+      cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
-$ac_declaration
-#include <stdlib.h>
+
 int
 main ()
 {
-exit (42);
+
   ;
   return 0;
 }
 _ACEOF
 rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
-  (eval $ac_compile) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_cxx_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest.$ac_objext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -6009,61 +6908,92 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-continue
-fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
-  cat >conftest.$ac_ext <<_ACEOF
+	ac_cxx_werror_flag=$ac_save_cxx_werror_flag
+	 CXXFLAGS="-g"
+	 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
-$ac_declaration
+
 int
 main ()
 {
-exit (42);
+
   ;
   return 0;
 }
 _ACEOF
 rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
-  (eval $ac_compile) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_cxx_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest.$ac_objext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
-  break
+  ac_cv_prog_cxx_g=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
+
 fi
+
 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
-done
-rm -f conftest*
-if test -n "$ac_declaration"; then
-  echo '#ifdef __cplusplus' >>confdefs.h
-  echo $ac_declaration      >>confdefs.h
-  echo '#endif'             >>confdefs.h
 fi
 
-ac_ext=cc
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+fi
+
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+   ac_cxx_werror_flag=$ac_save_cxx_werror_flag
+fi
+{ echo "$as_me:$LINENO: result: $ac_cv_prog_cxx_g" >&5
+echo "${ECHO_T}$ac_cv_prog_cxx_g" >&6; }
+if test "$ac_test_CXXFLAGS" = set; then
+  CXXFLAGS=$ac_save_CXXFLAGS
+elif test $ac_cv_prog_cxx_g = yes; then
+  if test "$GXX" = yes; then
+    CXXFLAGS="-g -O2"
+  else
+    CXXFLAGS="-g"
+  fi
+else
+  if test "$GXX" = yes; then
+    CXXFLAGS="-O2"
+  else
+    CXXFLAGS=
+  fi
+fi
+ac_ext=cpp
 ac_cpp='$CXXCPP $CPPFLAGS'
 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
@@ -6071,8 +7001,8 @@
 
 depcc="$CXX"  am_compiler_list=
 
-echo "$as_me:$LINENO: checking dependency style of $depcc" >&5
-echo $ECHO_N "checking dependency style of $depcc... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking dependency style of $depcc" >&5
+echo $ECHO_N "checking dependency style of $depcc... $ECHO_C" >&6; }
 if test "${am_cv_CXX_dependencies_compiler_type+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -6161,8 +7091,8 @@
 fi
 
 fi
-echo "$as_me:$LINENO: result: $am_cv_CXX_dependencies_compiler_type" >&5
-echo "${ECHO_T}$am_cv_CXX_dependencies_compiler_type" >&6
+{ echo "$as_me:$LINENO: result: $am_cv_CXX_dependencies_compiler_type" >&5
+echo "${ECHO_T}$am_cv_CXX_dependencies_compiler_type" >&6; }
 CXXDEPMODE=depmode=$am_cv_CXX_dependencies_compiler_type
 
 
@@ -6183,13 +7113,13 @@
 if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
     ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
     (test "X$CXX" != "Xg++"))) ; then
-  ac_ext=cc
+  ac_ext=cpp
 ac_cpp='$CXXCPP $CPPFLAGS'
 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
 ac_compiler_gnu=$ac_cv_cxx_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
+{ 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; }
 if test -z "$CXXCPP"; then
   if test "${ac_cv_prog_CXXCPP+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -6219,8 +7149,13 @@
 #endif
 		     Syntax error
 _ACEOF
-if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
-  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+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
@@ -6245,9 +7180,10 @@
   # Broken: fails on valid input.
 continue
 fi
+
 rm -f conftest.err conftest.$ac_ext
 
-  # OK, works on sane cases.  Now check whether non-existent headers
+  # OK, works on sane cases.  Now check whether nonexistent headers
   # can be detected and how.
   cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
@@ -6257,8 +7193,13 @@
 /* end confdefs.h.  */
 #include <ac_nonexistent.h>
 _ACEOF
-if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
-  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+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
@@ -6285,6 +7226,7 @@
 ac_preproc_ok=:
 break
 fi
+
 rm -f conftest.err conftest.$ac_ext
 
 done
@@ -6302,8 +7244,8 @@
 else
   ac_cv_prog_CXXCPP=$CXXCPP
 fi
-echo "$as_me:$LINENO: result: $CXXCPP" >&5
-echo "${ECHO_T}$CXXCPP" >&6
+{ echo "$as_me:$LINENO: result: $CXXCPP" >&5
+echo "${ECHO_T}$CXXCPP" >&6; }
 ac_preproc_ok=false
 for ac_cxx_preproc_warn_flag in '' yes
 do
@@ -6326,8 +7268,13 @@
 #endif
 		     Syntax error
 _ACEOF
-if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
-  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+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
@@ -6352,9 +7299,10 @@
   # Broken: fails on valid input.
 continue
 fi
+
 rm -f conftest.err conftest.$ac_ext
 
-  # OK, works on sane cases.  Now check whether non-existent headers
+  # OK, works on sane cases.  Now check whether nonexistent headers
   # can be detected and how.
   cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
@@ -6364,8 +7312,13 @@
 /* end confdefs.h.  */
 #include <ac_nonexistent.h>
 _ACEOF
-if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
-  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+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
@@ -6392,6 +7345,7 @@
 ac_preproc_ok=:
 break
 fi
+
 rm -f conftest.err conftest.$ac_ext
 
 done
@@ -6407,7 +7361,7 @@
    { (exit 1); exit 1; }; }
 fi
 
-ac_ext=cc
+ac_ext=cpp
 ac_cpp='$CXXCPP $CPPFLAGS'
 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
@@ -6421,12 +7375,12 @@
 ac_link='$F77 -o conftest$ac_exeext $FFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
 ac_compiler_gnu=$ac_cv_f77_compiler_gnu
 if test -n "$ac_tool_prefix"; then
-  for ac_prog in g77 f77 xlf frt pgf77 fort77 fl32 af77 f90 xlf90 pgf90 epcf90 f95 fort xlf95 ifc efc pgf95 lf95 gfortran
+  for ac_prog in g77 f77 xlf frt pgf77 cf77 fort77 fl32 af77 f90 xlf90 pgf90 pghpf epcf90 gfortran g95 f95 fort xlf95 ifort ifc efc pgf95 lf95 ftn
   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
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
 if test "${ac_cv_prog_F77+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -6439,36 +7393,38 @@
   IFS=$as_save_IFS
   test -z "$as_dir" && as_dir=.
   for ac_exec_ext in '' $ac_executable_extensions; do
-  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; }; then
     ac_cv_prog_F77="$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
 F77=$ac_cv_prog_F77
 if test -n "$F77"; then
-  echo "$as_me:$LINENO: result: $F77" >&5
-echo "${ECHO_T}$F77" >&6
+  { echo "$as_me:$LINENO: result: $F77" >&5
+echo "${ECHO_T}$F77" >&6; }
 else
-  echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
 fi
 
+
     test -n "$F77" && break
   done
 fi
 if test -z "$F77"; then
   ac_ct_F77=$F77
-  for ac_prog in g77 f77 xlf frt pgf77 fort77 fl32 af77 f90 xlf90 pgf90 epcf90 f95 fort xlf95 ifc efc pgf95 lf95 gfortran
+  for ac_prog in g77 f77 xlf frt pgf77 cf77 fort77 fl32 af77 f90 xlf90 pgf90 pghpf epcf90 gfortran g95 f95 fort xlf95 ifort ifc efc pgf95 lf95 ftn
 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
+{ 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_F77+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -6481,48 +7437,78 @@
   IFS=$as_save_IFS
   test -z "$as_dir" && as_dir=.
   for ac_exec_ext in '' $ac_executable_extensions; do
-  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; }; then
     ac_cv_prog_ac_ct_F77="$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_F77=$ac_cv_prog_ac_ct_F77
 if test -n "$ac_ct_F77"; then
-  echo "$as_me:$LINENO: result: $ac_ct_F77" >&5
-echo "${ECHO_T}$ac_ct_F77" >&6
+  { echo "$as_me:$LINENO: result: $ac_ct_F77" >&5
+echo "${ECHO_T}$ac_ct_F77" >&6; }
 else
-  echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
 fi
 
+
   test -n "$ac_ct_F77" && break
 done
 
-  F77=$ac_ct_F77
+  if test "x$ac_ct_F77" = x; then
+    F77=""
+  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
+    F77=$ac_ct_F77
+  fi
 fi
 
 
 # Provide some information about the compiler.
-echo "$as_me:6511:" \
-     "checking for Fortran 77 compiler version" >&5
+echo "$as_me:$LINENO: checking for Fortran 77 compiler version" >&5
 ac_compiler=`set X $ac_compile; echo $2`
-{ (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
-  (eval $ac_compiler --version </dev/null >&5) 2>&5
+{ (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); }
-{ (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
-  (eval $ac_compiler -v </dev/null >&5) 2>&5
+{ (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); }
-{ (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
-  (eval $ac_compiler -V </dev/null >&5) 2>&5
+{ (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); }
@@ -6532,8 +7518,8 @@
 # input file.  (Note that this only needs to work for GNU compilers.)
 ac_save_ext=$ac_ext
 ac_ext=F
-echo "$as_me:$LINENO: checking whether we are using the GNU Fortran 77 compiler" >&5
-echo $ECHO_N "checking whether we are using the GNU Fortran 77 compiler... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking whether we are using the GNU Fortran 77 compiler" >&5
+echo $ECHO_N "checking whether we are using the GNU Fortran 77 compiler... $ECHO_C" >&6; }
 if test "${ac_cv_f77_compiler_gnu+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -6546,23 +7532,36 @@
       end
 _ACEOF
 rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
-  (eval $ac_compile) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_f77_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_f77_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest.$ac_objext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -6571,20 +7570,21 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-ac_compiler_gnu=no
+	ac_compiler_gnu=no
 fi
+
 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
 ac_cv_f77_compiler_gnu=$ac_compiler_gnu
 
 fi
-echo "$as_me:$LINENO: result: $ac_cv_f77_compiler_gnu" >&5
-echo "${ECHO_T}$ac_cv_f77_compiler_gnu" >&6
+{ echo "$as_me:$LINENO: result: $ac_cv_f77_compiler_gnu" >&5
+echo "${ECHO_T}$ac_cv_f77_compiler_gnu" >&6; }
 ac_ext=$ac_save_ext
 ac_test_FFLAGS=${FFLAGS+set}
 ac_save_FFLAGS=$FFLAGS
 FFLAGS=
-echo "$as_me:$LINENO: checking whether $F77 accepts -g" >&5
-echo $ECHO_N "checking whether $F77 accepts -g... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking whether $F77 accepts -g" >&5
+echo $ECHO_N "checking whether $F77 accepts -g... $ECHO_C" >&6; }
 if test "${ac_cv_prog_f77_g+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -6595,23 +7595,36 @@
       end
 _ACEOF
 rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
-  (eval $ac_compile) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_f77_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_f77_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest.$ac_objext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -6620,13 +7633,14 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-ac_cv_prog_f77_g=no
+	ac_cv_prog_f77_g=no
 fi
+
 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
 
 fi
-echo "$as_me:$LINENO: result: $ac_cv_prog_f77_g" >&5
-echo "${ECHO_T}$ac_cv_prog_f77_g" >&6
+{ echo "$as_me:$LINENO: result: $ac_cv_prog_f77_g" >&5
+echo "${ECHO_T}$ac_cv_prog_f77_g" >&6; }
 if test "$ac_test_FFLAGS" = set; then
   FFLAGS=$ac_save_FFLAGS
 elif test $ac_cv_prog_f77_g = yes; then
@@ -6655,8 +7669,8 @@
 # Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers!
 
 # find the maximum length of command line arguments
-echo "$as_me:$LINENO: checking the maximum length of command line arguments" >&5
-echo $ECHO_N "checking the maximum length of command line arguments... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking the maximum length of command line arguments" >&5
+echo $ECHO_N "checking the maximum length of command line arguments... $ECHO_C" >&6; }
 if test "${lt_cv_sys_max_cmd_len+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -6764,19 +7778,19 @@
 fi
 
 if test -n $lt_cv_sys_max_cmd_len ; then
-  echo "$as_me:$LINENO: result: $lt_cv_sys_max_cmd_len" >&5
-echo "${ECHO_T}$lt_cv_sys_max_cmd_len" >&6
+  { echo "$as_me:$LINENO: result: $lt_cv_sys_max_cmd_len" >&5
+echo "${ECHO_T}$lt_cv_sys_max_cmd_len" >&6; }
 else
-  echo "$as_me:$LINENO: result: none" >&5
-echo "${ECHO_T}none" >&6
+  { echo "$as_me:$LINENO: result: none" >&5
+echo "${ECHO_T}none" >&6; }
 fi
 
 
 
 
 # Check for command to grab the raw symbol name followed by C symbol from nm.
-echo "$as_me:$LINENO: checking command to parse $NM output from $compiler object" >&5
-echo $ECHO_N "checking command to parse $NM output from $compiler object... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking command to parse $NM output from $compiler object" >&5
+echo $ECHO_N "checking command to parse $NM output from $compiler object... $ECHO_C" >&6; }
 if test "${lt_cv_sys_global_symbol_pipe+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -6980,15 +7994,15 @@
   lt_cv_sys_global_symbol_to_cdecl=
 fi
 if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
-  echo "$as_me:$LINENO: result: failed" >&5
-echo "${ECHO_T}failed" >&6
+  { echo "$as_me:$LINENO: result: failed" >&5
+echo "${ECHO_T}failed" >&6; }
 else
-  echo "$as_me:$LINENO: result: ok" >&5
-echo "${ECHO_T}ok" >&6
+  { echo "$as_me:$LINENO: result: ok" >&5
+echo "${ECHO_T}ok" >&6; }
 fi
 
-echo "$as_me:$LINENO: checking for objdir" >&5
-echo $ECHO_N "checking for objdir... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for objdir" >&5
+echo $ECHO_N "checking for objdir... $ECHO_C" >&6; }
 if test "${lt_cv_objdir+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -7002,8 +8016,8 @@
 fi
 rmdir .libs 2>/dev/null
 fi
-echo "$as_me:$LINENO: result: $lt_cv_objdir" >&5
-echo "${ECHO_T}$lt_cv_objdir" >&6
+{ echo "$as_me:$LINENO: result: $lt_cv_objdir" >&5
+echo "${ECHO_T}$lt_cv_objdir" >&6; }
 objdir=$lt_cv_objdir
 
 
@@ -7054,8 +8068,8 @@
 if test -n "$ac_tool_prefix"; then
   # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
 set dummy ${ac_tool_prefix}ar; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+{ 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
@@ -7068,32 +8082,34 @@
   IFS=$as_save_IFS
   test -z "$as_dir" && as_dir=.
   for ac_exec_ext in '' $ac_executable_extensions; do
-  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; }; then
     ac_cv_prog_AR="${ac_tool_prefix}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
+  { 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
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
 fi
 
+
 fi
 if test -z "$ac_cv_prog_AR"; then
   ac_ct_AR=$AR
   # 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
+{ 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_AR+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -7106,27 +8122,41 @@
   IFS=$as_save_IFS
   test -z "$as_dir" && as_dir=.
   for ac_exec_ext in '' $ac_executable_extensions; do
-  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; }; then
     ac_cv_prog_ac_ct_AR="ar"
     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_ac_ct_AR" && ac_cv_prog_ac_ct_AR="false"
 fi
 fi
 ac_ct_AR=$ac_cv_prog_ac_ct_AR
 if test -n "$ac_ct_AR"; then
-  echo "$as_me:$LINENO: result: $ac_ct_AR" >&5
-echo "${ECHO_T}$ac_ct_AR" >&6
+  { echo "$as_me:$LINENO: result: $ac_ct_AR" >&5
+echo "${ECHO_T}$ac_ct_AR" >&6; }
 else
-  echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
 fi
 
-  AR=$ac_ct_AR
+  if test "x$ac_ct_AR" = x; then
+    AR="false"
+  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
+    AR=$ac_ct_AR
+  fi
 else
   AR="$ac_cv_prog_AR"
 fi
@@ -7134,8 +8164,8 @@
 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
+{ 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
@@ -7148,32 +8178,34 @@
   IFS=$as_save_IFS
   test -z "$as_dir" && as_dir=.
   for ac_exec_ext in '' $ac_executable_extensions; do
-  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_executable_p "$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
+  { 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
+  { 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
+{ 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
@@ -7186,27 +8218,41 @@
   IFS=$as_save_IFS
   test -z "$as_dir" && as_dir=.
   for ac_exec_ext in '' $ac_executable_extensions; do
-  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_executable_p "$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
 
-  test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB=":"
 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
+  { 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
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
 fi
 
-  RANLIB=$ac_ct_RANLIB
+  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
@@ -7214,8 +8260,8 @@
 if test -n "$ac_tool_prefix"; then
   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
 set dummy ${ac_tool_prefix}strip; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
 if test "${ac_cv_prog_STRIP+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -7228,32 +8274,34 @@
   IFS=$as_save_IFS
   test -z "$as_dir" && as_dir=.
   for ac_exec_ext in '' $ac_executable_extensions; do
-  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; }; then
     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
     break 2
   fi
 done
 done
+IFS=$as_save_IFS
 
 fi
 fi
 STRIP=$ac_cv_prog_STRIP
 if test -n "$STRIP"; then
-  echo "$as_me:$LINENO: result: $STRIP" >&5
-echo "${ECHO_T}$STRIP" >&6
+  { echo "$as_me:$LINENO: result: $STRIP" >&5
+echo "${ECHO_T}$STRIP" >&6; }
 else
-  echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
 fi
 
+
 fi
 if test -z "$ac_cv_prog_STRIP"; then
   ac_ct_STRIP=$STRIP
   # Extract the first word of "strip", so it can be a program name with args.
 set dummy strip; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+{ 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_STRIP+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -7266,27 +8314,41 @@
   IFS=$as_save_IFS
   test -z "$as_dir" && as_dir=.
   for ac_exec_ext in '' $ac_executable_extensions; do
-  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; }; then
     ac_cv_prog_ac_ct_STRIP="strip"
     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_ac_ct_STRIP" && ac_cv_prog_ac_ct_STRIP=":"
 fi
 fi
 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
 if test -n "$ac_ct_STRIP"; then
-  echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
-echo "${ECHO_T}$ac_ct_STRIP" >&6
+  { echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
+echo "${ECHO_T}$ac_ct_STRIP" >&6; }
 else
-  echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
 fi
 
-  STRIP=$ac_ct_STRIP
+  if test "x$ac_ct_STRIP" = x; then
+    STRIP=":"
+  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
+    STRIP=$ac_ct_STRIP
+  fi
 else
   STRIP="$ac_cv_prog_STRIP"
 fi
@@ -7345,8 +8407,8 @@
 case $deplibs_check_method in
 file_magic*)
   if test "$file_magic_cmd" = '$MAGIC_CMD'; then
-    echo "$as_me:$LINENO: checking for ${ac_tool_prefix}file" >&5
-echo $ECHO_N "checking for ${ac_tool_prefix}file... $ECHO_C" >&6
+    { echo "$as_me:$LINENO: checking for ${ac_tool_prefix}file" >&5
+echo $ECHO_N "checking for ${ac_tool_prefix}file... $ECHO_C" >&6; }
 if test "${lt_cv_path_MAGIC_CMD+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -7398,17 +8460,17 @@
 
 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
 if test -n "$MAGIC_CMD"; then
-  echo "$as_me:$LINENO: result: $MAGIC_CMD" >&5
-echo "${ECHO_T}$MAGIC_CMD" >&6
+  { echo "$as_me:$LINENO: result: $MAGIC_CMD" >&5
+echo "${ECHO_T}$MAGIC_CMD" >&6; }
 else
-  echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
 fi
 
 if test -z "$lt_cv_path_MAGIC_CMD"; then
   if test -n "$ac_tool_prefix"; then
-    echo "$as_me:$LINENO: checking for file" >&5
-echo $ECHO_N "checking for file... $ECHO_C" >&6
+    { echo "$as_me:$LINENO: checking for file" >&5
+echo $ECHO_N "checking for file... $ECHO_C" >&6; }
 if test "${lt_cv_path_MAGIC_CMD+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -7460,11 +8522,11 @@
 
 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
 if test -n "$MAGIC_CMD"; then
-  echo "$as_me:$LINENO: result: $MAGIC_CMD" >&5
-echo "${ECHO_T}$MAGIC_CMD" >&6
+  { echo "$as_me:$LINENO: result: $MAGIC_CMD" >&5
+echo "${ECHO_T}$MAGIC_CMD" >&6; }
 else
-  echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
 fi
 
   else
@@ -7479,21 +8541,21 @@
 enable_dlopen=no
 enable_win32_dll=no
 
-# Check whether --enable-libtool-lock or --disable-libtool-lock was given.
+# Check whether --enable-libtool-lock was given.
 if test "${enable_libtool_lock+set}" = set; then
-  enableval="$enable_libtool_lock"
+  enableval=$enable_libtool_lock;
+fi
 
-fi;
 test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
 
 
-# Check whether --with-pic or --without-pic was given.
+# Check whether --with-pic was given.
 if test "${with_pic+set}" = set; then
-  withval="$with_pic"
-  pic_mode="$withval"
+  withval=$with_pic; pic_mode="$withval"
 else
   pic_mode=default
-fi;
+fi
+
 test -z "$pic_mode" && pic_mode=default
 
 # Use C for the default configuration in the libtool script
@@ -7551,8 +8613,8 @@
   lt_prog_compiler_no_builtin_flag=' -fno-builtin'
 
 
-echo "$as_me:$LINENO: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
-echo $ECHO_N "checking if $compiler supports -fno-rtti -fno-exceptions... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
+echo $ECHO_N "checking if $compiler supports -fno-rtti -fno-exceptions... $ECHO_C" >&6; }
 if test "${lt_cv_prog_compiler_rtti_exceptions+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -7569,11 +8631,11 @@
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:7572: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:8634: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>conftest.err)
    ac_status=$?
    cat conftest.err >&5
-   echo "$as_me:7576: \$? = $ac_status" >&5
+   echo "$as_me:8638: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s "$ac_outfile"; then
      # The compiler can only warn and ignore the option if not recognized
      # So say no if there are warnings other than the usual output.
@@ -7586,8 +8648,8 @@
    $rm conftest*
 
 fi
-echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_rtti_exceptions" >&5
-echo "${ECHO_T}$lt_cv_prog_compiler_rtti_exceptions" >&6
+{ echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_rtti_exceptions" >&5
+echo "${ECHO_T}$lt_cv_prog_compiler_rtti_exceptions" >&6; }
 
 if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then
     lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions"
@@ -7601,8 +8663,8 @@
 lt_prog_compiler_pic=
 lt_prog_compiler_static=
 
-echo "$as_me:$LINENO: checking for $compiler option to produce PIC" >&5
-echo $ECHO_N "checking for $compiler option to produce PIC... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for $compiler option to produce PIC" >&5
+echo $ECHO_N "checking for $compiler option to produce PIC... $ECHO_C" >&6; }
 
   if test "$GCC" = yes; then
     lt_prog_compiler_wl='-Wl,'
@@ -7811,16 +8873,16 @@
     esac
   fi
 
-echo "$as_me:$LINENO: result: $lt_prog_compiler_pic" >&5
-echo "${ECHO_T}$lt_prog_compiler_pic" >&6
+{ echo "$as_me:$LINENO: result: $lt_prog_compiler_pic" >&5
+echo "${ECHO_T}$lt_prog_compiler_pic" >&6; }
 
 #
 # Check to make sure the PIC flag actually works.
 #
 if test -n "$lt_prog_compiler_pic"; then
 
-echo "$as_me:$LINENO: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5
-echo $ECHO_N "checking if $compiler PIC flag $lt_prog_compiler_pic works... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5
+echo $ECHO_N "checking if $compiler PIC flag $lt_prog_compiler_pic works... $ECHO_C" >&6; }
 if test "${lt_prog_compiler_pic_works+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -7837,11 +8899,11 @@
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:7840: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:8902: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>conftest.err)
    ac_status=$?
    cat conftest.err >&5
-   echo "$as_me:7844: \$? = $ac_status" >&5
+   echo "$as_me:8906: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s "$ac_outfile"; then
      # The compiler can only warn and ignore the option if not recognized
      # So say no if there are warnings other than the usual output.
@@ -7854,8 +8916,8 @@
    $rm conftest*
 
 fi
-echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_works" >&5
-echo "${ECHO_T}$lt_prog_compiler_pic_works" >&6
+{ echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_works" >&5
+echo "${ECHO_T}$lt_prog_compiler_pic_works" >&6; }
 
 if test x"$lt_prog_compiler_pic_works" = xyes; then
     case $lt_prog_compiler_pic in
@@ -7882,8 +8944,8 @@
 # Check to make sure the static flag actually works.
 #
 wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\"
-echo "$as_me:$LINENO: checking if $compiler static flag $lt_tmp_static_flag works" >&5
-echo $ECHO_N "checking if $compiler static flag $lt_tmp_static_flag works... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking if $compiler static flag $lt_tmp_static_flag works" >&5
+echo $ECHO_N "checking if $compiler static flag $lt_tmp_static_flag works... $ECHO_C" >&6; }
 if test "${lt_prog_compiler_static_works+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -7910,8 +8972,8 @@
    LDFLAGS="$save_LDFLAGS"
 
 fi
-echo "$as_me:$LINENO: result: $lt_prog_compiler_static_works" >&5
-echo "${ECHO_T}$lt_prog_compiler_static_works" >&6
+{ echo "$as_me:$LINENO: result: $lt_prog_compiler_static_works" >&5
+echo "${ECHO_T}$lt_prog_compiler_static_works" >&6; }
 
 if test x"$lt_prog_compiler_static_works" = xyes; then
     :
@@ -7920,8 +8982,8 @@
 fi
 
 
-echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5
-echo $ECHO_N "checking if $compiler supports -c -o file.$ac_objext... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5
+echo $ECHO_N "checking if $compiler supports -c -o file.$ac_objext... $ECHO_C" >&6; }
 if test "${lt_cv_prog_compiler_c_o+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -7941,11 +9003,11 @@
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:7944: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:9006: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>out/conftest.err)
    ac_status=$?
    cat out/conftest.err >&5
-   echo "$as_me:7948: \$? = $ac_status" >&5
+   echo "$as_me:9010: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s out/conftest2.$ac_objext
    then
      # The compiler can only warn and ignore the option if not recognized
@@ -7967,23 +9029,23 @@
    $rm conftest*
 
 fi
-echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o" >&5
-echo "${ECHO_T}$lt_cv_prog_compiler_c_o" >&6
+{ echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o" >&5
+echo "${ECHO_T}$lt_cv_prog_compiler_c_o" >&6; }
 
 
 hard_links="nottested"
 if test "$lt_cv_prog_compiler_c_o" = no && test "$need_locks" != no; then
   # do not overwrite the value of need_locks provided by the user
-  echo "$as_me:$LINENO: checking if we can lock with hard links" >&5
-echo $ECHO_N "checking if we can lock with hard links... $ECHO_C" >&6
+  { echo "$as_me:$LINENO: checking if we can lock with hard links" >&5
+echo $ECHO_N "checking if we can lock with hard links... $ECHO_C" >&6; }
   hard_links=yes
   $rm conftest*
   ln conftest.a conftest.b 2>/dev/null && hard_links=no
   touch conftest.a
   ln conftest.a conftest.b 2>&5 || hard_links=no
   ln conftest.a conftest.b 2>/dev/null && hard_links=no
-  echo "$as_me:$LINENO: result: $hard_links" >&5
-echo "${ECHO_T}$hard_links" >&6
+  { echo "$as_me:$LINENO: result: $hard_links" >&5
+echo "${ECHO_T}$hard_links" >&6; }
   if test "$hard_links" = no; then
     { echo "$as_me:$LINENO: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5
 echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;}
@@ -7993,8 +9055,8 @@
   need_locks=no
 fi
 
-echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5
-echo $ECHO_N "checking whether the $compiler linker ($LD) supports shared libraries... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5
+echo $ECHO_N "checking whether the $compiler linker ($LD) supports shared libraries... $ECHO_C" >&6; }
 
   runpath_var=
   allow_undefined_flag=
@@ -8410,23 +9472,36 @@
 }
 _ACEOF
 rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
-  (eval $ac_link) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest$ac_exeext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -8440,7 +9515,9 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
+
 fi
+
 rm -f conftest.err conftest.$ac_objext \
       conftest$ac_exeext conftest.$ac_ext
 if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
@@ -8470,23 +9547,36 @@
 }
 _ACEOF
 rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
-  (eval $ac_link) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest$ac_exeext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -8500,7 +9590,9 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
+
 fi
+
 rm -f conftest.err conftest.$ac_objext \
       conftest$ac_exeext conftest.$ac_ext
 if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
@@ -8950,8 +10042,8 @@
     esac
   fi
 
-echo "$as_me:$LINENO: result: $ld_shlibs" >&5
-echo "${ECHO_T}$ld_shlibs" >&6
+{ echo "$as_me:$LINENO: result: $ld_shlibs" >&5
+echo "${ECHO_T}$ld_shlibs" >&6; }
 test "$ld_shlibs" = no && can_build_shared=no
 
 #
@@ -8971,8 +10063,8 @@
       # Test whether the compiler implicitly links with -lc since on some
       # systems, -lgcc has to come before -lc. If gcc already passes -lc
       # to ld, don't add -lc before -lgcc.
-      echo "$as_me:$LINENO: checking whether -lc should be explicitly linked in" >&5
-echo $ECHO_N "checking whether -lc should be explicitly linked in... $ECHO_C" >&6
+      { echo "$as_me:$LINENO: checking whether -lc should be explicitly linked in" >&5
+echo $ECHO_N "checking whether -lc should be explicitly linked in... $ECHO_C" >&6; }
       $rm conftest*
       printf "$lt_simple_compile_test_code" > conftest.$ac_ext
 
@@ -9009,16 +10101,16 @@
         cat conftest.err 1>&5
       fi
       $rm conftest*
-      echo "$as_me:$LINENO: result: $archive_cmds_need_lc" >&5
-echo "${ECHO_T}$archive_cmds_need_lc" >&6
+      { echo "$as_me:$LINENO: result: $archive_cmds_need_lc" >&5
+echo "${ECHO_T}$archive_cmds_need_lc" >&6; }
       ;;
     esac
   fi
   ;;
 esac
 
-echo "$as_me:$LINENO: checking dynamic linker characteristics" >&5
-echo $ECHO_N "checking dynamic linker characteristics... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking dynamic linker characteristics" >&5
+echo $ECHO_N "checking dynamic linker characteristics... $ECHO_C" >&6; }
 library_names_spec=
 libname_spec='lib$name'
 soname_spec=
@@ -9593,8 +10685,8 @@
   dynamic_linker=no
   ;;
 esac
-echo "$as_me:$LINENO: result: $dynamic_linker" >&5
-echo "${ECHO_T}$dynamic_linker" >&6
+{ echo "$as_me:$LINENO: result: $dynamic_linker" >&5
+echo "${ECHO_T}$dynamic_linker" >&6; }
 test "$dynamic_linker" = no && can_build_shared=no
 
 variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
@@ -9602,8 +10694,8 @@
   variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
 fi
 
-echo "$as_me:$LINENO: checking how to hardcode library paths into programs" >&5
-echo $ECHO_N "checking how to hardcode library paths into programs... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking how to hardcode library paths into programs" >&5
+echo $ECHO_N "checking how to hardcode library paths into programs... $ECHO_C" >&6; }
 hardcode_action=
 if test -n "$hardcode_libdir_flag_spec" || \
    test -n "$runpath_var" || \
@@ -9627,8 +10719,8 @@
   # directories.
   hardcode_action=unsupported
 fi
-echo "$as_me:$LINENO: result: $hardcode_action" >&5
-echo "${ECHO_T}$hardcode_action" >&6
+{ echo "$as_me:$LINENO: result: $hardcode_action" >&5
+echo "${ECHO_T}$hardcode_action" >&6; }
 
 if test "$hardcode_action" = relink; then
   # Fast installation is not supported
@@ -9641,29 +10733,29 @@
 
 striplib=
 old_striplib=
-echo "$as_me:$LINENO: checking whether stripping libraries is possible" >&5
-echo $ECHO_N "checking whether stripping libraries is possible... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking whether stripping libraries is possible" >&5
+echo $ECHO_N "checking whether stripping libraries is possible... $ECHO_C" >&6; }
 if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then
   test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
   test -z "$striplib" && striplib="$STRIP --strip-unneeded"
-  echo "$as_me:$LINENO: result: yes" >&5
-echo "${ECHO_T}yes" >&6
+  { echo "$as_me:$LINENO: result: yes" >&5
+echo "${ECHO_T}yes" >&6; }
 else
 # FIXME - insert some real tests, host_os isn't really good enough
   case $host_os in
    darwin*)
        if test -n "$STRIP" ; then
          striplib="$STRIP -x"
-         echo "$as_me:$LINENO: result: yes" >&5
-echo "${ECHO_T}yes" >&6
+         { 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
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
 fi
        ;;
    *)
-  echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
     ;;
   esac
 fi
@@ -9695,8 +10787,8 @@
 
   darwin*)
   # if libdl is installed we need to link against it
-    echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5
-echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6
+    { 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
@@ -9709,39 +10801,52 @@
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 
-/* Override any gcc2 internal prototype to avoid an error.  */
+/* 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
-/* We use char because int might match the return type of a gcc2
-   builtin and then its argument prototype would still apply.  */
 char dlopen ();
 int
 main ()
 {
-dlopen ();
+return dlopen ();
   ;
   return 0;
 }
 _ACEOF
 rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
-  (eval $ac_link) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest$ac_exeext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -9750,14 +10855,15 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-ac_cv_lib_dl_dlopen=no
+	ac_cv_lib_dl_dlopen=no
 fi
+
 rm -f conftest.err conftest.$ac_objext \
       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
+{ 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
   lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
 else
@@ -9771,8 +10877,8 @@
    ;;
 
   *)
-    echo "$as_me:$LINENO: checking for shl_load" >&5
-echo $ECHO_N "checking for shl_load... $ECHO_C" >&6
+    { echo "$as_me:$LINENO: checking for shl_load" >&5
+echo $ECHO_N "checking for shl_load... $ECHO_C" >&6; }
 if test "${ac_cv_func_shl_load+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -9799,52 +10905,59 @@
 
 #undef shl_load
 
-/* Override any gcc2 internal prototype to avoid an error.  */
+/* 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
-/* We use char because int might match the return type of a gcc2
-   builtin and then its argument prototype would still apply.  */
 char shl_load ();
 /* 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_shl_load) || defined (__stub___shl_load)
+#if defined __stub_shl_load || defined __stub___shl_load
 choke me
-#else
-char (*f) () = shl_load;
 #endif
-#ifdef __cplusplus
-}
-#endif
 
 int
 main ()
 {
-return f != shl_load;
+return shl_load ();
   ;
   return 0;
 }
 _ACEOF
 rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
-  (eval $ac_link) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest$ac_exeext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -9853,18 +10966,19 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-ac_cv_func_shl_load=no
+	ac_cv_func_shl_load=no
 fi
+
 rm -f conftest.err conftest.$ac_objext \
       conftest$ac_exeext conftest.$ac_ext
 fi
-echo "$as_me:$LINENO: result: $ac_cv_func_shl_load" >&5
-echo "${ECHO_T}$ac_cv_func_shl_load" >&6
+{ echo "$as_me:$LINENO: result: $ac_cv_func_shl_load" >&5
+echo "${ECHO_T}$ac_cv_func_shl_load" >&6; }
 if test $ac_cv_func_shl_load = yes; then
   lt_cv_dlopen="shl_load"
 else
-  echo "$as_me:$LINENO: checking for shl_load in -ldld" >&5
-echo $ECHO_N "checking for shl_load in -ldld... $ECHO_C" >&6
+  { 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
@@ -9877,39 +10991,52 @@
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 
-/* Override any gcc2 internal prototype to avoid an error.  */
+/* 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
-/* We use char because int might match the return type of a gcc2
-   builtin and then its argument prototype would still apply.  */
 char shl_load ();
 int
 main ()
 {
-shl_load ();
+return shl_load ();
   ;
   return 0;
 }
 _ACEOF
 rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
-  (eval $ac_link) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest$ac_exeext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -9918,19 +11045,20 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-ac_cv_lib_dld_shl_load=no
+	ac_cv_lib_dld_shl_load=no
 fi
+
 rm -f conftest.err conftest.$ac_objext \
       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
+{ 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
   lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-dld"
 else
-  echo "$as_me:$LINENO: checking for dlopen" >&5
-echo $ECHO_N "checking for dlopen... $ECHO_C" >&6
+  { echo "$as_me:$LINENO: checking for dlopen" >&5
+echo $ECHO_N "checking for dlopen... $ECHO_C" >&6; }
 if test "${ac_cv_func_dlopen+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -9957,52 +11085,59 @@
 
 #undef dlopen
 
-/* Override any gcc2 internal prototype to avoid an error.  */
+/* 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
-/* We use char because int might match the return type of a gcc2
-   builtin and then its argument prototype would still apply.  */
 char dlopen ();
 /* 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_dlopen) || defined (__stub___dlopen)
+#if defined __stub_dlopen || defined __stub___dlopen
 choke me
-#else
-char (*f) () = dlopen;
 #endif
-#ifdef __cplusplus
-}
-#endif
 
 int
 main ()
 {
-return f != dlopen;
+return dlopen ();
   ;
   return 0;
 }
 _ACEOF
 rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
-  (eval $ac_link) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest$ac_exeext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -10011,18 +11146,19 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-ac_cv_func_dlopen=no
+	ac_cv_func_dlopen=no
 fi
+
 rm -f conftest.err conftest.$ac_objext \
       conftest$ac_exeext conftest.$ac_ext
 fi
-echo "$as_me:$LINENO: result: $ac_cv_func_dlopen" >&5
-echo "${ECHO_T}$ac_cv_func_dlopen" >&6
+{ echo "$as_me:$LINENO: result: $ac_cv_func_dlopen" >&5
+echo "${ECHO_T}$ac_cv_func_dlopen" >&6; }
 if test $ac_cv_func_dlopen = yes; then
   lt_cv_dlopen="dlopen"
 else
-  echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5
-echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6
+  { 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
@@ -10035,39 +11171,52 @@
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 
-/* Override any gcc2 internal prototype to avoid an error.  */
+/* 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
-/* We use char because int might match the return type of a gcc2
-   builtin and then its argument prototype would still apply.  */
 char dlopen ();
 int
 main ()
 {
-dlopen ();
+return dlopen ();
   ;
   return 0;
 }
 _ACEOF
 rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
-  (eval $ac_link) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest$ac_exeext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -10076,19 +11225,20 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-ac_cv_lib_dl_dlopen=no
+	ac_cv_lib_dl_dlopen=no
 fi
+
 rm -f conftest.err conftest.$ac_objext \
       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
+{ 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
   lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
 else
-  echo "$as_me:$LINENO: checking for dlopen in -lsvld" >&5
-echo $ECHO_N "checking for dlopen in -lsvld... $ECHO_C" >&6
+  { echo "$as_me:$LINENO: checking for dlopen in -lsvld" >&5
+echo $ECHO_N "checking for dlopen in -lsvld... $ECHO_C" >&6; }
 if test "${ac_cv_lib_svld_dlopen+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -10101,39 +11251,52 @@
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 
-/* Override any gcc2 internal prototype to avoid an error.  */
+/* 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
-/* We use char because int might match the return type of a gcc2
-   builtin and then its argument prototype would still apply.  */
 char dlopen ();
 int
 main ()
 {
-dlopen ();
+return dlopen ();
   ;
   return 0;
 }
 _ACEOF
 rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
-  (eval $ac_link) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest$ac_exeext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -10142,19 +11305,20 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-ac_cv_lib_svld_dlopen=no
+	ac_cv_lib_svld_dlopen=no
 fi
+
 rm -f conftest.err conftest.$ac_objext \
       conftest$ac_exeext conftest.$ac_ext
 LIBS=$ac_check_lib_save_LIBS
 fi
-echo "$as_me:$LINENO: result: $ac_cv_lib_svld_dlopen" >&5
-echo "${ECHO_T}$ac_cv_lib_svld_dlopen" >&6
+{ echo "$as_me:$LINENO: result: $ac_cv_lib_svld_dlopen" >&5
+echo "${ECHO_T}$ac_cv_lib_svld_dlopen" >&6; }
 if test $ac_cv_lib_svld_dlopen = yes; then
   lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"
 else
-  echo "$as_me:$LINENO: checking for dld_link in -ldld" >&5
-echo $ECHO_N "checking for dld_link in -ldld... $ECHO_C" >&6
+  { echo "$as_me:$LINENO: checking for dld_link in -ldld" >&5
+echo $ECHO_N "checking for dld_link in -ldld... $ECHO_C" >&6; }
 if test "${ac_cv_lib_dld_dld_link+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -10167,39 +11331,52 @@
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 
-/* Override any gcc2 internal prototype to avoid an error.  */
+/* 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
-/* We use char because int might match the return type of a gcc2
-   builtin and then its argument prototype would still apply.  */
 char dld_link ();
 int
 main ()
 {
-dld_link ();
+return dld_link ();
   ;
   return 0;
 }
 _ACEOF
 rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
-  (eval $ac_link) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest$ac_exeext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -10208,14 +11385,15 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-ac_cv_lib_dld_dld_link=no
+	ac_cv_lib_dld_dld_link=no
 fi
+
 rm -f conftest.err conftest.$ac_objext \
       conftest$ac_exeext conftest.$ac_ext
 LIBS=$ac_check_lib_save_LIBS
 fi
-echo "$as_me:$LINENO: result: $ac_cv_lib_dld_dld_link" >&5
-echo "${ECHO_T}$ac_cv_lib_dld_dld_link" >&6
+{ echo "$as_me:$LINENO: result: $ac_cv_lib_dld_dld_link" >&5
+echo "${ECHO_T}$ac_cv_lib_dld_dld_link" >&6; }
 if test $ac_cv_lib_dld_dld_link = yes; then
   lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld"
 fi
@@ -10255,8 +11433,8 @@
     save_LIBS="$LIBS"
     LIBS="$lt_cv_dlopen_libs $LIBS"
 
-    echo "$as_me:$LINENO: checking whether a program can dlopen itself" >&5
-echo $ECHO_N "checking whether a program can dlopen itself... $ECHO_C" >&6
+    { echo "$as_me:$LINENO: checking whether a program can dlopen itself" >&5
+echo $ECHO_N "checking whether a program can dlopen itself... $ECHO_C" >&6; }
 if test "${lt_cv_dlopen_self+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -10266,7 +11444,7 @@
   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
   lt_status=$lt_dlunknown
   cat > conftest.$ac_ext <<EOF
-#line 10269 "configure"
+#line 11447 "configure"
 #include "confdefs.h"
 
 #if HAVE_DLFCN_H
@@ -10350,13 +11528,13 @@
 
 
 fi
-echo "$as_me:$LINENO: result: $lt_cv_dlopen_self" >&5
-echo "${ECHO_T}$lt_cv_dlopen_self" >&6
+{ echo "$as_me:$LINENO: result: $lt_cv_dlopen_self" >&5
+echo "${ECHO_T}$lt_cv_dlopen_self" >&6; }
 
     if test "x$lt_cv_dlopen_self" = xyes; then
       wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
-      echo "$as_me:$LINENO: checking whether a statically linked program can dlopen itself" >&5
-echo $ECHO_N "checking whether a statically linked program can dlopen itself... $ECHO_C" >&6
+      { echo "$as_me:$LINENO: checking whether a statically linked program can dlopen itself" >&5
+echo $ECHO_N "checking whether a statically linked program can dlopen itself... $ECHO_C" >&6; }
 if test "${lt_cv_dlopen_self_static+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -10366,7 +11544,7 @@
   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
   lt_status=$lt_dlunknown
   cat > conftest.$ac_ext <<EOF
-#line 10369 "configure"
+#line 11547 "configure"
 #include "confdefs.h"
 
 #if HAVE_DLFCN_H
@@ -10450,8 +11628,8 @@
 
 
 fi
-echo "$as_me:$LINENO: result: $lt_cv_dlopen_self_static" >&5
-echo "${ECHO_T}$lt_cv_dlopen_self_static" >&6
+{ echo "$as_me:$LINENO: result: $lt_cv_dlopen_self_static" >&5
+echo "${ECHO_T}$lt_cv_dlopen_self_static" >&6; }
     fi
 
     CPPFLAGS="$save_CPPFLAGS"
@@ -10473,13 +11651,13 @@
 
 
 # Report which library types will actually be built
-echo "$as_me:$LINENO: checking if libtool supports shared libraries" >&5
-echo $ECHO_N "checking if libtool supports shared libraries... $ECHO_C" >&6
-echo "$as_me:$LINENO: result: $can_build_shared" >&5
-echo "${ECHO_T}$can_build_shared" >&6
+{ echo "$as_me:$LINENO: checking if libtool supports shared libraries" >&5
+echo $ECHO_N "checking if libtool supports shared libraries... $ECHO_C" >&6; }
+{ echo "$as_me:$LINENO: result: $can_build_shared" >&5
+echo "${ECHO_T}$can_build_shared" >&6; }
 
-echo "$as_me:$LINENO: checking whether to build shared libraries" >&5
-echo $ECHO_N "checking whether to build shared libraries... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking whether to build shared libraries" >&5
+echo $ECHO_N "checking whether to build shared libraries... $ECHO_C" >&6; }
 test "$can_build_shared" = "no" && enable_shared=no
 
 # On AIX, shared libraries and static libraries use the same namespace, and
@@ -10499,15 +11677,15 @@
   fi
     ;;
 esac
-echo "$as_me:$LINENO: result: $enable_shared" >&5
-echo "${ECHO_T}$enable_shared" >&6
+{ echo "$as_me:$LINENO: result: $enable_shared" >&5
+echo "${ECHO_T}$enable_shared" >&6; }
 
-echo "$as_me:$LINENO: checking whether to build static libraries" >&5
-echo $ECHO_N "checking whether to build static libraries... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking whether to build static libraries" >&5
+echo $ECHO_N "checking whether to build static libraries... $ECHO_C" >&6; }
 # Make sure either enable_shared or enable_static is yes.
 test "$enable_shared" = yes || enable_static=yes
-echo "$as_me:$LINENO: result: $enable_static" >&5
-echo "${ECHO_T}$enable_static" >&6
+{ echo "$as_me:$LINENO: result: $enable_static" >&5
+echo "${ECHO_T}$enable_static" >&6; }
 
 # The else clause should only fire when bootstrapping the
 # libtool distribution, otherwise you forgot to ship ltmain.sh
@@ -10999,12 +12177,12 @@
 CC="$lt_save_CC"
 
 
-# Check whether --with-tags or --without-tags was given.
+# Check whether --with-tags was given.
 if test "${with_tags+set}" = set; then
-  withval="$with_tags"
-  tagnames="$withval"
-fi;
+  withval=$with_tags; tagnames="$withval"
+fi
 
+
 if test -f "$ltmain" && test -n "$tagnames"; then
   if test ! -f "${ofile}"; then
     { echo "$as_me:$LINENO: WARNING: output file \`$ofile' does not exist" >&5
@@ -11057,7 +12235,7 @@
 	if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
 	    ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
 	    (test "X$CXX" != "Xg++"))) ; then
-	  ac_ext=cc
+	  ac_ext=cpp
 ac_cpp='$CXXCPP $CPPFLAGS'
 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
@@ -11176,18 +12354,18 @@
   # Set up default GNU C++ configuration
 
 
-# Check whether --with-gnu-ld or --without-gnu-ld was given.
+# Check whether --with-gnu-ld was given.
 if test "${with_gnu_ld+set}" = set; then
-  withval="$with_gnu_ld"
-  test "$withval" = no || with_gnu_ld=yes
+  withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
 else
   with_gnu_ld=no
-fi;
+fi
+
 ac_prog=ld
 if test "$GCC" = yes; then
   # Check if gcc -print-prog-name=ld gives a path.
-  echo "$as_me:$LINENO: checking for ld used by $CC" >&5
-echo $ECHO_N "checking for ld used by $CC... $ECHO_C" >&6
+  { echo "$as_me:$LINENO: checking for ld used by $CC" >&5
+echo $ECHO_N "checking for ld used by $CC... $ECHO_C" >&6; }
   case $host in
   *-*-mingw*)
     # gcc leaves a trailing carriage return which upsets mingw
@@ -11216,11 +12394,11 @@
     ;;
   esac
 elif test "$with_gnu_ld" = yes; then
-  echo "$as_me:$LINENO: checking for GNU ld" >&5
-echo $ECHO_N "checking for GNU ld... $ECHO_C" >&6
+  { echo "$as_me:$LINENO: checking for GNU ld" >&5
+echo $ECHO_N "checking for GNU ld... $ECHO_C" >&6; }
 else
-  echo "$as_me:$LINENO: checking for non-GNU ld" >&5
-echo $ECHO_N "checking for non-GNU ld... $ECHO_C" >&6
+  { echo "$as_me:$LINENO: checking for non-GNU ld" >&5
+echo $ECHO_N "checking for non-GNU ld... $ECHO_C" >&6; }
 fi
 if test "${lt_cv_path_LD+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -11253,17 +12431,17 @@
 
 LD="$lt_cv_path_LD"
 if test -n "$LD"; then
-  echo "$as_me:$LINENO: result: $LD" >&5
-echo "${ECHO_T}$LD" >&6
+  { echo "$as_me:$LINENO: result: $LD" >&5
+echo "${ECHO_T}$LD" >&6; }
 else
-  echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
 fi
 test -z "$LD" && { { echo "$as_me:$LINENO: error: no acceptable ld found in \$PATH" >&5
 echo "$as_me: error: no acceptable ld found in \$PATH" >&2;}
    { (exit 1); exit 1; }; }
-echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5
-echo $ECHO_N "checking if the linker ($LD) is GNU ld... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5
+echo $ECHO_N "checking if the linker ($LD) is GNU ld... $ECHO_C" >&6; }
 if test "${lt_cv_prog_gnu_ld+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -11277,8 +12455,8 @@
   ;;
 esac
 fi
-echo "$as_me:$LINENO: result: $lt_cv_prog_gnu_ld" >&5
-echo "${ECHO_T}$lt_cv_prog_gnu_ld" >&6
+{ echo "$as_me:$LINENO: result: $lt_cv_prog_gnu_ld" >&5
+echo "${ECHO_T}$lt_cv_prog_gnu_ld" >&6; }
 with_gnu_ld=$lt_cv_prog_gnu_ld
 
 
@@ -11328,8 +12506,8 @@
 fi
 
 # PORTME: fill in a description of your system's C++ link characteristics
-echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5
-echo $ECHO_N "checking whether the $compiler linker ($LD) supports shared libraries... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5
+echo $ECHO_N "checking whether the $compiler linker ($LD) supports shared libraries... $ECHO_C" >&6; }
 ld_shlibs_CXX=yes
 case $host_os in
   aix3*)
@@ -11441,23 +12619,36 @@
 }
 _ACEOF
 rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
-  (eval $ac_link) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_cxx_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest$ac_exeext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -11471,7 +12662,9 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
+
 fi
+
 rm -f conftest.err conftest.$ac_objext \
       conftest$ac_exeext conftest.$ac_ext
 if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
@@ -11502,23 +12695,36 @@
 }
 _ACEOF
 rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
-  (eval $ac_link) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_cxx_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest$ac_exeext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -11532,7 +12738,9 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
+
 fi
+
 rm -f conftest.err conftest.$ac_objext \
       conftest$ac_exeext conftest.$ac_ext
 if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
@@ -12264,8 +13472,8 @@
     ld_shlibs_CXX=no
     ;;
 esac
-echo "$as_me:$LINENO: result: $ld_shlibs_CXX" >&5
-echo "${ECHO_T}$ld_shlibs_CXX" >&6
+{ echo "$as_me:$LINENO: result: $ld_shlibs_CXX" >&5
+echo "${ECHO_T}$ld_shlibs_CXX" >&6; }
 test "$ld_shlibs_CXX" = no && can_build_shared=no
 
 GCC_CXX="$GXX"
@@ -12404,8 +13612,8 @@
 lt_prog_compiler_pic_CXX=
 lt_prog_compiler_static_CXX=
 
-echo "$as_me:$LINENO: checking for $compiler option to produce PIC" >&5
-echo $ECHO_N "checking for $compiler option to produce PIC... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for $compiler option to produce PIC" >&5
+echo $ECHO_N "checking for $compiler option to produce PIC... $ECHO_C" >&6; }
 
   # C++ specific cases for pic, static, wl, etc.
   if test "$GXX" = yes; then
@@ -12678,16 +13886,16 @@
     esac
   fi
 
-echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_CXX" >&5
-echo "${ECHO_T}$lt_prog_compiler_pic_CXX" >&6
+{ echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_CXX" >&5
+echo "${ECHO_T}$lt_prog_compiler_pic_CXX" >&6; }
 
 #
 # Check to make sure the PIC flag actually works.
 #
 if test -n "$lt_prog_compiler_pic_CXX"; then
 
-echo "$as_me:$LINENO: checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works" >&5
-echo $ECHO_N "checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works" >&5
+echo $ECHO_N "checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works... $ECHO_C" >&6; }
 if test "${lt_prog_compiler_pic_works_CXX+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -12704,11 +13912,11 @@
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:12707: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:13915: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>conftest.err)
    ac_status=$?
    cat conftest.err >&5
-   echo "$as_me:12711: \$? = $ac_status" >&5
+   echo "$as_me:13919: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s "$ac_outfile"; then
      # The compiler can only warn and ignore the option if not recognized
      # So say no if there are warnings other than the usual output.
@@ -12721,8 +13929,8 @@
    $rm conftest*
 
 fi
-echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_works_CXX" >&5
-echo "${ECHO_T}$lt_prog_compiler_pic_works_CXX" >&6
+{ echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_works_CXX" >&5
+echo "${ECHO_T}$lt_prog_compiler_pic_works_CXX" >&6; }
 
 if test x"$lt_prog_compiler_pic_works_CXX" = xyes; then
     case $lt_prog_compiler_pic_CXX in
@@ -12749,8 +13957,8 @@
 # Check to make sure the static flag actually works.
 #
 wl=$lt_prog_compiler_wl_CXX eval lt_tmp_static_flag=\"$lt_prog_compiler_static_CXX\"
-echo "$as_me:$LINENO: checking if $compiler static flag $lt_tmp_static_flag works" >&5
-echo $ECHO_N "checking if $compiler static flag $lt_tmp_static_flag works... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking if $compiler static flag $lt_tmp_static_flag works" >&5
+echo $ECHO_N "checking if $compiler static flag $lt_tmp_static_flag works... $ECHO_C" >&6; }
 if test "${lt_prog_compiler_static_works_CXX+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -12777,8 +13985,8 @@
    LDFLAGS="$save_LDFLAGS"
 
 fi
-echo "$as_me:$LINENO: result: $lt_prog_compiler_static_works_CXX" >&5
-echo "${ECHO_T}$lt_prog_compiler_static_works_CXX" >&6
+{ echo "$as_me:$LINENO: result: $lt_prog_compiler_static_works_CXX" >&5
+echo "${ECHO_T}$lt_prog_compiler_static_works_CXX" >&6; }
 
 if test x"$lt_prog_compiler_static_works_CXX" = xyes; then
     :
@@ -12787,8 +13995,8 @@
 fi
 
 
-echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5
-echo $ECHO_N "checking if $compiler supports -c -o file.$ac_objext... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5
+echo $ECHO_N "checking if $compiler supports -c -o file.$ac_objext... $ECHO_C" >&6; }
 if test "${lt_cv_prog_compiler_c_o_CXX+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -12808,11 +14016,11 @@
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:12811: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:14019: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>out/conftest.err)
    ac_status=$?
    cat out/conftest.err >&5
-   echo "$as_me:12815: \$? = $ac_status" >&5
+   echo "$as_me:14023: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s out/conftest2.$ac_objext
    then
      # The compiler can only warn and ignore the option if not recognized
@@ -12834,23 +14042,23 @@
    $rm conftest*
 
 fi
-echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o_CXX" >&5
-echo "${ECHO_T}$lt_cv_prog_compiler_c_o_CXX" >&6
+{ echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o_CXX" >&5
+echo "${ECHO_T}$lt_cv_prog_compiler_c_o_CXX" >&6; }
 
 
 hard_links="nottested"
 if test "$lt_cv_prog_compiler_c_o_CXX" = no && test "$need_locks" != no; then
   # do not overwrite the value of need_locks provided by the user
-  echo "$as_me:$LINENO: checking if we can lock with hard links" >&5
-echo $ECHO_N "checking if we can lock with hard links... $ECHO_C" >&6
+  { echo "$as_me:$LINENO: checking if we can lock with hard links" >&5
+echo $ECHO_N "checking if we can lock with hard links... $ECHO_C" >&6; }
   hard_links=yes
   $rm conftest*
   ln conftest.a conftest.b 2>/dev/null && hard_links=no
   touch conftest.a
   ln conftest.a conftest.b 2>&5 || hard_links=no
   ln conftest.a conftest.b 2>/dev/null && hard_links=no
-  echo "$as_me:$LINENO: result: $hard_links" >&5
-echo "${ECHO_T}$hard_links" >&6
+  { echo "$as_me:$LINENO: result: $hard_links" >&5
+echo "${ECHO_T}$hard_links" >&6; }
   if test "$hard_links" = no; then
     { echo "$as_me:$LINENO: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5
 echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;}
@@ -12860,8 +14068,8 @@
   need_locks=no
 fi
 
-echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5
-echo $ECHO_N "checking whether the $compiler linker ($LD) supports shared libraries... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5
+echo $ECHO_N "checking whether the $compiler linker ($LD) supports shared libraries... $ECHO_C" >&6; }
 
   export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
   case $host_os in
@@ -12888,8 +14096,8 @@
   ;;
   esac
 
-echo "$as_me:$LINENO: result: $ld_shlibs_CXX" >&5
-echo "${ECHO_T}$ld_shlibs_CXX" >&6
+{ echo "$as_me:$LINENO: result: $ld_shlibs_CXX" >&5
+echo "${ECHO_T}$ld_shlibs_CXX" >&6; }
 test "$ld_shlibs_CXX" = no && can_build_shared=no
 
 #
@@ -12909,8 +14117,8 @@
       # Test whether the compiler implicitly links with -lc since on some
       # systems, -lgcc has to come before -lc. If gcc already passes -lc
       # to ld, don't add -lc before -lgcc.
-      echo "$as_me:$LINENO: checking whether -lc should be explicitly linked in" >&5
-echo $ECHO_N "checking whether -lc should be explicitly linked in... $ECHO_C" >&6
+      { echo "$as_me:$LINENO: checking whether -lc should be explicitly linked in" >&5
+echo $ECHO_N "checking whether -lc should be explicitly linked in... $ECHO_C" >&6; }
       $rm conftest*
       printf "$lt_simple_compile_test_code" > conftest.$ac_ext
 
@@ -12947,16 +14155,16 @@
         cat conftest.err 1>&5
       fi
       $rm conftest*
-      echo "$as_me:$LINENO: result: $archive_cmds_need_lc_CXX" >&5
-echo "${ECHO_T}$archive_cmds_need_lc_CXX" >&6
+      { echo "$as_me:$LINENO: result: $archive_cmds_need_lc_CXX" >&5
+echo "${ECHO_T}$archive_cmds_need_lc_CXX" >&6; }
       ;;
     esac
   fi
   ;;
 esac
 
-echo "$as_me:$LINENO: checking dynamic linker characteristics" >&5
-echo $ECHO_N "checking dynamic linker characteristics... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking dynamic linker characteristics" >&5
+echo $ECHO_N "checking dynamic linker characteristics... $ECHO_C" >&6; }
 library_names_spec=
 libname_spec='lib$name'
 soname_spec=
@@ -13531,8 +14739,8 @@
   dynamic_linker=no
   ;;
 esac
-echo "$as_me:$LINENO: result: $dynamic_linker" >&5
-echo "${ECHO_T}$dynamic_linker" >&6
+{ echo "$as_me:$LINENO: result: $dynamic_linker" >&5
+echo "${ECHO_T}$dynamic_linker" >&6; }
 test "$dynamic_linker" = no && can_build_shared=no
 
 variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
@@ -13540,8 +14748,8 @@
   variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
 fi
 
-echo "$as_me:$LINENO: checking how to hardcode library paths into programs" >&5
-echo $ECHO_N "checking how to hardcode library paths into programs... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking how to hardcode library paths into programs" >&5
+echo $ECHO_N "checking how to hardcode library paths into programs... $ECHO_C" >&6; }
 hardcode_action_CXX=
 if test -n "$hardcode_libdir_flag_spec_CXX" || \
    test -n "$runpath_var_CXX" || \
@@ -13565,8 +14773,8 @@
   # directories.
   hardcode_action_CXX=unsupported
 fi
-echo "$as_me:$LINENO: result: $hardcode_action_CXX" >&5
-echo "${ECHO_T}$hardcode_action_CXX" >&6
+{ echo "$as_me:$LINENO: result: $hardcode_action_CXX" >&5
+echo "${ECHO_T}$hardcode_action_CXX" >&6; }
 
 if test "$hardcode_action_CXX" = relink; then
   # Fast installation is not supported
@@ -14091,13 +15299,13 @@
 cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
 
 
-echo "$as_me:$LINENO: checking if libtool supports shared libraries" >&5
-echo $ECHO_N "checking if libtool supports shared libraries... $ECHO_C" >&6
-echo "$as_me:$LINENO: result: $can_build_shared" >&5
-echo "${ECHO_T}$can_build_shared" >&6
+{ echo "$as_me:$LINENO: checking if libtool supports shared libraries" >&5
+echo $ECHO_N "checking if libtool supports shared libraries... $ECHO_C" >&6; }
+{ echo "$as_me:$LINENO: result: $can_build_shared" >&5
+echo "${ECHO_T}$can_build_shared" >&6; }
 
-echo "$as_me:$LINENO: checking whether to build shared libraries" >&5
-echo $ECHO_N "checking whether to build shared libraries... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking whether to build shared libraries" >&5
+echo $ECHO_N "checking whether to build shared libraries... $ECHO_C" >&6; }
 test "$can_build_shared" = "no" && enable_shared=no
 
 # On AIX, shared libraries and static libraries use the same namespace, and
@@ -14116,15 +15324,15 @@
   fi
   ;;
 esac
-echo "$as_me:$LINENO: result: $enable_shared" >&5
-echo "${ECHO_T}$enable_shared" >&6
+{ echo "$as_me:$LINENO: result: $enable_shared" >&5
+echo "${ECHO_T}$enable_shared" >&6; }
 
-echo "$as_me:$LINENO: checking whether to build static libraries" >&5
-echo $ECHO_N "checking whether to build static libraries... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking whether to build static libraries" >&5
+echo $ECHO_N "checking whether to build static libraries... $ECHO_C" >&6; }
 # Make sure either enable_shared or enable_static is yes.
 test "$enable_shared" = yes || enable_static=yes
-echo "$as_me:$LINENO: result: $enable_static" >&5
-echo "${ECHO_T}$enable_static" >&6
+{ echo "$as_me:$LINENO: result: $enable_static" >&5
+echo "${ECHO_T}$enable_static" >&6; }
 
 GCC_F77="$G77"
 LD_F77="$LD"
@@ -14133,8 +15341,8 @@
 lt_prog_compiler_pic_F77=
 lt_prog_compiler_static_F77=
 
-echo "$as_me:$LINENO: checking for $compiler option to produce PIC" >&5
-echo $ECHO_N "checking for $compiler option to produce PIC... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for $compiler option to produce PIC" >&5
+echo $ECHO_N "checking for $compiler option to produce PIC... $ECHO_C" >&6; }
 
   if test "$GCC" = yes; then
     lt_prog_compiler_wl_F77='-Wl,'
@@ -14343,16 +15551,16 @@
     esac
   fi
 
-echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_F77" >&5
-echo "${ECHO_T}$lt_prog_compiler_pic_F77" >&6
+{ echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_F77" >&5
+echo "${ECHO_T}$lt_prog_compiler_pic_F77" >&6; }
 
 #
 # Check to make sure the PIC flag actually works.
 #
 if test -n "$lt_prog_compiler_pic_F77"; then
 
-echo "$as_me:$LINENO: checking if $compiler PIC flag $lt_prog_compiler_pic_F77 works" >&5
-echo $ECHO_N "checking if $compiler PIC flag $lt_prog_compiler_pic_F77 works... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking if $compiler PIC flag $lt_prog_compiler_pic_F77 works" >&5
+echo $ECHO_N "checking if $compiler PIC flag $lt_prog_compiler_pic_F77 works... $ECHO_C" >&6; }
 if test "${lt_prog_compiler_pic_works_F77+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -14369,11 +15577,11 @@
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:14372: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:15580: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>conftest.err)
    ac_status=$?
    cat conftest.err >&5
-   echo "$as_me:14376: \$? = $ac_status" >&5
+   echo "$as_me:15584: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s "$ac_outfile"; then
      # The compiler can only warn and ignore the option if not recognized
      # So say no if there are warnings other than the usual output.
@@ -14386,8 +15594,8 @@
    $rm conftest*
 
 fi
-echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_works_F77" >&5
-echo "${ECHO_T}$lt_prog_compiler_pic_works_F77" >&6
+{ echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_works_F77" >&5
+echo "${ECHO_T}$lt_prog_compiler_pic_works_F77" >&6; }
 
 if test x"$lt_prog_compiler_pic_works_F77" = xyes; then
     case $lt_prog_compiler_pic_F77 in
@@ -14414,8 +15622,8 @@
 # Check to make sure the static flag actually works.
 #
 wl=$lt_prog_compiler_wl_F77 eval lt_tmp_static_flag=\"$lt_prog_compiler_static_F77\"
-echo "$as_me:$LINENO: checking if $compiler static flag $lt_tmp_static_flag works" >&5
-echo $ECHO_N "checking if $compiler static flag $lt_tmp_static_flag works... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking if $compiler static flag $lt_tmp_static_flag works" >&5
+echo $ECHO_N "checking if $compiler static flag $lt_tmp_static_flag works... $ECHO_C" >&6; }
 if test "${lt_prog_compiler_static_works_F77+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -14442,8 +15650,8 @@
    LDFLAGS="$save_LDFLAGS"
 
 fi
-echo "$as_me:$LINENO: result: $lt_prog_compiler_static_works_F77" >&5
-echo "${ECHO_T}$lt_prog_compiler_static_works_F77" >&6
+{ echo "$as_me:$LINENO: result: $lt_prog_compiler_static_works_F77" >&5
+echo "${ECHO_T}$lt_prog_compiler_static_works_F77" >&6; }
 
 if test x"$lt_prog_compiler_static_works_F77" = xyes; then
     :
@@ -14452,8 +15660,8 @@
 fi
 
 
-echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5
-echo $ECHO_N "checking if $compiler supports -c -o file.$ac_objext... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5
+echo $ECHO_N "checking if $compiler supports -c -o file.$ac_objext... $ECHO_C" >&6; }
 if test "${lt_cv_prog_compiler_c_o_F77+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -14473,11 +15681,11 @@
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:14476: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:15684: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>out/conftest.err)
    ac_status=$?
    cat out/conftest.err >&5
-   echo "$as_me:14480: \$? = $ac_status" >&5
+   echo "$as_me:15688: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s out/conftest2.$ac_objext
    then
      # The compiler can only warn and ignore the option if not recognized
@@ -14499,23 +15707,23 @@
    $rm conftest*
 
 fi
-echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o_F77" >&5
-echo "${ECHO_T}$lt_cv_prog_compiler_c_o_F77" >&6
+{ echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o_F77" >&5
+echo "${ECHO_T}$lt_cv_prog_compiler_c_o_F77" >&6; }
 
 
 hard_links="nottested"
 if test "$lt_cv_prog_compiler_c_o_F77" = no && test "$need_locks" != no; then
   # do not overwrite the value of need_locks provided by the user
-  echo "$as_me:$LINENO: checking if we can lock with hard links" >&5
-echo $ECHO_N "checking if we can lock with hard links... $ECHO_C" >&6
+  { echo "$as_me:$LINENO: checking if we can lock with hard links" >&5
+echo $ECHO_N "checking if we can lock with hard links... $ECHO_C" >&6; }
   hard_links=yes
   $rm conftest*
   ln conftest.a conftest.b 2>/dev/null && hard_links=no
   touch conftest.a
   ln conftest.a conftest.b 2>&5 || hard_links=no
   ln conftest.a conftest.b 2>/dev/null && hard_links=no
-  echo "$as_me:$LINENO: result: $hard_links" >&5
-echo "${ECHO_T}$hard_links" >&6
+  { echo "$as_me:$LINENO: result: $hard_links" >&5
+echo "${ECHO_T}$hard_links" >&6; }
   if test "$hard_links" = no; then
     { echo "$as_me:$LINENO: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5
 echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;}
@@ -14525,8 +15733,8 @@
   need_locks=no
 fi
 
-echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5
-echo $ECHO_N "checking whether the $compiler linker ($LD) supports shared libraries... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5
+echo $ECHO_N "checking whether the $compiler linker ($LD) supports shared libraries... $ECHO_C" >&6; }
 
   runpath_var=
   allow_undefined_flag_F77=
@@ -14932,23 +16140,36 @@
       end
 _ACEOF
 rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
-  (eval $ac_link) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_f77_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_f77_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest$ac_exeext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -14962,7 +16183,9 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
+
 fi
+
 rm -f conftest.err conftest.$ac_objext \
       conftest$ac_exeext conftest.$ac_ext
 if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
@@ -14982,23 +16205,36 @@
       end
 _ACEOF
 rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
-  (eval $ac_link) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_f77_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_f77_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest$ac_exeext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -15012,7 +16248,9 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
+
 fi
+
 rm -f conftest.err conftest.$ac_objext \
       conftest$ac_exeext conftest.$ac_ext
 if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
@@ -15462,8 +16700,8 @@
     esac
   fi
 
-echo "$as_me:$LINENO: result: $ld_shlibs_F77" >&5
-echo "${ECHO_T}$ld_shlibs_F77" >&6
+{ echo "$as_me:$LINENO: result: $ld_shlibs_F77" >&5
+echo "${ECHO_T}$ld_shlibs_F77" >&6; }
 test "$ld_shlibs_F77" = no && can_build_shared=no
 
 #
@@ -15483,8 +16721,8 @@
       # Test whether the compiler implicitly links with -lc since on some
       # systems, -lgcc has to come before -lc. If gcc already passes -lc
       # to ld, don't add -lc before -lgcc.
-      echo "$as_me:$LINENO: checking whether -lc should be explicitly linked in" >&5
-echo $ECHO_N "checking whether -lc should be explicitly linked in... $ECHO_C" >&6
+      { echo "$as_me:$LINENO: checking whether -lc should be explicitly linked in" >&5
+echo $ECHO_N "checking whether -lc should be explicitly linked in... $ECHO_C" >&6; }
       $rm conftest*
       printf "$lt_simple_compile_test_code" > conftest.$ac_ext
 
@@ -15521,16 +16759,16 @@
         cat conftest.err 1>&5
       fi
       $rm conftest*
-      echo "$as_me:$LINENO: result: $archive_cmds_need_lc_F77" >&5
-echo "${ECHO_T}$archive_cmds_need_lc_F77" >&6
+      { echo "$as_me:$LINENO: result: $archive_cmds_need_lc_F77" >&5
+echo "${ECHO_T}$archive_cmds_need_lc_F77" >&6; }
       ;;
     esac
   fi
   ;;
 esac
 
-echo "$as_me:$LINENO: checking dynamic linker characteristics" >&5
-echo $ECHO_N "checking dynamic linker characteristics... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking dynamic linker characteristics" >&5
+echo $ECHO_N "checking dynamic linker characteristics... $ECHO_C" >&6; }
 library_names_spec=
 libname_spec='lib$name'
 soname_spec=
@@ -16105,8 +17343,8 @@
   dynamic_linker=no
   ;;
 esac
-echo "$as_me:$LINENO: result: $dynamic_linker" >&5
-echo "${ECHO_T}$dynamic_linker" >&6
+{ echo "$as_me:$LINENO: result: $dynamic_linker" >&5
+echo "${ECHO_T}$dynamic_linker" >&6; }
 test "$dynamic_linker" = no && can_build_shared=no
 
 variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
@@ -16114,8 +17352,8 @@
   variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
 fi
 
-echo "$as_me:$LINENO: checking how to hardcode library paths into programs" >&5
-echo $ECHO_N "checking how to hardcode library paths into programs... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking how to hardcode library paths into programs" >&5
+echo $ECHO_N "checking how to hardcode library paths into programs... $ECHO_C" >&6; }
 hardcode_action_F77=
 if test -n "$hardcode_libdir_flag_spec_F77" || \
    test -n "$runpath_var_F77" || \
@@ -16139,8 +17377,8 @@
   # directories.
   hardcode_action_F77=unsupported
 fi
-echo "$as_me:$LINENO: result: $hardcode_action_F77" >&5
-echo "${ECHO_T}$hardcode_action_F77" >&6
+{ echo "$as_me:$LINENO: result: $hardcode_action_F77" >&5
+echo "${ECHO_T}$hardcode_action_F77" >&6; }
 
 if test "$hardcode_action_F77" = relink; then
   # Fast installation is not supported
@@ -16577,7 +17815,6 @@
 	if test -n "$GCJ" && test "X$GCJ" != "Xno"; then
 
 
-
 # Source file extension for Java test sources.
 ac_ext=java
 
@@ -16645,8 +17882,8 @@
   lt_prog_compiler_no_builtin_flag_GCJ=' -fno-builtin'
 
 
-echo "$as_me:$LINENO: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
-echo $ECHO_N "checking if $compiler supports -fno-rtti -fno-exceptions... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
+echo $ECHO_N "checking if $compiler supports -fno-rtti -fno-exceptions... $ECHO_C" >&6; }
 if test "${lt_cv_prog_compiler_rtti_exceptions+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -16663,11 +17900,11 @@
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:16666: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:17903: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>conftest.err)
    ac_status=$?
    cat conftest.err >&5
-   echo "$as_me:16670: \$? = $ac_status" >&5
+   echo "$as_me:17907: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s "$ac_outfile"; then
      # The compiler can only warn and ignore the option if not recognized
      # So say no if there are warnings other than the usual output.
@@ -16680,8 +17917,8 @@
    $rm conftest*
 
 fi
-echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_rtti_exceptions" >&5
-echo "${ECHO_T}$lt_cv_prog_compiler_rtti_exceptions" >&6
+{ echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_rtti_exceptions" >&5
+echo "${ECHO_T}$lt_cv_prog_compiler_rtti_exceptions" >&6; }
 
 if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then
     lt_prog_compiler_no_builtin_flag_GCJ="$lt_prog_compiler_no_builtin_flag_GCJ -fno-rtti -fno-exceptions"
@@ -16695,8 +17932,8 @@
 lt_prog_compiler_pic_GCJ=
 lt_prog_compiler_static_GCJ=
 
-echo "$as_me:$LINENO: checking for $compiler option to produce PIC" >&5
-echo $ECHO_N "checking for $compiler option to produce PIC... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for $compiler option to produce PIC" >&5
+echo $ECHO_N "checking for $compiler option to produce PIC... $ECHO_C" >&6; }
 
   if test "$GCC" = yes; then
     lt_prog_compiler_wl_GCJ='-Wl,'
@@ -16905,16 +18142,16 @@
     esac
   fi
 
-echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_GCJ" >&5
-echo "${ECHO_T}$lt_prog_compiler_pic_GCJ" >&6
+{ echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_GCJ" >&5
+echo "${ECHO_T}$lt_prog_compiler_pic_GCJ" >&6; }
 
 #
 # Check to make sure the PIC flag actually works.
 #
 if test -n "$lt_prog_compiler_pic_GCJ"; then
 
-echo "$as_me:$LINENO: checking if $compiler PIC flag $lt_prog_compiler_pic_GCJ works" >&5
-echo $ECHO_N "checking if $compiler PIC flag $lt_prog_compiler_pic_GCJ works... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking if $compiler PIC flag $lt_prog_compiler_pic_GCJ works" >&5
+echo $ECHO_N "checking if $compiler PIC flag $lt_prog_compiler_pic_GCJ works... $ECHO_C" >&6; }
 if test "${lt_prog_compiler_pic_works_GCJ+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -16931,11 +18168,11 @@
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:16934: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:18171: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>conftest.err)
    ac_status=$?
    cat conftest.err >&5
-   echo "$as_me:16938: \$? = $ac_status" >&5
+   echo "$as_me:18175: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s "$ac_outfile"; then
      # The compiler can only warn and ignore the option if not recognized
      # So say no if there are warnings other than the usual output.
@@ -16948,8 +18185,8 @@
    $rm conftest*
 
 fi
-echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_works_GCJ" >&5
-echo "${ECHO_T}$lt_prog_compiler_pic_works_GCJ" >&6
+{ echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_works_GCJ" >&5
+echo "${ECHO_T}$lt_prog_compiler_pic_works_GCJ" >&6; }
 
 if test x"$lt_prog_compiler_pic_works_GCJ" = xyes; then
     case $lt_prog_compiler_pic_GCJ in
@@ -16976,8 +18213,8 @@
 # Check to make sure the static flag actually works.
 #
 wl=$lt_prog_compiler_wl_GCJ eval lt_tmp_static_flag=\"$lt_prog_compiler_static_GCJ\"
-echo "$as_me:$LINENO: checking if $compiler static flag $lt_tmp_static_flag works" >&5
-echo $ECHO_N "checking if $compiler static flag $lt_tmp_static_flag works... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking if $compiler static flag $lt_tmp_static_flag works" >&5
+echo $ECHO_N "checking if $compiler static flag $lt_tmp_static_flag works... $ECHO_C" >&6; }
 if test "${lt_prog_compiler_static_works_GCJ+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -17004,8 +18241,8 @@
    LDFLAGS="$save_LDFLAGS"
 
 fi
-echo "$as_me:$LINENO: result: $lt_prog_compiler_static_works_GCJ" >&5
-echo "${ECHO_T}$lt_prog_compiler_static_works_GCJ" >&6
+{ echo "$as_me:$LINENO: result: $lt_prog_compiler_static_works_GCJ" >&5
+echo "${ECHO_T}$lt_prog_compiler_static_works_GCJ" >&6; }
 
 if test x"$lt_prog_compiler_static_works_GCJ" = xyes; then
     :
@@ -17014,8 +18251,8 @@
 fi
 
 
-echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5
-echo $ECHO_N "checking if $compiler supports -c -o file.$ac_objext... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5
+echo $ECHO_N "checking if $compiler supports -c -o file.$ac_objext... $ECHO_C" >&6; }
 if test "${lt_cv_prog_compiler_c_o_GCJ+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -17035,11 +18272,11 @@
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:17038: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:18275: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>out/conftest.err)
    ac_status=$?
    cat out/conftest.err >&5
-   echo "$as_me:17042: \$? = $ac_status" >&5
+   echo "$as_me:18279: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s out/conftest2.$ac_objext
    then
      # The compiler can only warn and ignore the option if not recognized
@@ -17061,23 +18298,23 @@
    $rm conftest*
 
 fi
-echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o_GCJ" >&5
-echo "${ECHO_T}$lt_cv_prog_compiler_c_o_GCJ" >&6
+{ echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o_GCJ" >&5
+echo "${ECHO_T}$lt_cv_prog_compiler_c_o_GCJ" >&6; }
 
 
 hard_links="nottested"
 if test "$lt_cv_prog_compiler_c_o_GCJ" = no && test "$need_locks" != no; then
   # do not overwrite the value of need_locks provided by the user
-  echo "$as_me:$LINENO: checking if we can lock with hard links" >&5
-echo $ECHO_N "checking if we can lock with hard links... $ECHO_C" >&6
+  { echo "$as_me:$LINENO: checking if we can lock with hard links" >&5
+echo $ECHO_N "checking if we can lock with hard links... $ECHO_C" >&6; }
   hard_links=yes
   $rm conftest*
   ln conftest.a conftest.b 2>/dev/null && hard_links=no
   touch conftest.a
   ln conftest.a conftest.b 2>&5 || hard_links=no
   ln conftest.a conftest.b 2>/dev/null && hard_links=no
-  echo "$as_me:$LINENO: result: $hard_links" >&5
-echo "${ECHO_T}$hard_links" >&6
+  { echo "$as_me:$LINENO: result: $hard_links" >&5
+echo "${ECHO_T}$hard_links" >&6; }
   if test "$hard_links" = no; then
     { echo "$as_me:$LINENO: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5
 echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;}
@@ -17087,8 +18324,8 @@
   need_locks=no
 fi
 
-echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5
-echo $ECHO_N "checking whether the $compiler linker ($LD) supports shared libraries... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5
+echo $ECHO_N "checking whether the $compiler linker ($LD) supports shared libraries... $ECHO_C" >&6; }
 
   runpath_var=
   allow_undefined_flag_GCJ=
@@ -17504,23 +18741,36 @@
 }
 _ACEOF
 rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
-  (eval $ac_link) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest$ac_exeext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -17534,7 +18784,9 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
+
 fi
+
 rm -f conftest.err conftest.$ac_objext \
       conftest$ac_exeext conftest.$ac_ext
 if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
@@ -17564,23 +18816,36 @@
 }
 _ACEOF
 rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
-  (eval $ac_link) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest$ac_exeext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -17594,7 +18859,9 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
+
 fi
+
 rm -f conftest.err conftest.$ac_objext \
       conftest$ac_exeext conftest.$ac_ext
 if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
@@ -18044,8 +19311,8 @@
     esac
   fi
 
-echo "$as_me:$LINENO: result: $ld_shlibs_GCJ" >&5
-echo "${ECHO_T}$ld_shlibs_GCJ" >&6
+{ echo "$as_me:$LINENO: result: $ld_shlibs_GCJ" >&5
+echo "${ECHO_T}$ld_shlibs_GCJ" >&6; }
 test "$ld_shlibs_GCJ" = no && can_build_shared=no
 
 #
@@ -18065,8 +19332,8 @@
       # Test whether the compiler implicitly links with -lc since on some
       # systems, -lgcc has to come before -lc. If gcc already passes -lc
       # to ld, don't add -lc before -lgcc.
-      echo "$as_me:$LINENO: checking whether -lc should be explicitly linked in" >&5
-echo $ECHO_N "checking whether -lc should be explicitly linked in... $ECHO_C" >&6
+      { echo "$as_me:$LINENO: checking whether -lc should be explicitly linked in" >&5
+echo $ECHO_N "checking whether -lc should be explicitly linked in... $ECHO_C" >&6; }
       $rm conftest*
       printf "$lt_simple_compile_test_code" > conftest.$ac_ext
 
@@ -18103,16 +19370,16 @@
         cat conftest.err 1>&5
       fi
       $rm conftest*
-      echo "$as_me:$LINENO: result: $archive_cmds_need_lc_GCJ" >&5
-echo "${ECHO_T}$archive_cmds_need_lc_GCJ" >&6
+      { echo "$as_me:$LINENO: result: $archive_cmds_need_lc_GCJ" >&5
+echo "${ECHO_T}$archive_cmds_need_lc_GCJ" >&6; }
       ;;
     esac
   fi
   ;;
 esac
 
-echo "$as_me:$LINENO: checking dynamic linker characteristics" >&5
-echo $ECHO_N "checking dynamic linker characteristics... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking dynamic linker characteristics" >&5
+echo $ECHO_N "checking dynamic linker characteristics... $ECHO_C" >&6; }
 library_names_spec=
 libname_spec='lib$name'
 soname_spec=
@@ -18687,8 +19954,8 @@
   dynamic_linker=no
   ;;
 esac
-echo "$as_me:$LINENO: result: $dynamic_linker" >&5
-echo "${ECHO_T}$dynamic_linker" >&6
+{ echo "$as_me:$LINENO: result: $dynamic_linker" >&5
+echo "${ECHO_T}$dynamic_linker" >&6; }
 test "$dynamic_linker" = no && can_build_shared=no
 
 variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
@@ -18696,8 +19963,8 @@
   variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
 fi
 
-echo "$as_me:$LINENO: checking how to hardcode library paths into programs" >&5
-echo $ECHO_N "checking how to hardcode library paths into programs... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking how to hardcode library paths into programs" >&5
+echo $ECHO_N "checking how to hardcode library paths into programs... $ECHO_C" >&6; }
 hardcode_action_GCJ=
 if test -n "$hardcode_libdir_flag_spec_GCJ" || \
    test -n "$runpath_var_GCJ" || \
@@ -18721,8 +19988,8 @@
   # directories.
   hardcode_action_GCJ=unsupported
 fi
-echo "$as_me:$LINENO: result: $hardcode_action_GCJ" >&5
-echo "${ECHO_T}$hardcode_action_GCJ" >&6
+{ echo "$as_me:$LINENO: result: $hardcode_action_GCJ" >&5
+echo "${ECHO_T}$hardcode_action_GCJ" >&6; }
 
 if test "$hardcode_action_GCJ" = relink; then
   # Fast installation is not supported
@@ -19158,7 +20425,6 @@
       RC)
 
 
-
 # Source file extension for RC test sources.
 ac_ext=rc
 
@@ -19699,18 +20965,19 @@
 for ac_header in sys/types.h sys/time.h stdlib.h unistd.h string.h
 do
 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
-if eval "test \"\${$as_ac_Header+set}\" = set"; then
-  echo "$as_me:$LINENO: checking for $ac_header" >&5
-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
-if eval "test \"\${$as_ac_Header+set}\" = set"; then
+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
-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
+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
+{ 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
@@ -19721,23 +20988,36 @@
 #include <$ac_header>
 _ACEOF
 rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
-  (eval $ac_compile) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest.$ac_objext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -19746,15 +21026,16 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-ac_header_compiler=no
+	ac_header_compiler=no
 fi
+
 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
-echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
-echo "${ECHO_T}$ac_header_compiler" >&6
+{ 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
+{ 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
@@ -19763,8 +21044,13 @@
 /* end confdefs.h.  */
 #include <$ac_header>
 _ACEOF
-if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
-  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+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
@@ -19788,9 +21074,10 @@
 
   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
+{ 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
@@ -19814,25 +21101,19 @@
 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;}
-    (
-      cat <<\_ASBOX
-## ------------------------------------------ ##
-## Report this to the AC_PACKAGE_NAME lists.  ##
-## ------------------------------------------ ##
-_ASBOX
-    ) |
-      sed "s/^/$as_me: WARNING:     /" >&2
+
     ;;
 esac
-echo "$as_me:$LINENO: checking for $ac_header" >&5
-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
-if eval "test \"\${$as_ac_Header+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
 else
   eval "$as_ac_Header=\$ac_header_preproc"
 fi
-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
+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
@@ -19853,18 +21134,19 @@
 for ac_header in ieeefp.h nan.h math.h fp_class.h float.h ansidecl.h
 do
 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
-if eval "test \"\${$as_ac_Header+set}\" = set"; then
-  echo "$as_me:$LINENO: checking for $ac_header" >&5
-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
-if eval "test \"\${$as_ac_Header+set}\" = set"; then
+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
-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
+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
+{ 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
@@ -19875,23 +21157,36 @@
 #include <$ac_header>
 _ACEOF
 rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
-  (eval $ac_compile) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest.$ac_objext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -19900,15 +21195,16 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-ac_header_compiler=no
+	ac_header_compiler=no
 fi
+
 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
-echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
-echo "${ECHO_T}$ac_header_compiler" >&6
+{ 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
+{ 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
@@ -19917,8 +21213,13 @@
 /* end confdefs.h.  */
 #include <$ac_header>
 _ACEOF
-if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
-  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+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
@@ -19942,9 +21243,10 @@
 
   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
+{ 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
@@ -19968,25 +21270,19 @@
 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;}
-    (
-      cat <<\_ASBOX
-## ------------------------------------------ ##
-## Report this to the AC_PACKAGE_NAME lists.  ##
-## ------------------------------------------ ##
-_ASBOX
-    ) |
-      sed "s/^/$as_me: WARNING:     /" >&2
+
     ;;
 esac
-echo "$as_me:$LINENO: checking for $ac_header" >&5
-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
-if eval "test \"\${$as_ac_Header+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
 else
   eval "$as_ac_Header=\$ac_header_preproc"
 fi
-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
+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
@@ -20006,18 +21302,19 @@
 for ac_header in sys/timeb.h time.h sys/stat.h sys/select.h stdarg.h
 do
 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
-if eval "test \"\${$as_ac_Header+set}\" = set"; then
-  echo "$as_me:$LINENO: checking for $ac_header" >&5
-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
-if eval "test \"\${$as_ac_Header+set}\" = set"; then
+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
-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
+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
+{ 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
@@ -20028,23 +21325,36 @@
 #include <$ac_header>
 _ACEOF
 rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
-  (eval $ac_compile) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest.$ac_objext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -20053,15 +21363,16 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-ac_header_compiler=no
+	ac_header_compiler=no
 fi
+
 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
-echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
-echo "${ECHO_T}$ac_header_compiler" >&6
+{ 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
+{ 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
@@ -20070,8 +21381,13 @@
 /* end confdefs.h.  */
 #include <$ac_header>
 _ACEOF
-if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
-  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+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
@@ -20095,9 +21411,10 @@
 
   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
+{ 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
@@ -20121,25 +21438,19 @@
 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;}
-    (
-      cat <<\_ASBOX
-## ------------------------------------------ ##
-## Report this to the AC_PACKAGE_NAME lists.  ##
-## ------------------------------------------ ##
-_ASBOX
-    ) |
-      sed "s/^/$as_me: WARNING:     /" >&2
+
     ;;
 esac
-echo "$as_me:$LINENO: checking for $ac_header" >&5
-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
-if eval "test \"\${$as_ac_Header+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
 else
   eval "$as_ac_Header=\$ac_header_preproc"
 fi
-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
+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
@@ -20156,9 +21467,9 @@
 for ac_func in stat _stat
 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 eval "test \"\${$as_ac_var+set}\" = set"; then
+{ 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
@@ -20184,52 +21495,59 @@
 
 #undef $ac_func
 
-/* Override any gcc2 internal prototype to avoid an error.  */
+/* 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
-/* We use char because int might match the return type of a gcc2
-   builtin and then its argument prototype would still apply.  */
 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)
+#if defined __stub_$ac_func || defined __stub___$ac_func
 choke me
-#else
-char (*f) () = $ac_func;
 #endif
-#ifdef __cplusplus
-}
-#endif
 
 int
 main ()
 {
-return f != $ac_func;
+return $ac_func ();
   ;
   return 0;
 }
 _ACEOF
 rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
-  (eval $ac_link) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest$ac_exeext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -20238,13 +21556,15 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-eval "$as_ac_var=no"
+	eval "$as_ac_var=no"
 fi
+
 rm -f conftest.err conftest.$ac_objext \
       conftest$ac_exeext conftest.$ac_ext
 fi
-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
+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
@@ -20253,8 +21573,8 @@
 fi
 done
 
-echo "$as_me:$LINENO: checking for isnan" >&5
-echo $ECHO_N "checking for isnan... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for isnan" >&5
+echo $ECHO_N "checking for isnan... $ECHO_C" >&6; }
 if test "${ac_cv_func_isnan+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -20281,52 +21601,59 @@
 
 #undef isnan
 
-/* Override any gcc2 internal prototype to avoid an error.  */
+/* 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
-/* We use char because int might match the return type of a gcc2
-   builtin and then its argument prototype would still apply.  */
 char isnan ();
 /* 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_isnan) || defined (__stub___isnan)
+#if defined __stub_isnan || defined __stub___isnan
 choke me
-#else
-char (*f) () = isnan;
 #endif
-#ifdef __cplusplus
-}
-#endif
 
 int
 main ()
 {
-return f != isnan;
+return isnan ();
   ;
   return 0;
 }
 _ACEOF
 rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
-  (eval $ac_link) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest$ac_exeext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -20335,18 +21662,19 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-ac_cv_func_isnan=no
+	ac_cv_func_isnan=no
 fi
+
 rm -f conftest.err conftest.$ac_objext \
       conftest$ac_exeext conftest.$ac_ext
 fi
-echo "$as_me:$LINENO: result: $ac_cv_func_isnan" >&5
-echo "${ECHO_T}$ac_cv_func_isnan" >&6
+{ echo "$as_me:$LINENO: result: $ac_cv_func_isnan" >&5
+echo "${ECHO_T}$ac_cv_func_isnan" >&6; }
 if test $ac_cv_func_isnan = yes; then
   :
 else
-  echo "$as_me:$LINENO: checking for isnan in -lm" >&5
-echo $ECHO_N "checking for isnan in -lm... $ECHO_C" >&6
+  { echo "$as_me:$LINENO: checking for isnan in -lm" >&5
+echo $ECHO_N "checking for isnan in -lm... $ECHO_C" >&6; }
 if test "${ac_cv_lib_m_isnan+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -20359,39 +21687,52 @@
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 
-/* Override any gcc2 internal prototype to avoid an error.  */
+/* 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
-/* We use char because int might match the return type of a gcc2
-   builtin and then its argument prototype would still apply.  */
 char isnan ();
 int
 main ()
 {
-isnan ();
+return isnan ();
   ;
   return 0;
 }
 _ACEOF
 rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
-  (eval $ac_link) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest$ac_exeext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -20400,14 +21741,15 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-ac_cv_lib_m_isnan=no
+	ac_cv_lib_m_isnan=no
 fi
+
 rm -f conftest.err conftest.$ac_objext \
       conftest$ac_exeext conftest.$ac_ext
 LIBS=$ac_check_lib_save_LIBS
 fi
-echo "$as_me:$LINENO: result: $ac_cv_lib_m_isnan" >&5
-echo "${ECHO_T}$ac_cv_lib_m_isnan" >&6
+{ echo "$as_me:$LINENO: result: $ac_cv_lib_m_isnan" >&5
+echo "${ECHO_T}$ac_cv_lib_m_isnan" >&6; }
 if test $ac_cv_lib_m_isnan = yes; then
   M_LIBS="-lm"; cat >>confdefs.h <<\_ACEOF
 #define HAVE_ISNAN 1
@@ -20418,8 +21760,8 @@
 fi
 
 
-echo "$as_me:$LINENO: checking for isinf" >&5
-echo $ECHO_N "checking for isinf... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for isinf" >&5
+echo $ECHO_N "checking for isinf... $ECHO_C" >&6; }
 if test "${ac_cv_func_isinf+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -20446,52 +21788,59 @@
 
 #undef isinf
 
-/* Override any gcc2 internal prototype to avoid an error.  */
+/* 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
-/* We use char because int might match the return type of a gcc2
-   builtin and then its argument prototype would still apply.  */
 char isinf ();
 /* 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_isinf) || defined (__stub___isinf)
+#if defined __stub_isinf || defined __stub___isinf
 choke me
-#else
-char (*f) () = isinf;
 #endif
-#ifdef __cplusplus
-}
-#endif
 
 int
 main ()
 {
-return f != isinf;
+return isinf ();
   ;
   return 0;
 }
 _ACEOF
 rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
-  (eval $ac_link) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest$ac_exeext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -20500,18 +21849,19 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-ac_cv_func_isinf=no
+	ac_cv_func_isinf=no
 fi
+
 rm -f conftest.err conftest.$ac_objext \
       conftest$ac_exeext conftest.$ac_ext
 fi
-echo "$as_me:$LINENO: result: $ac_cv_func_isinf" >&5
-echo "${ECHO_T}$ac_cv_func_isinf" >&6
+{ echo "$as_me:$LINENO: result: $ac_cv_func_isinf" >&5
+echo "${ECHO_T}$ac_cv_func_isinf" >&6; }
 if test $ac_cv_func_isinf = yes; then
   :
 else
-  echo "$as_me:$LINENO: checking for isinf in -lm" >&5
-echo $ECHO_N "checking for isinf in -lm... $ECHO_C" >&6
+  { echo "$as_me:$LINENO: checking for isinf in -lm" >&5
+echo $ECHO_N "checking for isinf in -lm... $ECHO_C" >&6; }
 if test "${ac_cv_lib_m_isinf+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -20524,39 +21874,52 @@
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 
-/* Override any gcc2 internal prototype to avoid an error.  */
+/* 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
-/* We use char because int might match the return type of a gcc2
-   builtin and then its argument prototype would still apply.  */
 char isinf ();
 int
 main ()
 {
-isinf ();
+return isinf ();
   ;
   return 0;
 }
 _ACEOF
 rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
-  (eval $ac_link) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest$ac_exeext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -20565,14 +21928,15 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-ac_cv_lib_m_isinf=no
+	ac_cv_lib_m_isinf=no
 fi
+
 rm -f conftest.err conftest.$ac_objext \
       conftest$ac_exeext conftest.$ac_ext
 LIBS=$ac_check_lib_save_LIBS
 fi
-echo "$as_me:$LINENO: result: $ac_cv_lib_m_isinf" >&5
-echo "${ECHO_T}$ac_cv_lib_m_isinf" >&6
+{ echo "$as_me:$LINENO: result: $ac_cv_lib_m_isinf" >&5
+echo "${ECHO_T}$ac_cv_lib_m_isinf" >&6; }
 if test $ac_cv_lib_m_isinf = yes; then
   M_LIBS="-lm"; cat >>confdefs.h <<\_ACEOF
 #define HAVE_ISINF 1
@@ -20583,8 +21947,8 @@
 fi
 
 
-echo "$as_me:$LINENO: checking for pow" >&5
-echo $ECHO_N "checking for pow... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for pow" >&5
+echo $ECHO_N "checking for pow... $ECHO_C" >&6; }
 if test "${ac_cv_func_pow+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -20611,52 +21975,59 @@
 
 #undef pow
 
-/* Override any gcc2 internal prototype to avoid an error.  */
+/* 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
-/* We use char because int might match the return type of a gcc2
-   builtin and then its argument prototype would still apply.  */
 char pow ();
 /* 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_pow) || defined (__stub___pow)
+#if defined __stub_pow || defined __stub___pow
 choke me
-#else
-char (*f) () = pow;
 #endif
-#ifdef __cplusplus
-}
-#endif
 
 int
 main ()
 {
-return f != pow;
+return pow ();
   ;
   return 0;
 }
 _ACEOF
 rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
-  (eval $ac_link) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest$ac_exeext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -20665,18 +22036,19 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-ac_cv_func_pow=no
+	ac_cv_func_pow=no
 fi
+
 rm -f conftest.err conftest.$ac_objext \
       conftest$ac_exeext conftest.$ac_ext
 fi
-echo "$as_me:$LINENO: result: $ac_cv_func_pow" >&5
-echo "${ECHO_T}$ac_cv_func_pow" >&6
+{ echo "$as_me:$LINENO: result: $ac_cv_func_pow" >&5
+echo "${ECHO_T}$ac_cv_func_pow" >&6; }
 if test $ac_cv_func_pow = yes; then
   :
 else
-  echo "$as_me:$LINENO: checking for pow in -lm" >&5
-echo $ECHO_N "checking for pow in -lm... $ECHO_C" >&6
+  { echo "$as_me:$LINENO: checking for pow in -lm" >&5
+echo $ECHO_N "checking for pow in -lm... $ECHO_C" >&6; }
 if test "${ac_cv_lib_m_pow+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -20689,39 +22061,52 @@
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 
-/* Override any gcc2 internal prototype to avoid an error.  */
+/* 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
-/* We use char because int might match the return type of a gcc2
-   builtin and then its argument prototype would still apply.  */
 char pow ();
 int
 main ()
 {
-pow ();
+return pow ();
   ;
   return 0;
 }
 _ACEOF
 rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
-  (eval $ac_link) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest$ac_exeext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -20730,14 +22115,15 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-ac_cv_lib_m_pow=no
+	ac_cv_lib_m_pow=no
 fi
+
 rm -f conftest.err conftest.$ac_objext \
       conftest$ac_exeext conftest.$ac_ext
 LIBS=$ac_check_lib_save_LIBS
 fi
-echo "$as_me:$LINENO: result: $ac_cv_lib_m_pow" >&5
-echo "${ECHO_T}$ac_cv_lib_m_pow" >&6
+{ echo "$as_me:$LINENO: result: $ac_cv_lib_m_pow" >&5
+echo "${ECHO_T}$ac_cv_lib_m_pow" >&6; }
 if test $ac_cv_lib_m_pow = yes; then
   M_LIBS="-lm"; cat >>confdefs.h <<\_ACEOF
 #define HAVE_POW 1
@@ -20748,8 +22134,8 @@
 fi
 
 
-echo "$as_me:$LINENO: checking for floor" >&5
-echo $ECHO_N "checking for floor... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for floor" >&5
+echo $ECHO_N "checking for floor... $ECHO_C" >&6; }
 if test "${ac_cv_func_floor+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -20776,52 +22162,59 @@
 
 #undef floor
 
-/* Override any gcc2 internal prototype to avoid an error.  */
+/* 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
-/* We use char because int might match the return type of a gcc2
-   builtin and then its argument prototype would still apply.  */
 char floor ();
 /* 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_floor) || defined (__stub___floor)
+#if defined __stub_floor || defined __stub___floor
 choke me
-#else
-char (*f) () = floor;
 #endif
-#ifdef __cplusplus
-}
-#endif
 
 int
 main ()
 {
-return f != floor;
+return floor ();
   ;
   return 0;
 }
 _ACEOF
 rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
-  (eval $ac_link) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest$ac_exeext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -20830,18 +22223,19 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-ac_cv_func_floor=no
+	ac_cv_func_floor=no
 fi
+
 rm -f conftest.err conftest.$ac_objext \
       conftest$ac_exeext conftest.$ac_ext
 fi
-echo "$as_me:$LINENO: result: $ac_cv_func_floor" >&5
-echo "${ECHO_T}$ac_cv_func_floor" >&6
+{ echo "$as_me:$LINENO: result: $ac_cv_func_floor" >&5
+echo "${ECHO_T}$ac_cv_func_floor" >&6; }
 if test $ac_cv_func_floor = yes; then
   :
 else
-  echo "$as_me:$LINENO: checking for floor in -lm" >&5
-echo $ECHO_N "checking for floor in -lm... $ECHO_C" >&6
+  { echo "$as_me:$LINENO: checking for floor in -lm" >&5
+echo $ECHO_N "checking for floor in -lm... $ECHO_C" >&6; }
 if test "${ac_cv_lib_m_floor+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -20854,39 +22248,52 @@
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 
-/* Override any gcc2 internal prototype to avoid an error.  */
+/* 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
-/* We use char because int might match the return type of a gcc2
-   builtin and then its argument prototype would still apply.  */
 char floor ();
 int
 main ()
 {
-floor ();
+return floor ();
   ;
   return 0;
 }
 _ACEOF
 rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
-  (eval $ac_link) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest$ac_exeext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -20895,14 +22302,15 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-ac_cv_lib_m_floor=no
+	ac_cv_lib_m_floor=no
 fi
+
 rm -f conftest.err conftest.$ac_objext \
       conftest$ac_exeext conftest.$ac_ext
 LIBS=$ac_check_lib_save_LIBS
 fi
-echo "$as_me:$LINENO: result: $ac_cv_lib_m_floor" >&5
-echo "${ECHO_T}$ac_cv_lib_m_floor" >&6
+{ echo "$as_me:$LINENO: result: $ac_cv_lib_m_floor" >&5
+echo "${ECHO_T}$ac_cv_lib_m_floor" >&6; }
 if test $ac_cv_lib_m_floor = yes; then
   M_LIBS="-lm"; cat >>confdefs.h <<\_ACEOF
 #define HAVE_FLOOR 1
@@ -20913,8 +22321,8 @@
 fi
 
 
-echo "$as_me:$LINENO: checking for fabs" >&5
-echo $ECHO_N "checking for fabs... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for fabs" >&5
+echo $ECHO_N "checking for fabs... $ECHO_C" >&6; }
 if test "${ac_cv_func_fabs+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -20941,52 +22349,59 @@
 
 #undef fabs
 
-/* Override any gcc2 internal prototype to avoid an error.  */
+/* 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
-/* We use char because int might match the return type of a gcc2
-   builtin and then its argument prototype would still apply.  */
 char fabs ();
 /* 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_fabs) || defined (__stub___fabs)
+#if defined __stub_fabs || defined __stub___fabs
 choke me
-#else
-char (*f) () = fabs;
 #endif
-#ifdef __cplusplus
-}
-#endif
 
 int
 main ()
 {
-return f != fabs;
+return fabs ();
   ;
   return 0;
 }
 _ACEOF
 rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
-  (eval $ac_link) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest$ac_exeext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -20995,18 +22410,19 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-ac_cv_func_fabs=no
+	ac_cv_func_fabs=no
 fi
+
 rm -f conftest.err conftest.$ac_objext \
       conftest$ac_exeext conftest.$ac_ext
 fi
-echo "$as_me:$LINENO: result: $ac_cv_func_fabs" >&5
-echo "${ECHO_T}$ac_cv_func_fabs" >&6
+{ echo "$as_me:$LINENO: result: $ac_cv_func_fabs" >&5
+echo "${ECHO_T}$ac_cv_func_fabs" >&6; }
 if test $ac_cv_func_fabs = yes; then
   :
 else
-  echo "$as_me:$LINENO: checking for fabs in -lm" >&5
-echo $ECHO_N "checking for fabs in -lm... $ECHO_C" >&6
+  { echo "$as_me:$LINENO: checking for fabs in -lm" >&5
+echo $ECHO_N "checking for fabs in -lm... $ECHO_C" >&6; }
 if test "${ac_cv_lib_m_fabs+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -21019,39 +22435,52 @@
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 
-/* Override any gcc2 internal prototype to avoid an error.  */
+/* 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
-/* We use char because int might match the return type of a gcc2
-   builtin and then its argument prototype would still apply.  */
 char fabs ();
 int
 main ()
 {
-fabs ();
+return fabs ();
   ;
   return 0;
 }
 _ACEOF
 rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
-  (eval $ac_link) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest$ac_exeext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -21060,14 +22489,15 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-ac_cv_lib_m_fabs=no
+	ac_cv_lib_m_fabs=no
 fi
+
 rm -f conftest.err conftest.$ac_objext \
       conftest$ac_exeext conftest.$ac_ext
 LIBS=$ac_check_lib_save_LIBS
 fi
-echo "$as_me:$LINENO: result: $ac_cv_lib_m_fabs" >&5
-echo "${ECHO_T}$ac_cv_lib_m_fabs" >&6
+{ echo "$as_me:$LINENO: result: $ac_cv_lib_m_fabs" >&5
+echo "${ECHO_T}$ac_cv_lib_m_fabs" >&6; }
 if test $ac_cv_lib_m_fabs = yes; then
   M_LIBS="-lm"; cat >>confdefs.h <<\_ACEOF
 #define HAVE_FABS 1
@@ -21081,9 +22511,9 @@
 for ac_func in gettimeofday
 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 eval "test \"\${$as_ac_var+set}\" = set"; then
+{ 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
@@ -21109,52 +22539,59 @@
 
 #undef $ac_func
 
-/* Override any gcc2 internal prototype to avoid an error.  */
+/* 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
-/* We use char because int might match the return type of a gcc2
-   builtin and then its argument prototype would still apply.  */
 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)
+#if defined __stub_$ac_func || defined __stub___$ac_func
 choke me
-#else
-char (*f) () = $ac_func;
 #endif
-#ifdef __cplusplus
-}
-#endif
 
 int
 main ()
 {
-return f != $ac_func;
+return $ac_func ();
   ;
   return 0;
 }
 _ACEOF
 rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
-  (eval $ac_link) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest$ac_exeext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -21163,13 +22600,15 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-eval "$as_ac_var=no"
+	eval "$as_ac_var=no"
 fi
+
 rm -f conftest.err conftest.$ac_objext \
       conftest$ac_exeext conftest.$ac_ext
 fi
-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
+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
@@ -21188,9 +22627,9 @@
 for ac_func in mktime localtime localtime_r asctime time gmtime_r ftime
 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 eval "test \"\${$as_ac_var+set}\" = set"; then
+{ 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
@@ -21216,52 +22655,59 @@
 
 #undef $ac_func
 
-/* Override any gcc2 internal prototype to avoid an error.  */
+/* 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
-/* We use char because int might match the return type of a gcc2
-   builtin and then its argument prototype would still apply.  */
 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)
+#if defined __stub_$ac_func || defined __stub___$ac_func
 choke me
-#else
-char (*f) () = $ac_func;
 #endif
-#ifdef __cplusplus
-}
-#endif
 
 int
 main ()
 {
-return f != $ac_func;
+return $ac_func ();
   ;
   return 0;
 }
 _ACEOF
 rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
-  (eval $ac_link) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest$ac_exeext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -21270,13 +22716,15 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-eval "$as_ac_var=no"
+	eval "$as_ac_var=no"
 fi
+
 rm -f conftest.err conftest.$ac_objext \
       conftest$ac_exeext conftest.$ac_ext
 fi
-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
+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
@@ -21297,9 +22745,9 @@
 for ac_func in printf sprintf fprintf snprintf vfprintf vsprintf vsnprintf sscanf
 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 eval "test \"\${$as_ac_var+set}\" = set"; then
+{ 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
@@ -21325,52 +22773,59 @@
 
 #undef $ac_func
 
-/* Override any gcc2 internal prototype to avoid an error.  */
+/* 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
-/* We use char because int might match the return type of a gcc2
-   builtin and then its argument prototype would still apply.  */
 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)
+#if defined __stub_$ac_func || defined __stub___$ac_func
 choke me
-#else
-char (*f) () = $ac_func;
 #endif
-#ifdef __cplusplus
-}
-#endif
 
 int
 main ()
 {
-return f != $ac_func;
+return $ac_func ();
   ;
   return 0;
 }
 _ACEOF
 rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
-  (eval $ac_link) 2>conftest.er1
+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); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
+	 { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+  { (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); }; } &&
 	 { ac_try='test -s conftest$ac_exeext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&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_try") 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
@@ -21379,13 +22834,15 @@
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-eval "$as_ac_var=no"
+	eval "$as_ac_var=no"
 fi
+
 rm -f conftest.err conftest.$ac_objext \
       conftest$ac_exeext conftest.$ac_ext
 fi
-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
+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
@@ -21411,8 +22868,8 @@
 
 # Extract the first word of "perl", so it can be a program name with args.
 set dummy perl; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
 if test "${ac_cv_prog_PERL+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -21425,28 +22882,30 @@
   IFS=$as_save_IFS
   test -z "$as_dir" && as_dir=.
   for ac_exec_ext in '' $ac_executable_extensions; do
-  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; }; then
     ac_cv_prog_PERL="perl"
     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_PERL" && ac_cv_prog_PERL="false"
 fi
 fi
 PERL=$ac_cv_prog_PERL
 if test -n "$PERL"; then
-  echo "$as_me:$LINENO: result: $PERL" >&5
-echo "${ECHO_T}$PERL" >&6
+  { echo "$as_me:$LINENO: result: $PERL" >&5
+echo "${ECHO_T}$PERL" >&6; }
 else
-  echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
 fi
 
 
 
+
 if test "$PERL" != "false"; then
   WITH_PERL_TRUE=
   WITH_PERL_FALSE='#'
@@ -21462,11 +22921,11 @@
 PYTHON_SITE_PACKAGES=
 pythondir=
 
-# Check whether --with-python or --without-python was given.
+# Check whether --with-python was given.
 if test "${with_python+set}" = set; then
-  withval="$with_python"
+  withval=$with_python;
+fi
 
-fi;
 if test "$with_python" != "no" ; then
     if test -x "$with_python/bin/python"
     then
@@ -21485,8 +22944,8 @@
 	    else
 	        # Extract the first word of "python python2.4 python2.3 python2.2 python2.1 python2.0 python1.6 python1.5", so it can be a program name with args.
 set dummy python python2.4 python2.3 python2.2 python2.1 python2.0 python1.6 python1.5; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
 if test "${ac_cv_path_PYTHON+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -21501,27 +22960,28 @@
   IFS=$as_save_IFS
   test -z "$as_dir" && as_dir=.
   for ac_exec_ext in '' $ac_executable_extensions; do
-  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; }; then
     ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
     break 2
   fi
 done
 done
+IFS=$as_save_IFS
 
   ;;
 esac
 fi
 PYTHON=$ac_cv_path_PYTHON
-
 if test -n "$PYTHON"; then
-  echo "$as_me:$LINENO: result: $PYTHON" >&5
-echo "${ECHO_T}$PYTHON" >&6
+  { echo "$as_me:$LINENO: result: $PYTHON" >&5
+echo "${ECHO_T}$PYTHON" >&6; }
 else
-  echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
 fi
 
+
 	    fi
 	fi
     fi
@@ -21567,7 +23027,7 @@
     fi
     if test "$with_python" != ""
     then
-        pythondir=$(PYTHON_SITE_PACKAGES)
+        pythondir='$(PYTHON_SITE_PACKAGES)'
     else
         pythondir='$(libdir)/python$(PYTHON_VERSION)/site-packages'
     fi
@@ -21592,11 +23052,11 @@
 
 
 
-# Check whether --with-crypto or --without-crypto was given.
+# Check whether --with-crypto was given.
 if test "${with_crypto+set}" = set; then
-  withval="$with_crypto"
+  withval=$with_crypto;
+fi
 
-fi;
 WITH_CRYPTO=0
 if test "$with_crypto" = "no" ; then
     echo Disabling crypto support
@@ -21605,8 +23065,8 @@
 else
     # Extract the first word of "libgcrypt-config", so it can be a program name with args.
 set dummy libgcrypt-config; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
 if test "${ac_cv_path_LIBGCRYPT_CONFIG+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
@@ -21621,28 +23081,29 @@
   IFS=$as_save_IFS
   test -z "$as_dir" && as_dir=.
   for ac_exec_ext in '' $ac_executable_extensions; do
-  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; }; then
     ac_cv_path_LIBGCRYPT_CONFIG="$as_dir/$ac_word$ac_exec_ext"
     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_path_LIBGCRYPT_CONFIG" && ac_cv_path_LIBGCRYPT_CONFIG="no"
   ;;
 esac
 fi
 LIBGCRYPT_CONFIG=$ac_cv_path_LIBGCRYPT_CONFIG
-
 if test -n "$LIBGCRYPT_CONFIG"; then
-  echo "$as_me:$LINENO: result: $LIBGCRYPT_CONFIG" >&5
-echo "${ECHO_T}$LIBGCRYPT_CONFIG" >&6
+  { echo "$as_me:$LINENO: result: $LIBGCRYPT_CONFIG" >&5
+echo "${ECHO_T}$LIBGCRYPT_CONFIG" >&6; }
 else
-  echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
 fi
 
+
     if test "$LIBGCRYPT_CONFIG" != "no" ; then
       LIBGCRYPT_VERSION=`$LIBGCRYPT_CONFIG --version`
       if test `echo $LIBGCRYPT_VERSION | sed -e 's/libxml //' | awk 'BEGIN { FS = "."; } { printf "%d", ($1 * 1000 + $2) * 1000 + $3;}'` -lt `echo "1.1.42" | sed -e 's/libxml //' | awk 'BEGIN { FS = "."; } { printf "%d", ($1 * 1000 + $2) * 1000 + $3;}'`
@@ -21696,11 +23157,11 @@
 
 
 
-# Check whether --with-debug or --without-debug was given.
+# Check whether --with-debug was given.
 if test "${with_debug+set}" = set; then
-  withval="$with_debug"
+  withval=$with_debug;
+fi
 
-fi;
 if test "$with_debug" = "no" ; then
     echo Disabling debug support
     WITH_XSLT_DEBUG=0
@@ -21710,11 +23171,11 @@
 
 
 
-# Check whether --with-mem_debug or --without-mem_debug was given.
+# Check whether --with-mem_debug was given.
 if test "${with_mem_debug+set}" = set; then
-  withval="$with_mem_debug"
+  withval=$with_mem_debug;
+fi
 
-fi;
 if test "$with_mem_debug" = "yes" ; then
     echo Enabling memory debug support
     WITH_MEM_DEBUG=1
@@ -21724,11 +23185,11 @@
 
 
 
-# Check whether --with-with_debugger or --without-with_debugger was given.
+# Check whether --with-with_debugger was given.
 if test "${with_with_debugger+set}" = set; then
-  withval="$with_with_debugger"
+  withval=$with_with_debugger;
+fi
 
-fi;
 if test "$with_debugger" = "no" ; then
     echo Disabling debugger
     WITH_DEBUGGER=0
@@ -21757,42 +23218,42 @@
 LIBXML_SRC=""
 
 
-# Check whether --with-libxml-prefix or --without-libxml-prefix was given.
+# Check whether --with-libxml-prefix was given.
 if test "${with_libxml_prefix+set}" = set; then
-  withval="$with_libxml_prefix"
-  LIBXML_CONFIG_PREFIX=$withval
+  withval=$with_libxml_prefix; LIBXML_CONFIG_PREFIX=$withval
 
-fi;
+fi
 
 
-# Check whether --with-libxml-include-prefix or --without-libxml-include-prefix was given.
+
+# Check whether --with-libxml-include-prefix was given.
 if test "${with_libxml_include_prefix+set}" = set; then
-  withval="$with_libxml_include_prefix"
-  LIBXML_CFLAGS="-I$withval"
+  withval=$with_libxml_include_prefix; LIBXML_CFLAGS="-I$withval"
 
-fi;
+fi
 
 
-# Check whether --with-libxml-libs-prefix or --without-libxml-libs-prefix was given.
+
+# Check whether --with-libxml-libs-prefix was given.
 if test "${with_libxml_libs_prefix+set}" = set; then
-  withval="$with_libxml_libs_prefix"
-  LIBXML_LIBS="-L$withval"
+  withval=$with_libxml_libs_prefix; LIBXML_LIBS="-L$withval"
 
-fi;
+fi
 
 
-# Check whether --with-libxml-src or --without-libxml-src was given.
+
+# Check whether --with-libxml-src was given.
 if test "${with_libxml_src+set}" = set; then
-  withval="$with_libxml_src"
-  LIBXML_SRC="$withval"
+  withval=$with_libxml_src; LIBXML_SRC="$withval"
 
-fi;
+fi
 
 
 
 
-echo "$as_me:$LINENO: checking for libxml libraries >= $LIBXML_REQUIRED_VERSION" >&5
-echo $ECHO_N "checking for libxml libraries >= $LIBXML_REQUIRED_VERSION... $ECHO_C" >&6
+
+{ echo "$as_me:$LINENO: checking for libxml libraries >= $LIBXML_REQUIRED_VERSION" >&5
+echo $ECHO_N "checking for libxml libraries >= $LIBXML_REQUIRED_VERSION... $ECHO_C" >&6; }
 if test "x$LIBXML_CONFIG_PREFIX" != "x"
 then
 	XML_CONFIG=${LIBXML_CONFIG_PREFIX}/bin/xml2-config
@@ -21847,8 +23308,8 @@
 	then
 		LIBXML_LIBS="$LIBXML_LIBS `$XML_CONFIG --libs`"
 		LIBXML_CFLAGS="$LIBXML_CFLAGS `$XML_CONFIG --cflags`"
-		echo "$as_me:$LINENO: result: $XMLVERS found" >&5
-echo "${ECHO_T}$XMLVERS found" >&6
+		{ echo "$as_me:$LINENO: result: $XMLVERS found" >&5
+echo "${ECHO_T}$XMLVERS found" >&6; }
 	else
 		{ { echo "$as_me:$LINENO: error: Version $XMLVERS found. You need at least libxml2 $LIBXML_REQUIRED_VERSION for this version of libxslt" >&5
 echo "$as_me: error: Version $XMLVERS found. You need at least libxml2 $LIBXML_REQUIRED_VERSION for this version of libxslt" >&2;}
@@ -21866,41 +23327,41 @@
 
 
 
-# Check whether --with-plugins or --without-plugins was given.
+# Check whether --with-plugins was given.
 if test "${with_plugins+set}" = set; then
-  withval="$with_plugins"
+  withval=$with_plugins;
+fi
 
-fi;
 if test "$with_plugins" = ""
 then
     with_plugins=yes
 fi
 
-echo "$as_me:$LINENO: checking whether shared libraries will be built (required for plugins)" >&5
-echo $ECHO_N "checking whether shared libraries will be built (required for plugins)... $ECHO_C" >&6
+{ echo "$as_me:$LINENO: checking whether shared libraries will be built (required for plugins)" >&5
+echo $ECHO_N "checking whether shared libraries will be built (required for plugins)... $ECHO_C" >&6; }
 if test "$enable_shared" = "no" -a "$with_plugins" = "yes"; then
-	 echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
+	 { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
 	 { echo "$as_me:$LINENO: WARNING: Disabling plugin support." >&5
 echo "$as_me: WARNING: Disabling plugin support." >&2;}
 	 { echo "$as_me:$LINENO: WARNING: Plugins require that shared libraries be built." >&5
 echo "$as_me: WARNING: Plugins require that shared libraries be built." >&2;}
 	 with_plugins=no
 else
-	 echo "$as_me:$LINENO: result: yes" >&5
-echo "${ECHO_T}yes" >&6
+	 { echo "$as_me:$LINENO: result: yes" >&5
+echo "${ECHO_T}yes" >&6; }
 fi
 
 if test "$with_plugins" = "yes" ; then
-  echo "$as_me:$LINENO: checking libxml2 module support" >&5
-echo $ECHO_N "checking libxml2 module support... $ECHO_C" >&6
+  { echo "$as_me:$LINENO: checking libxml2 module support" >&5
+echo $ECHO_N "checking libxml2 module support... $ECHO_C" >&6; }
   WITH_MODULES="`$XML_CONFIG --modules`"
   if test "${WITH_MODULES}" = "1"; then
-    echo "$as_me:$LINENO: result: yes" >&5
-echo "${ECHO_T}yes" >&6
+    { 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
+    { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
     WITH_MODULES="0"
   fi
 else
@@ -21998,7 +23459,8 @@
 #ln -s Copyright COPYING
 
 
-                                                                                                                                                                                                                                                                                                                                                                                                                ac_config_files="$ac_config_files Makefile libxslt.pc libexslt.pc libxslt/Makefile libxslt/xsltconfig.h libxslt/xsltwin32config.h libexslt/Makefile libexslt/exsltconfig.h xsltproc/Makefile python/Makefile python/tests/Makefile tests/Makefile tests/docs/Makefile tests/REC1/Makefile tests/REC2/Makefile tests/REC/Makefile tests/general/Makefile tests/reports/Makefile tests/extensions/Makefile tests/namespaces/Makefile tests/keys/Makefile tests/numbers/Makefile tests/documents/Makefile tests/xmlspec/Makefile tests/multiple/Makefile tests/xinclude/Makefile tests/XSLTMark/Makefile tests/docbook/Makefile tests/exslt/Makefile tests/exslt/common/Makefile tests/exslt/functions/Makefile tests/exslt/math/Makefile tests/exslt/sets/Makefile tests/exslt/strings/Makefile tests/exslt/date/Makefile tests/exslt/dynamic/Makefile tests/plugins/Makefile doc/Makefile xslt-config libxslt.spec"
+ac_config_files="$ac_config_files Makefile libxslt.pc libexslt.pc libxslt/Makefile libxslt/xsltconfig.h libxslt/xsltwin32config.h libexslt/Makefile libexslt/exsltconfig.h xsltproc/Makefile python/Makefile python/tests/Makefile tests/Makefile tests/docs/Makefile tests/REC1/Makefile tests/REC2/Makefile tests/REC/Makefile tests/general/Makefile tests/reports/Makefile tests/extensions/Makefile tests/namespaces/Makefile tests/keys/Makefile tests/numbers/Makefile tests/documents/Makefile tests/xmlspec/Makefile tests/multiple/Makefile tests/xinclude/Makefile tests/XSLTMark/Makefile tests/docbook/Makefile tests/exslt/Makefile tests/exslt/common/Makefile tests/exslt/functions/Makefile tests/exslt/math/Makefile tests/exslt/sets/Makefile tests/exslt/strings/Makefile tests/exslt/date/Makefile tests/exslt/dynamic/Makefile tests/plugins/Makefile doc/Makefile xslt-config libxslt.spec"
+
 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
@@ -22017,39 +23479,58 @@
 
 # The following way of writing the cache mishandles newlines in values,
 # but we know of no workaround that is simple, portable, and efficient.
-# So, don't put newlines in cache variables' values.
+# 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 `(ac_space=' '; set | grep ac_space) 2>&1` in
-    *ac_space=\ *)
+    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 \
-	"s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
+      sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
       ;;
-    esac;
-} |
+    esac |
+    sort
+) |
   sed '
+     /^ac_cv_env_/b end
      t clear
-     : clear
+     :clear
      s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
      t end
-     /^ac_cv_env/!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 "updating cache $cache_file"
+     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 "not updating unwritable cache $cache_file"
+    { 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
@@ -22058,32 +23539,18 @@
 # Let make expand exec_prefix.
 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
 
-# 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
-
 DEFS=-DHAVE_CONFIG_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_i=`echo "$ac_i" |
-	 sed 's/\$U\././;s/\.o$//;s/\.obj$//'`
-  # 2. Add them.
-  ac_libobjs="$ac_libobjs $ac_i\$U.$ac_objext"
-  ac_ltlibobjs="$ac_ltlibobjs $ac_i"'$U.lo'
+  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
 
@@ -22184,11 +23651,35 @@
   # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
   # is contrary to our usage.  Disable this feature.
   alias -g '${1+"$@"}'='"$@"'
-elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
-  set -o posix
+  setopt NO_GLOB_SUBST
+else
+  case `(set -o) 2>/dev/null` in *posix*) set -o posix;; esac
 fi
+BIN_SH=xpg4; export BIN_SH # for Tru64
 DUALCASE=1; export DUALCASE # for MKS sh
 
+
+# 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
@@ -22197,8 +23688,43 @@
 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.
-$as_unset ENV MAIL MAILPATH
+for as_var in ENV MAIL MAILPATH
+do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
+done
 PS1='$ '
 PS2='> '
 PS4='+ '
@@ -22212,18 +23738,19 @@
   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
+    ($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; then
+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
+if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
   as_basename=basename
 else
   as_basename=false
@@ -22231,159 +23758,120 @@
 
 
 # Name of the executable.
-as_me=`$as_basename "$0" ||
+as_me=`$as_basename -- "$0" ||
 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
 	 X"$0" : 'X\(//\)$' \| \
-	 X"$0" : 'X\(/\)$' \| \
-	 .     : '\(.\)' 2>/dev/null ||
+	 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
 echo X/"$0" |
-    sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
-  	  /^X\/\(\/\/\)$/{ s//\1/; q; }
-  	  /^X\/\(\/\).*/{ s//\1/; q; }
-  	  s/.*/./; q'`
+    sed '/^.*\/\([^/][^/]*\)\/*$/{
+	    s//\1/
+	    q
+	  }
+	  /^X\/\(\/\/\)$/{
+	    s//\1/
+	    q
+	  }
+	  /^X\/\(\/\).*/{
+	    s//\1/
+	    q
+	  }
+	  s/.*/./; q'`
 
+# CDPATH.
+$as_unset CDPATH
 
-# PATH needs CR, and LINENO needs CR and PATH.
-# 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
 
-
   as_lineno_1=$LINENO
   as_lineno_2=$LINENO
-  as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
   test "x$as_lineno_1" != "x$as_lineno_2" &&
-  test "x$as_lineno_3"  = "x$as_lineno_2"  || {
-  # Find who we are.  Look in the path if we contain no path at all
-  # relative or not.
-  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
+  test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || {
 
-       ;;
-  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_me:$LINENO: error: cannot find myself; rerun with an absolute path" >&5
-echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2;}
-   { (exit 1); exit 1; }; }
-  fi
-  case $CONFIG_SHELL in
-  '')
-    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=.
-  for as_base in sh bash ksh sh5; do
-	 case $as_dir in
-	 /*)
-	   if ("$as_dir/$as_base" -c '
-  as_lineno_1=$LINENO
-  as_lineno_2=$LINENO
-  as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
-  test "x$as_lineno_1" != "x$as_lineno_2" &&
-  test "x$as_lineno_3"  = "x$as_lineno_2" ') 2>/dev/null; then
-	     $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
-	     $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
-	     CONFIG_SHELL=$as_dir/$as_base
-	     export CONFIG_SHELL
-	     exec "$CONFIG_SHELL" "$0" ${1+"$@"}
-	   fi;;
-	 esac
-       done
-done
-;;
-  esac
-
   # 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 before each line; the second 'sed' does the real
-  # work.  The second script uses 'N' to pair each line-number line
-  # with the numbered line, and appends trailing '-' during
-  # substitution so that $LINENO is not a special case at line end.
+  # 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
-  # second 'sed' script.  Blame Lee E. McMahon for sed's syntax.  :-)
-  sed '=' <$as_myself |
+  # 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
-      s,$,-,
-      : loop
-      s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
+      :loop
+      s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
       t loop
-      s,-$,,
-      s,^['$as_cr_digits']*\n,,
+      s/-\n.*//
     ' >$as_me.lineno &&
-  chmod +x $as_me.lineno ||
-    { { echo "$as_me:$LINENO: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&5
-echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2;}
+  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 sensible to this).
-  . ./$as_me.lineno
+  # original and so on.  Autoconf is especially sensitive to this).
+  . "./$as_me.lineno"
   # Exit status is that of the last command.
   exit
 }
 
 
-case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
-  *c*,-n*) ECHO_N= ECHO_C='
-' ECHO_T='	' ;;
-  *c*,*  ) ECHO_N=-n ECHO_C= ECHO_T= ;;
-  *)       ECHO_N= ECHO_C='\c' ECHO_T= ;;
+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; then
+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
-  # We could just check for DJGPP; but this test a) works b) is more generic
-  # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
-  if test -f conf$$.exe; then
-    # Don't use ln at all; we don't have any links
+  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'
-  else
-    as_ln_s='ln -s'
-  fi
 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$$.file
+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=:
@@ -22392,7 +23880,19 @@
   as_mkdir_p=false
 fi
 
-as_executable_p="test -f"
+# Find out whether ``test -x'' works.  Don't use a zero-byte file, as
+# systems may use methods other than mode bits to determine executability.
+cat >conf$$.file <<_ASEOF
+#! /bin/sh
+exit 0
+_ASEOF
+chmod +x conf$$.file
+if test -x conf$$.file >/dev/null 2>&1; then
+  as_executable_p="test -x"
+else
+  as_executable_p=:
+fi
+rm -f conf$$.file
 
 # 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'"
@@ -22401,31 +23901,14 @@
 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
 
 
-# IFS
-# We need space, tab and new line, in precisely that order.
-as_nl='
-'
-IFS=" 	$as_nl"
-
-# CDPATH.
-$as_unset CDPATH
-
 exec 6>&1
 
-# Open the log real soon, to keep \$[0] and so on meaningful, and to
+# 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.  Logging --version etc. is OK.
-exec 5>>config.log
-{
-  echo
-  sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
-## Running $as_me. ##
-_ASBOX
-} >&5
-cat >&5 <<_CSEOF
-
+# values after options handling.
+ac_log="
 This file was extended by $as_me, which was
-generated by GNU Autoconf 2.59.  Invocation command line was
+generated by GNU Autoconf 2.59e.  Invocation command line was
 
   CONFIG_FILES    = $CONFIG_FILES
   CONFIG_HEADERS  = $CONFIG_HEADERS
@@ -22433,30 +23916,20 @@
   CONFIG_COMMANDS = $CONFIG_COMMANDS
   $ $0 $@
 
-_CSEOF
-echo "on `(hostname || uname -n) 2>/dev/null | sed 1q`" >&5
-echo >&5
+on `(hostname || uname -n) 2>/dev/null | sed 1q`
+"
+
 _ACEOF
 
+cat >>$CONFIG_STATUS <<_ACEOF
 # Files that config.status was made for.
-if test -n "$ac_config_files"; then
-  echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
-fi
+config_files="$ac_config_files"
+config_headers="$ac_config_headers"
+config_commands="$ac_config_commands"
 
-if test -n "$ac_config_headers"; then
-  echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
-fi
+_ACEOF
 
-if test -n "$ac_config_links"; then
-  echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
-fi
-
-if test -n "$ac_config_commands"; then
-  echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
-fi
-
 cat >>$CONFIG_STATUS <<\_ACEOF
-
 ac_cs_usage="\
 \`$as_me' instantiates files from templates according to the
 current configuration.
@@ -22483,19 +23956,21 @@
 $config_commands
 
 Report bugs to <bug-autoconf at gnu.org>."
+
 _ACEOF
-
 cat >>$CONFIG_STATUS <<_ACEOF
 ac_cs_version="\\
 config.status
-configured by $0, generated by GNU Autoconf 2.59,
-  with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
+configured by $0, generated by GNU Autoconf 2.59e,
+  with options \\"`echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
 
-Copyright (C) 2003 Free Software Foundation, Inc.
+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."
-srcdir=$srcdir
-INSTALL="$INSTALL"
+
+ac_pwd='$ac_pwd'
+srcdir='$srcdir'
+INSTALL='$INSTALL'
 _ACEOF
 
 cat >>$CONFIG_STATUS <<\_ACEOF
@@ -22506,39 +23981,24 @@
 do
   case $1 in
   --*=*)
-    ac_option=`expr "x$1" : 'x\([^=]*\)='`
-    ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
+    ac_option=`expr "X$1" : 'X\([^=]*\)='`
+    ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
     ac_shift=:
     ;;
-  -*)
+  *)
     ac_option=$1
     ac_optarg=$2
     ac_shift=shift
     ;;
-  *) # This is not an option, so the user has probably given explicit
-     # arguments.
-     ac_option=$1
-     ac_need_defaults=false;;
   esac
 
   case $ac_option in
   # Handling of the options.
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF
   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
     ac_cs_recheck=: ;;
-  --version | --vers* | -V )
-    echo "$ac_cs_version"; exit 0 ;;
-  --he | --h)
-    # Conflict between --help and --header
-    { { echo "$as_me:$LINENO: error: ambiguous option: $1
-Try \`$0 --help' for more information." >&5
-echo "$as_me: error: ambiguous option: $1
-Try \`$0 --help' for more information." >&2;}
-   { (exit 1); exit 1; }; };;
-  --help | --hel | -h )
-    echo "$ac_cs_usage"; exit 0 ;;
-  --debug | --d* | -d )
+  --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
@@ -22548,18 +24008,24 @@
     $ac_shift
     CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg"
     ac_need_defaults=false;;
+  --he | --h)
+    # Conflict between --help and --header
+    { echo "$as_me: error: ambiguous option: $1
+Try \`$0 --help' for more information." >&2
+   { (exit 1); exit 1; }; };;
+  --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:$LINENO: error: unrecognized option: $1
-Try \`$0 --help' for more information." >&5
-echo "$as_me: error: unrecognized option: $1
-Try \`$0 --help' for more information." >&2;}
+  -*) { 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_config_targets="$ac_config_targets $1"
+     ac_need_defaults=false ;;
 
   esac
   shift
@@ -22575,76 +24041,88 @@
 _ACEOF
 cat >>$CONFIG_STATUS <<_ACEOF
 if \$ac_cs_recheck; then
-  echo "running $SHELL $0 " $ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6
-  exec $SHELL $0 $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
+  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
 #
-# INIT-COMMANDS section.
+# INIT-COMMANDS
 #
-
 AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
 
 _ACEOF
 
+cat >>$CONFIG_STATUS <<\_ACEOF
 
-
-cat >>$CONFIG_STATUS <<\_ACEOF
+# Handling of arguments.
 for ac_config_target in $ac_config_targets
 do
-  case "$ac_config_target" in
-  # Handling of arguments.
-  "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
-  "libxslt.pc" ) CONFIG_FILES="$CONFIG_FILES libxslt.pc" ;;
-  "libexslt.pc" ) CONFIG_FILES="$CONFIG_FILES libexslt.pc" ;;
-  "libxslt/Makefile" ) CONFIG_FILES="$CONFIG_FILES libxslt/Makefile" ;;
-  "libxslt/xsltconfig.h" ) CONFIG_FILES="$CONFIG_FILES libxslt/xsltconfig.h" ;;
-  "libxslt/xsltwin32config.h" ) CONFIG_FILES="$CONFIG_FILES libxslt/xsltwin32config.h" ;;
-  "libexslt/Makefile" ) CONFIG_FILES="$CONFIG_FILES libexslt/Makefile" ;;
-  "libexslt/exsltconfig.h" ) CONFIG_FILES="$CONFIG_FILES libexslt/exsltconfig.h" ;;
-  "xsltproc/Makefile" ) CONFIG_FILES="$CONFIG_FILES xsltproc/Makefile" ;;
-  "python/Makefile" ) CONFIG_FILES="$CONFIG_FILES python/Makefile" ;;
-  "python/tests/Makefile" ) CONFIG_FILES="$CONFIG_FILES python/tests/Makefile" ;;
-  "tests/Makefile" ) CONFIG_FILES="$CONFIG_FILES tests/Makefile" ;;
-  "tests/docs/Makefile" ) CONFIG_FILES="$CONFIG_FILES tests/docs/Makefile" ;;
-  "tests/REC1/Makefile" ) CONFIG_FILES="$CONFIG_FILES tests/REC1/Makefile" ;;
-  "tests/REC2/Makefile" ) CONFIG_FILES="$CONFIG_FILES tests/REC2/Makefile" ;;
-  "tests/REC/Makefile" ) CONFIG_FILES="$CONFIG_FILES tests/REC/Makefile" ;;
-  "tests/general/Makefile" ) CONFIG_FILES="$CONFIG_FILES tests/general/Makefile" ;;
-  "tests/reports/Makefile" ) CONFIG_FILES="$CONFIG_FILES tests/reports/Makefile" ;;
-  "tests/extensions/Makefile" ) CONFIG_FILES="$CONFIG_FILES tests/extensions/Makefile" ;;
-  "tests/namespaces/Makefile" ) CONFIG_FILES="$CONFIG_FILES tests/namespaces/Makefile" ;;
-  "tests/keys/Makefile" ) CONFIG_FILES="$CONFIG_FILES tests/keys/Makefile" ;;
-  "tests/numbers/Makefile" ) CONFIG_FILES="$CONFIG_FILES tests/numbers/Makefile" ;;
-  "tests/documents/Makefile" ) CONFIG_FILES="$CONFIG_FILES tests/documents/Makefile" ;;
-  "tests/xmlspec/Makefile" ) CONFIG_FILES="$CONFIG_FILES tests/xmlspec/Makefile" ;;
-  "tests/multiple/Makefile" ) CONFIG_FILES="$CONFIG_FILES tests/multiple/Makefile" ;;
-  "tests/xinclude/Makefile" ) CONFIG_FILES="$CONFIG_FILES tests/xinclude/Makefile" ;;
-  "tests/XSLTMark/Makefile" ) CONFIG_FILES="$CONFIG_FILES tests/XSLTMark/Makefile" ;;
-  "tests/docbook/Makefile" ) CONFIG_FILES="$CONFIG_FILES tests/docbook/Makefile" ;;
-  "tests/exslt/Makefile" ) CONFIG_FILES="$CONFIG_FILES tests/exslt/Makefile" ;;
-  "tests/exslt/common/Makefile" ) CONFIG_FILES="$CONFIG_FILES tests/exslt/common/Makefile" ;;
-  "tests/exslt/functions/Makefile" ) CONFIG_FILES="$CONFIG_FILES tests/exslt/functions/Makefile" ;;
-  "tests/exslt/math/Makefile" ) CONFIG_FILES="$CONFIG_FILES tests/exslt/math/Makefile" ;;
-  "tests/exslt/sets/Makefile" ) CONFIG_FILES="$CONFIG_FILES tests/exslt/sets/Makefile" ;;
-  "tests/exslt/strings/Makefile" ) CONFIG_FILES="$CONFIG_FILES tests/exslt/strings/Makefile" ;;
-  "tests/exslt/date/Makefile" ) CONFIG_FILES="$CONFIG_FILES tests/exslt/date/Makefile" ;;
-  "tests/exslt/dynamic/Makefile" ) CONFIG_FILES="$CONFIG_FILES tests/exslt/dynamic/Makefile" ;;
-  "tests/plugins/Makefile" ) CONFIG_FILES="$CONFIG_FILES tests/plugins/Makefile" ;;
-  "doc/Makefile" ) CONFIG_FILES="$CONFIG_FILES doc/Makefile" ;;
-  "xslt-config" ) CONFIG_FILES="$CONFIG_FILES xslt-config" ;;
-  "libxslt.spec" ) CONFIG_FILES="$CONFIG_FILES libxslt.spec" ;;
-  "depfiles" ) CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
-  "config.h" ) CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;;
+  case $ac_config_target in
+    "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;;
+    "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
+    "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
+    "libxslt.pc") CONFIG_FILES="$CONFIG_FILES libxslt.pc" ;;
+    "libexslt.pc") CONFIG_FILES="$CONFIG_FILES libexslt.pc" ;;
+    "libxslt/Makefile") CONFIG_FILES="$CONFIG_FILES libxslt/Makefile" ;;
+    "libxslt/xsltconfig.h") CONFIG_FILES="$CONFIG_FILES libxslt/xsltconfig.h" ;;
+    "libxslt/xsltwin32config.h") CONFIG_FILES="$CONFIG_FILES libxslt/xsltwin32config.h" ;;
+    "libexslt/Makefile") CONFIG_FILES="$CONFIG_FILES libexslt/Makefile" ;;
+    "libexslt/exsltconfig.h") CONFIG_FILES="$CONFIG_FILES libexslt/exsltconfig.h" ;;
+    "xsltproc/Makefile") CONFIG_FILES="$CONFIG_FILES xsltproc/Makefile" ;;
+    "python/Makefile") CONFIG_FILES="$CONFIG_FILES python/Makefile" ;;
+    "python/tests/Makefile") CONFIG_FILES="$CONFIG_FILES python/tests/Makefile" ;;
+    "tests/Makefile") CONFIG_FILES="$CONFIG_FILES tests/Makefile" ;;
+    "tests/docs/Makefile") CONFIG_FILES="$CONFIG_FILES tests/docs/Makefile" ;;
+    "tests/REC1/Makefile") CONFIG_FILES="$CONFIG_FILES tests/REC1/Makefile" ;;
+    "tests/REC2/Makefile") CONFIG_FILES="$CONFIG_FILES tests/REC2/Makefile" ;;
+    "tests/REC/Makefile") CONFIG_FILES="$CONFIG_FILES tests/REC/Makefile" ;;
+    "tests/general/Makefile") CONFIG_FILES="$CONFIG_FILES tests/general/Makefile" ;;
+    "tests/reports/Makefile") CONFIG_FILES="$CONFIG_FILES tests/reports/Makefile" ;;
+    "tests/extensions/Makefile") CONFIG_FILES="$CONFIG_FILES tests/extensions/Makefile" ;;
+    "tests/namespaces/Makefile") CONFIG_FILES="$CONFIG_FILES tests/namespaces/Makefile" ;;
+    "tests/keys/Makefile") CONFIG_FILES="$CONFIG_FILES tests/keys/Makefile" ;;
+    "tests/numbers/Makefile") CONFIG_FILES="$CONFIG_FILES tests/numbers/Makefile" ;;
+    "tests/documents/Makefile") CONFIG_FILES="$CONFIG_FILES tests/documents/Makefile" ;;
+    "tests/xmlspec/Makefile") CONFIG_FILES="$CONFIG_FILES tests/xmlspec/Makefile" ;;
+    "tests/multiple/Makefile") CONFIG_FILES="$CONFIG_FILES tests/multiple/Makefile" ;;
+    "tests/xinclude/Makefile") CONFIG_FILES="$CONFIG_FILES tests/xinclude/Makefile" ;;
+    "tests/XSLTMark/Makefile") CONFIG_FILES="$CONFIG_FILES tests/XSLTMark/Makefile" ;;
+    "tests/docbook/Makefile") CONFIG_FILES="$CONFIG_FILES tests/docbook/Makefile" ;;
+    "tests/exslt/Makefile") CONFIG_FILES="$CONFIG_FILES tests/exslt/Makefile" ;;
+    "tests/exslt/common/Makefile") CONFIG_FILES="$CONFIG_FILES tests/exslt/common/Makefile" ;;
+    "tests/exslt/functions/Makefile") CONFIG_FILES="$CONFIG_FILES tests/exslt/functions/Makefile" ;;
+    "tests/exslt/math/Makefile") CONFIG_FILES="$CONFIG_FILES tests/exslt/math/Makefile" ;;
+    "tests/exslt/sets/Makefile") CONFIG_FILES="$CONFIG_FILES tests/exslt/sets/Makefile" ;;
+    "tests/exslt/strings/Makefile") CONFIG_FILES="$CONFIG_FILES tests/exslt/strings/Makefile" ;;
+    "tests/exslt/date/Makefile") CONFIG_FILES="$CONFIG_FILES tests/exslt/date/Makefile" ;;
+    "tests/exslt/dynamic/Makefile") CONFIG_FILES="$CONFIG_FILES tests/exslt/dynamic/Makefile" ;;
+    "tests/plugins/Makefile") CONFIG_FILES="$CONFIG_FILES tests/plugins/Makefile" ;;
+    "doc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/Makefile" ;;
+    "xslt-config") CONFIG_FILES="$CONFIG_FILES xslt-config" ;;
+    "libxslt.spec") CONFIG_FILES="$CONFIG_FILES libxslt.spec" ;;
+
   *) { { 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
@@ -22656,667 +24134,653 @@
 fi
 
 # Have a temporary directory for convenience.  Make it in the build tree
-# simply because there is no reason to put it here, and in addition,
+# simply because there is no reason against having it here, and in addition,
 # creating and moving files from /tmp can sometimes cause problems.
-# Create a temporary directory, and hook for its removal unless debugging.
+# 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 ||
 {
-  trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
+  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 -q "./confstatXXXXXX") 2>/dev/null` &&
+  tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
   test -n "$tmp" && test -d "$tmp"
 }  ||
 {
-  tmp=./confstat$$-$RANDOM
-  (umask 077 && mkdir $tmp)
+  tmp=./conf$$-$RANDOM
+  (umask 077 && mkdir "$tmp")
 } ||
 {
    echo "$me: cannot create a temporary directory in ." >&2
    { (exit 1); exit 1; }
 }
 
-_ACEOF
-
-cat >>$CONFIG_STATUS <<_ACEOF
-
 #
-# CONFIG_FILES section.
+# 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
-  # Protect against being on the right side of a sed subst in config.status.
-  sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
-   s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
-s, at SHELL@,$SHELL,;t t
-s, at PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
-s, at PACKAGE_NAME@,$PACKAGE_NAME,;t t
-s, at PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
-s, at PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
-s, at PACKAGE_STRING@,$PACKAGE_STRING,;t t
-s, at PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
-s, at exec_prefix@,$exec_prefix,;t t
-s, at prefix@,$prefix,;t t
-s, at program_transform_name@,$program_transform_name,;t t
-s, at bindir@,$bindir,;t t
-s, at sbindir@,$sbindir,;t t
-s, at libexecdir@,$libexecdir,;t t
-s, at datadir@,$datadir,;t t
-s, at sysconfdir@,$sysconfdir,;t t
-s, at sharedstatedir@,$sharedstatedir,;t t
-s, at localstatedir@,$localstatedir,;t t
-s, at libdir@,$libdir,;t t
-s, at includedir@,$includedir,;t t
-s, at oldincludedir@,$oldincludedir,;t t
-s, at infodir@,$infodir,;t t
-s, at mandir@,$mandir,;t t
-s, at build_alias@,$build_alias,;t t
-s, at host_alias@,$host_alias,;t t
-s, at target_alias@,$target_alias,;t t
-s, at DEFS@,$DEFS,;t t
-s, at ECHO_C@,$ECHO_C,;t t
-s, at ECHO_N@,$ECHO_N,;t t
-s, at ECHO_T@,$ECHO_T,;t t
-s, at LIBS@,$LIBS,;t t
-s, at build@,$build,;t t
-s, at build_cpu@,$build_cpu,;t t
-s, at build_vendor@,$build_vendor,;t t
-s, at build_os@,$build_os,;t t
-s, at host@,$host,;t t
-s, at host_cpu@,$host_cpu,;t t
-s, at host_vendor@,$host_vendor,;t t
-s, at host_os@,$host_os,;t t
-s, at LIBXSLT_MAJOR_VERSION@,$LIBXSLT_MAJOR_VERSION,;t t
-s, at LIBXSLT_MINOR_VERSION@,$LIBXSLT_MINOR_VERSION,;t t
-s, at LIBXSLT_MICRO_VERSION@,$LIBXSLT_MICRO_VERSION,;t t
-s, at LIBXSLT_VERSION@,$LIBXSLT_VERSION,;t t
-s, at LIBXSLT_VERSION_INFO@,$LIBXSLT_VERSION_INFO,;t t
-s, at LIBXSLT_VERSION_NUMBER@,$LIBXSLT_VERSION_NUMBER,;t t
-s, at LIBXSLT_VERSION_EXTRA@,$LIBXSLT_VERSION_EXTRA,;t t
-s, at LIBXSLT_MAJOR_MINOR_VERSION@,$LIBXSLT_MAJOR_MINOR_VERSION,;t t
-s, at LIBEXSLT_MAJOR_VERSION@,$LIBEXSLT_MAJOR_VERSION,;t t
-s, at LIBEXSLT_MINOR_VERSION@,$LIBEXSLT_MINOR_VERSION,;t t
-s, at LIBEXSLT_MICRO_VERSION@,$LIBEXSLT_MICRO_VERSION,;t t
-s, at LIBEXSLT_VERSION@,$LIBEXSLT_VERSION,;t t
-s, at LIBEXSLT_VERSION_INFO@,$LIBEXSLT_VERSION_INFO,;t t
-s, at LIBEXSLT_VERSION_NUMBER@,$LIBEXSLT_VERSION_NUMBER,;t t
-s, at LIBEXSLT_VERSION_EXTRA@,$LIBEXSLT_VERSION_EXTRA,;t t
-s, at INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
-s, at INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
-s, at INSTALL_DATA@,$INSTALL_DATA,;t t
-s, at CYGPATH_W@,$CYGPATH_W,;t t
-s, at PACKAGE@,$PACKAGE,;t t
-s, at VERSION@,$VERSION,;t t
-s, at ACLOCAL@,$ACLOCAL,;t t
-s, at AUTOCONF@,$AUTOCONF,;t t
-s, at AUTOMAKE@,$AUTOMAKE,;t t
-s, at AUTOHEADER@,$AUTOHEADER,;t t
-s, at MAKEINFO@,$MAKEINFO,;t t
-s, at install_sh@,$install_sh,;t t
-s, at STRIP@,$STRIP,;t t
-s, at ac_ct_STRIP@,$ac_ct_STRIP,;t t
-s, at INSTALL_STRIP_PROGRAM@,$INSTALL_STRIP_PROGRAM,;t t
-s, at mkdir_p@,$mkdir_p,;t t
-s, at AWK@,$AWK,;t t
-s, at SET_MAKE@,$SET_MAKE,;t t
-s, at am__leading_dot@,$am__leading_dot,;t t
-s, at AMTAR@,$AMTAR,;t t
-s, at am__tar@,$am__tar,;t t
-s, at am__untar@,$am__untar,;t t
-s, at MAINTAINER_MODE_TRUE@,$MAINTAINER_MODE_TRUE,;t t
-s, at MAINTAINER_MODE_FALSE@,$MAINTAINER_MODE_FALSE,;t t
-s, at MAINT@,$MAINT,;t t
-s, at HTML_DIR@,$HTML_DIR,;t t
-s, at CC@,$CC,;t t
-s, at CFLAGS@,$CFLAGS,;t t
-s, at LDFLAGS@,$LDFLAGS,;t t
-s, at CPPFLAGS@,$CPPFLAGS,;t t
-s, at ac_ct_CC@,$ac_ct_CC,;t t
-s, at EXEEXT@,$EXEEXT,;t t
-s, at OBJEXT@,$OBJEXT,;t t
-s, at DEPDIR@,$DEPDIR,;t t
-s, at am__include@,$am__include,;t t
-s, at am__quote@,$am__quote,;t t
-s, at AMDEP_TRUE@,$AMDEP_TRUE,;t t
-s, at AMDEP_FALSE@,$AMDEP_FALSE,;t t
-s, at AMDEPBACKSLASH@,$AMDEPBACKSLASH,;t t
-s, at CCDEPMODE@,$CCDEPMODE,;t t
-s, at am__fastdepCC_TRUE@,$am__fastdepCC_TRUE,;t t
-s, at am__fastdepCC_FALSE@,$am__fastdepCC_FALSE,;t t
-s, at CPP@,$CPP,;t t
-s, at RM@,$RM,;t t
-s, at MV@,$MV,;t t
-s, at TAR@,$TAR,;t t
-s, at EGREP@,$EGREP,;t t
-s, at LN_S@,$LN_S,;t t
-s, at ECHO@,$ECHO,;t t
-s, at AR@,$AR,;t t
-s, at ac_ct_AR@,$ac_ct_AR,;t t
-s, at RANLIB@,$RANLIB,;t t
-s, at ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
-s, at CXX@,$CXX,;t t
-s, at CXXFLAGS@,$CXXFLAGS,;t t
-s, at ac_ct_CXX@,$ac_ct_CXX,;t t
-s, at CXXDEPMODE@,$CXXDEPMODE,;t t
-s, at am__fastdepCXX_TRUE@,$am__fastdepCXX_TRUE,;t t
-s, at am__fastdepCXX_FALSE@,$am__fastdepCXX_FALSE,;t t
-s, at CXXCPP@,$CXXCPP,;t t
-s, at F77@,$F77,;t t
-s, at FFLAGS@,$FFLAGS,;t t
-s, at ac_ct_F77@,$ac_ct_F77,;t t
-s, at LIBTOOL@,$LIBTOOL,;t t
-s, at WITH_TRIO@,$WITH_TRIO,;t t
-s, at PERL@,$PERL,;t t
-s, at WITH_PERL_TRUE@,$WITH_PERL_TRUE,;t t
-s, at WITH_PERL_FALSE@,$WITH_PERL_FALSE,;t t
-s, at PYTHON@,$PYTHON,;t t
-s, at WITH_PYTHON_TRUE@,$WITH_PYTHON_TRUE,;t t
-s, at WITH_PYTHON_FALSE@,$WITH_PYTHON_FALSE,;t t
-s, at pythondir@,$pythondir,;t t
-s, at PYTHON_SUBDIR@,$PYTHON_SUBDIR,;t t
-s, at LIBGCRYPT_CONFIG@,$LIBGCRYPT_CONFIG,;t t
-s, at WITH_CRYPTO@,$WITH_CRYPTO,;t t
-s, at LIBGCRYPT_CFLAGS@,$LIBGCRYPT_CFLAGS,;t t
-s, at LIBGCRYPT_LIBS@,$LIBGCRYPT_LIBS,;t t
-s, at STATIC_BINARIES@,$STATIC_BINARIES,;t t
-s, at WITH_XSLT_DEBUG@,$WITH_XSLT_DEBUG,;t t
-s, at WITH_MEM_DEBUG@,$WITH_MEM_DEBUG,;t t
-s, at WITH_DEBUGGER_TRUE@,$WITH_DEBUGGER_TRUE,;t t
-s, at WITH_DEBUGGER_FALSE@,$WITH_DEBUGGER_FALSE,;t t
-s, at WITH_DEBUGGER@,$WITH_DEBUGGER,;t t
-s, at LIBXML_SRC@,$LIBXML_SRC,;t t
-s, at LIBXML_REQUIRED_VERSION@,$LIBXML_REQUIRED_VERSION,;t t
-s, at WITH_MODULES@,$WITH_MODULES,;t t
-s, at WITH_MODULES_TRUE@,$WITH_MODULES_TRUE,;t t
-s, at WITH_MODULES_FALSE@,$WITH_MODULES_FALSE,;t t
-s, at LIBXSLT_DEFAULT_PLUGINS_PATH@,$LIBXSLT_DEFAULT_PLUGINS_PATH,;t t
-s, at WIN32_EXTRA_LIBADD@,$WIN32_EXTRA_LIBADD,;t t
-s, at WIN32_EXTRA_LDFLAGS@,$WIN32_EXTRA_LDFLAGS,;t t
-s, at XSLTPROCDV@,$XSLTPROCDV,;t t
-s, at PYTHONSODV@,$PYTHONSODV,;t t
-s, at XML_CONFIG@,$XML_CONFIG,;t t
-s, at LIBXML_LIBS@,$LIBXML_LIBS,;t t
-s, at LIBXML_CFLAGS@,$LIBXML_CFLAGS,;t t
-s, at PYTHON_VERSION@,$PYTHON_VERSION,;t t
-s, at PYTHON_INCLUDES@,$PYTHON_INCLUDES,;t t
-s, at PYTHON_SITE_PACKAGES@,$PYTHON_SITE_PACKAGES,;t t
-s, at XSLT_LIBDIR@,$XSLT_LIBDIR,;t t
-s, at XSLT_INCLUDEDIR@,$XSLT_INCLUDEDIR,;t t
-s, at XSLT_LIBS@,$XSLT_LIBS,;t t
-s, at EXSLT_LIBDIR@,$EXSLT_LIBDIR,;t t
-s, at EXSLT_INCLUDEDIR@,$EXSLT_INCLUDEDIR,;t t
-s, at EXSLT_LIBS@,$EXSLT_LIBS,;t t
-s, at EXTRA_LIBS@,$EXTRA_LIBS,;t t
-s, at M_LIBS@,$M_LIBS,;t t
-s, at RELDATE@,$RELDATE,;t t
-s, at LIBOBJS@,$LIBOBJS,;t t
-s, at LTLIBOBJS@,$LTLIBOBJS,;t t
-CEOF
+if test -n "$CONFIG_FILES"; then
 
 _ACEOF
 
-  cat >>$CONFIG_STATUS <<\_ACEOF
-  # Split the substitutions into bite-sized pieces for seds with
-  # small command number limits, like on Digital OSF/1 and HP-UX.
-  ac_max_sed_lines=48
-  ac_sed_frag=1 # Number of current file.
-  ac_beg=1 # First line for current file.
-  ac_end=$ac_max_sed_lines # Line after last line for current file.
-  ac_more_lines=:
-  ac_sed_cmds=
-  while $ac_more_lines; do
-    if test $ac_beg -gt 1; then
-      sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
-    else
-      sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
-    fi
-    if test ! -s $tmp/subs.frag; then
-      ac_more_lines=false
-    else
-      # The purpose of the label and of the branching condition is to
-      # speed up the sed processing (if there are no `@' at all, there
-      # is no need to browse any of the substitutions).
-      # These are the two extra sed commands mentioned above.
-      (echo ':t
-  /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
-      if test -z "$ac_sed_cmds"; then
-	ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
-      else
-	ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
-      fi
-      ac_sed_frag=`expr $ac_sed_frag + 1`
-      ac_beg=$ac_end
-      ac_end=`expr $ac_end + $ac_max_sed_lines`
-    fi
-  done
-  if test -z "$ac_sed_cmds"; then
-    ac_sed_cmds=cat
+
+
+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
+build!$build$ac_delim
+build_cpu!$build_cpu$ac_delim
+build_vendor!$build_vendor$ac_delim
+build_os!$build_os$ac_delim
+host!$host$ac_delim
+host_cpu!$host_cpu$ac_delim
+host_vendor!$host_vendor$ac_delim
+host_os!$host_os$ac_delim
+LIBXSLT_MAJOR_VERSION!$LIBXSLT_MAJOR_VERSION$ac_delim
+LIBXSLT_MINOR_VERSION!$LIBXSLT_MINOR_VERSION$ac_delim
+LIBXSLT_MICRO_VERSION!$LIBXSLT_MICRO_VERSION$ac_delim
+LIBXSLT_VERSION!$LIBXSLT_VERSION$ac_delim
+LIBXSLT_VERSION_INFO!$LIBXSLT_VERSION_INFO$ac_delim
+LIBXSLT_VERSION_NUMBER!$LIBXSLT_VERSION_NUMBER$ac_delim
+LIBXSLT_VERSION_EXTRA!$LIBXSLT_VERSION_EXTRA$ac_delim
+LIBXSLT_MAJOR_MINOR_VERSION!$LIBXSLT_MAJOR_MINOR_VERSION$ac_delim
+LIBEXSLT_MAJOR_VERSION!$LIBEXSLT_MAJOR_VERSION$ac_delim
+LIBEXSLT_MINOR_VERSION!$LIBEXSLT_MINOR_VERSION$ac_delim
+LIBEXSLT_MICRO_VERSION!$LIBEXSLT_MICRO_VERSION$ac_delim
+LIBEXSLT_VERSION!$LIBEXSLT_VERSION$ac_delim
+LIBEXSLT_VERSION_INFO!$LIBEXSLT_VERSION_INFO$ac_delim
+LIBEXSLT_VERSION_NUMBER!$LIBEXSLT_VERSION_NUMBER$ac_delim
+LIBEXSLT_VERSION_EXTRA!$LIBEXSLT_VERSION_EXTRA$ac_delim
+INSTALL_PROGRAM!$INSTALL_PROGRAM$ac_delim
+INSTALL_SCRIPT!$INSTALL_SCRIPT$ac_delim
+INSTALL_DATA!$INSTALL_DATA$ac_delim
+CYGPATH_W!$CYGPATH_W$ac_delim
+PACKAGE!$PACKAGE$ac_delim
+VERSION!$VERSION$ac_delim
+ACLOCAL!$ACLOCAL$ac_delim
+AUTOCONF!$AUTOCONF$ac_delim
+AUTOMAKE!$AUTOMAKE$ac_delim
+AUTOHEADER!$AUTOHEADER$ac_delim
+MAKEINFO!$MAKEINFO$ac_delim
+install_sh!$install_sh$ac_delim
+STRIP!$STRIP$ac_delim
+INSTALL_STRIP_PROGRAM!$INSTALL_STRIP_PROGRAM$ac_delim
+mkdir_p!$mkdir_p$ac_delim
+AWK!$AWK$ac_delim
+SET_MAKE!$SET_MAKE$ac_delim
+am__leading_dot!$am__leading_dot$ac_delim
+AMTAR!$AMTAR$ac_delim
+am__tar!$am__tar$ac_delim
+am__untar!$am__untar$ac_delim
+MAINTAINER_MODE_TRUE!$MAINTAINER_MODE_TRUE$ac_delim
+MAINTAINER_MODE_FALSE!$MAINTAINER_MODE_FALSE$ac_delim
+MAINT!$MAINT$ac_delim
+HTML_DIR!$HTML_DIR$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
+EXEEXT!$EXEEXT$ac_delim
+OBJEXT!$OBJEXT$ac_delim
+DEPDIR!$DEPDIR$ac_delim
+am__include!$am__include$ac_delim
+am__quote!$am__quote$ac_delim
+AMDEP_TRUE!$AMDEP_TRUE$ac_delim
+AMDEP_FALSE!$AMDEP_FALSE$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
-fi # test -n "$CONFIG_FILES"
+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
+AMDEPBACKSLASH!$AMDEPBACKSLASH$ac_delim
+CCDEPMODE!$CCDEPMODE$ac_delim
+am__fastdepCC_TRUE!$am__fastdepCC_TRUE$ac_delim
+am__fastdepCC_FALSE!$am__fastdepCC_FALSE$ac_delim
+CPP!$CPP$ac_delim
+RM!$RM$ac_delim
+MV!$MV$ac_delim
+TAR!$TAR$ac_delim
+GREP!$GREP$ac_delim
+EGREP!$EGREP$ac_delim
+LN_S!$LN_S$ac_delim
+ECHO!$ECHO$ac_delim
+AR!$AR$ac_delim
+RANLIB!$RANLIB$ac_delim
+CXX!$CXX$ac_delim
+CXXFLAGS!$CXXFLAGS$ac_delim
+ac_ct_CXX!$ac_ct_CXX$ac_delim
+CXXDEPMODE!$CXXDEPMODE$ac_delim
+am__fastdepCXX_TRUE!$am__fastdepCXX_TRUE$ac_delim
+am__fastdepCXX_FALSE!$am__fastdepCXX_FALSE$ac_delim
+CXXCPP!$CXXCPP$ac_delim
+F77!$F77$ac_delim
+FFLAGS!$FFLAGS$ac_delim
+ac_ct_F77!$ac_ct_F77$ac_delim
+LIBTOOL!$LIBTOOL$ac_delim
+WITH_TRIO!$WITH_TRIO$ac_delim
+PERL!$PERL$ac_delim
+WITH_PERL_TRUE!$WITH_PERL_TRUE$ac_delim
+WITH_PERL_FALSE!$WITH_PERL_FALSE$ac_delim
+PYTHON!$PYTHON$ac_delim
+WITH_PYTHON_TRUE!$WITH_PYTHON_TRUE$ac_delim
+WITH_PYTHON_FALSE!$WITH_PYTHON_FALSE$ac_delim
+pythondir!$pythondir$ac_delim
+PYTHON_SUBDIR!$PYTHON_SUBDIR$ac_delim
+LIBGCRYPT_CONFIG!$LIBGCRYPT_CONFIG$ac_delim
+WITH_CRYPTO!$WITH_CRYPTO$ac_delim
+LIBGCRYPT_CFLAGS!$LIBGCRYPT_CFLAGS$ac_delim
+LIBGCRYPT_LIBS!$LIBGCRYPT_LIBS$ac_delim
+STATIC_BINARIES!$STATIC_BINARIES$ac_delim
+WITH_XSLT_DEBUG!$WITH_XSLT_DEBUG$ac_delim
+WITH_MEM_DEBUG!$WITH_MEM_DEBUG$ac_delim
+WITH_DEBUGGER_TRUE!$WITH_DEBUGGER_TRUE$ac_delim
+WITH_DEBUGGER_FALSE!$WITH_DEBUGGER_FALSE$ac_delim
+WITH_DEBUGGER!$WITH_DEBUGGER$ac_delim
+LIBXML_SRC!$LIBXML_SRC$ac_delim
+LIBXML_REQUIRED_VERSION!$LIBXML_REQUIRED_VERSION$ac_delim
+WITH_MODULES!$WITH_MODULES$ac_delim
+WITH_MODULES_TRUE!$WITH_MODULES_TRUE$ac_delim
+WITH_MODULES_FALSE!$WITH_MODULES_FALSE$ac_delim
+LIBXSLT_DEFAULT_PLUGINS_PATH!$LIBXSLT_DEFAULT_PLUGINS_PATH$ac_delim
+WIN32_EXTRA_LIBADD!$WIN32_EXTRA_LIBADD$ac_delim
+WIN32_EXTRA_LDFLAGS!$WIN32_EXTRA_LDFLAGS$ac_delim
+XSLTPROCDV!$XSLTPROCDV$ac_delim
+PYTHONSODV!$PYTHONSODV$ac_delim
+XML_CONFIG!$XML_CONFIG$ac_delim
+LIBXML_LIBS!$LIBXML_LIBS$ac_delim
+LIBXML_CFLAGS!$LIBXML_CFLAGS$ac_delim
+PYTHON_VERSION!$PYTHON_VERSION$ac_delim
+PYTHON_INCLUDES!$PYTHON_INCLUDES$ac_delim
+PYTHON_SITE_PACKAGES!$PYTHON_SITE_PACKAGES$ac_delim
+XSLT_LIBDIR!$XSLT_LIBDIR$ac_delim
+XSLT_INCLUDEDIR!$XSLT_INCLUDEDIR$ac_delim
+XSLT_LIBS!$XSLT_LIBS$ac_delim
+EXSLT_LIBDIR!$EXSLT_LIBDIR$ac_delim
+EXSLT_INCLUDEDIR!$EXSLT_INCLUDEDIR$ac_delim
+EXSLT_LIBS!$EXSLT_LIBS$ac_delim
+EXTRA_LIBS!$EXTRA_LIBS$ac_delim
+M_LIBS!$M_LIBS$ac_delim
+RELDATE!$RELDATE$ac_delim
+LIBOBJS!$LIBOBJS$ac_delim
+LTLIBOBJS!$LTLIBOBJS$ac_delim
+_ACEOF
+
+  if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 71; 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
-for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
-  # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
-  case $ac_file in
-  - | *:- | *:-:* ) # input from stdin
-	cat >$tmp/stdin
-	ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
-	ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
-  *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
-	ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
-  * )   ac_file_in=$ac_file.in ;;
+fi # test -n "$CONFIG_FILES"
+
+
+for ac_tag in  :F $CONFIG_FILES  :H $CONFIG_HEADERS    :C $CONFIG_COMMANDS
+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
 
-  # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
-  ac_dir=`(dirname "$ac_file") 2>/dev/null ||
+  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 ||
+	 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'`
-  { if $as_mkdir_p; then
-    mkdir -p "$ac_dir"
-  else
-    as_dir="$ac_dir"
+    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 test ! -d "$as_dir"; do
-      as_dirs="$as_dir $as_dirs"
-      as_dir=`(dirname "$as_dir") 2>/dev/null ||
+    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 ||
+	 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'`
+    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 ! -n "$as_dirs" || mkdir $as_dirs
-  fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
-echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
+    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=.
 
-if test "$ac_dir" != .; then
+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=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
-else
-  ac_dir_suffix= ac_top_builddir=
-fi
+  # 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
-  .)  # No --srcdir option.  We are building in place.
+  .)  # We are building in place.
     ac_srcdir=.
-    if test -z "$ac_top_builddir"; then
-       ac_top_srcdir=.
-    else
-       ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
-    fi ;;
-  [\\/]* | ?:[\\/]* )  # Absolute path.
+    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 ;;
-  *) # Relative path.
-    ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
-    ac_top_srcdir=$ac_top_builddir$srcdir ;;
+    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
 
-# Do not use `cd foo && pwd` to compute absolute paths, because
-# the directories may not exist.
-case `pwd` in
-.) ac_abs_builddir="$ac_dir";;
-*)
-  case "$ac_dir" in
-  .) ac_abs_builddir=`pwd`;;
-  [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
-  *) ac_abs_builddir=`pwd`/"$ac_dir";;
-  esac;;
-esac
-case $ac_abs_builddir in
-.) ac_abs_top_builddir=${ac_top_builddir}.;;
-*)
-  case ${ac_top_builddir}. in
-  .) ac_abs_top_builddir=$ac_abs_builddir;;
-  [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
-  *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
-  esac;;
-esac
-case $ac_abs_builddir in
-.) ac_abs_srcdir=$ac_srcdir;;
-*)
-  case $ac_srcdir in
-  .) ac_abs_srcdir=$ac_abs_builddir;;
-  [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
-  *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
-  esac;;
-esac
-case $ac_abs_builddir in
-.) ac_abs_top_srcdir=$ac_top_srcdir;;
-*)
-  case $ac_top_srcdir in
-  .) ac_abs_top_srcdir=$ac_abs_builddir;;
-  [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
-  *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
-  esac;;
-esac
 
+  case $ac_mode in
+  :F)
+  #
+  # CONFIG_FILE
+  #
 
   case $INSTALL in
   [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
-  *) ac_INSTALL=$ac_top_builddir$INSTALL ;;
+  *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
   esac
+_ACEOF
 
-  # 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.  */
-  if test x"$ac_file" = x-; then
-    configure_input=
-  else
-    configure_input="$ac_file.  "
-  fi
-  configure_input=$configure_input"Generated from `echo $ac_file_in |
-				     sed 's,.*/,,'` by configure."
+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=
 
-  # First look for the input files in the build tree, otherwise in the
-  # src tree.
-  ac_file_inputs=`IFS=:
-    for f in $ac_file_in; do
-      case $f in
-      -) echo $tmp/stdin ;;
-      [\\/$]*)
-	 # Absolute (can't be DOS-style, as IFS=:)
-	 test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
-echo "$as_me: error: cannot find input file: $f" >&2;}
-   { (exit 1); exit 1; }; }
-	 echo "$f";;
-      *) # Relative
-	 if test -f "$f"; then
-	   # Build tree
-	   echo "$f"
-	 elif test -f "$srcdir/$f"; then
-	   # Source tree
-	   echo "$srcdir/$f"
-	 else
-	   # /dev/null tree
-	   { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
-echo "$as_me: error: cannot find input file: $f" >&2;}
-   { (exit 1); exit 1; }; }
-	 fi;;
-      esac
-    done` || { (exit 1); exit 1; }
-
-  if test x"$ac_file" != x-; then
-    { echo "$as_me:$LINENO: creating $ac_file" >&5
-echo "$as_me: creating $ac_file" >&6;}
-    rm -f "$ac_file"
-  fi
+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, at configure_input@,$configure_input,;t t
-s, at srcdir@,$ac_srcdir,;t t
-s, at abs_srcdir@,$ac_abs_srcdir,;t t
-s, at top_srcdir@,$ac_top_srcdir,;t t
-s, at abs_top_srcdir@,$ac_abs_top_srcdir,;t t
-s, at builddir@,$ac_builddir,;t t
-s, at abs_builddir@,$ac_abs_builddir,;t t
-s, at top_builddir@,$ac_top_builddir,;t t
-s, at abs_top_builddir@,$ac_abs_top_builddir,;t t
-s, at INSTALL@,$ac_INSTALL,;t t
-" $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
-  rm -f $tmp/stdin
-  if test x"$ac_file" != x-; then
-    mv $tmp/out $ac_file
-  else
-    cat $tmp/out
-    rm -f $tmp/out
-  fi
+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
 
-done
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF
+test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
+  { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$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;}
 
-#
-# CONFIG_HEADER section.
-#
-
-# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
-# NAME is the cpp macro being defined and VALUE is the value it is being given.
-#
-# ac_d sets the value in "#define NAME VALUE" lines.
-ac_dA='s,^\([	 ]*\)#\([	 ]*define[	 ][	 ]*\)'
-ac_dB='[	 ].*$,\1#\2'
-ac_dC=' '
-ac_dD=',;t'
-# ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
-ac_uA='s,^\([	 ]*\)#\([	 ]*\)undef\([	 ][	 ]*\)'
-ac_uB='$,\1#\2define\3'
-ac_uC=' '
-ac_uD=',;t'
-
-for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
-  # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
+  rm -f "$tmp/stdin"
   case $ac_file in
-  - | *:- | *:-:* ) # input from stdin
-	cat >$tmp/stdin
-	ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
-	ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
-  *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
-	ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
-  * )   ac_file_in=$ac_file.in ;;
+  -) cat "$tmp/out"; rm -f "$tmp/out";;
+  *) rm -f "$ac_file"; mv "$tmp/out" $ac_file;;
   esac
+ ;;
+  :H)
+  #
+  # CONFIG_HEADER
+  #
+_ACEOF
 
-  test x"$ac_file" != x- && { echo "$as_me:$LINENO: creating $ac_file" >&5
-echo "$as_me: creating $ac_file" >&6;}
+# Transform confdefs.h into a sed script `conftest.defines', that
+# substitutes the proper values into config.h.in to produce config.h.
+rm -f conftest.defines conftest.tail
+# First, append a space to every undef/define line, to ease matching.
+echo 's/$/ /' >conftest.defines
+# Then, protect against being on the right side of a sed subst, or in
+# an unquoted here document, in config.status.  If some macros were
+# called several times there might be several #defines for the same
+# symbol, which is useless.  But do not sort them, since the last
+# AC_DEFINE must be honored.
+ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
+# These sed commands are passed to sed as "A NAME B PARAMS C VALUE D", where
+# NAME is the cpp macro being defined, VALUE is the value it is being given.
+# PARAMS is the parameter list in the macro definition--in most cases, it's
+# just an empty string.
+ac_dA='s,^\\([	 #]*\\)[^	 ]*\\([	 ]*'
+ac_dB='\\)[	 (].*,\\1define\\2'
+ac_dC=' '
+ac_dD=' ,'
 
-  # First look for the input files in the build tree, otherwise in the
-  # src tree.
-  ac_file_inputs=`IFS=:
-    for f in $ac_file_in; do
-      case $f in
-      -) echo $tmp/stdin ;;
-      [\\/$]*)
-	 # Absolute (can't be DOS-style, as IFS=:)
-	 test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
-echo "$as_me: error: cannot find input file: $f" >&2;}
-   { (exit 1); exit 1; }; }
-	 # Do quote $f, to prevent DOS paths from being IFS'd.
-	 echo "$f";;
-      *) # Relative
-	 if test -f "$f"; then
-	   # Build tree
-	   echo "$f"
-	 elif test -f "$srcdir/$f"; then
-	   # Source tree
-	   echo "$srcdir/$f"
-	 else
-	   # /dev/null tree
-	   { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
-echo "$as_me: error: cannot find input file: $f" >&2;}
-   { (exit 1); exit 1; }; }
-	 fi;;
-      esac
-    done` || { (exit 1); exit 1; }
-  # Remove the trailing spaces.
-  sed 's/[	 ]*$//' $ac_file_inputs >$tmp/in
+uniq confdefs.h |
+  sed -n '
+	t rset
+	:rset
+	s/^[	 ]*#[	 ]*define[	 ][	 ]*//
+	t ok
+	d
+	:ok
+	s/[\\&,]/\\&/g
+	s/^\('"$ac_word_re"'\)\(([^()]*)\)[	 ]*\(.*\)/ '"$ac_dA"'\1'"$ac_dB"'\2'"${ac_dC}"'\3'"$ac_dD"'/p
+	s/^\('"$ac_word_re"'\)[	 ]*\(.*\)/'"$ac_dA"'\1'"$ac_dB$ac_dC"'\2'"$ac_dD"'/p
+  ' >>conftest.defines
 
-_ACEOF
-
-# Transform confdefs.h into two sed scripts, `conftest.defines' and
-# `conftest.undefs', that substitutes the proper values into
-# config.h.in to produce config.h.  The first handles `#define'
-# templates, and the second `#undef' templates.
-# And first: Protect against being on the right side of a sed subst in
-# config.status.  Protect against being in an unquoted here document
-# in config.status.
-rm -f conftest.defines conftest.undefs
-# Using a here document instead of a string reduces the quoting nightmare.
-# Putting comments in sed scripts is not portable.
-#
-# `end' is used to avoid that the second main sed command (meant for
-# 0-ary CPP macros) applies to n-ary macro definitions.
-# See the Autoconf documentation for `clear'.
-cat >confdef2sed.sed <<\_ACEOF
-s/[\\&,]/\\&/g
-s,[\\$`],\\&,g
-t clear
-: clear
-s,^[	 ]*#[	 ]*define[	 ][	 ]*\([^	 (][^	 (]*\)\(([^)]*)\)[	 ]*\(.*\)$,${ac_dA}\1${ac_dB}\1\2${ac_dC}\3${ac_dD},gp
-t end
-s,^[	 ]*#[	 ]*define[	 ][	 ]*\([^	 ][^	 ]*\)[	 ]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
-: end
-_ACEOF
-# If some macros were called several times there might be several times
-# the same #defines, which is useless.  Nevertheless, we may not want to
-# sort them, since we want the *last* AC-DEFINE to be honored.
-uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
-sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
-rm -f confdef2sed.sed
-
-# This sed command replaces #undef with comments.  This is necessary, for
+# Remove the space that was appended to ease matching.
+# Then replace #undef with comments.  This is necessary, for
 # example, in the case of _POSIX_SOURCE, which is predefined and required
 # on some systems where configure will not decide to define it.
-cat >>conftest.undefs <<\_ACEOF
-s,^[	 ]*#[	 ]*undef[	 ][	 ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
-_ACEOF
+# (The regexp can be short, since the line contains either #define or #undef.)
+echo 's/ $//
+s,^[	 #]*u.*,/* & */,' >>conftest.defines
 
-# Break up conftest.defines because some shells have a limit on the size
-# of here documents, and old seds have small limits too (100 cmds).
-echo '  # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS
-echo '  if grep "^[	 ]*#[	 ]*define" $tmp/in >/dev/null; then' >>$CONFIG_STATUS
-echo '  # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS
-echo '  :' >>$CONFIG_STATUS
-rm -f conftest.tail
-while grep . conftest.defines >/dev/null
+# Break up conftest.defines:
+ac_max_sed_lines=50
+
+# First sed command is:	 sed -f defines.sed $ac_file_inputs >"$tmp/out1"
+# Second one is:	 sed -f defines.sed "$tmp/out1" >"$tmp/out2"
+# Third one will be:	 sed -f defines.sed "$tmp/out2" >"$tmp/out1"
+# et cetera.
+ac_in='$ac_file_inputs'
+ac_out='"$tmp/out1"'
+ac_nxt='"$tmp/out2"'
+
+while :
 do
-  # Write a limited-size here document to $tmp/defines.sed.
-  echo '  cat >$tmp/defines.sed <<CEOF' >>$CONFIG_STATUS
-  # Speed up: don't consider the non `#define' lines.
-  echo '/^[	 ]*#[	 ]*define/!b' >>$CONFIG_STATUS
-  # Work around the forget-to-reset-the-flag bug.
-  echo 't clr' >>$CONFIG_STATUS
-  echo ': clr' >>$CONFIG_STATUS
-  sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS
+  # Write a here document:
+    cat >>$CONFIG_STATUS <<_ACEOF
+    # First, check the format of the line:
+    cat >"\$tmp/defines.sed" <<\\CEOF
+/^[	 ]*#[	 ]*undef[	 ][	 ]*$ac_word_re[	 ]*\$/b def
+/^[	 ]*#[	 ]*define[	 ][	 ]*$ac_word_re[(	 ]/b def
+b
+:def
+_ACEOF
+  sed ${ac_max_sed_lines}q conftest.defines >>$CONFIG_STATUS
   echo 'CEOF
-  sed -f $tmp/defines.sed $tmp/in >$tmp/out
-  rm -f $tmp/in
-  mv $tmp/out $tmp/in
-' >>$CONFIG_STATUS
-  sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail
+    sed -f "$tmp/defines.sed"' "$ac_in >$ac_out" >>$CONFIG_STATUS
+  ac_in=$ac_out; ac_out=$ac_nxt; ac_nxt=$ac_in
+  sed 1,${ac_max_sed_lines}d conftest.defines >conftest.tail
+  grep . conftest.tail >/dev/null || break
   rm -f conftest.defines
   mv conftest.tail conftest.defines
 done
-rm -f conftest.defines
-echo '  fi # grep' >>$CONFIG_STATUS
-echo >>$CONFIG_STATUS
+rm -f conftest.defines conftest.tail
 
-# Break up conftest.undefs because some shells have a limit on the size
-# of here documents, and old seds have small limits too (100 cmds).
-echo '  # Handle all the #undef templates' >>$CONFIG_STATUS
-rm -f conftest.tail
-while grep . conftest.undefs >/dev/null
-do
-  # Write a limited-size here document to $tmp/undefs.sed.
-  echo '  cat >$tmp/undefs.sed <<CEOF' >>$CONFIG_STATUS
-  # Speed up: don't consider the non `#undef'
-  echo '/^[	 ]*#[	 ]*undef/!b' >>$CONFIG_STATUS
-  # Work around the forget-to-reset-the-flag bug.
-  echo 't clr' >>$CONFIG_STATUS
-  echo ': clr' >>$CONFIG_STATUS
-  sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS
-  echo 'CEOF
-  sed -f $tmp/undefs.sed $tmp/in >$tmp/out
-  rm -f $tmp/in
-  mv $tmp/out $tmp/in
-' >>$CONFIG_STATUS
-  sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail
-  rm -f conftest.undefs
-  mv conftest.tail conftest.undefs
-done
-rm -f conftest.undefs
-
+echo "ac_result=$ac_in" >>$CONFIG_STATUS
 cat >>$CONFIG_STATUS <<\_ACEOF
-  # 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.  */
-  if test x"$ac_file" = x-; then
-    echo "/* Generated by configure.  */" >$tmp/config.h
-  else
-    echo "/* $ac_file.  Generated by configure.  */" >$tmp/config.h
-  fi
-  cat $tmp/in >>$tmp/config.h
-  rm -f $tmp/in
   if test x"$ac_file" != x-; then
-    if diff $ac_file $tmp/config.h >/dev/null 2>&1; then
+    echo "/* $configure_input  */" >"$tmp/config.h"
+    cat "$ac_result" >>"$tmp/config.h"
+    if diff $ac_file "$tmp/config.h" >/dev/null 2>&1; then
       { echo "$as_me:$LINENO: $ac_file is unchanged" >&5
 echo "$as_me: $ac_file is unchanged" >&6;}
     else
-      ac_dir=`(dirname "$ac_file") 2>/dev/null ||
-$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'`
-      { if $as_mkdir_p; then
-    mkdir -p "$ac_dir"
-  else
-    as_dir="$ac_dir"
-    as_dirs=
-    while test ! -d "$as_dir"; do
-      as_dirs="$as_dir $as_dirs"
-      as_dir=`(dirname "$as_dir") 2>/dev/null ||
-$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'`
-    done
-    test ! -n "$as_dirs" || mkdir $as_dirs
-  fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
-echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
-   { (exit 1); exit 1; }; }; }
-
       rm -f $ac_file
-      mv $tmp/config.h $ac_file
+      mv "$tmp/config.h" $ac_file
     fi
   else
-    cat $tmp/config.h
-    rm -f $tmp/config.h
+    echo "/* $configure_input  */"
+    cat "$ac_result"
   fi
+  rm -f "$tmp/out12"
 # Compute $ac_file's index in $config_headers.
 _am_stamp_count=1
 for _am_header in $config_headers :; do
@@ -23327,135 +24791,39 @@
       _am_stamp_count=`expr $_am_stamp_count + 1` ;;
   esac
 done
-echo "timestamp for $ac_file" >`(dirname $ac_file) 2>/dev/null ||
+echo "timestamp for $ac_file" >`$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 ||
+	 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'`/stamp-h$_am_stamp_count
-done
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF
+    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
+	    s//\1/
+	    q
+	  }
+	  /^X\(\/\/\)[^/].*/{
+	    s//\1/
+	    q
+	  }
+	  /^X\(\/\/\)$/{
+	    s//\1/
+	    q
+	  }
+	  /^X\(\/\).*/{
+	    s//\1/
+	    q
+	  }
+	  s/.*/./; q'`/stamp-h$_am_stamp_count
+ ;;
 
-#
-# CONFIG_COMMANDS section.
-#
-for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
-  ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
-  ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
-  ac_dir=`(dirname "$ac_dest") 2>/dev/null ||
-$as_expr X"$ac_dest" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
-	 X"$ac_dest" : 'X\(//\)[^/]' \| \
-	 X"$ac_dest" : 'X\(//\)$' \| \
-	 X"$ac_dest" : 'X\(/\)' \| \
-	 .     : '\(.\)' 2>/dev/null ||
-echo X"$ac_dest" |
-    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
-  	  /^X\(\/\/\)[^/].*/{ s//\1/; q; }
-  	  /^X\(\/\/\)$/{ s//\1/; q; }
-  	  /^X\(\/\).*/{ s//\1/; q; }
-  	  s/.*/./; q'`
-  { if $as_mkdir_p; then
-    mkdir -p "$ac_dir"
-  else
-    as_dir="$ac_dir"
-    as_dirs=
-    while test ! -d "$as_dir"; do
-      as_dirs="$as_dir $as_dirs"
-      as_dir=`(dirname "$as_dir") 2>/dev/null ||
-$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'`
-    done
-    test ! -n "$as_dirs" || mkdir $as_dirs
-  fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
-echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
-   { (exit 1); exit 1; }; }; }
+  :C)  { echo "$as_me:$LINENO: executing $ac_file commands" >&5
+echo "$as_me: executing $ac_file commands" >&6;}
+ ;;
+  esac
 
-  ac_builddir=.
 
-if test "$ac_dir" != .; then
-  ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
-  # A "../" for each directory in $ac_dir_suffix.
-  ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
-else
-  ac_dir_suffix= ac_top_builddir=
-fi
-
-case $srcdir in
-  .)  # No --srcdir option.  We are building in place.
-    ac_srcdir=.
-    if test -z "$ac_top_builddir"; then
-       ac_top_srcdir=.
-    else
-       ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
-    fi ;;
-  [\\/]* | ?:[\\/]* )  # Absolute path.
-    ac_srcdir=$srcdir$ac_dir_suffix;
-    ac_top_srcdir=$srcdir ;;
-  *) # Relative path.
-    ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
-    ac_top_srcdir=$ac_top_builddir$srcdir ;;
-esac
-
-# Do not use `cd foo && pwd` to compute absolute paths, because
-# the directories may not exist.
-case `pwd` in
-.) ac_abs_builddir="$ac_dir";;
-*)
-  case "$ac_dir" in
-  .) ac_abs_builddir=`pwd`;;
-  [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
-  *) ac_abs_builddir=`pwd`/"$ac_dir";;
-  esac;;
-esac
-case $ac_abs_builddir in
-.) ac_abs_top_builddir=${ac_top_builddir}.;;
-*)
-  case ${ac_top_builddir}. in
-  .) ac_abs_top_builddir=$ac_abs_builddir;;
-  [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
-  *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
-  esac;;
-esac
-case $ac_abs_builddir in
-.) ac_abs_srcdir=$ac_srcdir;;
-*)
-  case $ac_srcdir in
-  .) ac_abs_srcdir=$ac_abs_builddir;;
-  [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
-  *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
-  esac;;
-esac
-case $ac_abs_builddir in
-.) ac_abs_top_srcdir=$ac_top_srcdir;;
-*)
-  case $ac_top_srcdir in
-  .) ac_abs_top_srcdir=$ac_abs_builddir;;
-  [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
-  *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
-  esac;;
-esac
-
-
-  { echo "$as_me:$LINENO: executing $ac_dest commands" >&5
-echo "$as_me: executing $ac_dest commands" >&6;}
-  case $ac_dest in
-    depfiles ) test x"$AMDEP_TRUE" != x"" || for mf in $CONFIG_FILES; do
+  case $ac_file$ac_mode in
+    "depfiles":C) test x"$AMDEP_TRUE" != x"" || for mf in $CONFIG_FILES; do
   # Strip MF so we end up with the name of the file.
   mf=`echo "$mf" | sed -e 's/:.*$//'`
   # Check whether this is an Automake generated Makefile or not.
@@ -23465,18 +24833,29 @@
   # each Makefile.in and add a new line on top of each file to say so.
   # So let's grep whole file.
   if grep '^#.*generated by automake' $mf > /dev/null 2>&1; then
-    dirpart=`(dirname "$mf") 2>/dev/null ||
+    dirpart=`$as_dirname -- "$mf" ||
 $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
 	 X"$mf" : 'X\(//\)[^/]' \| \
 	 X"$mf" : 'X\(//\)$' \| \
-	 X"$mf" : 'X\(/\)' \| \
-	 .     : '\(.\)' 2>/dev/null ||
+	 X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
 echo X"$mf" |
-    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
-  	  /^X\(\/\/\)[^/].*/{ s//\1/; q; }
-  	  /^X\(\/\/\)$/{ s//\1/; q; }
-  	  /^X\(\/\).*/{ s//\1/; q; }
-  	  s/.*/./; q'`
+    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
+	    s//\1/
+	    q
+	  }
+	  /^X\(\/\/\)[^/].*/{
+	    s//\1/
+	    q
+	  }
+	  /^X\(\/\/\)$/{
+	    s//\1/
+	    q
+	  }
+	  /^X\(\/\).*/{
+	    s//\1/
+	    q
+	  }
+	  s/.*/./; q'`
   else
     continue
   fi
@@ -23498,53 +24877,79 @@
        sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
     # Make sure the directory exists.
     test -f "$dirpart/$file" && continue
-    fdir=`(dirname "$file") 2>/dev/null ||
+    fdir=`$as_dirname -- "$file" ||
 $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
 	 X"$file" : 'X\(//\)[^/]' \| \
 	 X"$file" : 'X\(//\)$' \| \
-	 X"$file" : 'X\(/\)' \| \
-	 .     : '\(.\)' 2>/dev/null ||
+	 X"$file" : 'X\(/\)' \| . 2>/dev/null ||
 echo X"$file" |
-    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
-  	  /^X\(\/\/\)[^/].*/{ s//\1/; q; }
-  	  /^X\(\/\/\)$/{ s//\1/; q; }
-  	  /^X\(\/\).*/{ s//\1/; q; }
-  	  s/.*/./; q'`
-    { if $as_mkdir_p; then
-    mkdir -p $dirpart/$fdir
-  else
-    as_dir=$dirpart/$fdir
+    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
+	    s//\1/
+	    q
+	  }
+	  /^X\(\/\/\)[^/].*/{
+	    s//\1/
+	    q
+	  }
+	  /^X\(\/\/\)$/{
+	    s//\1/
+	    q
+	  }
+	  /^X\(\/\).*/{
+	    s//\1/
+	    q
+	  }
+	  s/.*/./; q'`
+    { as_dir=$dirpart/$fdir
+  case $as_dir in #(
+  -*) as_dir=./$as_dir;;
+  esac
+  test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || {
     as_dirs=
-    while test ! -d "$as_dir"; do
-      as_dirs="$as_dir $as_dirs"
-      as_dir=`(dirname "$as_dir") 2>/dev/null ||
+    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 ||
+	 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'`
+    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 ! -n "$as_dirs" || mkdir $as_dirs
-  fi || { { echo "$as_me:$LINENO: error: cannot create directory $dirpart/$fdir" >&5
-echo "$as_me: error: cannot create directory $dirpart/$fdir" >&2;}
+    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; }; }; }
-
     # echo "creating $dirpart/$file"
     echo '# dummy' > "$dirpart/$file"
   done
 done
  ;;
+
   esac
-done
-_ACEOF
+done # for ac_tag
 
-cat >>$CONFIG_STATUS <<\_ACEOF
 
 { (exit 0); exit 0; }
 _ACEOF

Modified: packages/libxslt/trunk/configure.in
===================================================================
--- packages/libxslt/trunk/configure.in	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/configure.in	2006-06-08 22:29:07 UTC (rev 565)
@@ -10,12 +10,12 @@
 dnl
 LIBXSLT_MAJOR_VERSION=1
 LIBXSLT_MINOR_VERSION=1
-LIBXSLT_MICRO_VERSION=16
+LIBXSLT_MICRO_VERSION=17
 PACKAGE=libxslt
 LIBEXSLT_MAJOR_VERSION=0
 LIBEXSLT_MINOR_VERSION=8
 LIBEXSLT_MICRO_VERSION=13
-LIBXML_REQUIRED_VERSION=2.6.17 # if you need module support.
+LIBXML_REQUIRED_VERSION=2.6.25
 
 
 LIBXSLT_VERSION=$LIBXSLT_MAJOR_VERSION.$LIBXSLT_MINOR_VERSION.$LIBXSLT_MICRO_VERSION
@@ -223,7 +223,7 @@
     fi
     if test "$with_python" != ""
     then
-        pythondir=$(PYTHON_SITE_PACKAGES)
+        pythondir='$(PYTHON_SITE_PACKAGES)'
     else
         pythondir='$(libdir)/python$(PYTHON_VERSION)/site-packages'
     fi

Modified: packages/libxslt/trunk/debian/changelog
===================================================================
--- packages/libxslt/trunk/debian/changelog	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/debian/changelog	2006-06-08 22:29:07 UTC (rev 565)
@@ -1,3 +1,11 @@
+libxslt (1.1.17-1) unstable; urgency=low
+
+  * New upstream release.
+  * debian/control: Build depend on libxml2 >= 2.6.25, and adapt other
+    dependencies accordingly.
+
+ -- Mike Hommey <glandium at debian.org>  Thu,  8 Jun 2006 23:45:23 +0200
+
 libxslt (1.1.16-2) unstable; urgency=high
 
   * Urgency set to high, since we fix a serious bug.

Modified: packages/libxslt/trunk/debian/control
===================================================================
--- packages/libxslt/trunk/debian/control	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/debian/control	2006-06-08 22:29:07 UTC (rev 565)
@@ -4,7 +4,7 @@
 Maintainer: Debian XML/SGML Group <debian-xml-sgml-pkgs at lists.alioth.debian.org>
 Uploaders: Mike Hommey <glandium at debian.org>
 Standards-Version: 3.7.2.0
-Build-Depends: debhelper (>= 5.0.0), libxml2-dev (>= 2.6.17), python, python2.4-dev, python2.3-dev, python2.4-libxml2 (>= 2.6.17), python2.3-libxml2 (>= 2.6.17), zlib1g-dev | libz-dev, libgcrypt11-dev, autotools-dev, binutils (>= 2.14.90.0.7)
+Build-Depends: debhelper (>= 5.0.0), libxml2-dev (>= 2.6.25), python, python2.4-dev, python2.3-dev, python2.4-libxml2 (>= 2.6.25), python2.3-libxml2 (>= 2.6.25), zlib1g-dev | libz-dev, libgcrypt11-dev, autotools-dev, binutils (>= 2.14.90.0.7)
 
 Package: libxslt1.1
 Section: libs
@@ -25,7 +25,7 @@
 Architecture: any
 Provides: libxslt-dev
 Conflicts: libxslt-dev, libxslt0-dev
-Depends: libxslt1.1 (= ${Source-Version}), libxml2-dev (>= 2.6.17), zlib1g-dev | libz-dev, libgcrypt11-dev
+Depends: libxslt1.1 (= ${Source-Version}), libxml2-dev (>= 2.6.25), zlib1g-dev | libz-dev, libgcrypt11-dev
 Description: XSLT processing library - development kit
  XSLT is an XML language for defining transformations of XML files from
  XML to some other arbitrary format, such as XML, HTML, plain text, etc.
@@ -72,7 +72,7 @@
 Package: python2.4-libxslt1
 Section: python
 Architecture: any
-Depends: ${shlibs:Depends}, python2.4-libxml2 (>= 2.6.17), python2.4
+Depends: ${shlibs:Depends}, python2.4-libxml2 (>= 2.6.25), python2.4
 Description:  Python 2.4 bindings for libxslt1
  XSLT is an XML language for defining transformations of XML files from
  XML to some other arbitrary format, such as XML, HTML, plain text, etc.
@@ -85,7 +85,7 @@
 Package: python2.3-libxslt1
 Section: python
 Architecture: any
-Depends: ${shlibs:Depends}, python2.3-libxml2 (>= 2.6.17), python2.3
+Depends: ${shlibs:Depends}, python2.3-libxml2 (>= 2.6.25), python2.3
 Description:  Python 2.3 bindings for libxslt1
  XSLT is an XML language for defining transformations of XML files from
  XML to some other arbitrary format, such as XML, HTML, plain text, etc.

Modified: packages/libxslt/trunk/doc/API.html
===================================================================
--- packages/libxslt/trunk/doc/API.html	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/doc/API.html	2006-06-08 22:29:07 UTC (rev 565)
@@ -8,19 +8,19 @@
 H3 {font-family: Verdana,Arial,Helvetica}
 A:link, A:visited, A:active { text-decoration: underline }
     </style><title>The programming API</title></head><body bgcolor="#8b7765" text="#000000" link="#a06060" vlink="#000000"><table border="0" width="100%" cellpadding="5" cellspacing="0" align="center"><tr><td width="120"><a href="http://swpat.ffii.org/"><img src="epatents.png" alt="Action against software patents" /></a></td><td width="180"><a href="http://www.gnome.org/"><img src="gnome2.png" alt="Gnome2 Logo" /></a><a href="http://www.w3.org/Status"><img src="w3c.png" alt="W3C logo" /></a><a href="http://www.redhat.com"><img src="redhat.gif" alt="Red Hat Logo" /></a><div align="left"><a href="http://xmlsoft.org/XSLT/"><img src="Libxslt-Logo-180x168.gif" alt="Made with Libxslt Logo" /></a></div></td><td><table border="0" width="90%" cellpadding="2" cellspacing="0" align="center" bgcolor="#000000"><tr><td><table width="100%" border="0" cellspacing="1" cellpadding="3" bgcolor="#fffacd"><tr><td align="center"><h1>The XSLT C library for Gnome</h1><h2>The programming API</h2></td></tr></table></td></tr></table></td></tr></table><table border="0" cellpadding="4" cellspacing="0" width="100%" align="center"><tr><td bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="2" width="100%"><tr><td valign="top" width="200" bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000"><tr><td><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>Main Menu</b></center></td></tr><tr><td bgcolor="#fffacd"><form action="search.php" enctype="application/x-www-form-urlencoded" method="get"><input name="query" type="text" size="20" value="" /><input name="submit" type="submit" value="Search ..." /></form><ul><li><a href="index.html">Home</a></li><li><a href="http://xmlsoft.org/wiki">Wiki</a></li><li><a href="intro.html">Introduction</a></li><li><a href="docs.html">Documentation</a></li><li><a href="bugs.html">Reporting bugs and getting help</a></li><li><a href="help.html">How to help</a></li><li><a href="downloads.html">Downloads</a></li><li><a href="FAQ.html">FAQ</a></li><li><a href="news.html">News</a></li><li><a href="xsltproc2.html">The xsltproc tool</a></li><li><a href="docbook.html">DocBook</a></li><li><a href="API.html">The programming API</a></li><li><a href="python.html">Python and bindings</a></li><li><a href="internals.html">Library internals</a></li><li><a href="extensions.html">Writing extensions</a></li><li><a href="contribs.html">Contributions</a></li><li><a href="EXSLT/index.html" style="font-weight:bold">libexslt</a></li><li><a href="xslt.html">flat page</a>, <a href="site.xsl">stylesheet</a></li><li><a href="html/index.html" style="font-weight:bold">API Menu</a></li><li><a href="ChangeLog.html">ChangeLog</a></li></ul></td></tr></table><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>Related links</b></center></td></tr><tr><td bgcolor="#fffacd"><ul><li><a href="tutorial/libxslttutorial.html">Tutorial</a>,
-          <a href="tutorial2/libxslt_pipes.html">Tutorial2</a></li><li><a href="xsltproc.html">Man page for xsltproc</a></li><li><a href="http://mail.gnome.org/archives/xslt/">Mail archive</a></li><li><a href="http://xmlsoft.org/">XML libxml2</a></li><li><a href="ftp://xmlsoft.org/">FTP</a></li><li><a href="http://www.zlatkovic.com/projects/libxml/">Windows binaries</a></li><li><a href="http://garypennington.net/libxml2/">Solaris binaries</a></li><li><a href="http://www.explain.com.au/oss/libxml2xslt.html">MacOsX binaries</a></li><li><a href="http://bugzilla.gnome.org/buglist.cgi?product=libxslt">Bug Tracker</a></li><li><a href="http://www.zend.com/php5/articles/php5-xmlphp.php#Heading17">XSLT with PHP</a></li><li><a href="http://www.mod-xslt2.com/">Apache module</a></li><li><a href="http://sourceforge.net/projects/libxml2-pas/">Pascal bindings</a></li><li><a href="http://xsldbg.sourceforge.net/">Xsldbg Debugger</a></li></ul></td></tr></table><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>API Indexes</b></center></td></tr><tr><td bgcolor="#fffacd"><ul><li><a href="APIchunk0.html">Alphabetic</a></li><li><a href="APIconstructors.html">Constructors</a></li><li><a href="APIfunctions.html">Functions/Types</a></li><li><a href="APIfiles.html">Modules</a></li><li><a href="APIsymbols.html">Symbols</a></li></ul></td></tr></table></td></tr></table></td><td valign="top" bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="1" width="100%"><tr><td><table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000"><tr><td><table border="0" cellpadding="3" cellspacing="1" width="100%"><tr><td bgcolor="#fffacd"><p>Okay this section is clearly incomplete. But integrating libxslt into your
-application should be relatively easy. First check the few steps described
-below, then for more detailed informations, look at the<a href="html/libxslt-lib.html"> generated pages</a> for the API and the source
-of libxslt/xsltproc.c  and the  <a href="tutorial/libxslttutorial.html">tutorial</a>.</p><p>Basically doing an XSLT transformation can be done in a few steps:</p><ol><li>configure the parser for XSLT:
+          <a href="tutorial2/libxslt_pipes.html">Tutorial2</a></li><li><a href="xsltproc.html">Man page for xsltproc</a></li><li><a href="http://mail.gnome.org/archives/xslt/">Mail archive</a></li><li><a href="http://xmlsoft.org/">XML libxml2</a></li><li><a href="ftp://xmlsoft.org/">FTP</a></li><li><a href="http://www.zlatkovic.com/projects/libxml/">Windows binaries</a></li><li><a href="http://garypennington.net/libxml2/">Solaris binaries</a></li><li><a href="http://www.explain.com.au/oss/libxml2xslt.html">MacOsX binaries</a></li><li><a href="http://bugzilla.gnome.org/buglist.cgi?product=libxslt">Bug Tracker</a></li><li><a href="http://www.zend.com/php5/articles/php5-xmlphp.php#Heading17">XSLT with PHP</a></li><li><a href="http://www.mod-xslt2.com/">Apache module</a></li><li><a href="http://sourceforge.net/projects/libxml2-pas/">Pascal bindings</a></li><li><a href="http://xsldbg.sourceforge.net/">Xsldbg Debugger</a></li></ul></td></tr></table><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>API Indexes</b></center></td></tr><tr><td bgcolor="#fffacd"><ul><li><a href="APIchunk0.html">Alphabetic</a></li><li><a href="APIconstructors.html">Constructors</a></li><li><a href="APIfunctions.html">Functions/Types</a></li><li><a href="APIfiles.html">Modules</a></li><li><a href="APIsymbols.html">Symbols</a></li></ul></td></tr></table></td></tr></table></td><td valign="top" bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="1" width="100%"><tr><td><table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000"><tr><td><table border="0" cellpadding="3" cellspacing="1" width="100%"><tr><td bgcolor="#fffacd"><p>Okay this section is clearly incomplete. But integrating libxslt into
+yourapplication should be relatively easy. First check the few steps
+describedbelow, then for more detailed informations, look at the<a href="html/libxslt-lib.html">generated pages</a>for the API and the sourceof
+libxslt/xsltproc.c  and the  <a href="tutorial/libxslttutorial.html">tutorial</a>.</p><p>Basically doing an XSLT transformation can be done in a few steps:</p><ol><li>configure the parser for XSLT:
     <p>xmlSubstituteEntitiesDefault(1);</p>
     <p>xmlLoadExtDtdDefaultValue = 1;</p>
   </li>
   <li>parse the stylesheet with xsltParseStylesheetFile()</li>
   <li>parse the document with xmlParseFile()</li>
   <li>apply the stylesheet using xsltApplyStylesheet()</li>
-  <li>save the result using xsltSaveResultToFile() if needed set
-    xmlIndentTreeOutput to 1</li>
-</ol><p>Steps 2,3, and 5 will probably need to be changed depending on you
-processing needs and environment for example if reading/saving from/to
-memory, or if you want to apply XInclude processing to the stylesheet or
-input documents.</p><p><a href="bugs.html">Daniel Veillard</a></p></td></tr></table></td></tr></table></td></tr></table></td></tr></table></td></tr></table></body></html>
+  <li>save the result using xsltSaveResultToFile() if needed
+    setxmlIndentTreeOutput to 1</li>
+</ol><p>Steps 2,3, and 5 will probably need to be changed depending on
+youprocessing needs and environment for example if reading/saving
+from/tomemory, or if you want to apply XInclude processing to the stylesheet
+orinput documents.</p><p><a href="bugs.html">Daniel Veillard</a></p></td></tr></table></td></tr></table></td></tr></table></td></tr></table></td></tr></table></body></html>

Modified: packages/libxslt/trunk/doc/FAQ.html
===================================================================
--- packages/libxslt/trunk/doc/FAQ.html	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/doc/FAQ.html	2006-06-08 22:29:07 UTC (rev 565)
@@ -9,35 +9,35 @@
 A:link, A:visited, A:active { text-decoration: underline }
     </style><title>FAQ</title></head><body bgcolor="#8b7765" text="#000000" link="#a06060" vlink="#000000"><table border="0" width="100%" cellpadding="5" cellspacing="0" align="center"><tr><td width="120"><a href="http://swpat.ffii.org/"><img src="epatents.png" alt="Action against software patents" /></a></td><td width="180"><a href="http://www.gnome.org/"><img src="gnome2.png" alt="Gnome2 Logo" /></a><a href="http://www.w3.org/Status"><img src="w3c.png" alt="W3C logo" /></a><a href="http://www.redhat.com"><img src="redhat.gif" alt="Red Hat Logo" /></a><div align="left"><a href="http://xmlsoft.org/XSLT/"><img src="Libxslt-Logo-180x168.gif" alt="Made with Libxslt Logo" /></a></div></td><td><table border="0" width="90%" cellpadding="2" cellspacing="0" align="center" bgcolor="#000000"><tr><td><table width="100%" border="0" cellspacing="1" cellpadding="3" bgcolor="#fffacd"><tr><td align="center"><h1>The XSLT C library for Gnome</h1><h2>FAQ</h2></td></tr></table></td></tr></table></td></tr></table><table border="0" cellpadding="4" cellspacing="0" width="100%" align="center"><tr><td bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="2" width="100%"><tr><td valign="top" width="200" bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000"><tr><td><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>Main Menu</b></center></td></tr><tr><td bgcolor="#fffacd"><form action="search.php" enctype="application/x-www-form-urlencoded" method="get"><input name="query" type="text" size="20" value="" /><input name="submit" type="submit" value="Search ..." /></form><ul><li><a href="index.html">Home</a></li><li><a href="http://xmlsoft.org/wiki">Wiki</a></li><li><a href="intro.html">Introduction</a></li><li><a href="docs.html">Documentation</a></li><li><a href="bugs.html">Reporting bugs and getting help</a></li><li><a href="help.html">How to help</a></li><li><a href="downloads.html">Downloads</a></li><li><a href="FAQ.html">FAQ</a></li><li><a href="news.html">News</a></li><li><a href="xsltproc2.html">The xsltproc tool</a></li><li><a href="docbook.html">DocBook</a></li><li><a href="API.html">The programming API</a></li><li><a href="python.html">Python and bindings</a></li><li><a href="internals.html">Library internals</a></li><li><a href="extensions.html">Writing extensions</a></li><li><a href="contribs.html">Contributions</a></li><li><a href="EXSLT/index.html" style="font-weight:bold">libexslt</a></li><li><a href="xslt.html">flat page</a>, <a href="site.xsl">stylesheet</a></li><li><a href="html/index.html" style="font-weight:bold">API Menu</a></li><li><a href="ChangeLog.html">ChangeLog</a></li></ul></td></tr></table><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>Related links</b></center></td></tr><tr><td bgcolor="#fffacd"><ul><li><a href="tutorial/libxslttutorial.html">Tutorial</a>,
           <a href="tutorial2/libxslt_pipes.html">Tutorial2</a></li><li><a href="xsltproc.html">Man page for xsltproc</a></li><li><a href="http://mail.gnome.org/archives/xslt/">Mail archive</a></li><li><a href="http://xmlsoft.org/">XML libxml2</a></li><li><a href="ftp://xmlsoft.org/">FTP</a></li><li><a href="http://www.zlatkovic.com/projects/libxml/">Windows binaries</a></li><li><a href="http://garypennington.net/libxml2/">Solaris binaries</a></li><li><a href="http://www.explain.com.au/oss/libxml2xslt.html">MacOsX binaries</a></li><li><a href="http://bugzilla.gnome.org/buglist.cgi?product=libxslt">Bug Tracker</a></li><li><a href="http://www.zend.com/php5/articles/php5-xmlphp.php#Heading17">XSLT with PHP</a></li><li><a href="http://www.mod-xslt2.com/">Apache module</a></li><li><a href="http://sourceforge.net/projects/libxml2-pas/">Pascal bindings</a></li><li><a href="http://xsldbg.sourceforge.net/">Xsldbg Debugger</a></li></ul></td></tr></table><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>API Indexes</b></center></td></tr><tr><td bgcolor="#fffacd"><ul><li><a href="APIchunk0.html">Alphabetic</a></li><li><a href="APIconstructors.html">Constructors</a></li><li><a href="APIfunctions.html">Functions/Types</a></li><li><a href="APIfiles.html">Modules</a></li><li><a href="APIsymbols.html">Symbols</a></li></ul></td></tr></table></td></tr></table></td><td valign="top" bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="1" width="100%"><tr><td><table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000"><tr><td><table border="0" cellpadding="3" cellspacing="1" width="100%"><tr><td bgcolor="#fffacd"><ol><li><em>Troubles compiling or linking programs using libxslt</em>
-    <p>Usually the problem comes from the fact that the compiler doesn't get
-    the right compilation or linking flags. There is a small shell script
-    <code>xslt-config</code> which is installed as part of libxslt usual
-    install process which provides those flags. Use</p>
+    <p>Usually the problem comes from the fact that the compiler doesn't
+    getthe right compilation or linking flags. There is a small shell
+    script<code>xslt-config</code>which is installed as part of libxslt
+    usualinstall process which provides those flags. Use</p>
     <p><code>xslt-config --cflags</code></p>
     <p>to get the compilation flags and</p>
     <p><code>xslt-config --libs</code></p>
-    <p>to get the linker flags. Usually this is done directly from the
-    Makefile as:</p>
+    <p>to get the linker flags. Usually this is done directly from
+    theMakefile as:</p>
     <p><code>CFLAGS=`xslt-config --cflags`</code></p>
     <p><code>LIBS=`xslt-config --libs`</code></p>
-    <p>Note also that if you use the EXSLT extensions from the program then
-    you should prepend <code>-lexslt</code> to the LIBS options</p>
+    <p>Note also that if you use the EXSLT extensions from the program
+    thenyou should prepend <code>-lexslt</code>to the LIBS options</p>
   </li>
   <li><em>passing parameters on the xsltproc command line doesn't work</em>
     <p><em>xsltproc --param test alpha foo.xsl foo.xml</em></p>
     <p><em>the param does not get passed and ends up as ""</em></p>
     <p>In a nutshell do a double escaping at the shell prompt:</p>
     <p>xsltproc --param test "'alpha'" foo.xsl foo.xml</p>
-    <p>i.e. the string value is surrounded by " and ' then terminated by '
-    and ". Libxslt interpret the parameter values as XPath expressions, so
-    the string -&gt;<code>alpha</code>&lt;- is intepreted as the node set
-    matching this string. You really want -&gt;<code>'alpha'</code>&lt;- to
-    be passed to the processor. And to allow this you need to escape the
-    quotes at the shell level using -&gt;<code>"'alpha'"</code>&lt;- .</p>
+    <p>i.e. the string value is surrounded by " and ' then terminated by 'and
+    ". Libxslt interpret the parameter values as XPath expressions, sothe
+    string -&gt;<code>alpha</code>&lt;- is intepreted as the node setmatching
+    this string. You really want -&gt;<code>'alpha'</code>&lt;- tobe passed
+    to the processor. And to allow this you need to escape thequotes at the
+    shell level using -&gt;<code>"'alpha'"</code>&lt;- .</p>
     <p>or use</p>
     <p>xsltproc --stringparam test alpha foo.xsl foo.xml</p>
   </li>
   <li><em>Is there C++ bindings ?</em>
-    <p>Yes for example <a href="http://pmade.org/pjones/software/xmlwrapp/">xmlwrapp</a> , see <a href="python.html">the related pages about bindings</a></p>
+    <p>Yes for example <a href="http://pmade.org/pjones/software/xmlwrapp/">xmlwrapp</a>, see <a href="python.html">the related pages about bindings</a></p>
   </li>
 </ol><p><a href="bugs.html">Daniel Veillard</a></p></td></tr></table></td></tr></table></td></tr></table></td></tr></table></td></tr></table></body></html>

Modified: packages/libxslt/trunk/doc/Makefile.in
===================================================================
--- packages/libxslt/trunk/doc/Makefile.in	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/doc/Makefile.in	2006-06-08 22:29:07 UTC (rev 565)
@@ -84,6 +84,7 @@
 EXTRA_LIBS = @EXTRA_LIBS@
 F77 = @F77@
 FFLAGS = @FFLAGS@
+GREP = @GREP@
 HTML_DIR = $(datadir)/doc
 INSTALL_DATA = @INSTALL_DATA@
 INSTALL_PROGRAM = @INSTALL_PROGRAM@
@@ -169,12 +170,9 @@
 XSLT_INCLUDEDIR = @XSLT_INCLUDEDIR@
 XSLT_LIBDIR = @XSLT_LIBDIR@
 XSLT_LIBS = @XSLT_LIBS@
-ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_CXX = @ac_ct_CXX@
 ac_ct_F77 = @ac_ct_F77@
-ac_ct_RANLIB = @ac_ct_RANLIB@
-ac_ct_STRIP = @ac_ct_STRIP@
 am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
 am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
 am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@
@@ -191,23 +189,30 @@
 build_os = @build_os@
 build_vendor = @build_vendor@
 datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
 exec_prefix = @exec_prefix@
 host = @host@
 host_alias = @host_alias@
 host_cpu = @host_cpu@
 host_os = @host_os@
 host_vendor = @host_vendor@
+htmldir = @htmldir@
 includedir = @includedir@
 infodir = @infodir@
 install_sh = @install_sh@
 libdir = @libdir@
 libexecdir = @libexecdir@
+localedir = @localedir@
 localstatedir = @localstatedir@
 mandir = @mandir@
 mkdir_p = @mkdir_p@
 oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
 prefix = @prefix@
 program_transform_name = @program_transform_name@
+psdir = @psdir@
 pythondir = @pythondir@
 sbindir = @sbindir@
 sharedstatedir = @sharedstatedir@

Modified: packages/libxslt/trunk/doc/bugs.html
===================================================================
--- packages/libxslt/trunk/doc/bugs.html	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/doc/bugs.html	2006-06-08 22:29:07 UTC (rev 565)
@@ -8,86 +8,84 @@
 H3 {font-family: Verdana,Arial,Helvetica}
 A:link, A:visited, A:active { text-decoration: underline }
     </style><title>Reporting bugs and getting help</title></head><body bgcolor="#8b7765" text="#000000" link="#a06060" vlink="#000000"><table border="0" width="100%" cellpadding="5" cellspacing="0" align="center"><tr><td width="120"><a href="http://swpat.ffii.org/"><img src="epatents.png" alt="Action against software patents" /></a></td><td width="180"><a href="http://www.gnome.org/"><img src="gnome2.png" alt="Gnome2 Logo" /></a><a href="http://www.w3.org/Status"><img src="w3c.png" alt="W3C logo" /></a><a href="http://www.redhat.com"><img src="redhat.gif" alt="Red Hat Logo" /></a><div align="left"><a href="http://xmlsoft.org/XSLT/"><img src="Libxslt-Logo-180x168.gif" alt="Made with Libxslt Logo" /></a></div></td><td><table border="0" width="90%" cellpadding="2" cellspacing="0" align="center" bgcolor="#000000"><tr><td><table width="100%" border="0" cellspacing="1" cellpadding="3" bgcolor="#fffacd"><tr><td align="center"><h1>The XSLT C library for Gnome</h1><h2>Reporting bugs and getting help</h2></td></tr></table></td></tr></table></td></tr></table><table border="0" cellpadding="4" cellspacing="0" width="100%" align="center"><tr><td bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="2" width="100%"><tr><td valign="top" width="200" bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000"><tr><td><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>Main Menu</b></center></td></tr><tr><td bgcolor="#fffacd"><form action="search.php" enctype="application/x-www-form-urlencoded" method="get"><input name="query" type="text" size="20" value="" /><input name="submit" type="submit" value="Search ..." /></form><ul><li><a href="index.html">Home</a></li><li><a href="http://xmlsoft.org/wiki">Wiki</a></li><li><a href="intro.html">Introduction</a></li><li><a href="docs.html">Documentation</a></li><li><a href="bugs.html">Reporting bugs and getting help</a></li><li><a href="help.html">How to help</a></li><li><a href="downloads.html">Downloads</a></li><li><a href="FAQ.html">FAQ</a></li><li><a href="news.html">News</a></li><li><a href="xsltproc2.html">The xsltproc tool</a></li><li><a href="docbook.html">DocBook</a></li><li><a href="API.html">The programming API</a></li><li><a href="python.html">Python and bindings</a></li><li><a href="internals.html">Library internals</a></li><li><a href="extensions.html">Writing extensions</a></li><li><a href="contribs.html">Contributions</a></li><li><a href="EXSLT/index.html" style="font-weight:bold">libexslt</a></li><li><a href="xslt.html">flat page</a>, <a href="site.xsl">stylesheet</a></li><li><a href="html/index.html" style="font-weight:bold">API Menu</a></li><li><a href="ChangeLog.html">ChangeLog</a></li></ul></td></tr></table><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>Related links</b></center></td></tr><tr><td bgcolor="#fffacd"><ul><li><a href="tutorial/libxslttutorial.html">Tutorial</a>,
-          <a href="tutorial2/libxslt_pipes.html">Tutorial2</a></li><li><a href="xsltproc.html">Man page for xsltproc</a></li><li><a href="http://mail.gnome.org/archives/xslt/">Mail archive</a></li><li><a href="http://xmlsoft.org/">XML libxml2</a></li><li><a href="ftp://xmlsoft.org/">FTP</a></li><li><a href="http://www.zlatkovic.com/projects/libxml/">Windows binaries</a></li><li><a href="http://garypennington.net/libxml2/">Solaris binaries</a></li><li><a href="http://www.explain.com.au/oss/libxml2xslt.html">MacOsX binaries</a></li><li><a href="http://bugzilla.gnome.org/buglist.cgi?product=libxslt">Bug Tracker</a></li><li><a href="http://www.zend.com/php5/articles/php5-xmlphp.php#Heading17">XSLT with PHP</a></li><li><a href="http://www.mod-xslt2.com/">Apache module</a></li><li><a href="http://sourceforge.net/projects/libxml2-pas/">Pascal bindings</a></li><li><a href="http://xsldbg.sourceforge.net/">Xsldbg Debugger</a></li></ul></td></tr></table><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>API Indexes</b></center></td></tr><tr><td bgcolor="#fffacd"><ul><li><a href="APIchunk0.html">Alphabetic</a></li><li><a href="APIconstructors.html">Constructors</a></li><li><a href="APIfunctions.html">Functions/Types</a></li><li><a href="APIfiles.html">Modules</a></li><li><a href="APIsymbols.html">Symbols</a></li></ul></td></tr></table></td></tr></table></td><td valign="top" bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="1" width="100%"><tr><td><table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000"><tr><td><table border="0" cellpadding="3" cellspacing="1" width="100%"><tr><td bgcolor="#fffacd"><p>If you need help with the XSLT language itself, here are a number of
-useful resources:</p><ul><li>I strongly suggest to subscribe to <a href="http://www.mulberrytech.com/xsl/xsl-list">XSL-list</a>, check <a href="http://www.biglist.com/lists/xsl-list/archives/">the XSL-list
-    archives</a></li>
+          <a href="tutorial2/libxslt_pipes.html">Tutorial2</a></li><li><a href="xsltproc.html">Man page for xsltproc</a></li><li><a href="http://mail.gnome.org/archives/xslt/">Mail archive</a></li><li><a href="http://xmlsoft.org/">XML libxml2</a></li><li><a href="ftp://xmlsoft.org/">FTP</a></li><li><a href="http://www.zlatkovic.com/projects/libxml/">Windows binaries</a></li><li><a href="http://garypennington.net/libxml2/">Solaris binaries</a></li><li><a href="http://www.explain.com.au/oss/libxml2xslt.html">MacOsX binaries</a></li><li><a href="http://bugzilla.gnome.org/buglist.cgi?product=libxslt">Bug Tracker</a></li><li><a href="http://www.zend.com/php5/articles/php5-xmlphp.php#Heading17">XSLT with PHP</a></li><li><a href="http://www.mod-xslt2.com/">Apache module</a></li><li><a href="http://sourceforge.net/projects/libxml2-pas/">Pascal bindings</a></li><li><a href="http://xsldbg.sourceforge.net/">Xsldbg Debugger</a></li></ul></td></tr></table><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>API Indexes</b></center></td></tr><tr><td bgcolor="#fffacd"><ul><li><a href="APIchunk0.html">Alphabetic</a></li><li><a href="APIconstructors.html">Constructors</a></li><li><a href="APIfunctions.html">Functions/Types</a></li><li><a href="APIfiles.html">Modules</a></li><li><a href="APIsymbols.html">Symbols</a></li></ul></td></tr></table></td></tr></table></td><td valign="top" bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="1" width="100%"><tr><td><table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000"><tr><td><table border="0" cellpadding="3" cellspacing="1" width="100%"><tr><td bgcolor="#fffacd"><p>If you need help with the XSLT language itself, here are a number ofuseful
+resources:</p><ul><li>I strongly suggest to subscribe to <a href="http://www.mulberrytech.com/xsl/xsl-list">XSL-list</a>, check <a href="http://www.biglist.com/lists/xsl-list/archives/">the
+    XSL-listarchives</a></li>
   <li>The <a href="http://www.dpawson.co.uk/xsl/xslfaq.html">XSL FAQ</a>.</li>
-  <li>The <a href="http://www.nwalsh.com/docs/tutorials/xsl/xsl/slides.html">tutorial</a>
-    written by Paul Grosso and Norman Walsh is a very good on-line
-    introdution to the language.</li>
-  <li>The <a href="http://www.zvon.org/xxl/XSLTutorial/Books/Book1/index.html">only
-    Zvon XSLT tutorial</a> details a lot of constructs with examples.</li>
-  <li><a href="http://www.jenitennison.com/xslt/index.html">Jeni Tennison's
-    XSLT</a> pages provide links to a lot of answers</li>
-  <li>the <a href="http://incrementaldevelopment.com/xsltrick/">Gallery of
-    XSLT Tricks</a> provides non-standard use case of XSLT</li>
-  <li>And I suggest to buy Michael Kay "XSLT Programmer's Reference" book
-    published by <a href="http://www.wrox.com/">Wrox</a> if you plan to work
-    seriously with XSLT in the future.</li>
-</ul><p>Well, bugs or missing features are always possible, and I will make a
-point of fixing them in a timely fashion. The best way to report a bug is to
-use the <a href="http://bugzilla.gnome.org/enter_bug.cgi?product=libxslt">Gnome bug
-tracking database</a> (make sure to use the "libxslt" module name). Before
-filing a bug, check the <a href="http://bugzilla.gnome.org/buglist.cgi?product=libxslt">list of existing
-libxslt bugs</a> to make sure it hasn't already been filed. I look at reports
-there regularly and it's good to have a reminder when a bug is still open. Be
-sure to specify that the bug is for the package libxslt.</p><p>For small problems you can try to get help on IRC, the #xml channel on
-irc.gnome.org (port 6667) usually have a few person subscribed which may help
-(but there is no garantee and if a real issue is raised it should go on the
-mailing-list for archival).</p><p>There is also a mailing-list <a href="mailto:xslt at gnome.org">xslt at gnome.org</a> for libxslt, with an <a href="http://mail.gnome.org/archives/xslt/">on-line archive</a>. To subscribe
-to this list, please visit the <a href="http://mail.gnome.org/mailman/listinfo/xslt">associated Web</a> page
-and follow the instructions.</p><p>Alternatively, you can just send the bug to the <a href="mailto:xslt at gnome.org">xslt at gnome.org</a> list, if it's really libxslt
-related I will approve it.. Please do not send me mail directly especially
-for portability problem, it makes things really harder to track and in some
-cases I'm not the best person to answer a given question, ask the list
-instead. <strong>Do not send code, I won't debug it</strong> (but patches are
-really appreciated!).</p><p>Please note that with the current amount of virus and SPAM, sending mail
-to the list without being subscribed won't work. There is *far too many
-bounces* (in the order of a thousand a day !) I cannot approve them manually
-anymore. If your mail to the list bounced waiting for administrator approval,
-it is LOST ! Repost it and fix the problem triggering the error. Also please
-note that <span style="color: #FF0000; background-color: #FFFFFF">emails with
-a legal warning asking to not copy or redistribute freely the informations
-they contain</span> are <strong>NOT</strong> acceptable for the mailing-list,
-such mail will as much as possible be discarded automatically, and are less
-likely to be answered if they made it to the list, <strong>DO NOT</strong>
-post to the list from an email address where such legal requirements are
-automatically added, get private paying support if you can't share
-informations.</p><p>Check the following too <span style="color: #E50000">before
-posting</span>:</p><ul><li><a href="search.php">use the search engine</a> to get informations
-    related to your problem.</li>
-  <li>make sure you are <a href="ftp://xmlsoft.org/libxslt/">using a recent
-    version</a>, and that the problem still shows up in those</li>
-  <li>check the <a href="http://mail.gnome.org/archives/xslt/">list
-    archives</a> to see if the problem was reported already, in this case
-    there is probably a fix available, similarly check the <a href="http://bugzilla.gnome.org/buglist.cgi?product=libxslt">registered
-    open bugs</a></li>
-  <li>make sure you can reproduce the bug with xsltproc, a very useful thing
-    to do is run the transformation with -v argument and redirect the
-    standard error to a file, then search in this file for the transformation
-    logs just preceding the possible problem</li>
-  <li>Please send the command showing the error as well as the input and
-    stylesheet (as an attachment)</li>
-</ul><p>Then send the bug with associated informations to reproduce it to the <a href="mailto:xslt at gnome.org">xslt at gnome.org</a> list; if it's really libxslt
-related I will approve it. Please do not send mail to me directly, it makes
-things really hard to track and in some cases I am not the best person to
-answer a given question, ask on the list.</p><p>To <span style="color: #E50000">be really clear about support</span>:</p><ul><li>Support or help <span style="color: #E50000">request MUST be sent to
-    the list or on bugzilla</span> in case of problems, so that the Question
-    and Answers can be shared publicly. Failing to do so carries the implicit
-    message "I want free support but I don't want to share the benefits with
-    others" and is not welcome. I will automatically Carbon-Copy the
-    xslt at gnome.org mailing list for any technical reply made about libxml2 or
-    libxslt.</li>
-  <li>There is <span style="color: #E50000">no garantee for support</span>,
-    if your question remains unanswered after a week, repost it, making sure
-    you gave all the detail needed and the informations requested.</li>
-  <li>Failing to provide informations as requested or double checking first
-    for prior feedback also carries the implicit message "the time of the
-    library maintainers is less valuable than my time" and might not be
-    welcome.</li>
-</ul><p>Of course, bugs reports with a suggested patch for fixing them will
-probably be processed faster.</p><p>If you're looking for help, a quick look at <a href="http://mail.gnome.org/archives/xslt/">the list archive</a> may actually
-provide the answer, I usually send source samples when answering libxslt
-usage questions. The <a href="html/libxslt-lib.html#LIBXSLT-LIB">auto-generated documentation</a> is
-not as polished as I would like (I need to learn more about Docbook), but
-it's a good starting point.</p><p><a href="bugs.html">Daniel Veillard</a></p></td></tr></table></td></tr></table></td></tr></table></td></tr></table></td></tr></table></body></html>
+  <li>The <a href="http://www.nwalsh.com/docs/tutorials/xsl/xsl/slides.html">tutorial</a>written
+    by Paul Grosso and Norman Walsh is a very good on-lineintrodution to the
+    language.</li>
+  <li>The <a href="http://www.zvon.org/xxl/XSLTutorial/Books/Book1/index.html">onlyZvon
+    XSLT tutorial</a>details a lot of constructs with examples.</li>
+  <li><a href="http://www.jenitennison.com/xslt/index.html">Jeni
+    Tennison'sXSLT</a>pages provide links to a lot of answers</li>
+  <li>the <a href="http://incrementaldevelopment.com/xsltrick/">Gallery
+    ofXSLT Tricks</a>provides non-standard use case of XSLT</li>
+  <li>And I suggest to buy Michael Kay "XSLT Programmer's Reference"
+    bookpublished by <a href="http://www.wrox.com/">Wrox</a>if you plan to
+    workseriously with XSLT in the future.</li>
+</ul><p>Well, bugs or missing features are always possible, and I will make apoint
+of fixing them in a timely fashion. The best way to report a bug is touse the
+<a href="http://bugzilla.gnome.org/enter_bug.cgi?product=libxslt">Gnome
+bugtracking database</a>(make sure to use the "libxslt" module name).
+Beforefiling a bug, check the <a href="http://bugzilla.gnome.org/buglist.cgi?product=libxslt">list of
+existinglibxslt bugs</a>to make sure it hasn't already been filed. I look at
+reportsthere regularly and it's good to have a reminder when a bug is still
+open. Besure to specify that the bug is for the package libxslt.</p><p>For small problems you can try to get help on IRC, the #xml channel
+onirc.gnome.org (port 6667) usually have a few person subscribed which may
+help(but there is no garantee and if a real issue is raised it should go on
+themailing-list for archival).</p><p>There is also a mailing-list <a href="mailto:xslt at gnome.org">xslt at gnome.org</a>for libxslt, with an <a href="http://mail.gnome.org/archives/xslt/">on-line archive</a>. To
+subscribeto this list, please visit the <a href="http://mail.gnome.org/mailman/listinfo/xslt">associated Web</a>pageand
+follow the instructions.</p><p>Alternatively, you can just send the bug to the <a href="mailto:xslt at gnome.org">xslt at gnome.org</a>list, if it's really
+libxsltrelated I will approve it.. Please do not send me mail directly
+especiallyfor portability problem, it makes things really harder to track and
+in somecases I'm not the best person to answer a given question, ask the
+listinstead. <strong>Do not send code, I won't debug it</strong>(but patches
+arereally appreciated!).</p><p>Please note that with the current amount of virus and SPAM, sending mailto
+the list without being subscribed won't work. There is *far too manybounces*
+(in the order of a thousand a day !) I cannot approve them manuallyanymore.
+If your mail to the list bounced waiting for administrator approval,it is
+LOST ! Repost it and fix the problem triggering the error. Also pleasenote
+that <span style="color: #FF0000; background-color: #FFFFFF">emails witha
+legal warning asking to not copy or redistribute freely the informationsthey
+contain</span>are <strong>NOT</strong>acceptable for the mailing-list,such
+mail will as much as possible be discarded automatically, and are lesslikely
+to be answered if they made it to the list, <strong>DO NOT</strong>post to
+the list from an email address where such legal requirements areautomatically
+added, get private paying support if you can't shareinformations.</p><p>Check the following too <span style="color: #E50000">beforeposting</span>:</p><ul><li><a href="search.php">use the search engine</a>to get
+    informationsrelated to your problem.</li>
+  <li>make sure you are <a href="ftp://xmlsoft.org/libxslt/">using a
+    recentversion</a>, and that the problem still shows up in those</li>
+  <li>check the <a href="http://mail.gnome.org/archives/xslt/">listarchives</a>to see if the
+    problem was reported already, in this casethere is probably a fix
+    available, similarly check the <a href="http://bugzilla.gnome.org/buglist.cgi?product=libxslt">registeredopen
+    bugs</a></li>
+  <li>make sure you can reproduce the bug with xsltproc, a very useful
+    thingto do is run the transformation with -v argument and redirect
+    thestandard error to a file, then search in this file for the
+    transformationlogs just preceding the possible problem</li>
+  <li>Please send the command showing the error as well as the input
+    andstylesheet (as an attachment)</li>
+</ul><p>Then send the bug with associated informations to reproduce it to the <a href="mailto:xslt at gnome.org">xslt at gnome.org</a>list; if it's really
+libxsltrelated I will approve it. Please do not send mail to me directly, it
+makesthings really hard to track and in some cases I am not the best person
+toanswer a given question, ask on the list.</p><p>To <span style="color: #E50000">be really clear about support</span>:</p><ul><li>Support or help <span style="color: #E50000">request MUST be sent tothe
+    list or on bugzilla</span>in case of problems, so that the Questionand
+    Answers can be shared publicly. Failing to do so carries the
+    implicitmessage "I want free support but I don't want to share the
+    benefits withothers" and is not welcome. I will automatically Carbon-Copy
+    thexslt at gnome.org mailing list for any technical reply made about libxml2
+    orlibxslt.</li>
+  <li>There is <span style="color: #E50000">no garantee for support</span>,if
+    your question remains unanswered after a week, repost it, making sureyou
+    gave all the detail needed and the informations requested.</li>
+  <li>Failing to provide informations as requested or double checking
+    firstfor prior feedback also carries the implicit message "the time of
+    thelibrary maintainers is less valuable than my time" and might not
+    bewelcome.</li>
+</ul><p>Of course, bugs reports with a suggested patch for fixing them
+willprobably be processed faster.</p><p>If you're looking for help, a quick look at <a href="http://mail.gnome.org/archives/xslt/">the list archive</a>may
+actuallyprovide the answer, I usually send source samples when answering
+libxsltusage questions. The <a href="html/libxslt-lib.html#LIBXSLT-LIB">auto-generated
+documentation</a>isnot as polished as I would like (I need to learn more
+about Docbook), butit's a good starting point.</p><p><a href="bugs.html">Daniel Veillard</a></p></td></tr></table></td></tr></table></td></tr></table></td></tr></table></td></tr></table></body></html>

Modified: packages/libxslt/trunk/doc/contribs.html
===================================================================
--- packages/libxslt/trunk/doc/contribs.html	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/doc/contribs.html	2006-06-08 22:29:07 UTC (rev 565)
@@ -8,34 +8,33 @@
 H3 {font-family: Verdana,Arial,Helvetica}
 A:link, A:visited, A:active { text-decoration: underline }
     </style><title>Contributions</title></head><body bgcolor="#8b7765" text="#000000" link="#a06060" vlink="#000000"><table border="0" width="100%" cellpadding="5" cellspacing="0" align="center"><tr><td width="120"><a href="http://swpat.ffii.org/"><img src="epatents.png" alt="Action against software patents" /></a></td><td width="180"><a href="http://www.gnome.org/"><img src="gnome2.png" alt="Gnome2 Logo" /></a><a href="http://www.w3.org/Status"><img src="w3c.png" alt="W3C logo" /></a><a href="http://www.redhat.com"><img src="redhat.gif" alt="Red Hat Logo" /></a><div align="left"><a href="http://xmlsoft.org/XSLT/"><img src="Libxslt-Logo-180x168.gif" alt="Made with Libxslt Logo" /></a></div></td><td><table border="0" width="90%" cellpadding="2" cellspacing="0" align="center" bgcolor="#000000"><tr><td><table width="100%" border="0" cellspacing="1" cellpadding="3" bgcolor="#fffacd"><tr><td align="center"><h1>The XSLT C library for Gnome</h1><h2>Contributions</h2></td></tr></table></td></tr></table></td></tr></table><table border="0" cellpadding="4" cellspacing="0" width="100%" align="center"><tr><td bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="2" width="100%"><tr><td valign="top" width="200" bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000"><tr><td><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>Main Menu</b></center></td></tr><tr><td bgcolor="#fffacd"><form action="search.php" enctype="application/x-www-form-urlencoded" method="get"><input name="query" type="text" size="20" value="" /><input name="submit" type="submit" value="Search ..." /></form><ul><li><a href="index.html">Home</a></li><li><a href="http://xmlsoft.org/wiki">Wiki</a></li><li><a href="intro.html">Introduction</a></li><li><a href="docs.html">Documentation</a></li><li><a href="bugs.html">Reporting bugs and getting help</a></li><li><a href="help.html">How to help</a></li><li><a href="downloads.html">Downloads</a></li><li><a href="FAQ.html">FAQ</a></li><li><a href="news.html">News</a></li><li><a href="xsltproc2.html">The xsltproc tool</a></li><li><a href="docbook.html">DocBook</a></li><li><a href="API.html">The programming API</a></li><li><a href="python.html">Python and bindings</a></li><li><a href="internals.html">Library internals</a></li><li><a href="extensions.html">Writing extensions</a></li><li><a href="contribs.html">Contributions</a></li><li><a href="EXSLT/index.html" style="font-weight:bold">libexslt</a></li><li><a href="xslt.html">flat page</a>, <a href="site.xsl">stylesheet</a></li><li><a href="html/index.html" style="font-weight:bold">API Menu</a></li><li><a href="ChangeLog.html">ChangeLog</a></li></ul></td></tr></table><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>Related links</b></center></td></tr><tr><td bgcolor="#fffacd"><ul><li><a href="tutorial/libxslttutorial.html">Tutorial</a>,
-          <a href="tutorial2/libxslt_pipes.html">Tutorial2</a></li><li><a href="xsltproc.html">Man page for xsltproc</a></li><li><a href="http://mail.gnome.org/archives/xslt/">Mail archive</a></li><li><a href="http://xmlsoft.org/">XML libxml2</a></li><li><a href="ftp://xmlsoft.org/">FTP</a></li><li><a href="http://www.zlatkovic.com/projects/libxml/">Windows binaries</a></li><li><a href="http://garypennington.net/libxml2/">Solaris binaries</a></li><li><a href="http://www.explain.com.au/oss/libxml2xslt.html">MacOsX binaries</a></li><li><a href="http://bugzilla.gnome.org/buglist.cgi?product=libxslt">Bug Tracker</a></li><li><a href="http://www.zend.com/php5/articles/php5-xmlphp.php#Heading17">XSLT with PHP</a></li><li><a href="http://www.mod-xslt2.com/">Apache module</a></li><li><a href="http://sourceforge.net/projects/libxml2-pas/">Pascal bindings</a></li><li><a href="http://xsldbg.sourceforge.net/">Xsldbg Debugger</a></li></ul></td></tr></table><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>API Indexes</b></center></td></tr><tr><td bgcolor="#fffacd"><ul><li><a href="APIchunk0.html">Alphabetic</a></li><li><a href="APIconstructors.html">Constructors</a></li><li><a href="APIfunctions.html">Functions/Types</a></li><li><a href="APIfiles.html">Modules</a></li><li><a href="APIsymbols.html">Symbols</a></li></ul></td></tr></table></td></tr></table></td><td valign="top" bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="1" width="100%"><tr><td><table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000"><tr><td><table border="0" cellpadding="3" cellspacing="1" width="100%"><tr><td bgcolor="#fffacd"><ul><li>Bjorn Reese is the author of the number support and worked on the
-    XSLTMark support</li>
-  <li>William Brack was an early adopted, contributed a number of patches and
-    spent quite some time debugging non-trivial problems in early versions of
-    libxslt</li>
-  <li><a href="mailto:igor at zlatkovic.com">Igor  Zlatkovic</a> is now the
-    maintainer of the Windows port, <a href="http://www.zlatkovic.com/projects/libxml/index.html">he provides
-    binaries</a></li>
-  <li>Thomas Broyer provided a lot of suggestions, and drafted most of the
-    extension API</li>
-  <li>John Fleck maintains <a href="tutorial/libxslttutorial.html">a tutorial
-    for libxslt</a></li>
-  <li><a href="http://mail.gnome.org/archives/xml/2001-March/msg00014.html">Matt
-    Sergeant</a> developed <a href="http://axkit.org/download/">XML::LibXSLT</a>, a perl wrapper for
-    libxml2/libxslt as part of the <a href="http://axkit.com/">AxKit XML
-    application server</a></li>
-  <li>there is a module for <a href="http://acs-misc.sourceforge.net/nsxml.html">libxml/libxslt support
-    in OpenNSD/AOLServer</a></li>
-  <li><a href="mailto:dkuhlman at cutter.rexx.com">Dave Kuhlman</a> provides
-    libxml/libxslt <a href="http://www.rexx.com/~dkuhlman">wrappers for
-    Python</a></li>
-  <li><a href="mailto:Steve.Ball at explain.com.au">Steve Ball</a>, and
-    contributors maintain <a href="http://tclxml.sourceforge.net/">tcl
-    bindings for libxml2 and libxslt</a>, as well as <a href="http://tclxml.sf.net/tkxmllint.html">tkxmllint</a> a GUI for
-    xmllint and <a href="http://tclxml.sf.net/tkxsltproc.html">tkxsltproc</a>
-    a GUI for xsltproc.</li>
-  <li>If you want to use libxslt in a Mac OS X/Cocoa or Objective-C
-    framework, Marc Liyanage provides <a href="http://www.entropy.ch/software/macosx/#testxslt">an application
-    TestXSLT for XSLT and XML editing</a> including wrapper classes for the
-    XML parser and XSLT processor.</li>
+          <a href="tutorial2/libxslt_pipes.html">Tutorial2</a></li><li><a href="xsltproc.html">Man page for xsltproc</a></li><li><a href="http://mail.gnome.org/archives/xslt/">Mail archive</a></li><li><a href="http://xmlsoft.org/">XML libxml2</a></li><li><a href="ftp://xmlsoft.org/">FTP</a></li><li><a href="http://www.zlatkovic.com/projects/libxml/">Windows binaries</a></li><li><a href="http://garypennington.net/libxml2/">Solaris binaries</a></li><li><a href="http://www.explain.com.au/oss/libxml2xslt.html">MacOsX binaries</a></li><li><a href="http://bugzilla.gnome.org/buglist.cgi?product=libxslt">Bug Tracker</a></li><li><a href="http://www.zend.com/php5/articles/php5-xmlphp.php#Heading17">XSLT with PHP</a></li><li><a href="http://www.mod-xslt2.com/">Apache module</a></li><li><a href="http://sourceforge.net/projects/libxml2-pas/">Pascal bindings</a></li><li><a href="http://xsldbg.sourceforge.net/">Xsldbg Debugger</a></li></ul></td></tr></table><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>API Indexes</b></center></td></tr><tr><td bgcolor="#fffacd"><ul><li><a href="APIchunk0.html">Alphabetic</a></li><li><a href="APIconstructors.html">Constructors</a></li><li><a href="APIfunctions.html">Functions/Types</a></li><li><a href="APIfiles.html">Modules</a></li><li><a href="APIsymbols.html">Symbols</a></li></ul></td></tr></table></td></tr></table></td><td valign="top" bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="1" width="100%"><tr><td><table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000"><tr><td><table border="0" cellpadding="3" cellspacing="1" width="100%"><tr><td bgcolor="#fffacd"><ul><li>Bjorn Reese is the author of the number support and worked on
+    theXSLTMark support</li>
+  <li>William Brack was an early adopted, contributed a number of patches
+    andspent quite some time debugging non-trivial problems in early versions
+    oflibxslt</li>
+  <li><a href="mailto:igor at zlatkovic.com">Igor  Zlatkovic</a>is now
+    themaintainer of the Windows port, <a href="http://www.zlatkovic.com/projects/libxml/index.html">he
+    providesbinaries</a></li>
+  <li>Thomas Broyer provided a lot of suggestions, and drafted most of
+    theextension API</li>
+  <li>John Fleck maintains <a href="tutorial/libxslttutorial.html">a
+    tutorialfor libxslt</a></li>
+  <li><a href="http://mail.gnome.org/archives/xml/2001-March/msg00014.html">MattSergeant</a>developed
+    <a href="http://axkit.org/download/">XML::LibXSLT</a>, a perl wrapper
+    forlibxml2/libxslt as part of the <a href="http://axkit.com/">AxKit
+    XMLapplication server</a></li>
+  <li>there is a module for <a href="http://acs-misc.sourceforge.net/nsxml.html">libxml/libxslt
+    supportin OpenNSD/AOLServer</a></li>
+  <li><a href="mailto:dkuhlman at cutter.rexx.com">Dave
+    Kuhlman</a>provideslibxml/libxslt <a href="http://www.rexx.com/~dkuhlman">wrappers forPython</a></li>
+  <li><a href="mailto:Steve.Ball at explain.com.au">Steve Ball</a>,
+    andcontributors maintain <a href="http://tclxml.sourceforge.net/">tclbindings for libxml2 and
+    libxslt</a>, as well as <a href="http://tclxml.sf.net/tkxmllint.html">tkxmllint</a>a GUI forxmllint
+    and <a href="http://tclxml.sf.net/tkxsltproc.html">tkxsltproc</a>a GUI
+    for xsltproc.</li>
+  <li>If you want to use libxslt in a Mac OS X/Cocoa or Objective-Cframework,
+    Marc Liyanage provides <a href="http://www.entropy.ch/software/macosx/#testxslt">an
+    applicationTestXSLT for XSLT and XML editing</a>including wrapper classes
+    for theXML parser and XSLT processor.</li>
 </ul><p></p><p><a href="bugs.html">Daniel Veillard</a></p></td></tr></table></td></tr></table></td></tr></table></td></tr></table></td></tr></table></body></html>

Modified: packages/libxslt/trunk/doc/docbook.html
===================================================================
--- packages/libxslt/trunk/doc/docbook.html	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/doc/docbook.html	2006-06-08 22:29:07 UTC (rev 565)
@@ -8,56 +8,53 @@
 H3 {font-family: Verdana,Arial,Helvetica}
 A:link, A:visited, A:active { text-decoration: underline }
     </style><title>DocBook</title></head><body bgcolor="#8b7765" text="#000000" link="#a06060" vlink="#000000"><table border="0" width="100%" cellpadding="5" cellspacing="0" align="center"><tr><td width="120"><a href="http://swpat.ffii.org/"><img src="epatents.png" alt="Action against software patents" /></a></td><td width="180"><a href="http://www.gnome.org/"><img src="gnome2.png" alt="Gnome2 Logo" /></a><a href="http://www.w3.org/Status"><img src="w3c.png" alt="W3C logo" /></a><a href="http://www.redhat.com"><img src="redhat.gif" alt="Red Hat Logo" /></a><div align="left"><a href="http://xmlsoft.org/XSLT/"><img src="Libxslt-Logo-180x168.gif" alt="Made with Libxslt Logo" /></a></div></td><td><table border="0" width="90%" cellpadding="2" cellspacing="0" align="center" bgcolor="#000000"><tr><td><table width="100%" border="0" cellspacing="1" cellpadding="3" bgcolor="#fffacd"><tr><td align="center"><h1>The XSLT C library for Gnome</h1><h2>DocBook</h2></td></tr></table></td></tr></table></td></tr></table><table border="0" cellpadding="4" cellspacing="0" width="100%" align="center"><tr><td bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="2" width="100%"><tr><td valign="top" width="200" bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000"><tr><td><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>Main Menu</b></center></td></tr><tr><td bgcolor="#fffacd"><form action="search.php" enctype="application/x-www-form-urlencoded" method="get"><input name="query" type="text" size="20" value="" /><input name="submit" type="submit" value="Search ..." /></form><ul><li><a href="index.html">Home</a></li><li><a href="http://xmlsoft.org/wiki">Wiki</a></li><li><a href="intro.html">Introduction</a></li><li><a href="docs.html">Documentation</a></li><li><a href="bugs.html">Reporting bugs and getting help</a></li><li><a href="help.html">How to help</a></li><li><a href="downloads.html">Downloads</a></li><li><a href="FAQ.html">FAQ</a></li><li><a href="news.html">News</a></li><li><a href="xsltproc2.html">The xsltproc tool</a></li><li><a href="docbook.html">DocBook</a></li><li><a href="API.html">The programming API</a></li><li><a href="python.html">Python and bindings</a></li><li><a href="internals.html">Library internals</a></li><li><a href="extensions.html">Writing extensions</a></li><li><a href="contribs.html">Contributions</a></li><li><a href="EXSLT/index.html" style="font-weight:bold">libexslt</a></li><li><a href="xslt.html">flat page</a>, <a href="site.xsl">stylesheet</a></li><li><a href="html/index.html" style="font-weight:bold">API Menu</a></li><li><a href="ChangeLog.html">ChangeLog</a></li></ul></td></tr></table><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>Related links</b></center></td></tr><tr><td bgcolor="#fffacd"><ul><li><a href="tutorial/libxslttutorial.html">Tutorial</a>,
-          <a href="tutorial2/libxslt_pipes.html">Tutorial2</a></li><li><a href="xsltproc.html">Man page for xsltproc</a></li><li><a href="http://mail.gnome.org/archives/xslt/">Mail archive</a></li><li><a href="http://xmlsoft.org/">XML libxml2</a></li><li><a href="ftp://xmlsoft.org/">FTP</a></li><li><a href="http://www.zlatkovic.com/projects/libxml/">Windows binaries</a></li><li><a href="http://garypennington.net/libxml2/">Solaris binaries</a></li><li><a href="http://www.explain.com.au/oss/libxml2xslt.html">MacOsX binaries</a></li><li><a href="http://bugzilla.gnome.org/buglist.cgi?product=libxslt">Bug Tracker</a></li><li><a href="http://www.zend.com/php5/articles/php5-xmlphp.php#Heading17">XSLT with PHP</a></li><li><a href="http://www.mod-xslt2.com/">Apache module</a></li><li><a href="http://sourceforge.net/projects/libxml2-pas/">Pascal bindings</a></li><li><a href="http://xsldbg.sourceforge.net/">Xsldbg Debugger</a></li></ul></td></tr></table><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>API Indexes</b></center></td></tr><tr><td bgcolor="#fffacd"><ul><li><a href="APIchunk0.html">Alphabetic</a></li><li><a href="APIconstructors.html">Constructors</a></li><li><a href="APIfunctions.html">Functions/Types</a></li><li><a href="APIfiles.html">Modules</a></li><li><a href="APIsymbols.html">Symbols</a></li></ul></td></tr></table></td></tr></table></td><td valign="top" bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="1" width="100%"><tr><td><table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000"><tr><td><table border="0" cellpadding="3" cellspacing="1" width="100%"><tr><td bgcolor="#fffacd"><p><img src="duck.png" align="right" alt="The duck picture" /></p><p><a href="http://www.oasis-open.org/committees/docbook/">DocBook</a> is an
-XML/SGML vocabulary particularly well suited to books and papers about
-computer hardware and software.</p><p>xsltproc and libxslt are not specifically dependant on DocBook, but since
-a lot of people use xsltproc and libxml2 for DocBook formatting, here are a
-few pointers and informations which may be helpful:</p><ul><li>The <a href="http://www.oasis-open.org/committees/docbook/">DocBook
-    homepage at Oasis</a> you should find pointers there on all the lastest
-    versions of the DTDs and XSLT stylesheets</li>
-  <li><a href="http://www.docbook.org/">DocBook: The Definitive Guide</a> is
-    the official reference documentation for DocBook.</li>
-  <li><a href="https://sourceforge.net/docman/index.php?group_id=21935">DocBook
-    Open Repository</a> contains a lot of informations about DocBook</li>
-  <li>Bob Stayton provides a <a href="http://www.sagehill.net/">lot of
-    resources</a> and consulting services around DocBook.</li>
-  <li>Here is a <a href="/buildDocBookCatalog">shell script</a> to generate
-    XML Catalogs for DocBook 4.1.2 . If it can write to the /etc/xml/
-    directory, it will set-up /etc/xml/catalog and /etc/xml/docbook based on
-    the resources found on the system. Otherwise it will just create
-    ~/xmlcatalog and ~/dbkxmlcatalog and doing:
+          <a href="tutorial2/libxslt_pipes.html">Tutorial2</a></li><li><a href="xsltproc.html">Man page for xsltproc</a></li><li><a href="http://mail.gnome.org/archives/xslt/">Mail archive</a></li><li><a href="http://xmlsoft.org/">XML libxml2</a></li><li><a href="ftp://xmlsoft.org/">FTP</a></li><li><a href="http://www.zlatkovic.com/projects/libxml/">Windows binaries</a></li><li><a href="http://garypennington.net/libxml2/">Solaris binaries</a></li><li><a href="http://www.explain.com.au/oss/libxml2xslt.html">MacOsX binaries</a></li><li><a href="http://bugzilla.gnome.org/buglist.cgi?product=libxslt">Bug Tracker</a></li><li><a href="http://www.zend.com/php5/articles/php5-xmlphp.php#Heading17">XSLT with PHP</a></li><li><a href="http://www.mod-xslt2.com/">Apache module</a></li><li><a href="http://sourceforge.net/projects/libxml2-pas/">Pascal bindings</a></li><li><a href="http://xsldbg.sourceforge.net/">Xsldbg Debugger</a></li></ul></td></tr></table><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>API Indexes</b></center></td></tr><tr><td bgcolor="#fffacd"><ul><li><a href="APIchunk0.html">Alphabetic</a></li><li><a href="APIconstructors.html">Constructors</a></li><li><a href="APIfunctions.html">Functions/Types</a></li><li><a href="APIfiles.html">Modules</a></li><li><a href="APIsymbols.html">Symbols</a></li></ul></td></tr></table></td></tr></table></td><td valign="top" bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="1" width="100%"><tr><td><table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000"><tr><td><table border="0" cellpadding="3" cellspacing="1" width="100%"><tr><td bgcolor="#fffacd"><p><img src="duck.png" align="right" alt="The duck picture" /></p><p><a href="http://www.oasis-open.org/committees/docbook/">DocBook</a>is
+anXML/SGML vocabulary particularly well suited to books and papers
+aboutcomputer hardware and software.</p><p>xsltproc and libxslt are not specifically dependant on DocBook, but sincea
+lot of people use xsltproc and libxml2 for DocBook formatting, here are afew
+pointers and informations which may be helpful:</p><ul><li>The <a href="http://www.oasis-open.org/committees/docbook/">DocBookhomepage at
+    Oasis</a>you should find pointers there on all the lastestversions of the
+    DTDs and XSLT stylesheets</li>
+  <li><a href="http://www.docbook.org/">DocBook: The Definitive
+    Guide</a>isthe official reference documentation for DocBook.</li>
+  <li><a href="https://sourceforge.net/docman/index.php?group_id=21935">DocBookOpen
+    Repository</a>contains a lot of informations about DocBook</li>
+  <li>Bob Stayton provides a <a href="http://www.sagehill.net/">lot
+    ofresources</a>and consulting services around DocBook.</li>
+  <li>Here is a <a href="/buildDocBookCatalog">shell script</a>to generateXML
+    Catalogs for DocBook 4.1.2 . If it can write to the /etc/xml/directory,
+    it will set-up /etc/xml/catalog and /etc/xml/docbook based onthe
+    resources found on the system. Otherwise it will just create~/xmlcatalog
+    and ~/dbkxmlcatalog and doing:
     <p><code>export XMLCATALOG=$HOME/xmlcatalog</code></p>
-    <p>should allow to process DocBook documentations without requiring
-    network accesses for the DTd or stylesheets</p>
+    <p>should allow to process DocBook documentations without
+    requiringnetwork accesses for the DTd or stylesheets</p>
   </li>
-  <li>I have uploaded <a href="ftp://xmlsoft.org/libxml2/test/dbk412catalog.tar.gz">a
-    small tarball</a> containing XML Catalogs for DocBook 4.1.2 which seems
-    to work fine for me too</li>
-  <li>Informations on installing a <a href="http://ourworld.compuserve.com/homepages/hoenicka_markus/ntsgml.html">Windows
-    DocBook processing setup</a> based on Cygwin (using the binaries from the
-    official Windows port should be possible too)</li>
-  <li>Alexander Kirillov's page on <a href="http://www.math.sunysb.edu/~kirillov/dbxml/">Using DocBook XML
-    4.1.2</a> (RPM packages)</li>
-  <li>Tim Waugh's <a href="http://cyberelk.net/tim/xmlto/">xmlto front-end
-    conversion script</a></li>
-  <li>Linux Documentation Project <a href="http://www.linuxdoc.org/HOWTO/mini/DocBook-Install/">
-    DocBook-Install-mini-HOWTO</a></li>
-  <li>ScrollKeeper the open documentation cataloging project has a <a href="http://scrollkeeper.sourceforge.net/docbook.shtml">DocBook
-    section</a></li>
-  <li>Dan York presentation on <a href="http://www.lodestar2.com/people/dyork/talks/2001/xugo/docbook/index.html">Publishing
-    using DocBook XML</a></li>
-</ul><p>Do not use the --docbook option of xsltproc to process XML DocBook
-documents, this option is only intended to provide some (limited) support of
-the SGML version of DocBook.</p><p>Points which are not DocBook specific but still worth mentionning
-again:</p><ul><li>if you think DocBook processing time is too slow, make sure you have
-    XML Catalogs pointing to a local installation of the DTD of DocBook.
-    Check the <a href="http://xmlsoft.org/catalog.html">XML Catalog page</a>
-    to understand more on this subject.</li>
+  <li>I have uploaded <a href="ftp://xmlsoft.org/libxml2/test/dbk412catalog.tar.gz">asmall
+    tarball</a>containing XML Catalogs for DocBook 4.1.2 which seemsto work
+    fine for me too</li>
+  <li>Informations on installing a <a href="http://ourworld.compuserve.com/homepages/hoenicka_markus/ntsgml.html">WindowsDocBook
+    processing setup</a>based on Cygwin (using the binaries from theofficial
+    Windows port should be possible too)</li>
+  <li>Alexander Kirillov's page on <a href="http://www.math.sunysb.edu/~kirillov/dbxml/">Using DocBook
+    XML4.1.2</a>(RPM packages)</li>
+  <li>Tim Waugh's <a href="http://cyberelk.net/tim/xmlto/">xmlto
+    front-endconversion script</a></li>
+  <li>Linux Documentation Project <a href="http://www.linuxdoc.org/HOWTO/mini/DocBook-Install/">DocBook-Install-mini-HOWTO</a></li>
+  <li>ScrollKeeper the open documentation cataloging project has a <a href="http://scrollkeeper.sourceforge.net/docbook.shtml">DocBooksection</a></li>
+  <li>Dan York presentation on <a href="http://www.lodestar2.com/people/dyork/talks/2001/xugo/docbook/index.html">Publishingusing
+    DocBook XML</a></li>
+</ul><p>Do not use the --docbook option of xsltproc to process XML
+DocBookdocuments, this option is only intended to provide some (limited)
+support ofthe SGML version of DocBook.</p><p>Points which are not DocBook specific but still worth mentionningagain:</p><ul><li>if you think DocBook processing time is too slow, make sure you haveXML
+    Catalogs pointing to a local installation of the DTD of DocBook.Check the
+    <a href="http://xmlsoft.org/catalog.html">XML Catalog page</a>to
+    understand more on this subject.</li>
   <li>before processing a new document, use the command
     <p><code>xmllint --valid --noout path_to_document</code></p>
-    <p>to make sure that your input is valid DocBook. And fixes the errors
-    before processing further. Note that XSLT processing may work correctly
-    with some forms of validity errors left, but in general it can give
-    troubles on output.</p>
+    <p>to make sure that your input is valid DocBook. And fixes the
+    errorsbefore processing further. Note that XSLT processing may work
+    correctlywith some forms of validity errors left, but in general it can
+    givetroubles on output.</p>
   </li>
 </ul><p><a href="bugs.html">Daniel Veillard</a></p></td></tr></table></td></tr></table></td></tr></table></td></tr></table></td></tr></table></body></html>

Modified: packages/libxslt/trunk/doc/docs.html
===================================================================
--- packages/libxslt/trunk/doc/docs.html	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/doc/docs.html	2006-06-08 22:29:07 UTC (rev 565)
@@ -8,12 +8,11 @@
 H3 {font-family: Verdana,Arial,Helvetica}
 A:link, A:visited, A:active { text-decoration: underline }
     </style><title>Documentation</title></head><body bgcolor="#8b7765" text="#000000" link="#a06060" vlink="#000000"><table border="0" width="100%" cellpadding="5" cellspacing="0" align="center"><tr><td width="120"><a href="http://swpat.ffii.org/"><img src="epatents.png" alt="Action against software patents" /></a></td><td width="180"><a href="http://www.gnome.org/"><img src="gnome2.png" alt="Gnome2 Logo" /></a><a href="http://www.w3.org/Status"><img src="w3c.png" alt="W3C logo" /></a><a href="http://www.redhat.com"><img src="redhat.gif" alt="Red Hat Logo" /></a><div align="left"><a href="http://xmlsoft.org/XSLT/"><img src="Libxslt-Logo-180x168.gif" alt="Made with Libxslt Logo" /></a></div></td><td><table border="0" width="90%" cellpadding="2" cellspacing="0" align="center" bgcolor="#000000"><tr><td><table width="100%" border="0" cellspacing="1" cellpadding="3" bgcolor="#fffacd"><tr><td align="center"><h1>The XSLT C library for Gnome</h1><h2>Documentation</h2></td></tr></table></td></tr></table></td></tr></table><table border="0" cellpadding="4" cellspacing="0" width="100%" align="center"><tr><td bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="2" width="100%"><tr><td valign="top" width="200" bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000"><tr><td><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>Main Menu</b></center></td></tr><tr><td bgcolor="#fffacd"><form action="search.php" enctype="application/x-www-form-urlencoded" method="get"><input name="query" type="text" size="20" value="" /><input name="submit" type="submit" value="Search ..." /></form><ul><li><a href="index.html">Home</a></li><li><a href="http://xmlsoft.org/wiki">Wiki</a></li><li><a href="intro.html">Introduction</a></li><li><a href="docs.html">Documentation</a></li><li><a href="bugs.html">Reporting bugs and getting help</a></li><li><a href="help.html">How to help</a></li><li><a href="downloads.html">Downloads</a></li><li><a href="FAQ.html">FAQ</a></li><li><a href="news.html">News</a></li><li><a href="xsltproc2.html">The xsltproc tool</a></li><li><a href="docbook.html">DocBook</a></li><li><a href="API.html">The programming API</a></li><li><a href="python.html">Python and bindings</a></li><li><a href="internals.html">Library internals</a></li><li><a href="extensions.html">Writing extensions</a></li><li><a href="contribs.html">Contributions</a></li><li><a href="EXSLT/index.html" style="font-weight:bold">libexslt</a></li><li><a href="xslt.html">flat page</a>, <a href="site.xsl">stylesheet</a></li><li><a href="html/index.html" style="font-weight:bold">API Menu</a></li><li><a href="ChangeLog.html">ChangeLog</a></li></ul></td></tr></table><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>Related links</b></center></td></tr><tr><td bgcolor="#fffacd"><ul><li><a href="tutorial/libxslttutorial.html">Tutorial</a>,
-          <a href="tutorial2/libxslt_pipes.html">Tutorial2</a></li><li><a href="xsltproc.html">Man page for xsltproc</a></li><li><a href="http://mail.gnome.org/archives/xslt/">Mail archive</a></li><li><a href="http://xmlsoft.org/">XML libxml2</a></li><li><a href="ftp://xmlsoft.org/">FTP</a></li><li><a href="http://www.zlatkovic.com/projects/libxml/">Windows binaries</a></li><li><a href="http://garypennington.net/libxml2/">Solaris binaries</a></li><li><a href="http://www.explain.com.au/oss/libxml2xslt.html">MacOsX binaries</a></li><li><a href="http://bugzilla.gnome.org/buglist.cgi?product=libxslt">Bug Tracker</a></li><li><a href="http://www.zend.com/php5/articles/php5-xmlphp.php#Heading17">XSLT with PHP</a></li><li><a href="http://www.mod-xslt2.com/">Apache module</a></li><li><a href="http://sourceforge.net/projects/libxml2-pas/">Pascal bindings</a></li><li><a href="http://xsldbg.sourceforge.net/">Xsldbg Debugger</a></li></ul></td></tr></table><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>API Indexes</b></center></td></tr><tr><td bgcolor="#fffacd"><ul><li><a href="APIchunk0.html">Alphabetic</a></li><li><a href="APIconstructors.html">Constructors</a></li><li><a href="APIfunctions.html">Functions/Types</a></li><li><a href="APIfiles.html">Modules</a></li><li><a href="APIsymbols.html">Symbols</a></li></ul></td></tr></table></td></tr></table></td><td valign="top" bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="1" width="100%"><tr><td><table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000"><tr><td><table border="0" cellpadding="3" cellspacing="1" width="100%"><tr><td bgcolor="#fffacd"><p>There are some on-line resources about using libxslt:</p><ol><li>Check the <a href="html/libxslt-lib.html#LIBXSLT-LIB">API
-    documentation</a> automatically extracted from code comments (using the
-    program apibuild.py, developed for libxml, together with the xsl script
-    'newapi.xsl' and the libxslt xsltproc program).</li>
-  <li>Look at the <a href="http://mail.gnome.org/archives/xslt/">mailing-list
-    archive</a>.</li>
-  <li>Of course since libxslt is based on libxml, it's a good idea to at
-    least read <a href="http://xmlsoft.org/">libxml description</a></li>
+          <a href="tutorial2/libxslt_pipes.html">Tutorial2</a></li><li><a href="xsltproc.html">Man page for xsltproc</a></li><li><a href="http://mail.gnome.org/archives/xslt/">Mail archive</a></li><li><a href="http://xmlsoft.org/">XML libxml2</a></li><li><a href="ftp://xmlsoft.org/">FTP</a></li><li><a href="http://www.zlatkovic.com/projects/libxml/">Windows binaries</a></li><li><a href="http://garypennington.net/libxml2/">Solaris binaries</a></li><li><a href="http://www.explain.com.au/oss/libxml2xslt.html">MacOsX binaries</a></li><li><a href="http://bugzilla.gnome.org/buglist.cgi?product=libxslt">Bug Tracker</a></li><li><a href="http://www.zend.com/php5/articles/php5-xmlphp.php#Heading17">XSLT with PHP</a></li><li><a href="http://www.mod-xslt2.com/">Apache module</a></li><li><a href="http://sourceforge.net/projects/libxml2-pas/">Pascal bindings</a></li><li><a href="http://xsldbg.sourceforge.net/">Xsldbg Debugger</a></li></ul></td></tr></table><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>API Indexes</b></center></td></tr><tr><td bgcolor="#fffacd"><ul><li><a href="APIchunk0.html">Alphabetic</a></li><li><a href="APIconstructors.html">Constructors</a></li><li><a href="APIfunctions.html">Functions/Types</a></li><li><a href="APIfiles.html">Modules</a></li><li><a href="APIsymbols.html">Symbols</a></li></ul></td></tr></table></td></tr></table></td><td valign="top" bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="1" width="100%"><tr><td><table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000"><tr><td><table border="0" cellpadding="3" cellspacing="1" width="100%"><tr><td bgcolor="#fffacd"><p>There are some on-line resources about using libxslt:</p><ol><li>Check the <a href="html/libxslt-lib.html#LIBXSLT-LIB">APIdocumentation</a>automatically
+    extracted from code comments (using theprogram apibuild.py, developed for
+    libxml, together with the xsl script'newapi.xsl' and the libxslt xsltproc
+    program).</li>
+  <li>Look at the <a href="http://mail.gnome.org/archives/xslt/">mailing-listarchive</a>.</li>
+  <li>Of course since libxslt is based on libxml, it's a good idea to atleast
+    read <a href="http://xmlsoft.org/">libxml description</a></li>
 </ol><p><a href="bugs.html">Daniel Veillard</a></p></td></tr></table></td></tr></table></td></tr></table></td></tr></table></td></tr></table></body></html>

Modified: packages/libxslt/trunk/doc/downloads.html
===================================================================
--- packages/libxslt/trunk/doc/downloads.html	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/doc/downloads.html	2006-06-08 22:29:07 UTC (rev 565)
@@ -8,23 +8,21 @@
 H3 {font-family: Verdana,Arial,Helvetica}
 A:link, A:visited, A:active { text-decoration: underline }
     </style><title>Downloads</title></head><body bgcolor="#8b7765" text="#000000" link="#a06060" vlink="#000000"><table border="0" width="100%" cellpadding="5" cellspacing="0" align="center"><tr><td width="120"><a href="http://swpat.ffii.org/"><img src="epatents.png" alt="Action against software patents" /></a></td><td width="180"><a href="http://www.gnome.org/"><img src="gnome2.png" alt="Gnome2 Logo" /></a><a href="http://www.w3.org/Status"><img src="w3c.png" alt="W3C logo" /></a><a href="http://www.redhat.com"><img src="redhat.gif" alt="Red Hat Logo" /></a><div align="left"><a href="http://xmlsoft.org/XSLT/"><img src="Libxslt-Logo-180x168.gif" alt="Made with Libxslt Logo" /></a></div></td><td><table border="0" width="90%" cellpadding="2" cellspacing="0" align="center" bgcolor="#000000"><tr><td><table width="100%" border="0" cellspacing="1" cellpadding="3" bgcolor="#fffacd"><tr><td align="center"><h1>The XSLT C library for Gnome</h1><h2>Downloads</h2></td></tr></table></td></tr></table></td></tr></table><table border="0" cellpadding="4" cellspacing="0" width="100%" align="center"><tr><td bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="2" width="100%"><tr><td valign="top" width="200" bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000"><tr><td><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>Main Menu</b></center></td></tr><tr><td bgcolor="#fffacd"><form action="search.php" enctype="application/x-www-form-urlencoded" method="get"><input name="query" type="text" size="20" value="" /><input name="submit" type="submit" value="Search ..." /></form><ul><li><a href="index.html">Home</a></li><li><a href="http://xmlsoft.org/wiki">Wiki</a></li><li><a href="intro.html">Introduction</a></li><li><a href="docs.html">Documentation</a></li><li><a href="bugs.html">Reporting bugs and getting help</a></li><li><a href="help.html">How to help</a></li><li><a href="downloads.html">Downloads</a></li><li><a href="FAQ.html">FAQ</a></li><li><a href="news.html">News</a></li><li><a href="xsltproc2.html">The xsltproc tool</a></li><li><a href="docbook.html">DocBook</a></li><li><a href="API.html">The programming API</a></li><li><a href="python.html">Python and bindings</a></li><li><a href="internals.html">Library internals</a></li><li><a href="extensions.html">Writing extensions</a></li><li><a href="contribs.html">Contributions</a></li><li><a href="EXSLT/index.html" style="font-weight:bold">libexslt</a></li><li><a href="xslt.html">flat page</a>, <a href="site.xsl">stylesheet</a></li><li><a href="html/index.html" style="font-weight:bold">API Menu</a></li><li><a href="ChangeLog.html">ChangeLog</a></li></ul></td></tr></table><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>Related links</b></center></td></tr><tr><td bgcolor="#fffacd"><ul><li><a href="tutorial/libxslttutorial.html">Tutorial</a>,
-          <a href="tutorial2/libxslt_pipes.html">Tutorial2</a></li><li><a href="xsltproc.html">Man page for xsltproc</a></li><li><a href="http://mail.gnome.org/archives/xslt/">Mail archive</a></li><li><a href="http://xmlsoft.org/">XML libxml2</a></li><li><a href="ftp://xmlsoft.org/">FTP</a></li><li><a href="http://www.zlatkovic.com/projects/libxml/">Windows binaries</a></li><li><a href="http://garypennington.net/libxml2/">Solaris binaries</a></li><li><a href="http://www.explain.com.au/oss/libxml2xslt.html">MacOsX binaries</a></li><li><a href="http://bugzilla.gnome.org/buglist.cgi?product=libxslt">Bug Tracker</a></li><li><a href="http://www.zend.com/php5/articles/php5-xmlphp.php#Heading17">XSLT with PHP</a></li><li><a href="http://www.mod-xslt2.com/">Apache module</a></li><li><a href="http://sourceforge.net/projects/libxml2-pas/">Pascal bindings</a></li><li><a href="http://xsldbg.sourceforge.net/">Xsldbg Debugger</a></li></ul></td></tr></table><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>API Indexes</b></center></td></tr><tr><td bgcolor="#fffacd"><ul><li><a href="APIchunk0.html">Alphabetic</a></li><li><a href="APIconstructors.html">Constructors</a></li><li><a href="APIfunctions.html">Functions/Types</a></li><li><a href="APIfiles.html">Modules</a></li><li><a href="APIsymbols.html">Symbols</a></li></ul></td></tr></table></td></tr></table></td><td valign="top" bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="1" width="100%"><tr><td><table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000"><tr><td><table border="0" cellpadding="3" cellspacing="1" width="100%"><tr><td bgcolor="#fffacd"><p>The latest versions of libxslt can be found on the <a href="ftp://xmlsoft.org/libxslt/">xmlsoft.org</a> server and on mirrors (<a href="ftp://fr.rpmfind.net/pub/libxml/">France</a>) or on the <a href="ftp://ftp.gnome.org/pub/GNOME/MIRRORS.html">Gnome FTP server</a> as a
-<a href="ftp://ftp.gnome.org/pub/GNOME/sources/libxslt/1.1/">source
-archive</a>, Antonin Sprinzl also provides <a href="ftp://gd.tuwien.ac.at/pub/libxml/">a mirror in Austria</a>. (NOTE that
-you need the <a href="http://rpmfind.net/linux/RPM/libxml2.html">libxml2</a>,
-<a href="http://rpmfind.net/linux/RPM/libxml2-devel.html">libxml2-devel</a>,
-<a href="http://rpmfind.net/linux/RPM/libxslt.html">libxslt</a> and <a href="http://rpmfind.net/linux/RPM/libxslt-devel.html">libxslt-devel</a>
-packages installed to compile applications using libxslt.) <a href="mailto:igor at zlatkovic.com">Igor Zlatkovic</a> is now the maintainer of
-the Windows port, <a href="http://www.zlatkovic.com/projects/libxml/index.html">he provides
-binaries</a>. <a href="mailto:Gary.Pennington at sun.com">Gary Pennington</a>
-provides <a href="http://garypennington.net/libxml2/">Solaris binaries</a>.
-<a href="mailto:Steve.Ball at explain.com.au">Steve Ball</a> provides <a href="http://www.explain.com.au/oss/libxml2xslt.html">Mac Os X
-binaries</a>.</p><p><a name="Contribs" id="Contribs">Contribs:</a></p><p>I do accept external contributions, especially if compiling on another
-platform, get in touch with me to upload the package. I will keep them in the
-<a href="ftp://xmlsoft.org/libxml2/contribs/">contrib directory</a></p><p>Libxslt is also available from CVS:</p><ul><li><p>The <a href="http://cvs.gnome.org/viewcvs/libxslt/">Gnome CVS
-    base</a>. Check the <a href="http://developer.gnome.org/tools/cvs.html">Gnome CVS Tools</a>
-    page; the CVS module is <b>libxslt</b>.</p>
+          <a href="tutorial2/libxslt_pipes.html">Tutorial2</a></li><li><a href="xsltproc.html">Man page for xsltproc</a></li><li><a href="http://mail.gnome.org/archives/xslt/">Mail archive</a></li><li><a href="http://xmlsoft.org/">XML libxml2</a></li><li><a href="ftp://xmlsoft.org/">FTP</a></li><li><a href="http://www.zlatkovic.com/projects/libxml/">Windows binaries</a></li><li><a href="http://garypennington.net/libxml2/">Solaris binaries</a></li><li><a href="http://www.explain.com.au/oss/libxml2xslt.html">MacOsX binaries</a></li><li><a href="http://bugzilla.gnome.org/buglist.cgi?product=libxslt">Bug Tracker</a></li><li><a href="http://www.zend.com/php5/articles/php5-xmlphp.php#Heading17">XSLT with PHP</a></li><li><a href="http://www.mod-xslt2.com/">Apache module</a></li><li><a href="http://sourceforge.net/projects/libxml2-pas/">Pascal bindings</a></li><li><a href="http://xsldbg.sourceforge.net/">Xsldbg Debugger</a></li></ul></td></tr></table><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>API Indexes</b></center></td></tr><tr><td bgcolor="#fffacd"><ul><li><a href="APIchunk0.html">Alphabetic</a></li><li><a href="APIconstructors.html">Constructors</a></li><li><a href="APIfunctions.html">Functions/Types</a></li><li><a href="APIfiles.html">Modules</a></li><li><a href="APIsymbols.html">Symbols</a></li></ul></td></tr></table></td></tr></table></td><td valign="top" bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="1" width="100%"><tr><td><table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000"><tr><td><table border="0" cellpadding="3" cellspacing="1" width="100%"><tr><td bgcolor="#fffacd"><p>The latest versions of libxslt can be found on the <a href="ftp://xmlsoft.org/libxslt/">xmlsoft.org</a>server and on mirrors (<a href="ftp://fr.rpmfind.net/pub/libxml/">France</a>) or on the <a href="ftp://ftp.gnome.org/pub/GNOME/MIRRORS.html">Gnome FTP server</a>as a<a href="ftp://ftp.gnome.org/pub/GNOME/sources/libxslt/1.1/">sourcearchive</a>,
+Antonin Sprinzl also provides <a href="ftp://gd.tuwien.ac.at/pub/libxml/">a
+mirror in Austria</a>. (NOTE thatyou need the <a href="http://rpmfind.net/linux/RPM/libxml2.html">libxml2</a>,<a href="http://rpmfind.net/linux/RPM/libxml2-devel.html">libxml2-devel</a>,<a href="http://rpmfind.net/linux/RPM/libxslt.html">libxslt</a>and <a href="http://rpmfind.net/linux/RPM/libxslt-devel.html">libxslt-devel</a>packages
+installed to compile applications using libxslt.) <a href="mailto:igor at zlatkovic.com">Igor Zlatkovic</a>is now the maintainer
+ofthe Windows port, <a href="http://www.zlatkovic.com/projects/libxml/index.html">he
+providesbinaries</a>. <a href="mailto:Gary.Pennington at sun.com">Gary
+Pennington</a>provides <a href="http://garypennington.net/libxml2/">Solaris
+binaries</a>.<a href="mailto:Steve.Ball at explain.com.au">Steve
+Ball</a>provides <a href="http://www.explain.com.au/oss/libxml2xslt.html">Mac
+Os Xbinaries</a>.</p><p><a name="Contribs" id="Contribs">Contribs:</a></p><p>I do accept external contributions, especially if compiling on
+anotherplatform, get in touch with me to upload the package. I will keep them
+in the<a href="ftp://xmlsoft.org/libxml2/contribs/">contrib directory</a></p><p>Libxslt is also available from CVS:</p><ul><li><p>The <a href="http://cvs.gnome.org/viewcvs/libxslt/">Gnome
+    CVSbase</a>. Check the <a href="http://developer.gnome.org/tools/cvs.html">Gnome CVS Tools</a>page;
+    the CVS module is <b>libxslt</b>.</p>
   </li>
-  <li><a href="ftp://xmlsoft.org/libxml2/libxslt-cvs-snapshot.tar.gz">snapshots from
-    CVS</a> updated every hour are also provided</li>
+  <li><a href="ftp://xmlsoft.org/libxml2/libxslt-cvs-snapshot.tar.gz">snapshots
+    fromCVS</a>updated every hour are also provided</li>
 </ul><p><a href="bugs.html">Daniel Veillard</a></p></td></tr></table></td></tr></table></td></tr></table></td></tr></table></td></tr></table></body></html>

Modified: packages/libxslt/trunk/doc/extensions.html
===================================================================
--- packages/libxslt/trunk/doc/extensions.html	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/doc/extensions.html	2006-06-08 22:29:07 UTC (rev 565)
@@ -13,54 +13,53 @@
   <li><a href="extensions.html#Keep">Extension modules</a></li>
   <li><a href="extensions.html#Registerin">Registering a module</a></li>
   <li><a href="extensions.html#module">Loading a module</a></li>
-  <li><a href="extensions.html#Registerin1">Registering an extension
-    function</a></li>
-  <li><a href="extensions.html#Implementi">Implementing an extension
-    function</a></li>
-  <li><a href="extensions.html#Examples">Examples for extension
-  functions</a></li>
-  <li><a href="extensions.html#Registerin2">Registering an extension
-    element</a></li>
-  <li><a href="extensions.html#Implementi1">Implementing an extension
-    element</a></li>
-  <li><a href="extensions.html#Example">Example for extension
-  elements</a></li>
+  <li><a href="extensions.html#Registerin1">Registering an
+    extensionfunction</a></li>
+  <li><a href="extensions.html#Implementi">Implementing an
+    extensionfunction</a></li>
+  <li><a href="extensions.html#Examples">Examples for
+  extensionfunctions</a></li>
+  <li><a href="extensions.html#Registerin2">Registering an
+    extensionelement</a></li>
+  <li><a href="extensions.html#Implementi1">Implementing an
+    extensionelement</a></li>
+  <li><a href="extensions.html#Example">Example for extensionelements</a></li>
   <li><a href="extensions.html#shutdown">The shutdown of a module</a></li>
   <li><a href="extensions.html#Future">Future work</a></li>
-</ul><h3><a name="Introducti1" id="Introducti1">Introduction</a></h3><p>This document describes the work needed to write extensions to the
-standard XSLT library for use with <a href="http://xmlsoft.org/XSLT/">libxslt</a>, the <a href="http://www.w3.org/TR/xslt">XSLT</a> C library developed for the <a href="http://www.gnome.org/">Gnome</a> project.</p><p>Before starting reading this document it is highly recommended to get
-familiar with <a href="internals.html">the libxslt internals</a>.</p><p>Note: this documentation is by definition incomplete and I am not good at
-spelling, grammar, so patches and suggestions are <a href="mailto:veillard at redhat.com">really welcome</a>.</p><h3><a name="Basics" id="Basics">Basics</a></h3><p>The <a href="http://www.w3.org/TR/xslt">XSLT specification</a> provides
-two <a href="http://www.w3.org/TR/xslt">ways to extend an XSLT engine</a>:</p><ul><li>providing <a href="http://www.w3.org/TR/xslt">new extension
-    functions</a> which can be called from XPath expressions</li>
-  <li>providing <a href="http://www.w3.org/TR/xslt">new extension
-    elements</a> which can be inserted in stylesheets</li>
-</ul><p>In both cases the extensions need to be associated to a new namespace,
-i.e. an URI used as the name for the extension's namespace (there is no need
-to have a resource there for this to work).</p><p>libxslt provides a few extensions itself, either in the libxslt namespace
-"http://xmlsoft.org/XSLT/namespace" or in namespaces for other well known
-extensions provided by other XSLT processors like Saxon, Xalan or XT.</p><h3><a name="Keep" id="Keep">Extension modules</a></h3><p>Since extensions are bound to a namespace name, usually sets of extensions
-coming from a given source are using the same namespace name defining in
-practice a group of extensions providing elements, functions or both. From
-the libxslt point of view those are considered as an "extension module", and
-most of the APIs work at a module point of view.</p><p>Registration of new functions or elements are bound to the activation of
-the module. This is currently done by declaring the namespace as an extension
-by using the attribute  <code>extension-element-prefixes</code> on the
-<code><a href="http://www.w3.org/TR/xslt">xsl:stylesheet</a></code>
-element.</p><p>An extension module is defined by 3 objects:</p><ul><li>the namespace name associated</li>
+</ul><h3><a name="Introducti1" id="Introducti1">Introduction</a></h3><p>This document describes the work needed to write extensions to thestandard
+XSLT library for use with <a href="http://xmlsoft.org/XSLT/">libxslt</a>, the
+<a href="http://www.w3.org/TR/xslt">XSLT</a>C library developed for the <a href="http://www.gnome.org/">Gnome</a>project.</p><p>Before starting reading this document it is highly recommended to
+getfamiliar with <a href="internals.html">the libxslt internals</a>.</p><p>Note: this documentation is by definition incomplete and I am not good
+atspelling, grammar, so patches and suggestions are <a href="mailto:veillard at redhat.com">really welcome</a>.</p><h3><a name="Basics" id="Basics">Basics</a></h3><p>The <a href="http://www.w3.org/TR/xslt">XSLT specification</a>providestwo
+<a href="http://www.w3.org/TR/xslt">ways to extend an XSLT engine</a>:</p><ul><li>providing <a href="http://www.w3.org/TR/xslt">new
+    extensionfunctions</a>which can be called from XPath expressions</li>
+  <li>providing <a href="http://www.w3.org/TR/xslt">new
+    extensionelements</a>which can be inserted in stylesheets</li>
+</ul><p>In both cases the extensions need to be associated to a new namespace,i.e.
+an URI used as the name for the extension's namespace (there is no needto
+have a resource there for this to work).</p><p>libxslt provides a few extensions itself, either in the libxslt
+namespace"http://xmlsoft.org/XSLT/namespace" or in namespaces for other well
+knownextensions provided by other XSLT processors like Saxon, Xalan or XT.</p><h3><a name="Keep" id="Keep">Extension modules</a></h3><p>Since extensions are bound to a namespace name, usually sets of
+extensionscoming from a given source are using the same namespace name
+defining inpractice a group of extensions providing elements, functions or
+both. Fromthe libxslt point of view those are considered as an "extension
+module", andmost of the APIs work at a module point of view.</p><p>Registration of new functions or elements are bound to the activation
+ofthe module. This is currently done by declaring the namespace as an
+extensionby using the attribute  <code>extension-element-prefixes</code>on
+the<code><a href="http://www.w3.org/TR/xslt">xsl:stylesheet</a></code>element.</p><p>An extension module is defined by 3 objects:</p><ul><li>the namespace name associated</li>
   <li>an initialization function</li>
   <li>a shutdown function</li>
-</ul><h3><a name="Registerin" id="Registerin">Registering a module</a></h3><p>Currently a libxslt module has to be compiled within the application using
-libxslt. There is no code to load dynamically shared libraries associated to
-a namespace (this may be added but is likely to become a portability
-nightmare).</p><p>The current way to register a module is to link the code implementing it
-with the application and to call a registration function:</p><pre>int xsltRegisterExtModule(const xmlChar *URI,
+</ul><h3><a name="Registerin" id="Registerin">Registering a module</a></h3><p>Currently a libxslt module has to be compiled within the application
+usinglibxslt. There is no code to load dynamically shared libraries
+associated toa namespace (this may be added but is likely to become a
+portabilitynightmare).</p><p>The current way to register a module is to link the code implementing
+itwith the application and to call a registration function:</p><pre>int xsltRegisterExtModule(const xmlChar *URI,
                           xsltExtInitFunction initFunc,
-                          xsltExtShutdownFunction shutdownFunc);</pre><p>The associated header is read by:</p><pre>#include&lt;libxslt/extensions.h&gt;</pre><p>which also defines the type for the initialization and shutdown
-functions</p><h3><a name="module" id="module">Loading a module</a></h3><p>Once the module URI has been registered and if the XSLT processor detects
-that a given stylesheet needs the functionalities of an extended module, this
-one is initialized.</p><p>The xsltExtInitFunction type defines the interface for an initialization
-function:</p><pre>/**
+                          xsltExtShutdownFunction shutdownFunc);</pre><p>The associated header is read by:</p><pre>#include&lt;libxslt/extensions.h&gt;</pre><p>which also defines the type for the initialization and
+shutdownfunctions</p><h3><a name="module" id="module">Loading a module</a></h3><p>Once the module URI has been registered and if the XSLT processor
+detectsthat a given stylesheet needs the functionalities of an extended
+module, thisone is initialized.</p><p>The xsltExtInitFunction type defines the interface for an
+initializationfunction:</p><pre>/**
  * xsltExtInitFunction:
  * @ctxt:  an XSLT transformation context
  * @URI:  the namespace URI for the extension
@@ -72,30 +71,30 @@
  * transformation
  */
 typedef void *(*xsltExtInitFunction)(xsltTransformContextPtr ctxt,
-                                     const xmlChar *URI);</pre><p>There are 3 things to notice:</p><ul><li>The function gets passed the namespace name URI as an argument. This
-    allows a single function to provide the initialization for multiple
-    logical modules.</li>
-  <li>It also gets passed a transformation context. The initialization is
-    done at run time before any processing occurs on the stylesheet but it
-    will be invoked separately each time for each transformation.</li>
-  <li>It returns a pointer.  This can be used to store module specific
-    information which can be retrieved later when a function or an element
-    from the extension is used.  An obvious example is a connection to a
-    database which should be kept and reused along with the transformation.
-    NULL is a perfectly valid return; there is no way to indicate a failure
-    at this level</li>
-</ul><p>What this function is expected to do is:</p><ul><li>prepare the context for this module (like opening the database
-    connection)</li>
+                                     const xmlChar *URI);</pre><p>There are 3 things to notice:</p><ul><li>The function gets passed the namespace name URI as an argument.
+    Thisallows a single function to provide the initialization for
+    multiplelogical modules.</li>
+  <li>It also gets passed a transformation context. The initialization isdone
+    at run time before any processing occurs on the stylesheet but itwill be
+    invoked separately each time for each transformation.</li>
+  <li>It returns a pointer.  This can be used to store module
+    specificinformation which can be retrieved later when a function or an
+    elementfrom the extension is used.  An obvious example is a connection to
+    adatabase which should be kept and reused along with the
+    transformation.NULL is a perfectly valid return; there is no way to
+    indicate a failureat this level</li>
+</ul><p>What this function is expected to do is:</p><ul><li>prepare the context for this module (like opening the
+    databaseconnection)</li>
   <li>register the extensions specific to this module</li>
 </ul><h3><a name="Registerin1" id="Registerin1">Registering an extension function</a></h3><p>There is a single call to do this registration:</p><pre>int xsltRegisterExtFunction(xsltTransformContextPtr ctxt,
                             const xmlChar *name,
                             const xmlChar *URI,
-                            xmlXPathEvalFunc function);</pre><p>The registration is bound to a single transformation instance referred by
-ctxt, name is the UTF8 encoded name for the NCName of the function, and URI
-is the namespace name for the extension (no checking is done, a module could
-register functions or elements from a different namespace, but it is not
-recommended).</p><h3><a name="Implementi" id="Implementi">Implementing an extension function</a></h3><p>The implementation of the function must have the signature of a libxml
-XPath function:</p><pre>/**
+                            xmlXPathEvalFunc function);</pre><p>The registration is bound to a single transformation instance referred
+byctxt, name is the UTF8 encoded name for the NCName of the function, and
+URIis the namespace name for the extension (no checking is done, a module
+couldregister functions or elements from a different namespace, but it is
+notrecommended).</p><h3><a name="Implementi" id="Implementi">Implementing an extension function</a></h3><p>The implementation of the function must have the signature of a
+libxmlXPath function:</p><pre>/**
  * xmlXPathEvalFunc:
  * @ctxt: an XPath parser context
  * @nargs: the number of arguments passed to the function
@@ -105,43 +104,43 @@
  */
 
 typedef void (*xmlXPathEvalFunc)(xmlXPathParserContextPtr ctxt,
-                                 int nargs);</pre><p>The context passed to an XPath function is not an XSLT context but an <a href="internals.html#XPath1">XPath context</a>. However it is possible to
-find one from the other:</p><ul><li>The function xsltXPathGetTransformContext provides this lookup facility:
+                                 int nargs);</pre><p>The context passed to an XPath function is not an XSLT context but an <a href="internals.html#XPath1">XPath context</a>. However it is possible tofind
+one from the other:</p><ul><li>The function xsltXPathGetTransformContext provides this lookup facility:
     <pre>xsltTransformContextPtr
          xsltXPathGetTransformContext
                           (xmlXPathParserContextPtr ctxt);</pre>
   </li>
-  <li>The <code>xmlXPathContextPtr</code> associated to an
-    <code>xsltTransformContext</code> is stored in the <code>xpathCtxt</code>
-    field.</li>
-</ul><p>The first thing an extension function may want to do is to check the
-arguments passed on the stack, the <code>nargs</code> parameter will tell how
-many of them were provided on the XPath expression. The macro valuePop will
-extract them from the XPath stack:</p><pre>#include &lt;libxml/xpath.h&gt;
+  <li>The <code>xmlXPathContextPtr</code>associated to
+    an<code>xsltTransformContext</code>is stored in the
+    <code>xpathCtxt</code>field.</li>
+</ul><p>The first thing an extension function may want to do is to check
+thearguments passed on the stack, the <code>nargs</code>parameter will tell
+howmany of them were provided on the XPath expression. The macro valuePop
+willextract them from the XPath stack:</p><pre>#include &lt;libxml/xpath.h&gt;
 #include &lt;libxml/xpathInternals.h&gt;
 
-xmlXPathObjectPtr obj = valuePop(ctxt); </pre><p>Note that <code>ctxt</code> is the XPath context not the XSLT one. It is
-then possible to examine the content of the value. Check <a href="internals.html#Descriptio">the description of XPath objects</a> if
-necessary. The following is a common sequence checking whether the argument
-passed is a string and converting it using the built-in XPath
-<code>string()</code> function if this is not the case:</p><pre>if (obj-&gt;type != XPATH_STRING) {
+xmlXPathObjectPtr obj = valuePop(ctxt); </pre><p>Note that <code>ctxt</code>is the XPath context not the XSLT one. It
+isthen possible to examine the content of the value. Check <a href="internals.html#Descriptio">the description of XPath
+objects</a>ifnecessary. The following is a common sequence checking whether
+the argumentpassed is a string and converting it using the built-in
+XPath<code>string()</code>function if this is not the case:</p><pre>if (obj-&gt;type != XPATH_STRING) {
     valuePush(ctxt, obj);
     xmlXPathStringFunction(ctxt, 1);
     obj = valuePop(ctxt);
-}</pre><p>Most common XPath functions are available directly at the C level and are
-exported either in <code>&lt;libxml/xpath.h&gt;</code> or in
-<code>&lt;libxml/xpathInternals.h&gt;</code>.</p><p>The extension function may also need to retrieve the data associated to
-this module instance (the database connection in the previous example) this
-can be done using the xsltGetExtData:</p><pre>void * xsltGetExtData(xsltTransformContextPtr ctxt,
-                      const xmlChar *URI);</pre><p>Again the URI to be provided is the one which was used when registering
-the module.</p><p>Once the function finishes, don't forget to:</p><ul><li>push the return value on the stack using <code>valuePush(ctxt,
-    obj)</code></li>
-  <li>deallocate the parameters passed to the function using
-    <code>xmlXPathFreeObject(obj)</code></li>
-</ul><h3><a name="Examples" id="Examples">Examples for extension functions</a></h3><p>The module libxslt/functions.c contains the sources of the XSLT built-in
-functions, including document(), key(), generate-id(), etc. as well as a full
-example module at the end. Here is the test function implementation for the
-libxslt:test function:</p><pre>/**
+}</pre><p>Most common XPath functions are available directly at the C level and
+areexported either in <code>&lt;libxml/xpath.h&gt;</code>or
+in<code>&lt;libxml/xpathInternals.h&gt;</code>.</p><p>The extension function may also need to retrieve the data associated
+tothis module instance (the database connection in the previous example)
+thiscan be done using the xsltGetExtData:</p><pre>void * xsltGetExtData(xsltTransformContextPtr ctxt,
+                      const xmlChar *URI);</pre><p>Again the URI to be provided is the one which was used when registeringthe
+module.</p><p>Once the function finishes, don't forget to:</p><ul><li>push the return value on the stack using
+    <code>valuePush(ctxt,obj)</code></li>
+  <li>deallocate the parameters passed to the function
+    using<code>xmlXPathFreeObject(obj)</code></li>
+</ul><h3><a name="Examples" id="Examples">Examples for extension functions</a></h3><p>The module libxslt/functions.c contains the sources of the XSLT
+built-infunctions, including document(), key(), generate-id(), etc. as well
+as a fullexample module at the end. Here is the test function implementation
+for thelibxslt:test function:</p><pre>/**
  * xsltExtFunctionTest:
  * @ctxt:  the XPath Parser context
  * @nargs:  the number of arguments
@@ -173,13 +172,14 @@
 }</pre><h3><a name="Registerin2" id="Registerin2">Registering an extension element</a></h3><p>There is a single call to do this registration:</p><pre>int xsltRegisterExtElement(xsltTransformContextPtr ctxt,
                            const xmlChar *name,
                            const xmlChar *URI,
-                           xsltTransformFunction function);</pre><p>It is similar to the mechanism used to register an extension function,
-except that the signature of an extension element implementation is
-different.</p><p>The registration is bound to a single transformation instance referred to
-by ctxt, name is the UTF8 encoded name for the NCName of the element, and URI
-is the namespace name for the extension (no checking is done, a module could
-register elements for a different namespace, but it is not recommended).</p><h3><a name="Implementi1" id="Implementi1">Implementing an extension element</a></h3><p>The implementation of the element must have the signature of an XSLT
-transformation function:</p><pre>/** 
+                           xsltTransformFunction function);</pre><p>It is similar to the mechanism used to register an extension
+function,except that the signature of an extension element implementation
+isdifferent.</p><p>The registration is bound to a single transformation instance referred
+toby ctxt, name is the UTF8 encoded name for the NCName of the element, and
+URIis the namespace name for the extension (no checking is done, a module
+couldregister elements for a different namespace, but it is not
+recommended).</p><h3><a name="Implementi1" id="Implementi1">Implementing an extension element</a></h3><p>The implementation of the element must have the signature of an
+XSLTtransformation function:</p><pre>/** 
  * xsltTransformFunction: 
  * @ctxt: the XSLT transformation context
  * @node: the input node
@@ -193,27 +193,27 @@
                           (xsltTransformContextPtr ctxt,
                            xmlNodePtr node,
                            xmlNodePtr inst,
-                           xsltStylePreCompPtr comp);</pre><p>The first argument is the XSLT transformation context. The second and
-third arguments are xmlNodePtr i.e. internal memory <a href="internals.html#libxml">representation of  XML nodes</a>. They are
-respectively <code>node</code> from the the input document being transformed
-by the stylesheet and <code>inst</code> the extension element in the
-stylesheet. The last argument is <code>comp</code> a pointer to a precompiled
-representation of <code>inst</code> but usually for an extension function
-this value is <code>NULL</code> by default (it could be added and associated
-to the instruction in <code>inst-&gt;_private</code>).</p><p>The same functions are available from a function implementing an extension
-element as in an extension function, including
-<code>xsltGetExtData()</code>.</p><p>The goal of an extension element being usually to enrich the generated
-output, it is expected that they will grow the currently generated output
-tree. This can be done by grabbing ctxt-&gt;insert which is the current
-libxml node being generated (Note this can also be the intermediate value
-tree being built for example to initialize a variable, the processing should
-be similar). The functions for libxml tree manipulation from <a href="http://xmlsoft.org/html/libxml-tree.html">&lt;libxml/tree.h&gt;</a> can
-be employed to extend or modify the tree, but it is required to preserve the
-insertion node and its ancestors since there are existing pointers to those
-elements still in use in the XSLT template execution stack.</p><h3><a name="Example" id="Example">Example for extension elements</a></h3><p>The module libxslt/transform.c contains the sources of the XSLT built-in
-elements, including xsl:element, xsl:attribute, xsl:if, etc. There is a small
-but full example in functions.c providing the implementation for the
-libxslt:test element, it will output a comment in the result tree:</p><pre>/**
+                           xsltStylePreCompPtr comp);</pre><p>The first argument is the XSLT transformation context. The second andthird
+arguments are xmlNodePtr i.e. internal memory <a href="internals.html#libxml">representation of  XML nodes</a>. They
+arerespectively <code>node</code>from the the input document being
+transformedby the stylesheet and <code>inst</code>the extension element in
+thestylesheet. The last argument is <code>comp</code>a pointer to a
+precompiledrepresentation of <code>inst</code>but usually for an extension
+functionthis value is <code>NULL</code>by default (it could be added and
+associatedto the instruction in <code>inst-&gt;_private</code>).</p><p>The same functions are available from a function implementing an
+extensionelement as in an extension function,
+including<code>xsltGetExtData()</code>.</p><p>The goal of an extension element being usually to enrich the
+generatedoutput, it is expected that they will grow the currently generated
+outputtree. This can be done by grabbing ctxt-&gt;insert which is the
+currentlibxml node being generated (Note this can also be the intermediate
+valuetree being built for example to initialize a variable, the processing
+shouldbe similar). The functions for libxml tree manipulation from <a href="http://xmlsoft.org/html/libxml-tree.html">&lt;libxml/tree.h&gt;</a>canbe
+employed to extend or modify the tree, but it is required to preserve
+theinsertion node and its ancestors since there are existing pointers to
+thoseelements still in use in the XSLT template execution stack.</p><h3><a name="Example" id="Example">Example for extension elements</a></h3><p>The module libxslt/transform.c contains the sources of the XSLT
+built-inelements, including xsl:element, xsl:attribute, xsl:if, etc. There is
+a smallbut full example in functions.c providing the implementation for
+thelibxslt:test element, it will output a comment in the result tree:</p><pre>/**
  * xsltExtElementTest:
  * @ctxt:  an XSLT processing context
  * @node:  The current node
@@ -253,10 +253,10 @@
         xmlNewComment((const xmlChar *)
                       "libxslt:test element test worked");
     xmlAddChild(ctxt-&gt;insert, comment);
-}</pre><h3><a name="shutdown" id="shutdown">The shutdown of a module</a></h3><p>When the XSLT processor ends a transformation, the shutdown function (if
-it exists) for each of the modules initialized is called.  The
-xsltExtShutdownFunction type defines the interface for a shutdown
-function:</p><pre>/**
+}</pre><h3><a name="shutdown" id="shutdown">The shutdown of a module</a></h3><p>When the XSLT processor ends a transformation, the shutdown function (ifit
+exists) for each of the modules initialized is called. 
+ThexsltExtShutdownFunction type defines the interface for a
+shutdownfunction:</p><pre>/**
  * xsltExtShutdownFunction:
  * @ctxt:  an XSLT transformation context
  * @URI:  the namespace URI for the extension
@@ -266,14 +266,15 @@
  */
 typedef void (*xsltExtShutdownFunction) (xsltTransformContextPtr ctxt,
                                          const xmlChar *URI,
-                                         void *data);</pre><p>This is really similar to a module initialization function except a third
-argument is passed, it's the value that was returned by the initialization
-function. This allows the routine to deallocate resources from the module for
-example close the connection to the database to keep the same example.</p><h3><a name="Future" id="Future">Future work</a></h3><p>Well, some of the pieces missing:</p><ul><li>a way to load shared libraries to instantiate new modules</li>
-  <li>a better detection of extension functions usage and their registration
-    without having to use the extension prefix which ought to be reserved to
-    element extensions.</li>
+                                         void *data);</pre><p>This is really similar to a module initialization function except a
+thirdargument is passed, it's the value that was returned by the
+initializationfunction. This allows the routine to deallocate resources from
+the module forexample close the connection to the database to keep the same
+example.</p><h3><a name="Future" id="Future">Future work</a></h3><p>Well, some of the pieces missing:</p><ul><li>a way to load shared libraries to instantiate new modules</li>
+  <li>a better detection of extension functions usage and their
+    registrationwithout having to use the extension prefix which ought to be
+    reserved toelement extensions.</li>
   <li>more examples</li>
-  <li>implementations of the <a href="http://www.exslt.org/">EXSLT</a> common
-    extension libraries, Thomas Broyer nearly finished implementing them.</li>
+  <li>implementations of the <a href="http://www.exslt.org/">EXSLT</a>commonextension libraries, Thomas
+    Broyer nearly finished implementing them.</li>
 </ul><p></p><p><a href="bugs.html">Daniel Veillard</a></p></td></tr></table></td></tr></table></td></tr></table></td></tr></table></td></tr></table></body></html>

Modified: packages/libxslt/trunk/doc/help.html
===================================================================
--- packages/libxslt/trunk/doc/help.html	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/doc/help.html	2006-06-08 22:29:07 UTC (rev 565)
@@ -8,18 +8,18 @@
 H3 {font-family: Verdana,Arial,Helvetica}
 A:link, A:visited, A:active { text-decoration: underline }
     </style><title>How to help</title></head><body bgcolor="#8b7765" text="#000000" link="#a06060" vlink="#000000"><table border="0" width="100%" cellpadding="5" cellspacing="0" align="center"><tr><td width="120"><a href="http://swpat.ffii.org/"><img src="epatents.png" alt="Action against software patents" /></a></td><td width="180"><a href="http://www.gnome.org/"><img src="gnome2.png" alt="Gnome2 Logo" /></a><a href="http://www.w3.org/Status"><img src="w3c.png" alt="W3C logo" /></a><a href="http://www.redhat.com"><img src="redhat.gif" alt="Red Hat Logo" /></a><div align="left"><a href="http://xmlsoft.org/XSLT/"><img src="Libxslt-Logo-180x168.gif" alt="Made with Libxslt Logo" /></a></div></td><td><table border="0" width="90%" cellpadding="2" cellspacing="0" align="center" bgcolor="#000000"><tr><td><table width="100%" border="0" cellspacing="1" cellpadding="3" bgcolor="#fffacd"><tr><td align="center"><h1>The XSLT C library for Gnome</h1><h2>How to help</h2></td></tr></table></td></tr></table></td></tr></table><table border="0" cellpadding="4" cellspacing="0" width="100%" align="center"><tr><td bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="2" width="100%"><tr><td valign="top" width="200" bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000"><tr><td><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>Main Menu</b></center></td></tr><tr><td bgcolor="#fffacd"><form action="search.php" enctype="application/x-www-form-urlencoded" method="get"><input name="query" type="text" size="20" value="" /><input name="submit" type="submit" value="Search ..." /></form><ul><li><a href="index.html">Home</a></li><li><a href="http://xmlsoft.org/wiki">Wiki</a></li><li><a href="intro.html">Introduction</a></li><li><a href="docs.html">Documentation</a></li><li><a href="bugs.html">Reporting bugs and getting help</a></li><li><a href="help.html">How to help</a></li><li><a href="downloads.html">Downloads</a></li><li><a href="FAQ.html">FAQ</a></li><li><a href="news.html">News</a></li><li><a href="xsltproc2.html">The xsltproc tool</a></li><li><a href="docbook.html">DocBook</a></li><li><a href="API.html">The programming API</a></li><li><a href="python.html">Python and bindings</a></li><li><a href="internals.html">Library internals</a></li><li><a href="extensions.html">Writing extensions</a></li><li><a href="contribs.html">Contributions</a></li><li><a href="EXSLT/index.html" style="font-weight:bold">libexslt</a></li><li><a href="xslt.html">flat page</a>, <a href="site.xsl">stylesheet</a></li><li><a href="html/index.html" style="font-weight:bold">API Menu</a></li><li><a href="ChangeLog.html">ChangeLog</a></li></ul></td></tr></table><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>Related links</b></center></td></tr><tr><td bgcolor="#fffacd"><ul><li><a href="tutorial/libxslttutorial.html">Tutorial</a>,
-          <a href="tutorial2/libxslt_pipes.html">Tutorial2</a></li><li><a href="xsltproc.html">Man page for xsltproc</a></li><li><a href="http://mail.gnome.org/archives/xslt/">Mail archive</a></li><li><a href="http://xmlsoft.org/">XML libxml2</a></li><li><a href="ftp://xmlsoft.org/">FTP</a></li><li><a href="http://www.zlatkovic.com/projects/libxml/">Windows binaries</a></li><li><a href="http://garypennington.net/libxml2/">Solaris binaries</a></li><li><a href="http://www.explain.com.au/oss/libxml2xslt.html">MacOsX binaries</a></li><li><a href="http://bugzilla.gnome.org/buglist.cgi?product=libxslt">Bug Tracker</a></li><li><a href="http://www.zend.com/php5/articles/php5-xmlphp.php#Heading17">XSLT with PHP</a></li><li><a href="http://www.mod-xslt2.com/">Apache module</a></li><li><a href="http://sourceforge.net/projects/libxml2-pas/">Pascal bindings</a></li><li><a href="http://xsldbg.sourceforge.net/">Xsldbg Debugger</a></li></ul></td></tr></table><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>API Indexes</b></center></td></tr><tr><td bgcolor="#fffacd"><ul><li><a href="APIchunk0.html">Alphabetic</a></li><li><a href="APIconstructors.html">Constructors</a></li><li><a href="APIfunctions.html">Functions/Types</a></li><li><a href="APIfiles.html">Modules</a></li><li><a href="APIsymbols.html">Symbols</a></li></ul></td></tr></table></td></tr></table></td><td valign="top" bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="1" width="100%"><tr><td><table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000"><tr><td><table border="0" cellpadding="3" cellspacing="1" width="100%"><tr><td bgcolor="#fffacd"><p>You can help the project in various ways, the best thing to do first is to
-subscribe to the mailing-list as explained before, check the <a href="http://mail.gnome.org/archives/xslt/">archives </a>and the <a href="http://bugzilla.gnome.org/buglist.cgi?product=libxslt">Gnome bug
-database:</a>:</p><ol><li>provide patches when you find problems</li>
-  <li>provide the diffs when you port libxslt to a new platform. They may not
-    be integrated in all cases but help pinpointing portability problems
-  and</li>
-  <li>provide documentation fixes (either as patches to the code comments or
-    as HTML diffs).</li>
+          <a href="tutorial2/libxslt_pipes.html">Tutorial2</a></li><li><a href="xsltproc.html">Man page for xsltproc</a></li><li><a href="http://mail.gnome.org/archives/xslt/">Mail archive</a></li><li><a href="http://xmlsoft.org/">XML libxml2</a></li><li><a href="ftp://xmlsoft.org/">FTP</a></li><li><a href="http://www.zlatkovic.com/projects/libxml/">Windows binaries</a></li><li><a href="http://garypennington.net/libxml2/">Solaris binaries</a></li><li><a href="http://www.explain.com.au/oss/libxml2xslt.html">MacOsX binaries</a></li><li><a href="http://bugzilla.gnome.org/buglist.cgi?product=libxslt">Bug Tracker</a></li><li><a href="http://www.zend.com/php5/articles/php5-xmlphp.php#Heading17">XSLT with PHP</a></li><li><a href="http://www.mod-xslt2.com/">Apache module</a></li><li><a href="http://sourceforge.net/projects/libxml2-pas/">Pascal bindings</a></li><li><a href="http://xsldbg.sourceforge.net/">Xsldbg Debugger</a></li></ul></td></tr></table><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>API Indexes</b></center></td></tr><tr><td bgcolor="#fffacd"><ul><li><a href="APIchunk0.html">Alphabetic</a></li><li><a href="APIconstructors.html">Constructors</a></li><li><a href="APIfunctions.html">Functions/Types</a></li><li><a href="APIfiles.html">Modules</a></li><li><a href="APIsymbols.html">Symbols</a></li></ul></td></tr></table></td></tr></table></td><td valign="top" bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="1" width="100%"><tr><td><table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000"><tr><td><table border="0" cellpadding="3" cellspacing="1" width="100%"><tr><td bgcolor="#fffacd"><p>You can help the project in various ways, the best thing to do first is
+tosubscribe to the mailing-list as explained before, check the <a href="http://mail.gnome.org/archives/xslt/">archives </a>and the <a href="http://bugzilla.gnome.org/buglist.cgi?product=libxslt">Gnome
+bugdatabase:</a>:</p><ol><li>provide patches when you find problems</li>
+  <li>provide the diffs when you port libxslt to a new platform. They may
+    notbe integrated in all cases but help pinpointing portability
+  problemsand</li>
+  <li>provide documentation fixes (either as patches to the code comments
+    oras HTML diffs).</li>
   <li>provide new documentations pieces (translations, examples, etc ...)</li>
   <li>Check the TODO file and try to close one of the items</li>
-  <li>take one of the points raised in the archive or the bug database and
-    provide a fix. <a href="mailto:daniel at veillard.com">Get in touch with me
-    </a>before to avoid synchronization problems and check that the suggested
-    fix will fit in nicely :-)</li>
+  <li>take one of the points raised in the archive or the bug database
+    andprovide a fix. <a href="mailto:daniel at veillard.com">Get in touch with
+    me</a>before to avoid synchronization problems and check that the
+    suggestedfix will fit in nicely :-)</li>
 </ol><p><a href="bugs.html">Daniel Veillard</a></p></td></tr></table></td></tr></table></td></tr></table></td></tr></table></td></tr></table></body></html>

Modified: packages/libxslt/trunk/doc/index.html
===================================================================
--- packages/libxslt/trunk/doc/index.html	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/doc/index.html	2006-06-08 22:29:07 UTC (rev 565)
@@ -8,14 +8,15 @@
 H3 {font-family: Verdana,Arial,Helvetica}
 A:link, A:visited, A:active { text-decoration: underline }
     </style><title>libxslt</title></head><body bgcolor="#8b7765" text="#000000" link="#a06060" vlink="#000000"><table border="0" width="100%" cellpadding="5" cellspacing="0" align="center"><tr><td width="120"><a href="http://swpat.ffii.org/"><img src="epatents.png" alt="Action against software patents" /></a></td><td width="180"><a href="http://www.gnome.org/"><img src="gnome2.png" alt="Gnome2 Logo" /></a><a href="http://www.w3.org/Status"><img src="w3c.png" alt="W3C logo" /></a><a href="http://www.redhat.com"><img src="redhat.gif" alt="Red Hat Logo" /></a><div align="left"><a href="http://xmlsoft.org/XSLT/"><img src="Libxslt-Logo-180x168.gif" alt="Made with Libxslt Logo" /></a></div></td><td><table border="0" width="90%" cellpadding="2" cellspacing="0" align="center" bgcolor="#000000"><tr><td><table width="100%" border="0" cellspacing="1" cellpadding="3" bgcolor="#fffacd"><tr><td align="center"><h1>The XSLT C library for Gnome</h1><h2>libxslt</h2></td></tr></table></td></tr></table></td></tr></table><table border="0" cellpadding="4" cellspacing="0" width="100%" align="center"><tr><td bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="2" width="100%"><tr><td valign="top" width="200" bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000"><tr><td><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>Main Menu</b></center></td></tr><tr><td bgcolor="#fffacd"><form action="search.php" enctype="application/x-www-form-urlencoded" method="get"><input name="query" type="text" size="20" value="" /><input name="submit" type="submit" value="Search ..." /></form><ul><li><a href="index.html">Home</a></li><li><a href="http://xmlsoft.org/wiki">Wiki</a></li><li><a href="intro.html">Introduction</a></li><li><a href="docs.html">Documentation</a></li><li><a href="bugs.html">Reporting bugs and getting help</a></li><li><a href="help.html">How to help</a></li><li><a href="downloads.html">Downloads</a></li><li><a href="FAQ.html">FAQ</a></li><li><a href="news.html">News</a></li><li><a href="xsltproc2.html">The xsltproc tool</a></li><li><a href="docbook.html">DocBook</a></li><li><a href="API.html">The programming API</a></li><li><a href="python.html">Python and bindings</a></li><li><a href="internals.html">Library internals</a></li><li><a href="extensions.html">Writing extensions</a></li><li><a href="contribs.html">Contributions</a></li><li><a href="EXSLT/index.html" style="font-weight:bold">libexslt</a></li><li><a href="xslt.html">flat page</a>, <a href="site.xsl">stylesheet</a></li><li><a href="html/index.html" style="font-weight:bold">API Menu</a></li><li><a href="ChangeLog.html">ChangeLog</a></li></ul></td></tr></table><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>Related links</b></center></td></tr><tr><td bgcolor="#fffacd"><ul><li><a href="tutorial/libxslttutorial.html">Tutorial</a>,
-          <a href="tutorial2/libxslt_pipes.html">Tutorial2</a></li><li><a href="xsltproc.html">Man page for xsltproc</a></li><li><a href="http://mail.gnome.org/archives/xslt/">Mail archive</a></li><li><a href="http://xmlsoft.org/">XML libxml2</a></li><li><a href="ftp://xmlsoft.org/">FTP</a></li><li><a href="http://www.zlatkovic.com/projects/libxml/">Windows binaries</a></li><li><a href="http://garypennington.net/libxml2/">Solaris binaries</a></li><li><a href="http://www.explain.com.au/oss/libxml2xslt.html">MacOsX binaries</a></li><li><a href="http://bugzilla.gnome.org/buglist.cgi?product=libxslt">Bug Tracker</a></li><li><a href="http://www.zend.com/php5/articles/php5-xmlphp.php#Heading17">XSLT with PHP</a></li><li><a href="http://www.mod-xslt2.com/">Apache module</a></li><li><a href="http://sourceforge.net/projects/libxml2-pas/">Pascal bindings</a></li><li><a href="http://xsldbg.sourceforge.net/">Xsldbg Debugger</a></li></ul></td></tr></table><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>API Indexes</b></center></td></tr><tr><td bgcolor="#fffacd"><ul><li><a href="APIchunk0.html">Alphabetic</a></li><li><a href="APIconstructors.html">Constructors</a></li><li><a href="APIfunctions.html">Functions/Types</a></li><li><a href="APIfiles.html">Modules</a></li><li><a href="APIsymbols.html">Symbols</a></li></ul></td></tr></table></td></tr></table></td><td valign="top" bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="1" width="100%"><tr><td><table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000"><tr><td><table border="0" cellpadding="3" cellspacing="1" width="100%"><tr><td bgcolor="#fffacd"><p>Libxslt is the <a href="http://www.w3.org/TR/xslt">XSLT</a> C library
-developed for the Gnome project. XSLT itself is a an XML language to define
-transformation for XML. Libxslt is based on <a href="http://xmlsoft.org/">libxml2</a> the XML C library developed for the
-Gnome project. It also implements most of the <a href="http://www.exslt.org/">EXSLT</a> set of processor-portable extensions
-functions and some of Saxon's evaluate and expressions extensions.</p><p>People can either embed the library in their application or use xsltproc
-the command line processing tool. This library is free software and can be
-reused in commercial applications (see the <a href="intro.html">intro</a>)</p><p>External documents:</p><ul><li>John Fleck wrote <a href="tutorial/libxslttutorial.html">a tutorial for
-    libxslt</a></li>
+          <a href="tutorial2/libxslt_pipes.html">Tutorial2</a></li><li><a href="xsltproc.html">Man page for xsltproc</a></li><li><a href="http://mail.gnome.org/archives/xslt/">Mail archive</a></li><li><a href="http://xmlsoft.org/">XML libxml2</a></li><li><a href="ftp://xmlsoft.org/">FTP</a></li><li><a href="http://www.zlatkovic.com/projects/libxml/">Windows binaries</a></li><li><a href="http://garypennington.net/libxml2/">Solaris binaries</a></li><li><a href="http://www.explain.com.au/oss/libxml2xslt.html">MacOsX binaries</a></li><li><a href="http://bugzilla.gnome.org/buglist.cgi?product=libxslt">Bug Tracker</a></li><li><a href="http://www.zend.com/php5/articles/php5-xmlphp.php#Heading17">XSLT with PHP</a></li><li><a href="http://www.mod-xslt2.com/">Apache module</a></li><li><a href="http://sourceforge.net/projects/libxml2-pas/">Pascal bindings</a></li><li><a href="http://xsldbg.sourceforge.net/">Xsldbg Debugger</a></li></ul></td></tr></table><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>API Indexes</b></center></td></tr><tr><td bgcolor="#fffacd"><ul><li><a href="APIchunk0.html">Alphabetic</a></li><li><a href="APIconstructors.html">Constructors</a></li><li><a href="APIfunctions.html">Functions/Types</a></li><li><a href="APIfiles.html">Modules</a></li><li><a href="APIsymbols.html">Symbols</a></li></ul></td></tr></table></td></tr></table></td><td valign="top" bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="1" width="100%"><tr><td><table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000"><tr><td><table border="0" cellpadding="3" cellspacing="1" width="100%"><tr><td bgcolor="#fffacd"><p>Libxslt is the <a href="http://www.w3.org/TR/xslt">XSLT</a>C
+librarydeveloped for the Gnome project. XSLT itself is a an XML language to
+definetransformation for XML. Libxslt is based on <a href="http://xmlsoft.org/">libxml2</a>the XML C library developed for
+theGnome project. It also implements most of the <a href="http://www.exslt.org/">EXSLT</a>set of processor-portable
+extensionsfunctions and some of Saxon's evaluate and expressions
+extensions.</p><p>People can either embed the library in their application or use
+xsltprocthe command line processing tool. This library is free software and
+can bereused in commercial applications (see the <a href="intro.html">intro</a>)</p><p>External documents:</p><ul><li>John Fleck wrote <a href="tutorial/libxslttutorial.html">a tutorial
+    forlibxslt</a></li>
   <li><a href="xsltproc.html">xsltproc user manual</a></li>
   <li><a href="http://xmlsoft.org/">the libxml documentation</a></li>
 </ul><p></p><p>Logo designed by <a href="mailto:liyanage at access.ch">Marc Liyanage</a>.</p><p><a href="bugs.html">Daniel Veillard</a></p></td></tr></table></td></tr></table></td></tr></table></td></tr></table></td></tr></table></body></html>

Modified: packages/libxslt/trunk/doc/internals.html
===================================================================
--- packages/libxslt/trunk/doc/internals.html	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/doc/internals.html	2006-06-08 22:29:07 UTC (rev 565)
@@ -18,152 +18,152 @@
   <li><a href="internals.html#processing">The processing itself</a></li>
   <li><a href="internals.html#XPath">XPath expressions compilation</a></li>
   <li><a href="internals.html#XPath1">XPath interpretation</a></li>
-  <li><a href="internals.html#Descriptio">Description of XPath
-  Objects</a></li>
+  <li><a href="internals.html#Descriptio">Description of XPathObjects</a></li>
   <li><a href="internals.html#XPath3">XPath functions</a></li>
   <li><a href="internals.html#stack">The variables stack frame</a></li>
   <li><a href="internals.html#Extension">Extension support</a></li>
   <li><a href="internals.html#Futher">Further reading</a></li>
   <li><a href="internals.html#TODOs">TODOs</a></li>
-</ul><h3><a name="Introducti2" id="Introducti2">Introduction</a></h3><p>This document describes the processing of <a href="http://xmlsoft.org/XSLT/">libxslt</a>, the <a href="http://www.w3.org/TR/xslt">XSLT</a> C library developed for the <a href="http://www.gnome.org/">Gnome</a> project.</p><p>Note: this documentation is by definition incomplete and I am not good at
-spelling, grammar, so patches and suggestions are <a href="mailto:veillard at redhat.com">really welcome</a>.</p><h3><a name="Basics1" id="Basics1">Basics</a></h3><p>XSLT is a transformation language. It takes an input document and a
-stylesheet document and generates an output document:</p><p align="center"><img src="processing.gif" alt="the XSLT processing model" /></p><p>Libxslt is written in C. It relies on <a href="http://www.xmlsoft.org/">libxml</a>, the XML C library for Gnome, for
-the following operations:</p><ul><li>parsing files</li>
-  <li>building the in-memory DOM structure associated with the documents
-    handled</li>
+</ul><h3><a name="Introducti2" id="Introducti2">Introduction</a></h3><p>This document describes the processing of <a href="http://xmlsoft.org/XSLT/">libxslt</a>, the <a href="http://www.w3.org/TR/xslt">XSLT</a>C library developed for the <a href="http://www.gnome.org/">Gnome</a>project.</p><p>Note: this documentation is by definition incomplete and I am not good
+atspelling, grammar, so patches and suggestions are <a href="mailto:veillard at redhat.com">really welcome</a>.</p><h3><a name="Basics1" id="Basics1">Basics</a></h3><p>XSLT is a transformation language. It takes an input document and
+astylesheet document and generates an output document:</p><p align="center"><img src="processing.gif" alt="the XSLT processing model" /></p><p>Libxslt is written in C. It relies on <a href="http://www.xmlsoft.org/">libxml</a>, the XML C library for Gnome,
+forthe following operations:</p><ul><li>parsing files</li>
+  <li>building the in-memory DOM structure associated with the
+    documentshandled</li>
   <li>the XPath implementation</li>
-  <li>serializing back the result document to XML and HTML. (Text is handled
-    directly.)</li>
-</ul><h3><a name="Keep1" id="Keep1">Keep it simple stupid</a></h3><p>Libxslt is not very specialized. It is built under the assumption that all
-nodes from the source and output document can fit in the virtual memory of
-the system. There is a big trade-off there. It is fine for reasonably sized
-documents but may not be suitable for large sets of data. The gain is that it
-can be used in a relatively versatile way. The input or output may never be
-serialized, but the size of documents it can handle are limited by the size
-of the memory available.</p><p>More specialized memory handling approaches are possible, like building
-the input tree from a serialization progressively as it is consumed,
-factoring repetitive patterns, or even on-the-fly generation of the output as
-the input is parsed but it is possible only for a limited subset of the
-stylesheets. In general the implementation of libxslt follows the following
-pattern:</p><ul><li>KISS (keep it simple stupid)</li>
-  <li>when there is a clear bottleneck optimize on top of this simple
-    framework and refine only as much as is needed to reach the expected
-    result</li>
-</ul><p>The result is not that bad, clearly one can do a better job but more
-specialized too. Most optimization like building the tree on-demand would
-need serious changes to the libxml XPath framework. An easy step would be to
-serialize the output directly (or call a set of SAX-like output handler to
-keep this a flexible interface) and hence avoid the memory consumption of the
-result.</p><h3><a name="libxml" id="libxml">The libxml nodes</a></h3><p>DOM-like trees, as used and generated by libxml and libxslt, are
-relatively complex. Most node types follow the given structure except a few
-variations depending on the node type:</p><p align="center"><img src="node.gif" alt="description of a libxml node" /></p><p>Nodes carry a <strong>name</strong> and the node <strong>type</strong>
-indicates the kind of node it represents, the most common ones are:</p><ul><li>document nodes</li>
+  <li>serializing back the result document to XML and HTML. (Text is
+    handleddirectly.)</li>
+</ul><h3><a name="Keep1" id="Keep1">Keep it simple stupid</a></h3><p>Libxslt is not very specialized. It is built under the assumption that
+allnodes from the source and output document can fit in the virtual memory
+ofthe system. There is a big trade-off there. It is fine for reasonably
+sizeddocuments but may not be suitable for large sets of data. The gain is
+that itcan be used in a relatively versatile way. The input or output may
+never beserialized, but the size of documents it can handle are limited by
+the sizeof the memory available.</p><p>More specialized memory handling approaches are possible, like buildingthe
+input tree from a serialization progressively as it is consumed,factoring
+repetitive patterns, or even on-the-fly generation of the output asthe input
+is parsed but it is possible only for a limited subset of thestylesheets. In
+general the implementation of libxslt follows the followingpattern:</p><ul><li>KISS (keep it simple stupid)</li>
+  <li>when there is a clear bottleneck optimize on top of this
+    simpleframework and refine only as much as is needed to reach the
+    expectedresult</li>
+</ul><p>The result is not that bad, clearly one can do a better job but
+morespecialized too. Most optimization like building the tree on-demand
+wouldneed serious changes to the libxml XPath framework. An easy step would
+be toserialize the output directly (or call a set of SAX-like output handler
+tokeep this a flexible interface) and hence avoid the memory consumption of
+theresult.</p><h3><a name="libxml" id="libxml">The libxml nodes</a></h3><p>DOM-like trees, as used and generated by libxml and libxslt, arerelatively
+complex. Most node types follow the given structure except a fewvariations
+depending on the node type:</p><p align="center"><img src="node.gif" alt="description of a libxml node" /></p><p>Nodes carry a <strong>name</strong>and the node
+<strong>type</strong>indicates the kind of node it represents, the most
+common ones are:</p><ul><li>document nodes</li>
   <li>element nodes</li>
   <li>text nodes</li>
-</ul><p>For the XSLT processing, entity nodes should not be generated (i.e. they
-should be replaced by their content). Most nodes also contains the following
-"navigation" informations:</p><ul><li>the containing <strong>doc</strong>ument</li>
-  <li>the <strong>parent</strong> node</li>
-  <li>the first <strong>children</strong> node</li>
-  <li>the <strong>last</strong> children node</li>
+</ul><p>For the XSLT processing, entity nodes should not be generated (i.e.
+theyshould be replaced by their content). Most nodes also contains the
+following"navigation" informations:</p><ul><li>the containing <strong>doc</strong>ument</li>
+  <li>the <strong>parent</strong>node</li>
+  <li>the first <strong>children</strong>node</li>
+  <li>the <strong>last</strong>children node</li>
   <li>the <strong>prev</strong>ious sibling</li>
   <li>the following sibling (<strong>next</strong>)</li>
-</ul><p>Elements nodes carries the list of attributes in the properties, an
-attribute itself holds the navigation pointers and the children list (the
-attribute value is not represented as a simple string to allow usage of
-entities references).</p><p>The <strong>ns</strong> points to the namespace declaration for the
-namespace associated to the node, <strong>nsDef</strong> is the linked list
-of namespace declaration present on element nodes.</p><p>Most nodes also carry an <strong>_private</strong> pointer which can be
-used by the application to hold specific data on this node.</p><h3><a name="XSLT" id="XSLT">The XSLT processing steps</a></h3><p>There are a few steps which are clearly decoupled at the interface
-level:</p><ol><li>parse the stylesheet and generate a DOM tree</li>
-  <li>take the stylesheet tree and build a compiled version of it (the
-    compilation phase)</li>
+</ul><p>Elements nodes carries the list of attributes in the properties,
+anattribute itself holds the navigation pointers and the children list
+(theattribute value is not represented as a simple string to allow usage
+ofentities references).</p><p>The <strong>ns</strong>points to the namespace declaration for
+thenamespace associated to the node, <strong>nsDef</strong>is the linked
+listof namespace declaration present on element nodes.</p><p>Most nodes also carry an <strong>_private</strong>pointer which can beused
+by the application to hold specific data on this node.</p><h3><a name="XSLT" id="XSLT">The XSLT processing steps</a></h3><p>There are a few steps which are clearly decoupled at the
+interfacelevel:</p><ol><li>parse the stylesheet and generate a DOM tree</li>
+  <li>take the stylesheet tree and build a compiled version of it
+    (thecompilation phase)</li>
   <li>take the input and generate a DOM tree</li>
-  <li>process the stylesheet against the input tree and generate an output
-    tree</li>
+  <li>process the stylesheet against the input tree and generate an
+  outputtree</li>
   <li>serialize the output tree</li>
 </ol><p>A few things should be noted here:</p><ul><li>the steps 1/ 3/ and 5/ are optional</li>
-  <li>the stylesheet obtained at 2/ can be reused by multiple processing 4/
-    (and this should also work in threaded programs)</li>
-  <li>the tree provided in 2/ should never be freed using xmlFreeDoc, but by
-    freeing the stylesheet.</li>
-  <li>the input tree 4/ is not modified except the _private field which may
-    be used for labelling keys if used by the stylesheet</li>
-</ul><h3><a name="XSLT1" id="XSLT1">The XSLT stylesheet compilation</a></h3><p>This is the second step described. It takes a stylesheet tree, and
-"compiles" it. This associates to each node a structure stored in the
-_private field and containing information computed in the stylesheet:</p><p align="center"><img src="stylesheet.gif" alt="a compiled XSLT stylesheet" /></p><p>One xsltStylesheet structure is generated per document parsed for the
-stylesheet. XSLT documents allow includes and imports of other documents,
-imports are stored in the <strong>imports</strong> list (hence keeping the
-tree hierarchy of includes which is very important for a proper XSLT
-processing model) and includes are stored in the <strong>doclist</strong>
-list. An imported stylesheet has a parent link to allow browsing of the
-tree.</p><p>The DOM tree associated to the document is stored in <strong>doc</strong>.
-It is preprocessed to remove ignorable empty nodes and all the nodes in the
-XSLT namespace are subject to precomputing. This usually consist of
-extracting all the context information from the context tree (attributes,
-namespaces, XPath expressions), and storing them in an xsltStylePreComp
-structure associated to the <strong>_private</strong> field of the node.</p><p>A couple of notable exceptions to this are XSLT template nodes (more on
-this later) and attribute value templates. If they are actually templates,
-the value cannot be computed at compilation time. (Some preprocessing could
-be done like isolation and preparsing of the XPath subexpressions but it's
-not done, yet.)</p><p>The xsltStylePreComp structure also allows storing of the precompiled form
-of an XPath expression that can be associated to an XSLT element (more on
-this later).</p><h3><a name="XSLT2" id="XSLT2">The XSLT template compilation</a></h3><p>A proper handling of templates lookup is one of the keys of fast XSLT
-processing. (Given a node in the source document this is the process of
-finding which templates should be applied to this node.) Libxslt follows the
-hint suggested in the <a href="http://www.w3.org/TR/xslt#patterns">5.2
-Patterns</a> section of the XSLT Recommendation, i.e. it doesn't evaluate it
-as an XPath expression but tokenizes it and compiles it as a set of rules to
-be evaluated on a candidate node. There usually is an indication of the node
-name in the last step of this evaluation and this is used as a key check for
-the match. As a result libxslt builds a relatively more complex set of
-structures for the templates:</p><p align="center"><img src="templates.gif" alt="The templates related structure" /></p><p>Let's describe a bit more closely what is built. First the xsltStylesheet
-structure holds a pointer to the template hash table. All the XSLT patterns
-compiled in this stylesheet are indexed by the value of the the target
-element (or attribute, pi ...) name, so when a element or an attribute "foo"
-needs to be processed the lookup is done using the name as a key.</p><p>Each of the patterns is compiled into an xsltCompMatch structure. It holds
-the set of rules based on the tokenization of the pattern stored in reverse
-order (matching is easier this way). It also holds some information about the
-previous matches used to speed up the process when one iterates over a set of
-siblings. (This optimization may be defeated by trashing when running
-threaded computation, it's unclear that this is a big deal in practice.)
-Predicate expressions are not compiled at this stage, they may be at run-time
-if needed, but in this case they are compiled as full XPath expressions (the
-use of some fixed predicate can probably be optimized, they are not yet).</p><p>The xsltCompMatch are then stored in the hash table, the clash list is
-itself sorted by priority of the template to implement "naturally" the XSLT
-priority rules.</p><p>Associated to the compiled pattern is the xsltTemplate itself containing
-the information required for the processing of the pattern including, of
-course, a pointer to the list of elements used for building the pattern
-result.</p><p>Last but not least a number of patterns do not fit in the hash table
-because they are not associated to a name, this is the case for patterns
-applying to the root, any element, any attributes, text nodes, pi nodes, keys
-etc. Those are stored independently in the stylesheet structure as separate
-linked lists of xsltCompMatch.</p><h3><a name="processing" id="processing">The processing itself</a></h3><p>The processing is defined by the XSLT specification (the basis of the
-algorithm is explained in <a href="http://www.w3.org/TR/xslt#section-Introduction">the Introduction</a>
-section). Basically it works by taking the root of the input document and
-applying the following algorithm:</p><ol><li>Finding the template applying to it. This is a lookup in the template
-    hash table, walking the hash list until the node satisfies all the steps
-    of the pattern, then checking the appropriate(s) global templates to see
-    if there isn't a higher priority rule to apply</li>
-  <li>If there is no template, apply the default rule (recurse on the
-    children)</li>
+  <li>the stylesheet obtained at 2/ can be reused by multiple processing
+    4/(and this should also work in threaded programs)</li>
+  <li>the tree provided in 2/ should never be freed using xmlFreeDoc, but
+    byfreeing the stylesheet.</li>
+  <li>the input tree 4/ is not modified except the _private field which maybe
+    used for labelling keys if used by the stylesheet</li>
+</ul><h3><a name="XSLT1" id="XSLT1">The XSLT stylesheet compilation</a></h3><p>This is the second step described. It takes a stylesheet tree,
+and"compiles" it. This associates to each node a structure stored in
+the_private field and containing information computed in the stylesheet:</p><p align="center"><img src="stylesheet.gif" alt="a compiled XSLT stylesheet" /></p><p>One xsltStylesheet structure is generated per document parsed for
+thestylesheet. XSLT documents allow includes and imports of other
+documents,imports are stored in the <strong>imports</strong>list (hence
+keeping thetree hierarchy of includes which is very important for a proper
+XSLTprocessing model) and includes are stored in the
+<strong>doclist</strong>list. An imported stylesheet has a parent link to
+allow browsing of thetree.</p><p>The DOM tree associated to the document is stored in
+<strong>doc</strong>.It is preprocessed to remove ignorable empty nodes and
+all the nodes in theXSLT namespace are subject to precomputing. This usually
+consist ofextracting all the context information from the context tree
+(attributes,namespaces, XPath expressions), and storing them in an
+xsltStylePreCompstructure associated to the <strong>_private</strong>field of
+the node.</p><p>A couple of notable exceptions to this are XSLT template nodes (more
+onthis later) and attribute value templates. If they are actually
+templates,the value cannot be computed at compilation time. (Some
+preprocessing couldbe done like isolation and preparsing of the XPath
+subexpressions but it'snot done, yet.)</p><p>The xsltStylePreComp structure also allows storing of the precompiled
+formof an XPath expression that can be associated to an XSLT element (more
+onthis later).</p><h3><a name="XSLT2" id="XSLT2">The XSLT template compilation</a></h3><p>A proper handling of templates lookup is one of the keys of fast
+XSLTprocessing. (Given a node in the source document this is the process
+offinding which templates should be applied to this node.) Libxslt follows
+thehint suggested in the <a href="http://www.w3.org/TR/xslt#patterns">5.2Patterns</a>section of the XSLT
+Recommendation, i.e. it doesn't evaluate itas an XPath expression but
+tokenizes it and compiles it as a set of rules tobe evaluated on a candidate
+node. There usually is an indication of the nodename in the last step of this
+evaluation and this is used as a key check forthe match. As a result libxslt
+builds a relatively more complex set ofstructures for the templates:</p><p align="center"><img src="templates.gif" alt="The templates related structure" /></p><p>Let's describe a bit more closely what is built. First the
+xsltStylesheetstructure holds a pointer to the template hash table. All the
+XSLT patternscompiled in this stylesheet are indexed by the value of the the
+targetelement (or attribute, pi ...) name, so when a element or an attribute
+"foo"needs to be processed the lookup is done using the name as a key.</p><p>Each of the patterns is compiled into an xsltCompMatch structure. It
+holdsthe set of rules based on the tokenization of the pattern stored in
+reverseorder (matching is easier this way). It also holds some information
+about theprevious matches used to speed up the process when one iterates over
+a set ofsiblings. (This optimization may be defeated by trashing when
+runningthreaded computation, it's unclear that this is a big deal in
+practice.)Predicate expressions are not compiled at this stage, they may be
+at run-timeif needed, but in this case they are compiled as full XPath
+expressions (theuse of some fixed predicate can probably be optimized, they
+are not yet).</p><p>The xsltCompMatch are then stored in the hash table, the clash list
+isitself sorted by priority of the template to implement "naturally" the
+XSLTpriority rules.</p><p>Associated to the compiled pattern is the xsltTemplate itself
+containingthe information required for the processing of the pattern
+including, ofcourse, a pointer to the list of elements used for building the
+patternresult.</p><p>Last but not least a number of patterns do not fit in the hash
+tablebecause they are not associated to a name, this is the case for
+patternsapplying to the root, any element, any attributes, text nodes, pi
+nodes, keysetc. Those are stored independently in the stylesheet structure as
+separatelinked lists of xsltCompMatch.</p><h3><a name="processing" id="processing">The processing itself</a></h3><p>The processing is defined by the XSLT specification (the basis of
+thealgorithm is explained in <a href="http://www.w3.org/TR/xslt#section-Introduction">the
+Introduction</a>section). Basically it works by taking the root of the input
+document andapplying the following algorithm:</p><ol><li>Finding the template applying to it. This is a lookup in the
+    templatehash table, walking the hash list until the node satisfies all
+    the stepsof the pattern, then checking the appropriate(s) global
+    templates to seeif there isn't a higher priority rule to apply</li>
+  <li>If there is no template, apply the default rule (recurse on
+  thechildren)</li>
   <li>else walk the content list of the selected templates, for each of them:
-    <ul><li>if the node is in the XSLT namespace then the node has a _private
-        field pointing to the preprocessed values, jump to the specific
-      code</li>
-      <li>if the node is in an extension namespace, look up the associated
-        behavior</li>
+    <ul><li>if the node is in the XSLT namespace then the node has a
+        _privatefield pointing to the preprocessed values, jump to the
+        specificcode</li>
+      <li>if the node is in an extension namespace, look up the
+        associatedbehavior</li>
       <li>otherwise copy the node.</li>
-    </ul><p>The closure is usually done through the XSLT
-    <strong>apply-templates</strong> construct recursing by applying the
-    adequate template on the input node children or on the result of an
-    associated XPath selection lookup.</p>
+    </ul><p>The closure is usually done through the
+    XSLT<strong>apply-templates</strong>construct recursing by applying
+    theadequate template on the input node children or on the result of
+    anassociated XPath selection lookup.</p>
   </li>
-</ol><p>Note that large parts of the input tree may not be processed by a given
-stylesheet and that on the opposite some may be processed multiple times.
-(This often is the case when a Table of Contents is built).</p><p>The module <code>transform.c</code> is the one implementing most of this
-logic. <strong>xsltApplyStylesheet()</strong> is the entry point, it
-allocates an xsltTransformContext containing the following:</p><ul><li>a pointer to the stylesheet being processed</li>
+</ol><p>Note that large parts of the input tree may not be processed by a
+givenstylesheet and that on the opposite some may be processed multiple
+times.(This often is the case when a Table of Contents is built).</p><p>The module <code>transform.c</code>is the one implementing most of
+thislogic. <strong>xsltApplyStylesheet()</strong>is the entry point,
+itallocates an xsltTransformContext containing the following:</p><ul><li>a pointer to the stylesheet being processed</li>
   <li>a stack of templates</li>
   <li>a stack of variables and parameters</li>
   <li>an XPath context</li>
@@ -173,18 +173,18 @@
   <li>current selected node list</li>
   <li>the current insertion points in the output document</li>
   <li>a couple of hash tables for extension elements and functions</li>
-</ul><p>Then a new document gets allocated (HTML or XML depending on the type of
-output), the user parameters and global variables and parameters are
-evaluated. Then <strong>xsltProcessOneNode()</strong> which implements the
-1-2-3 algorithm is called on the root element of the input. Step 1/ is
-implemented by calling <strong>xsltGetTemplate()</strong>, step 2/ is
-implemented by <strong>xsltDefaultProcessOneNode()</strong> and step 3/ is
-implemented by <strong>xsltApplyOneTemplate()</strong>.</p><h3><a name="XPath" id="XPath">XPath expression compilation</a></h3><p>The XPath support is actually implemented in the libxml module (where it
-is reused by the XPointer implementation). XPath is a relatively classic
-expression language. The only uncommon feature is that it is working on XML
-trees and hence has specific syntax and types to handle them.</p><p>XPath expressions are compiled using <strong>xmlXPathCompile()</strong>.
-It will take an expression string in input and generate a structure
-containing the parsed expression tree, for example the expression:</p><pre>/doc/chapter[title='Introduction']</pre><p>will be compiled as</p><pre>Compiled Expression : 10 elements
+</ul><p>Then a new document gets allocated (HTML or XML depending on the type
+ofoutput), the user parameters and global variables and parameters
+areevaluated. Then <strong>xsltProcessOneNode()</strong>which implements
+the1-2-3 algorithm is called on the root element of the input. Step 1/
+isimplemented by calling <strong>xsltGetTemplate()</strong>, step 2/
+isimplemented by <strong>xsltDefaultProcessOneNode()</strong>and step 3/
+isimplemented by <strong>xsltApplyOneTemplate()</strong>.</p><h3><a name="XPath" id="XPath">XPath expression compilation</a></h3><p>The XPath support is actually implemented in the libxml module (where itis
+reused by the XPointer implementation). XPath is a relatively
+classicexpression language. The only uncommon feature is that it is working
+on XMLtrees and hence has specific syntax and types to handle them.</p><p>XPath expressions are compiled using <strong>xmlXPathCompile()</strong>.It
+will take an expression string in input and generate a structurecontaining
+the parsed expression tree, for example the expression:</p><pre>/doc/chapter[title='Introduction']</pre><p>will be compiled as</p><pre>Compiled Expression : 10 elements
   SORT
     COLLECT  'child' 'name' 'node' chapter
       COLLECT  'child' 'name' 'node' doc
@@ -196,97 +196,96 @@
               NODE
             ELEM Object is a string : Introduction
               COLLECT  'child' 'name' 'node' title
-                NODE</pre><p>This can be tested using the  <code>testXPath</code>  command (in the
-libxml codebase) using the <code>--tree</code> option.</p><p>Again, the KISS approach is used. No optimization is done. This could be
-an interesting thing to add. <a href="http://www-106.ibm.com/developerworks/library/x-xslt2/?dwzone=x?open&amp;l=132%2ct=gr%2c+p=saxon">Michael
-Kay describes</a> a lot of possible and interesting optimizations done in
-Saxon which would be possible at this level. I'm unsure they would provide
-much gain since the expressions tends to be relatively simple in general and
-stylesheets are still hand generated. Optimizations at the interpretation
-sounds likely to be more efficient.</p><h3><a name="XPath1" id="XPath1">XPath interpretation</a></h3><p>The interpreter is implemented by <strong>xmlXPathCompiledEval()</strong>
-which is the front-end to <strong>xmlXPathCompOpEval()</strong> the function
-implementing the evaluation of the expression tree. This evaluation follows
-the KISS approach again. It's recursive and calls
-<strong>xmlXPathNodeCollectAndTest()</strong> to collect nodes set when
-evaluating a <code>COLLECT</code> node.</p><p>An evaluation is done within the framework of an XPath context stored in
-an <strong>xmlXPathContext</strong> structure, in the framework of a
-transformation the context is maintained within the XSLT context. Its content
-follows the requirements from the XPath specification:</p><ul><li>the current document</li>
+                NODE</pre><p>This can be tested using the  <code>testXPath</code>command (in thelibxml
+codebase) using the <code>--tree</code>option.</p><p>Again, the KISS approach is used. No optimization is done. This could bean
+interesting thing to add. <a href="http://www-106.ibm.com/developerworks/library/x-xslt2/?dwzone=x?open&amp;l=132%2ct=gr%2c+p=saxon">MichaelKay
+describes</a>a lot of possible and interesting optimizations done inSaxon
+which would be possible at this level. I'm unsure they would providemuch gain
+since the expressions tends to be relatively simple in general andstylesheets
+are still hand generated. Optimizations at the interpretationsounds likely to
+be more efficient.</p><h3><a name="XPath1" id="XPath1">XPath interpretation</a></h3><p>The interpreter is implemented by
+<strong>xmlXPathCompiledEval()</strong>which is the front-end to
+<strong>xmlXPathCompOpEval()</strong>the functionimplementing the evaluation
+of the expression tree. This evaluation followsthe KISS approach again. It's
+recursive and calls<strong>xmlXPathNodeCollectAndTest()</strong>to collect
+nodes set whenevaluating a <code>COLLECT</code>node.</p><p>An evaluation is done within the framework of an XPath context stored inan
+<strong>xmlXPathContext</strong>structure, in the framework of
+atransformation the context is maintained within the XSLT context. Its
+contentfollows the requirements from the XPath specification:</p><ul><li>the current document</li>
   <li>the current node</li>
   <li>a hash table of defined variables (but not used by XSLT)</li>
   <li>a hash table of defined functions</li>
-  <li>the proximity position (the place of the node in the current node
-  list)</li>
+  <li>the proximity position (the place of the node in the current
+  nodelist)</li>
   <li>the context size (the size of the current node list)</li>
-  <li>the array of namespace declarations in scope (there also is a namespace
-    hash table but it is not used in the XSLT transformation).</li>
-</ul><p>For the purpose of XSLT an <strong>extra</strong> pointer has been added
-allowing to retrieve the XSLT transformation context. When an XPath
-evaluation is about to be performed, an XPath parser context is allocated
-containing and XPath object stack (this is actually an XPath evaluation
-context, this is a remain of the time where there was no separate parsing and
-evaluation phase in the XPath implementation). Here is an overview of the set
-of contexts associated to an XPath evaluation within an XSLT
-transformation:</p><p align="center"><img src="contexts.gif" alt="The set of contexts associated " /></p><p>Clearly this is a bit too complex and confusing and should be refactored
-at the next set of binary incompatible releases of libxml. For example the
-xmlXPathCtxt has a lot of unused parts and should probably be merged with
-xmlXPathParserCtxt.</p><h3><a name="Descriptio" id="Descriptio">Description of XPath Objects</a></h3><p>An XPath expression manipulates XPath objects. XPath defines the default
-types boolean, numbers, strings and node sets. XSLT adds the result tree
-fragment type which is basically an unmodifiable node set.</p><p>Implementation-wise, libxml follows again a KISS approach, the
-xmlXPathObject is a structure containing a type description and the various
-possibilities. (Using an enum could have gained some bytes.) In the case of
-node sets (or result tree fragments), it points to a separate xmlNodeSet
-object which contains the list of pointers to the document nodes:</p><p align="center"><img src="object.gif" alt="An Node set object pointing to " /></p><p>The <a href="http://xmlsoft.org/html/libxml-xpath.html">XPath API</a> (and
-its <a href="http://xmlsoft.org/html/libxml-xpathinternals.html">'internal'
-part</a>) includes a number of functions to create, copy, compare, convert or
-free XPath objects.</p><h3><a name="XPath3" id="XPath3">XPath functions</a></h3><p>All the XPath functions available to the interpreter are registered in the
-function hash table linked from the XPath context. They all share the same
-signature:</p><pre>void xmlXPathFunc (xmlXPathParserContextPtr ctxt, int nargs);</pre><p>The first argument is the XPath interpretation context, holding the
-interpretation stack. The second argument defines the number of objects
-passed on the stack for the function to consume (last argument is on top of
-the stack).</p><p>Basically an XPath function does the following:</p><ul><li>check <code>nargs</code> for proper handling of errors or functions
-    with variable numbers of parameters</li>
-  <li>pop the parameters from the stack using <code>obj =
-    valuePop(ctxt);</code></li>
+  <li>the array of namespace declarations in scope (there also is a
+    namespacehash table but it is not used in the XSLT transformation).</li>
+</ul><p>For the purpose of XSLT an <strong>extra</strong>pointer has been
+addedallowing to retrieve the XSLT transformation context. When an
+XPathevaluation is about to be performed, an XPath parser context is
+allocatedcontaining and XPath object stack (this is actually an XPath
+evaluationcontext, this is a remain of the time where there was no separate
+parsing andevaluation phase in the XPath implementation). Here is an overview
+of the setof contexts associated to an XPath evaluation within an
+XSLTtransformation:</p><p align="center"><img src="contexts.gif" alt="The set of contexts associated " /></p><p>Clearly this is a bit too complex and confusing and should be refactoredat
+the next set of binary incompatible releases of libxml. For example
+thexmlXPathCtxt has a lot of unused parts and should probably be merged
+withxmlXPathParserCtxt.</p><h3><a name="Descriptio" id="Descriptio">Description of XPath Objects</a></h3><p>An XPath expression manipulates XPath objects. XPath defines the
+defaulttypes boolean, numbers, strings and node sets. XSLT adds the result
+treefragment type which is basically an unmodifiable node set.</p><p>Implementation-wise, libxml follows again a KISS approach,
+thexmlXPathObject is a structure containing a type description and the
+variouspossibilities. (Using an enum could have gained some bytes.) In the
+case ofnode sets (or result tree fragments), it points to a separate
+xmlNodeSetobject which contains the list of pointers to the document
+nodes:</p><p align="center"><img src="object.gif" alt="An Node set object pointing to " /></p><p>The <a href="http://xmlsoft.org/html/libxml-xpath.html">XPath
+API</a>(andits <a href="http://xmlsoft.org/html/libxml-xpathinternals.html">'internal'part</a>)
+includes a number of functions to create, copy, compare, convert orfree XPath
+objects.</p><h3><a name="XPath3" id="XPath3">XPath functions</a></h3><p>All the XPath functions available to the interpreter are registered in
+thefunction hash table linked from the XPath context. They all share the
+samesignature:</p><pre>void xmlXPathFunc (xmlXPathParserContextPtr ctxt, int nargs);</pre><p>The first argument is the XPath interpretation context, holding
+theinterpretation stack. The second argument defines the number of
+objectspassed on the stack for the function to consume (last argument is on
+top ofthe stack).</p><p>Basically an XPath function does the following:</p><ul><li>check <code>nargs</code>for proper handling of errors or functionswith
+    variable numbers of parameters</li>
+  <li>pop the parameters from the stack using <code>obj
+    =valuePop(ctxt);</code></li>
   <li>do the function specific computation</li>
-  <li>push the result parameter on the stack using <code>valuePush(ctxt,
-    res);</code></li>
-  <li>free up the input parameters with
-  <code>xmlXPathFreeObject(obj);</code></li>
+  <li>push the result parameter on the stack using
+    <code>valuePush(ctxt,res);</code></li>
+  <li>free up the input parameters
+  with<code>xmlXPathFreeObject(obj);</code></li>
   <li>return</li>
-</ul><p>Sometime the work can be done directly by modifying in-situ the top object
-on the stack <code>ctxt-&gt;value</code>.</p><h3><a name="stack" id="stack">The XSLT variables stack frame</a></h3><p>Not to be confused with XPath object stack, this stack holds the XSLT
-variables and parameters as they are defined through the recursive calls of
-call-template, apply-templates and default templates. This is used to define
-the scope of variables being called.</p><p>This part seems to be the most urgent attention right now, first it is
-done in a very inefficient way since the location of the variables and
-parameters within the stylesheet tree is still done at run time (it really
-should be done statically at compile time), and I am still unsure that my
-understanding of the template variables and parameter scope is actually
-right.</p><p>This part of the documentation is still to be written once this part of
-the code will be stable. <span style="background-color: #FF0000">TODO</span></p><h3><a name="Extension" id="Extension">Extension support</a></h3><p>There is a separate document explaining <a href="extensions.html">how the
-extension support works</a>.</p><h3><a name="Futher" id="Futher">Further reading</a></h3><p>Michael Kay wrote <a href="http://www-106.ibm.com/developerworks/library/x-xslt2/?dwzone=x?open&amp;l=132%2ct=gr%2c+p=saxon">a
-really interesting article on Saxon internals</a> and the work he did on
-performance issues. I wishes I had read it before starting libxslt design (I
-would probably have avoided a few mistakes and progressed faster). A lot of
-the ideas in his papers should be implemented or at least tried in
-libxslt.</p><p>The <a href="http://xmlsoft.org/">libxml documentation</a>, especially <a href="http://xmlsoft.org/xmlio.html">the I/O interfaces</a> and the <a href="http://xmlsoft.org/xmlmem.html">memory management</a>.</p><h3><a name="TODOs" id="TODOs">TODOs</a></h3><p>redesign the XSLT stack frame handling. Far too much work is done at
-execution time. Similarly for the attribute value templates handling, at
-least the embedded subexpressions ought to be precompiled.</p><p>Allow output to be saved to a SAX like output (this notion of SAX like API
-for output should be added directly to libxml).</p><p>Implement and test some of the optimization explained by Michael Kay
-especially:</p><ul><li>static slot allocation on the stack frame</li>
+</ul><p>Sometime the work can be done directly by modifying in-situ the top
+objecton the stack <code>ctxt-&gt;value</code>.</p><h3><a name="stack" id="stack">The XSLT variables stack frame</a></h3><p>Not to be confused with XPath object stack, this stack holds the
+XSLTvariables and parameters as they are defined through the recursive calls
+ofcall-template, apply-templates and default templates. This is used to
+definethe scope of variables being called.</p><p>This part seems to be the most urgent attention right now, first it isdone
+in a very inefficient way since the location of the variables andparameters
+within the stylesheet tree is still done at run time (it reallyshould be done
+statically at compile time), and I am still unsure that myunderstanding of
+the template variables and parameter scope is actuallyright.</p><p>This part of the documentation is still to be written once this part ofthe
+code will be stable. <span style="background-color: #FF0000">TODO</span></p><h3><a name="Extension" id="Extension">Extension support</a></h3><p>There is a separate document explaining <a href="extensions.html">how
+theextension support works</a>.</p><h3><a name="Futher" id="Futher">Further reading</a></h3><p>Michael Kay wrote <a href="http://www-106.ibm.com/developerworks/library/x-xslt2/?dwzone=x?open&amp;l=132%2ct=gr%2c+p=saxon">areally
+interesting article on Saxon internals</a>and the work he did onperformance
+issues. I wishes I had read it before starting libxslt design (Iwould
+probably have avoided a few mistakes and progressed faster). A lot ofthe
+ideas in his papers should be implemented or at least tried inlibxslt.</p><p>The <a href="http://xmlsoft.org/">libxml documentation</a>, especially <a href="http://xmlsoft.org/xmlio.html">the I/O interfaces</a>and the <a href="http://xmlsoft.org/xmlmem.html">memory management</a>.</p><h3><a name="TODOs" id="TODOs">TODOs</a></h3><p>redesign the XSLT stack frame handling. Far too much work is done
+atexecution time. Similarly for the attribute value templates handling,
+atleast the embedded subexpressions ought to be precompiled.</p><p>Allow output to be saved to a SAX like output (this notion of SAX like
+APIfor output should be added directly to libxml).</p><p>Implement and test some of the optimization explained by Michael
+Kayespecially:</p><ul><li>static slot allocation on the stack frame</li>
   <li>specific boolean interpretation of an XPath expression</li>
   <li>some of the sorting optimization</li>
-  <li>Lazy evaluation of location path. (this may require more changes but
-    sounds really interesting. XT does this too.)</li>
-  <li>Optimization of an expression tree (This could be done as a completely
-    independent module.)</li>
-</ul><p></p><p>Error reporting, there is a lot of case where the XSLT specification
-specify that a given construct is an error are not checked adequately by
-libxslt. Basically one should do a complete pass on the XSLT spec again and
-add all tests to the stylesheet compilation. Using the DTD provided in the
-appendix and making direct checks using the libxml validation API sounds a
-good idea too (though one should take care of not raising errors for
-elements/attributes in different namespaces).</p><p>Double check all the places where the stylesheet compiled form might be
-modified at run time (extra removal of blanks nodes, hint on the
-xsltCompMatch).</p><p></p><p><a href="bugs.html">Daniel Veillard</a></p></td></tr></table></td></tr></table></td></tr></table></td></tr></table></td></tr></table></body></html>
+  <li>Lazy evaluation of location path. (this may require more changes
+    butsounds really interesting. XT does this too.)</li>
+  <li>Optimization of an expression tree (This could be done as a
+    completelyindependent module.)</li>
+</ul><p></p><p>Error reporting, there is a lot of case where the XSLT
+specificationspecify that a given construct is an error are not checked
+adequately bylibxslt. Basically one should do a complete pass on the XSLT
+spec again andadd all tests to the stylesheet compilation. Using the DTD
+provided in theappendix and making direct checks using the libxml validation
+API sounds agood idea too (though one should take care of not raising errors
+forelements/attributes in different namespaces).</p><p>Double check all the places where the stylesheet compiled form might
+bemodified at run time (extra removal of blanks nodes, hint on
+thexsltCompMatch).</p><p></p><p><a href="bugs.html">Daniel Veillard</a></p></td></tr></table></td></tr></table></td></tr></table></td></tr></table></td></tr></table></body></html>

Modified: packages/libxslt/trunk/doc/intro.html
===================================================================
--- packages/libxslt/trunk/doc/intro.html	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/doc/intro.html	2006-06-08 22:29:07 UTC (rev 565)
@@ -8,16 +8,14 @@
 H3 {font-family: Verdana,Arial,Helvetica}
 A:link, A:visited, A:active { text-decoration: underline }
     </style><title>Introduction</title></head><body bgcolor="#8b7765" text="#000000" link="#a06060" vlink="#000000"><table border="0" width="100%" cellpadding="5" cellspacing="0" align="center"><tr><td width="120"><a href="http://swpat.ffii.org/"><img src="epatents.png" alt="Action against software patents" /></a></td><td width="180"><a href="http://www.gnome.org/"><img src="gnome2.png" alt="Gnome2 Logo" /></a><a href="http://www.w3.org/Status"><img src="w3c.png" alt="W3C logo" /></a><a href="http://www.redhat.com"><img src="redhat.gif" alt="Red Hat Logo" /></a><div align="left"><a href="http://xmlsoft.org/XSLT/"><img src="Libxslt-Logo-180x168.gif" alt="Made with Libxslt Logo" /></a></div></td><td><table border="0" width="90%" cellpadding="2" cellspacing="0" align="center" bgcolor="#000000"><tr><td><table width="100%" border="0" cellspacing="1" cellpadding="3" bgcolor="#fffacd"><tr><td align="center"><h1>The XSLT C library for Gnome</h1><h2>Introduction</h2></td></tr></table></td></tr></table></td></tr></table><table border="0" cellpadding="4" cellspacing="0" width="100%" align="center"><tr><td bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="2" width="100%"><tr><td valign="top" width="200" bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000"><tr><td><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>Main Menu</b></center></td></tr><tr><td bgcolor="#fffacd"><form action="search.php" enctype="application/x-www-form-urlencoded" method="get"><input name="query" type="text" size="20" value="" /><input name="submit" type="submit" value="Search ..." /></form><ul><li><a href="index.html">Home</a></li><li><a href="http://xmlsoft.org/wiki">Wiki</a></li><li><a href="intro.html">Introduction</a></li><li><a href="docs.html">Documentation</a></li><li><a href="bugs.html">Reporting bugs and getting help</a></li><li><a href="help.html">How to help</a></li><li><a href="downloads.html">Downloads</a></li><li><a href="FAQ.html">FAQ</a></li><li><a href="news.html">News</a></li><li><a href="xsltproc2.html">The xsltproc tool</a></li><li><a href="docbook.html">DocBook</a></li><li><a href="API.html">The programming API</a></li><li><a href="python.html">Python and bindings</a></li><li><a href="internals.html">Library internals</a></li><li><a href="extensions.html">Writing extensions</a></li><li><a href="contribs.html">Contributions</a></li><li><a href="EXSLT/index.html" style="font-weight:bold">libexslt</a></li><li><a href="xslt.html">flat page</a>, <a href="site.xsl">stylesheet</a></li><li><a href="html/index.html" style="font-weight:bold">API Menu</a></li><li><a href="ChangeLog.html">ChangeLog</a></li></ul></td></tr></table><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>Related links</b></center></td></tr><tr><td bgcolor="#fffacd"><ul><li><a href="tutorial/libxslttutorial.html">Tutorial</a>,
-          <a href="tutorial2/libxslt_pipes.html">Tutorial2</a></li><li><a href="xsltproc.html">Man page for xsltproc</a></li><li><a href="http://mail.gnome.org/archives/xslt/">Mail archive</a></li><li><a href="http://xmlsoft.org/">XML libxml2</a></li><li><a href="ftp://xmlsoft.org/">FTP</a></li><li><a href="http://www.zlatkovic.com/projects/libxml/">Windows binaries</a></li><li><a href="http://garypennington.net/libxml2/">Solaris binaries</a></li><li><a href="http://www.explain.com.au/oss/libxml2xslt.html">MacOsX binaries</a></li><li><a href="http://bugzilla.gnome.org/buglist.cgi?product=libxslt">Bug Tracker</a></li><li><a href="http://www.zend.com/php5/articles/php5-xmlphp.php#Heading17">XSLT with PHP</a></li><li><a href="http://www.mod-xslt2.com/">Apache module</a></li><li><a href="http://sourceforge.net/projects/libxml2-pas/">Pascal bindings</a></li><li><a href="http://xsldbg.sourceforge.net/">Xsldbg Debugger</a></li></ul></td></tr></table><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>API Indexes</b></center></td></tr><tr><td bgcolor="#fffacd"><ul><li><a href="APIchunk0.html">Alphabetic</a></li><li><a href="APIconstructors.html">Constructors</a></li><li><a href="APIfunctions.html">Functions/Types</a></li><li><a href="APIfiles.html">Modules</a></li><li><a href="APIsymbols.html">Symbols</a></li></ul></td></tr></table></td></tr></table></td><td valign="top" bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="1" width="100%"><tr><td><table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000"><tr><td><table border="0" cellpadding="3" cellspacing="1" width="100%"><tr><td bgcolor="#fffacd"><p>This document describes <a href="http://xmlsoft.org/XSLT/">libxslt</a>,
-the <a href="http://www.w3.org/TR/xslt">XSLT</a> C library developed for the
-<a href="http://www.gnome.org/">Gnome</a> project.</p><p>Here are some key points about libxslt:</p><ul><li>Libxslt is a C implementation</li>
-  <li>Libxslt is based on libxml for XML parsing, tree manipulation and XPath
-    support</li>
-  <li>It is written in plain C, making as few assumptions as possible, and
-    sticking closely to ANSI C/POSIX for easy embedding. Should works on
-    Linux/Unix/Windows.</li>
-  <li>This library is released under the <a href="http://www.opensource.org/licenses/mit-license.html">MIT
-  Licence</a></li>
-  <li>Though not designed primarily with performances in mind, libxslt seems
-    to be a relatively fast processor.</li>
+          <a href="tutorial2/libxslt_pipes.html">Tutorial2</a></li><li><a href="xsltproc.html">Man page for xsltproc</a></li><li><a href="http://mail.gnome.org/archives/xslt/">Mail archive</a></li><li><a href="http://xmlsoft.org/">XML libxml2</a></li><li><a href="ftp://xmlsoft.org/">FTP</a></li><li><a href="http://www.zlatkovic.com/projects/libxml/">Windows binaries</a></li><li><a href="http://garypennington.net/libxml2/">Solaris binaries</a></li><li><a href="http://www.explain.com.au/oss/libxml2xslt.html">MacOsX binaries</a></li><li><a href="http://bugzilla.gnome.org/buglist.cgi?product=libxslt">Bug Tracker</a></li><li><a href="http://www.zend.com/php5/articles/php5-xmlphp.php#Heading17">XSLT with PHP</a></li><li><a href="http://www.mod-xslt2.com/">Apache module</a></li><li><a href="http://sourceforge.net/projects/libxml2-pas/">Pascal bindings</a></li><li><a href="http://xsldbg.sourceforge.net/">Xsldbg Debugger</a></li></ul></td></tr></table><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>API Indexes</b></center></td></tr><tr><td bgcolor="#fffacd"><ul><li><a href="APIchunk0.html">Alphabetic</a></li><li><a href="APIconstructors.html">Constructors</a></li><li><a href="APIfunctions.html">Functions/Types</a></li><li><a href="APIfiles.html">Modules</a></li><li><a href="APIsymbols.html">Symbols</a></li></ul></td></tr></table></td></tr></table></td><td valign="top" bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="1" width="100%"><tr><td><table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000"><tr><td><table border="0" cellpadding="3" cellspacing="1" width="100%"><tr><td bgcolor="#fffacd"><p>This document describes <a href="http://xmlsoft.org/XSLT/">libxslt</a>,the
+<a href="http://www.w3.org/TR/xslt">XSLT</a>C library developed for the<a href="http://www.gnome.org/">Gnome</a>project.</p><p>Here are some key points about libxslt:</p><ul><li>Libxslt is a C implementation</li>
+  <li>Libxslt is based on libxml for XML parsing, tree manipulation and
+    XPathsupport</li>
+  <li>It is written in plain C, making as few assumptions as possible,
+    andsticking closely to ANSI C/POSIX for easy embedding. Should works
+    onLinux/Unix/Windows.</li>
+  <li>This library is released under the <a href="http://www.opensource.org/licenses/mit-license.html">MITLicence</a></li>
+  <li>Though not designed primarily with performances in mind, libxslt
+    seemsto be a relatively fast processor.</li>
 </ul><p><a href="bugs.html">Daniel Veillard</a></p></td></tr></table></td></tr></table></td></tr></table></td></tr></table></td></tr></table></body></html>

Modified: packages/libxslt/trunk/doc/libxslt.xsa
===================================================================
--- packages/libxslt/trunk/doc/libxslt.xsa	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/doc/libxslt.xsa	2006-06-08 22:29:07 UTC (rev 565)
@@ -8,19 +8,22 @@
   </vendor>
   <product id="libxslt">
     <name>libxslt</name>
-    <version>1.1.15</version>
-    <last-release> Sep 04 2005</last-release>
+    <version>1.1.16</version>
+    <last-release> May 01 2006</last-release>
     <info-url>http://xmlsoft.org/XSLT/</info-url>
-    <changes>   - build fixes: Windows build cleanups and updates (Igor Zlatkovic),
-    remove jhbuild warnings
-   - bug fixes: negative number formatting (William Brack), number
-    formatting per mille definition (William Brack), XInclude default values
-    (William), text copy bugs (William), bug related to xmlXPathContext size,
-    reuse libxml2 memory management for text nodes, dictionnary text bug,
-    forbid variables in match (needs libxml2-2.6.21)
-   - improvements: EXSLT dyn:map (Mark Vakoc),
-   - documentation: EXSLT date and time functions namespace in man (Jonathan
-    Wakely)
+    <changes>   - portability fixes: EXSLT date/time on Solaris and IRIX (Albert
+    Chin),HP-UX  build (Albert Chin),
+   - build fixes: Python detection(Joseph Sacco), plugin configurei(Joel
+    Reed)
+   - bug fixes: pattern compilation fix(William Brack), EXSLT date/timefix
+    (Thomas Broyer), EXSLT function bug, potential loop on variableeval,
+    startup race (Christopher Palmer), debug statement left in python(Nic
+    Ferrier), various cleanup based on Coverity reports), error onOut of
+    memory condition (Charles Hardin), various namespace prefixesfixes
+    (Kasimier Buchcik),
+   - improvement: speed up sortingi, start of internals refactoring
+    (KasimierBuchcik)
+   - documentation: man page fixes and updates (Daniel Leidert)
 
 </changes>
   </product>

Modified: packages/libxslt/trunk/doc/news.html
===================================================================
--- packages/libxslt/trunk/doc/news.html	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/doc/news.html	2006-06-08 22:29:07 UTC (rev 565)
@@ -8,155 +8,162 @@
 H3 {font-family: Verdana,Arial,Helvetica}
 A:link, A:visited, A:active { text-decoration: underline }
     </style><title>News</title></head><body bgcolor="#8b7765" text="#000000" link="#a06060" vlink="#000000"><table border="0" width="100%" cellpadding="5" cellspacing="0" align="center"><tr><td width="120"><a href="http://swpat.ffii.org/"><img src="epatents.png" alt="Action against software patents" /></a></td><td width="180"><a href="http://www.gnome.org/"><img src="gnome2.png" alt="Gnome2 Logo" /></a><a href="http://www.w3.org/Status"><img src="w3c.png" alt="W3C logo" /></a><a href="http://www.redhat.com"><img src="redhat.gif" alt="Red Hat Logo" /></a><div align="left"><a href="http://xmlsoft.org/XSLT/"><img src="Libxslt-Logo-180x168.gif" alt="Made with Libxslt Logo" /></a></div></td><td><table border="0" width="90%" cellpadding="2" cellspacing="0" align="center" bgcolor="#000000"><tr><td><table width="100%" border="0" cellspacing="1" cellpadding="3" bgcolor="#fffacd"><tr><td align="center"><h1>The XSLT C library for Gnome</h1><h2>News</h2></td></tr></table></td></tr></table></td></tr></table><table border="0" cellpadding="4" cellspacing="0" width="100%" align="center"><tr><td bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="2" width="100%"><tr><td valign="top" width="200" bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000"><tr><td><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>Main Menu</b></center></td></tr><tr><td bgcolor="#fffacd"><form action="search.php" enctype="application/x-www-form-urlencoded" method="get"><input name="query" type="text" size="20" value="" /><input name="submit" type="submit" value="Search ..." /></form><ul><li><a href="index.html">Home</a></li><li><a href="http://xmlsoft.org/wiki">Wiki</a></li><li><a href="intro.html">Introduction</a></li><li><a href="docs.html">Documentation</a></li><li><a href="bugs.html">Reporting bugs and getting help</a></li><li><a href="help.html">How to help</a></li><li><a href="downloads.html">Downloads</a></li><li><a href="FAQ.html">FAQ</a></li><li><a href="news.html">News</a></li><li><a href="xsltproc2.html">The xsltproc tool</a></li><li><a href="docbook.html">DocBook</a></li><li><a href="API.html">The programming API</a></li><li><a href="python.html">Python and bindings</a></li><li><a href="internals.html">Library internals</a></li><li><a href="extensions.html">Writing extensions</a></li><li><a href="contribs.html">Contributions</a></li><li><a href="EXSLT/index.html" style="font-weight:bold">libexslt</a></li><li><a href="xslt.html">flat page</a>, <a href="site.xsl">stylesheet</a></li><li><a href="html/index.html" style="font-weight:bold">API Menu</a></li><li><a href="ChangeLog.html">ChangeLog</a></li></ul></td></tr></table><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>Related links</b></center></td></tr><tr><td bgcolor="#fffacd"><ul><li><a href="tutorial/libxslttutorial.html">Tutorial</a>,
-          <a href="tutorial2/libxslt_pipes.html">Tutorial2</a></li><li><a href="xsltproc.html">Man page for xsltproc</a></li><li><a href="http://mail.gnome.org/archives/xslt/">Mail archive</a></li><li><a href="http://xmlsoft.org/">XML libxml2</a></li><li><a href="ftp://xmlsoft.org/">FTP</a></li><li><a href="http://www.zlatkovic.com/projects/libxml/">Windows binaries</a></li><li><a href="http://garypennington.net/libxml2/">Solaris binaries</a></li><li><a href="http://www.explain.com.au/oss/libxml2xslt.html">MacOsX binaries</a></li><li><a href="http://bugzilla.gnome.org/buglist.cgi?product=libxslt">Bug Tracker</a></li><li><a href="http://www.zend.com/php5/articles/php5-xmlphp.php#Heading17">XSLT with PHP</a></li><li><a href="http://www.mod-xslt2.com/">Apache module</a></li><li><a href="http://sourceforge.net/projects/libxml2-pas/">Pascal bindings</a></li><li><a href="http://xsldbg.sourceforge.net/">Xsldbg Debugger</a></li></ul></td></tr></table><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>API Indexes</b></center></td></tr><tr><td bgcolor="#fffacd"><ul><li><a href="APIchunk0.html">Alphabetic</a></li><li><a href="APIconstructors.html">Constructors</a></li><li><a href="APIfunctions.html">Functions/Types</a></li><li><a href="APIfiles.html">Modules</a></li><li><a href="APIsymbols.html">Symbols</a></li></ul></td></tr></table></td></tr></table></td><td valign="top" bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="1" width="100%"><tr><td><table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000"><tr><td><table border="0" cellpadding="3" cellspacing="1" width="100%"><tr><td bgcolor="#fffacd"><p>The <a href="ChangeLog.html">change log</a> describes the recents commits
-to the <a href="http://cvs.gnome.org/viewcvs/libxslt/">CVS</a> code base.</p><p>Those are the public releases made:</p><h3>1.1.16: May 01 2006</h3><ul><li>portability fixes: EXSLT date/time on Solaris and IRIX (Albert Chin),
-      HP-UX  build (Albert Chin), 
-  </li><li>build fixes: Python detection(Joseph Sacco), plugin configurei
-      (Joel Reed)</li>
-  <li>bug fixes: pattern compilation fix(William Brack), EXSLT date/time
-      fix (Thomas Broyer), EXSLT function bug, potential loop on variable
-      eval, startup race (Christopher Palmer), debug statement left in python
-      (Nic Ferrier), various cleanup based on Coverity reports), error on
-      Out of memory condition (Charles Hardin), various namespace prefixes
-      fixes (Kasimier Buchcik), </li>
-  <li>improvement: speed up sortingi, start of internals refactoring (Kasimier
-      Buchcik)</li>
-  <li>documentation: man page fixes and updates (Daniel Leidert)
-</li></ul><h3>1.1.15: Sep 04 2005</h3><ul><li>build fixes: Windows build cleanups and updates (Igor Zlatkovic),
-    remove jhbuild warnings</li>
-  <li>bug fixes: negative number formatting (William Brack), number
-    formatting per mille definition (William Brack), XInclude default values
-    (William), text copy bugs (William), bug related to xmlXPathContext size,
-    reuse libxml2 memory management for text nodes, dictionnary text bug,
-    forbid variables in match (needs libxml2-2.6.21)</li>
+          <a href="tutorial2/libxslt_pipes.html">Tutorial2</a></li><li><a href="xsltproc.html">Man page for xsltproc</a></li><li><a href="http://mail.gnome.org/archives/xslt/">Mail archive</a></li><li><a href="http://xmlsoft.org/">XML libxml2</a></li><li><a href="ftp://xmlsoft.org/">FTP</a></li><li><a href="http://www.zlatkovic.com/projects/libxml/">Windows binaries</a></li><li><a href="http://garypennington.net/libxml2/">Solaris binaries</a></li><li><a href="http://www.explain.com.au/oss/libxml2xslt.html">MacOsX binaries</a></li><li><a href="http://bugzilla.gnome.org/buglist.cgi?product=libxslt">Bug Tracker</a></li><li><a href="http://www.zend.com/php5/articles/php5-xmlphp.php#Heading17">XSLT with PHP</a></li><li><a href="http://www.mod-xslt2.com/">Apache module</a></li><li><a href="http://sourceforge.net/projects/libxml2-pas/">Pascal bindings</a></li><li><a href="http://xsldbg.sourceforge.net/">Xsldbg Debugger</a></li></ul></td></tr></table><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>API Indexes</b></center></td></tr><tr><td bgcolor="#fffacd"><ul><li><a href="APIchunk0.html">Alphabetic</a></li><li><a href="APIconstructors.html">Constructors</a></li><li><a href="APIfunctions.html">Functions/Types</a></li><li><a href="APIfiles.html">Modules</a></li><li><a href="APIsymbols.html">Symbols</a></li></ul></td></tr></table></td></tr></table></td><td valign="top" bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="1" width="100%"><tr><td><table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000"><tr><td><table border="0" cellpadding="3" cellspacing="1" width="100%"><tr><td bgcolor="#fffacd"><p>The <a href="ChangeLog.html">change log</a>describes the recents commitsto
+the <a href="http://cvs.gnome.org/viewcvs/libxslt/">CVS</a>code base.</p><p>Those are the public releases made:</p><h3>1.1.17: Jun 6 2006</h3><ul><li>portability fixes: python detection</li>
+  <li>bug fixes: some regression tests, attribute/namespaces output (Kasimier
+    Buchcik), problem in mixed xsl:value-of and xsl:text uses (Kasimier)</li>
+  <li>improvements: internal refactoring (Kasimier Buchcik), use of the XPath
+    object cache in libxml2-2.6.25 (Kasimier)</li>
+</ul><h3>1.1.16: May 01 2006</h3><ul><li>portability fixes: EXSLT date/time on Solaris and IRIX (Albert
+    Chin),HP-UX  build (Albert Chin),</li>
+  <li>build fixes: Python detection(Joseph Sacco), plugin configurei(Joel
+    Reed)</li>
+  <li>bug fixes: pattern compilation fix(William Brack), EXSLT date/timefix
+    (Thomas Broyer), EXSLT function bug, potential loop on variableeval,
+    startup race (Christopher Palmer), debug statement left in python(Nic
+    Ferrier), various cleanup based on Coverity reports), error onOut of
+    memory condition (Charles Hardin), various namespace prefixesfixes
+    (Kasimier Buchcik),</li>
+  <li>improvement: speed up sortingi, start of internals refactoring
+    (KasimierBuchcik)</li>
+  <li>documentation: man page fixes and updates (Daniel Leidert)</li>
+</ul><h3>1.1.15: Sep 04 2005</h3><ul><li>build fixes: Windows build cleanups and updates (Igor Zlatkovic),remove
+    jhbuild warnings</li>
+  <li>bug fixes: negative number formatting (William Brack), numberformatting
+    per mille definition (William Brack), XInclude default values(William),
+    text copy bugs (William), bug related to xmlXPathContext size,reuse
+    libxml2 memory management for text nodes, dictionnary text bug,forbid
+    variables in match (needs libxml2-2.6.21)</li>
   <li>improvements: EXSLT dyn:map (Mark Vakoc),</li>
-  <li>documentation: EXSLT date and time functions namespace in man (Jonathan
-    Wakely)</li>
-</ul><h3>1.1.14: Apr 02 2005</h3><ul><li>bug fixes: text node on stylesheet document without a dictionary
-    (William Brack), more checking of XSLT syntax, calling xsltInit()
-    multiple times, mode values interning raised by Mark Vakoc, bug in
-    pattern matching with ancestors, bug in patterna matching with cascading
-    select, xinclude and document() problem, build outside of source tree
-    (Mike Castle)</li>
-  <li>improvement: added a --nodict mode to xsltproc to check problems for
-    docuemtns without dictionnaries</li>
-</ul><h3>1.1.13: Mar 13 2005</h3><ul><li>build fixes: 64bits cleanup (William Brack), python 2.4 test (William),
-    LIBXSLT_VERSION_EXTRA on Windows (William), Windows makefiles fixes (Joel
-    Reed), libgcrypt-devel requires for RPM spec.</li>
-  <li>bug fixes: exslt day-of-week-in-month (Sal Paradise), xsl:call-template
-    should not change the current template rule (William Brack), evaluation
-    of global variables (William Brack), RVT's in XPath predicates (William),
-    namespace URI on template names (Mark Vakoc), stat() for Windows patch
-    (Aleksey Gurtovoy), pattern expression fixes (William Brack), out of
-    memory detection misses (William), parserOptions propagation (William),
-    exclude-result-prefixes fix (William), // patten fix (William).</li>
-  <li>extensions: module support (Joel Reed), dictionnary based speedups
-    trying to get rid of xmlStrEqual as much as possible.</li>
+  <li>documentation: EXSLT date and time functions namespace in man
+    (JonathanWakely)</li>
+</ul><h3>1.1.14: Apr 02 2005</h3><ul><li>bug fixes: text node on stylesheet document without a
+    dictionary(William Brack), more checking of XSLT syntax, calling
+    xsltInit()multiple times, mode values interning raised by Mark Vakoc, bug
+    inpattern matching with ancestors, bug in patterna matching with
+    cascadingselect, xinclude and document() problem, build outside of source
+    tree(Mike Castle)</li>
+  <li>improvement: added a --nodict mode to xsltproc to check problems
+    fordocuemtns without dictionnaries</li>
+</ul><h3>1.1.13: Mar 13 2005</h3><ul><li>build fixes: 64bits cleanup (William Brack), python 2.4 test
+    (William),LIBXSLT_VERSION_EXTRA on Windows (William), Windows makefiles
+    fixes (JoelReed), libgcrypt-devel requires for RPM spec.</li>
+  <li>bug fixes: exslt day-of-week-in-month (Sal Paradise),
+    xsl:call-templateshould not change the current template rule (William
+    Brack), evaluationof global variables (William Brack), RVT's in XPath
+    predicates (William),namespace URI on template names (Mark Vakoc), stat()
+    for Windows patch(Aleksey Gurtovoy), pattern expression fixes (William
+    Brack), out ofmemory detection misses (William), parserOptions
+    propagation (William),exclude-result-prefixes fix (William), // patten
+    fix (William).</li>
+  <li>extensions: module support (Joel Reed), dictionnary based
+    speedupstrying to get rid of xmlStrEqual as much as possible.</li>
   <li>documentation: added Wiki (Joel Reed)</li>
 </ul><h3>1.1.12: Oct 29 2004</h3><ul><li>build fixes: warnings removal (William).</li>
-  <li>bug fixes: attribute document pointer fix (Mark Vakoc), exslt date
-    negative periods (William Brack), generated tree structure fixes,
-    namespace lookup fix, use reentrant gmtime_r (William Brack),
-    exslt:funtion namespace fix (William), potential NULL pointer reference
-    (Dennis Dams, William), force string interning on generated
-  documents.</li>
-  <li>documentation: update of the second tutorial (Panagiotis Louridas), add
-    exslt doc in rpm packages, fix the xsltproc man page.</li>
-</ul><h3>1.1.11: Sep 29 2004</h3><ul><li>bug fixes: xsl:include problems (William Brack), UTF8 number pattern
-    (William), date-time validation (William), namespace fix (William),
-    various Exslt date fixes (William), error callback fixes, leak with
-    namespaced global variable, attempt to fix a weird problem #153137</li>
+  <li>bug fixes: attribute document pointer fix (Mark Vakoc), exslt
+    datenegative periods (William Brack), generated tree structure
+    fixes,namespace lookup fix, use reentrant gmtime_r (William
+    Brack),exslt:funtion namespace fix (William), potential NULL pointer
+    reference(Dennis Dams, William), force string interning on
+    generateddocuments.</li>
+  <li>documentation: update of the second tutorial (Panagiotis Louridas),
+    addexslt doc in rpm packages, fix the xsltproc man page.</li>
+</ul><h3>1.1.11: Sep 29 2004</h3><ul><li>bug fixes: xsl:include problems (William Brack), UTF8 number
+    pattern(William), date-time validation (William), namespace fix
+    (William),various Exslt date fixes (William), error callback fixes, leak
+    withnamespaced global variable, attempt to fix a weird problem
+  #153137</li>
   <li>improvements: exslt:date-sum tests (Derek Poon)</li>
   <li>documentation: second tutorial by Panagiotis Lourida</li>
-</ul><h3>1.1.10: Aug 31 2004</h3><ul><li>build fix: NUL in c file blocking compilation on Solaris, Windows build
-    (Igor Zlatkovic)</li>
+</ul><h3>1.1.10: Aug 31 2004</h3><ul><li>build fix: NUL in c file blocking compilation on Solaris, Windows
+    build(Igor Zlatkovic)</li>
   <li>fix: key initialization problem (William Brack)</li>
   <li>documentation: fixed missing man page description for --path</li>
-</ul><h3>1.1.9: Aug 22 2004</h3><ul><li>build fixes: missing tests (William Brack), Python dependancies, Python
-    on 64bits boxes, --with-crypto flag (Rob Richards),</li>
-  <li>fixes: RVT key handling (William), Python binding (William and Sitsofe
-    Wheeler), key and XPath troubles (William), template priority on imports
-    (William), str:tokenize with empty strings (William), #default namespace
-    alias behaviour (William), doc ordering missing for main document
-    (William), 64bit bug (Andreas Schwab)</li>
-  <li>improvements: EXSLT date:sum added (Joel Reed), hook for document
-    loading for David Hyatt, xsltproc --nodtdattr to avoid defaulting DTD
-    attributes, extend xsltproc --version with CVS stamp (William).</li>
+</ul><h3>1.1.9: Aug 22 2004</h3><ul><li>build fixes: missing tests (William Brack), Python dependancies,
+    Pythonon 64bits boxes, --with-crypto flag (Rob Richards),</li>
+  <li>fixes: RVT key handling (William), Python binding (William and
+    SitsofeWheeler), key and XPath troubles (William), template priority on
+    imports(William), str:tokenize with empty strings (William), #default
+    namespacealias behaviour (William), doc ordering missing for main
+    document(William), 64bit bug (Andreas Schwab)</li>
+  <li>improvements: EXSLT date:sum added (Joel Reed), hook for
+    documentloading for David Hyatt, xsltproc --nodtdattr to avoid defaulting
+    DTDattributes, extend xsltproc --version with CVS stamp (William).</li>
   <li>Documentation: web page problem reported by Oliver Stoeneberg</li>
-</ul><h3>1.1.8: July 5 2004</h3><ul><li>build fixes: Windows runtime options (Oliver Stoeneberg), Windows
-    binary package layout (Igor Zlatkovic), libgcrypt version test and link
-    (William)</li>
+</ul><h3>1.1.8: July 5 2004</h3><ul><li>build fixes: Windows runtime options (Oliver Stoeneberg), Windowsbinary
+    package layout (Igor Zlatkovic), libgcrypt version test and
+  link(William)</li>
   <li>documentation: fix libxslt namespace name in doc (William)</li>
-  <li>bug fixes: undefined namespace message (William Brack), search engine
-    (William), multiple namespace fixups (William), namespace fix for key
-    evaluation (William), Python memory debug bindings,</li>
+  <li>bug fixes: undefined namespace message (William Brack), search
+    engine(William), multiple namespace fixups (William), namespace fix for
+    keyevaluation (William), Python memory debug bindings,</li>
   <li>improvements: crypto extensions for exslt (Joel Reed, William)</li>
 </ul><h3>1.1.7: May 17 2004</h3><ul><li>build fix: warning about localtime_r on Solaris</li>
-  <li>bug fix: UTF8 string tokenize (William Brack), subtle memory
-    corruption, linefeed after comment at document level (William),
-    disable-output-escaping problem (William), pattern compilation in deep
-    imported stylesheets (William), namespace extension prefix bug,
-    libxslt.m4 bug (Edward Rudd), namespace lookup for attribute, namespaced
-    DOCTYPE name</li>
+  <li>bug fix: UTF8 string tokenize (William Brack), subtle memorycorruption,
+    linefeed after comment at document level
+    (William),disable-output-escaping problem (William), pattern compilation
+    in deepimported stylesheets (William), namespace extension prefix
+    bug,libxslt.m4 bug (Edward Rudd), namespace lookup for attribute,
+    namespacedDOCTYPE name</li>
 </ul><h3>1.1.6: Apr 18 2004</h3><ul><li>2 bug fixes about keys fixed one by Mark Vakoc</li>
 </ul><h3>1.1.5: Mar 23 2004</h3><ul><li>performance: use dictionnary lookup for variables</li>
   <li>remove use of _private from source documents</li>
   <li>cleanup of "make tests" output</li>
-  <li>bugfixes: AVT in local variables, use localtime_r to avoid thread
-    troubles (William), dictionary handling bug (William), limited number of
-    stubstitutions in AVT (William), tokenize fix for UTF-8 (William),
-    superfluous namespace (William), xsltproc error code on
-    &lt;xsl:message&gt; halt, OpenVMS fix, dictionnary reference counting
-    change.</li>
-</ul><h3>1.1.4: Feb 23 2004</h3><ul><li>bugfixes: attributes without doc (Mariano Suárez-Alvarez), problem with
-    Yelp, extension problem</li>
+  <li>bugfixes: AVT in local variables, use localtime_r to avoid
+    threadtroubles (William), dictionary handling bug (William), limited
+    number ofstubstitutions in AVT (William), tokenize fix for UTF-8
+    (William),superfluous namespace (William), xsltproc error code
+    on&lt;xsl:message&gt; halt, OpenVMS fix, dictionnary reference
+    countingchange.</li>
+</ul><h3>1.1.4: Feb 23 2004</h3><ul><li>bugfixes: attributes without doc (Mariano Suárez-Alvarez), problem
+    withYelp, extension problem</li>
   <li>display extension modules (Steve Little)</li>
   <li>Windows compilation patch (Mark Vadoc), Mingw (Mikhail Grushinskiy)</li>
-</ul><h3>1.1.3: Feb 16 2004</h3><ul><li>Rewrote the Attribute Value Template code, new XPath compilation
-    interfaces, dictionnary reuses for XSLT with potential for serious
-    performance improvements.</li>
-  <li>bug fixes: portability (William Brack), key() in node-set() results
-    (William), comment before doctype (William), math and node-set() problems
-    (William), cdata element and default namespace (William), behaviour on
-    unknown XSLT elements (Stefan Kost), priority of "//foo" patterns
-    (William), xsl:element and xsl:attribute QName check (William), comments
-    with -- (William), attribute namespace (William), check for ?&gt; in PI
-    (William)</li>
+</ul><h3>1.1.3: Feb 16 2004</h3><ul><li>Rewrote the Attribute Value Template code, new XPath
+    compilationinterfaces, dictionnary reuses for XSLT with potential for
+    seriousperformance improvements.</li>
+  <li>bug fixes: portability (William Brack), key() in node-set()
+    results(William), comment before doctype (William), math and node-set()
+    problems(William), cdata element and default namespace (William),
+    behaviour onunknown XSLT elements (Stefan Kost), priority of "//foo"
+    patterns(William), xsl:element and xsl:attribute QName check (William),
+    commentswith -- (William), attribute namespace (William), check for ?&gt;
+    in PI(William)</li>
   <li>Documentations: cleanup (John Fleck and William)</li>
-  <li>Python: patch for OS-X (Gianni Ceccarelli), enums export (Stephane
-    bidoul)</li>
-</ul><h3>1.1.2: Dec 24 2003</h3><ul><li>Documentation fixes (John Fleck, William Brack), EXSLT documentation
-    (William Brack)</li>
+  <li>Python: patch for OS-X (Gianni Ceccarelli), enums export
+    (Stephanebidoul)</li>
+</ul><h3>1.1.2: Dec 24 2003</h3><ul><li>Documentation fixes (John Fleck, William Brack), EXSLT
+    documentation(William Brack)</li>
   <li>Windows compilation fixes for MSVC and Mingw (Igor Zlatkovic)</li>
-  <li>Bug fixes: exslt:date returning NULL strings (William Brack),
-    namespaces output (William Brack),  key and namespace definition problem,
-    passing options down to the document() parser, xsl:number fixes (William
-    Brack)</li>
+  <li>Bug fixes: exslt:date returning NULL strings (William Brack),namespaces
+    output (William Brack),  key and namespace definition problem,passing
+    options down to the document() parser, xsl:number fixes
+  (WilliamBrack)</li>
 </ul><h3>1.1.1: Dec 10 2003</h3><ul><li>code cleanup (William Brack)</li>
   <li>Windows: Makefile improvements (Igor Zlatkovic)</li>
-  <li>documentation improvements: William Brack, libexslt man page (Jonathan
-    Wakely)</li>
+  <li>documentation improvements: William Brack, libexslt man page
+    (JonathanWakely)</li>
   <li>param in EXSLT functions (Shaun McCance)</li>
   <li>XSLT debugging improvements (Mark Vakoc)</li>
-  <li>bug fixes: number formatting (Bjorn Reese), exslt:tokenize (William
-    Brack), key selector parsing with | reported by Oleg Paraschenko,
-    xsl:element with computed namespaces (William Brack), xslt:import/include
-    recursion detection (William Brack), exslt:function used in keys (William
-    Brack), bug when CDATA_SECTION are foun in the tree (William Brack),
-    entities handling when using XInclude.</li>
+  <li>bug fixes: number formatting (Bjorn Reese), exslt:tokenize
+    (WilliamBrack), key selector parsing with | reported by Oleg
+    Paraschenko,xsl:element with computed namespaces (William Brack),
+    xslt:import/includerecursion detection (William Brack), exslt:function
+    used in keys (WilliamBrack), bug when CDATA_SECTION are foun in the tree
+    (William Brack),entities handling when using XInclude.</li>
 </ul><h3>1.1.0: Nov 4 2003</h3><ul><li>Removed DocBook SGML broken support</li>
   <li>fix xsl:key to work with PIs</li>
-  <li>Makefile and build improvement (Graham Wilson), build cleanup (William
-    Brack), macro fix (Justin Fletcher), build outside of source tree (Roumen
-    Petrov)</li>
-  <li>xsltproc option display fix (Alexey Efimov), --load-trace (Crutcher
-    Dunnavant)</li>
+  <li>Makefile and build improvement (Graham Wilson), build cleanup
+    (WilliamBrack), macro fix (Justin Fletcher), build outside of source tree
+    (RoumenPetrov)</li>
+  <li>xsltproc option display fix (Alexey Efimov), --load-trace
+    (CrutcherDunnavant)</li>
   <li>Python: never use stdout for error</li>
   <li>extension memory error fix (Karl Eichwalder)</li>
   <li>header path fixes (Steve Ball)</li>
   <li>added saxon:line-number() to libexslt (Brett Kail)</li>
-  <li>Fix some tortuous template problems when using predicates (William
-    Brack)</li>
+  <li>Fix some tortuous template problems when using predicates
+  (WilliamBrack)</li>
   <li>Debugger status patch (Kasimier Buchcik)</li>
   <li>Use new libxml2-2.6.x APIs for faster processing</li>
   <li>Make sure xsl:sort is empty</li>
@@ -175,66 +182,67 @@
   <li>apply-templates crash (William Brack)</li>
   <li>bug with imported templates (William Brack)</li>
   <li>imported attribute-sets merging bug (DocBook) (William Brack)</li>
-</ul><h3>1.0.32: Aug 9 2003</h3><ul><li>bugfixes: xsltSaveResultToFile() python binding (Chris Jaeger), EXSLT
-    function (William Brack), RVT for globals (William Brack), EXSLT date
-    (William Brack),
-    <p>speed of large text output, xsl:copy with attributes, strip-space and
-    namespaces prefix, fix for --path xsltproc option, EXST:tokenize (Shaun
-    McCance), EXSLT:seconds (William Brack), sort with multiple keys (William
-    Brack), checking of { and } for attribute value templates (William
-    Brack)</p>
+</ul><h3>1.0.32: Aug 9 2003</h3><ul><li>bugfixes: xsltSaveResultToFile() python binding (Chris Jaeger),
+    EXSLTfunction (William Brack), RVT for globals (William Brack), EXSLT
+    date(William Brack),
+    <p>speed of large text output, xsl:copy with attributes, strip-space
+    andnamespaces prefix, fix for --path xsltproc option, EXST:tokenize
+    (ShaunMcCance), EXSLT:seconds (William Brack), sort with multiple keys
+    (WilliamBrack), checking of { and } for attribute value templates
+    (WilliamBrack)</p>
   </li>
   <li>Python bindings for extension elements (Sean Treadway)</li>
   <li>EXSLT:split added (Shaun McCance)</li>
   <li>portability fixes for HP-UX/Solaris/IRIX (William Brack)</li>
   <li>doc cleanup</li>
-</ul><h3>1.0.31: Jul 6 2003</h3><ul><li>bugfixes: xsl:copy on namespace nodes, AVT for xsl:sort order, fix for
-    the debugger (Keith Isdale), output filename limitation, trio.h and
-    triodef.h added (Albert Chin), EXSLT node-set (Peter Breitenlohner),
-    xsltChoose and whitespace (Igor Zlatkovic),
-    <p>stylesheet compilation (Igor Zlatkovic), NaN and sort (William Brack),
-    RVT bug introduced in 1.0.30</p>
+</ul><h3>1.0.31: Jul 6 2003</h3><ul><li>bugfixes: xsl:copy on namespace nodes, AVT for xsl:sort order, fix
+    forthe debugger (Keith Isdale), output filename limitation, trio.h
+    andtriodef.h added (Albert Chin), EXSLT node-set (Peter
+    Breitenlohner),xsltChoose and whitespace (Igor Zlatkovic),
+    <p>stylesheet compilation (Igor Zlatkovic), NaN and sort (William
+    Brack),RVT bug introduced in 1.0.30</p>
   </li>
   <li>avoid generating &amp;quot; (fix in libxml2-2.5.8)</li>
-  <li>fix 64bit cleaness problem and compilation troubles introduced in
-  1.0.30</li>
+  <li>fix 64bit cleaness problem and compilation troubles introduced
+  in1.0.30</li>
   <li>Windows makefile generation (Igor Zlatkovic)</li>
   <li>HP-UX portability fix</li>
 </ul><h3>1.0.30: May 4 2003</h3><ul><li>Fixes and new APIs to handle Result Value Trees and avoid leaks</li>
-  <li>Fixes for: EXSLT math pow() function (Charles Bozeman), global
-    parameter and global variables mismatch, a segfault on pattern
-    compilation errors, namespace copy in xsl:copy-of, python generator
-    problem, OpenVMS trio update, premature call to xsltFreeStackElem (Igor),
-    current node when templates applies to attributes</li>
+  <li>Fixes for: EXSLT math pow() function (Charles Bozeman), globalparameter
+    and global variables mismatch, a segfault on patterncompilation errors,
+    namespace copy in xsl:copy-of, python generatorproblem, OpenVMS trio
+    update, premature call to xsltFreeStackElem (Igor),current node when
+    templates applies to attributes</li>
 </ul><h3>1.0.29: Apr 1 2003</h3><ul><li>performance improvements especially for large flat documents</li>
-  <li>bug fixes: Result Value Tree handling, XML IDs, keys(), extra namespace
-    declarations with xsl:elements.</li>
-  <li>portability: python and trio fixes (Albert Chin), python on Solaris
-    (Ben Phillips)</li>
+  <li>bug fixes: Result Value Tree handling, XML IDs, keys(), extra
+    namespacedeclarations with xsl:elements.</li>
+  <li>portability: python and trio fixes (Albert Chin), python on Solaris(Ben
+    Phillips)</li>
 </ul><h3>1.0.28: Mar 24 2003</h3><ul><li>fixed node() in patterns semantic.</li>
   <li>fixed a memory access problem in format-number()</li>
   <li>fixed stack overflow in recursive global variable or params</li>
-  <li>cleaned up Result Value Tree handling, and fixed a couple of old bugs
-    in the process</li>
-</ul><h3>1.0.27: Feb 24 2003</h3><ul><li>bug fixes: spurious xmlns:nsX="" generation, serialization bug (in
-    libxml2), a namespace copy problem, errors in the RPM spec prereqs</li>
+  <li>cleaned up Result Value Tree handling, and fixed a couple of old bugsin
+    the process</li>
+</ul><h3>1.0.27: Feb 24 2003</h3><ul><li>bug fixes: spurious xmlns:nsX="" generation, serialization bug
+    (inlibxml2), a namespace copy problem, errors in the RPM spec prereqs</li>
   <li>Windows path canonicalization and document cache fix (Igor)</li>
-</ul><h3>1.0.26: Feb 10 2003</h3><ul><li>Fixed 3 serious bugs in document() and stylesheet compilation which
-    could lead to a crash</li>
-</ul><h3>1.0.25: Feb 5 2003</h3><ul><li>Bug fix: double-free for standalone stylesheets introduced in 1.0.24, C
-    syntax pbm, 3 bugs reported by Eric van der Vlist</li>
-  <li>Some XPath and XInclude related problems were actually fixed in
-    libxml2-2.5.2</li>
+</ul><h3>1.0.26: Feb 10 2003</h3><ul><li>Fixed 3 serious bugs in document() and stylesheet compilation
+    whichcould lead to a crash</li>
+</ul><h3>1.0.25: Feb 5 2003</h3><ul><li>Bug fix: double-free for standalone stylesheets introduced in 1.0.24,
+    Csyntax pbm, 3 bugs reported by Eric van der Vlist</li>
+  <li>Some XPath and XInclude related problems were actually fixed
+    inlibxml2-2.5.2</li>
   <li>Documentation: emphasize taht --docbook is not for XML docs.</li>
-</ul><h3>1.0.24: Jan 14 2003</h3><ul><li>bug fixes: imported global varables, python bindings (Stéphane Bidoul),
-    EXSLT memory leak (Charles Bozeman), namespace generation on
-    xsl:attribute, space handling with imports (Daniel Stodden),
-    extension-element-prefixes (Josh Parsons), comments within xsl:text (Matt
-    Sergeant), superfluous xmlns generation, XInclude related bug for
-    numbering, EXSLT strings (Alexey Efimov), attribute-sets computation on
-    imports, extension module init and shutdown callbacks not called</li>
-  <li>HP-UX portability (Alexey Efimov), Windows makefiles (Igor and Stephane
-    Bidoul), VMS makefile updates (Craig A. Berry)</li>
+</ul><h3>1.0.24: Jan 14 2003</h3><ul><li>bug fixes: imported global varables, python bindings (Stéphane
+    Bidoul),EXSLT memory leak (Charles Bozeman), namespace generation
+    onxsl:attribute, space handling with imports (Daniel
+    Stodden),extension-element-prefixes (Josh Parsons), comments within
+    xsl:text (MattSergeant), superfluous xmlns generation, XInclude related
+    bug fornumbering, EXSLT strings (Alexey Efimov), attribute-sets
+    computation onimports, extension module init and shutdown callbacks not
+    called</li>
+  <li>HP-UX portability (Alexey Efimov), Windows makefiles (Igor and
+    StephaneBidoul), VMS makefile updates (Craig A. Berry)</li>
   <li>adds xsltGetProfileInformation() (Michael Rothwell)</li>
   <li>fix the API generation scripts</li>
   <li>API to provide the sorting routines (Richard Jinks)</li>
@@ -244,31 +252,31 @@
   <li>document() now support fragment identifiers in URIs</li>
 </ul><h3>1.0.23: Nov 17 2002</h3><ul><li>Windows build cleanup (Igor)</li>
   <li>Unix build and RPM packaging cleanup</li>
-  <li>Improvement of the python bindings: extension functions and activating
-    EXSLT</li>
-  <li>various bug fixes: number formatting, portability for bounded string
-    functions, CData nodes, key(), @*[...] patterns</li>
+  <li>Improvement of the python bindings: extension functions and
+    activatingEXSLT</li>
+  <li>various bug fixes: number formatting, portability for bounded
+    stringfunctions, CData nodes, key(), @*[...] patterns</li>
   <li>Documentation improvements (John Fleck)</li>
   <li>added libxslt.m4 (Thomas Schraitle)</li>
 </ul><h3>1.0.22: Oct 18 2002</h3><ul><li>Updates on the Windows Makefiles</li>
-  <li>Added a security module, and a related set of new options to
-  xsltproc</li>
+  <li>Added a security module, and a related set of new options
+  toxsltproc</li>
   <li>Allowed per transformation error handler.</li>
-  <li>Fixed a few bugs: node() semantic, URI escaping, media-type, attribute
-    lists</li>
-</ul><h3>1.0.21: Sep 26 2002</h3><ul><li>Bug fixes: match="node()", date:difference() (Igor and Charlie
-    Bozeman), disable-output-escaping</li>
+  <li>Fixed a few bugs: node() semantic, URI escaping, media-type,
+    attributelists</li>
+</ul><h3>1.0.21: Sep 26 2002</h3><ul><li>Bug fixes: match="node()", date:difference() (Igor and CharlieBozeman),
+    disable-output-escaping</li>
   <li>Python bindings: style.saveResultToString() from Ralf Mattes</li>
   <li>Logos from Marc Liyanage</li>
   <li>Mem leak fix from Nathan Myers</li>
-  <li>Makefile: DESTDIR fix from Christophe Merlet, AMD x86_64 (Mandrake),
-    Windows (Igor), Python detection</li>
+  <li>Makefile: DESTDIR fix from Christophe Merlet, AMD x86_64
+    (Mandrake),Windows (Igor), Python detection</li>
   <li>Documentation improvements: John Fleck</li>
 </ul><h3>1.0.20: Aug 23 2002</h3><ul><li>Windows makefile updates (Igor) and x86-64 (Frederic Crozat)</li>
   <li>fixed HTML meta tag saving for Mac/IE users</li>
   <li>possible leak patches from Nathan Myers</li>
-  <li>try to handle document('') as best as possible depending in the
-  cases</li>
+  <li>try to handle document('') as best as possible depending in
+  thecases</li>
   <li>Fixed the DocBook stylesheets handling problem</li>
   <li>Fixed a few XSLT reported errors</li>
 </ul><h3>1.0.19:  July 6 2002</h3><ul><li>EXSLT: dynamic functions and date support bug fixes (Mark Vakoc)</li>
@@ -277,89 +285,84 @@
   <li>document('') fix: bug pointed by Eric van der Vlist</li>
   <li>xsl:message with terminate="yes" fixes: William Brack</li>
   <li>xsl:sort order support added: Ken Neighbors</li>
-  <li>a few other bug fixes, some of them requiring the latest version of
-    libxml2</li>
-</ul><h3>1.0.18: May 27 2002</h3><ul><li>a number of bug fixes: attributes, extra namespace declarations
-    (DocBook), xsl:include crash (Igor), documentation (Christian Cornelssen,
-    Charles Bozeman and Geert Kloosterman),  element-available (Richard
-  Jinks)</li>
-  <li>xsltproc can now list teh registered extensions thanks to Mark
-  Vakoc</li>
-  <li>there is a new API to save directly to a string
-    xsltSaveResultToString() by Morus Walter</li>
+  <li>a few other bug fixes, some of them requiring the latest version
+    oflibxml2</li>
+</ul><h3>1.0.18: May 27 2002</h3><ul><li>a number of bug fixes: attributes, extra namespace
+    declarations(DocBook), xsl:include crash (Igor), documentation (Christian
+    Cornelssen,Charles Bozeman and Geert Kloosterman),  element-available
+    (RichardJinks)</li>
+  <li>xsltproc can now list teh registered extensions thanks to MarkVakoc</li>
+  <li>there is a new API to save directly to a stringxsltSaveResultToString()
+    by Morus Walter</li>
   <li>specific error registration function for the python API</li>
-</ul><h3>1.0.17: April 29 2002</h3><ul><li>cleanup in code, XSLT debugger support and Makefiles for Windows by
-  Igor</li>
+</ul><h3>1.0.17: April 29 2002</h3><ul><li>cleanup in code, XSLT debugger support and Makefiles for Windows
+  byIgor</li>
   <li>a C++ portability fix by Mark Vakoc</li>
   <li>EXSLT date improvement and regression tests by Charles Bozeman</li>
   <li>attempt to fix a bug in xsltProcessUserParamInternal</li>
-</ul><h3>1.0.16: April 15 2002</h3><ul><li>Bug fixes: strip-space, URL in HTML output, error when xsltproc can't
-    save</li>
+</ul><h3>1.0.16: April 15 2002</h3><ul><li>Bug fixes: strip-space, URL in HTML output, error when xsltproc
+    can'tsave</li>
   <li>portability fixes: OSF/1, IEEE on alphas, Windows, Python bindings</li>
-</ul><h3>1.0.15: Mar 25 2002</h3><ul><li>Bugfixes: XPath, python Makefile, recursive attribute sets, @foo[..]
-    templates</li>
+</ul><h3>1.0.15: Mar 25 2002</h3><ul><li>Bugfixes: XPath, python Makefile, recursive attribute sets,
+    @foo[..]templates</li>
   <li>Debug of memory alocation with valgind</li>
-  <li>serious profiling leading to significant improvement for DocBook
-    processing</li>
+  <li>serious profiling leading to significant improvement for
+    DocBookprocessing</li>
   <li>revamp of the Windows build</li>
 </ul><h3>1.0.14: Mar 18 2002</h3><ul><li>Improvement in the XPath engine (libxml2-2.4.18)</li>
   <li>Nasty bug fix related to exslt:node-set</li>
-  <li>Fixed the python Makefiles, cleanup of doc comments, Windows
-    portability fixes</li>
+  <li>Fixed the python Makefiles, cleanup of doc comments, Windowsportability
+    fixes</li>
 </ul><h3>1.0.13: Mar 8 2002</h3><ul><li>a number of bug fixes including "namespace node have no parents"</li>
   <li>Improvement of the Python bindings</li>
-  <li>Charles Bozeman provided fixes and regression tests for exslt date
-    functions.</li>
+  <li>Charles Bozeman provided fixes and regression tests for exslt
+    datefunctions.</li>
 </ul><h3>1.0.12: Feb 11 2002</h3><ul><li>Fixed the makefiles especially the python module ones</li>
   <li>half a dozen bugs fixes including 2 old ones</li>
-</ul><h3>1.0.11: Feb 8 2002</h3><ul><li>Change of Licence to the <a href="http://www.opensource.org/licenses/mit-license.html">MIT
-  Licence</a></li>
-  <li>Added a beta version of the Python bindings, including support to
-    extend the engine with functions written in Python</li>
+</ul><h3>1.0.11: Feb 8 2002</h3><ul><li>Change of Licence to the <a href="http://www.opensource.org/licenses/mit-license.html">MITLicence</a></li>
+  <li>Added a beta version of the Python bindings, including support toextend
+    the engine with functions written in Python</li>
   <li>A number of bug fixes</li>
   <li>Charlie Bozeman provided more EXSLT functions</li>
   <li>Portability fixes</li>
 </ul><h3>1.0.10: Jan 14 2002</h3><ul><li>Windows fixes for Win32 from Igor</li>
   <li>Fixed the Solaris compilation trouble (Albert)</li>
   <li>Documentation changes and updates: John Fleck</li>
-  <li>Added a stringparam option to avoid escaping hell at the shell
-  level</li>
+  <li>Added a stringparam option to avoid escaping hell at the shelllevel</li>
   <li>A few bug fixes</li>
 </ul><h3>1.0.9: Dec 7 2001</h3><ul><li>Makefile patches from Peter Williams</li>
   <li>attempt to fix the compilation problem associated to prelinking</li>
   <li>obsoleted libxsltbreakpoint now deprecated and frozen to 1.0.8 API</li>
-  <li>xsltproc return codes are now significant, John Fleck updated the
-    documentation</li>
-  <li>patch to allow as much as 40 steps in patterns (Marc Tardif), should be
-    made dynamic really</li>
-  <li>fixed a bug raised by Nik Clayton when using doctypes with HTML
-  output</li>
+  <li>xsltproc return codes are now significant, John Fleck updated
+    thedocumentation</li>
+  <li>patch to allow as much as 40 steps in patterns (Marc Tardif), should
+    bemade dynamic really</li>
+  <li>fixed a bug raised by Nik Clayton when using doctypes with
+  HTMLoutput</li>
   <li>patches from Keith Isdale to interface with xsltdebugger</li>
-</ul><h3>1.0.8: Nov 26 2001</h3><ul><li>fixed an annoying header problem, removed a few bugs and some code
-    cleanup</li>
+</ul><h3>1.0.8: Nov 26 2001</h3><ul><li>fixed an annoying header problem, removed a few bugs and some
+    codecleanup</li>
   <li>patches for Windows and update of Windows Makefiles by Igor</li>
   <li>OpenVMS port instructions from John A Fotheringham</li>
-  <li>fixed some Makefiles annoyance and libraries prelinking
-  informations</li>
+  <li>fixed some Makefiles annoyance and libraries prelinkinginformations</li>
 </ul><h3>1.0.7: Nov 10 2001</h3><ul><li>remove a compilation problem with LIBXSLT_PUBLIC</li>
   <li>Finishing the integration steps for Keith Isdale debugger</li>
   <li>fixes the handling of indent="no" on HTML output</li>
   <li>fixes on the configure script and RPM spec file</li>
-</ul><h3>1.0.6: Oct 30 2001</h3><ul><li>bug fixes on number formatting (Thomas), date/time functions (Bruce
-    Miller)</li>
+</ul><h3>1.0.6: Oct 30 2001</h3><ul><li>bug fixes on number formatting (Thomas), date/time functions
+    (BruceMiller)</li>
   <li>update of the Windows Makefiles (Igor)</li>
   <li>fixed DOCTYPE generation rules for HTML output (me)</li>
-</ul><h3>1.0.5: Oct 10 2001</h3><ul><li>some portability fixes, including Windows makefile updates from
-  Igor</li>
+</ul><h3>1.0.5: Oct 10 2001</h3><ul><li>some portability fixes, including Windows makefile updates fromIgor</li>
   <li>fixed a dozen bugs on XSLT and EXSLT (me and Thomas Broyer)</li>
-  <li>support for Saxon's evaluate and expressions extensions added (initial
-    contribution from Darren Graves)</li>
+  <li>support for Saxon's evaluate and expressions extensions added
+    (initialcontribution from Darren Graves)</li>
   <li>better handling of XPath evaluation errors</li>
 </ul><h3>1.0.4: Sep 12 2001</h3><ul><li>Documentation updates from John fleck</li>
-  <li>bug fixes (DocBook  FO generation should be fixed)  and portability
-    improvements</li>
-  <li>Thomas Broyer improved the existing EXSLT support and added String,
-    Time and Date core functions support</li>
+  <li>bug fixes (DocBook  FO generation should be fixed)  and
+    portabilityimprovements</li>
+  <li>Thomas Broyer improved the existing EXSLT support and added String,Time
+    and Date core functions support</li>
 </ul><h3>1.0.3:  Aug 23 2001</h3><ul><li>XML Catalog support see the doc</li>
   <li>New NaN/Infinity floating point code</li>
   <li>A few bug fixes</li>
@@ -374,45 +377,44 @@
   <li>fixed the profiler on Windows</li>
   <li>bug fixes</li>
 </ul><h3>1.0.0: July 10 2001</h3><ul><li>a lot of cleanup, a lot of regression tests added or fixed</li>
-  <li>added a documentation for <a href="extensions.html">writing
-    extensions</a></li>
+  <li>added a documentation for <a href="extensions.html">writingextensions</a></li>
   <li>fixed some variable evaluation problems (with William)</li>
-  <li>added profiling of stylesheet execution accessible as the xsltproc
-    --profile option</li>
-  <li>fixed element-available() and the implementation of the various
-    chunking methods present, Norm Walsh provided a lot of feedback</li>
-  <li>exclude-result-prefixes and namespaces output should now work as
-    expected</li>
-  <li>added support of embedded stylesheet as described in section 2.7 of the
-    spec</li>
+  <li>added profiling of stylesheet execution accessible as the
+    xsltproc--profile option</li>
+  <li>fixed element-available() and the implementation of the variouschunking
+    methods present, Norm Walsh provided a lot of feedback</li>
+  <li>exclude-result-prefixes and namespaces output should now work
+  asexpected</li>
+  <li>added support of embedded stylesheet as described in section 2.7 of
+    thespec</li>
 </ul><h3>0.14.0: July 5 2001</h3><ul><li>lot of bug fixes, and code cleanup</li>
   <li>completion of the little XSLT-1.0 features left unimplemented</li>
   <li>Added and implemented the extension API suggested by Thomas Broyer</li>
   <li>the Windows MSC environment should be complete</li>
-  <li>tested and optimized with a really large document (DocBook Definitive
-    Guide) libxml/libxslt should really be faster on serious workloads</li>
+  <li>tested and optimized with a really large document (DocBook
+    DefinitiveGuide) libxml/libxslt should really be faster on serious
+    workloads</li>
 </ul><h3>0.13.0: June 26 2001</h3><ul><li>lots of cleanups</li>
   <li>fixed a C++ compilation problem</li>
   <li>couple of fixes to xsltSaveTo()</li>
-  <li>try to fix Docbook-xslt-1.4 and chunking, updated the regression test
-    with them</li>
+  <li>try to fix Docbook-xslt-1.4 and chunking, updated the regression
+    testwith them</li>
   <li>fixed pattern compilation and priorities problems</li>
   <li>Patches for Windows and MSC project mostly contributed by Yon Derek</li>
   <li>update to the Tutorial by John Fleck</li>
   <li>William fixed bugs in templates and for-each functions</li>
-  <li>added a new interface xsltRunStylesheet() for a more flexible output
-    (incomplete), added -o option to xsltproc</li>
+  <li>added a new interface xsltRunStylesheet() for a more flexible
+    output(incomplete), added -o option to xsltproc</li>
 </ul><h3>0.12.0: June 18 2001</h3><ul><li>fixed a dozen of bugs reported</li>
-  <li>HTML generation should be quite better (requires libxml-2.3.11 upgrade
-    too)</li>
+  <li>HTML generation should be quite better (requires libxml-2.3.11
+    upgradetoo)</li>
   <li>William fixed some problems with document()</li>
-  <li>Fix namespace nodes selection and copy (requires libxml-2.3.11 upgrade
-    too)</li>
-  <li>John Fleck added a<a href="tutorial/libxslttutorial.html">
-  tutorial</a></li>
+  <li>Fix namespace nodes selection and copy (requires libxml-2.3.11
+    upgradetoo)</li>
+  <li>John Fleck added a<a href="tutorial/libxslttutorial.html">tutorial</a></li>
   <li>Fixes for namespace handling when evaluating variables</li>
-  <li>XInclude global flag added to process XInclude on document() if
-    requested</li>
+  <li>XInclude global flag added to process XInclude on document()
+  ifrequested</li>
   <li>made xsltproc --version more detailed</li>
 </ul><h3>0.11.0: June 1 2001</h3><p>Mostly a bug fix release.</p><ul><li>integration of catalogs from xsltproc</li>
   <li>added --version to xsltproc for bug reporting</li>
@@ -422,8 +424,8 @@
   <li>William fixed the XPath string functions when using unicode</li>
 </ul><h3>0.10.0: May 19 2001</h3><ul><li>cleanups to make stylesheet read-only (not 100% complete)</li>
   <li>fixed URI resolution in document()</li>
-  <li>force all XPath expression to be compiled at stylesheet parsing time,
-    even if unused ...</li>
+  <li>force all XPath expression to be compiled at stylesheet parsing
+    time,even if unused ...</li>
   <li>Fixed HTML default output detection</li>
   <li>Fixed double attribute generation #54446</li>
   <li>Fixed {{ handling in attributes #54451</li>
@@ -433,25 +435,25 @@
   <li>William Brack and Bjorn Reese improved format-number()</li>
   <li>Fixed multiple sort, it should really work now</li>
   <li>added a --docbook option for SGML DocBook input (hackish)</li>
-  <li>a number of other bug fixes and regression test added as people were
-    submitting them</li>
+  <li>a number of other bug fixes and regression test added as people
+    weresubmitting them</li>
 </ul><h3>0.9.0: May 3 2001</h3><ul><li>lot of various bugfixes, extended the regression suite</li>
   <li>xsltproc should work with multiple params</li>
   <li>added an option to use xsltproc with HTML input</li>
-  <li>improved the stylesheet compilation, processing of complex stylesheets
-    should be faster</li>
-  <li>using the same stylesheet for concurrent processing on multithreaded
-    programs should work now</li>
+  <li>improved the stylesheet compilation, processing of complex
+    stylesheetsshould be faster</li>
+  <li>using the same stylesheet for concurrent processing on
+    multithreadedprograms should work now</li>
   <li>fixed another batch of namespace handling problems</li>
   <li>Implemented multiple level of sorting</li>
 </ul><h3>0.8.0: Apr 22 2001</h3><ul><li>fixed ansidecl.h problem</li>
   <li>fixed unparsed-entity-uri() and generate-id()</li>
   <li>sort semantic fixes and priority prob from William M. Brack</li>
-  <li>fixed namespace handling problems in XPath expression computations
-    (requires libxml-2.3.7)</li>
+  <li>fixed namespace handling problems in XPath expression
+    computations(requires libxml-2.3.7)</li>
   <li>fixes to current() and key()</li>
-  <li>other, smaller fixes, lots of testing with N Walsh DocBook HTML
-    stylesheets</li>
+  <li>other, smaller fixes, lots of testing with N Walsh DocBook
+    HTMLstylesheets</li>
 </ul><h3>0.7.0: Apr 10 2001</h3><ul><li>cleanup using stricter compiler flags</li>
   <li>command line parameter passing</li>
   <li>fix to xsltApplyTemplates from William M. Brack</li>
@@ -461,13 +463,13 @@
   <li>document() extension should function properly</li>
   <li>fixed a number or reported bugs</li>
 </ul><h3>0.5.0: Mar 10 2001</h3><ul><li>fifth beta</li>
-  <li>some optimization work, for the moment 2 XSLT transform cannot use the
-    same stylesheet at the same time (to be fixed)</li>
+  <li>some optimization work, for the moment 2 XSLT transform cannot use
+    thesame stylesheet at the same time (to be fixed)</li>
   <li>fixed problems with handling of tree results</li>
   <li>fixed a reported strip-spaces problem</li>
   <li>added more reported/fixed bugs to the test suite</li>
-  <li>incorporated William M. Brack fix for imports and global variables as
-    well as patch for with-param support in apply-templates</li>
+  <li>incorporated William M. Brack fix for imports and global variables
+    aswell as patch for with-param support in apply-templates</li>
   <li>a bug fix on for-each</li>
 </ul><h3>0.4.0: Mar 1 2001</h3><ul><li>fourth beta test, released at the same time of libxml2-2.3.3</li>
   <li>bug fixes</li>
@@ -479,17 +481,17 @@
   <li>some optimization</li>
   <li>added DocBook XSL based testsuite</li>
 </ul><h3>0.2.0: Feb 15 2001</h3><ul><li>second beta version, released at the same time as libxml2-2.3.1</li>
-  <li>getting close to feature completion, lot of bug fixes, some in the HTML
-    and XPath support of libxml</li>
-  <li>start becoming usable for real work. This version can now regenerate
-    the XML 2e HTML from the original XML sources and the associated
-    stylesheets (in <a href="http://www.w3.org/TR/REC-xml#b4d250b6c21">section I of the XML
-    REC</a>)</li>
-  <li>Still misses extension element/function/prefixes support. Support of
-    key() and document() is not complete</li>
+  <li>getting close to feature completion, lot of bug fixes, some in the
+    HTMLand XPath support of libxml</li>
+  <li>start becoming usable for real work. This version can now regeneratethe
+    XML 2e HTML from the original XML sources and the associatedstylesheets
+    (in <a href="http://www.w3.org/TR/REC-xml#b4d250b6c21">section I of the
+    XMLREC</a>)</li>
+  <li>Still misses extension element/function/prefixes support. Support
+    ofkey() and document() is not complete</li>
 </ul><h3>0.1.0: Feb 8 2001</h3><ul><li>first beta version, released at the same time as libxml2-2.3.0</li>
   <li>lots of bug fixes, first "testing" version, but incomplete</li>
 </ul><h3>0.0.1: Jan 25 2001</h3><ul><li>first alpha version released at the same time as libxml2-2.2.12</li>
-  <li>Framework in place, should work on simple examples, but far from being
-    feature complete</li>
+  <li>Framework in place, should work on simple examples, but far from
+    beingfeature complete</li>
 </ul><p><a href="bugs.html">Daniel Veillard</a></p></td></tr></table></td></tr></table></td></tr></table></td></tr></table></td></tr></table></body></html>

Modified: packages/libxslt/trunk/doc/python.html
===================================================================
--- packages/libxslt/trunk/doc/python.html	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/doc/python.html	2006-06-08 22:29:07 UTC (rev 565)
@@ -8,56 +8,52 @@
 H3 {font-family: Verdana,Arial,Helvetica}
 A:link, A:visited, A:active { text-decoration: underline }
     </style><title>Python and bindings</title></head><body bgcolor="#8b7765" text="#000000" link="#a06060" vlink="#000000"><table border="0" width="100%" cellpadding="5" cellspacing="0" align="center"><tr><td width="120"><a href="http://swpat.ffii.org/"><img src="epatents.png" alt="Action against software patents" /></a></td><td width="180"><a href="http://www.gnome.org/"><img src="gnome2.png" alt="Gnome2 Logo" /></a><a href="http://www.w3.org/Status"><img src="w3c.png" alt="W3C logo" /></a><a href="http://www.redhat.com"><img src="redhat.gif" alt="Red Hat Logo" /></a><div align="left"><a href="http://xmlsoft.org/XSLT/"><img src="Libxslt-Logo-180x168.gif" alt="Made with Libxslt Logo" /></a></div></td><td><table border="0" width="90%" cellpadding="2" cellspacing="0" align="center" bgcolor="#000000"><tr><td><table width="100%" border="0" cellspacing="1" cellpadding="3" bgcolor="#fffacd"><tr><td align="center"><h1>The XSLT C library for Gnome</h1><h2>Python and bindings</h2></td></tr></table></td></tr></table></td></tr></table><table border="0" cellpadding="4" cellspacing="0" width="100%" align="center"><tr><td bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="2" width="100%"><tr><td valign="top" width="200" bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000"><tr><td><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>Main Menu</b></center></td></tr><tr><td bgcolor="#fffacd"><form action="search.php" enctype="application/x-www-form-urlencoded" method="get"><input name="query" type="text" size="20" value="" /><input name="submit" type="submit" value="Search ..." /></form><ul><li><a href="index.html">Home</a></li><li><a href="http://xmlsoft.org/wiki">Wiki</a></li><li><a href="intro.html">Introduction</a></li><li><a href="docs.html">Documentation</a></li><li><a href="bugs.html">Reporting bugs and getting help</a></li><li><a href="help.html">How to help</a></li><li><a href="downloads.html">Downloads</a></li><li><a href="FAQ.html">FAQ</a></li><li><a href="news.html">News</a></li><li><a href="xsltproc2.html">The xsltproc tool</a></li><li><a href="docbook.html">DocBook</a></li><li><a href="API.html">The programming API</a></li><li><a href="python.html">Python and bindings</a></li><li><a href="internals.html">Library internals</a></li><li><a href="extensions.html">Writing extensions</a></li><li><a href="contribs.html">Contributions</a></li><li><a href="EXSLT/index.html" style="font-weight:bold">libexslt</a></li><li><a href="xslt.html">flat page</a>, <a href="site.xsl">stylesheet</a></li><li><a href="html/index.html" style="font-weight:bold">API Menu</a></li><li><a href="ChangeLog.html">ChangeLog</a></li></ul></td></tr></table><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>Related links</b></center></td></tr><tr><td bgcolor="#fffacd"><ul><li><a href="tutorial/libxslttutorial.html">Tutorial</a>,
-          <a href="tutorial2/libxslt_pipes.html">Tutorial2</a></li><li><a href="xsltproc.html">Man page for xsltproc</a></li><li><a href="http://mail.gnome.org/archives/xslt/">Mail archive</a></li><li><a href="http://xmlsoft.org/">XML libxml2</a></li><li><a href="ftp://xmlsoft.org/">FTP</a></li><li><a href="http://www.zlatkovic.com/projects/libxml/">Windows binaries</a></li><li><a href="http://garypennington.net/libxml2/">Solaris binaries</a></li><li><a href="http://www.explain.com.au/oss/libxml2xslt.html">MacOsX binaries</a></li><li><a href="http://bugzilla.gnome.org/buglist.cgi?product=libxslt">Bug Tracker</a></li><li><a href="http://www.zend.com/php5/articles/php5-xmlphp.php#Heading17">XSLT with PHP</a></li><li><a href="http://www.mod-xslt2.com/">Apache module</a></li><li><a href="http://sourceforge.net/projects/libxml2-pas/">Pascal bindings</a></li><li><a href="http://xsldbg.sourceforge.net/">Xsldbg Debugger</a></li></ul></td></tr></table><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>API Indexes</b></center></td></tr><tr><td bgcolor="#fffacd"><ul><li><a href="APIchunk0.html">Alphabetic</a></li><li><a href="APIconstructors.html">Constructors</a></li><li><a href="APIfunctions.html">Functions/Types</a></li><li><a href="APIfiles.html">Modules</a></li><li><a href="APIsymbols.html">Symbols</a></li></ul></td></tr></table></td></tr></table></td><td valign="top" bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="1" width="100%"><tr><td><table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000"><tr><td><table border="0" cellpadding="3" cellspacing="1" width="100%"><tr><td bgcolor="#fffacd"><p>There is a number of language bindings and wrappers available for libxml2,
-the list below is not exhaustive. Please contact the <a href="http://mail.gnome.org/mailman/listinfo/xml-bindings">xml-bindings at gnome.org</a>
-(<a href="http://mail.gnome.org/archives/xml-bindings/">archives</a>) in
-order to get updates to this list or to discuss the specific topic of libxml2
-or libxslt wrappers or bindings:</p><ul><li><a href="http://mail.gnome.org/archives/xml/2001-March/msg00014.html">Matt
-    Sergeant</a> developped <a href="http://axkit.org/download/">XML::LibXML
-    and XML::LibXSLT</a>, Perl wrappers for libxml2/libxslt as part of the <a href="http://axkit.com/">AxKit XML application server</a></li>
-  <li><a href="mailto:dkuhlman at cutter.rexx.com">Dave Kuhlman</a> provides and
-    earlier version of the libxml/libxslt <a href="http://www.rexx.com/~dkuhlman">wrappers for Python</a></li>
-  <li>Petr Kozelka provides <a href="http://sourceforge.net/projects/libxml2-pas">Pascal units to glue
-    libxml2</a> with Kylix, Delphi and other Pascal compilers</li>
-  <li>Wai-Sun "Squidster" Chia provides <a href="http://www.rubycolor.org/arc/redist/">bindings for Ruby</a>  and
-    libxml2 bindings are also available in Ruby through the <a href="http://libgdome-ruby.berlios.de/">libgdome-ruby</a> module
-    maintained by Tobias Peters.</li>
-  <li>Steve Ball and contributors maintains <a href="http://tclxml.sourceforge.net/">libxml2 and libxslt bindings for
-    Tcl</a></li>
-  <li><a href="mailto:xmlwrapp at pmade.org">Peter Jones</a> maintains C++
-    bindings for libxslt within <a href="http://pmade.org/pjones/software/xmlwrapp/">xmlwrapp</a></li>
-  <li><a href="phillim2 at comcast.net">Mike Phillips</a> provides a module
-    using <a href="http://siasl.dyndns.org/projects/projects.html">libxslt
-    for PHP</a>.</li>
-  <li><a href="http://savannah.gnu.org/projects/classpathx/">LibxmlJ</a> is
-    an effort to create a 100% JAXP-compatible Java wrapper for libxml2 and
-    libxslt as part of GNU ClasspathX project.</li>
-  <li>Patrick McPhee provides Rexx bindings fof libxml2 and libxslt, look for
-    <a href="http://www.interlog.com/~ptjm/software.html">RexxXML</a>.</li>
-  <li><a href="http://www.satimage.fr/software/en/xml_suite.html">Satimage</a>
-    provides <a href="http://www.satimage.fr/software/en/downloads_osaxen.html">XMLLib
-    osax</a>. This is an osax for Mac OS X with a set of commands to
-    implement in AppleScript the XML DOM, XPATH and XSLT.</li>
-</ul><p>The libxslt Python module depends on the <a href="http://xmlsoft.org/python.html">libxml2 Python</a> module.</p><p>The distribution includes a set of Python bindings, which are garanteed to
-be maintained as part of the library in the future, though the Python
-interface have not yet reached the completeness of the C API.</p><p><a href="mailto:stephane.bidoul at softwareag.com">Stéphane Bidoul</a>
-maintains <a href="http://users.skynet.be/sbi/libxml-python/">a Windows port
-of the Python bindings</a>.</p><p>Note to people interested in building bindings, the API is formalized as
-<a href="libxslt-api.xml">an XML API description file</a> which allows to
-automate a large part of the Python bindings, this includes function
-descriptions, enums, structures, typedefs, etc... The Python script used to
-build the bindings is python/generator.py in the source distribution.</p><p>To install the Python bindings there are 2 options:</p><ul><li>If you use an RPM based distribution, simply install the <a href="http://rpmfind.net/linux/rpm2html/search.php?query=libxml2-python">libxml2-python
-    RPM</a> and the <a href="http://rpmfind.net/linux/rpm2html/search.php?query=libxslt-python">libxslt-python
-    RPM</a>.</li>
-  <li>Otherwise use the <a href="ftp://xmlsoft.org/libxml2/python/">libxml2-python
-    module distribution</a> corresponding to your installed version of
-    libxml2 and libxslt. Note that to install it you will need both libxml2
-    and libxslt installed and run "python setup.py build install" in the
-    module tree.</li>
-</ul><p>The distribution includes a set of examples and regression tests for the
-python bindings in the <code>python/tests</code> directory. Here are some
-excepts from those tests:</p><h3>basic.py:</h3><p>This is a basic test of XSLT interfaces: loading a stylesheet and a
-document, transforming the document and saving the result.</p><pre>import libxml2
+          <a href="tutorial2/libxslt_pipes.html">Tutorial2</a></li><li><a href="xsltproc.html">Man page for xsltproc</a></li><li><a href="http://mail.gnome.org/archives/xslt/">Mail archive</a></li><li><a href="http://xmlsoft.org/">XML libxml2</a></li><li><a href="ftp://xmlsoft.org/">FTP</a></li><li><a href="http://www.zlatkovic.com/projects/libxml/">Windows binaries</a></li><li><a href="http://garypennington.net/libxml2/">Solaris binaries</a></li><li><a href="http://www.explain.com.au/oss/libxml2xslt.html">MacOsX binaries</a></li><li><a href="http://bugzilla.gnome.org/buglist.cgi?product=libxslt">Bug Tracker</a></li><li><a href="http://www.zend.com/php5/articles/php5-xmlphp.php#Heading17">XSLT with PHP</a></li><li><a href="http://www.mod-xslt2.com/">Apache module</a></li><li><a href="http://sourceforge.net/projects/libxml2-pas/">Pascal bindings</a></li><li><a href="http://xsldbg.sourceforge.net/">Xsldbg Debugger</a></li></ul></td></tr></table><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>API Indexes</b></center></td></tr><tr><td bgcolor="#fffacd"><ul><li><a href="APIchunk0.html">Alphabetic</a></li><li><a href="APIconstructors.html">Constructors</a></li><li><a href="APIfunctions.html">Functions/Types</a></li><li><a href="APIfiles.html">Modules</a></li><li><a href="APIsymbols.html">Symbols</a></li></ul></td></tr></table></td></tr></table></td><td valign="top" bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="1" width="100%"><tr><td><table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000"><tr><td><table border="0" cellpadding="3" cellspacing="1" width="100%"><tr><td bgcolor="#fffacd"><p>There is a number of language bindings and wrappers available for
+libxml2,the list below is not exhaustive. Please contact the <a href="http://mail.gnome.org/mailman/listinfo/xml-bindings">xml-bindings at gnome.org</a>(<a href="http://mail.gnome.org/archives/xml-bindings/">archives</a>) inorder to
+get updates to this list or to discuss the specific topic of libxml2or
+libxslt wrappers or bindings:</p><ul><li><a href="http://mail.gnome.org/archives/xml/2001-March/msg00014.html">MattSergeant</a>developped
+    <a href="http://axkit.org/download/">XML::LibXMLand XML::LibXSLT</a>,
+    Perl wrappers for libxml2/libxslt as part of the <a href="http://axkit.com/">AxKit XML application server</a></li>
+  <li><a href="mailto:dkuhlman at cutter.rexx.com">Dave Kuhlman</a>provides
+    andearlier version of the libxml/libxslt <a href="http://www.rexx.com/~dkuhlman">wrappers for Python</a></li>
+  <li>Petr Kozelka provides <a href="http://sourceforge.net/projects/libxml2-pas">Pascal units to
+    gluelibxml2</a>with Kylix, Delphi and other Pascal compilers</li>
+  <li>Wai-Sun "Squidster" Chia provides <a href="http://www.rubycolor.org/arc/redist/">bindings for
+    Ruby</a>andlibxml2 bindings are also available in Ruby through the <a href="http://libgdome-ruby.berlios.de/">libgdome-ruby</a>modulemaintained
+    by Tobias Peters.</li>
+  <li>Steve Ball and contributors maintains <a href="http://tclxml.sourceforge.net/">libxml2 and libxslt bindings
+    forTcl</a></li>
+  <li><a href="mailto:xmlwrapp at pmade.org">Peter Jones</a>maintains
+    C++bindings for libxslt within <a href="http://pmade.org/pjones/software/xmlwrapp/">xmlwrapp</a></li>
+  <li><a href="phillim2 at comcast.net">Mike Phillips</a>provides a moduleusing
+    <a href="http://siasl.dyndns.org/projects/projects.html">libxsltfor
+    PHP</a>.</li>
+  <li><a href="http://savannah.gnu.org/projects/classpathx/">LibxmlJ</a>isan
+    effort to create a 100% JAXP-compatible Java wrapper for libxml2
+    andlibxslt as part of GNU ClasspathX project.</li>
+  <li>Patrick McPhee provides Rexx bindings fof libxml2 and libxslt, look
+    for<a href="http://www.interlog.com/~ptjm/software.html">RexxXML</a>.</li>
+  <li><a href="http://www.satimage.fr/software/en/xml_suite.html">Satimage</a>provides
+    <a href="http://www.satimage.fr/software/en/downloads_osaxen.html">XMLLibosax</a>.
+    This is an osax for Mac OS X with a set of commands toimplement in
+    AppleScript the XML DOM, XPATH and XSLT.</li>
+</ul><p>The libxslt Python module depends on the <a href="http://xmlsoft.org/python.html">libxml2 Python</a>module.</p><p>The distribution includes a set of Python bindings, which are garanteed
+tobe maintained as part of the library in the future, though the
+Pythoninterface have not yet reached the completeness of the C API.</p><p><a href="mailto:stephane.bidoul at softwareag.com">Stéphane
+Bidoul</a>maintains <a href="http://users.skynet.be/sbi/libxml-python/">a
+Windows portof the Python bindings</a>.</p><p>Note to people interested in building bindings, the API is formalized as<a href="libxslt-api.xml">an XML API description file</a>which allows toautomate
+a large part of the Python bindings, this includes functiondescriptions,
+enums, structures, typedefs, etc... The Python script used tobuild the
+bindings is python/generator.py in the source distribution.</p><p>To install the Python bindings there are 2 options:</p><ul><li>If you use an RPM based distribution, simply install the <a href="http://rpmfind.net/linux/rpm2html/search.php?query=libxml2-python">libxml2-pythonRPM</a>and
+    the <a href="http://rpmfind.net/linux/rpm2html/search.php?query=libxslt-python">libxslt-pythonRPM</a>.</li>
+  <li>Otherwise use the <a href="ftp://xmlsoft.org/libxml2/python/">libxml2-pythonmodule
+    distribution</a>corresponding to your installed version oflibxml2 and
+    libxslt. Note that to install it you will need both libxml2and libxslt
+    installed and run "python setup.py build install" in themodule tree.</li>
+</ul><p>The distribution includes a set of examples and regression tests for
+thepython bindings in the <code>python/tests</code>directory. Here are
+someexcepts from those tests:</p><h3>basic.py:</h3><p>This is a basic test of XSLT interfaces: loading a stylesheet and
+adocument, transforming the document and saving the result.</p><pre>import libxml2
 import libxslt
 
 styledoc = libxml2.parseFile("test.xsl")
@@ -67,28 +63,28 @@
 style.saveResultToFilename("foo", result, 0)
 style.freeStylesheet()
 doc.freeDoc()
-result.freeDoc()</pre><p>The Python module is called libxslt, you will also need the libxml2 module
-for the operations on XML trees. Let's have a look at the objects manipulated
-in that example and how is the processing done:</p><ul><li><code>styledoc</code> : is a libxml2 document tree. It is obtained by
-    parsing the XML file "test.xsl" containing the stylesheet.</li>
-  <li><code>style</code> : this is a precompiled stylesheet ready to be used
-    by the following transformations (note the plural form, multiple
-    transformations can resuse the same stylesheet).</li>
-  <li><code>doc</code> : this is the document to apply the transformation to.
-    In this case it is simply generated by parsing it from a file but any
-    other processing is possible as long as one get a libxml2 Doc. Note that
-    HTML tree are suitable for XSLT processing in libxslt. This is actually
-    how this page is generated !</li>
-  <li><code>result</code> : this is a document generated by applying the
-    stylesheet to the document. Note that some of the stylesheet informations
-    may be related to the serialization of that document and as in this
-    example a specific saveResultToFilename() method of the stylesheet should
-    be used to save it to a file (in that case to "foo").</li>
-</ul><p>Also note the need to explicitely deallocate documents with freeDoc()
-except for the stylesheet document which is freed when its compiled form is
-garbage collected.</p><h3>extfunc.py:</h3><p>This one is a far more complex test. It shows how to modify the behaviour
-of an XSLT transformation by passing parameters and how to extend the XSLT
-engine with functions defined in python:</p><pre>import libxml2
+result.freeDoc()</pre><p>The Python module is called libxslt, you will also need the libxml2
+modulefor the operations on XML trees. Let's have a look at the objects
+manipulatedin that example and how is the processing done:</p><ul><li><code>styledoc</code>: is a libxml2 document tree. It is obtained
+    byparsing the XML file "test.xsl" containing the stylesheet.</li>
+  <li><code>style</code>: this is a precompiled stylesheet ready to be usedby
+    the following transformations (note the plural form,
+    multipletransformations can resuse the same stylesheet).</li>
+  <li><code>doc</code>: this is the document to apply the transformation
+    to.In this case it is simply generated by parsing it from a file but
+    anyother processing is possible as long as one get a libxml2 Doc. Note
+    thatHTML tree are suitable for XSLT processing in libxslt. This is
+    actuallyhow this page is generated !</li>
+  <li><code>result</code>: this is a document generated by applying
+    thestylesheet to the document. Note that some of the stylesheet
+    informationsmay be related to the serialization of that document and as
+    in thisexample a specific saveResultToFilename() method of the stylesheet
+    shouldbe used to save it to a file (in that case to "foo").</li>
+</ul><p>Also note the need to explicitely deallocate documents with
+freeDoc()except for the stylesheet document which is freed when its compiled
+form isgarbage collected.</p><h3>extfunc.py:</h3><p>This one is a far more complex test. It shows how to modify the
+behaviourof an XSLT transformation by passing parameters and how to extend
+the XSLTengine with functions defined in python:</p><pre>import libxml2
 import libxslt
 import string
 
@@ -109,20 +105,20 @@
 
     return string.upper(str)
 
-libxslt.registerExtModuleFunction("foo", "http://example.com/foo", f)</pre><p>This code defines and register an extension function. Note that the
-function can be bound to any name (foo) and how the binding is also
-associated to a namespace name "http://example.com/foo". From an XSLT point
-of view the function just returns an upper case version of the string passed
-as a parameter. But the first part of the function also read some contextual
-information from the current XSLT processing environement, in that case it
-looks for the current insertion node in the resulting output (either the
-resulting document or the Result Value Tree being generated), and saves it to
-a global variable for checking that the access actually worked.</p><p>For more informations on the xpathParserContext and transformContext
-objects check the <a href="internals.html">libray internals description</a>.
-The pctxt is actually an object from a class derived from the
-libxml2.xpathParserContext() with just a couple more properties including the
-possibility to look up the XSLT transformation context from the XPath
-context.</p><pre>styledoc = libxml2.parseDoc("""
+libxslt.registerExtModuleFunction("foo", "http://example.com/foo", f)</pre><p>This code defines and register an extension function. Note that
+thefunction can be bound to any name (foo) and how the binding is
+alsoassociated to a namespace name "http://example.com/foo". From an XSLT
+pointof view the function just returns an upper case version of the string
+passedas a parameter. But the first part of the function also read some
+contextualinformation from the current XSLT processing environement, in that
+case itlooks for the current insertion node in the resulting output (either
+theresulting document or the Result Value Tree being generated), and saves it
+toa global variable for checking that the access actually worked.</p><p>For more informations on the xpathParserContext and
+transformContextobjects check the <a href="internals.html">libray internals
+description</a>.The pctxt is actually an object from a class derived from
+thelibxml2.xpathParserContext() with just a couple more properties including
+thepossibility to look up the XSLT transformation context from the
+XPathcontext.</p><pre>styledoc = libxml2.parseDoc("""
 &lt;xsl:stylesheet version='1.0'
   xmlns:xsl='http://www.w3.org/1999/XSL/Transform'
   xmlns:foo='http://example.com/foo'
@@ -133,21 +129,21 @@
     &lt;article&gt;&lt;xsl:value-of select='foo:foo($bar)'/&gt;&lt;/article&gt;
   &lt;/xsl:template&gt;
 &lt;/xsl:stylesheet&gt;
-""")</pre><p>Here is a simple example of how to read an XML document from a python
-string with libxml2. Note how this stylesheet:</p><ul><li>Uses a global parameter <code>bar</code></li>
+""")</pre><p>Here is a simple example of how to read an XML document from a
+pythonstring with libxml2. Note how this stylesheet:</p><ul><li>Uses a global parameter <code>bar</code></li>
   <li>Reference the extension function f</li>
-  <li>how the Namespace name "http://example.com/foo" has to be bound to a
-    prefix</li>
+  <li>how the Namespace name "http://example.com/foo" has to be bound to
+    aprefix</li>
   <li>how that prefix is excluded from the output</li>
   <li>how the function is called from the select</li>
 </ul><pre>style = libxslt.parseStylesheetDoc(styledoc)
 doc = libxml2.parseDoc("&lt;doc/&gt;")
 result = style.applyStylesheet(doc, { "bar": "'success'" })
 style.freeStylesheet()
-doc.freeDoc()</pre><p>that part is identical, to the basic example except that the
-transformation is passed a dictionnary of parameters. Note that the string
-passed "success" had to be quoted, otherwise it is interpreted as an XPath
-query for the childs of root named "success".</p><pre>root = result.children
+doc.freeDoc()</pre><p>that part is identical, to the basic example except that thetransformation
+is passed a dictionnary of parameters. Note that the stringpassed "success"
+had to be quoted, otherwise it is interpreted as an XPathquery for the childs
+of root named "success".</p><pre>root = result.children
 if root.name != "article":
     print "Unexpected root node name"
     sys.exit(1)
@@ -158,12 +154,14 @@
     print "The function callback failed to access its context"
     sys.exit(1)
 
-result.freeDoc()</pre><p>That part just verifies that the transformation worked, that the parameter
-got properly passed to the engine, that the function f() got called and that
-it properly accessed the context to find the name of the insertion node.</p><h3>pyxsltproc.py:</h3><p>this module is a bit too long to be described there but it is basically a
-rewrite of the xsltproc command line interface of libxslt in Python. It
-provides nearly all the functionalities of xsltproc and can be used as a base
-module to write Python customized XSLT processors. One of the thing to notice
-are:</p><pre>libxml2.lineNumbersDefault(1)
-libxml2.substituteEntitiesDefault(1)</pre><p>those two calls in the main() function are needed to force the libxml2
-processor to generate DOM trees compliant with the XPath data model.</p><p><a href="bugs.html">Daniel Veillard</a></p></td></tr></table></td></tr></table></td></tr></table></td></tr></table></td></tr></table></body></html>
+result.freeDoc()</pre><p>That part just verifies that the transformation worked, that the
+parametergot properly passed to the engine, that the function f() got called
+and thatit properly accessed the context to find the name of the insertion
+node.</p><h3>pyxsltproc.py:</h3><p>this module is a bit too long to be described there but it is basically
+arewrite of the xsltproc command line interface of libxslt in Python.
+Itprovides nearly all the functionalities of xsltproc and can be used as a
+basemodule to write Python customized XSLT processors. One of the thing to
+noticeare:</p><pre>libxml2.lineNumbersDefault(1)
+libxml2.substituteEntitiesDefault(1)</pre><p>those two calls in the main() function are needed to force the
+libxml2processor to generate DOM trees compliant with the XPath data
+model.</p><p><a href="bugs.html">Daniel Veillard</a></p></td></tr></table></td></tr></table></td></tr></table></td></tr></table></td></tr></table></body></html>

Modified: packages/libxslt/trunk/doc/xslt.html
===================================================================
--- packages/libxslt/trunk/doc/xslt.html	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/doc/xslt.html	2006-06-08 22:29:07 UTC (rev 565)
@@ -3,8 +3,8 @@
 <html>
 <head>
   <title>The XSLT C library for Gnome</title>
-  <meta name="GENERATOR" content="amaya 8.5, see http://www.w3.org/Amaya/">
-  <meta http-equiv="Content-Type" content="text/html">
+  <meta name="GENERATOR" content="amaya 8.8.5, see http://www.w3.org/Amaya/">
+  <meta http-equiv="content-type" content="text/html">
 </head>
 
 <body bgcolor="#ffffff">
@@ -12,22 +12,24 @@
 
 <h1 style="text-align: center">libxslt</h1>
 
-<p>Libxslt is the <a href="http://www.w3.org/TR/xslt">XSLT</a> C library
-developed for the Gnome project. XSLT itself is a an XML language to define
-transformation for XML. Libxslt is based on <a
-href="http://xmlsoft.org/">libxml2</a> the XML C library developed for the
-Gnome project. It also implements most of the <a
-href="http://www.exslt.org/">EXSLT</a> set of processor-portable extensions
-functions and some of Saxon's evaluate and expressions extensions.</p>
+<p>Libxslt is the <a href="http://www.w3.org/TR/xslt">XSLT</a>C
+librarydeveloped for the Gnome project. XSLT itself is a an XML language to
+definetransformation for XML. Libxslt is based on <a
+href="http://xmlsoft.org/">libxml2</a>the XML C library developed for
+theGnome project. It also implements most of the <a
+href="http://www.exslt.org/">EXSLT</a>set of processor-portable
+extensionsfunctions and some of Saxon's evaluate and expressions
+extensions.</p>
 
-<p>People can either embed the library in their application or use xsltproc
-the command line processing tool. This library is free software and can be
-reused in commercial applications (see the <a href="#Introducti">intro</a>)</p>
+<p>People can either embed the library in their application or use
+xsltprocthe command line processing tool. This library is free software and
+can bereused in commercial applications (see the <a
+href="intro.html">intro</a>)</p>
 
 <p>External documents:</p>
 <ul>
-  <li>John Fleck wrote <a href="tutorial/libxslttutorial.html">a tutorial for
-    libxslt</a></li>
+  <li>John Fleck wrote <a href="tutorial/libxslttutorial.html">a tutorial
+    forlibxslt</a></li>
   <li><a href="xsltproc.html">xsltproc user manual</a></li>
   <li><a href="http://xmlsoft.org/">the libxml documentation</a></li>
 </ul>
@@ -38,399 +40,410 @@
 
 <h2><a name="Introducti">Introduction</a></h2>
 
-<p>This document describes <a href="http://xmlsoft.org/XSLT/">libxslt</a>,
-the <a href="http://www.w3.org/TR/xslt">XSLT</a> C library developed for the
-<a href="http://www.gnome.org/">Gnome</a> project.</p>
+<p>This document describes <a href="http://xmlsoft.org/XSLT/">libxslt</a>,the
+<a href="http://www.w3.org/TR/xslt">XSLT</a>C library developed for the<a
+href="http://www.gnome.org/">Gnome</a>project.</p>
 
 <p>Here are some key points about libxslt:</p>
 <ul>
   <li>Libxslt is a C implementation</li>
-  <li>Libxslt is based on libxml for XML parsing, tree manipulation and XPath
-    support</li>
-  <li>It is written in plain C, making as few assumptions as possible, and
-    sticking closely to ANSI C/POSIX for easy embedding. Should works on
-    Linux/Unix/Windows.</li>
+  <li>Libxslt is based on libxml for XML parsing, tree manipulation and
+    XPathsupport</li>
+  <li>It is written in plain C, making as few assumptions as possible,
+    andsticking closely to ANSI C/POSIX for easy embedding. Should works
+    onLinux/Unix/Windows.</li>
   <li>This library is released under the <a
-    href="http://www.opensource.org/licenses/mit-license.html">MIT
-  Licence</a></li>
-  <li>Though not designed primarily with performances in mind, libxslt seems
-    to be a relatively fast processor.</li>
+    href="http://www.opensource.org/licenses/mit-license.html">MITLicence</a></li>
+  <li>Though not designed primarily with performances in mind, libxslt
+    seemsto be a relatively fast processor.</li>
 </ul>
 
 <h2><a name="Documentat">Documentation</a></h2>
 
 <p>There are some on-line resources about using libxslt:</p>
 <ol>
-  <li>Check the <a href="html/libxslt-lib.html#LIBXSLT-LIB">API
-    documentation</a> automatically extracted from code comments (using the
-    program apibuild.py, developed for libxml, together with the xsl script
-    'newapi.xsl' and the libxslt xsltproc program).</li>
-  <li>Look at the <a href="http://mail.gnome.org/archives/xslt/">mailing-list
-    archive</a>.</li>
-  <li>Of course since libxslt is based on libxml, it's a good idea to at
-    least read <a href="http://xmlsoft.org/">libxml description</a></li>
+  <li>Check the <a
+    href="html/libxslt-lib.html#LIBXSLT-LIB">APIdocumentation</a>automatically
+    extracted from code comments (using theprogram apibuild.py, developed for
+    libxml, together with the xsl script'newapi.xsl' and the libxslt xsltproc
+    program).</li>
+  <li>Look at the <a
+    href="http://mail.gnome.org/archives/xslt/">mailing-listarchive</a>.</li>
+  <li>Of course since libxslt is based on libxml, it's a good idea to atleast
+    read <a href="http://xmlsoft.org/">libxml description</a></li>
 </ol>
 
 <h2><a name="Reporting">Reporting bugs and getting help</a></h2>
 
-<p>If you need help with the XSLT language itself, here are a number of
-useful resources:</p>
+<p>If you need help with the XSLT language itself, here are a number ofuseful
+resources:</p>
 <ul>
   <li>I strongly suggest to subscribe to <a
     href="http://www.mulberrytech.com/xsl/xsl-list">XSL-list</a>, check <a
-    href="http://www.biglist.com/lists/xsl-list/archives/">the XSL-list
-    archives</a></li>
+    href="http://www.biglist.com/lists/xsl-list/archives/">the
+    XSL-listarchives</a></li>
   <li>The <a href="http://www.dpawson.co.uk/xsl/xslfaq.html">XSL FAQ</a>.</li>
   <li>The <a
-    href="http://www.nwalsh.com/docs/tutorials/xsl/xsl/slides.html">tutorial</a>
-    written by Paul Grosso and Norman Walsh is a very good on-line
-    introdution to the language.</li>
+    href="http://www.nwalsh.com/docs/tutorials/xsl/xsl/slides.html">tutorial</a>written
+    by Paul Grosso and Norman Walsh is a very good on-lineintrodution to the
+    language.</li>
   <li>The <a
-    href="http://www.zvon.org/xxl/XSLTutorial/Books/Book1/index.html">only
-    Zvon XSLT tutorial</a> details a lot of constructs with examples.</li>
-  <li><a href="http://www.jenitennison.com/xslt/index.html">Jeni Tennison's
-    XSLT</a> pages provide links to a lot of answers</li>
-  <li>the <a href="http://incrementaldevelopment.com/xsltrick/">Gallery of
-    XSLT Tricks</a> provides non-standard use case of XSLT</li>
-  <li>And I suggest to buy Michael Kay "XSLT Programmer's Reference" book
-    published by <a href="http://www.wrox.com/">Wrox</a> if you plan to work
-    seriously with XSLT in the future.</li>
+    href="http://www.zvon.org/xxl/XSLTutorial/Books/Book1/index.html">onlyZvon
+    XSLT tutorial</a>details a lot of constructs with examples.</li>
+  <li><a href="http://www.jenitennison.com/xslt/index.html">Jeni
+    Tennison'sXSLT</a>pages provide links to a lot of answers</li>
+  <li>the <a href="http://incrementaldevelopment.com/xsltrick/">Gallery
+    ofXSLT Tricks</a>provides non-standard use case of XSLT</li>
+  <li>And I suggest to buy Michael Kay "XSLT Programmer's Reference"
+    bookpublished by <a href="http://www.wrox.com/">Wrox</a>if you plan to
+    workseriously with XSLT in the future.</li>
 </ul>
 
-<p>Well, bugs or missing features are always possible, and I will make a
-point of fixing them in a timely fashion. The best way to report a bug is to
-use the <a
-href="http://bugzilla.gnome.org/enter_bug.cgi?product=libxslt">Gnome bug
-tracking database</a> (make sure to use the "libxslt" module name). Before
-filing a bug, check the <a
-href="http://bugzilla.gnome.org/buglist.cgi?product=libxslt">list of existing
-libxslt bugs</a> to make sure it hasn't already been filed. I look at reports
-there regularly and it's good to have a reminder when a bug is still open. Be
-sure to specify that the bug is for the package libxslt.</p>
+<p>Well, bugs or missing features are always possible, and I will make apoint
+of fixing them in a timely fashion. The best way to report a bug is touse the
+<a href="http://bugzilla.gnome.org/enter_bug.cgi?product=libxslt">Gnome
+bugtracking database</a>(make sure to use the "libxslt" module name).
+Beforefiling a bug, check the <a
+href="http://bugzilla.gnome.org/buglist.cgi?product=libxslt">list of
+existinglibxslt bugs</a>to make sure it hasn't already been filed. I look at
+reportsthere regularly and it's good to have a reminder when a bug is still
+open. Besure to specify that the bug is for the package libxslt.</p>
 
-<p>For small problems you can try to get help on IRC, the #xml channel on
-irc.gnome.org (port 6667) usually have a few person subscribed which may help
-(but there is no garantee and if a real issue is raised it should go on the
-mailing-list for archival).</p>
+<p>For small problems you can try to get help on IRC, the #xml channel
+onirc.gnome.org (port 6667) usually have a few person subscribed which may
+help(but there is no garantee and if a real issue is raised it should go on
+themailing-list for archival).</p>
 
 <p>There is also a mailing-list <a
-href="mailto:xslt at gnome.org">xslt at gnome.org</a> for libxslt, with an <a
-href="http://mail.gnome.org/archives/xslt/">on-line archive</a>. To subscribe
-to this list, please visit the <a
-href="http://mail.gnome.org/mailman/listinfo/xslt">associated Web</a> page
-and follow the instructions.</p>
+href="mailto:xslt at gnome.org">xslt at gnome.org</a>for libxslt, with an <a
+href="http://mail.gnome.org/archives/xslt/">on-line archive</a>. To
+subscribeto this list, please visit the <a
+href="http://mail.gnome.org/mailman/listinfo/xslt">associated Web</a>pageand
+follow the instructions.</p>
 
 <p>Alternatively, you can just send the bug to the <a
-href="mailto:xslt at gnome.org">xslt at gnome.org</a> list, if it's really libxslt
-related I will approve it.. Please do not send me mail directly especially
-for portability problem, it makes things really harder to track and in some
-cases I'm not the best person to answer a given question, ask the list
-instead. <strong>Do not send code, I won't debug it</strong> (but patches are
-really appreciated!).</p>
+href="mailto:xslt at gnome.org">xslt at gnome.org</a>list, if it's really
+libxsltrelated I will approve it.. Please do not send me mail directly
+especiallyfor portability problem, it makes things really harder to track and
+in somecases I'm not the best person to answer a given question, ask the
+listinstead. <strong>Do not send code, I won't debug it</strong>(but patches
+arereally appreciated!).</p>
 
-<p>Please note that with the current amount of virus and SPAM, sending mail
-to the list without being subscribed won't work. There is *far too many
-bounces* (in the order of a thousand a day !) I cannot approve them manually
-anymore. If your mail to the list bounced waiting for administrator approval,
-it is LOST ! Repost it and fix the problem triggering the error. Also please
-note that <span style="color: #FF0000; background-color: #FFFFFF">emails with
-a legal warning asking to not copy or redistribute freely the informations
-they contain</span> are <strong>NOT</strong> acceptable for the mailing-list,
-such mail will as much as possible be discarded automatically, and are less
-likely to be answered if they made it to the list, <strong>DO NOT</strong>
-post to the list from an email address where such legal requirements are
-automatically added, get private paying support if you can't share
-informations.</p>
+<p>Please note that with the current amount of virus and SPAM, sending mailto
+the list without being subscribed won't work. There is *far too manybounces*
+(in the order of a thousand a day !) I cannot approve them manuallyanymore.
+If your mail to the list bounced waiting for administrator approval,it is
+LOST ! Repost it and fix the problem triggering the error. Also pleasenote
+that <span style="color: #FF0000; background-color: #FFFFFF">emails witha
+legal warning asking to not copy or redistribute freely the informationsthey
+contain</span>are <strong>NOT</strong>acceptable for the mailing-list,such
+mail will as much as possible be discarded automatically, and are lesslikely
+to be answered if they made it to the list, <strong>DO NOT</strong>post to
+the list from an email address where such legal requirements areautomatically
+added, get private paying support if you can't shareinformations.</p>
 
-<p>Check the following too <span style="color: #E50000">before
-posting</span>:</p>
+<p>Check the following too <span
+style="color: #E50000">beforeposting</span>:</p>
 <ul>
-  <li><a href="search.php">use the search engine</a> to get informations
-    related to your problem.</li>
-  <li>make sure you are <a href="ftp://xmlsoft.org/libxslt/">using a recent
-    version</a>, and that the problem still shows up in those</li>
-  <li>check the <a href="http://mail.gnome.org/archives/xslt/">list
-    archives</a> to see if the problem was reported already, in this case
-    there is probably a fix available, similarly check the <a
-    href="http://bugzilla.gnome.org/buglist.cgi?product=libxslt">registered
-    open bugs</a></li>
-  <li>make sure you can reproduce the bug with xsltproc, a very useful thing
-    to do is run the transformation with -v argument and redirect the
-    standard error to a file, then search in this file for the transformation
-    logs just preceding the possible problem</li>
-  <li>Please send the command showing the error as well as the input and
-    stylesheet (as an attachment)</li>
+  <li><a href="search.php">use the search engine</a>to get
+    informationsrelated to your problem.</li>
+  <li>make sure you are <a href="ftp://xmlsoft.org/libxslt/">using a
+    recentversion</a>, and that the problem still shows up in those</li>
+  <li>check the <a
+    href="http://mail.gnome.org/archives/xslt/">listarchives</a>to see if the
+    problem was reported already, in this casethere is probably a fix
+    available, similarly check the <a
+    href="http://bugzilla.gnome.org/buglist.cgi?product=libxslt">registeredopen
+    bugs</a></li>
+  <li>make sure you can reproduce the bug with xsltproc, a very useful
+    thingto do is run the transformation with -v argument and redirect
+    thestandard error to a file, then search in this file for the
+    transformationlogs just preceding the possible problem</li>
+  <li>Please send the command showing the error as well as the input
+    andstylesheet (as an attachment)</li>
 </ul>
 
 <p>Then send the bug with associated informations to reproduce it to the <a
-href="mailto:xslt at gnome.org">xslt at gnome.org</a> list; if it's really libxslt
-related I will approve it. Please do not send mail to me directly, it makes
-things really hard to track and in some cases I am not the best person to
-answer a given question, ask on the list.</p>
+href="mailto:xslt at gnome.org">xslt at gnome.org</a>list; if it's really
+libxsltrelated I will approve it. Please do not send mail to me directly, it
+makesthings really hard to track and in some cases I am not the best person
+toanswer a given question, ask on the list.</p>
 
 <p>To <span style="color: #E50000">be really clear about support</span>:</p>
 <ul>
-  <li>Support or help <span style="color: #E50000">request MUST be sent to
-    the list or on bugzilla</span> in case of problems, so that the Question
-    and Answers can be shared publicly. Failing to do so carries the implicit
-    message "I want free support but I don't want to share the benefits with
-    others" and is not welcome. I will automatically Carbon-Copy the
-    xslt at gnome.org mailing list for any technical reply made about libxml2 or
-    libxslt.</li>
-  <li>There is <span style="color: #E50000">no garantee for support</span>,
-    if your question remains unanswered after a week, repost it, making sure
-    you gave all the detail needed and the informations requested.</li>
-  <li>Failing to provide informations as requested or double checking first
-    for prior feedback also carries the implicit message "the time of the
-    library maintainers is less valuable than my time" and might not be
-    welcome.</li>
+  <li>Support or help <span style="color: #E50000">request MUST be sent tothe
+    list or on bugzilla</span>in case of problems, so that the Questionand
+    Answers can be shared publicly. Failing to do so carries the
+    implicitmessage "I want free support but I don't want to share the
+    benefits withothers" and is not welcome. I will automatically Carbon-Copy
+    thexslt at gnome.org mailing list for any technical reply made about libxml2
+    orlibxslt.</li>
+  <li>There is <span style="color: #E50000">no garantee for support</span>,if
+    your question remains unanswered after a week, repost it, making sureyou
+    gave all the detail needed and the informations requested.</li>
+  <li>Failing to provide informations as requested or double checking
+    firstfor prior feedback also carries the implicit message "the time of
+    thelibrary maintainers is less valuable than my time" and might not
+    bewelcome.</li>
 </ul>
 
-<p>Of course, bugs reports with a suggested patch for fixing them will
-probably be processed faster.</p>
+<p>Of course, bugs reports with a suggested patch for fixing them
+willprobably be processed faster.</p>
 
 <p>If you're looking for help, a quick look at <a
-href="http://mail.gnome.org/archives/xslt/">the list archive</a> may actually
-provide the answer, I usually send source samples when answering libxslt
-usage questions. The <a
-href="html/libxslt-lib.html#LIBXSLT-LIB">auto-generated documentation</a> is
-not as polished as I would like (I need to learn more about Docbook), but
-it's a good starting point.</p>
+href="http://mail.gnome.org/archives/xslt/">the list archive</a>may
+actuallyprovide the answer, I usually send source samples when answering
+libxsltusage questions. The <a
+href="html/libxslt-lib.html#LIBXSLT-LIB">auto-generated
+documentation</a>isnot as polished as I would like (I need to learn more
+about Docbook), butit's a good starting point.</p>
 
 <h2><a name="help">How to help</a></h2>
 
-<p>You can help the project in various ways, the best thing to do first is to
-subscribe to the mailing-list as explained before, check the <a
+<p>You can help the project in various ways, the best thing to do first is
+tosubscribe to the mailing-list as explained before, check the <a
 href="http://mail.gnome.org/archives/xslt/">archives </a>and the <a
-href="http://bugzilla.gnome.org/buglist.cgi?product=libxslt">Gnome bug
-database:</a>:</p>
+href="http://bugzilla.gnome.org/buglist.cgi?product=libxslt">Gnome
+bugdatabase:</a>:</p>
 <ol>
   <li>provide patches when you find problems</li>
-  <li>provide the diffs when you port libxslt to a new platform. They may not
-    be integrated in all cases but help pinpointing portability problems
-  and</li>
-  <li>provide documentation fixes (either as patches to the code comments or
-    as HTML diffs).</li>
+  <li>provide the diffs when you port libxslt to a new platform. They may
+    notbe integrated in all cases but help pinpointing portability
+  problemsand</li>
+  <li>provide documentation fixes (either as patches to the code comments
+    oras HTML diffs).</li>
   <li>provide new documentations pieces (translations, examples, etc ...)</li>
   <li>Check the TODO file and try to close one of the items</li>
-  <li>take one of the points raised in the archive or the bug database and
-    provide a fix. <a href="mailto:daniel at veillard.com">Get in touch with me
-    </a>before to avoid synchronization problems and check that the suggested
-    fix will fit in nicely :-)</li>
+  <li>take one of the points raised in the archive or the bug database
+    andprovide a fix. <a href="mailto:daniel at veillard.com">Get in touch with
+    me</a>before to avoid synchronization problems and check that the
+    suggestedfix will fit in nicely :-)</li>
 </ol>
 
 <h2><a name="Downloads">Downloads</a></h2>
 
 <p>The latest versions of libxslt can be found on the <a
-href="ftp://xmlsoft.org/libxslt/">xmlsoft.org</a> server and on mirrors (<a
+href="ftp://xmlsoft.org/libxslt/">xmlsoft.org</a>server and on mirrors (<a
 href="ftp://fr.rpmfind.net/pub/libxml/">France</a>) or on the <a
-href="ftp://ftp.gnome.org/pub/GNOME/MIRRORS.html">Gnome FTP server</a> as a
-<a href="ftp://ftp.gnome.org/pub/GNOME/sources/libxslt/1.1/">source
-archive</a>, Antonin Sprinzl also provides <a
-href="ftp://gd.tuwien.ac.at/pub/libxml/">a mirror in Austria</a>. (NOTE that
-you need the <a href="http://rpmfind.net/linux/RPM/libxml2.html">libxml2</a>,
-<a href="http://rpmfind.net/linux/RPM/libxml2-devel.html">libxml2-devel</a>,
-<a href="http://rpmfind.net/linux/RPM/libxslt.html">libxslt</a> and <a
-href="http://rpmfind.net/linux/RPM/libxslt-devel.html">libxslt-devel</a>
-packages installed to compile applications using libxslt.) <a
-href="mailto:igor at zlatkovic.com">Igor Zlatkovic</a> is now the maintainer of
-the Windows port, <a
-href="http://www.zlatkovic.com/projects/libxml/index.html">he provides
-binaries</a>. <a href="mailto:Gary.Pennington at sun.com">Gary Pennington</a>
-provides <a href="http://garypennington.net/libxml2/">Solaris binaries</a>.
-<a href="mailto:Steve.Ball at explain.com.au">Steve Ball</a> provides <a
-href="http://www.explain.com.au/oss/libxml2xslt.html">Mac Os X
-binaries</a>.</p>
+href="ftp://ftp.gnome.org/pub/GNOME/MIRRORS.html">Gnome FTP server</a>as a<a
+href="ftp://ftp.gnome.org/pub/GNOME/sources/libxslt/1.1/">sourcearchive</a>,
+Antonin Sprinzl also provides <a href="ftp://gd.tuwien.ac.at/pub/libxml/">a
+mirror in Austria</a>. (NOTE thatyou need the <a
+href="http://rpmfind.net/linux/RPM/libxml2.html">libxml2</a>,<a
+href="http://rpmfind.net/linux/RPM/libxml2-devel.html">libxml2-devel</a>,<a
+href="http://rpmfind.net/linux/RPM/libxslt.html">libxslt</a>and <a
+href="http://rpmfind.net/linux/RPM/libxslt-devel.html">libxslt-devel</a>packages
+installed to compile applications using libxslt.) <a
+href="mailto:igor at zlatkovic.com">Igor Zlatkovic</a>is now the maintainer
+ofthe Windows port, <a
+href="http://www.zlatkovic.com/projects/libxml/index.html">he
+providesbinaries</a>. <a href="mailto:Gary.Pennington at sun.com">Gary
+Pennington</a>provides <a href="http://garypennington.net/libxml2/">Solaris
+binaries</a>.<a href="mailto:Steve.Ball at explain.com.au">Steve
+Ball</a>provides <a href="http://www.explain.com.au/oss/libxml2xslt.html">Mac
+Os Xbinaries</a>.</p>
 
 <p><a name="Contribs">Contribs:</a></p>
 
-<p>I do accept external contributions, especially if compiling on another
-platform, get in touch with me to upload the package. I will keep them in the
-<a href="ftp://xmlsoft.org/libxml2/contribs/">contrib directory</a></p>
+<p>I do accept external contributions, especially if compiling on
+anotherplatform, get in touch with me to upload the package. I will keep them
+in the<a href="ftp://xmlsoft.org/libxml2/contribs/">contrib directory</a></p>
 
 <p>Libxslt is also available from CVS:</p>
 <ul>
-  <li><p>The <a href="http://cvs.gnome.org/viewcvs/libxslt/">Gnome CVS
-    base</a>. Check the <a
-    href="http://developer.gnome.org/tools/cvs.html">Gnome CVS Tools</a>
-    page; the CVS module is <b>libxslt</b>.</p>
+  <li><p>The <a href="http://cvs.gnome.org/viewcvs/libxslt/">Gnome
+    CVSbase</a>. Check the <a
+    href="http://developer.gnome.org/tools/cvs.html">Gnome CVS Tools</a>page;
+    the CVS module is <b>libxslt</b>.</p>
   </li>
-  <li><a href="ftp://xmlsoft.org/libxml2/libxslt-cvs-snapshot.tar.gz">snapshots from
-    CVS</a> updated every hour are also provided</li>
+  <li><a
+    href="ftp://xmlsoft.org/libxml2/libxslt-cvs-snapshot.tar.gz">snapshots
+    fromCVS</a>updated every hour are also provided</li>
 </ul>
 
 <h2><a name="FAQ">FAQ</a></h2>
 <ol>
   <li><em>Troubles compiling or linking programs using libxslt</em>
-    <p>Usually the problem comes from the fact that the compiler doesn't get
-    the right compilation or linking flags. There is a small shell script
-    <code>xslt-config</code> which is installed as part of libxslt usual
-    install process which provides those flags. Use</p>
+    <p>Usually the problem comes from the fact that the compiler doesn't
+    getthe right compilation or linking flags. There is a small shell
+    script<code>xslt-config</code>which is installed as part of libxslt
+    usualinstall process which provides those flags. Use</p>
     <p><code>xslt-config --cflags</code></p>
     <p>to get the compilation flags and</p>
     <p><code>xslt-config --libs</code></p>
-    <p>to get the linker flags. Usually this is done directly from the
-    Makefile as:</p>
+    <p>to get the linker flags. Usually this is done directly from
+    theMakefile as:</p>
     <p><code>CFLAGS=`xslt-config --cflags`</code></p>
     <p><code>LIBS=`xslt-config --libs`</code></p>
-    <p>Note also that if you use the EXSLT extensions from the program then
-    you should prepend <code>-lexslt</code> to the LIBS options</p>
+    <p>Note also that if you use the EXSLT extensions from the program
+    thenyou should prepend <code>-lexslt</code>to the LIBS options</p>
   </li>
   <li><em>passing parameters on the xsltproc command line doesn't work</em>
     <p><em>xsltproc --param test alpha foo.xsl foo.xml</em></p>
     <p><em>the param does not get passed and ends up as ""</em></p>
     <p>In a nutshell do a double escaping at the shell prompt:</p>
     <p>xsltproc --param test "'alpha'" foo.xsl foo.xml</p>
-    <p>i.e. the string value is surrounded by " and ' then terminated by '
-    and ". Libxslt interpret the parameter values as XPath expressions, so
-    the string -&gt;<code>alpha</code>&lt;- is intepreted as the node set
-    matching this string. You really want -&gt;<code>'alpha'</code>&lt;- to
-    be passed to the processor. And to allow this you need to escape the
-    quotes at the shell level using -&gt;<code>"'alpha'"</code>&lt;- .</p>
+    <p>i.e. the string value is surrounded by " and ' then terminated by 'and
+    ". Libxslt interpret the parameter values as XPath expressions, sothe
+    string -&gt;<code>alpha</code>&lt;- is intepreted as the node setmatching
+    this string. You really want -&gt;<code>'alpha'</code>&lt;- tobe passed
+    to the processor. And to allow this you need to escape thequotes at the
+    shell level using -&gt;<code>"'alpha'"</code>&lt;- .</p>
     <p>or use</p>
     <p>xsltproc --stringparam test alpha foo.xsl foo.xml</p>
   </li>
   <li><em>Is there C++ bindings ?</em>
     <p>Yes for example <a
-    href="http://pmade.org/pjones/software/xmlwrapp/">xmlwrapp</a> , see <a
+    href="http://pmade.org/pjones/software/xmlwrapp/">xmlwrapp</a>, see <a
     href="python.html">the related pages about bindings</a></p>
   </li>
 </ol>
 
 <h2><a name="News">News</a></h2>
 
-<p>The <a href="ChangeLog.html">change log</a> describes the recents commits
-to the <a href="http://cvs.gnome.org/viewcvs/libxslt/">CVS</a> code base.</p>
+<p>The <a href="ChangeLog.html">change log</a>describes the recents commitsto
+the <a href="http://cvs.gnome.org/viewcvs/libxslt/">CVS</a>code base.</p>
 
 <p>Those are the public releases made:</p>
 
+<h3>1.1.17: Jun 6 2006</h3>
+<ul>
+  <li>portability fixes: python detection</li>
+  <li>bug fixes: some regression tests, attribute/namespaces output (Kasimier
+    Buchcik), problem in mixed xsl:value-of and xsl:text uses (Kasimier)</li>
+  <li>improvements: internal refactoring (Kasimier Buchcik), use of the XPath
+    object cache in libxml2-2.6.25 (Kasimier)</li>
+</ul>
+
 <h3>1.1.16: May 01 2006</h3>
 <ul>
-  <li>portability fixes: EXSLT date/time on Solaris and IRIX (Albert Chin),
-      HP-UX  build (Albert Chin), 
-  <li>build fixes: Python detection(Joseph Sacco), plugin configurei
-      (Joel Reed)</li>
-  <li>bug fixes: pattern compilation fix(William Brack), EXSLT date/time
-      fix (Thomas Broyer), EXSLT function bug, potential loop on variable
-      eval, startup race (Christopher Palmer), debug statement left in python
-      (Nic Ferrier), various cleanup based on Coverity reports), error on
-      Out of memory condition (Charles Hardin), various namespace prefixes
-      fixes (Kasimier Buchcik), </li>
-  <li>improvement: speed up sortingi, start of internals refactoring (Kasimier
-      Buchcik)</li>
-  <li>documentation: man page fixes and updates (Daniel Leidert)
+  <li>portability fixes: EXSLT date/time on Solaris and IRIX (Albert
+    Chin),HP-UX  build (Albert Chin),</li>
+  <li>build fixes: Python detection(Joseph Sacco), plugin configurei(Joel
+    Reed)</li>
+  <li>bug fixes: pattern compilation fix(William Brack), EXSLT date/timefix
+    (Thomas Broyer), EXSLT function bug, potential loop on variableeval,
+    startup race (Christopher Palmer), debug statement left in python(Nic
+    Ferrier), various cleanup based on Coverity reports), error onOut of
+    memory condition (Charles Hardin), various namespace prefixesfixes
+    (Kasimier Buchcik),</li>
+  <li>improvement: speed up sortingi, start of internals refactoring
+    (KasimierBuchcik)</li>
+  <li>documentation: man page fixes and updates (Daniel Leidert)</li>
 </ul>
 
 <h3>1.1.15: Sep 04 2005</h3>
 <ul>
-  <li>build fixes: Windows build cleanups and updates (Igor Zlatkovic),
-    remove jhbuild warnings</li>
-  <li>bug fixes: negative number formatting (William Brack), number
-    formatting per mille definition (William Brack), XInclude default values
-    (William), text copy bugs (William), bug related to xmlXPathContext size,
-    reuse libxml2 memory management for text nodes, dictionnary text bug,
-    forbid variables in match (needs libxml2-2.6.21)</li>
+  <li>build fixes: Windows build cleanups and updates (Igor Zlatkovic),remove
+    jhbuild warnings</li>
+  <li>bug fixes: negative number formatting (William Brack), numberformatting
+    per mille definition (William Brack), XInclude default values(William),
+    text copy bugs (William), bug related to xmlXPathContext size,reuse
+    libxml2 memory management for text nodes, dictionnary text bug,forbid
+    variables in match (needs libxml2-2.6.21)</li>
   <li>improvements: EXSLT dyn:map (Mark Vakoc),</li>
-  <li>documentation: EXSLT date and time functions namespace in man (Jonathan
-    Wakely)</li>
+  <li>documentation: EXSLT date and time functions namespace in man
+    (JonathanWakely)</li>
 </ul>
 
 <h3>1.1.14: Apr 02 2005</h3>
 <ul>
-  <li>bug fixes: text node on stylesheet document without a dictionary
-    (William Brack), more checking of XSLT syntax, calling xsltInit()
-    multiple times, mode values interning raised by Mark Vakoc, bug in
-    pattern matching with ancestors, bug in patterna matching with cascading
-    select, xinclude and document() problem, build outside of source tree
-    (Mike Castle)</li>
-  <li>improvement: added a --nodict mode to xsltproc to check problems for
-    docuemtns without dictionnaries</li>
+  <li>bug fixes: text node on stylesheet document without a
+    dictionary(William Brack), more checking of XSLT syntax, calling
+    xsltInit()multiple times, mode values interning raised by Mark Vakoc, bug
+    inpattern matching with ancestors, bug in patterna matching with
+    cascadingselect, xinclude and document() problem, build outside of source
+    tree(Mike Castle)</li>
+  <li>improvement: added a --nodict mode to xsltproc to check problems
+    fordocuemtns without dictionnaries</li>
 </ul>
 
 <h3>1.1.13: Mar 13 2005</h3>
 <ul>
-  <li>build fixes: 64bits cleanup (William Brack), python 2.4 test (William),
-    LIBXSLT_VERSION_EXTRA on Windows (William), Windows makefiles fixes (Joel
-    Reed), libgcrypt-devel requires for RPM spec.</li>
-  <li>bug fixes: exslt day-of-week-in-month (Sal Paradise), xsl:call-template
-    should not change the current template rule (William Brack), evaluation
-    of global variables (William Brack), RVT's in XPath predicates (William),
-    namespace URI on template names (Mark Vakoc), stat() for Windows patch
-    (Aleksey Gurtovoy), pattern expression fixes (William Brack), out of
-    memory detection misses (William), parserOptions propagation (William),
-    exclude-result-prefixes fix (William), // patten fix (William).</li>
-  <li>extensions: module support (Joel Reed), dictionnary based speedups
-    trying to get rid of xmlStrEqual as much as possible.</li>
+  <li>build fixes: 64bits cleanup (William Brack), python 2.4 test
+    (William),LIBXSLT_VERSION_EXTRA on Windows (William), Windows makefiles
+    fixes (JoelReed), libgcrypt-devel requires for RPM spec.</li>
+  <li>bug fixes: exslt day-of-week-in-month (Sal Paradise),
+    xsl:call-templateshould not change the current template rule (William
+    Brack), evaluationof global variables (William Brack), RVT's in XPath
+    predicates (William),namespace URI on template names (Mark Vakoc), stat()
+    for Windows patch(Aleksey Gurtovoy), pattern expression fixes (William
+    Brack), out ofmemory detection misses (William), parserOptions
+    propagation (William),exclude-result-prefixes fix (William), // patten
+    fix (William).</li>
+  <li>extensions: module support (Joel Reed), dictionnary based
+    speedupstrying to get rid of xmlStrEqual as much as possible.</li>
   <li>documentation: added Wiki (Joel Reed)</li>
 </ul>
 
 <h3>1.1.12: Oct 29 2004</h3>
 <ul>
   <li>build fixes: warnings removal (William).</li>
-  <li>bug fixes: attribute document pointer fix (Mark Vakoc), exslt date
-    negative periods (William Brack), generated tree structure fixes,
-    namespace lookup fix, use reentrant gmtime_r (William Brack),
-    exslt:funtion namespace fix (William), potential NULL pointer reference
-    (Dennis Dams, William), force string interning on generated
-  documents.</li>
-  <li>documentation: update of the second tutorial (Panagiotis Louridas), add
-    exslt doc in rpm packages, fix the xsltproc man page.</li>
+  <li>bug fixes: attribute document pointer fix (Mark Vakoc), exslt
+    datenegative periods (William Brack), generated tree structure
+    fixes,namespace lookup fix, use reentrant gmtime_r (William
+    Brack),exslt:funtion namespace fix (William), potential NULL pointer
+    reference(Dennis Dams, William), force string interning on
+    generateddocuments.</li>
+  <li>documentation: update of the second tutorial (Panagiotis Louridas),
+    addexslt doc in rpm packages, fix the xsltproc man page.</li>
 </ul>
 
 <h3>1.1.11: Sep 29 2004</h3>
 <ul>
-  <li>bug fixes: xsl:include problems (William Brack), UTF8 number pattern
-    (William), date-time validation (William), namespace fix (William),
-    various Exslt date fixes (William), error callback fixes, leak with
-    namespaced global variable, attempt to fix a weird problem #153137</li>
+  <li>bug fixes: xsl:include problems (William Brack), UTF8 number
+    pattern(William), date-time validation (William), namespace fix
+    (William),various Exslt date fixes (William), error callback fixes, leak
+    withnamespaced global variable, attempt to fix a weird problem
+  #153137</li>
   <li>improvements: exslt:date-sum tests (Derek Poon)</li>
   <li>documentation: second tutorial by Panagiotis Lourida</li>
 </ul>
 
 <h3>1.1.10: Aug 31 2004</h3>
 <ul>
-  <li>build fix: NUL in c file blocking compilation on Solaris, Windows build
-    (Igor Zlatkovic)</li>
+  <li>build fix: NUL in c file blocking compilation on Solaris, Windows
+    build(Igor Zlatkovic)</li>
   <li>fix: key initialization problem (William Brack)</li>
   <li>documentation: fixed missing man page description for --path</li>
 </ul>
 
 <h3>1.1.9: Aug 22 2004</h3>
 <ul>
-  <li>build fixes: missing tests (William Brack), Python dependancies, Python
-    on 64bits boxes, --with-crypto flag (Rob Richards),</li>
-  <li>fixes: RVT key handling (William), Python binding (William and Sitsofe
-    Wheeler), key and XPath troubles (William), template priority on imports
-    (William), str:tokenize with empty strings (William), #default namespace
-    alias behaviour (William), doc ordering missing for main document
-    (William), 64bit bug (Andreas Schwab)</li>
-  <li>improvements: EXSLT date:sum added (Joel Reed), hook for document
-    loading for David Hyatt, xsltproc --nodtdattr to avoid defaulting DTD
-    attributes, extend xsltproc --version with CVS stamp (William).</li>
+  <li>build fixes: missing tests (William Brack), Python dependancies,
+    Pythonon 64bits boxes, --with-crypto flag (Rob Richards),</li>
+  <li>fixes: RVT key handling (William), Python binding (William and
+    SitsofeWheeler), key and XPath troubles (William), template priority on
+    imports(William), str:tokenize with empty strings (William), #default
+    namespacealias behaviour (William), doc ordering missing for main
+    document(William), 64bit bug (Andreas Schwab)</li>
+  <li>improvements: EXSLT date:sum added (Joel Reed), hook for
+    documentloading for David Hyatt, xsltproc --nodtdattr to avoid defaulting
+    DTDattributes, extend xsltproc --version with CVS stamp (William).</li>
   <li>Documentation: web page problem reported by Oliver Stoeneberg</li>
 </ul>
 
 <h3>1.1.8: July 5 2004</h3>
 <ul>
-  <li>build fixes: Windows runtime options (Oliver Stoeneberg), Windows
-    binary package layout (Igor Zlatkovic), libgcrypt version test and link
-    (William)</li>
+  <li>build fixes: Windows runtime options (Oliver Stoeneberg), Windowsbinary
+    package layout (Igor Zlatkovic), libgcrypt version test and
+  link(William)</li>
   <li>documentation: fix libxslt namespace name in doc (William)</li>
-  <li>bug fixes: undefined namespace message (William Brack), search engine
-    (William), multiple namespace fixups (William), namespace fix for key
-    evaluation (William), Python memory debug bindings,</li>
+  <li>bug fixes: undefined namespace message (William Brack), search
+    engine(William), multiple namespace fixups (William), namespace fix for
+    keyevaluation (William), Python memory debug bindings,</li>
   <li>improvements: crypto extensions for exslt (Joel Reed, William)</li>
 </ul>
 
 <h3>1.1.7: May 17 2004</h3>
 <ul>
   <li>build fix: warning about localtime_r on Solaris</li>
-  <li>bug fix: UTF8 string tokenize (William Brack), subtle memory
-    corruption, linefeed after comment at document level (William),
-    disable-output-escaping problem (William), pattern compilation in deep
-    imported stylesheets (William), namespace extension prefix bug,
-    libxslt.m4 bug (Edward Rudd), namespace lookup for attribute, namespaced
-    DOCTYPE name</li>
+  <li>bug fix: UTF8 string tokenize (William Brack), subtle memorycorruption,
+    linefeed after comment at document level
+    (William),disable-output-escaping problem (William), pattern compilation
+    in deepimported stylesheets (William), namespace extension prefix
+    bug,libxslt.m4 bug (Edward Rudd), namespace lookup for attribute,
+    namespacedDOCTYPE name</li>
 </ul>
 
 <h3>1.1.6: Apr 18 2004</h3>
@@ -443,81 +456,81 @@
   <li>performance: use dictionnary lookup for variables</li>
   <li>remove use of _private from source documents</li>
   <li>cleanup of "make tests" output</li>
-  <li>bugfixes: AVT in local variables, use localtime_r to avoid thread
-    troubles (William), dictionary handling bug (William), limited number of
-    stubstitutions in AVT (William), tokenize fix for UTF-8 (William),
-    superfluous namespace (William), xsltproc error code on
-    &lt;xsl:message&gt; halt, OpenVMS fix, dictionnary reference counting
-    change.</li>
+  <li>bugfixes: AVT in local variables, use localtime_r to avoid
+    threadtroubles (William), dictionary handling bug (William), limited
+    number ofstubstitutions in AVT (William), tokenize fix for UTF-8
+    (William),superfluous namespace (William), xsltproc error code
+    on&lt;xsl:message&gt; halt, OpenVMS fix, dictionnary reference
+    countingchange.</li>
 </ul>
 
 <h3>1.1.4: Feb 23 2004</h3>
 <ul>
-  <li>bugfixes: attributes without doc (Mariano Suárez-Alvarez), problem with
-    Yelp, extension problem</li>
+  <li>bugfixes: attributes without doc (Mariano Suárez-Alvarez), problem
+    withYelp, extension problem</li>
   <li>display extension modules (Steve Little)</li>
   <li>Windows compilation patch (Mark Vadoc), Mingw (Mikhail Grushinskiy)</li>
 </ul>
 
 <h3>1.1.3: Feb 16 2004</h3>
 <ul>
-  <li>Rewrote the Attribute Value Template code, new XPath compilation
-    interfaces, dictionnary reuses for XSLT with potential for serious
-    performance improvements.</li>
-  <li>bug fixes: portability (William Brack), key() in node-set() results
-    (William), comment before doctype (William), math and node-set() problems
-    (William), cdata element and default namespace (William), behaviour on
-    unknown XSLT elements (Stefan Kost), priority of "//foo" patterns
-    (William), xsl:element and xsl:attribute QName check (William), comments
-    with -- (William), attribute namespace (William), check for ?&gt; in PI
-    (William)</li>
+  <li>Rewrote the Attribute Value Template code, new XPath
+    compilationinterfaces, dictionnary reuses for XSLT with potential for
+    seriousperformance improvements.</li>
+  <li>bug fixes: portability (William Brack), key() in node-set()
+    results(William), comment before doctype (William), math and node-set()
+    problems(William), cdata element and default namespace (William),
+    behaviour onunknown XSLT elements (Stefan Kost), priority of "//foo"
+    patterns(William), xsl:element and xsl:attribute QName check (William),
+    commentswith -- (William), attribute namespace (William), check for ?&gt;
+    in PI(William)</li>
   <li>Documentations: cleanup (John Fleck and William)</li>
-  <li>Python: patch for OS-X (Gianni Ceccarelli), enums export (Stephane
-    bidoul)</li>
+  <li>Python: patch for OS-X (Gianni Ceccarelli), enums export
+    (Stephanebidoul)</li>
 </ul>
 
 <h3>1.1.2: Dec 24 2003</h3>
 <ul>
-  <li>Documentation fixes (John Fleck, William Brack), EXSLT documentation
-    (William Brack)</li>
+  <li>Documentation fixes (John Fleck, William Brack), EXSLT
+    documentation(William Brack)</li>
   <li>Windows compilation fixes for MSVC and Mingw (Igor Zlatkovic)</li>
-  <li>Bug fixes: exslt:date returning NULL strings (William Brack),
-    namespaces output (William Brack),  key and namespace definition problem,
-    passing options down to the document() parser, xsl:number fixes (William
-    Brack)</li>
+  <li>Bug fixes: exslt:date returning NULL strings (William Brack),namespaces
+    output (William Brack),  key and namespace definition problem,passing
+    options down to the document() parser, xsl:number fixes
+  (WilliamBrack)</li>
 </ul>
 
 <h3>1.1.1: Dec 10 2003</h3>
 <ul>
   <li>code cleanup (William Brack)</li>
   <li>Windows: Makefile improvements (Igor Zlatkovic)</li>
-  <li>documentation improvements: William Brack, libexslt man page (Jonathan
-    Wakely)</li>
+  <li>documentation improvements: William Brack, libexslt man page
+    (JonathanWakely)</li>
   <li>param in EXSLT functions (Shaun McCance)</li>
   <li>XSLT debugging improvements (Mark Vakoc)</li>
-  <li>bug fixes: number formatting (Bjorn Reese), exslt:tokenize (William
-    Brack), key selector parsing with | reported by Oleg Paraschenko,
-    xsl:element with computed namespaces (William Brack), xslt:import/include
-    recursion detection (William Brack), exslt:function used in keys (William
-    Brack), bug when CDATA_SECTION are foun in the tree (William Brack),
-    entities handling when using XInclude.</li>
+  <li>bug fixes: number formatting (Bjorn Reese), exslt:tokenize
+    (WilliamBrack), key selector parsing with | reported by Oleg
+    Paraschenko,xsl:element with computed namespaces (William Brack),
+    xslt:import/includerecursion detection (William Brack), exslt:function
+    used in keys (WilliamBrack), bug when CDATA_SECTION are foun in the tree
+    (William Brack),entities handling when using XInclude.</li>
 </ul>
 
 <h3>1.1.0: Nov 4 2003</h3>
 <ul>
   <li>Removed DocBook SGML broken support</li>
   <li>fix xsl:key to work with PIs</li>
-  <li>Makefile and build improvement (Graham Wilson), build cleanup (William
-    Brack), macro fix (Justin Fletcher), build outside of source tree (Roumen
-    Petrov)</li>
-  <li>xsltproc option display fix (Alexey Efimov), --load-trace (Crutcher
-    Dunnavant)</li>
+  <li>Makefile and build improvement (Graham Wilson), build cleanup
+    (WilliamBrack), macro fix (Justin Fletcher), build outside of source tree
+    (RoumenPetrov)</li>
+  <li>xsltproc option display fix (Alexey Efimov), --load-trace
+    (CrutcherDunnavant)</li>
   <li>Python: never use stdout for error</li>
   <li>extension memory error fix (Karl Eichwalder)</li>
   <li>header path fixes (Steve Ball)</li>
   <li>added saxon:line-number() to libexslt (Brett Kail)</li>
-  <li>Fix some tortuous template problems when using predicates (William
-    Brack)</li>
+  <li>Fix some tortuous template problems when using predicates
+  (WilliamBrack)</li>
   <li>Debugger status patch (Kasimier Buchcik)</li>
   <li>Use new libxml2-2.6.x APIs for faster processing</li>
   <li>Make sure xsl:sort is empty</li>
@@ -546,14 +559,14 @@
 
 <h3>1.0.32: Aug 9 2003</h3>
 <ul>
-  <li>bugfixes: xsltSaveResultToFile() python binding (Chris Jaeger), EXSLT
-    function (William Brack), RVT for globals (William Brack), EXSLT date
-    (William Brack),
-    <p>speed of large text output, xsl:copy with attributes, strip-space and
-    namespaces prefix, fix for --path xsltproc option, EXST:tokenize (Shaun
-    McCance), EXSLT:seconds (William Brack), sort with multiple keys (William
-    Brack), checking of { and } for attribute value templates (William
-    Brack)</p>
+  <li>bugfixes: xsltSaveResultToFile() python binding (Chris Jaeger),
+    EXSLTfunction (William Brack), RVT for globals (William Brack), EXSLT
+    date(William Brack),
+    <p>speed of large text output, xsl:copy with attributes, strip-space
+    andnamespaces prefix, fix for --path xsltproc option, EXST:tokenize
+    (ShaunMcCance), EXSLT:seconds (William Brack), sort with multiple keys
+    (WilliamBrack), checking of { and } for attribute value templates
+    (WilliamBrack)</p>
   </li>
   <li>Python bindings for extension elements (Sean Treadway)</li>
   <li>EXSLT:split added (Shaun McCance)</li>
@@ -563,16 +576,16 @@
 
 <h3>1.0.31: Jul 6 2003</h3>
 <ul>
-  <li>bugfixes: xsl:copy on namespace nodes, AVT for xsl:sort order, fix for
-    the debugger (Keith Isdale), output filename limitation, trio.h and
-    triodef.h added (Albert Chin), EXSLT node-set (Peter Breitenlohner),
-    xsltChoose and whitespace (Igor Zlatkovic),
-    <p>stylesheet compilation (Igor Zlatkovic), NaN and sort (William Brack),
-    RVT bug introduced in 1.0.30</p>
+  <li>bugfixes: xsl:copy on namespace nodes, AVT for xsl:sort order, fix
+    forthe debugger (Keith Isdale), output filename limitation, trio.h
+    andtriodef.h added (Albert Chin), EXSLT node-set (Peter
+    Breitenlohner),xsltChoose and whitespace (Igor Zlatkovic),
+    <p>stylesheet compilation (Igor Zlatkovic), NaN and sort (William
+    Brack),RVT bug introduced in 1.0.30</p>
   </li>
   <li>avoid generating &amp;quot; (fix in libxml2-2.5.8)</li>
-  <li>fix 64bit cleaness problem and compilation troubles introduced in
-  1.0.30</li>
+  <li>fix 64bit cleaness problem and compilation troubles introduced
+  in1.0.30</li>
   <li>Windows makefile generation (Igor Zlatkovic)</li>
   <li>HP-UX portability fix</li>
 </ul>
@@ -580,20 +593,20 @@
 <h3>1.0.30: May 4 2003</h3>
 <ul>
   <li>Fixes and new APIs to handle Result Value Trees and avoid leaks</li>
-  <li>Fixes for: EXSLT math pow() function (Charles Bozeman), global
-    parameter and global variables mismatch, a segfault on pattern
-    compilation errors, namespace copy in xsl:copy-of, python generator
-    problem, OpenVMS trio update, premature call to xsltFreeStackElem (Igor),
-    current node when templates applies to attributes</li>
+  <li>Fixes for: EXSLT math pow() function (Charles Bozeman), globalparameter
+    and global variables mismatch, a segfault on patterncompilation errors,
+    namespace copy in xsl:copy-of, python generatorproblem, OpenVMS trio
+    update, premature call to xsltFreeStackElem (Igor),current node when
+    templates applies to attributes</li>
 </ul>
 
 <h3>1.0.29: Apr 1 2003</h3>
 <ul>
   <li>performance improvements especially for large flat documents</li>
-  <li>bug fixes: Result Value Tree handling, XML IDs, keys(), extra namespace
-    declarations with xsl:elements.</li>
-  <li>portability: python and trio fixes (Albert Chin), python on Solaris
-    (Ben Phillips)</li>
+  <li>bug fixes: Result Value Tree handling, XML IDs, keys(), extra
+    namespacedeclarations with xsl:elements.</li>
+  <li>portability: python and trio fixes (Albert Chin), python on Solaris(Ben
+    Phillips)</li>
 </ul>
 
 <h3>1.0.28: Mar 24 2003</h3>
@@ -601,43 +614,44 @@
   <li>fixed node() in patterns semantic.</li>
   <li>fixed a memory access problem in format-number()</li>
   <li>fixed stack overflow in recursive global variable or params</li>
-  <li>cleaned up Result Value Tree handling, and fixed a couple of old bugs
-    in the process</li>
+  <li>cleaned up Result Value Tree handling, and fixed a couple of old bugsin
+    the process</li>
 </ul>
 
 <h3>1.0.27: Feb 24 2003</h3>
 <ul>
-  <li>bug fixes: spurious xmlns:nsX="" generation, serialization bug (in
-    libxml2), a namespace copy problem, errors in the RPM spec prereqs</li>
+  <li>bug fixes: spurious xmlns:nsX="" generation, serialization bug
+    (inlibxml2), a namespace copy problem, errors in the RPM spec prereqs</li>
   <li>Windows path canonicalization and document cache fix (Igor)</li>
 </ul>
 
 <h3>1.0.26: Feb 10 2003</h3>
 <ul>
-  <li>Fixed 3 serious bugs in document() and stylesheet compilation which
-    could lead to a crash</li>
+  <li>Fixed 3 serious bugs in document() and stylesheet compilation
+    whichcould lead to a crash</li>
 </ul>
 
 <h3>1.0.25: Feb 5 2003</h3>
 <ul>
-  <li>Bug fix: double-free for standalone stylesheets introduced in 1.0.24, C
-    syntax pbm, 3 bugs reported by Eric van der Vlist</li>
-  <li>Some XPath and XInclude related problems were actually fixed in
-    libxml2-2.5.2</li>
+  <li>Bug fix: double-free for standalone stylesheets introduced in 1.0.24,
+    Csyntax pbm, 3 bugs reported by Eric van der Vlist</li>
+  <li>Some XPath and XInclude related problems were actually fixed
+    inlibxml2-2.5.2</li>
   <li>Documentation: emphasize taht --docbook is not for XML docs.</li>
 </ul>
 
 <h3>1.0.24: Jan 14 2003</h3>
 <ul>
-  <li>bug fixes: imported global varables, python bindings (Stéphane Bidoul),
-    EXSLT memory leak (Charles Bozeman), namespace generation on
-    xsl:attribute, space handling with imports (Daniel Stodden),
-    extension-element-prefixes (Josh Parsons), comments within xsl:text (Matt
-    Sergeant), superfluous xmlns generation, XInclude related bug for
-    numbering, EXSLT strings (Alexey Efimov), attribute-sets computation on
-    imports, extension module init and shutdown callbacks not called</li>
-  <li>HP-UX portability (Alexey Efimov), Windows makefiles (Igor and Stephane
-    Bidoul), VMS makefile updates (Craig A. Berry)</li>
+  <li>bug fixes: imported global varables, python bindings (Stéphane
+    Bidoul),EXSLT memory leak (Charles Bozeman), namespace generation
+    onxsl:attribute, space handling with imports (Daniel
+    Stodden),extension-element-prefixes (Josh Parsons), comments within
+    xsl:text (MattSergeant), superfluous xmlns generation, XInclude related
+    bug fornumbering, EXSLT strings (Alexey Efimov), attribute-sets
+    computation onimports, extension module init and shutdown callbacks not
+    called</li>
+  <li>HP-UX portability (Alexey Efimov), Windows makefiles (Igor and
+    StephaneBidoul), VMS makefile updates (Craig A. Berry)</li>
   <li>adds xsltGetProfileInformation() (Michael Rothwell)</li>
   <li>fix the API generation scripts</li>
   <li>API to provide the sorting routines (Richard Jinks)</li>
@@ -651,10 +665,10 @@
 <ul>
   <li>Windows build cleanup (Igor)</li>
   <li>Unix build and RPM packaging cleanup</li>
-  <li>Improvement of the python bindings: extension functions and activating
-    EXSLT</li>
-  <li>various bug fixes: number formatting, portability for bounded string
-    functions, CData nodes, key(), @*[...] patterns</li>
+  <li>Improvement of the python bindings: extension functions and
+    activatingEXSLT</li>
+  <li>various bug fixes: number formatting, portability for bounded
+    stringfunctions, CData nodes, key(), @*[...] patterns</li>
   <li>Documentation improvements (John Fleck)</li>
   <li>added libxslt.m4 (Thomas Schraitle)</li>
 </ul>
@@ -662,22 +676,22 @@
 <h3>1.0.22: Oct 18 2002</h3>
 <ul>
   <li>Updates on the Windows Makefiles</li>
-  <li>Added a security module, and a related set of new options to
-  xsltproc</li>
+  <li>Added a security module, and a related set of new options
+  toxsltproc</li>
   <li>Allowed per transformation error handler.</li>
-  <li>Fixed a few bugs: node() semantic, URI escaping, media-type, attribute
-    lists</li>
+  <li>Fixed a few bugs: node() semantic, URI escaping, media-type,
+    attributelists</li>
 </ul>
 
 <h3>1.0.21: Sep 26 2002</h3>
 <ul>
-  <li>Bug fixes: match="node()", date:difference() (Igor and Charlie
-    Bozeman), disable-output-escaping</li>
+  <li>Bug fixes: match="node()", date:difference() (Igor and CharlieBozeman),
+    disable-output-escaping</li>
   <li>Python bindings: style.saveResultToString() from Ralf Mattes</li>
   <li>Logos from Marc Liyanage</li>
   <li>Mem leak fix from Nathan Myers</li>
-  <li>Makefile: DESTDIR fix from Christophe Merlet, AMD x86_64 (Mandrake),
-    Windows (Igor), Python detection</li>
+  <li>Makefile: DESTDIR fix from Christophe Merlet, AMD x86_64
+    (Mandrake),Windows (Igor), Python detection</li>
   <li>Documentation improvements: John Fleck</li>
 </ul>
 
@@ -686,8 +700,8 @@
   <li>Windows makefile updates (Igor) and x86-64 (Frederic Crozat)</li>
   <li>fixed HTML meta tag saving for Mac/IE users</li>
   <li>possible leak patches from Nathan Myers</li>
-  <li>try to handle document('') as best as possible depending in the
-  cases</li>
+  <li>try to handle document('') as best as possible depending in
+  thecases</li>
   <li>Fixed the DocBook stylesheets handling problem</li>
   <li>Fixed a few XSLT reported errors</li>
 </ul>
@@ -700,27 +714,26 @@
   <li>document('') fix: bug pointed by Eric van der Vlist</li>
   <li>xsl:message with terminate="yes" fixes: William Brack</li>
   <li>xsl:sort order support added: Ken Neighbors</li>
-  <li>a few other bug fixes, some of them requiring the latest version of
-    libxml2</li>
+  <li>a few other bug fixes, some of them requiring the latest version
+    oflibxml2</li>
 </ul>
 
 <h3>1.0.18: May 27 2002</h3>
 <ul>
-  <li>a number of bug fixes: attributes, extra namespace declarations
-    (DocBook), xsl:include crash (Igor), documentation (Christian Cornelssen,
-    Charles Bozeman and Geert Kloosterman),  element-available (Richard
-  Jinks)</li>
-  <li>xsltproc can now list teh registered extensions thanks to Mark
-  Vakoc</li>
-  <li>there is a new API to save directly to a string
-    xsltSaveResultToString() by Morus Walter</li>
+  <li>a number of bug fixes: attributes, extra namespace
+    declarations(DocBook), xsl:include crash (Igor), documentation (Christian
+    Cornelssen,Charles Bozeman and Geert Kloosterman),  element-available
+    (RichardJinks)</li>
+  <li>xsltproc can now list teh registered extensions thanks to MarkVakoc</li>
+  <li>there is a new API to save directly to a stringxsltSaveResultToString()
+    by Morus Walter</li>
   <li>specific error registration function for the python API</li>
 </ul>
 
 <h3>1.0.17: April 29 2002</h3>
 <ul>
-  <li>cleanup in code, XSLT debugger support and Makefiles for Windows by
-  Igor</li>
+  <li>cleanup in code, XSLT debugger support and Makefiles for Windows
+  byIgor</li>
   <li>a C++ portability fix by Mark Vakoc</li>
   <li>EXSLT date improvement and regression tests by Charles Bozeman</li>
   <li>attempt to fix a bug in xsltProcessUserParamInternal</li>
@@ -728,18 +741,18 @@
 
 <h3>1.0.16: April 15 2002</h3>
 <ul>
-  <li>Bug fixes: strip-space, URL in HTML output, error when xsltproc can't
-    save</li>
+  <li>Bug fixes: strip-space, URL in HTML output, error when xsltproc
+    can'tsave</li>
   <li>portability fixes: OSF/1, IEEE on alphas, Windows, Python bindings</li>
 </ul>
 
 <h3>1.0.15: Mar 25 2002</h3>
 <ul>
-  <li>Bugfixes: XPath, python Makefile, recursive attribute sets, @foo[..]
-    templates</li>
+  <li>Bugfixes: XPath, python Makefile, recursive attribute sets,
+    @foo[..]templates</li>
   <li>Debug of memory alocation with valgind</li>
-  <li>serious profiling leading to significant improvement for DocBook
-    processing</li>
+  <li>serious profiling leading to significant improvement for
+    DocBookprocessing</li>
   <li>revamp of the Windows build</li>
 </ul>
 
@@ -747,16 +760,16 @@
 <ul>
   <li>Improvement in the XPath engine (libxml2-2.4.18)</li>
   <li>Nasty bug fix related to exslt:node-set</li>
-  <li>Fixed the python Makefiles, cleanup of doc comments, Windows
-    portability fixes</li>
+  <li>Fixed the python Makefiles, cleanup of doc comments, Windowsportability
+    fixes</li>
 </ul>
 
 <h3>1.0.13: Mar 8 2002</h3>
 <ul>
   <li>a number of bug fixes including "namespace node have no parents"</li>
   <li>Improvement of the Python bindings</li>
-  <li>Charles Bozeman provided fixes and regression tests for exslt date
-    functions.</li>
+  <li>Charles Bozeman provided fixes and regression tests for exslt
+    datefunctions.</li>
 </ul>
 
 <h3>1.0.12: Feb 11 2002</h3>
@@ -768,10 +781,9 @@
 <h3>1.0.11: Feb 8 2002</h3>
 <ul>
   <li>Change of Licence to the <a
-    href="http://www.opensource.org/licenses/mit-license.html">MIT
-  Licence</a></li>
-  <li>Added a beta version of the Python bindings, including support to
-    extend the engine with functions written in Python</li>
+    href="http://www.opensource.org/licenses/mit-license.html">MITLicence</a></li>
+  <li>Added a beta version of the Python bindings, including support toextend
+    the engine with functions written in Python</li>
   <li>A number of bug fixes</li>
   <li>Charlie Bozeman provided more EXSLT functions</li>
   <li>Portability fixes</li>
@@ -782,8 +794,7 @@
   <li>Windows fixes for Win32 from Igor</li>
   <li>Fixed the Solaris compilation trouble (Albert)</li>
   <li>Documentation changes and updates: John Fleck</li>
-  <li>Added a stringparam option to avoid escaping hell at the shell
-  level</li>
+  <li>Added a stringparam option to avoid escaping hell at the shelllevel</li>
   <li>A few bug fixes</li>
 </ul>
 
@@ -792,23 +803,22 @@
   <li>Makefile patches from Peter Williams</li>
   <li>attempt to fix the compilation problem associated to prelinking</li>
   <li>obsoleted libxsltbreakpoint now deprecated and frozen to 1.0.8 API</li>
-  <li>xsltproc return codes are now significant, John Fleck updated the
-    documentation</li>
-  <li>patch to allow as much as 40 steps in patterns (Marc Tardif), should be
-    made dynamic really</li>
-  <li>fixed a bug raised by Nik Clayton when using doctypes with HTML
-  output</li>
+  <li>xsltproc return codes are now significant, John Fleck updated
+    thedocumentation</li>
+  <li>patch to allow as much as 40 steps in patterns (Marc Tardif), should
+    bemade dynamic really</li>
+  <li>fixed a bug raised by Nik Clayton when using doctypes with
+  HTMLoutput</li>
   <li>patches from Keith Isdale to interface with xsltdebugger</li>
 </ul>
 
 <h3>1.0.8: Nov 26 2001</h3>
 <ul>
-  <li>fixed an annoying header problem, removed a few bugs and some code
-    cleanup</li>
+  <li>fixed an annoying header problem, removed a few bugs and some
+    codecleanup</li>
   <li>patches for Windows and update of Windows Makefiles by Igor</li>
   <li>OpenVMS port instructions from John A Fotheringham</li>
-  <li>fixed some Makefiles annoyance and libraries prelinking
-  informations</li>
+  <li>fixed some Makefiles annoyance and libraries prelinkinginformations</li>
 </ul>
 
 <h3>1.0.7: Nov 10 2001</h3>
@@ -821,29 +831,28 @@
 
 <h3>1.0.6: Oct 30 2001</h3>
 <ul>
-  <li>bug fixes on number formatting (Thomas), date/time functions (Bruce
-    Miller)</li>
+  <li>bug fixes on number formatting (Thomas), date/time functions
+    (BruceMiller)</li>
   <li>update of the Windows Makefiles (Igor)</li>
   <li>fixed DOCTYPE generation rules for HTML output (me)</li>
 </ul>
 
 <h3>1.0.5: Oct 10 2001</h3>
 <ul>
-  <li>some portability fixes, including Windows makefile updates from
-  Igor</li>
+  <li>some portability fixes, including Windows makefile updates fromIgor</li>
   <li>fixed a dozen bugs on XSLT and EXSLT (me and Thomas Broyer)</li>
-  <li>support for Saxon's evaluate and expressions extensions added (initial
-    contribution from Darren Graves)</li>
+  <li>support for Saxon's evaluate and expressions extensions added
+    (initialcontribution from Darren Graves)</li>
   <li>better handling of XPath evaluation errors</li>
 </ul>
 
 <h3>1.0.4: Sep 12 2001</h3>
 <ul>
   <li>Documentation updates from John fleck</li>
-  <li>bug fixes (DocBook  FO generation should be fixed)  and portability
-    improvements</li>
-  <li>Thomas Broyer improved the existing EXSLT support and added String,
-    Time and Date core functions support</li>
+  <li>bug fixes (DocBook  FO generation should be fixed)  and
+    portabilityimprovements</li>
+  <li>Thomas Broyer improved the existing EXSLT support and added String,Time
+    and Date core functions support</li>
 </ul>
 
 <h3>1.0.3:  Aug 23 2001</h3>
@@ -874,17 +883,17 @@
 <h3>1.0.0: July 10 2001</h3>
 <ul>
   <li>a lot of cleanup, a lot of regression tests added or fixed</li>
-  <li>added a documentation for <a href="extensions.html">writing
-    extensions</a></li>
+  <li>added a documentation for <a
+    href="extensions.html">writingextensions</a></li>
   <li>fixed some variable evaluation problems (with William)</li>
-  <li>added profiling of stylesheet execution accessible as the xsltproc
-    --profile option</li>
-  <li>fixed element-available() and the implementation of the various
-    chunking methods present, Norm Walsh provided a lot of feedback</li>
-  <li>exclude-result-prefixes and namespaces output should now work as
-    expected</li>
-  <li>added support of embedded stylesheet as described in section 2.7 of the
-    spec</li>
+  <li>added profiling of stylesheet execution accessible as the
+    xsltproc--profile option</li>
+  <li>fixed element-available() and the implementation of the variouschunking
+    methods present, Norm Walsh provided a lot of feedback</li>
+  <li>exclude-result-prefixes and namespaces output should now work
+  asexpected</li>
+  <li>added support of embedded stylesheet as described in section 2.7 of
+    thespec</li>
 </ul>
 
 <h3>0.14.0: July 5 2001</h3>
@@ -893,8 +902,9 @@
   <li>completion of the little XSLT-1.0 features left unimplemented</li>
   <li>Added and implemented the extension API suggested by Thomas Broyer</li>
   <li>the Windows MSC environment should be complete</li>
-  <li>tested and optimized with a really large document (DocBook Definitive
-    Guide) libxml/libxslt should really be faster on serious workloads</li>
+  <li>tested and optimized with a really large document (DocBook
+    DefinitiveGuide) libxml/libxslt should really be faster on serious
+    workloads</li>
 </ul>
 
 <h3>0.13.0: June 26 2001</h3>
@@ -902,29 +912,29 @@
   <li>lots of cleanups</li>
   <li>fixed a C++ compilation problem</li>
   <li>couple of fixes to xsltSaveTo()</li>
-  <li>try to fix Docbook-xslt-1.4 and chunking, updated the regression test
-    with them</li>
+  <li>try to fix Docbook-xslt-1.4 and chunking, updated the regression
+    testwith them</li>
   <li>fixed pattern compilation and priorities problems</li>
   <li>Patches for Windows and MSC project mostly contributed by Yon Derek</li>
   <li>update to the Tutorial by John Fleck</li>
   <li>William fixed bugs in templates and for-each functions</li>
-  <li>added a new interface xsltRunStylesheet() for a more flexible output
-    (incomplete), added -o option to xsltproc</li>
+  <li>added a new interface xsltRunStylesheet() for a more flexible
+    output(incomplete), added -o option to xsltproc</li>
 </ul>
 
 <h3>0.12.0: June 18 2001</h3>
 <ul>
   <li>fixed a dozen of bugs reported</li>
-  <li>HTML generation should be quite better (requires libxml-2.3.11 upgrade
-    too)</li>
+  <li>HTML generation should be quite better (requires libxml-2.3.11
+    upgradetoo)</li>
   <li>William fixed some problems with document()</li>
-  <li>Fix namespace nodes selection and copy (requires libxml-2.3.11 upgrade
-    too)</li>
-  <li>John Fleck added a<a href="tutorial/libxslttutorial.html">
-  tutorial</a></li>
+  <li>Fix namespace nodes selection and copy (requires libxml-2.3.11
+    upgradetoo)</li>
+  <li>John Fleck added a<a
+  href="tutorial/libxslttutorial.html">tutorial</a></li>
   <li>Fixes for namespace handling when evaluating variables</li>
-  <li>XInclude global flag added to process XInclude on document() if
-    requested</li>
+  <li>XInclude global flag added to process XInclude on document()
+  ifrequested</li>
   <li>made xsltproc --version more detailed</li>
 </ul>
 
@@ -944,8 +954,8 @@
 <ul>
   <li>cleanups to make stylesheet read-only (not 100% complete)</li>
   <li>fixed URI resolution in document()</li>
-  <li>force all XPath expression to be compiled at stylesheet parsing time,
-    even if unused ...</li>
+  <li>force all XPath expression to be compiled at stylesheet parsing
+    time,even if unused ...</li>
   <li>Fixed HTML default output detection</li>
   <li>Fixed double attribute generation #54446</li>
   <li>Fixed {{ handling in attributes #54451</li>
@@ -955,8 +965,8 @@
   <li>William Brack and Bjorn Reese improved format-number()</li>
   <li>Fixed multiple sort, it should really work now</li>
   <li>added a --docbook option for SGML DocBook input (hackish)</li>
-  <li>a number of other bug fixes and regression test added as people were
-    submitting them</li>
+  <li>a number of other bug fixes and regression test added as people
+    weresubmitting them</li>
 </ul>
 
 <h3>0.9.0: May 3 2001</h3>
@@ -964,10 +974,10 @@
   <li>lot of various bugfixes, extended the regression suite</li>
   <li>xsltproc should work with multiple params</li>
   <li>added an option to use xsltproc with HTML input</li>
-  <li>improved the stylesheet compilation, processing of complex stylesheets
-    should be faster</li>
-  <li>using the same stylesheet for concurrent processing on multithreaded
-    programs should work now</li>
+  <li>improved the stylesheet compilation, processing of complex
+    stylesheetsshould be faster</li>
+  <li>using the same stylesheet for concurrent processing on
+    multithreadedprograms should work now</li>
   <li>fixed another batch of namespace handling problems</li>
   <li>Implemented multiple level of sorting</li>
 </ul>
@@ -977,11 +987,11 @@
   <li>fixed ansidecl.h problem</li>
   <li>fixed unparsed-entity-uri() and generate-id()</li>
   <li>sort semantic fixes and priority prob from William M. Brack</li>
-  <li>fixed namespace handling problems in XPath expression computations
-    (requires libxml-2.3.7)</li>
+  <li>fixed namespace handling problems in XPath expression
+    computations(requires libxml-2.3.7)</li>
   <li>fixes to current() and key()</li>
-  <li>other, smaller fixes, lots of testing with N Walsh DocBook HTML
-    stylesheets</li>
+  <li>other, smaller fixes, lots of testing with N Walsh DocBook
+    HTMLstylesheets</li>
 </ul>
 
 <h3>0.7.0: Apr 10 2001</h3>
@@ -1003,13 +1013,13 @@
 <h3>0.5.0: Mar 10 2001</h3>
 <ul>
   <li>fifth beta</li>
-  <li>some optimization work, for the moment 2 XSLT transform cannot use the
-    same stylesheet at the same time (to be fixed)</li>
+  <li>some optimization work, for the moment 2 XSLT transform cannot use
+    thesame stylesheet at the same time (to be fixed)</li>
   <li>fixed problems with handling of tree results</li>
   <li>fixed a reported strip-spaces problem</li>
   <li>added more reported/fixed bugs to the test suite</li>
-  <li>incorporated William M. Brack fix for imports and global variables as
-    well as patch for with-param support in apply-templates</li>
+  <li>incorporated William M. Brack fix for imports and global variables
+    aswell as patch for with-param support in apply-templates</li>
   <li>a bug fix on for-each</li>
 </ul>
 
@@ -1033,15 +1043,14 @@
 <h3>0.2.0: Feb 15 2001</h3>
 <ul>
   <li>second beta version, released at the same time as libxml2-2.3.1</li>
-  <li>getting close to feature completion, lot of bug fixes, some in the HTML
-    and XPath support of libxml</li>
-  <li>start becoming usable for real work. This version can now regenerate
-    the XML 2e HTML from the original XML sources and the associated
-    stylesheets (in <a
-    href="http://www.w3.org/TR/REC-xml#b4d250b6c21">section I of the XML
-    REC</a>)</li>
-  <li>Still misses extension element/function/prefixes support. Support of
-    key() and document() is not complete</li>
+  <li>getting close to feature completion, lot of bug fixes, some in the
+    HTMLand XPath support of libxml</li>
+  <li>start becoming usable for real work. This version can now regeneratethe
+    XML 2e HTML from the original XML sources and the associatedstylesheets
+    (in <a href="http://www.w3.org/TR/REC-xml#b4d250b6c21">section I of the
+    XMLREC</a>)</li>
+  <li>Still misses extension element/function/prefixes support. Support
+    ofkey() and document() is not complete</li>
 </ul>
 
 <h3>0.1.0: Feb 8 2001</h3>
@@ -1053,19 +1062,19 @@
 <h3>0.0.1: Jan 25 2001</h3>
 <ul>
   <li>first alpha version released at the same time as libxml2-2.2.12</li>
-  <li>Framework in place, should work on simple examples, but far from being
-    feature complete</li>
+  <li>Framework in place, should work on simple examples, but far from
+    beingfeature complete</li>
 </ul>
 
 <h2><a name="xsltproc">The xsltproc tool</a></h2>
 
-<p>This program is the simplest way to use libxslt: from the command line. It
-is also used for doing the regression tests of the library.</p>
+<p>This program is the simplest way to use libxslt: from the command line.
+Itis also used for doing the regression tests of the library.</p>
 
-<p>It takes as first argument the path or URL to an XSLT stylesheet, the next
-arguments are filenames or URIs of the inputs to be processed. The output of
-the processing is redirected on the standard output. There is actually a few
-more options available:</p>
+<p>It takes as first argument the path or URL to an XSLT stylesheet, the
+nextarguments are filenames or URIs of the inputs to be processed. The output
+ofthe processing is redirected on the standard output. There is actually a
+fewmore options available:</p>
 <pre>orchis:~ -&gt; xsltproc
 Usage: xsltproc [options] stylesheet file [file ...]
    Options:
@@ -1092,83 +1101,82 @@
 
 <p><img src="duck.png" align="right" alt="The duck picture"></p>
 
-<p><a href="http://www.oasis-open.org/committees/docbook/">DocBook</a> is an
-XML/SGML vocabulary particularly well suited to books and papers about
-computer hardware and software.</p>
+<p><a href="http://www.oasis-open.org/committees/docbook/">DocBook</a>is
+anXML/SGML vocabulary particularly well suited to books and papers
+aboutcomputer hardware and software.</p>
 
-<p>xsltproc and libxslt are not specifically dependant on DocBook, but since
-a lot of people use xsltproc and libxml2 for DocBook formatting, here are a
-few pointers and informations which may be helpful:</p>
+<p>xsltproc and libxslt are not specifically dependant on DocBook, but sincea
+lot of people use xsltproc and libxml2 for DocBook formatting, here are afew
+pointers and informations which may be helpful:</p>
 <ul>
-  <li>The <a href="http://www.oasis-open.org/committees/docbook/">DocBook
-    homepage at Oasis</a> you should find pointers there on all the lastest
-    versions of the DTDs and XSLT stylesheets</li>
-  <li><a href="http://www.docbook.org/">DocBook: The Definitive Guide</a> is
-    the official reference documentation for DocBook.</li>
+  <li>The <a
+    href="http://www.oasis-open.org/committees/docbook/">DocBookhomepage at
+    Oasis</a>you should find pointers there on all the lastestversions of the
+    DTDs and XSLT stylesheets</li>
+  <li><a href="http://www.docbook.org/">DocBook: The Definitive
+    Guide</a>isthe official reference documentation for DocBook.</li>
   <li><a
-    href="https://sourceforge.net/docman/index.php?group_id=21935">DocBook
-    Open Repository</a> contains a lot of informations about DocBook</li>
-  <li>Bob Stayton provides a <a href="http://www.sagehill.net/">lot of
-    resources</a> and consulting services around DocBook.</li>
-  <li>Here is a <a href="/buildDocBookCatalog">shell script</a> to generate
-    XML Catalogs for DocBook 4.1.2 . If it can write to the /etc/xml/
-    directory, it will set-up /etc/xml/catalog and /etc/xml/docbook based on
-    the resources found on the system. Otherwise it will just create
-    ~/xmlcatalog and ~/dbkxmlcatalog and doing:
+    href="https://sourceforge.net/docman/index.php?group_id=21935">DocBookOpen
+    Repository</a>contains a lot of informations about DocBook</li>
+  <li>Bob Stayton provides a <a href="http://www.sagehill.net/">lot
+    ofresources</a>and consulting services around DocBook.</li>
+  <li>Here is a <a href="/buildDocBookCatalog">shell script</a>to generateXML
+    Catalogs for DocBook 4.1.2 . If it can write to the /etc/xml/directory,
+    it will set-up /etc/xml/catalog and /etc/xml/docbook based onthe
+    resources found on the system. Otherwise it will just create~/xmlcatalog
+    and ~/dbkxmlcatalog and doing:
     <p><code>export XMLCATALOG=$HOME/xmlcatalog</code></p>
-    <p>should allow to process DocBook documentations without requiring
-    network accesses for the DTd or stylesheets</p>
+    <p>should allow to process DocBook documentations without
+    requiringnetwork accesses for the DTd or stylesheets</p>
   </li>
-  <li>I have uploaded <a href="ftp://xmlsoft.org/libxml2/test/dbk412catalog.tar.gz">a
-    small tarball</a> containing XML Catalogs for DocBook 4.1.2 which seems
-    to work fine for me too</li>
+  <li>I have uploaded <a
+    href="ftp://xmlsoft.org/libxml2/test/dbk412catalog.tar.gz">asmall
+    tarball</a>containing XML Catalogs for DocBook 4.1.2 which seemsto work
+    fine for me too</li>
   <li>Informations on installing a <a
-    href="http://ourworld.compuserve.com/homepages/hoenicka_markus/ntsgml.html">Windows
-    DocBook processing setup</a> based on Cygwin (using the binaries from the
-    official Windows port should be possible too)</li>
+    href="http://ourworld.compuserve.com/homepages/hoenicka_markus/ntsgml.html">WindowsDocBook
+    processing setup</a>based on Cygwin (using the binaries from theofficial
+    Windows port should be possible too)</li>
   <li>Alexander Kirillov's page on <a
-    href="http://www.math.sunysb.edu/~kirillov/dbxml/">Using DocBook XML
-    4.1.2</a> (RPM packages)</li>
-  <li>Tim Waugh's <a href="http://cyberelk.net/tim/xmlto/">xmlto front-end
-    conversion script</a></li>
+    href="http://www.math.sunysb.edu/~kirillov/dbxml/">Using DocBook
+    XML4.1.2</a>(RPM packages)</li>
+  <li>Tim Waugh's <a href="http://cyberelk.net/tim/xmlto/">xmlto
+    front-endconversion script</a></li>
   <li>Linux Documentation Project <a
-    href="http://www.linuxdoc.org/HOWTO/mini/DocBook-Install/">
-    DocBook-Install-mini-HOWTO</a></li>
+    href="http://www.linuxdoc.org/HOWTO/mini/DocBook-Install/">DocBook-Install-mini-HOWTO</a></li>
   <li>ScrollKeeper the open documentation cataloging project has a <a
-    href="http://scrollkeeper.sourceforge.net/docbook.shtml">DocBook
-    section</a></li>
+    href="http://scrollkeeper.sourceforge.net/docbook.shtml">DocBooksection</a></li>
   <li>Dan York presentation on <a
-    href="http://www.lodestar2.com/people/dyork/talks/2001/xugo/docbook/index.html">Publishing
-    using DocBook XML</a></li>
+    href="http://www.lodestar2.com/people/dyork/talks/2001/xugo/docbook/index.html">Publishingusing
+    DocBook XML</a></li>
 </ul>
 
-<p>Do not use the --docbook option of xsltproc to process XML DocBook
-documents, this option is only intended to provide some (limited) support of
-the SGML version of DocBook.</p>
+<p>Do not use the --docbook option of xsltproc to process XML
+DocBookdocuments, this option is only intended to provide some (limited)
+support ofthe SGML version of DocBook.</p>
 
-<p>Points which are not DocBook specific but still worth mentionning
-again:</p>
+<p>Points which are not DocBook specific but still worth mentionningagain:</p>
 <ul>
-  <li>if you think DocBook processing time is too slow, make sure you have
-    XML Catalogs pointing to a local installation of the DTD of DocBook.
-    Check the <a href="http://xmlsoft.org/catalog.html">XML Catalog page</a>
-    to understand more on this subject.</li>
+  <li>if you think DocBook processing time is too slow, make sure you haveXML
+    Catalogs pointing to a local installation of the DTD of DocBook.Check the
+    <a href="http://xmlsoft.org/catalog.html">XML Catalog page</a>to
+    understand more on this subject.</li>
   <li>before processing a new document, use the command
     <p><code>xmllint --valid --noout path_to_document</code></p>
-    <p>to make sure that your input is valid DocBook. And fixes the errors
-    before processing further. Note that XSLT processing may work correctly
-    with some forms of validity errors left, but in general it can give
-    troubles on output.</p>
+    <p>to make sure that your input is valid DocBook. And fixes the
+    errorsbefore processing further. Note that XSLT processing may work
+    correctlywith some forms of validity errors left, but in general it can
+    givetroubles on output.</p>
   </li>
 </ul>
 
 <h2><a name="API">The programming API</a></h2>
 
-<p>Okay this section is clearly incomplete. But integrating libxslt into your
-application should be relatively easy. First check the few steps described
-below, then for more detailed informations, look at the<a
-href="html/libxslt-lib.html"> generated pages</a> for the API and the source
-of libxslt/xsltproc.c  and the  <a
+<p>Okay this section is clearly incomplete. But integrating libxslt into
+yourapplication should be relatively easy. First check the few steps
+describedbelow, then for more detailed informations, look at the<a
+href="html/libxslt-lib.html">generated pages</a>for the API and the sourceof
+libxslt/xsltproc.c  and the  <a
 href="tutorial/libxslttutorial.html">tutorial</a>.</p>
 
 <p>Basically doing an XSLT transformation can be done in a few steps:</p>
@@ -1180,101 +1188,100 @@
   <li>parse the stylesheet with xsltParseStylesheetFile()</li>
   <li>parse the document with xmlParseFile()</li>
   <li>apply the stylesheet using xsltApplyStylesheet()</li>
-  <li>save the result using xsltSaveResultToFile() if needed set
-    xmlIndentTreeOutput to 1</li>
+  <li>save the result using xsltSaveResultToFile() if needed
+    setxmlIndentTreeOutput to 1</li>
 </ol>
 
-<p>Steps 2,3, and 5 will probably need to be changed depending on you
-processing needs and environment for example if reading/saving from/to
-memory, or if you want to apply XInclude processing to the stylesheet or
-input documents.</p>
+<p>Steps 2,3, and 5 will probably need to be changed depending on
+youprocessing needs and environment for example if reading/saving
+from/tomemory, or if you want to apply XInclude processing to the stylesheet
+orinput documents.</p>
 
 <h2><a name="Python">Python and bindings</a></h2>
 
-<p>There is a number of language bindings and wrappers available for libxml2,
-the list below is not exhaustive. Please contact the <a
-href="http://mail.gnome.org/mailman/listinfo/xml-bindings">xml-bindings at gnome.org</a>
-(<a href="http://mail.gnome.org/archives/xml-bindings/">archives</a>) in
-order to get updates to this list or to discuss the specific topic of libxml2
-or libxslt wrappers or bindings:</p>
+<p>There is a number of language bindings and wrappers available for
+libxml2,the list below is not exhaustive. Please contact the <a
+href="http://mail.gnome.org/mailman/listinfo/xml-bindings">xml-bindings at gnome.org</a>(<a
+href="http://mail.gnome.org/archives/xml-bindings/">archives</a>) inorder to
+get updates to this list or to discuss the specific topic of libxml2or
+libxslt wrappers or bindings:</p>
 <ul>
   <li><a
-    href="http://mail.gnome.org/archives/xml/2001-March/msg00014.html">Matt
-    Sergeant</a> developped <a href="http://axkit.org/download/">XML::LibXML
-    and XML::LibXSLT</a>, Perl wrappers for libxml2/libxslt as part of the <a
+    href="http://mail.gnome.org/archives/xml/2001-March/msg00014.html">MattSergeant</a>developped
+    <a href="http://axkit.org/download/">XML::LibXMLand XML::LibXSLT</a>,
+    Perl wrappers for libxml2/libxslt as part of the <a
     href="http://axkit.com/">AxKit XML application server</a></li>
-  <li><a href="mailto:dkuhlman at cutter.rexx.com">Dave Kuhlman</a> provides and
-    earlier version of the libxml/libxslt <a
+  <li><a href="mailto:dkuhlman at cutter.rexx.com">Dave Kuhlman</a>provides
+    andearlier version of the libxml/libxslt <a
     href="http://www.rexx.com/~dkuhlman">wrappers for Python</a></li>
   <li>Petr Kozelka provides <a
-    href="http://sourceforge.net/projects/libxml2-pas">Pascal units to glue
-    libxml2</a> with Kylix, Delphi and other Pascal compilers</li>
+    href="http://sourceforge.net/projects/libxml2-pas">Pascal units to
+    gluelibxml2</a>with Kylix, Delphi and other Pascal compilers</li>
   <li>Wai-Sun "Squidster" Chia provides <a
-    href="http://www.rubycolor.org/arc/redist/">bindings for Ruby</a>  and
-    libxml2 bindings are also available in Ruby through the <a
-    href="http://libgdome-ruby.berlios.de/">libgdome-ruby</a> module
-    maintained by Tobias Peters.</li>
+    href="http://www.rubycolor.org/arc/redist/">bindings for
+    Ruby</a>andlibxml2 bindings are also available in Ruby through the <a
+    href="http://libgdome-ruby.berlios.de/">libgdome-ruby</a>modulemaintained
+    by Tobias Peters.</li>
   <li>Steve Ball and contributors maintains <a
-    href="http://tclxml.sourceforge.net/">libxml2 and libxslt bindings for
-    Tcl</a></li>
-  <li><a href="mailto:xmlwrapp at pmade.org">Peter Jones</a> maintains C++
-    bindings for libxslt within <a
+    href="http://tclxml.sourceforge.net/">libxml2 and libxslt bindings
+    forTcl</a></li>
+  <li><a href="mailto:xmlwrapp at pmade.org">Peter Jones</a>maintains
+    C++bindings for libxslt within <a
     href="http://pmade.org/pjones/software/xmlwrapp/">xmlwrapp</a></li>
-  <li><a href="phillim2 at comcast.net">Mike Phillips</a> provides a module
-    using <a href="http://siasl.dyndns.org/projects/projects.html">libxslt
-    for PHP</a>.</li>
-  <li><a href="http://savannah.gnu.org/projects/classpathx/">LibxmlJ</a> is
-    an effort to create a 100% JAXP-compatible Java wrapper for libxml2 and
-    libxslt as part of GNU ClasspathX project.</li>
-  <li>Patrick McPhee provides Rexx bindings fof libxml2 and libxslt, look for
-    <a href="http://www.interlog.com/~ptjm/software.html">RexxXML</a>.</li>
+  <li><a href="phillim2 at comcast.net">Mike Phillips</a>provides a moduleusing
+    <a href="http://siasl.dyndns.org/projects/projects.html">libxsltfor
+    PHP</a>.</li>
+  <li><a href="http://savannah.gnu.org/projects/classpathx/">LibxmlJ</a>isan
+    effort to create a 100% JAXP-compatible Java wrapper for libxml2
+    andlibxslt as part of GNU ClasspathX project.</li>
+  <li>Patrick McPhee provides Rexx bindings fof libxml2 and libxslt, look
+    for<a href="http://www.interlog.com/~ptjm/software.html">RexxXML</a>.</li>
   <li><a
-    href="http://www.satimage.fr/software/en/xml_suite.html">Satimage</a>
-    provides <a
-    href="http://www.satimage.fr/software/en/downloads_osaxen.html">XMLLib
-    osax</a>. This is an osax for Mac OS X with a set of commands to
-    implement in AppleScript the XML DOM, XPATH and XSLT.</li>
+    href="http://www.satimage.fr/software/en/xml_suite.html">Satimage</a>provides
+    <a
+    href="http://www.satimage.fr/software/en/downloads_osaxen.html">XMLLibosax</a>.
+    This is an osax for Mac OS X with a set of commands toimplement in
+    AppleScript the XML DOM, XPATH and XSLT.</li>
 </ul>
 
 <p>The libxslt Python module depends on the <a
-href="http://xmlsoft.org/python.html">libxml2 Python</a> module.</p>
+href="http://xmlsoft.org/python.html">libxml2 Python</a>module.</p>
 
-<p>The distribution includes a set of Python bindings, which are garanteed to
-be maintained as part of the library in the future, though the Python
-interface have not yet reached the completeness of the C API.</p>
+<p>The distribution includes a set of Python bindings, which are garanteed
+tobe maintained as part of the library in the future, though the
+Pythoninterface have not yet reached the completeness of the C API.</p>
 
-<p><a href="mailto:stephane.bidoul at softwareag.com">Stéphane Bidoul</a>
-maintains <a href="http://users.skynet.be/sbi/libxml-python/">a Windows port
-of the Python bindings</a>.</p>
+<p><a href="mailto:stephane.bidoul at softwareag.com">Stéphane
+Bidoul</a>maintains <a href="http://users.skynet.be/sbi/libxml-python/">a
+Windows portof the Python bindings</a>.</p>
 
-<p>Note to people interested in building bindings, the API is formalized as
-<a href="libxslt-api.xml">an XML API description file</a> which allows to
-automate a large part of the Python bindings, this includes function
-descriptions, enums, structures, typedefs, etc... The Python script used to
-build the bindings is python/generator.py in the source distribution.</p>
+<p>Note to people interested in building bindings, the API is formalized as<a
+href="libxslt-api.xml">an XML API description file</a>which allows toautomate
+a large part of the Python bindings, this includes functiondescriptions,
+enums, structures, typedefs, etc... The Python script used tobuild the
+bindings is python/generator.py in the source distribution.</p>
 
 <p>To install the Python bindings there are 2 options:</p>
 <ul>
   <li>If you use an RPM based distribution, simply install the <a
-    href="http://rpmfind.net/linux/rpm2html/search.php?query=libxml2-python">libxml2-python
-    RPM</a> and the <a
-    href="http://rpmfind.net/linux/rpm2html/search.php?query=libxslt-python">libxslt-python
-    RPM</a>.</li>
-  <li>Otherwise use the <a href="ftp://xmlsoft.org/libxml2/python/">libxml2-python
-    module distribution</a> corresponding to your installed version of
-    libxml2 and libxslt. Note that to install it you will need both libxml2
-    and libxslt installed and run "python setup.py build install" in the
-    module tree.</li>
+    href="http://rpmfind.net/linux/rpm2html/search.php?query=libxml2-python">libxml2-pythonRPM</a>and
+    the <a
+    href="http://rpmfind.net/linux/rpm2html/search.php?query=libxslt-python">libxslt-pythonRPM</a>.</li>
+  <li>Otherwise use the <a
+    href="ftp://xmlsoft.org/libxml2/python/">libxml2-pythonmodule
+    distribution</a>corresponding to your installed version oflibxml2 and
+    libxslt. Note that to install it you will need both libxml2and libxslt
+    installed and run "python setup.py build install" in themodule tree.</li>
 </ul>
 
-<p>The distribution includes a set of examples and regression tests for the
-python bindings in the <code>python/tests</code> directory. Here are some
-excepts from those tests:</p>
+<p>The distribution includes a set of examples and regression tests for
+thepython bindings in the <code>python/tests</code>directory. Here are
+someexcepts from those tests:</p>
 
 <h3>basic.py:</h3>
 
-<p>This is a basic test of XSLT interfaces: loading a stylesheet and a
-document, transforming the document and saving the result.</p>
+<p>This is a basic test of XSLT interfaces: loading a stylesheet and
+adocument, transforming the document and saving the result.</p>
 <pre>import libxml2
 import libxslt
 
@@ -1287,36 +1294,36 @@
 doc.freeDoc()
 result.freeDoc()</pre>
 
-<p>The Python module is called libxslt, you will also need the libxml2 module
-for the operations on XML trees. Let's have a look at the objects manipulated
-in that example and how is the processing done:</p>
+<p>The Python module is called libxslt, you will also need the libxml2
+modulefor the operations on XML trees. Let's have a look at the objects
+manipulatedin that example and how is the processing done:</p>
 <ul>
-  <li><code>styledoc</code> : is a libxml2 document tree. It is obtained by
-    parsing the XML file "test.xsl" containing the stylesheet.</li>
-  <li><code>style</code> : this is a precompiled stylesheet ready to be used
-    by the following transformations (note the plural form, multiple
-    transformations can resuse the same stylesheet).</li>
-  <li><code>doc</code> : this is the document to apply the transformation to.
-    In this case it is simply generated by parsing it from a file but any
-    other processing is possible as long as one get a libxml2 Doc. Note that
-    HTML tree are suitable for XSLT processing in libxslt. This is actually
-    how this page is generated !</li>
-  <li><code>result</code> : this is a document generated by applying the
-    stylesheet to the document. Note that some of the stylesheet informations
-    may be related to the serialization of that document and as in this
-    example a specific saveResultToFilename() method of the stylesheet should
-    be used to save it to a file (in that case to "foo").</li>
+  <li><code>styledoc</code>: is a libxml2 document tree. It is obtained
+    byparsing the XML file "test.xsl" containing the stylesheet.</li>
+  <li><code>style</code>: this is a precompiled stylesheet ready to be usedby
+    the following transformations (note the plural form,
+    multipletransformations can resuse the same stylesheet).</li>
+  <li><code>doc</code>: this is the document to apply the transformation
+    to.In this case it is simply generated by parsing it from a file but
+    anyother processing is possible as long as one get a libxml2 Doc. Note
+    thatHTML tree are suitable for XSLT processing in libxslt. This is
+    actuallyhow this page is generated !</li>
+  <li><code>result</code>: this is a document generated by applying
+    thestylesheet to the document. Note that some of the stylesheet
+    informationsmay be related to the serialization of that document and as
+    in thisexample a specific saveResultToFilename() method of the stylesheet
+    shouldbe used to save it to a file (in that case to "foo").</li>
 </ul>
 
-<p>Also note the need to explicitely deallocate documents with freeDoc()
-except for the stylesheet document which is freed when its compiled form is
-garbage collected.</p>
+<p>Also note the need to explicitely deallocate documents with
+freeDoc()except for the stylesheet document which is freed when its compiled
+form isgarbage collected.</p>
 
 <h3>extfunc.py:</h3>
 
-<p>This one is a far more complex test. It shows how to modify the behaviour
-of an XSLT transformation by passing parameters and how to extend the XSLT
-engine with functions defined in python:</p>
+<p>This one is a far more complex test. It shows how to modify the
+behaviourof an XSLT transformation by passing parameters and how to extend
+the XSLTengine with functions defined in python:</p>
 <pre>import libxml2
 import libxslt
 import string
@@ -1340,22 +1347,22 @@
 
 libxslt.registerExtModuleFunction("foo", "http://example.com/foo", f)</pre>
 
-<p>This code defines and register an extension function. Note that the
-function can be bound to any name (foo) and how the binding is also
-associated to a namespace name "http://example.com/foo". From an XSLT point
-of view the function just returns an upper case version of the string passed
-as a parameter. But the first part of the function also read some contextual
-information from the current XSLT processing environement, in that case it
-looks for the current insertion node in the resulting output (either the
-resulting document or the Result Value Tree being generated), and saves it to
-a global variable for checking that the access actually worked.</p>
+<p>This code defines and register an extension function. Note that
+thefunction can be bound to any name (foo) and how the binding is
+alsoassociated to a namespace name "http://example.com/foo". From an XSLT
+pointof view the function just returns an upper case version of the string
+passedas a parameter. But the first part of the function also read some
+contextualinformation from the current XSLT processing environement, in that
+case itlooks for the current insertion node in the resulting output (either
+theresulting document or the Result Value Tree being generated), and saves it
+toa global variable for checking that the access actually worked.</p>
 
-<p>For more informations on the xpathParserContext and transformContext
-objects check the <a href="internals.html">libray internals description</a>.
-The pctxt is actually an object from a class derived from the
-libxml2.xpathParserContext() with just a couple more properties including the
-possibility to look up the XSLT transformation context from the XPath
-context.</p>
+<p>For more informations on the xpathParserContext and
+transformContextobjects check the <a href="internals.html">libray internals
+description</a>.The pctxt is actually an object from a class derived from
+thelibxml2.xpathParserContext() with just a couple more properties including
+thepossibility to look up the XSLT transformation context from the
+XPathcontext.</p>
 <pre>styledoc = libxml2.parseDoc("""
 &lt;xsl:stylesheet version='1.0'
   xmlns:xsl='http://www.w3.org/1999/XSL/Transform'
@@ -1369,13 +1376,13 @@
 &lt;/xsl:stylesheet&gt;
 """)</pre>
 
-<p>Here is a simple example of how to read an XML document from a python
-string with libxml2. Note how this stylesheet:</p>
+<p>Here is a simple example of how to read an XML document from a
+pythonstring with libxml2. Note how this stylesheet:</p>
 <ul>
   <li>Uses a global parameter <code>bar</code></li>
   <li>Reference the extension function f</li>
-  <li>how the Namespace name "http://example.com/foo" has to be bound to a
-    prefix</li>
+  <li>how the Namespace name "http://example.com/foo" has to be bound to
+    aprefix</li>
   <li>how that prefix is excluded from the output</li>
   <li>how the function is called from the select</li>
 </ul>
@@ -1385,10 +1392,10 @@
 style.freeStylesheet()
 doc.freeDoc()</pre>
 
-<p>that part is identical, to the basic example except that the
-transformation is passed a dictionnary of parameters. Note that the string
-passed "success" had to be quoted, otherwise it is interpreted as an XPath
-query for the childs of root named "success".</p>
+<p>that part is identical, to the basic example except that thetransformation
+is passed a dictionnary of parameters. Note that the stringpassed "success"
+had to be quoted, otherwise it is interpreted as an XPathquery for the childs
+of root named "success".</p>
 <pre>root = result.children
 if root.name != "article":
     print "Unexpected root node name"
@@ -1402,22 +1409,24 @@
 
 result.freeDoc()</pre>
 
-<p>That part just verifies that the transformation worked, that the parameter
-got properly passed to the engine, that the function f() got called and that
-it properly accessed the context to find the name of the insertion node.</p>
+<p>That part just verifies that the transformation worked, that the
+parametergot properly passed to the engine, that the function f() got called
+and thatit properly accessed the context to find the name of the insertion
+node.</p>
 
 <h3>pyxsltproc.py:</h3>
 
-<p>this module is a bit too long to be described there but it is basically a
-rewrite of the xsltproc command line interface of libxslt in Python. It
-provides nearly all the functionalities of xsltproc and can be used as a base
-module to write Python customized XSLT processors. One of the thing to notice
-are:</p>
+<p>this module is a bit too long to be described there but it is basically
+arewrite of the xsltproc command line interface of libxslt in Python.
+Itprovides nearly all the functionalities of xsltproc and can be used as a
+basemodule to write Python customized XSLT processors. One of the thing to
+noticeare:</p>
 <pre>libxml2.lineNumbersDefault(1)
 libxml2.substituteEntitiesDefault(1)</pre>
 
-<p>those two calls in the main() function are needed to force the libxml2
-processor to generate DOM trees compliant with the XPath data model.</p>
+<p>those two calls in the main() function are needed to force the
+libxml2processor to generate DOM trees compliant with the XPath data
+model.</p>
 
 <h2><a name="Internals">Library internals</a></h2>
 
@@ -1433,8 +1442,7 @@
   <li><a href="internals.html#processing">The processing itself</a></li>
   <li><a href="internals.html#XPath">XPath expressions compilation</a></li>
   <li><a href="internals.html#XPath1">XPath interpretation</a></li>
-  <li><a href="internals.html#Descriptio">Description of XPath
-  Objects</a></li>
+  <li><a href="internals.html#Descriptio">Description of XPathObjects</a></li>
   <li><a href="internals.html#XPath3">XPath functions</a></li>
   <li><a href="internals.html#stack">The variables stack frame</a></li>
   <li><a href="internals.html#Extension">Extension support</a></li>
@@ -1446,246 +1454,248 @@
 
 <p>This document describes the processing of <a
 href="http://xmlsoft.org/XSLT/">libxslt</a>, the <a
-href="http://www.w3.org/TR/xslt">XSLT</a> C library developed for the <a
-href="http://www.gnome.org/">Gnome</a> project.</p>
+href="http://www.w3.org/TR/xslt">XSLT</a>C library developed for the <a
+href="http://www.gnome.org/">Gnome</a>project.</p>
 
-<p>Note: this documentation is by definition incomplete and I am not good at
-spelling, grammar, so patches and suggestions are <a
+<p>Note: this documentation is by definition incomplete and I am not good
+atspelling, grammar, so patches and suggestions are <a
 href="mailto:veillard at redhat.com">really welcome</a>.</p>
 
 <h3><a name="Basics1">Basics</a></h3>
 
-<p>XSLT is a transformation language. It takes an input document and a
-stylesheet document and generates an output document:</p>
+<p>XSLT is a transformation language. It takes an input document and
+astylesheet document and generates an output document:</p>
 
 <p align="center"><img src="processing.gif"
 alt="the XSLT processing model"></p>
 
 <p>Libxslt is written in C. It relies on <a
-href="http://www.xmlsoft.org/">libxml</a>, the XML C library for Gnome, for
-the following operations:</p>
+href="http://www.xmlsoft.org/">libxml</a>, the XML C library for Gnome,
+forthe following operations:</p>
 <ul>
   <li>parsing files</li>
-  <li>building the in-memory DOM structure associated with the documents
-    handled</li>
+  <li>building the in-memory DOM structure associated with the
+    documentshandled</li>
   <li>the XPath implementation</li>
-  <li>serializing back the result document to XML and HTML. (Text is handled
-    directly.)</li>
+  <li>serializing back the result document to XML and HTML. (Text is
+    handleddirectly.)</li>
 </ul>
 
 <h3><a name="Keep1">Keep it simple stupid</a></h3>
 
-<p>Libxslt is not very specialized. It is built under the assumption that all
-nodes from the source and output document can fit in the virtual memory of
-the system. There is a big trade-off there. It is fine for reasonably sized
-documents but may not be suitable for large sets of data. The gain is that it
-can be used in a relatively versatile way. The input or output may never be
-serialized, but the size of documents it can handle are limited by the size
-of the memory available.</p>
+<p>Libxslt is not very specialized. It is built under the assumption that
+allnodes from the source and output document can fit in the virtual memory
+ofthe system. There is a big trade-off there. It is fine for reasonably
+sizeddocuments but may not be suitable for large sets of data. The gain is
+that itcan be used in a relatively versatile way. The input or output may
+never beserialized, but the size of documents it can handle are limited by
+the sizeof the memory available.</p>
 
-<p>More specialized memory handling approaches are possible, like building
-the input tree from a serialization progressively as it is consumed,
-factoring repetitive patterns, or even on-the-fly generation of the output as
-the input is parsed but it is possible only for a limited subset of the
-stylesheets. In general the implementation of libxslt follows the following
-pattern:</p>
+<p>More specialized memory handling approaches are possible, like buildingthe
+input tree from a serialization progressively as it is consumed,factoring
+repetitive patterns, or even on-the-fly generation of the output asthe input
+is parsed but it is possible only for a limited subset of thestylesheets. In
+general the implementation of libxslt follows the followingpattern:</p>
 <ul>
   <li>KISS (keep it simple stupid)</li>
-  <li>when there is a clear bottleneck optimize on top of this simple
-    framework and refine only as much as is needed to reach the expected
-    result</li>
+  <li>when there is a clear bottleneck optimize on top of this
+    simpleframework and refine only as much as is needed to reach the
+    expectedresult</li>
 </ul>
 
-<p>The result is not that bad, clearly one can do a better job but more
-specialized too. Most optimization like building the tree on-demand would
-need serious changes to the libxml XPath framework. An easy step would be to
-serialize the output directly (or call a set of SAX-like output handler to
-keep this a flexible interface) and hence avoid the memory consumption of the
-result.</p>
+<p>The result is not that bad, clearly one can do a better job but
+morespecialized too. Most optimization like building the tree on-demand
+wouldneed serious changes to the libxml XPath framework. An easy step would
+be toserialize the output directly (or call a set of SAX-like output handler
+tokeep this a flexible interface) and hence avoid the memory consumption of
+theresult.</p>
 
 <h3><a name="libxml">The libxml nodes</a></h3>
 
-<p>DOM-like trees, as used and generated by libxml and libxslt, are
-relatively complex. Most node types follow the given structure except a few
-variations depending on the node type:</p>
+<p>DOM-like trees, as used and generated by libxml and libxslt, arerelatively
+complex. Most node types follow the given structure except a fewvariations
+depending on the node type:</p>
 
 <p align="center"><img src="node.gif" alt="description of a libxml node"></p>
 
-<p>Nodes carry a <strong>name</strong> and the node <strong>type</strong>
-indicates the kind of node it represents, the most common ones are:</p>
+<p>Nodes carry a <strong>name</strong>and the node
+<strong>type</strong>indicates the kind of node it represents, the most
+common ones are:</p>
 <ul>
   <li>document nodes</li>
   <li>element nodes</li>
   <li>text nodes</li>
 </ul>
 
-<p>For the XSLT processing, entity nodes should not be generated (i.e. they
-should be replaced by their content). Most nodes also contains the following
-"navigation" informations:</p>
+<p>For the XSLT processing, entity nodes should not be generated (i.e.
+theyshould be replaced by their content). Most nodes also contains the
+following"navigation" informations:</p>
 <ul>
   <li>the containing <strong>doc</strong>ument</li>
-  <li>the <strong>parent</strong> node</li>
-  <li>the first <strong>children</strong> node</li>
-  <li>the <strong>last</strong> children node</li>
+  <li>the <strong>parent</strong>node</li>
+  <li>the first <strong>children</strong>node</li>
+  <li>the <strong>last</strong>children node</li>
   <li>the <strong>prev</strong>ious sibling</li>
   <li>the following sibling (<strong>next</strong>)</li>
 </ul>
 
-<p>Elements nodes carries the list of attributes in the properties, an
-attribute itself holds the navigation pointers and the children list (the
-attribute value is not represented as a simple string to allow usage of
-entities references).</p>
+<p>Elements nodes carries the list of attributes in the properties,
+anattribute itself holds the navigation pointers and the children list
+(theattribute value is not represented as a simple string to allow usage
+ofentities references).</p>
 
-<p>The <strong>ns</strong> points to the namespace declaration for the
-namespace associated to the node, <strong>nsDef</strong> is the linked list
-of namespace declaration present on element nodes.</p>
+<p>The <strong>ns</strong>points to the namespace declaration for
+thenamespace associated to the node, <strong>nsDef</strong>is the linked
+listof namespace declaration present on element nodes.</p>
 
-<p>Most nodes also carry an <strong>_private</strong> pointer which can be
-used by the application to hold specific data on this node.</p>
+<p>Most nodes also carry an <strong>_private</strong>pointer which can beused
+by the application to hold specific data on this node.</p>
 
 <h3><a name="XSLT">The XSLT processing steps</a></h3>
 
-<p>There are a few steps which are clearly decoupled at the interface
-level:</p>
+<p>There are a few steps which are clearly decoupled at the
+interfacelevel:</p>
 <ol>
   <li>parse the stylesheet and generate a DOM tree</li>
-  <li>take the stylesheet tree and build a compiled version of it (the
-    compilation phase)</li>
+  <li>take the stylesheet tree and build a compiled version of it
+    (thecompilation phase)</li>
   <li>take the input and generate a DOM tree</li>
-  <li>process the stylesheet against the input tree and generate an output
-    tree</li>
+  <li>process the stylesheet against the input tree and generate an
+  outputtree</li>
   <li>serialize the output tree</li>
 </ol>
 
 <p>A few things should be noted here:</p>
 <ul>
   <li>the steps 1/ 3/ and 5/ are optional</li>
-  <li>the stylesheet obtained at 2/ can be reused by multiple processing 4/
-    (and this should also work in threaded programs)</li>
-  <li>the tree provided in 2/ should never be freed using xmlFreeDoc, but by
-    freeing the stylesheet.</li>
-  <li>the input tree 4/ is not modified except the _private field which may
-    be used for labelling keys if used by the stylesheet</li>
+  <li>the stylesheet obtained at 2/ can be reused by multiple processing
+    4/(and this should also work in threaded programs)</li>
+  <li>the tree provided in 2/ should never be freed using xmlFreeDoc, but
+    byfreeing the stylesheet.</li>
+  <li>the input tree 4/ is not modified except the _private field which maybe
+    used for labelling keys if used by the stylesheet</li>
 </ul>
 
 <h3><a name="XSLT1">The XSLT stylesheet compilation</a></h3>
 
-<p>This is the second step described. It takes a stylesheet tree, and
-"compiles" it. This associates to each node a structure stored in the
-_private field and containing information computed in the stylesheet:</p>
+<p>This is the second step described. It takes a stylesheet tree,
+and"compiles" it. This associates to each node a structure stored in
+the_private field and containing information computed in the stylesheet:</p>
 
 <p align="center"><img src="stylesheet.gif"
 alt="a compiled XSLT stylesheet"></p>
 
-<p>One xsltStylesheet structure is generated per document parsed for the
-stylesheet. XSLT documents allow includes and imports of other documents,
-imports are stored in the <strong>imports</strong> list (hence keeping the
-tree hierarchy of includes which is very important for a proper XSLT
-processing model) and includes are stored in the <strong>doclist</strong>
-list. An imported stylesheet has a parent link to allow browsing of the
-tree.</p>
+<p>One xsltStylesheet structure is generated per document parsed for
+thestylesheet. XSLT documents allow includes and imports of other
+documents,imports are stored in the <strong>imports</strong>list (hence
+keeping thetree hierarchy of includes which is very important for a proper
+XSLTprocessing model) and includes are stored in the
+<strong>doclist</strong>list. An imported stylesheet has a parent link to
+allow browsing of thetree.</p>
 
-<p>The DOM tree associated to the document is stored in <strong>doc</strong>.
-It is preprocessed to remove ignorable empty nodes and all the nodes in the
-XSLT namespace are subject to precomputing. This usually consist of
-extracting all the context information from the context tree (attributes,
-namespaces, XPath expressions), and storing them in an xsltStylePreComp
-structure associated to the <strong>_private</strong> field of the node.</p>
+<p>The DOM tree associated to the document is stored in
+<strong>doc</strong>.It is preprocessed to remove ignorable empty nodes and
+all the nodes in theXSLT namespace are subject to precomputing. This usually
+consist ofextracting all the context information from the context tree
+(attributes,namespaces, XPath expressions), and storing them in an
+xsltStylePreCompstructure associated to the <strong>_private</strong>field of
+the node.</p>
 
-<p>A couple of notable exceptions to this are XSLT template nodes (more on
-this later) and attribute value templates. If they are actually templates,
-the value cannot be computed at compilation time. (Some preprocessing could
-be done like isolation and preparsing of the XPath subexpressions but it's
-not done, yet.)</p>
+<p>A couple of notable exceptions to this are XSLT template nodes (more
+onthis later) and attribute value templates. If they are actually
+templates,the value cannot be computed at compilation time. (Some
+preprocessing couldbe done like isolation and preparsing of the XPath
+subexpressions but it'snot done, yet.)</p>
 
-<p>The xsltStylePreComp structure also allows storing of the precompiled form
-of an XPath expression that can be associated to an XSLT element (more on
-this later).</p>
+<p>The xsltStylePreComp structure also allows storing of the precompiled
+formof an XPath expression that can be associated to an XSLT element (more
+onthis later).</p>
 
 <h3><a name="XSLT2">The XSLT template compilation</a></h3>
 
-<p>A proper handling of templates lookup is one of the keys of fast XSLT
-processing. (Given a node in the source document this is the process of
-finding which templates should be applied to this node.) Libxslt follows the
-hint suggested in the <a href="http://www.w3.org/TR/xslt#patterns">5.2
-Patterns</a> section of the XSLT Recommendation, i.e. it doesn't evaluate it
-as an XPath expression but tokenizes it and compiles it as a set of rules to
-be evaluated on a candidate node. There usually is an indication of the node
-name in the last step of this evaluation and this is used as a key check for
-the match. As a result libxslt builds a relatively more complex set of
-structures for the templates:</p>
+<p>A proper handling of templates lookup is one of the keys of fast
+XSLTprocessing. (Given a node in the source document this is the process
+offinding which templates should be applied to this node.) Libxslt follows
+thehint suggested in the <a
+href="http://www.w3.org/TR/xslt#patterns">5.2Patterns</a>section of the XSLT
+Recommendation, i.e. it doesn't evaluate itas an XPath expression but
+tokenizes it and compiles it as a set of rules tobe evaluated on a candidate
+node. There usually is an indication of the nodename in the last step of this
+evaluation and this is used as a key check forthe match. As a result libxslt
+builds a relatively more complex set ofstructures for the templates:</p>
 
 <p align="center"><img src="templates.gif"
 alt="The templates related structure"></p>
 
-<p>Let's describe a bit more closely what is built. First the xsltStylesheet
-structure holds a pointer to the template hash table. All the XSLT patterns
-compiled in this stylesheet are indexed by the value of the the target
-element (or attribute, pi ...) name, so when a element or an attribute "foo"
-needs to be processed the lookup is done using the name as a key.</p>
+<p>Let's describe a bit more closely what is built. First the
+xsltStylesheetstructure holds a pointer to the template hash table. All the
+XSLT patternscompiled in this stylesheet are indexed by the value of the the
+targetelement (or attribute, pi ...) name, so when a element or an attribute
+"foo"needs to be processed the lookup is done using the name as a key.</p>
 
-<p>Each of the patterns is compiled into an xsltCompMatch structure. It holds
-the set of rules based on the tokenization of the pattern stored in reverse
-order (matching is easier this way). It also holds some information about the
-previous matches used to speed up the process when one iterates over a set of
-siblings. (This optimization may be defeated by trashing when running
-threaded computation, it's unclear that this is a big deal in practice.)
-Predicate expressions are not compiled at this stage, they may be at run-time
-if needed, but in this case they are compiled as full XPath expressions (the
-use of some fixed predicate can probably be optimized, they are not yet).</p>
+<p>Each of the patterns is compiled into an xsltCompMatch structure. It
+holdsthe set of rules based on the tokenization of the pattern stored in
+reverseorder (matching is easier this way). It also holds some information
+about theprevious matches used to speed up the process when one iterates over
+a set ofsiblings. (This optimization may be defeated by trashing when
+runningthreaded computation, it's unclear that this is a big deal in
+practice.)Predicate expressions are not compiled at this stage, they may be
+at run-timeif needed, but in this case they are compiled as full XPath
+expressions (theuse of some fixed predicate can probably be optimized, they
+are not yet).</p>
 
-<p>The xsltCompMatch are then stored in the hash table, the clash list is
-itself sorted by priority of the template to implement "naturally" the XSLT
-priority rules.</p>
+<p>The xsltCompMatch are then stored in the hash table, the clash list
+isitself sorted by priority of the template to implement "naturally" the
+XSLTpriority rules.</p>
 
-<p>Associated to the compiled pattern is the xsltTemplate itself containing
-the information required for the processing of the pattern including, of
-course, a pointer to the list of elements used for building the pattern
-result.</p>
+<p>Associated to the compiled pattern is the xsltTemplate itself
+containingthe information required for the processing of the pattern
+including, ofcourse, a pointer to the list of elements used for building the
+patternresult.</p>
 
-<p>Last but not least a number of patterns do not fit in the hash table
-because they are not associated to a name, this is the case for patterns
-applying to the root, any element, any attributes, text nodes, pi nodes, keys
-etc. Those are stored independently in the stylesheet structure as separate
-linked lists of xsltCompMatch.</p>
+<p>Last but not least a number of patterns do not fit in the hash
+tablebecause they are not associated to a name, this is the case for
+patternsapplying to the root, any element, any attributes, text nodes, pi
+nodes, keysetc. Those are stored independently in the stylesheet structure as
+separatelinked lists of xsltCompMatch.</p>
 
 <h3><a name="processing">The processing itself</a></h3>
 
-<p>The processing is defined by the XSLT specification (the basis of the
-algorithm is explained in <a
-href="http://www.w3.org/TR/xslt#section-Introduction">the Introduction</a>
-section). Basically it works by taking the root of the input document and
-applying the following algorithm:</p>
+<p>The processing is defined by the XSLT specification (the basis of
+thealgorithm is explained in <a
+href="http://www.w3.org/TR/xslt#section-Introduction">the
+Introduction</a>section). Basically it works by taking the root of the input
+document andapplying the following algorithm:</p>
 <ol>
-  <li>Finding the template applying to it. This is a lookup in the template
-    hash table, walking the hash list until the node satisfies all the steps
-    of the pattern, then checking the appropriate(s) global templates to see
-    if there isn't a higher priority rule to apply</li>
-  <li>If there is no template, apply the default rule (recurse on the
-    children)</li>
+  <li>Finding the template applying to it. This is a lookup in the
+    templatehash table, walking the hash list until the node satisfies all
+    the stepsof the pattern, then checking the appropriate(s) global
+    templates to seeif there isn't a higher priority rule to apply</li>
+  <li>If there is no template, apply the default rule (recurse on
+  thechildren)</li>
   <li>else walk the content list of the selected templates, for each of them:
     <ul>
-      <li>if the node is in the XSLT namespace then the node has a _private
-        field pointing to the preprocessed values, jump to the specific
-      code</li>
-      <li>if the node is in an extension namespace, look up the associated
-        behavior</li>
+      <li>if the node is in the XSLT namespace then the node has a
+        _privatefield pointing to the preprocessed values, jump to the
+        specificcode</li>
+      <li>if the node is in an extension namespace, look up the
+        associatedbehavior</li>
       <li>otherwise copy the node.</li>
     </ul>
-    <p>The closure is usually done through the XSLT
-    <strong>apply-templates</strong> construct recursing by applying the
-    adequate template on the input node children or on the result of an
-    associated XPath selection lookup.</p>
+    <p>The closure is usually done through the
+    XSLT<strong>apply-templates</strong>construct recursing by applying
+    theadequate template on the input node children or on the result of
+    anassociated XPath selection lookup.</p>
   </li>
 </ol>
 
-<p>Note that large parts of the input tree may not be processed by a given
-stylesheet and that on the opposite some may be processed multiple times.
-(This often is the case when a Table of Contents is built).</p>
+<p>Note that large parts of the input tree may not be processed by a
+givenstylesheet and that on the opposite some may be processed multiple
+times.(This often is the case when a Table of Contents is built).</p>
 
-<p>The module <code>transform.c</code> is the one implementing most of this
-logic. <strong>xsltApplyStylesheet()</strong> is the entry point, it
-allocates an xsltTransformContext containing the following:</p>
+<p>The module <code>transform.c</code>is the one implementing most of
+thislogic. <strong>xsltApplyStylesheet()</strong>is the entry point,
+itallocates an xsltTransformContext containing the following:</p>
 <ul>
   <li>a pointer to the stylesheet being processed</li>
   <li>a stack of templates</li>
@@ -1699,24 +1709,24 @@
   <li>a couple of hash tables for extension elements and functions</li>
 </ul>
 
-<p>Then a new document gets allocated (HTML or XML depending on the type of
-output), the user parameters and global variables and parameters are
-evaluated. Then <strong>xsltProcessOneNode()</strong> which implements the
-1-2-3 algorithm is called on the root element of the input. Step 1/ is
-implemented by calling <strong>xsltGetTemplate()</strong>, step 2/ is
-implemented by <strong>xsltDefaultProcessOneNode()</strong> and step 3/ is
-implemented by <strong>xsltApplyOneTemplate()</strong>.</p>
+<p>Then a new document gets allocated (HTML or XML depending on the type
+ofoutput), the user parameters and global variables and parameters
+areevaluated. Then <strong>xsltProcessOneNode()</strong>which implements
+the1-2-3 algorithm is called on the root element of the input. Step 1/
+isimplemented by calling <strong>xsltGetTemplate()</strong>, step 2/
+isimplemented by <strong>xsltDefaultProcessOneNode()</strong>and step 3/
+isimplemented by <strong>xsltApplyOneTemplate()</strong>.</p>
 
 <h3><a name="XPath">XPath expression compilation</a></h3>
 
-<p>The XPath support is actually implemented in the libxml module (where it
-is reused by the XPointer implementation). XPath is a relatively classic
-expression language. The only uncommon feature is that it is working on XML
-trees and hence has specific syntax and types to handle them.</p>
+<p>The XPath support is actually implemented in the libxml module (where itis
+reused by the XPointer implementation). XPath is a relatively
+classicexpression language. The only uncommon feature is that it is working
+on XMLtrees and hence has specific syntax and types to handle them.</p>
 
-<p>XPath expressions are compiled using <strong>xmlXPathCompile()</strong>.
-It will take an expression string in input and generate a structure
-containing the parsed expression tree, for example the expression:</p>
+<p>XPath expressions are compiled using <strong>xmlXPathCompile()</strong>.It
+will take an expression string in input and generate a structurecontaining
+the parsed expression tree, for example the expression:</p>
 <pre>/doc/chapter[title='Introduction']</pre>
 
 <p>will be compiled as</p>
@@ -1734,180 +1744,179 @@
               COLLECT  'child' 'name' 'node' title
                 NODE</pre>
 
-<p>This can be tested using the  <code>testXPath</code>  command (in the
-libxml codebase) using the <code>--tree</code> option.</p>
+<p>This can be tested using the  <code>testXPath</code>command (in thelibxml
+codebase) using the <code>--tree</code>option.</p>
 
-<p>Again, the KISS approach is used. No optimization is done. This could be
-an interesting thing to add. <a
-href="http://www-106.ibm.com/developerworks/library/x-xslt2/?dwzone=x?open&amp;l=132%2ct=gr%2c+p=saxon">Michael
-Kay describes</a> a lot of possible and interesting optimizations done in
-Saxon which would be possible at this level. I'm unsure they would provide
-much gain since the expressions tends to be relatively simple in general and
-stylesheets are still hand generated. Optimizations at the interpretation
-sounds likely to be more efficient.</p>
+<p>Again, the KISS approach is used. No optimization is done. This could bean
+interesting thing to add. <a
+href="http://www-106.ibm.com/developerworks/library/x-xslt2/?dwzone=x?open&amp;l=132%2ct=gr%2c+p=saxon">MichaelKay
+describes</a>a lot of possible and interesting optimizations done inSaxon
+which would be possible at this level. I'm unsure they would providemuch gain
+since the expressions tends to be relatively simple in general andstylesheets
+are still hand generated. Optimizations at the interpretationsounds likely to
+be more efficient.</p>
 
 <h3><a name="XPath1">XPath interpretation</a></h3>
 
-<p>The interpreter is implemented by <strong>xmlXPathCompiledEval()</strong>
-which is the front-end to <strong>xmlXPathCompOpEval()</strong> the function
-implementing the evaluation of the expression tree. This evaluation follows
-the KISS approach again. It's recursive and calls
-<strong>xmlXPathNodeCollectAndTest()</strong> to collect nodes set when
-evaluating a <code>COLLECT</code> node.</p>
+<p>The interpreter is implemented by
+<strong>xmlXPathCompiledEval()</strong>which is the front-end to
+<strong>xmlXPathCompOpEval()</strong>the functionimplementing the evaluation
+of the expression tree. This evaluation followsthe KISS approach again. It's
+recursive and calls<strong>xmlXPathNodeCollectAndTest()</strong>to collect
+nodes set whenevaluating a <code>COLLECT</code>node.</p>
 
-<p>An evaluation is done within the framework of an XPath context stored in
-an <strong>xmlXPathContext</strong> structure, in the framework of a
-transformation the context is maintained within the XSLT context. Its content
-follows the requirements from the XPath specification:</p>
+<p>An evaluation is done within the framework of an XPath context stored inan
+<strong>xmlXPathContext</strong>structure, in the framework of
+atransformation the context is maintained within the XSLT context. Its
+contentfollows the requirements from the XPath specification:</p>
 <ul>
   <li>the current document</li>
   <li>the current node</li>
   <li>a hash table of defined variables (but not used by XSLT)</li>
   <li>a hash table of defined functions</li>
-  <li>the proximity position (the place of the node in the current node
-  list)</li>
+  <li>the proximity position (the place of the node in the current
+  nodelist)</li>
   <li>the context size (the size of the current node list)</li>
-  <li>the array of namespace declarations in scope (there also is a namespace
-    hash table but it is not used in the XSLT transformation).</li>
+  <li>the array of namespace declarations in scope (there also is a
+    namespacehash table but it is not used in the XSLT transformation).</li>
 </ul>
 
-<p>For the purpose of XSLT an <strong>extra</strong> pointer has been added
-allowing to retrieve the XSLT transformation context. When an XPath
-evaluation is about to be performed, an XPath parser context is allocated
-containing and XPath object stack (this is actually an XPath evaluation
-context, this is a remain of the time where there was no separate parsing and
-evaluation phase in the XPath implementation). Here is an overview of the set
-of contexts associated to an XPath evaluation within an XSLT
-transformation:</p>
+<p>For the purpose of XSLT an <strong>extra</strong>pointer has been
+addedallowing to retrieve the XSLT transformation context. When an
+XPathevaluation is about to be performed, an XPath parser context is
+allocatedcontaining and XPath object stack (this is actually an XPath
+evaluationcontext, this is a remain of the time where there was no separate
+parsing andevaluation phase in the XPath implementation). Here is an overview
+of the setof contexts associated to an XPath evaluation within an
+XSLTtransformation:</p>
 
 <p align="center"><img src="contexts.gif"
 alt="The set of contexts associated "></p>
 
-<p>Clearly this is a bit too complex and confusing and should be refactored
-at the next set of binary incompatible releases of libxml. For example the
-xmlXPathCtxt has a lot of unused parts and should probably be merged with
-xmlXPathParserCtxt.</p>
+<p>Clearly this is a bit too complex and confusing and should be refactoredat
+the next set of binary incompatible releases of libxml. For example
+thexmlXPathCtxt has a lot of unused parts and should probably be merged
+withxmlXPathParserCtxt.</p>
 
 <h3><a name="Descriptio">Description of XPath Objects</a></h3>
 
-<p>An XPath expression manipulates XPath objects. XPath defines the default
-types boolean, numbers, strings and node sets. XSLT adds the result tree
-fragment type which is basically an unmodifiable node set.</p>
+<p>An XPath expression manipulates XPath objects. XPath defines the
+defaulttypes boolean, numbers, strings and node sets. XSLT adds the result
+treefragment type which is basically an unmodifiable node set.</p>
 
-<p>Implementation-wise, libxml follows again a KISS approach, the
-xmlXPathObject is a structure containing a type description and the various
-possibilities. (Using an enum could have gained some bytes.) In the case of
-node sets (or result tree fragments), it points to a separate xmlNodeSet
-object which contains the list of pointers to the document nodes:</p>
+<p>Implementation-wise, libxml follows again a KISS approach,
+thexmlXPathObject is a structure containing a type description and the
+variouspossibilities. (Using an enum could have gained some bytes.) In the
+case ofnode sets (or result tree fragments), it points to a separate
+xmlNodeSetobject which contains the list of pointers to the document
+nodes:</p>
 
 <p align="center"><img src="object.gif"
 alt="An Node set object pointing to "></p>
 
-<p>The <a href="http://xmlsoft.org/html/libxml-xpath.html">XPath API</a> (and
-its <a href="http://xmlsoft.org/html/libxml-xpathinternals.html">'internal'
-part</a>) includes a number of functions to create, copy, compare, convert or
-free XPath objects.</p>
+<p>The <a href="http://xmlsoft.org/html/libxml-xpath.html">XPath
+API</a>(andits <a
+href="http://xmlsoft.org/html/libxml-xpathinternals.html">'internal'part</a>)
+includes a number of functions to create, copy, compare, convert orfree XPath
+objects.</p>
 
 <h3><a name="XPath3">XPath functions</a></h3>
 
-<p>All the XPath functions available to the interpreter are registered in the
-function hash table linked from the XPath context. They all share the same
-signature:</p>
+<p>All the XPath functions available to the interpreter are registered in
+thefunction hash table linked from the XPath context. They all share the
+samesignature:</p>
 <pre>void xmlXPathFunc (xmlXPathParserContextPtr ctxt, int nargs);</pre>
 
-<p>The first argument is the XPath interpretation context, holding the
-interpretation stack. The second argument defines the number of objects
-passed on the stack for the function to consume (last argument is on top of
-the stack).</p>
+<p>The first argument is the XPath interpretation context, holding
+theinterpretation stack. The second argument defines the number of
+objectspassed on the stack for the function to consume (last argument is on
+top ofthe stack).</p>
 
 <p>Basically an XPath function does the following:</p>
 <ul>
-  <li>check <code>nargs</code> for proper handling of errors or functions
-    with variable numbers of parameters</li>
-  <li>pop the parameters from the stack using <code>obj =
-    valuePop(ctxt);</code></li>
+  <li>check <code>nargs</code>for proper handling of errors or functionswith
+    variable numbers of parameters</li>
+  <li>pop the parameters from the stack using <code>obj
+    =valuePop(ctxt);</code></li>
   <li>do the function specific computation</li>
-  <li>push the result parameter on the stack using <code>valuePush(ctxt,
-    res);</code></li>
-  <li>free up the input parameters with
-  <code>xmlXPathFreeObject(obj);</code></li>
+  <li>push the result parameter on the stack using
+    <code>valuePush(ctxt,res);</code></li>
+  <li>free up the input parameters
+  with<code>xmlXPathFreeObject(obj);</code></li>
   <li>return</li>
 </ul>
 
-<p>Sometime the work can be done directly by modifying in-situ the top object
-on the stack <code>ctxt-&gt;value</code>.</p>
+<p>Sometime the work can be done directly by modifying in-situ the top
+objecton the stack <code>ctxt-&gt;value</code>.</p>
 
 <h3><a name="stack">The XSLT variables stack frame</a></h3>
 
-<p>Not to be confused with XPath object stack, this stack holds the XSLT
-variables and parameters as they are defined through the recursive calls of
-call-template, apply-templates and default templates. This is used to define
-the scope of variables being called.</p>
+<p>Not to be confused with XPath object stack, this stack holds the
+XSLTvariables and parameters as they are defined through the recursive calls
+ofcall-template, apply-templates and default templates. This is used to
+definethe scope of variables being called.</p>
 
-<p>This part seems to be the most urgent attention right now, first it is
-done in a very inefficient way since the location of the variables and
-parameters within the stylesheet tree is still done at run time (it really
-should be done statically at compile time), and I am still unsure that my
-understanding of the template variables and parameter scope is actually
-right.</p>
+<p>This part seems to be the most urgent attention right now, first it isdone
+in a very inefficient way since the location of the variables andparameters
+within the stylesheet tree is still done at run time (it reallyshould be done
+statically at compile time), and I am still unsure that myunderstanding of
+the template variables and parameter scope is actuallyright.</p>
 
-<p>This part of the documentation is still to be written once this part of
-the code will be stable. <span
-style="background-color: #FF0000">TODO</span></p>
+<p>This part of the documentation is still to be written once this part ofthe
+code will be stable. <span style="background-color: #FF0000">TODO</span></p>
 
 <h3><a name="Extension">Extension support</a></h3>
 
-<p>There is a separate document explaining <a href="extensions.html">how the
-extension support works</a>.</p>
+<p>There is a separate document explaining <a href="extensions.html">how
+theextension support works</a>.</p>
 
 <h3><a name="Futher">Further reading</a></h3>
 
 <p>Michael Kay wrote <a
-href="http://www-106.ibm.com/developerworks/library/x-xslt2/?dwzone=x?open&amp;l=132%2ct=gr%2c+p=saxon">a
-really interesting article on Saxon internals</a> and the work he did on
-performance issues. I wishes I had read it before starting libxslt design (I
-would probably have avoided a few mistakes and progressed faster). A lot of
-the ideas in his papers should be implemented or at least tried in
-libxslt.</p>
+href="http://www-106.ibm.com/developerworks/library/x-xslt2/?dwzone=x?open&amp;l=132%2ct=gr%2c+p=saxon">areally
+interesting article on Saxon internals</a>and the work he did onperformance
+issues. I wishes I had read it before starting libxslt design (Iwould
+probably have avoided a few mistakes and progressed faster). A lot ofthe
+ideas in his papers should be implemented or at least tried inlibxslt.</p>
 
 <p>The <a href="http://xmlsoft.org/">libxml documentation</a>, especially <a
-href="http://xmlsoft.org/xmlio.html">the I/O interfaces</a> and the <a
+href="http://xmlsoft.org/xmlio.html">the I/O interfaces</a>and the <a
 href="http://xmlsoft.org/xmlmem.html">memory management</a>.</p>
 
 <h3><a name="TODOs">TODOs</a></h3>
 
-<p>redesign the XSLT stack frame handling. Far too much work is done at
-execution time. Similarly for the attribute value templates handling, at
-least the embedded subexpressions ought to be precompiled.</p>
+<p>redesign the XSLT stack frame handling. Far too much work is done
+atexecution time. Similarly for the attribute value templates handling,
+atleast the embedded subexpressions ought to be precompiled.</p>
 
-<p>Allow output to be saved to a SAX like output (this notion of SAX like API
-for output should be added directly to libxml).</p>
+<p>Allow output to be saved to a SAX like output (this notion of SAX like
+APIfor output should be added directly to libxml).</p>
 
-<p>Implement and test some of the optimization explained by Michael Kay
-especially:</p>
+<p>Implement and test some of the optimization explained by Michael
+Kayespecially:</p>
 <ul>
   <li>static slot allocation on the stack frame</li>
   <li>specific boolean interpretation of an XPath expression</li>
   <li>some of the sorting optimization</li>
-  <li>Lazy evaluation of location path. (this may require more changes but
-    sounds really interesting. XT does this too.)</li>
-  <li>Optimization of an expression tree (This could be done as a completely
-    independent module.)</li>
+  <li>Lazy evaluation of location path. (this may require more changes
+    butsounds really interesting. XT does this too.)</li>
+  <li>Optimization of an expression tree (This could be done as a
+    completelyindependent module.)</li>
 </ul>
 
 <p></p>
 
-<p>Error reporting, there is a lot of case where the XSLT specification
-specify that a given construct is an error are not checked adequately by
-libxslt. Basically one should do a complete pass on the XSLT spec again and
-add all tests to the stylesheet compilation. Using the DTD provided in the
-appendix and making direct checks using the libxml validation API sounds a
-good idea too (though one should take care of not raising errors for
-elements/attributes in different namespaces).</p>
+<p>Error reporting, there is a lot of case where the XSLT
+specificationspecify that a given construct is an error are not checked
+adequately bylibxslt. Basically one should do a complete pass on the XSLT
+spec again andadd all tests to the stylesheet compilation. Using the DTD
+provided in theappendix and making direct checks using the libxml validation
+API sounds agood idea too (though one should take care of not raising errors
+forelements/attributes in different namespaces).</p>
 
-<p>Double check all the places where the stylesheet compiled form might be
-modified at run time (extra removal of blanks nodes, hint on the
-xsltCompMatch).</p>
+<p>Double check all the places where the stylesheet compiled form might
+bemodified at run time (extra removal of blanks nodes, hint on
+thexsltCompMatch).</p>
 
 <p></p>
 
@@ -1920,69 +1929,67 @@
   <li><a href="extensions.html#Keep">Extension modules</a></li>
   <li><a href="extensions.html#Registerin">Registering a module</a></li>
   <li><a href="extensions.html#module">Loading a module</a></li>
-  <li><a href="extensions.html#Registerin1">Registering an extension
-    function</a></li>
-  <li><a href="extensions.html#Implementi">Implementing an extension
-    function</a></li>
-  <li><a href="extensions.html#Examples">Examples for extension
-  functions</a></li>
-  <li><a href="extensions.html#Registerin2">Registering an extension
-    element</a></li>
-  <li><a href="extensions.html#Implementi1">Implementing an extension
-    element</a></li>
-  <li><a href="extensions.html#Example">Example for extension
-  elements</a></li>
+  <li><a href="extensions.html#Registerin1">Registering an
+    extensionfunction</a></li>
+  <li><a href="extensions.html#Implementi">Implementing an
+    extensionfunction</a></li>
+  <li><a href="extensions.html#Examples">Examples for
+  extensionfunctions</a></li>
+  <li><a href="extensions.html#Registerin2">Registering an
+    extensionelement</a></li>
+  <li><a href="extensions.html#Implementi1">Implementing an
+    extensionelement</a></li>
+  <li><a href="extensions.html#Example">Example for extensionelements</a></li>
   <li><a href="extensions.html#shutdown">The shutdown of a module</a></li>
   <li><a href="extensions.html#Future">Future work</a></li>
 </ul>
 
 <h3><a name="Introducti1">Introduction</a></h3>
 
-<p>This document describes the work needed to write extensions to the
-standard XSLT library for use with <a
-href="http://xmlsoft.org/XSLT/">libxslt</a>, the <a
-href="http://www.w3.org/TR/xslt">XSLT</a> C library developed for the <a
-href="http://www.gnome.org/">Gnome</a> project.</p>
+<p>This document describes the work needed to write extensions to thestandard
+XSLT library for use with <a href="http://xmlsoft.org/XSLT/">libxslt</a>, the
+<a href="http://www.w3.org/TR/xslt">XSLT</a>C library developed for the <a
+href="http://www.gnome.org/">Gnome</a>project.</p>
 
-<p>Before starting reading this document it is highly recommended to get
-familiar with <a href="internals.html">the libxslt internals</a>.</p>
+<p>Before starting reading this document it is highly recommended to
+getfamiliar with <a href="internals.html">the libxslt internals</a>.</p>
 
-<p>Note: this documentation is by definition incomplete and I am not good at
-spelling, grammar, so patches and suggestions are <a
+<p>Note: this documentation is by definition incomplete and I am not good
+atspelling, grammar, so patches and suggestions are <a
 href="mailto:veillard at redhat.com">really welcome</a>.</p>
 
 <h3><a name="Basics">Basics</a></h3>
 
-<p>The <a href="http://www.w3.org/TR/xslt">XSLT specification</a> provides
-two <a href="http://www.w3.org/TR/xslt">ways to extend an XSLT engine</a>:</p>
+<p>The <a href="http://www.w3.org/TR/xslt">XSLT specification</a>providestwo
+<a href="http://www.w3.org/TR/xslt">ways to extend an XSLT engine</a>:</p>
 <ul>
-  <li>providing <a href="http://www.w3.org/TR/xslt">new extension
-    functions</a> which can be called from XPath expressions</li>
-  <li>providing <a href="http://www.w3.org/TR/xslt">new extension
-    elements</a> which can be inserted in stylesheets</li>
+  <li>providing <a href="http://www.w3.org/TR/xslt">new
+    extensionfunctions</a>which can be called from XPath expressions</li>
+  <li>providing <a href="http://www.w3.org/TR/xslt">new
+    extensionelements</a>which can be inserted in stylesheets</li>
 </ul>
 
-<p>In both cases the extensions need to be associated to a new namespace,
-i.e. an URI used as the name for the extension's namespace (there is no need
-to have a resource there for this to work).</p>
+<p>In both cases the extensions need to be associated to a new namespace,i.e.
+an URI used as the name for the extension's namespace (there is no needto
+have a resource there for this to work).</p>
 
-<p>libxslt provides a few extensions itself, either in the libxslt namespace
-"http://xmlsoft.org/XSLT/namespace" or in namespaces for other well known
-extensions provided by other XSLT processors like Saxon, Xalan or XT.</p>
+<p>libxslt provides a few extensions itself, either in the libxslt
+namespace"http://xmlsoft.org/XSLT/namespace" or in namespaces for other well
+knownextensions provided by other XSLT processors like Saxon, Xalan or XT.</p>
 
 <h3><a name="Keep">Extension modules</a></h3>
 
-<p>Since extensions are bound to a namespace name, usually sets of extensions
-coming from a given source are using the same namespace name defining in
-practice a group of extensions providing elements, functions or both. From
-the libxslt point of view those are considered as an "extension module", and
-most of the APIs work at a module point of view.</p>
+<p>Since extensions are bound to a namespace name, usually sets of
+extensionscoming from a given source are using the same namespace name
+defining inpractice a group of extensions providing elements, functions or
+both. Fromthe libxslt point of view those are considered as an "extension
+module", andmost of the APIs work at a module point of view.</p>
 
-<p>Registration of new functions or elements are bound to the activation of
-the module. This is currently done by declaring the namespace as an extension
-by using the attribute  <code>extension-element-prefixes</code> on the
-<code><a href="http://www.w3.org/TR/xslt">xsl:stylesheet</a></code>
-element.</p>
+<p>Registration of new functions or elements are bound to the activation
+ofthe module. This is currently done by declaring the namespace as an
+extensionby using the attribute  <code>extension-element-prefixes</code>on
+the<code><a
+href="http://www.w3.org/TR/xslt">xsl:stylesheet</a></code>element.</p>
 
 <p>An extension module is defined by 3 objects:</p>
 <ul>
@@ -1993,13 +2000,13 @@
 
 <h3><a name="Registerin">Registering a module</a></h3>
 
-<p>Currently a libxslt module has to be compiled within the application using
-libxslt. There is no code to load dynamically shared libraries associated to
-a namespace (this may be added but is likely to become a portability
-nightmare).</p>
+<p>Currently a libxslt module has to be compiled within the application
+usinglibxslt. There is no code to load dynamically shared libraries
+associated toa namespace (this may be added but is likely to become a
+portabilitynightmare).</p>
 
-<p>The current way to register a module is to link the code implementing it
-with the application and to call a registration function:</p>
+<p>The current way to register a module is to link the code implementing
+itwith the application and to call a registration function:</p>
 <pre>int xsltRegisterExtModule(const xmlChar *URI,
                           xsltExtInitFunction initFunc,
                           xsltExtShutdownFunction shutdownFunc);</pre>
@@ -2007,17 +2014,17 @@
 <p>The associated header is read by:</p>
 <pre>#include&lt;libxslt/extensions.h&gt;</pre>
 
-<p>which also defines the type for the initialization and shutdown
-functions</p>
+<p>which also defines the type for the initialization and
+shutdownfunctions</p>
 
 <h3><a name="module">Loading a module</a></h3>
 
-<p>Once the module URI has been registered and if the XSLT processor detects
-that a given stylesheet needs the functionalities of an extended module, this
-one is initialized.</p>
+<p>Once the module URI has been registered and if the XSLT processor
+detectsthat a given stylesheet needs the functionalities of an extended
+module, thisone is initialized.</p>
 
-<p>The xsltExtInitFunction type defines the interface for an initialization
-function:</p>
+<p>The xsltExtInitFunction type defines the interface for an
+initializationfunction:</p>
 <pre>/**
  * xsltExtInitFunction:
  * @ctxt:  an XSLT transformation context
@@ -2034,24 +2041,24 @@
 
 <p>There are 3 things to notice:</p>
 <ul>
-  <li>The function gets passed the namespace name URI as an argument. This
-    allows a single function to provide the initialization for multiple
-    logical modules.</li>
-  <li>It also gets passed a transformation context. The initialization is
-    done at run time before any processing occurs on the stylesheet but it
-    will be invoked separately each time for each transformation.</li>
-  <li>It returns a pointer.  This can be used to store module specific
-    information which can be retrieved later when a function or an element
-    from the extension is used.  An obvious example is a connection to a
-    database which should be kept and reused along with the transformation.
-    NULL is a perfectly valid return; there is no way to indicate a failure
-    at this level</li>
+  <li>The function gets passed the namespace name URI as an argument.
+    Thisallows a single function to provide the initialization for
+    multiplelogical modules.</li>
+  <li>It also gets passed a transformation context. The initialization isdone
+    at run time before any processing occurs on the stylesheet but itwill be
+    invoked separately each time for each transformation.</li>
+  <li>It returns a pointer.  This can be used to store module
+    specificinformation which can be retrieved later when a function or an
+    elementfrom the extension is used.  An obvious example is a connection to
+    adatabase which should be kept and reused along with the
+    transformation.NULL is a perfectly valid return; there is no way to
+    indicate a failureat this level</li>
 </ul>
 
 <p>What this function is expected to do is:</p>
 <ul>
-  <li>prepare the context for this module (like opening the database
-    connection)</li>
+  <li>prepare the context for this module (like opening the
+    databaseconnection)</li>
   <li>register the extensions specific to this module</li>
 </ul>
 
@@ -2063,16 +2070,16 @@
                             const xmlChar *URI,
                             xmlXPathEvalFunc function);</pre>
 
-<p>The registration is bound to a single transformation instance referred by
-ctxt, name is the UTF8 encoded name for the NCName of the function, and URI
-is the namespace name for the extension (no checking is done, a module could
-register functions or elements from a different namespace, but it is not
-recommended).</p>
+<p>The registration is bound to a single transformation instance referred
+byctxt, name is the UTF8 encoded name for the NCName of the function, and
+URIis the namespace name for the extension (no checking is done, a module
+couldregister functions or elements from a different namespace, but it is
+notrecommended).</p>
 
 <h3><a name="Implementi">Implementing an extension function</a></h3>
 
-<p>The implementation of the function must have the signature of a libxml
-XPath function:</p>
+<p>The implementation of the function must have the signature of a
+libxmlXPath function:</p>
 <pre>/**
  * xmlXPathEvalFunc:
  * @ctxt: an XPath parser context
@@ -2086,67 +2093,67 @@
                                  int nargs);</pre>
 
 <p>The context passed to an XPath function is not an XSLT context but an <a
-href="internals.html#XPath1">XPath context</a>. However it is possible to
-find one from the other:</p>
+href="internals.html#XPath1">XPath context</a>. However it is possible tofind
+one from the other:</p>
 <ul>
   <li>The function xsltXPathGetTransformContext provides this lookup facility:
     <pre>xsltTransformContextPtr
          xsltXPathGetTransformContext
                           (xmlXPathParserContextPtr ctxt);</pre>
   </li>
-  <li>The <code>xmlXPathContextPtr</code> associated to an
-    <code>xsltTransformContext</code> is stored in the <code>xpathCtxt</code>
-    field.</li>
+  <li>The <code>xmlXPathContextPtr</code>associated to
+    an<code>xsltTransformContext</code>is stored in the
+    <code>xpathCtxt</code>field.</li>
 </ul>
 
-<p>The first thing an extension function may want to do is to check the
-arguments passed on the stack, the <code>nargs</code> parameter will tell how
-many of them were provided on the XPath expression. The macro valuePop will
-extract them from the XPath stack:</p>
+<p>The first thing an extension function may want to do is to check
+thearguments passed on the stack, the <code>nargs</code>parameter will tell
+howmany of them were provided on the XPath expression. The macro valuePop
+willextract them from the XPath stack:</p>
 <pre>#include &lt;libxml/xpath.h&gt;
 #include &lt;libxml/xpathInternals.h&gt;
 
 xmlXPathObjectPtr obj = valuePop(ctxt); </pre>
 
-<p>Note that <code>ctxt</code> is the XPath context not the XSLT one. It is
-then possible to examine the content of the value. Check <a
-href="internals.html#Descriptio">the description of XPath objects</a> if
-necessary. The following is a common sequence checking whether the argument
-passed is a string and converting it using the built-in XPath
-<code>string()</code> function if this is not the case:</p>
+<p>Note that <code>ctxt</code>is the XPath context not the XSLT one. It
+isthen possible to examine the content of the value. Check <a
+href="internals.html#Descriptio">the description of XPath
+objects</a>ifnecessary. The following is a common sequence checking whether
+the argumentpassed is a string and converting it using the built-in
+XPath<code>string()</code>function if this is not the case:</p>
 <pre>if (obj-&gt;type != XPATH_STRING) {
     valuePush(ctxt, obj);
     xmlXPathStringFunction(ctxt, 1);
     obj = valuePop(ctxt);
 }</pre>
 
-<p>Most common XPath functions are available directly at the C level and are
-exported either in <code>&lt;libxml/xpath.h&gt;</code> or in
-<code>&lt;libxml/xpathInternals.h&gt;</code>.</p>
+<p>Most common XPath functions are available directly at the C level and
+areexported either in <code>&lt;libxml/xpath.h&gt;</code>or
+in<code>&lt;libxml/xpathInternals.h&gt;</code>.</p>
 
-<p>The extension function may also need to retrieve the data associated to
-this module instance (the database connection in the previous example) this
-can be done using the xsltGetExtData:</p>
+<p>The extension function may also need to retrieve the data associated
+tothis module instance (the database connection in the previous example)
+thiscan be done using the xsltGetExtData:</p>
 <pre>void * xsltGetExtData(xsltTransformContextPtr ctxt,
                       const xmlChar *URI);</pre>
 
-<p>Again the URI to be provided is the one which was used when registering
-the module.</p>
+<p>Again the URI to be provided is the one which was used when registeringthe
+module.</p>
 
 <p>Once the function finishes, don't forget to:</p>
 <ul>
-  <li>push the return value on the stack using <code>valuePush(ctxt,
-    obj)</code></li>
-  <li>deallocate the parameters passed to the function using
-    <code>xmlXPathFreeObject(obj)</code></li>
+  <li>push the return value on the stack using
+    <code>valuePush(ctxt,obj)</code></li>
+  <li>deallocate the parameters passed to the function
+    using<code>xmlXPathFreeObject(obj)</code></li>
 </ul>
 
 <h3><a name="Examples">Examples for extension functions</a></h3>
 
-<p>The module libxslt/functions.c contains the sources of the XSLT built-in
-functions, including document(), key(), generate-id(), etc. as well as a full
-example module at the end. Here is the test function implementation for the
-libxslt:test function:</p>
+<p>The module libxslt/functions.c contains the sources of the XSLT
+built-infunctions, including document(), key(), generate-id(), etc. as well
+as a fullexample module at the end. Here is the test function implementation
+for thelibxslt:test function:</p>
 <pre>/**
  * xsltExtFunctionTest:
  * @ctxt:  the XPath Parser context
@@ -2186,19 +2193,20 @@
                            const xmlChar *URI,
                            xsltTransformFunction function);</pre>
 
-<p>It is similar to the mechanism used to register an extension function,
-except that the signature of an extension element implementation is
-different.</p>
+<p>It is similar to the mechanism used to register an extension
+function,except that the signature of an extension element implementation
+isdifferent.</p>
 
-<p>The registration is bound to a single transformation instance referred to
-by ctxt, name is the UTF8 encoded name for the NCName of the element, and URI
-is the namespace name for the extension (no checking is done, a module could
-register elements for a different namespace, but it is not recommended).</p>
+<p>The registration is bound to a single transformation instance referred
+toby ctxt, name is the UTF8 encoded name for the NCName of the element, and
+URIis the namespace name for the extension (no checking is done, a module
+couldregister elements for a different namespace, but it is not
+recommended).</p>
 
 <h3><a name="Implementi1">Implementing an extension element</a></h3>
 
-<p>The implementation of the element must have the signature of an XSLT
-transformation function:</p>
+<p>The implementation of the element must have the signature of an
+XSLTtransformation function:</p>
 <pre>/** 
  * xsltTransformFunction: 
  * @ctxt: the XSLT transformation context
@@ -2215,37 +2223,37 @@
                            xmlNodePtr inst,
                            xsltStylePreCompPtr comp);</pre>
 
-<p>The first argument is the XSLT transformation context. The second and
-third arguments are xmlNodePtr i.e. internal memory <a
-href="internals.html#libxml">representation of  XML nodes</a>. They are
-respectively <code>node</code> from the the input document being transformed
-by the stylesheet and <code>inst</code> the extension element in the
-stylesheet. The last argument is <code>comp</code> a pointer to a precompiled
-representation of <code>inst</code> but usually for an extension function
-this value is <code>NULL</code> by default (it could be added and associated
-to the instruction in <code>inst-&gt;_private</code>).</p>
+<p>The first argument is the XSLT transformation context. The second andthird
+arguments are xmlNodePtr i.e. internal memory <a
+href="internals.html#libxml">representation of  XML nodes</a>. They
+arerespectively <code>node</code>from the the input document being
+transformedby the stylesheet and <code>inst</code>the extension element in
+thestylesheet. The last argument is <code>comp</code>a pointer to a
+precompiledrepresentation of <code>inst</code>but usually for an extension
+functionthis value is <code>NULL</code>by default (it could be added and
+associatedto the instruction in <code>inst-&gt;_private</code>).</p>
 
-<p>The same functions are available from a function implementing an extension
-element as in an extension function, including
-<code>xsltGetExtData()</code>.</p>
+<p>The same functions are available from a function implementing an
+extensionelement as in an extension function,
+including<code>xsltGetExtData()</code>.</p>
 
-<p>The goal of an extension element being usually to enrich the generated
-output, it is expected that they will grow the currently generated output
-tree. This can be done by grabbing ctxt-&gt;insert which is the current
-libxml node being generated (Note this can also be the intermediate value
-tree being built for example to initialize a variable, the processing should
-be similar). The functions for libxml tree manipulation from <a
-href="http://xmlsoft.org/html/libxml-tree.html">&lt;libxml/tree.h&gt;</a> can
-be employed to extend or modify the tree, but it is required to preserve the
-insertion node and its ancestors since there are existing pointers to those
-elements still in use in the XSLT template execution stack.</p>
+<p>The goal of an extension element being usually to enrich the
+generatedoutput, it is expected that they will grow the currently generated
+outputtree. This can be done by grabbing ctxt-&gt;insert which is the
+currentlibxml node being generated (Note this can also be the intermediate
+valuetree being built for example to initialize a variable, the processing
+shouldbe similar). The functions for libxml tree manipulation from <a
+href="http://xmlsoft.org/html/libxml-tree.html">&lt;libxml/tree.h&gt;</a>canbe
+employed to extend or modify the tree, but it is required to preserve
+theinsertion node and its ancestors since there are existing pointers to
+thoseelements still in use in the XSLT template execution stack.</p>
 
 <h3><a name="Example">Example for extension elements</a></h3>
 
-<p>The module libxslt/transform.c contains the sources of the XSLT built-in
-elements, including xsl:element, xsl:attribute, xsl:if, etc. There is a small
-but full example in functions.c providing the implementation for the
-libxslt:test element, it will output a comment in the result tree:</p>
+<p>The module libxslt/transform.c contains the sources of the XSLT
+built-inelements, including xsl:element, xsl:attribute, xsl:if, etc. There is
+a smallbut full example in functions.c providing the implementation for
+thelibxslt:test element, it will output a comment in the result tree:</p>
 <pre>/**
  * xsltExtElementTest:
  * @ctxt:  an XSLT processing context
@@ -2290,10 +2298,10 @@
 
 <h3><a name="shutdown">The shutdown of a module</a></h3>
 
-<p>When the XSLT processor ends a transformation, the shutdown function (if
-it exists) for each of the modules initialized is called.  The
-xsltExtShutdownFunction type defines the interface for a shutdown
-function:</p>
+<p>When the XSLT processor ends a transformation, the shutdown function (ifit
+exists) for each of the modules initialized is called. 
+ThexsltExtShutdownFunction type defines the interface for a
+shutdownfunction:</p>
 <pre>/**
  * xsltExtShutdownFunction:
  * @ctxt:  an XSLT transformation context
@@ -2306,64 +2314,66 @@
                                          const xmlChar *URI,
                                          void *data);</pre>
 
-<p>This is really similar to a module initialization function except a third
-argument is passed, it's the value that was returned by the initialization
-function. This allows the routine to deallocate resources from the module for
-example close the connection to the database to keep the same example.</p>
+<p>This is really similar to a module initialization function except a
+thirdargument is passed, it's the value that was returned by the
+initializationfunction. This allows the routine to deallocate resources from
+the module forexample close the connection to the database to keep the same
+example.</p>
 
 <h3><a name="Future">Future work</a></h3>
 
 <p>Well, some of the pieces missing:</p>
 <ul>
   <li>a way to load shared libraries to instantiate new modules</li>
-  <li>a better detection of extension functions usage and their registration
-    without having to use the extension prefix which ought to be reserved to
-    element extensions.</li>
+  <li>a better detection of extension functions usage and their
+    registrationwithout having to use the extension prefix which ought to be
+    reserved toelement extensions.</li>
   <li>more examples</li>
-  <li>implementations of the <a href="http://www.exslt.org/">EXSLT</a> common
-    extension libraries, Thomas Broyer nearly finished implementing them.</li>
+  <li>implementations of the <a
+    href="http://www.exslt.org/">EXSLT</a>commonextension libraries, Thomas
+    Broyer nearly finished implementing them.</li>
 </ul>
 
 <p></p>
 
 <h2><a name="Contributi">Contributions</a></h2>
 <ul>
-  <li>Bjorn Reese is the author of the number support and worked on the
-    XSLTMark support</li>
-  <li>William Brack was an early adopted, contributed a number of patches and
-    spent quite some time debugging non-trivial problems in early versions of
-    libxslt</li>
-  <li><a href="mailto:igor at zlatkovic.com">Igor  Zlatkovic</a> is now the
-    maintainer of the Windows port, <a
-    href="http://www.zlatkovic.com/projects/libxml/index.html">he provides
-    binaries</a></li>
-  <li>Thomas Broyer provided a lot of suggestions, and drafted most of the
-    extension API</li>
-  <li>John Fleck maintains <a href="tutorial/libxslttutorial.html">a tutorial
-    for libxslt</a></li>
+  <li>Bjorn Reese is the author of the number support and worked on
+    theXSLTMark support</li>
+  <li>William Brack was an early adopted, contributed a number of patches
+    andspent quite some time debugging non-trivial problems in early versions
+    oflibxslt</li>
+  <li><a href="mailto:igor at zlatkovic.com">Igor  Zlatkovic</a>is now
+    themaintainer of the Windows port, <a
+    href="http://www.zlatkovic.com/projects/libxml/index.html">he
+    providesbinaries</a></li>
+  <li>Thomas Broyer provided a lot of suggestions, and drafted most of
+    theextension API</li>
+  <li>John Fleck maintains <a href="tutorial/libxslttutorial.html">a
+    tutorialfor libxslt</a></li>
   <li><a
-    href="http://mail.gnome.org/archives/xml/2001-March/msg00014.html">Matt
-    Sergeant</a> developed <a
-    href="http://axkit.org/download/">XML::LibXSLT</a>, a perl wrapper for
-    libxml2/libxslt as part of the <a href="http://axkit.com/">AxKit XML
-    application server</a></li>
+    href="http://mail.gnome.org/archives/xml/2001-March/msg00014.html">MattSergeant</a>developed
+    <a href="http://axkit.org/download/">XML::LibXSLT</a>, a perl wrapper
+    forlibxml2/libxslt as part of the <a href="http://axkit.com/">AxKit
+    XMLapplication server</a></li>
   <li>there is a module for <a
-    href="http://acs-misc.sourceforge.net/nsxml.html">libxml/libxslt support
-    in OpenNSD/AOLServer</a></li>
-  <li><a href="mailto:dkuhlman at cutter.rexx.com">Dave Kuhlman</a> provides
-    libxml/libxslt <a href="http://www.rexx.com/~dkuhlman">wrappers for
-    Python</a></li>
-  <li><a href="mailto:Steve.Ball at explain.com.au">Steve Ball</a>, and
-    contributors maintain <a href="http://tclxml.sourceforge.net/">tcl
-    bindings for libxml2 and libxslt</a>, as well as <a
-    href="http://tclxml.sf.net/tkxmllint.html">tkxmllint</a> a GUI for
-    xmllint and <a href="http://tclxml.sf.net/tkxsltproc.html">tkxsltproc</a>
-    a GUI for xsltproc.</li>
-  <li>If you want to use libxslt in a Mac OS X/Cocoa or Objective-C
-    framework, Marc Liyanage provides <a
-    href="http://www.entropy.ch/software/macosx/#testxslt">an application
-    TestXSLT for XSLT and XML editing</a> including wrapper classes for the
-    XML parser and XSLT processor.</li>
+    href="http://acs-misc.sourceforge.net/nsxml.html">libxml/libxslt
+    supportin OpenNSD/AOLServer</a></li>
+  <li><a href="mailto:dkuhlman at cutter.rexx.com">Dave
+    Kuhlman</a>provideslibxml/libxslt <a
+    href="http://www.rexx.com/~dkuhlman">wrappers forPython</a></li>
+  <li><a href="mailto:Steve.Ball at explain.com.au">Steve Ball</a>,
+    andcontributors maintain <a
+    href="http://tclxml.sourceforge.net/">tclbindings for libxml2 and
+    libxslt</a>, as well as <a
+    href="http://tclxml.sf.net/tkxmllint.html">tkxmllint</a>a GUI forxmllint
+    and <a href="http://tclxml.sf.net/tkxsltproc.html">tkxsltproc</a>a GUI
+    for xsltproc.</li>
+  <li>If you want to use libxslt in a Mac OS X/Cocoa or Objective-Cframework,
+    Marc Liyanage provides <a
+    href="http://www.entropy.ch/software/macosx/#testxslt">an
+    applicationTestXSLT for XSLT and XML editing</a>including wrapper classes
+    for theXML parser and XSLT processor.</li>
 </ul>
 
 <p></p>

Modified: packages/libxslt/trunk/doc/xsltproc2.html
===================================================================
--- packages/libxslt/trunk/doc/xsltproc2.html	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/doc/xsltproc2.html	2006-06-08 22:29:07 UTC (rev 565)
@@ -8,11 +8,11 @@
 H3 {font-family: Verdana,Arial,Helvetica}
 A:link, A:visited, A:active { text-decoration: underline }
     </style><title>The xsltproc tool</title></head><body bgcolor="#8b7765" text="#000000" link="#a06060" vlink="#000000"><table border="0" width="100%" cellpadding="5" cellspacing="0" align="center"><tr><td width="120"><a href="http://swpat.ffii.org/"><img src="epatents.png" alt="Action against software patents" /></a></td><td width="180"><a href="http://www.gnome.org/"><img src="gnome2.png" alt="Gnome2 Logo" /></a><a href="http://www.w3.org/Status"><img src="w3c.png" alt="W3C logo" /></a><a href="http://www.redhat.com"><img src="redhat.gif" alt="Red Hat Logo" /></a><div align="left"><a href="http://xmlsoft.org/XSLT/"><img src="Libxslt-Logo-180x168.gif" alt="Made with Libxslt Logo" /></a></div></td><td><table border="0" width="90%" cellpadding="2" cellspacing="0" align="center" bgcolor="#000000"><tr><td><table width="100%" border="0" cellspacing="1" cellpadding="3" bgcolor="#fffacd"><tr><td align="center"><h1>The XSLT C library for Gnome</h1><h2>The xsltproc tool</h2></td></tr></table></td></tr></table></td></tr></table><table border="0" cellpadding="4" cellspacing="0" width="100%" align="center"><tr><td bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="2" width="100%"><tr><td valign="top" width="200" bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000"><tr><td><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>Main Menu</b></center></td></tr><tr><td bgcolor="#fffacd"><form action="search.php" enctype="application/x-www-form-urlencoded" method="get"><input name="query" type="text" size="20" value="" /><input name="submit" type="submit" value="Search ..." /></form><ul><li><a href="index.html">Home</a></li><li><a href="http://xmlsoft.org/wiki">Wiki</a></li><li><a href="intro.html">Introduction</a></li><li><a href="docs.html">Documentation</a></li><li><a href="bugs.html">Reporting bugs and getting help</a></li><li><a href="help.html">How to help</a></li><li><a href="downloads.html">Downloads</a></li><li><a href="FAQ.html">FAQ</a></li><li><a href="news.html">News</a></li><li><a href="xsltproc2.html">The xsltproc tool</a></li><li><a href="docbook.html">DocBook</a></li><li><a href="API.html">The programming API</a></li><li><a href="python.html">Python and bindings</a></li><li><a href="internals.html">Library internals</a></li><li><a href="extensions.html">Writing extensions</a></li><li><a href="contribs.html">Contributions</a></li><li><a href="EXSLT/index.html" style="font-weight:bold">libexslt</a></li><li><a href="xslt.html">flat page</a>, <a href="site.xsl">stylesheet</a></li><li><a href="html/index.html" style="font-weight:bold">API Menu</a></li><li><a href="ChangeLog.html">ChangeLog</a></li></ul></td></tr></table><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>Related links</b></center></td></tr><tr><td bgcolor="#fffacd"><ul><li><a href="tutorial/libxslttutorial.html">Tutorial</a>,
-          <a href="tutorial2/libxslt_pipes.html">Tutorial2</a></li><li><a href="xsltproc.html">Man page for xsltproc</a></li><li><a href="http://mail.gnome.org/archives/xslt/">Mail archive</a></li><li><a href="http://xmlsoft.org/">XML libxml2</a></li><li><a href="ftp://xmlsoft.org/">FTP</a></li><li><a href="http://www.zlatkovic.com/projects/libxml/">Windows binaries</a></li><li><a href="http://garypennington.net/libxml2/">Solaris binaries</a></li><li><a href="http://www.explain.com.au/oss/libxml2xslt.html">MacOsX binaries</a></li><li><a href="http://bugzilla.gnome.org/buglist.cgi?product=libxslt">Bug Tracker</a></li><li><a href="http://www.zend.com/php5/articles/php5-xmlphp.php#Heading17">XSLT with PHP</a></li><li><a href="http://www.mod-xslt2.com/">Apache module</a></li><li><a href="http://sourceforge.net/projects/libxml2-pas/">Pascal bindings</a></li><li><a href="http://xsldbg.sourceforge.net/">Xsldbg Debugger</a></li></ul></td></tr></table><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>API Indexes</b></center></td></tr><tr><td bgcolor="#fffacd"><ul><li><a href="APIchunk0.html">Alphabetic</a></li><li><a href="APIconstructors.html">Constructors</a></li><li><a href="APIfunctions.html">Functions/Types</a></li><li><a href="APIfiles.html">Modules</a></li><li><a href="APIsymbols.html">Symbols</a></li></ul></td></tr></table></td></tr></table></td><td valign="top" bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="1" width="100%"><tr><td><table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000"><tr><td><table border="0" cellpadding="3" cellspacing="1" width="100%"><tr><td bgcolor="#fffacd"><p>This program is the simplest way to use libxslt: from the command line. It
-is also used for doing the regression tests of the library.</p><p>It takes as first argument the path or URL to an XSLT stylesheet, the next
-arguments are filenames or URIs of the inputs to be processed. The output of
-the processing is redirected on the standard output. There is actually a few
-more options available:</p><pre>orchis:~ -&gt; xsltproc
+          <a href="tutorial2/libxslt_pipes.html">Tutorial2</a></li><li><a href="xsltproc.html">Man page for xsltproc</a></li><li><a href="http://mail.gnome.org/archives/xslt/">Mail archive</a></li><li><a href="http://xmlsoft.org/">XML libxml2</a></li><li><a href="ftp://xmlsoft.org/">FTP</a></li><li><a href="http://www.zlatkovic.com/projects/libxml/">Windows binaries</a></li><li><a href="http://garypennington.net/libxml2/">Solaris binaries</a></li><li><a href="http://www.explain.com.au/oss/libxml2xslt.html">MacOsX binaries</a></li><li><a href="http://bugzilla.gnome.org/buglist.cgi?product=libxslt">Bug Tracker</a></li><li><a href="http://www.zend.com/php5/articles/php5-xmlphp.php#Heading17">XSLT with PHP</a></li><li><a href="http://www.mod-xslt2.com/">Apache module</a></li><li><a href="http://sourceforge.net/projects/libxml2-pas/">Pascal bindings</a></li><li><a href="http://xsldbg.sourceforge.net/">Xsldbg Debugger</a></li></ul></td></tr></table><table width="100%" border="0" cellspacing="1" cellpadding="3"><tr><td colspan="1" bgcolor="#eecfa1" align="center"><center><b>API Indexes</b></center></td></tr><tr><td bgcolor="#fffacd"><ul><li><a href="APIchunk0.html">Alphabetic</a></li><li><a href="APIconstructors.html">Constructors</a></li><li><a href="APIfunctions.html">Functions/Types</a></li><li><a href="APIfiles.html">Modules</a></li><li><a href="APIsymbols.html">Symbols</a></li></ul></td></tr></table></td></tr></table></td><td valign="top" bgcolor="#8b7765"><table border="0" cellspacing="0" cellpadding="1" width="100%"><tr><td><table border="0" cellspacing="0" cellpadding="1" width="100%" bgcolor="#000000"><tr><td><table border="0" cellpadding="3" cellspacing="1" width="100%"><tr><td bgcolor="#fffacd"><p>This program is the simplest way to use libxslt: from the command line.
+Itis also used for doing the regression tests of the library.</p><p>It takes as first argument the path or URL to an XSLT stylesheet, the
+nextarguments are filenames or URIs of the inputs to be processed. The output
+ofthe processing is redirected on the standard output. There is actually a
+fewmore options available:</p><pre>orchis:~ -&gt; xsltproc
 Usage: xsltproc [options] stylesheet file [file ...]
    Options:
       --version or -V: show the version of libxml and libxslt used

Modified: packages/libxslt/trunk/libexslt/Makefile.in
===================================================================
--- packages/libxslt/trunk/libexslt/Makefile.in	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/libexslt/Makefile.in	2006-06-08 22:29:07 UTC (rev 565)
@@ -117,6 +117,7 @@
 EXTRA_LIBS = @EXTRA_LIBS@
 F77 = @F77@
 FFLAGS = @FFLAGS@
+GREP = @GREP@
 HTML_DIR = @HTML_DIR@
 INSTALL_DATA = @INSTALL_DATA@
 INSTALL_PROGRAM = @INSTALL_PROGRAM@
@@ -202,12 +203,9 @@
 XSLT_INCLUDEDIR = @XSLT_INCLUDEDIR@
 XSLT_LIBDIR = @XSLT_LIBDIR@
 XSLT_LIBS = @XSLT_LIBS@
-ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_CXX = @ac_ct_CXX@
 ac_ct_F77 = @ac_ct_F77@
-ac_ct_RANLIB = @ac_ct_RANLIB@
-ac_ct_STRIP = @ac_ct_STRIP@
 am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
 am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
 am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@
@@ -224,23 +222,30 @@
 build_os = @build_os@
 build_vendor = @build_vendor@
 datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
 exec_prefix = @exec_prefix@
 host = @host@
 host_alias = @host_alias@
 host_cpu = @host_cpu@
 host_os = @host_os@
 host_vendor = @host_vendor@
+htmldir = @htmldir@
 includedir = @includedir@
 infodir = @infodir@
 install_sh = @install_sh@
 libdir = @libdir@
 libexecdir = @libexecdir@
+localedir = @localedir@
 localstatedir = @localstatedir@
 mandir = @mandir@
 mkdir_p = @mkdir_p@
 oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
 prefix = @prefix@
 program_transform_name = @program_transform_name@
+psdir = @psdir@
 pythondir = @pythondir@
 sbindir = @sbindir@
 sharedstatedir = @sharedstatedir@

Modified: packages/libxslt/trunk/libexslt/exsltconfig.h
===================================================================
--- packages/libxslt/trunk/libexslt/exsltconfig.h	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/libexslt/exsltconfig.h	2006-06-08 22:29:07 UTC (rev 565)
@@ -18,7 +18,7 @@
  *
  * the version string like "1.2.3"
  */
-#define LIBEXSLT_DOTTED_VERSION "1.1.16"
+#define LIBEXSLT_DOTTED_VERSION "1.1.17"
 
 /**
  * LIBEXSLT_VERSION:
@@ -39,7 +39,7 @@
  *
  * extra version information, used to show a CVS compilation
  */
-#define	LIBEXSLT_VERSION_EXTRA "-CVS1050"
+#define	LIBEXSLT_VERSION_EXTRA "-CVS1062"
 
 /**
  * WITH_CRYPTO:

Modified: packages/libxslt/trunk/libexslt/functions.c
===================================================================
--- packages/libxslt/trunk/libexslt/functions.c	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/libexslt/functions.c	2006-06-08 22:29:07 UTC (rev 565)
@@ -128,6 +128,10 @@
  * @URI: the namespace URI for the extension
  *
  * Initializes the EXSLT - Functions module.
+ * Called at transformation-time; merges all
+ * functions declared in the import tree taking
+ * import precedence into account, i.e. overriding
+ * functions with lower import precedence.
  *
  * Returns the data for this transformation
  */
@@ -170,8 +174,9 @@
  * @ctxt: an XSLT transformation context
  * @URI: the namespace URI for the extension
  * @data: the module data to free up
- *
+ *  
  * Shutdown the EXSLT - Functions module
+ * Called at transformation-time.
  */
 static void
 exsltFuncShutdown (xsltTransformContextPtr ctxt ATTRIBUTE_UNUSED,
@@ -188,6 +193,7 @@
  * @URI: the namespace URI for the extension
  *
  * Allocates the stylesheet data for EXSLT - Function
+ * Called at compile-time.
  *
  * Returns the allocated data
  */
@@ -201,9 +207,10 @@
  * exsltFuncStyleShutdown:
  * @style: an XSLT stylesheet
  * @URI: the namespace URI for the extension
- * @data: the stylesheet data to free up
+ * @data: the stylesheet data to free up 
  *
  * Shutdown the EXSLT - Function module
+ * Called at compile-time.
  */
 static void
 exsltFuncStyleShutdown (xsltStylesheetPtr style ATTRIBUTE_UNUSED,
@@ -431,8 +438,19 @@
      * Register the function data such that it can be retrieved
      * by exslFuncFunctionFunction
      */
-    data = (xmlHashTablePtr) xsltStyleGetExtData (style,
-						  EXSLT_FUNCTIONS_NAMESPACE);
+#ifdef XSLT_REFACTORED
+    /*
+    * Ensure that the hash table will be stored in the *current*
+    * stylesheet level in order to correctly evaluate the
+    * import precedence.
+    */
+    data = (xmlHashTablePtr)
+	xsltStyleStylesheetLevelGetExtData(style,
+	    EXSLT_FUNCTIONS_NAMESPACE);
+#else
+    data = (xmlHashTablePtr)
+	xsltStyleGetExtData (style, EXSLT_FUNCTIONS_NAMESPACE);
+#endif
     if (data == NULL) {
 	xsltGenericError(xsltGenericErrorContext,
 			 "exsltFuncFunctionComp: no stylesheet data\n");
@@ -441,9 +459,10 @@
     }
 
     if (xmlHashAddEntry2 (data, ns->href, name, func) < 0) {
-	xsltGenericError(xsltGenericErrorContext,
-			 "Failed to register function {%s}%s\n",
+	xsltTransformError(NULL, style, inst,
+	    "Failed to register function {%s}%s\n",
 			 ns->href, name);
+	style->errors++;
     } else {
 	xsltGenericDebug(xsltGenericDebugContext,
 			 "exsltFuncFunctionComp: register {%s}%s\n",

Modified: packages/libxslt/trunk/libxslt/Makefile.in
===================================================================
--- packages/libxslt/trunk/libxslt/Makefile.in	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/libxslt/Makefile.in	2006-06-08 22:29:07 UTC (rev 565)
@@ -119,6 +119,7 @@
 EXTRA_LIBS = @EXTRA_LIBS@
 F77 = @F77@
 FFLAGS = @FFLAGS@
+GREP = @GREP@
 HTML_DIR = @HTML_DIR@
 INSTALL_DATA = @INSTALL_DATA@
 INSTALL_PROGRAM = @INSTALL_PROGRAM@
@@ -204,12 +205,9 @@
 XSLT_INCLUDEDIR = @XSLT_INCLUDEDIR@
 XSLT_LIBDIR = @XSLT_LIBDIR@
 XSLT_LIBS = @XSLT_LIBS@
-ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_CXX = @ac_ct_CXX@
 ac_ct_F77 = @ac_ct_F77@
-ac_ct_RANLIB = @ac_ct_RANLIB@
-ac_ct_STRIP = @ac_ct_STRIP@
 am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
 am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
 am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@
@@ -226,23 +224,30 @@
 build_os = @build_os@
 build_vendor = @build_vendor@
 datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
 exec_prefix = @exec_prefix@
 host = @host@
 host_alias = @host_alias@
 host_cpu = @host_cpu@
 host_os = @host_os@
 host_vendor = @host_vendor@
+htmldir = @htmldir@
 includedir = @includedir@
 infodir = @infodir@
 install_sh = @install_sh@
 libdir = @libdir@
 libexecdir = @libexecdir@
+localedir = @localedir@
 localstatedir = @localstatedir@
 mandir = @mandir@
 mkdir_p = @mkdir_p@
 oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
 prefix = @prefix@
 program_transform_name = @program_transform_name@
+psdir = @psdir@
 pythondir = @pythondir@
 sbindir = @sbindir@
 sharedstatedir = @sharedstatedir@

Modified: packages/libxslt/trunk/libxslt/attributes.c
===================================================================
--- packages/libxslt/trunk/libxslt/attributes.c	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/libxslt/attributes.c	2006-06-08 22:29:07 UTC (rev 565)
@@ -38,6 +38,7 @@
 #include <libxml/hash.h>
 #include <libxml/xmlerror.h>
 #include <libxml/uri.h>
+#include <libxml/parserInternals.h>
 #include "xslt.h"
 #include "xsltInternals.h"
 #include "xsltutils.h"
@@ -46,6 +47,7 @@
 #include "templates.h"
 #include "imports.h"
 #include "transform.h"
+#include "preproc.h"
 
 #define WITH_XSLT_DEBUG_ATTRIBUTES
 #ifdef WITH_XSLT_DEBUG
@@ -63,6 +65,9 @@
 /*
  * Useful macros
  */
+#ifdef IS_BLANK
+#undef IS_BLANK
+#endif
 
 #define IS_BLANK(c) (((c) == 0x20) || ((c) == 0x09) || ((c) == 0xA) ||	\
                      ((c) == 0x0D))
@@ -143,6 +148,11 @@
     }
 }
 
+#ifdef XSLT_REFACTORED
+    /*
+    * This was moved to xsltParseStylesheetAttributeSet().
+    */
+#else
 /**
  * xsltAddAttrElemList:
  * @list:  an XSLT AttrElem list
@@ -161,7 +171,7 @@
     if (list == NULL)
 	return(xsltNewAttrElem(attr));
     cur = list;
-    while (cur != NULL) {
+    while (cur != NULL) {	
 	next = cur->next;
 	if (cur->attr == attr)
 	    return(cur);
@@ -173,6 +183,7 @@
     }
     return(list);
 }
+#endif /* XSLT_REFACTORED */
 
 /**
  * xsltMergeAttrElemList:
@@ -185,7 +196,8 @@
  * Returns the new list pointer
  */
 static xsltAttrElemPtr
-xsltMergeAttrElemList(xsltAttrElemPtr list, xsltAttrElemPtr old) {
+xsltMergeAttrElemList(xsltStylesheetPtr style,
+		      xsltAttrElemPtr list, xsltAttrElemPtr old) {
     xsltAttrElemPtr cur;
     int add;
 
@@ -233,19 +245,23 @@
 	}
 
 	if (add == 1) {
+	    /*
+	    * Changed to use the string-dict, rather than duplicating
+	    * @set and @ns; this fixes bug #340400.
+	    */
 	    if (cur == NULL) {
 		list = xsltNewAttrElem(old->attr);
 		if (old->set != NULL) {
-		    list->set = xmlStrdup(old->set);
+		    list->set = xmlDictLookup(style->dict, old->set, -1);
 		    if (old->ns != NULL)
-			list->ns = xmlStrdup(old->ns);
+			list->ns = xmlDictLookup(style->dict, old->ns, -1);
 		}
 	    } else if (add) {
 		cur->next = xsltNewAttrElem(old->attr);
 		if (old->set != NULL) {
-		    cur->next->set = xmlStrdup(old->set);
+		    cur->next->set = xmlDictLookup(style->dict, old->set, -1);
 		    if (old->ns != NULL)
-			cur->next->ns = xmlStrdup(old->ns);
+			cur->next->ns = xmlDictLookup(style->dict, old->ns, -1);
 		}
 	    }
 	}
@@ -273,24 +289,23 @@
 xsltParseStylesheetAttributeSet(xsltStylesheetPtr style, xmlNodePtr cur) {
     const xmlChar *ncname;
     const xmlChar *prefix;
-    const xmlChar *attrib, *endattr;
-    xmlChar *prop;
-    xmlChar *attributes;
-    xmlNodePtr list;
-    xsltAttrElemPtr values;
+    xmlChar *value;
+    xmlNodePtr child;
+    xsltAttrElemPtr attrItems;
 
     if ((cur == NULL) || (style == NULL))
 	return;
 
-    prop = xmlGetNsProp(cur, (const xmlChar *)"name", NULL);
-    if (prop == NULL) {
+    value = xmlGetNsProp(cur, (const xmlChar *)"name", NULL);
+    if (value == NULL) {
 	xsltGenericError(xsltGenericErrorContext,
 	     "xsl:attribute-set : name is missing\n");
 	return;
     }
 
-    ncname = xsltSplitQName(style->dict, prop, &prefix);
-    xmlFree(prop);
+    ncname = xsltSplitQName(style->dict, value, &prefix);
+    xmlFree(value);
+    value = NULL;
 
     if (style->attributeSets == NULL) {
 #ifdef WITH_XSLT_DEBUG_ATTRIBUTES
@@ -302,80 +317,141 @@
     if (style->attributeSets == NULL)
 	return;
 
-    values = xmlHashLookup2(style->attributeSets, ncname, prefix);
+    attrItems = xmlHashLookup2(style->attributeSets, ncname, prefix);
 
     /*
-     * check the children list
-     */
-    list = cur->children;
-    while (list != NULL) {
-	if (IS_XSLT_ELEM(list)) {
-	    if (!IS_XSLT_NAME(list, "attribute")) {
-		xsltGenericError(xsltGenericErrorContext,
-		    "xsl:attribute-set : unexpected child xsl:%s\n",
-		                 list->name);
+    * Parse the content. Only xsl:attribute elements are allowed.
+    */
+    child = cur->children;
+    while (child != NULL) {
+	/*
+	* Report invalid nodes.
+	*/
+	if ((child->type != XML_ELEMENT_NODE) ||
+	    (child->ns == NULL) ||
+	    (! IS_XSLT_ELEM(child)))
+	{
+	    if (child->type == XML_ELEMENT_NODE)
+		xsltTransformError(NULL, style, child,
+			"xsl:attribute-set : unexpected child %s\n",
+		                 child->name);
+	    else
+		xsltTransformError(NULL, style, child,
+			"xsl:attribute-set : child of unexpected type\n");
+	} else if (!IS_XSLT_NAME(child, "attribute")) {
+	    xsltTransformError(NULL, style, child,
+		"xsl:attribute-set : unexpected child xsl:%s\n",
+		child->name);
+	} else {
+#ifdef XSLT_REFACTORED
+	    xsltAttrElemPtr nextAttr, curAttr;
+
+	    /*
+	    * Process xsl:attribute
+	    * ---------------------
+	    */
+
+#ifdef WITH_XSLT_DEBUG_ATTRIBUTES
+	    xsltGenericDebug(xsltGenericDebugContext,
+		"add attribute to list %s\n", ncname);
+#endif
+	    /*
+	    * The following was taken over from
+	    * xsltAddAttrElemList().
+	    */
+	    if (attrItems == NULL) {
+		attrItems = xsltNewAttrElem(child);
 	    } else {
+		curAttr = attrItems;
+		while (curAttr != NULL) {
+		    nextAttr = curAttr->next;
+		    if (curAttr->attr == child) {
+			/*
+			* URGENT TODO: Can somebody explain
+			*  why attrItems is set to curAttr
+			*  here? Is this somehow related to
+			*  avoidance of recursions?
+			*/
+			attrItems = curAttr;
+			goto next_child;
+		    }
+		    if (curAttr->next == NULL)			
+			curAttr->next = xsltNewAttrElem(child);
+		    curAttr = nextAttr;
+		}
+	    }
+	    /*
+	    * Parse the xsl:attribute and its content.
+	    */
+	    xsltParseAnyXSLTElem(XSLT_CCTXT(style), child);
+#else
 #ifdef WITH_XSLT_DEBUG_ATTRIBUTES
-		xsltGenericDebug(xsltGenericDebugContext,
-		    "add attribute to list %s\n", ncname);
+	    xsltGenericDebug(xsltGenericDebugContext,
+		"add attribute to list %s\n", ncname);
 #endif
-                values = xsltAddAttrElemList(values, list);
-	    }
-	} else {
-	    xsltGenericError(xsltGenericErrorContext,
-		"xsl:attribute-set : unexpected child %s\n", list->name);
+	    /*
+	    * OLD behaviour:
+	    */
+	    attrItems = xsltAddAttrElemList(attrItems, child);
+#endif
 	}
-	list = list->next;
+
+#ifdef XSLT_REFACTORED
+next_child:
+#endif
+	child = child->next;
     }
 
     /*
-     * Check a possible use-attribute-sets definition
-     */
-    /* TODO check recursion */
-
-    attributes = xmlGetNsProp(cur, (const xmlChar *)"use-attribute-sets",
+    * Process attribue "use-attribute-sets".
+    */
+    /* TODO check recursion */    
+    value = xmlGetNsProp(cur, (const xmlChar *)"use-attribute-sets",
 	NULL);
-    if (attributes == NULL) {
-	goto done;
-    }
-
-    attrib = attributes;
-    while (*attrib != 0) {
-	while (IS_BLANK(*attrib)) attrib++;
-	if (*attrib == 0)
-	    break;
-        endattr = attrib;
-	while ((*endattr != 0) && (!IS_BLANK(*endattr))) endattr++;
-	attrib = xmlDictLookup(style->dict, attrib, endattr - attrib);
-	if (attrib) {
-	    const xmlChar *ncname2 = NULL;
-	    const xmlChar *prefix2 = NULL;
-	    xsltAttrElemPtr values2;
-
+    if (value != NULL) {
+	const xmlChar *curval, *endval;
+	curval = value;
+	while (*curval != 0) {
+	    while (IS_BLANK(*curval)) curval++;
+	    if (*curval == 0)
+		break;
+	    endval = curval;
+	    while ((*endval != 0) && (!IS_BLANK(*endval))) endval++;
+	    curval = xmlDictLookup(style->dict, curval, endval - curval);
+	    if (curval) {
+		const xmlChar *ncname2 = NULL;
+		const xmlChar *prefix2 = NULL;
+		xsltAttrElemPtr refAttrItems;
+		
 #ifdef WITH_XSLT_DEBUG_ATTRIBUTES
-	    xsltGenericDebug(xsltGenericDebugContext,
-		"xsl:attribute-set : %s adds use %s\n", ncname, attrib);
+		xsltGenericDebug(xsltGenericDebugContext,
+		    "xsl:attribute-set : %s adds use %s\n", ncname, curval);
 #endif
-	    ncname2 = xsltSplitQName(style->dict, attrib, &prefix2);
-	    values2 = xsltNewAttrElem(NULL);
-	    if (values2 != NULL) {
-		values2->set = ncname2;
-		values2->ns = prefix2;
-		values = xsltMergeAttrElemList(values, values2);
-		xsltFreeAttrElem(values2);
+		ncname2 = xsltSplitQName(style->dict, curval, &prefix2);
+		refAttrItems = xsltNewAttrElem(NULL);
+		if (refAttrItems != NULL) {
+		    refAttrItems->set = ncname2;
+		    refAttrItems->ns = prefix2;
+		    attrItems = xsltMergeAttrElemList(style,
+			attrItems, refAttrItems);
+		    xsltFreeAttrElem(refAttrItems);
+		}
 	    }
+	    curval = endval;
 	}
-	attrib = endattr;
+	xmlFree(value);
+	value = NULL;
     }
-    xmlFree(attributes);
 
-done:
     /*
      * Update the value
      */
-    if (values == NULL)
-	values = xsltNewAttrElem(NULL);
-    xmlHashUpdateEntry2(style->attributeSets, ncname, prefix, values, NULL);
+    /*
+    * TODO: Why is this dummy entry needed.?
+    */
+    if (attrItems == NULL)
+	attrItems = xsltNewAttrElem(NULL);
+    xmlHashUpdateEntry2(style->attributeSets, ncname, prefix, attrItems, NULL);
 #ifdef WITH_XSLT_DEBUG_ATTRIBUTES
     xsltGenericDebug(xsltGenericDebugContext,
 	"updated attribute list %s\n", ncname);
@@ -447,15 +523,12 @@
 		    /*
 		     * Then merge
 		     */
-		    xsltMergeAttrElemList(values, refs);
+		    xsltMergeAttrElemList(style, values, refs);
 		    /*
 		     * Then suppress the reference
 		     */
-		    xmlFree((char *)tmp->set);
 		    tmp->set = NULL;
-		    if (tmp->ns != NULL) {
-			xmlFree((char *)tmp->ns);
-		    }
+		    tmp->ns = NULL;
 		}
 	    }
 	}
@@ -492,7 +565,7 @@
 	        "xsl:attribute-set : logic error merging from imports for"
 		" attribute-set %s\n", name);
 	} else {
-	    topSet = xsltMergeAttrElemList(topSet, values);
+	    topSet = xsltMergeAttrElemList(style, topSet, values);
 	    xmlHashUpdateEntry2(style->attributeSets, name, ns, topSet, NULL);
 	}
 	xsltFreeAttrElemList(values);
@@ -557,9 +630,9 @@
  * xsltAttributeInternal:
  * @ctxt:  a XSLT process context
  * @node:  the node in the source tree.
- * @inst:  the xslt attribute node
+ * @inst:  the xsl:attribute element
  * @comp:  precomputed information
- * @fromset:  the attribute comes from an attribute-set
+ * @fromAttributeSet:  the attribute comes from an attribute-set
  *
  * Process the xslt attribute node on the source node
  */
@@ -567,59 +640,113 @@
 xsltAttributeInternal(xsltTransformContextPtr ctxt, xmlNodePtr node,
                       xmlNodePtr inst,
 		      xsltStylePreCompPtr castedComp,
-                      int fromset) {
+                      int fromAttributeSet) {
 #ifdef XSLT_REFACTORED
     xsltStyleItemAttributePtr comp =
 	(xsltStyleItemAttributePtr) castedComp;
+    /*
+    * TODO: Change the fields of the compiled struct:
+    *  1) @name (char)
+    *  2) @nameType (String, AVT)
+    *  3) @nsName (char)
+    *  4) nsNameType (None, String, AVT)
+    */
 #else
     xsltStylePreCompPtr comp = castedComp;
 #endif
-    xmlChar *prop = NULL;
-    xmlChar *namespace;
-    const xmlChar *name = NULL;
-    const xmlChar *prefix = NULL;
+    xmlNodePtr targetElem;
+    xmlChar *prop = NULL;    
+    const xmlChar *name = NULL, *prefix = NULL, *nsName = NULL;
     xmlChar *value = NULL;
     xmlNsPtr ns = NULL;
-    xmlAttrPtr attr;
-    const xmlChar *URL = NULL;
+    xmlAttrPtr attr;    
 
+    if ((ctxt == NULL) || (node == NULL) || (inst == NULL))
+        return;
+    /*
+    * BIG NOTE: This previously used xsltGetSpecialNamespace() and
+    *  xsltGetNamespace(), but since both are not appropriate, we
+    *  will process namespace lookup here to avoid adding yet another
+    *  ns-lookup function to namespaces.c.
+    */
+    /*
+    * SPEC XSLT 1.0: Error cases:
+    * - Creating nodes other than text nodes during the instantiation of
+    *   the content of the xsl:attribute element; implementations may
+    *   either signal the error or ignore the offending nodes."
+    */
 
-    if ((comp == NULL) || (ctxt == NULL)) {
+    if (comp == NULL) {
         xsltTransformError(ctxt, NULL, inst,
-                         "xsl:attribute : compilation failed\n");
+	    "Internal error in xsltAttributeInternal(): "
+	    "The instruction was no compiled.\n");
         return;
-    }
+    }    
+    /*
+    * TODO: Shouldn't ctxt->insert == NULL be treated as an internal error?
+    *   So report an internal error?
+    */
     if (ctxt->insert == NULL)
+        return;    
+    /*
+    * SPEC XSLT 1.0:
+    *  "Adding an attribute to a node that is not an element;
+    *  implementations may either signal the error or ignore the attribute."
+    *
+    * TODO: I think we should signal such errors in the future, and maybe
+    *  provide an option to ignore such errors.
+    */
+    targetElem = ctxt->insert;
+    if (targetElem->type != XML_ELEMENT_NODE)
+	return;
+    
+    /*
+    * SPEC XSLT 1.0:
+    * "Adding an attribute to an element after children have been added
+    *  to it; implementations may either signal the error or ignore the
+    *  attribute."
+    *
+    * TODO: We should decide whether not to report such errors or
+    *  to ignore them; note that we *ignore* if the parent is not an
+    *  element, but here we report an error.
+    */
+    if (targetElem->children != NULL) {
+	/*
+	* NOTE: Ah! This seems to be intended to support streamed
+	*  result generation!.
+	*/
+        xsltTransformError(ctxt, NULL, inst,
+	    "xsl:attribute: Cannot add attributes to an "
+	    "element if children have been already added "
+	    "to the element.\n");
         return;
+    }
 
-    if ((node == NULL) || (inst == NULL) || (comp == NULL))
+    /*
+    * Process the name
+    * ----------------
+    */
+    if (!comp->has_name) /* TODO: raise error */
         return;
-    if (!comp->has_name) {
-        return;
-    }
-    if (ctxt->insert->children != NULL) {
-        xsltTransformError(ctxt, NULL, inst,
-                         "xsl:attribute : node already has children\n");
-        return;
-    }
+
 #ifdef WITH_DEBUGGER
-    if (ctxt->debugStatus != XSLT_DEBUG_NONE) {
+    if (ctxt->debugStatus != XSLT_DEBUG_NONE)
         xslHandleDebugger(inst, node, NULL, ctxt);
-    }
 #endif
 
     if (comp->name == NULL) {
-        prop =
-            xsltEvalAttrValueTemplate(ctxt, inst, (const xmlChar *) "name",
-                                      XSLT_NAMESPACE);
+	/* TODO: fix attr acquisition wrt to the XSLT namespace */
+        prop = xsltEvalAttrValueTemplate(ctxt, inst,
+	    (const xmlChar *) "name", XSLT_NAMESPACE);
         if (prop == NULL) {
             xsltTransformError(ctxt, NULL, inst,
-                             "xsl:attribute : name is missing\n");
+		"xsl:attribute: The attribute 'name' is missing.\n");
             goto error;
         }
 	if (xmlValidateQName(prop, 0)) {
 	    xsltTransformError(ctxt, NULL, inst,
-			    "xsl:attribute : invalid QName\n");
+		"xsl:attribute: The effective name '%s' is not a "
+		"valid QName.\n", prop);
 	    /* we fall through to catch any further errors, if possible */
 	}
 	name = xsltSplitQName(ctxt->dict, prop, &prefix);
@@ -631,72 +758,286 @@
     if (!xmlStrncasecmp(prefix, (xmlChar *) "xmlns", 5)) {
 #ifdef WITH_XSLT_DEBUG_PARSING
         xsltGenericDebug(xsltGenericDebugContext,
-                         "xsltAttribute: xmlns prefix forbidden\n");
+	    "xsltAttribute: xmlns prefix forbidden\n");
 #endif
+	/*
+	* SPEC XSLT 1.0:
+	*  "It is an error if the string that results from instantiating
+	*  the attribute value template is not a QName or is the string
+	*  xmlns. An XSLT processor may signal the error; if it does not
+	*  signal the error, it must recover by not adding the attribute
+	*  to the result tree."
+	* TODO: Decide which way to go here.
+	*/
         goto error;
     }
-    if ((comp->ns == NULL) && (comp->has_ns)) {
-        namespace = xsltEvalAttrValueTemplate(ctxt, inst,
-                                              (const xmlChar *)
-                                              "namespace", XSLT_NAMESPACE);
-        if (namespace != NULL) {
-            ns = xsltGetSpecialNamespace(ctxt, inst, namespace, prefix,
-                                         ctxt->insert);
-            xmlFree(namespace);
-        } else {
-            if (prefix != NULL) {
-                ns = xmlSearchNs(inst->doc, inst, prefix);
-                if (ns == NULL) {
-                    xsltTransformError(ctxt, NULL, inst,
-			 "xsl:attribute : no namespace bound to prefix %s\n",
-                                     prefix);
-                } else {
-                    ns = xsltGetNamespace(ctxt, inst, ns, ctxt->insert);
-                }
-            }
-        }
-    } else if (comp->ns != NULL) {
-        ns = xsltGetSpecialNamespace(ctxt, inst, comp->ns, prefix,
-                                     ctxt->insert);
+    /*
+    * Process namespace semantics
+    * ---------------------------
+    *
+    * Evaluate the namespace name.
+    */
+    if (comp->has_ns) {	 
+	if (comp->ns != NULL) {
+	    if (comp->ns[0] != 0)
+		nsName = comp->ns;
+	} else {
+	    xmlChar *tmpNsName;
+	    /*
+	    * Eval the AVT.
+	    */
+	    /* TODO: check attr acquisition wrt to the XSLT namespace */
+	    tmpNsName = xsltEvalAttrValueTemplate(ctxt, inst,
+		(const xmlChar *) "namespace", XSLT_NAMESPACE);	
+	    /*
+	    * This fixes bug #302020: The AVT might also evaluate to the 
+	    * empty string; this means that the empty string also indicates
+	    * "no namespace".
+	    * SPEC XSLT 1.0:
+	    *  "If the string is empty, then the expanded-name of the
+	    *  attribute has a null namespace URI."
+	    */
+	    if ((tmpNsName != NULL) && (tmpNsName[0] != 0))
+		nsName = xmlDictLookup(ctxt->dict, BAD_CAST tmpNsName, -1);
+	    xmlFree(tmpNsName);		
+	};	    
     } else if (prefix != NULL) {
-	xmlNsPtr tmp;
-	tmp = xmlSearchNs(inst->doc, inst, prefix);
-	if (tmp != NULL) {
-	    ns = xsltGetNamespace(ctxt, inst, tmp, ctxt->insert);
-	}
+	/*
+	* SPEC XSLT 1.0:
+	*  "If the namespace attribute is not present, then the QName is
+	*  expanded into an expanded-name using the namespace declarations
+	*  in effect for the xsl:attribute element, *not* including any
+	*  default namespace declaration."
+	*/	
+	ns = xmlSearchNs(inst->doc, inst, prefix);
+	if (ns == NULL) {
+	    /*
+	    * Note that this is treated as an error now (checked with
+	    *  Saxon, Xalan-J and MSXML).
+	    */
+	    xsltTransformError(ctxt, NULL, inst,
+		"xsl:attribute: The effective prefix '%s', has no "
+		"namespace binding in scope in the stylesheet; "
+		"this is an error, since the namespace was not "
+		"specified by the instruction itself.\n", prefix);
+	} else
+	    nsName = ns->href;	
     }
 
-    if ((fromset) && (ns != NULL))
-        URL = ns->href;
-
-    if (fromset) {
-	if (URL != NULL)
-	    attr = xmlHasNsProp(ctxt->insert, name, URL);
-	else
-	    attr = xmlHasProp(ctxt->insert, name);
+    if (fromAttributeSet) {
+	/*
+	* I think this tries to ensure that xsl:attribute(s) coming
+	* from an xsl:attribute-set won't override attribute of
+	* literal result elements or of explicit xsl:attribute(s).
+	*/
+	attr = xmlHasNsProp(targetElem, name, nsName);
 	if (attr != NULL)
 	    return;
     }
-    value = xsltEvalTemplateString(ctxt, node, inst);
-    if (value == NULL) {
-        if (ns) {
-            attr = xmlSetNsProp(ctxt->insert, ns, name,
-                                (const xmlChar *) "");
-        } else {
-            attr =
-                xmlSetProp(ctxt->insert, name, (const xmlChar *) "");
-        }
+
+    /*
+    * Something about ns-prefixes:
+    * SPEC XSLT 1.0:
+    *  "XSLT processors may make use of the prefix of the QName specified
+    *  in the name attribute when selecting the prefix used for outputting
+    *  the created attribute as XML; however, they are not required to do
+    *  so and, if the prefix is xmlns, they must not do so"
+    */        
+    /*
+    * Find/create a matching ns-decl in the result tree.
+    */
+    ns = NULL;
+#if 0
+    if (0) {	
+	/*
+	* OPTIMIZE TODO: How do we know if we are adding to a
+	*  fragment or not?
+	*
+	* If we are adding to a result tree fragment (i.e., not to the
+	* actual result tree), we'll don't bother searching for the
+	* ns-decl, but just store it in the dummy-doc of the result
+	* tree fragment.
+	*/
+	if (nsName != NULL) {
+	    ns = xsltTreeAcquireStoredNs(ctxt->document->doc, nsName,
+		prefix);
+	}
+    }
+#endif
+    if (nsName != NULL) {
+	/*
+	* The owner-element might be in the same namespace.
+	*/
+	if ((targetElem->ns != NULL) &&
+	    (targetElem->ns->prefix != NULL) &&	    
+	    xmlStrEqual(targetElem->ns->href, nsName))
+	{
+	    ns = targetElem->ns;
+	    goto namespace_finished;
+	}
+	if (prefix != NULL) {
+	    /*
+	    * Search by ns-prefix.
+	    */
+	    ns = xmlSearchNs(targetElem->doc, targetElem, prefix);
+	    if ((ns != NULL) && (xmlStrEqual(ns->href, nsName))) {
+		goto namespace_finished;
+	    }
+	}
+	/*
+	* Fallback to a search by ns-name.
+	*/	
+	ns = xmlSearchNsByHref(targetElem->doc, targetElem, nsName);
+	if ((ns != NULL) && (ns->prefix != NULL)) {
+	    goto namespace_finished;
+	}
+	/*
+	* OK, we need to declare the namespace on the target element.
+	*/
+	if (prefix) {
+	    if (targetElem->nsDef != NULL) {
+		ns = targetElem->nsDef;
+		do {
+		    if ((ns->prefix) && xmlStrEqual(ns->prefix, prefix)) {
+			/*
+			* The prefix is aready occupied.
+			*/
+			break;
+		    }
+		    ns = ns->next;
+		} while (ns != NULL);
+		if (ns == NULL) {
+		    ns = xmlNewNs(targetElem, nsName, prefix);
+		    goto namespace_finished;
+		}
+	    }
+	}
+	/*
+	* Generate a new prefix.
+	*/
+	{
+	    const xmlChar *basepref = prefix;
+	    xmlChar pref[30];
+	    int counter = 1;
+	    
+	    if (prefix != NULL)
+		basepref = prefix;
+	    else
+		basepref = xmlStrdup(BAD_CAST "ns");
+	    
+	    do {
+		snprintf((char *) pref, 30, "%s%d",
+		    basepref, counter++);
+		ns = xmlSearchNs(targetElem->doc, targetElem, BAD_CAST pref);
+		if (counter > 1000) {
+		    xsltTransformError(ctxt, NULL, inst,
+		    	"Namespace fixup error: Failed to compute a "
+			"new unique ns-prefix for the generated attribute "
+			"{%s}%s'.\n", nsName, name);		    			
+		    ns = NULL;
+		    break;
+		}
+	    } while (ns != NULL);
+	    if (basepref != prefix)
+		xmlFree((xmlChar *)basepref);
+	    ns = xmlNewNs(targetElem, nsName, BAD_CAST pref);
+	}
+
+namespace_finished:
+
+	if (ns == NULL) {
+	    xsltTransformError(ctxt, NULL, inst,
+		"Namespace fixup error: Failed to acquire an in-scope "
+		"namespace binding of the generated attribute '{%s}%s'.\n",
+		nsName, name);
+	    /*
+	    * TODO: Should we just stop here?
+	    */
+	}
+    }
+    /*
+    * Construction of the value
+    * -------------------------
+    */
+    if (inst->children == NULL) {
+	/*
+	* No content.
+	* TODO: Do we need to put the empty string in ?
+	*/
+	attr = xmlSetNsProp(ctxt->insert, ns, name, (const xmlChar *) "");
+    } else if ((inst->children->next == NULL) && 
+	    ((inst->children->type == XML_TEXT_NODE) ||
+	     (inst->children->type == XML_CDATA_SECTION_NODE)))
+    {
+	xmlNodePtr origTxt = inst->children, copyTxt;
+	/*
+	* Optimization: if the content is just 1 text node, then
+	* just need to copy it over, or just assign it to the result
+	* if the string is shared.
+	*/
+	attr = xmlSetNsProp(ctxt->insert, ns, name, NULL);
+	if (attr == NULL) /* TODO: report error ? */
+	    goto error;
+	/*
+	* This was taken over from xsltCopyText() (transform.c).
+	*/
+	if (ctxt->internalized &&
+	    (ctxt->insert->doc != NULL) &&
+	    (ctxt->insert->doc->dict == ctxt->dict))
+	{
+	    copyTxt = xmlNewText(NULL);
+	    if (copyTxt == NULL) /* TODO: report error */
+		goto error;
+	    /*
+	    * This is a safe scenario where we don't need to lookup
+	    * the dict.
+	    */
+	    copyTxt->content = origTxt->content;
+	    /*
+	    * Copy "disable-output-escaping" information.
+	    * TODO: Does this have any effect for attribute values
+	    *  anyway?
+	    */
+	    if (origTxt->name == xmlStringTextNoenc)
+		copyTxt->name = xmlStringTextNoenc;
+	} else {
+	    /*
+	    * Copy the value.
+	    */
+	    copyTxt = xmlNewText(origTxt->content);
+	    if (copyTxt == NULL) /* TODO: report error */
+		goto error;
+	    /*
+	    * Copy "disable-output-escaping" information.
+	    * TODO: Does this have any effect for attribute values
+	    *  anyway?
+	    */
+	    if (origTxt->name == xmlStringTextNoenc)
+		copyTxt->name = xmlStringTextNoenc;
+	}
+	if (copyTxt != NULL) {
+	    copyTxt->doc = attr->doc;
+	    xmlAddChild((xmlNodePtr) attr, copyTxt);
+	}
     } else {
-        if (ns) {
-            attr = xmlSetNsProp(ctxt->insert, ns, name, value);
-        } else {
-            attr = xmlSetProp(ctxt->insert, name, value);
-        }
+	/*
+	* The sequence constructor might be complex, so instantiate it.
+	*/
+	value = xsltEvalTemplateString(ctxt, node, inst);
+	if (value != NULL) {
+	    attr = xmlSetNsProp(ctxt->insert, ns, name, value);
+	    xmlFree(value);
+	} else {
+	    /*
+	    * TODO: Do we have to add the empty string to the attr?
+	    */
+	    attr = xmlSetNsProp(ctxt->insert, ns, name,
+		(const xmlChar *) "");
+	}
     }
 
 error:
-    if (value != NULL)
-        xmlFree(value);
+    return;    
 }
 
 /**

Modified: packages/libxslt/trunk/libxslt/documents.c
===================================================================
--- packages/libxslt/trunk/libxslt/documents.c	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/libxslt/documents.c	2006-06-08 22:29:07 UTC (rev 565)
@@ -153,11 +153,24 @@
     memset(cur, 0, sizeof(xsltDocument));
     cur->doc = doc;
     if (ctxt != NULL) {
-        if (!xmlStrEqual((xmlChar *)doc->name, BAD_CAST " fake node libxslt")) {
+        if (! XSLT_IS_RES_TREE_FRAG(doc)) {
 	    cur->next = ctxt->docList;
 	    ctxt->docList = cur;
 	}
+#ifdef XSLT_REFACTORED_KEYCOMP
+	/*
+	* A key with a specific name for a specific document
+	* will only be computed if there's a call to the key()
+	* function using that specific name for that specific
+	* document. I.e. computation of keys will be done in
+	* xsltGetKey() (keys.c) on an on-demand basis.
+	*/
+#else
+	/*
+	* Old behaviour.
+	*/
 	xsltInitCtxtKeys(ctxt, cur);
+#endif
     }
     return(cur);
 }
@@ -192,18 +205,40 @@
 
 /**
  * xsltFreeStyleDocuments:
- * @style: an XSLT style sheet
+ * @style: an XSLT stylesheet (representing a stylesheet-level)
  *
- * Free up all the space used by the loaded documents
+ * Frees the node-trees (and xsltDocument structures) of all
+ * stylesheet-modules of the stylesheet-level represented by
+ * the given @style. 
  */
 void	
 xsltFreeStyleDocuments(xsltStylesheetPtr style) {
     xsltDocumentPtr doc, cur;
+#ifdef XSLT_REFACTORED_XSLT_NSCOMP
+    xsltNsMapPtr nsMap;
+#endif
+    
+    if (style == NULL)
+	return;
 
+#ifdef XSLT_REFACTORED_XSLT_NSCOMP
+    if (XSLT_HAS_INTERNAL_NSMAP(style))
+	nsMap = XSLT_GET_INTERNAL_NSMAP(style);
+    else
+	nsMap = NULL;    
+#endif   
+
     cur = style->docList;
     while (cur != NULL) {
 	doc = cur;
 	cur = cur->next;
+#ifdef XSLT_REFACTORED_XSLT_NSCOMP
+	/*
+	* Restore all changed namespace URIs of ns-decls.
+	*/
+	if (nsMap)
+	    xsltRestoreDocumentNamespaces(nsMap, doc->doc);
+#endif
 	xsltFreeDocumentKeys(doc);
 	if (!doc->main)
 	    xmlFreeDoc(doc->doc);

Modified: packages/libxslt/trunk/libxslt/extensions.c
===================================================================
--- packages/libxslt/trunk/libxslt/extensions.c	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/libxslt/extensions.c	2006-06-08 22:29:07 UTC (rev 565)
@@ -469,12 +469,19 @@
 /**
  * xsltRegisterExtPrefix:
  * @style: an XSLT stylesheet
- * @prefix: the prefix used
+ * @prefix: the prefix used (optional)
  * @URI: the URI associated to the extension
- *
+ * 
  * Registers an extension namespace
+ * This is called from xslt.c during compile-time.
+ * The given prefix is not needed.
+ * Called by:
+ *   xsltParseExtElemPrefixes() (new function)
+ *   xsltRegisterExtPrefix() (old function)
  *
- * Returns 0 in case of success, -1 in case of failure
+ * Returns 0 in case of success, 1 if the @URI was already
+ *         registered as an extension namespace and
+ *         -1 in case of failure
  */
 int
 xsltRegisterExtPrefix(xsltStylesheetPtr style,
@@ -482,20 +489,30 @@
 {
     xsltExtDefPtr def, ret;
 
-    if ((style == NULL) || (prefix == NULL) | (URI == NULL))
+    if ((style == NULL) || (URI == NULL))
         return (-1);
 
 #ifdef WITH_XSLT_DEBUG_EXTENSIONS
     xsltGenericDebug(xsltGenericDebugContext,
-                     "Registering extension prefix %s : %s\n", prefix,
-                     URI);
+	"Registering extension namespace '%s'.\n", URI);
 #endif
     def = (xsltExtDefPtr) style->nsDefs;
+#ifdef XSLT_REFACTORED
+    /*
+    * The extension is associated with a namespace name.
+    */
     while (def != NULL) {
+        if (xmlStrEqual(URI, def->URI))
+            return (1);
+        def = def->next;
+    }
+#else
+    while (def != NULL) {
         if (xmlStrEqual(prefix, def->prefix))
             return (-1);
         def = def->next;
     }
+#endif
     ret = xsltNewExtDef(prefix, URI);
     if (ret == NULL)
         return (-1);
@@ -506,6 +523,12 @@
      * check wether there is an extension module with a stylesheet
      * initialization function.
      */
+#ifdef XSLT_REFACTORED
+    /*
+    * Don't initialize modules based on specified namespaced via
+    * the attribute "[xsl:]extension-element-prefixes".
+    */
+#else
     if (xsltExtensionsHash != NULL) {
         xsltExtModulePtr module;
 
@@ -515,11 +538,11 @@
                 module = xmlHashLookup(xsltExtensionsHash, URI);
             }
         }
-
         if (module != NULL) {
             xsltStyleGetExtData(style, URI);
         }
     }
+#endif
     return (0);
 }
 
@@ -600,85 +623,200 @@
 }
 
 /**
- * xsltStyleGetExtData:
+ * xsltStyleGetStylesheetExtData:
  * @style: an XSLT stylesheet
  * @URI:  the URI associated to the exension module
  *
- * Retrieve the data associated to the extension module in this given
- * stylesheet.
+ * Fires the compile-time initialization callback
+ * of an extension module and returns a container
+ * holding the user-data (retrieved via the callback).
  *
- * Returns the pointer or NULL if not present
+ * Returns the create module-data container
+ *         or NULL if such a module was not registered.
  */
-void *
-xsltStyleGetExtData(xsltStylesheetPtr style, const xmlChar * URI)
+static xsltExtDataPtr
+xsltStyleInitializeStylesheetModule(xsltStylesheetPtr style,
+				     const xmlChar * URI)
 {
-    xsltExtDataPtr data = NULL;
-    xsltStylesheetPtr tmp;
+    xsltExtDataPtr dataContainer;
+    void *userData = NULL;
+    xsltExtModulePtr module;
+    
+    if ((style == NULL) || (URI == NULL))	
+	return(NULL);
 
-
-    if ((style == NULL) || (URI == NULL))
-        return (NULL);
-
-    tmp = style;
-    while (tmp != NULL) {
-        if (tmp->extInfos != NULL) {
-            data = (xsltExtDataPtr) xmlHashLookup(tmp->extInfos, URI);
-            if (data != NULL)
-                break;
-        }
-        tmp = xsltNextImport(tmp);
+    if (xsltExtensionsHash == NULL) {
+#ifdef WITH_XSLT_DEBUG_EXTENSIONS
+	xsltGenericDebug(xsltGenericDebugContext,
+	    "Not registered extension module: %s\n", URI);
+#endif
+	return(NULL);
     }
-    if (data == NULL) {
-        if (style->extInfos == NULL) {
-            style->extInfos = xmlHashCreate(10);
-            if (style->extInfos == NULL)
-                return (NULL);
-        }
-    }
-    if (data == NULL) {
-        void *extData;
-        xsltExtModulePtr module;
 
-        module = xmlHashLookup(xsltExtensionsHash, URI);
-        if (module == NULL) {
+    module = xmlHashLookup(xsltExtensionsHash, URI);
+    if (module == NULL) {
 #ifdef WITH_XSLT_DEBUG_EXTENSIONS
-            xsltGenericDebug(xsltGenericDebugContext,
-                             "Not registered extension module: %s\n", URI);
+	xsltGenericDebug(xsltGenericDebugContext,
+	    "Not registered extension module: %s\n", URI);
 #endif
-            return (NULL);
-        } else {
-            if (module->styleInitFunc == NULL) {
+	return (NULL);
+    }
+    /*
+    * The specified module was registered so initialize it.
+    */
+    if (style->extInfos == NULL) {
+	style->extInfos = xmlHashCreate(10);
+	if (style->extInfos == NULL)
+	    return (NULL);
+    }
+    /*
+    * Fire the initialization callback if available.
+    */
+    if (module->styleInitFunc == NULL) {
 #ifdef WITH_XSLT_DEBUG_EXTENSIONS
-                xsltGenericDebug(xsltGenericDebugContext,
-                                 "Registering style module: %s\n", URI);
+	xsltGenericDebug(xsltGenericDebugContext,
+	    "Initializing module with *no* callback: %s\n", URI);
 #endif
-                extData = NULL;
-            } else {
+    } else {
 #ifdef WITH_XSLT_DEBUG_EXTENSIONS
-                xsltGenericDebug(xsltGenericDebugContext,
-                                 "Initializing module: %s\n", URI);
+	xsltGenericDebug(xsltGenericDebugContext,
+	    "Initializing module with callback: %s\n", URI);
 #endif
-                extData = module->styleInitFunc(style, URI);
-            }
+	/*
+	* Fire the initialization callback.
+	*/
+	userData = module->styleInitFunc(style, URI);
+    }    
+    /*
+    * Store the user-data in the context of the given stylesheet.
+    */
+    dataContainer = xsltNewExtData(module, userData);
+    if (dataContainer == NULL)
+	return (NULL);
 
-            data = xsltNewExtData(module, extData);
-            if (data == NULL)
-                return (NULL);
-            if (xmlHashAddEntry(style->extInfos, URI, (void *) data) < 0) {
-                xsltGenericError(xsltGenericErrorContext,
-                                 "Failed to register module data: %s\n",
-                                 URI);
-                if (module->styleShutdownFunc)
-                    module->styleShutdownFunc(style, URI, extData);
-                xsltFreeExtData(data);
-                return (NULL);
-            }
-        }
+    if (xmlHashAddEntry(style->extInfos, URI,
+	(void *) dataContainer) < 0)
+    {
+	xsltTransformError(NULL, style, NULL,	    
+	    "Failed to register module '%s'.\n", URI);
+	style->errors++;
+	if (module->styleShutdownFunc)
+	    module->styleShutdownFunc(style, URI, userData);
+	xsltFreeExtData(dataContainer);
+	return (NULL);
     }
-    return (data->extData);
+
+    return(dataContainer);
 }
 
 /**
+ * xsltStyleGetExtData:
+ * @style: an XSLT stylesheet
+ * @URI:  the URI associated to the exension module
+ *
+ * Retrieve the data associated to the extension module
+ * in this given stylesheet.
+ * Called by:
+ *   xsltRegisterExtPrefix(),
+ *   ( xsltExtElementPreCompTest(), xsltExtInitTest )
+ *
+ * Returns the pointer or NULL if not present
+ */
+void *
+xsltStyleGetExtData(xsltStylesheetPtr style, const xmlChar * URI)
+{
+    xsltExtDataPtr dataContainer = NULL;
+    xsltStylesheetPtr tmpStyle;
+
+    if ((style == NULL) || (URI == NULL) ||
+	(xsltExtensionsHash == NULL))
+	return (NULL);
+
+    
+#ifdef XSLT_REFACTORED
+    /*
+    * This is intended for global storage, so only the main
+    * stylesheet will hold the data.
+    */
+    tmpStyle = style;
+    while (tmpStyle->parent != NULL)
+	tmpStyle = tmpStyle->parent;
+    if (tmpStyle->extInfos != NULL) {
+	dataContainer =
+	    (xsltExtDataPtr) xmlHashLookup(tmpStyle->extInfos, URI);
+	if (dataContainer != NULL) {
+	    /*
+	    * The module was already initialized in the context
+	    * of this stylesheet; just return the user-data that
+	    * comes with it.
+	    */
+	    return(dataContainer->extData);
+	}
+    }
+#else
+    /*
+    * Old behaviour.
+    */
+    tmpStyle = style;
+    while (tmpStyle != NULL) {
+	if (tmpStyle->extInfos != NULL) {
+	    dataContainer =
+		(xsltExtDataPtr) xmlHashLookup(tmpStyle->extInfos, URI);
+	    if (dataContainer != NULL) {
+		return(dataContainer->extData);
+	    }
+	}
+	tmpStyle = xsltNextImport(tmpStyle);
+    }
+    tmpStyle = style;
+#endif
+
+    dataContainer =
+        xsltStyleInitializeStylesheetModule(tmpStyle, URI);
+    if (dataContainer != NULL)
+	return (dataContainer->extData);
+    return(NULL);
+}
+
+/**
+ * xsltStyleGetExtDataPerStylesheetLevel:
+ * @style: an XSLT stylesheet
+ * @URI:  the URI associated to the exension module
+ *
+ * Retrieve the data associated to the extension module in this given
+ * stylesheet.
+ *
+ * Returns the pointer or NULL if not present
+ */
+void *
+xsltStyleStylesheetLevelGetExtData(xsltStylesheetPtr style,
+				   const xmlChar * URI)
+{
+    xsltExtDataPtr dataContainer = NULL;
+
+    if ((style == NULL) || (URI == NULL) ||
+	(xsltExtensionsHash == NULL))
+	return (NULL);
+
+    if (style->extInfos != NULL) {
+	dataContainer = (xsltExtDataPtr) xmlHashLookup(style->extInfos, URI);
+	/*
+	* The module was already initialized in the context
+	* of this stylesheet; just return the user-data that
+	* comes with it.
+	*/
+	if (dataContainer)
+	    return(dataContainer->extData);
+    }  
+
+    dataContainer =
+        xsltStyleInitializeStylesheetModule(style, URI);
+    if (dataContainer != NULL)
+	return (dataContainer->extData);
+    return(NULL);
+}
+
+/**
  * xsltGetExtData:
  * @ctxt: an XSLT transformation context
  * @URI:  the URI associated to the exension module
@@ -939,8 +1077,13 @@
                      "Shutting down module : %s\n", URI);
 #endif
     module->styleShutdownFunc(style, URI, data->extData);
-    xmlHashRemoveEntry(style->extInfos, URI,
-                       (xmlHashDeallocator) xsltFreeExtData);
+    /*
+    * Don't remove the entry from the hash table here, since
+    * this will produce segfaults - this fixes bug #340624.
+    *
+    * xmlHashRemoveEntry(style->extInfos, URI,
+    *   (xmlHashDeallocator) xsltFreeExtData);
+    */    
 }
 
 /**
@@ -964,29 +1107,60 @@
 /**
  * xsltCheckExtPrefix:
  * @style: the stylesheet
- * @prefix: the namespace prefix (possibly NULL)
+ * @URI: the namespace URI (possibly NULL)
  *
- * Check if the given prefix is one of the declared extensions
+ * Check if the given prefix is one of the declared extensions.
+ * This is intended to be called only at compile-time.
+ * Called by:
+ *  xsltGetInheritedNsList() (xslt.c)
+ *  xsltParseTemplateContent (xslt.c)
  *
  * Returns 1 if this is an extension, 0 otherwise
  */
 int
-xsltCheckExtPrefix(xsltStylesheetPtr style, const xmlChar * prefix)
-{
+xsltCheckExtPrefix(xsltStylesheetPtr style, const xmlChar * URI)
+{    
+#ifdef XSLT_REFACTORED
+    if ((style == NULL) || (style->compCtxt == NULL) ||
+	(XSLT_CCTXT(style)->inode == NULL) ||
+	(XSLT_CCTXT(style)->inode->extElemNs == NULL))
+        return (0);    
+    /*
+    * Lookup the extension namespaces registered
+    * at the current node in the stylesheet's tree.
+    */
+    if (XSLT_CCTXT(style)->inode->extElemNs != NULL) {
+	int i;
+	xsltPointerListPtr list = XSLT_CCTXT(style)->inode->extElemNs;
+
+	for (i = 0; i < list->number; i++) {
+	    if (xmlStrEqual((const xmlChar *) list->items[i],
+		URI))
+	    {
+		return(1);
+	    }	    
+	}
+    }
+#else
     xsltExtDefPtr cur;
 
     if ((style == NULL) || (style->nsDefs == NULL))
         return (0);
-
-    if (prefix == NULL)
-        prefix = BAD_CAST "#default";
-
+    if (URI == NULL)
+        URI = BAD_CAST "#default";
     cur = (xsltExtDefPtr) style->nsDefs;
     while (cur != NULL) {
-        if (xmlStrEqual(prefix, cur->prefix))
+	/*
+	* NOTE: This was change to work on namespace names rather
+	* than namespace prefixes. This fixes bug #339583.
+	* TODO: Consider renaming the field "prefix" of xsltExtDef
+	*  to "href".
+	*/
+        if (xmlStrEqual(URI, cur->prefix))
             return (1);
         cur = cur->next;
     }
+#endif
     return (0);
 }
 
@@ -1281,13 +1455,39 @@
 
     ext = (xsltExtElementPtr)
         xmlHashLookup2(xsltElementsHash, inst->name, inst->ns->href);
+    /*
+    * EXT TODO: Now what?
+    */
     if (ext == NULL)
         return (NULL);
 
-    if (ext->precomp != NULL)
+    if (ext->precomp != NULL) {
+	/*
+	* REVISIT TODO: Check if the text below is correct.
+	* This will return a xsltElemPreComp structure or NULL.
+	* 1) If the the author of the extension needs a
+	*  custom structure to hold the specific values of
+	*  this extension, he will derive a structure based on
+	*  xsltElemPreComp; thus we obviously *cannot* refactor
+	*  the xsltElemPreComp structure, since all already derived
+	*  user-defined strucures will break.
+	*  Example: For the extension xsl:document,
+	*   in xsltDocumentComp() (preproc.c), the structure
+	*   xsltStyleItemDocument is allocated, filled with
+	*   specific values and returned.
+	* 2) If the author needs no values to be stored in
+	*  this structure, then he'll return NULL;
+	*/
         comp = ext->precomp(style, inst, ext->transform);
-    if (comp == NULL)
+    }
+    if (comp == NULL) {
+	/*
+	* Default creation of a xsltElemPreComp structure, if
+	* the author of this extension did not create a custom
+	* structure.
+	*/
         comp = xsltNewElemPreComp(style, inst, ext->transform);
+    }
 
     return (comp);
 }
@@ -1553,6 +1753,13 @@
 {
     xsltExtDataPtr data;
 
+    /*
+    * TODO: Why do we have a return type of xmlHashTablePtr?
+    *   Is the user-allocated data for extension modules expected
+    *   to be a xmlHashTablePtr only? Or is this intended for
+    *   the EXSLT module only?
+    */
+
     if (style != NULL && style->extInfos != NULL) {
         data = xmlHashLookup(style->extInfos, URI);
         if (data != NULL && data->extData != NULL)

Modified: packages/libxslt/trunk/libxslt/extensions.h
===================================================================
--- packages/libxslt/trunk/libxslt/extensions.h	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/libxslt/extensions.h	2006-06-08 22:29:07 UTC (rev 565)
@@ -93,7 +93,12 @@
 XSLTPUBFUN void * XSLTCALL		
 		xsltStyleGetExtData	(xsltStylesheetPtr style,
 					 const xmlChar *URI);
-
+#ifdef XSLT_REFACTORED
+XSLTPUBFUN void * XSLTCALL
+		xsltStyleStylesheetLevelGetExtData(
+					 xsltStylesheetPtr style,
+					 const xmlChar * URI);
+#endif
 XSLTPUBFUN void XSLTCALL		
     		xsltShutdownCtxtExts	(xsltTransformContextPtr ctxt);
 
@@ -210,7 +215,7 @@
 					 const xmlChar *URI);
 XSLTPUBFUN int XSLTCALL		
 		xsltCheckExtPrefix	(xsltStylesheetPtr style,
-					 const xmlChar *prefix);
+					 const xmlChar *URI);
 XSLTPUBFUN int XSLTCALL		
 		xsltInitCtxtExts	(xsltTransformContextPtr ctxt);
 XSLTPUBFUN void XSLTCALL		

Modified: packages/libxslt/trunk/libxslt/imports.c
===================================================================
--- packages/libxslt/trunk/libxslt/imports.c	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/libxslt/imports.c	2006-06-08 22:29:07 UTC (rev 565)
@@ -41,6 +41,7 @@
 #include "xslt.h"
 #include "xsltInternals.h"
 #include "xsltutils.h"
+#include "preproc.h"
 #include "imports.h"
 #include "documents.h"
 #include "security.h"
@@ -229,7 +230,16 @@
 	    "xsl:include : unable to load %s\n", URI);
 	goto error;
     }
-
+#ifdef XSLT_REFACTORED    
+    if (IS_XSLT_ELEM_FAST(cur) && (cur->psvi != NULL)) {
+	((xsltStyleItemIncludePtr) cur->psvi)->include = include;
+    } else {
+	xsltTransformError(NULL, style, cur,
+	    "Internal error: (xsltParseStylesheetInclude) "
+	    "The xsl:include element was not compiled.\n", URI);
+	style->errors++;
+    }
+#endif
     oldDoc = style->doc;
     style->doc = include->doc;
     /* chain to stylesheet for recursion checking */
@@ -237,6 +247,12 @@
     style->includes = include;
     oldNopreproc = style->nopreproc;
     style->nopreproc = include->preproc;
+    /*
+    * TODO: This will change some values of the
+    *  including stylesheet with every included module
+    *  (e.g. excluded-result-prefixes)
+    *  We need to strictly seperate such stylesheet-owned values.
+    */
     result = xsltParseStylesheetProcess(style, include->doc);
     style->nopreproc = oldNopreproc;
     include->preproc = 1;
@@ -359,6 +375,13 @@
  * @nameURI: the template name URI
  *
  * Finds the named template, apply import precedence rule.
+ * REVISIT TODO: We'll change the nameURI fields of
+ *  templates to be in the string dict, so if the
+ *  specified @nameURI is in the same dict, then use pointer
+ *  comparison. Check if this can be done in a sane way.
+ *  Maybe this function is not needed internally at
+ *  transformation-time if we hard-wire the called templates
+ *  to the caller.
  *
  * Returns the xsltTemplatePtr or NULL if not found
  */

Modified: packages/libxslt/trunk/libxslt/keys.c
===================================================================
--- packages/libxslt/trunk/libxslt/keys.c	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/libxslt/keys.c	2006-06-08 22:29:07 UTC (rev 565)
@@ -32,31 +32,7 @@
 #define WITH_XSLT_DEBUG_KEYS
 #endif
 
-typedef struct _xsltKeyDef xsltKeyDef;
-typedef xsltKeyDef *xsltKeyDefPtr;
-struct _xsltKeyDef {
-    struct _xsltKeyDef *next;
-    xmlNodePtr inst;
-    xmlChar *name;
-    xmlChar *nameURI;
-    xmlChar *match;
-    xmlChar *use;
-    xmlXPathCompExprPtr comp;
-    xmlXPathCompExprPtr usecomp;
-    xmlNsPtr *nsList;           /* the namespaces in scope */
-    int nsNr;                   /* the number of namespaces in scope */
-};
 
-typedef struct _xsltKeyTable xsltKeyTable;
-typedef xsltKeyTable *xsltKeyTablePtr;
-struct _xsltKeyTable {
-    struct _xsltKeyTable *next;
-    xmlChar *name;
-    xmlChar *nameURI;
-    xmlHashTablePtr keys;
-};
-
-
 /************************************************************************
  * 									*
  * 			Type functions 					*
@@ -369,6 +345,14 @@
     xsltGenericDebug(xsltGenericDebugContext,
 	"   resulting pattern %s\n", pattern);
 #endif
+    /*    
+    * XSLT-1: "It is an error for the value of either the use
+    *  attribute or the match attribute to contain a
+    *  VariableReference."
+    * TODO: We should report a variable-reference at compile-time.
+    *   Maybe a search for "$", if it occurs outside of quotation
+    *   marks, could be sufficient.
+    */
     key->comp = xsltXPathCompile(style, pattern);
     if (key->comp == NULL) {
 	xsltTransformError(NULL, style, inst,
@@ -407,6 +391,9 @@
 	   const xmlChar *nameURI, const xmlChar *value) {
     xmlNodeSetPtr ret;
     xsltKeyTablePtr table;
+#ifdef XSLT_REFACTORED_KEYCOMP
+    int found = 0;
+#endif
 
     if ((ctxt == NULL) || (name == NULL) || (value == NULL) ||
 	(ctxt->document == NULL))
@@ -418,15 +405,62 @@
 #endif
     table = (xsltKeyTablePtr) ctxt->document->keys;
     while (table != NULL) {
-	if (xmlStrEqual(table->name, name) &&
-	    (((nameURI == NULL) && (table->nameURI == NULL)) ||
-	     ((nameURI != NULL) && (table->nameURI != NULL) &&
-	      (xmlStrEqual(table->nameURI, nameURI))))) {
+	if (((nameURI != NULL) == (table->nameURI != NULL)) &&
+	    xmlStrEqual(table->name, name) &&
+	    xmlStrEqual(table->nameURI, nameURI))
+	{
+#ifdef XSLT_REFACTORED_KEYCOMP
+	    found = 1;
+#endif
 	    ret = (xmlNodeSetPtr)xmlHashLookup(table->keys, value);
 	    return(ret);
 	}
 	table = table->next;
     }
+#ifdef XSLT_REFACTORED_KEYCOMP
+    if (! found) {
+	xsltStylesheetPtr style = ctxt->style;	
+	xsltKeyDefPtr keyd;
+	/*
+	* This might be the first call to the key with the specified
+	* name and the specified document.
+	* Find all keys with a matching name and compute them for the
+	* current tree.
+	*/
+	found = 0;
+	while (style != NULL) {
+	    keyd = (xsltKeyDefPtr) style->keys;
+	    while (keyd != NULL) {
+		if (((nameURI != NULL) == (keyd->nameURI != NULL)) &&
+		    xmlStrEqual(keyd->name, name) &&
+		    xmlStrEqual(keyd->nameURI, nameURI))
+		{
+		    found = 1;
+		    xsltInitCtxtKey(ctxt, ctxt->document, keyd);
+		}
+		keyd = keyd->next;		
+	    }	    
+	    style = xsltNextImport(style);
+	}
+	if (found) {
+	    /*
+	    * The key was computed, so look it up.
+	    */
+	    table = (xsltKeyTablePtr) ctxt->document->keys;
+	    while (table != NULL) {
+		if (((nameURI != NULL) == (table->nameURI != NULL)) &&
+		    xmlStrEqual(table->name, name) &&
+		    xmlStrEqual(table->nameURI, nameURI))
+		{
+		    ret = (xmlNodeSetPtr)xmlHashLookup(table->keys, value);
+		    return(ret);
+		}
+		table = table->next;
+	    }
+
+	}
+    }
+#endif
     return(NULL);
 }
 
@@ -513,6 +547,7 @@
     ctxt->xpathCtxt->namespaces = oldNamespaces;
     return(ret);
 }
+
 /**
  * xsltInitCtxtKey:
  * @ctxt: an XSLT transformation context
@@ -521,7 +556,7 @@
  *
  * Computes the key tables this key and for the current input document.
  */
-static void
+int
 xsltInitCtxtKey(xsltTransformContextPtr ctxt, xsltDocumentPtr doc,
 	        xsltKeyDefPtr keyd) {
     int i;
@@ -537,6 +572,7 @@
     int oldNsNr;
     xmlNsPtr *oldNamespaces;
 
+    doc->nbKeysComputed++;
     /*
      * Evaluate the nodelist
      */
@@ -692,6 +728,7 @@
     ctxt->node = oldNode;
     if (res != NULL)
 	xmlXPathFreeObject(res);
+    return(0);
 }
 
 /**
@@ -701,6 +738,7 @@
  *
  * Computes all the keys tables for the current input document.
  * Should be done before global varibales are initialized.
+ * NOTE: Not used anymore in the refactored code.
  */
 void
 xsltInitCtxtKeys(xsltTransformContextPtr ctxt, xsltDocumentPtr doc) {

Modified: packages/libxslt/trunk/libxslt/namespaces.c
===================================================================
--- packages/libxslt/trunk/libxslt/namespaces.c	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/libxslt/namespaces.c	2006-06-08 22:29:07 UTC (rev 565)
@@ -52,6 +52,32 @@
  *									*
  ************************************************************************/
 
+#ifdef XSLT_REFACTORED  
+static xsltNsAliasPtr
+xsltNewNsAlias(xsltCompilerCtxtPtr cctxt)
+{
+    xsltNsAliasPtr ret;
+
+    if (cctxt == NULL)
+	return(NULL);
+
+    ret = (xsltNsAliasPtr) xmlMalloc(sizeof(xsltNsAlias));
+    if (ret == NULL) {
+	xsltTransformError(NULL, cctxt->style, NULL,
+	    "Internal error in xsltNewNsAlias(): Memory allocation failed.\n");
+	cctxt->style->errors++;
+	return(NULL);
+    }
+    memset(ret, 0, sizeof(xsltNsAlias));    
+    /*
+    * TODO: Store the item at current stylesheet-level.
+    */
+    ret->next = cctxt->nsAliases;
+    cctxt->nsAliases = ret;       
+
+    return(ret);
+}
+#endif /* XSLT_REFACTORED */
 /**
  * xsltNamespaceAlias:
  * @style:  the XSLT stylesheet
@@ -61,46 +87,163 @@
  * them as well as the corresponding namespace.
  */
 void
-xsltNamespaceAlias(xsltStylesheetPtr style, xmlNodePtr node) {
-    xmlChar *sprefix;
-    xmlNsPtr sNs;
-    const xmlChar *shref;
-    xmlChar *rprefix;
-    xmlNsPtr rNs;
-    const xmlChar *rhref;
+xsltNamespaceAlias(xsltStylesheetPtr style, xmlNodePtr node)
+{
+    xmlChar *resultPrefix = NULL;
+    xmlChar *stylePrefix = NULL;
+    xmlNsPtr literalNs = NULL;
+    xmlNsPtr targetNs = NULL;
+ 
+#ifdef XSLT_REFACTORED 
+    xsltNsAliasPtr alias;
 
-    sprefix = xmlGetNsProp(node, (const xmlChar *)"stylesheet-prefix", NULL);
-    if (sprefix == NULL) {
+    if ((style == NULL) || (node == NULL))
+	return;
+
+    /*
+    * SPEC XSLT 1.0:
+    *  "If a namespace URI is declared to be an alias for multiple
+    *  different namespace URIs, then the declaration with the highest
+    *  import precedence is used. It is an error if there is more than
+    *  one such declaration. An XSLT processor may signal the error;
+    *  if it does not signal the error, it must recover by choosing,
+    *  from amongst the declarations with the highest import precedence,
+    *  the one that occurs last in the stylesheet."
+    *
+    * SPEC TODO: Check for the errors mentioned above.
+    */
+    /*
+    * NOTE that the XSLT 2.0 also *does* use the NULL namespace if
+    *  "#default" is used and there's no default namespace is scope.
+    *  I.e., this is *not* an error. 
+    *  Most XSLT 1.0 implementations work this way.
+    *  The XSLT 1.0 spec has nothing to say on the subject. 
+    */
+    /*
+    * Attribute "stylesheet-prefix".
+    */
+    stylePrefix = xmlGetNsProp(node, (const xmlChar *)"stylesheet-prefix", NULL);
+    if (stylePrefix == NULL) {
 	xsltTransformError(NULL, style, node,
+	    "The attribute 'stylesheet-prefix' is missing.\n");
+	return;
+    }
+    if (xmlStrEqual(stylePrefix, (const xmlChar *)"#default"))
+	literalNs = xmlSearchNs(node->doc, node, NULL);	
+    else {
+	literalNs = xmlSearchNs(node->doc, node, stylePrefix);
+	if (literalNs == NULL) {
+	    xsltTransformError(NULL, style, node,
+	        "Attribute 'stylesheet-prefix': There's no namespace "
+		"declaration in scope for the prefix '%s'.\n",
+		    stylePrefix);
+	    goto error;
+	}
+    }
+    /*
+    * Attribute "result-prefix".
+    */
+    resultPrefix = xmlGetNsProp(node, (const xmlChar *)"result-prefix", NULL);
+    if (resultPrefix == NULL) {
+	xsltTransformError(NULL, style, node,
+	    "The attribute 'result-prefix' is missing.\n");
+	goto error;
+    }        
+    if (xmlStrEqual(resultPrefix, (const xmlChar *)"#default"))
+	targetNs = xmlSearchNs(node->doc, node, NULL);
+    else {
+	targetNs = xmlSearchNs(node->doc, node, resultPrefix);
+
+        if (targetNs == NULL) {
+	   xsltTransformError(NULL, style, node,
+	        "Attribute 'result-prefix': There's no namespace "
+		"declaration in scope for the prefix '%s'.\n",
+		    stylePrefix);
+	    goto error;
+	}
+    }
+    /*
+     *
+     * Same alias for multiple different target namespace URIs:
+     *  TODO: The one with the highest import precedence is used.
+     *  Example:
+     *  <xsl:namespace-alias stylesheet-prefix="foo"
+     *                       result-prefix="bar"/>
+     *
+     *  <xsl:namespace-alias stylesheet-prefix="foo"
+     *                       result-prefix="zar"/>
+     *
+     * Same target namespace URI for multiple different aliases:
+     *  All alias-definitions will be used.
+     *  Example:
+     *  <xsl:namespace-alias stylesheet-prefix="bar"
+     *                       result-prefix="foo"/>
+     *
+     *  <xsl:namespace-alias stylesheet-prefix="zar"
+     *                       result-prefix="foo"/>
+     * Cases using #default:
+     *  <xsl:namespace-alias stylesheet-prefix="#default"
+     *                       result-prefix="#default"/>
+     *  TODO: Has this an effect at all?
+     *
+     *  <xsl:namespace-alias stylesheet-prefix="foo"
+     *                       result-prefix="#default"/>
+     *  From namespace to no namespace.
+     *
+     *  <xsl:namespace-alias stylesheet-prefix="#default"
+     *                       result-prefix="foo"/>
+     *  From no namespace to namespace.
+     */
+    
+	
+	/*
+	* Store the ns-node in the alias-object.
+	*/
+	alias = xsltNewNsAlias(XSLT_CCTXT(style));
+	if (alias == NULL)
+	    return;
+	alias->literalNs = literalNs;
+	alias->targetNs = targetNs;
+	XSLT_CCTXT(style)->hasNsAliases = 1;
+
+
+#else /* XSLT_REFACTORED */
+    const xmlChar *literalNsName;
+    const xmlChar *targetNsName;
+    
+
+    if ((style == NULL) || (node == NULL))
+	return;
+
+    stylePrefix = xmlGetNsProp(node, (const xmlChar *)"stylesheet-prefix", NULL);
+    if (stylePrefix == NULL) {
+	xsltTransformError(NULL, style, node,
 	    "namespace-alias: stylesheet-prefix attribute missing\n");
 	return;
     }
-    rprefix = xmlGetNsProp(node, (const xmlChar *)"result-prefix", NULL);
-    if (rprefix == NULL) {
+    resultPrefix = xmlGetNsProp(node, (const xmlChar *)"result-prefix", NULL);
+    if (resultPrefix == NULL) {
 	xsltTransformError(NULL, style, node,
 	    "namespace-alias: result-prefix attribute missing\n");
 	goto error;
     }
     
-    if (xmlStrEqual(sprefix, (const xmlChar *)"#default")) {
-        /*
-	 * Do we have a default namespace previously declared?
-	 */
-	sNs = xmlSearchNs(node->doc, node, NULL);
-	if (sNs == NULL)
-	    shref = NULL;	/* No - set NULL */
-	else
-	    shref = sNs->href;	/* Yes - set for nsAlias table */
+    if (xmlStrEqual(stylePrefix, (const xmlChar *)"#default")) {
+	literalNs = xmlSearchNs(node->doc, node, NULL);
+	if (literalNs == NULL) {
+	    literalNsName = NULL;
+	} else
+	    literalNsName = literalNs->href; /* Yes - set for nsAlias table */
     } else {
-	sNs = xmlSearchNs(node->doc, node, sprefix);
+	literalNs = xmlSearchNs(node->doc, node, stylePrefix);
  
-	if ((sNs == NULL) || (sNs->href == NULL)) {
+	if ((literalNs == NULL) || (literalNs->href == NULL)) {
 	    xsltTransformError(NULL, style, node,
 	        "namespace-alias: prefix %s not bound to any namespace\n",
-					sprefix);
+					stylePrefix);
 	    goto error;
 	} else
-	    shref = sNs->href;
+	    literalNsName = literalNs->href;
     }
 
     /*
@@ -108,30 +251,43 @@
      * been explicitly declared the special value UNDEFINED_DEFAULT_NS is
      * put into the nsAliases table
      */
-    if (xmlStrEqual(rprefix, (const xmlChar *)"#default")) {
-	rNs = xmlSearchNs(node->doc, node, NULL);
-	if (rNs == NULL)
-	    rhref = UNDEFINED_DEFAULT_NS;
-	else
-	    rhref = rNs->href;
+    if (xmlStrEqual(resultPrefix, (const xmlChar *)"#default")) {
+	targetNs = xmlSearchNs(node->doc, node, NULL);
+	if (targetNs == NULL) {
+	    targetNsName = UNDEFINED_DEFAULT_NS;
+	} else
+	    targetNsName = targetNs->href;
     } else {
-	rNs = xmlSearchNs(node->doc, node, rprefix);
+	targetNs = xmlSearchNs(node->doc, node, resultPrefix);
 
-        if ((rNs == NULL) || (rNs->href == NULL)) {
+        if ((targetNs == NULL) || (targetNs->href == NULL)) {
 	    xsltTransformError(NULL, style, node,
 	        "namespace-alias: prefix %s not bound to any namespace\n",
-					rprefix);
+					resultPrefix);
 	    goto error;
 	} else
-	    rhref = rNs->href;
+	    targetNsName = targetNs->href;
     }
     /*
-     * Special case if #default is used for stylesheet and no default has
-     * been explicitly declared.  We use style->defaultAlias for this
-     */
-    if (shref == NULL) {
-        if (rNs != NULL)
-            style->defaultAlias = rNs->href;
+     * Special case: if #default is used for
+     *  the stylesheet-prefix (literal namespace) and there's no default
+     *  namespace in scope, we'll use style->defaultAlias for this.
+     */   
+    if (literalNsName == NULL) {
+        if (targetNs != NULL) {
+	    /*
+	    * BUG TODO: Is it not sufficient to have only 1 field for
+	    *  this, since subsequently alias declarations will
+	    *  overwrite this.	    
+	    *  Example:
+	    *   <xsl:namespace-alias result-prefix="foo"
+	    *                        stylesheet-prefix="#default"/>
+	    *   <xsl:namespace-alias result-prefix="bar"
+	    *                        stylesheet-prefix="#default"/>
+	    *  The mapping for "foo" won't be visible anymore.
+	    */
+            style->defaultAlias = targetNs->href;
+	}
     } else {
         if (style->nsAliases == NULL)
 	    style->nsAliases = xmlHashCreate(10);
@@ -140,15 +296,16 @@
 	        "namespace-alias: cannot create hash table\n");
 	    goto error;
         }
-        xmlHashAddEntry((xmlHashTablePtr) style->nsAliases,
-	            shref, (void *) rhref);
+	xmlHashAddEntry((xmlHashTablePtr) style->nsAliases,
+	    literalNsName, (void *) targetNsName);
     }
+#endif /* else of XSLT_REFACTORED */
 
 error:
-    if (sprefix != NULL)
-	xmlFree(sprefix);
-    if (rprefix != NULL)
-	xmlFree(rprefix);
+    if (stylePrefix != NULL)
+	xmlFree(stylePrefix);
+    if (resultPrefix != NULL)
+	xmlFree(resultPrefix);
 }
 
 /**
@@ -255,27 +412,39 @@
  * and add a new namespace decalaration on the node
  * Handle namespace aliases and make sure the prefix is not NULL, this
  * is needed for attributes.
+ * Called from:
+ *   xsltAttrTemplateProcess() (templates.c)
+ *   xsltCopyProp() (transform.c)
  *
  * Returns the namespace node to use or NULL
  */
 xmlNsPtr
 xsltGetPlainNamespace(xsltTransformContextPtr ctxt, xmlNodePtr cur,
-                      xmlNsPtr ns, xmlNodePtr out) {
-    xsltStylesheetPtr style;
+                      xmlNsPtr ns, xmlNodePtr out) {    
     xmlNsPtr ret;
     const xmlChar *URI = NULL; /* the replacement URI */
 
     if ((ctxt == NULL) || (cur == NULL) || (out == NULL) || (ns == NULL))
 	return(NULL);
 
-    style = ctxt->style;
-    while (style != NULL) {
-	if (style->nsAliases != NULL)
-	    URI = (const xmlChar *) xmlHashLookup(style->nsAliases, ns->href);
-	if (URI != NULL)
-	    break;
-
-	style = xsltNextImport(style);
+#ifdef XSLT_REFACTORED
+    /*
+    * Namespace exclusion and ns-aliasing is performed at
+    * compilation-time in the refactored code.
+    */
+    URI = ns->href;
+#else
+    {
+	xsltStylesheetPtr style;
+	style = ctxt->style;
+	while (style != NULL) {
+	    if (style->nsAliases != NULL)
+		URI = (const xmlChar *) xmlHashLookup(style->nsAliases, ns->href);
+	    if (URI != NULL)
+		break;
+	    
+	    style = xsltNextImport(style);
+	}
     }
 
     if (URI == UNDEFINED_DEFAULT_NS) {
@@ -289,6 +458,7 @@
 
     if (URI == NULL)
 	URI = ns->href;
+#endif
 
     if ((out->parent != NULL) &&
 	(out->parent->type == XML_ELEMENT_NODE) &&
@@ -339,10 +509,34 @@
 	return(NULL);
 
     if ((prefix == NULL) && (URI[0] == 0)) {
+	/*
+	* This tries to "undeclare" a default namespace.
+	* This fixes a part of bug #302020:
+	*  1) Added a check whether the queried ns-decl
+	*     is already an "undeclaration" of the default
+	*     namespace.
+	*  2) This fires an error if the default namespace
+	*     couldn't be "undeclared".	
+	*/
 	ret = xmlSearchNs(out->doc, out, NULL);
+	if ((ret == NULL) ||
+	    (ret->href == NULL) || (ret->href[0] == 0))
+	    return(ret);
+
 	if (ret != NULL) {
-	    ret = xmlNewNs(out, URI, prefix);
-	    return(ret);
+	    xmlNsPtr newns;
+
+	    newns = xmlNewNs(out, URI, prefix);
+	    if (newns == NULL) {
+		xsltTransformError(ctxt, NULL, cur,
+		    "Namespace fixup error: Failed to undeclare "
+		    "the default namespace '%s'.\n",
+		    ret->href);
+	    }
+	    /*
+	    * TODO: Why does this try to return an xmlns="" at all?
+	    */
+	    return(newns);
 	}
 	return(NULL);
     }
@@ -351,8 +545,9 @@
 	(out->parent->type == XML_ELEMENT_NODE) &&
 	(out->parent->ns != NULL) &&
 	(xmlStrEqual(out->parent->ns->href, URI)))
+    {
 	ret = out->parent->ns;
-    else 
+    } else 
 	ret = xmlSearchNsByHref(out->doc, out, URI);
 
     if ((ret == NULL) || (ret->prefix == NULL)) {
@@ -381,6 +576,9 @@
  * @ns:  the namespace
  * @out:  the output node (or its parent)
  *
+ * REFACTORED NOTE: Won't be used anymore in the refactored code
+ *  for literal result elements/attributes.
+ *
  * Find the right namespace value for this prefix, if needed create
  * and add a new namespace decalaration on the node
  * Handle namespace aliases
@@ -389,27 +587,38 @@
  */
 xmlNsPtr
 xsltGetNamespace(xsltTransformContextPtr ctxt, xmlNodePtr cur, xmlNsPtr ns,
-	         xmlNodePtr out) {
-    xsltStylesheetPtr style;
+	         xmlNodePtr out) {    
     xmlNsPtr ret;
     const xmlChar *URI = NULL; /* the replacement URI */
 
     if ((ctxt == NULL) || (cur == NULL) || (out == NULL) || (ns == NULL))
 	return(NULL);
-
-    style = ctxt->style;
-    while (style != NULL) {
-	if (style->nsAliases != NULL)
-	    URI = (const xmlChar *) 
+    
+#ifdef XSLT_REFACTORED
+    /*
+    * Namespace exclusion and ns-aliasing is performed at
+    * compilation-time in the refactored code.    
+    */
+    URI = ns->href;
+#else
+    {
+	xsltStylesheetPtr style;
+	style = ctxt->style;
+	while (style != NULL) {
+	    if (style->nsAliases != NULL)
+		URI = (const xmlChar *) 
 		xmlHashLookup(style->nsAliases, ns->href);
-	if (URI != NULL)
-	    break;
-
-	style = xsltNextImport(style);
+	    if (URI != NULL)
+		break;
+	    
+	    style = xsltNextImport(style);
+	}
     }
 
     if (URI == UNDEFINED_DEFAULT_NS) {
         xmlNsPtr dflt;
+	/*
+	*/
 	dflt = xmlSearchNs(cur->doc, cur, NULL);
 	if (dflt != NULL)
 	    URI = dflt->href;
@@ -417,7 +626,7 @@
 	    return NULL;
     } else if (URI == NULL)
 	URI = ns->href;
-
+#endif
     /*
      * If the parent is an XML_ELEMENT_NODE, and has the "equivalent"
      * namespace as ns (either both default, or both with a prefix
@@ -468,7 +677,14 @@
  *
  * Do a copy of an namespace list. If @node is non-NULL the
  * new namespaces are added automatically. This handles namespaces
- * aliases
+ * aliases.
+ * This function is intended only for *internal* use at
+ * transformation-time. Use it *only* for copying ns-decls of
+ * literal result elements.
+ * 
+ * Called by:
+ *   xsltCopyTree() (transform.c)
+ *   xsltCopyNode() (transform.c)
  *
  * Returns: a new xmlNsPtr, or NULL in case of error.
  */
@@ -476,8 +692,7 @@
 xsltCopyNamespaceList(xsltTransformContextPtr ctxt, xmlNodePtr node,
 	              xmlNsPtr cur) {
     xmlNsPtr ret = NULL, tmp;
-    xmlNsPtr p = NULL,q;
-    const xmlChar *URI;
+    xmlNsPtr p = NULL,q;    
 
     if (cur == NULL)
 	return(NULL);
@@ -495,12 +710,13 @@
 	    break;
 
 	/*
-	 * Avoid duplicating namespace declrations on the tree
+	 * Avoid duplicating namespace declarations in the tree if
+	 * a matching declaration is in scope.
 	 */
 	if (node != NULL) {
 	    if ((node->ns != NULL) &&
-        	(xmlStrEqual(node->ns->href, cur->href)) &&
-        	(xmlStrEqual(node->ns->prefix, cur->prefix))) {
+		(xmlStrEqual(node->ns->prefix, cur->prefix)) &&
+        	(xmlStrEqual(node->ns->href, cur->href))) {
 		cur = cur->next;
 		continue;
 	    }
@@ -510,8 +726,21 @@
 		continue;
 	    }
 	}
-	
+#ifdef XSLT_REFACTORED
+	/*
+	* Namespace exclusion and ns-aliasing is performed at
+	* compilation-time in the refactored code.
+	*/
+	q = xmlNewNs(node, cur->href, cur->prefix);
+	if (p == NULL) {
+	    ret = p = q;
+	} else {
+	    p->next = q;
+	    p = q;
+	}
+#else
 	if (!xmlStrEqual(cur->href, XSLT_NAMESPACE)) {
+	    const xmlChar *URI;
 	    /* TODO apply cascading */
 	    URI = (const xmlChar *) xmlHashLookup(ctxt->style->nsAliases,
 		                                  cur->href);
@@ -529,6 +758,7 @@
 		p = q;
 	    }
 	}
+#endif
 	cur = cur->next;
     }
     return(ret);
@@ -550,8 +780,7 @@
 xsltCopyNamespace(xsltTransformContextPtr ctxt, xmlNodePtr node,
 	          xmlNsPtr cur) {
     xmlNsPtr ret = NULL;
-    const xmlChar *URI;
-
+    
     if (cur == NULL)
 	return(NULL);
     if (cur->type != XML_NAMESPACE_DECL)
@@ -563,7 +792,16 @@
     if ((node != NULL) && (node->type != XML_ELEMENT_NODE))
 	node = NULL;
 
+#ifdef XSLT_REFACTORED
+    /*
+    * Namespace exclusion and ns-aliasing is performed at
+    * compilation-time in the refactored code.
+    */
+    ret = xmlNewNs(node, cur->href, cur->prefix);	
+#else
     if (!xmlStrEqual(cur->href, XSLT_NAMESPACE)) {
+	const xmlChar *URI;
+
 	URI = (const xmlChar *) xmlHashLookup(ctxt->style->nsAliases,
 					      cur->href);
 	if (URI == UNDEFINED_DEFAULT_NS)
@@ -574,6 +812,7 @@
 	    ret = xmlNewNs(node, cur->href, cur->prefix);
 	}
     }
+#endif
     return(ret);
 }
 

Modified: packages/libxslt/trunk/libxslt/pattern.c
===================================================================
--- packages/libxslt/trunk/libxslt/pattern.c	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/libxslt/pattern.c	2006-06-08 22:29:07 UTC (rev 565)
@@ -466,11 +466,7 @@
     int isRVT;
 
     doc = node->doc;
-    if ((doc != NULL) &&
-	(doc->name != NULL) &&
-	(doc->name[0] == ' ') &&
-	(xmlStrEqual(BAD_CAST doc->name,
-		     BAD_CAST " fake node libxslt")))
+    if (XSLT_IS_RES_TREE_FRAG(doc))
 	isRVT = 1;
     else
 	isRVT = 0;
@@ -825,11 +821,7 @@
 		}
 
 		doc = node->doc;
-		if ((doc != NULL) &&
-		    (doc->name != NULL) &&
-		    (doc->name[0] == ' ') &&
-		    (xmlStrEqual(BAD_CAST doc->name,
-		    		 BAD_CAST " fake node libxslt")))
+		if (XSLT_IS_RES_TREE_FRAG(doc))
 		    isRVT = 1;
 		else
 		    isRVT = 0;
@@ -1424,7 +1416,7 @@
 	    return;
 	}
 	NEXT;
-	/* TODO: support namespace in keys */
+	/* URGENT TODO: support namespace in keys */
 	PUSH(XSLT_OP_KEY, lit, lit2, novar);
     } else if (xmlStrEqual(name, (const xmlChar *)"processing-instruction")) {
 	NEXT;
@@ -2217,6 +2209,71 @@
     return(0);
 }
 
+#ifdef XSLT_REFACTORED_KEYCOMP
+static int
+xsltComputeAllKeys(xsltTransformContextPtr ctxt,
+		xsltDocumentPtr document)
+{
+    xsltStylesheetPtr style, style2;
+    xsltKeyDefPtr keyd, keyd2;
+    xsltKeyTablePtr table;
+
+    if ((ctxt == NULL) || (document == NULL))
+	return(-1);
+ 
+    if (document->nbKeysComputed == ctxt->nbKeys)
+	return(0);
+    /*
+    * TODO: This could be further optimized
+    */
+    style = ctxt->style;
+    while (style) {
+	keyd = (xsltKeyDefPtr) style->keys;
+	while (keyd != NULL) {	    
+	    /*
+	    * Check if keys with this QName have been already
+	    * computed.
+	    */
+	    table = (xsltKeyTablePtr) document->keys;
+	    while (table) {
+		if (((keyd->nameURI != NULL) == (table->nameURI != NULL)) &&
+		    xmlStrEqual(keyd->name, table->name) &&
+		    xmlStrEqual(keyd->nameURI, table->nameURI))
+		{
+		    break;
+		}		
+		table = table->next;
+	    }
+	    if (table == NULL) {
+		/*
+		* Keys with this QName have not been yet computed.
+		*/
+		style2 = ctxt->style;
+		while (style2 != NULL) {
+		    keyd2 = (xsltKeyDefPtr) style2->keys;
+		    while (keyd2 != NULL) {
+			if (((keyd2->nameURI != NULL) ==
+			     (keyd->nameURI != NULL)) &&
+			    xmlStrEqual(keyd2->name, keyd->name) &&
+			    xmlStrEqual(keyd2->nameURI, keyd->nameURI))
+			{
+			    xsltInitCtxtKey(ctxt, document, keyd2);
+			    if (document->nbKeysComputed == ctxt->nbKeys)
+				return(0);
+			}
+			keyd2 = keyd2->next;		
+		    }	    
+		    style2 = xsltNextImport(style2);
+		}
+	    }	    
+	    keyd = keyd->next;
+	}
+	style = xsltNextImport(style);
+    }
+    return(0);
+}
+#endif
+
 /**
  * xsltGetTemplate:
  * @ctxt:  a XSLT process context
@@ -2403,6 +2460,9 @@
 	    }
 	}
 
+#ifdef XSLT_REFACTORED_KEYCOMP
+keyed_match:
+#endif
 	if (keyed) {
 	    list = curstyle->keyMatch;
 	    while ((list != NULL) &&
@@ -2416,6 +2476,41 @@
 		list = list->next;
 	    }
 	}
+#ifdef XSLT_REFACTORED_KEYCOMP	
+	else if (ctxt->hasTemplKeyPatterns &&
+	    (ctxt->document->nbKeysComputed < ctxt->nbKeys))
+	{
+	    /*
+	    * Compute all remaining keys for this document.
+	    *
+	    * REVISIT TODO: I think this could be further optimized.	    
+	    */
+	    xsltComputeAllKeys(ctxt, ctxt->document);
+
+	    switch (node->type) {
+		case XML_ELEMENT_NODE:		    
+		    if (node->psvi != NULL) keyed = 1;
+		    break;
+		case XML_ATTRIBUTE_NODE:
+		    if (((xmlAttrPtr) node)->psvi != NULL) keyed = 1;
+		    break;
+		case XML_TEXT_NODE:
+		case XML_CDATA_SECTION_NODE:
+		case XML_COMMENT_NODE:
+		case XML_PI_NODE:		
+		    if (node->psvi != NULL) keyed = 1;
+		    break;
+		case XML_DOCUMENT_NODE:
+		case XML_HTML_DOCUMENT_NODE:
+		    if (((xmlDocPtr) node)->psvi != NULL) keyed = 1;
+		    break;		
+		default:
+		    break;
+	    }
+	    if (keyed)
+		goto keyed_match;
+	}
+#endif /* XSLT_REFACTORED_KEYCOMP */
 	if (ret != NULL)
 	    return(ret);
 

Modified: packages/libxslt/trunk/libxslt/preproc.c
===================================================================
--- packages/libxslt/trunk/libxslt/preproc.c	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/libxslt/preproc.c	2006-06-08 22:29:07 UTC (rev 565)
@@ -52,6 +52,11 @@
  *									*
  ************************************************************************/
 
+#ifdef XSLT_REFACTORED
+    /*
+    * Grammar checks are now performed in xslt.c.
+    */
+#else
 /**
  * xsltCheckTopLevelElement:
  * @style: the XSLT stylesheet
@@ -197,6 +202,7 @@
 		       inst->name);
     style->errors++;
 }
+#endif
 
 /************************************************************************
  *									*
@@ -350,7 +356,6 @@
 	case XSLT_FUNC_PARAM:	    
 	case XSLT_FUNC_VARIABLE:	    
 	case XSLT_FUNC_WHEN:
-	case XSLT_FUNC_OTHERWISE:
 	    break;
 	default:
 	if (cur->func == NULL) {
@@ -380,6 +385,8 @@
     * URGENT TODO: Implement destructors.
     */
     switch (comp->type) {
+	case XSLT_FUNC_LITERAL_RESULT_ELEMENT:
+	    break;
 	case XSLT_FUNC_COPY:
             break;
         case XSLT_FUNC_SORT: {
@@ -468,7 +475,12 @@
 		    xmlXPathFreeCompExpr(item->comp);
 	    }
 	    break;
-	case XSLT_FUNC_OTHERWISE:
+	case XSLT_FUNC_OTHERWISE:	    
+	case XSLT_FUNC_FALLBACK:
+	case XSLT_FUNC_MESSAGE:
+	case XSLT_FUNC_INCLUDE:
+	case XSLT_FUNC_ATTRSET:
+	
 	    break;
 	default:
 	    /* TODO: Raise error. */
@@ -518,7 +530,8 @@
     * "output" in XSLT_SAXON_NAMESPACE
     * "write" XSLT_XALAN_NAMESPACE
     * "document" XSLT_XT_NAMESPACE
-    * "document" XSLT_NAMESPACE
+    * "document" XSLT_NAMESPACE (from the abandoned old working
+    *                            draft of XSLT 1.1)
     * (in libexslt/common.c)
     * "document" in EXSLT_COMMON_NAMESPACE
     */
@@ -544,6 +557,8 @@
 	*   (http://icl.com/saxon)
 	* The @file is in no namespace; it is an AVT.
 	*   (http://www.computerwizards.com/saxon/doc/extensions.html#saxon:output)
+	*
+	* TODO: Do we need not to check the namespace here?
 	*/
 	filename = xsltEvalStaticAttrValueTemplate(style, inst,
 			 (const xmlChar *)"file",
@@ -557,6 +572,10 @@
 	/*
 	* TODO: Is "filename need to be interpreted" meant to be a todo?
 	*   Where will be the filename of xalan:write be processed?
+	*
+	* TODO: Do we need not to check the namespace here?
+	*   The extension ns is "http://xml.apache.org/xalan/redirect".
+	*   See http://xml.apache.org/xalan-j/extensionslib.html.
 	*/
     } else if (xmlStrEqual(inst->name, (const xmlChar *) "document")) {
 	if (inst->ns != NULL) {
@@ -770,11 +789,17 @@
 	comp->has_use = 1;
 }
 
+#ifdef XSLT_REFACTORED
+    /* Enable if ever needed for xsl:text. */
+#else
 /**
  * xsltTextComp:
  * @style: an XSLT compiled stylesheet
  * @inst:  the xslt text node
  *
+ * TODO: This function is obsolete, since xsl:text won't
+ *  be compiled, but removed from the tree.
+ *
  * Process the xslt text node on the source node
  */
 static void
@@ -807,13 +832,14 @@
 	if (xmlStrEqual(prop, (const xmlChar *)"yes")) {
 	    comp->noescape = 1;
 	} else if (!xmlStrEqual(prop,
-				(const xmlChar *)"no")){
+	    (const xmlChar *)"no")){
 	    xsltTransformError(NULL, style, inst,
-"xsl:text: disable-output-escaping allows only yes or no\n");
+		"xsl:text: disable-output-escaping allows only yes or no\n");
 	    if (style != NULL) style->warnings++;
 	}
     }
 }
+#endif /* else of XSLT_REFACTORED */
 
 /**
  * xsltElementComp:
@@ -1774,85 +1800,6 @@
     }
 }
 
-#ifdef XSLT_REFACTORED
-
-/*
-* xsltCompilerGetInScopeNSInfo:
-*
-* Create and store the list of in-scope namespaces for the given
-* node in the stylesheet. If there are no changes in the in-scope
-* namespaces then the last ns-info of the ancestor axis will be returned.
-* Compilation-time only.
-*
-* Returns the ns-info or NULL if there are no namespaces in scope.
-*/
-xsltNsListPtr
-xsltCompilerGetInScopeNSInfo(xsltCompilerCtxtPtr cctxt, xmlNodePtr node)
-{
-    xsltNsListPtr nsi = NULL;
-    xmlNsPtr *list = NULL;
-    /*
-    * Create a new ns-list for this position in the node-tree.
-    * xmlGetNsList() will return NULL, if there are no ns-decls in the
-    * tree. Note that the ns-decl for the XML namespace is not added
-    * to the resulting list; the XPath module handles the XML namespace
-    * internally.
-    */
-    list = xmlGetNsList(node->doc, node);
-    if (list == NULL)
-	return(NULL);
-    /*
-    * Initialize the list hold by the stylesheet.
-    */
-    if (cctxt->sheet->inScopeNamespaces == NULL) {
-	cctxt->sheet->inScopeNamespaces = xsltPointerListCreate();
-	if (cctxt->sheet->inScopeNamespaces == NULL) {	    
-	    xsltTransformError(NULL, cctxt->sheet, NULL,
-		"xsltCompilerGetInScopeNSInfo: malloc failed.\n");	    
-	    goto internal_err;	    
-	}
-    }
-    /*
-    * Create the info-structure.
-    */
-    nsi = (xsltNsListPtr) xmlMalloc(sizeof(xsltNsList));
-    if (nsi == NULL) {	
-	xsltTransformError(NULL, cctxt->sheet, NULL,
-	    "xsltCompilerGetInScopeNSInfo: malloc failed.\n");
-	goto internal_err;
-    }
-    memset(nsi, 0, sizeof(xsltNsList));
-    nsi->list = list;
-    /*
-    * Eval the number of ns-decls; this is used to speed up
-    * XPath-context initialization.
-    */
-    while (list[nsi->number] != NULL)
-	nsi->number++;
-    /*
-    * Store the ns-list in the stylesheet.
-    */
-    if (xsltPointerListAdd(
-	(xsltPointerListPtr)cctxt->sheet->inScopeNamespaces,
-	(void *) nsi) == -1)
-    {	
-	xmlFree(nsi);
-	nsi = NULL;
-	xsltTransformError(NULL, cctxt->sheet, NULL,
-	    "xsltCompilerGetInScopeNSInfo: failed to add ns-info.\n");
-	goto internal_err;
-    }     
-
-    return(nsi);
-
-internal_err:
-    if (list != NULL)
-	xmlFree(list);    
-    cctxt->sheet->errors++;
-    return(NULL);
-}
-#endif /* XSLT_REFACTORED */
-
 /************************************************************************
  *									*
  *		    Generic interface					*
@@ -1870,10 +1817,11 @@
     xsltElemPreCompPtr cur, next;
 
     if (style == NULL)
-	return;
+	return;        
+    
     cur = style->preComps;
     while (cur != NULL) {
-	next = cur->next;
+	next = cur->next;		
 	if (cur->type == XSLT_FUNC_EXTENSION)
 	    cur->free(cur);
 	else
@@ -1882,9 +1830,224 @@
     }
 }
 
+#ifdef XSLT_REFACTORED
+
 /**
  * xsltStylePreCompute:
  * @style:  the XSLT stylesheet
+ * @node:  the element in the XSLT namespace
+ *
+ * Precompute an XSLT element.
+ * This expects the type of the element to be already
+ * set in style->compCtxt->inode->type;
+ */
+void
+xsltStylePreCompute(xsltStylesheetPtr style, xmlNodePtr node) {
+    /*    
+    * The xsltXSLTElemMarker marker was set beforehand by
+    *  the parsing mechanism for all elements in the XSLT namespace.
+    */
+    if (style == NULL) {
+	if (node != NULL)
+	    node->psvi = NULL;
+	return;
+    }
+    if (node == NULL)
+	return;
+    if (! IS_XSLT_ELEM_FAST(node))
+	return;
+
+    node->psvi = NULL;
+    if (XSLT_CCTXT(style)->inode->type != 0) {
+	switch (XSLT_CCTXT(style)->inode->type) {
+	    case XSLT_FUNC_APPLYTEMPLATES:
+		xsltApplyTemplatesComp(style, node);
+		break;
+	    case XSLT_FUNC_WITHPARAM:			   
+		xsltWithParamComp(style, node);
+		break;
+	    case XSLT_FUNC_VALUEOF:	    
+		xsltValueOfComp(style, node);
+		break;
+	    case XSLT_FUNC_COPY:	    
+		xsltCopyComp(style, node);
+		break;
+	    case XSLT_FUNC_COPYOF:
+		xsltCopyOfComp(style, node);
+		break;
+	    case XSLT_FUNC_IF:	    
+		xsltIfComp(style, node);
+		break;
+	    case XSLT_FUNC_CHOOSE:	    
+		xsltChooseComp(style, node);
+		break;
+	    case XSLT_FUNC_WHEN:	    
+		xsltWhenComp(style, node);
+		break;
+	    case XSLT_FUNC_OTHERWISE:	    
+		/* NOP yet */
+		return;
+	    case XSLT_FUNC_FOREACH:	    
+		xsltForEachComp(style, node);
+		break;
+	    case XSLT_FUNC_APPLYIMPORTS:	    
+		xsltApplyImportsComp(style, node);
+		break;
+	    case XSLT_FUNC_ATTRIBUTE:	    
+		xsltAttributeComp(style, node);
+		break;
+	    case XSLT_FUNC_ELEMENT:	    
+		xsltElementComp(style, node);
+		break;
+	    case XSLT_FUNC_SORT:	    
+		xsltSortComp(style, node);
+		break;
+	    case XSLT_FUNC_COMMENT:	    
+		xsltCommentComp(style, node);
+		break;
+	    case XSLT_FUNC_NUMBER:	    
+		xsltNumberComp(style, node);
+		break;
+	    case XSLT_FUNC_PI:	    
+		xsltProcessingInstructionComp(style, node);
+		break;
+	    case XSLT_FUNC_CALLTEMPLATE:	    
+		xsltCallTemplateComp(style, node);
+		break;
+	    case XSLT_FUNC_PARAM:	    
+		xsltParamComp(style, node);
+		break;
+	    case XSLT_FUNC_VARIABLE:	    
+		xsltVariableComp(style, node);
+		break;
+	    case XSLT_FUNC_FALLBACK:	    
+		/* NOP yet */
+		return;
+	    case XSLT_FUNC_DOCUMENT:	    
+		/* The extra one */
+		node->psvi = (void *) xsltDocumentComp(style, node,
+		    (xsltTransformFunction) xsltDocumentElem);
+		break;
+	    case XSLT_FUNC_MESSAGE:
+		/* NOP yet */
+		return;
+	    default:
+		/*
+		* NOTE that xsl:text, xsl:template, xsl:stylesheet,
+		*  xsl:transform, xsl:import, xsl:include are not expected
+		*  to be handed over to this function.
+		*/
+		xsltTransformError(NULL, style, node,
+		    "Internal error: (xsltStylePreCompute) cannot handle "
+		    "the XSLT element '%s'.\n", node->name);
+		style->errors++;
+		return;
+	}
+    } else {
+	/*
+	* Fallback to string comparison.
+	*/	
+	if (IS_XSLT_NAME(node, "apply-templates")) {
+	    xsltApplyTemplatesComp(style, node);
+	} else if (IS_XSLT_NAME(node, "with-param")) {
+	    xsltWithParamComp(style, node);
+	} else if (IS_XSLT_NAME(node, "value-of")) {
+	    xsltValueOfComp(style, node);
+	} else if (IS_XSLT_NAME(node, "copy")) {
+	    xsltCopyComp(style, node);
+	} else if (IS_XSLT_NAME(node, "copy-of")) {
+	    xsltCopyOfComp(style, node);
+	} else if (IS_XSLT_NAME(node, "if")) {
+	    xsltIfComp(style, node);
+	} else if (IS_XSLT_NAME(node, "choose")) {
+	    xsltChooseComp(style, node);
+	} else if (IS_XSLT_NAME(node, "when")) {
+	    xsltWhenComp(style, node);	
+	} else if (IS_XSLT_NAME(node, "otherwise")) {
+	    /* NOP yet */
+	    return;
+	} else if (IS_XSLT_NAME(node, "for-each")) {
+	    xsltForEachComp(style, node);
+	} else if (IS_XSLT_NAME(node, "apply-imports")) {
+	    xsltApplyImportsComp(style, node);
+	} else if (IS_XSLT_NAME(node, "attribute")) {
+	    xsltAttributeComp(style, node);
+	} else if (IS_XSLT_NAME(node, "element")) {
+	    xsltElementComp(style, node);
+	} else if (IS_XSLT_NAME(node, "sort")) {
+	    xsltSortComp(style, node);
+	} else if (IS_XSLT_NAME(node, "comment")) {
+	    xsltCommentComp(style, node);
+	} else if (IS_XSLT_NAME(node, "number")) {
+	    xsltNumberComp(style, node);
+	} else if (IS_XSLT_NAME(node, "processing-instruction")) {
+	    xsltProcessingInstructionComp(style, node);
+	} else if (IS_XSLT_NAME(node, "call-template")) {
+	    xsltCallTemplateComp(style, node);
+	} else if (IS_XSLT_NAME(node, "param")) {
+	    xsltParamComp(style, node);
+	} else if (IS_XSLT_NAME(node, "variable")) {
+	    xsltVariableComp(style, node);
+	} else if (IS_XSLT_NAME(node, "fallback")) {
+	    /* NOP yet */
+	    return;
+	} else if (IS_XSLT_NAME(node, "document")) {
+	    /* The extra one */
+	    node->psvi = (void *) xsltDocumentComp(style, node,
+		(xsltTransformFunction) xsltDocumentElem);	
+	} else if (IS_XSLT_NAME(node, "output")) {
+	    /* Top-level */
+	    return;
+	} else if (IS_XSLT_NAME(node, "preserve-space")) {
+	    /* Top-level */
+	    return;
+	} else if (IS_XSLT_NAME(node, "strip-space")) {
+	    /* Top-level */
+	    return;	
+	} else if (IS_XSLT_NAME(node, "key")) {
+	    /* Top-level */
+	    return;
+	} else if (IS_XSLT_NAME(node, "message")) {
+	    return;
+	} else if (IS_XSLT_NAME(node, "attribute-set")) {
+	    /* Top-level */
+	    return;
+	} else if (IS_XSLT_NAME(node, "namespace-alias")) {
+	    /* Top-level */
+	    return;
+	} else if (IS_XSLT_NAME(node, "decimal-format")) {
+	    /* Top-level */
+	    return;
+	} else if (IS_XSLT_NAME(node, "include")) {
+	    /* Top-level */	    	    
+	} else {
+	    /*
+	    * NOTE that xsl:text, xsl:template, xsl:stylesheet,
+	    *  xsl:transform, xsl:import, xsl:include are not expected
+	    *  to be handed over to this function.
+	    */
+	    xsltTransformError(NULL, style, node,
+		"Internal error: (xsltStylePreCompute) cannot handle "
+		"the XSLT element '%s'.\n", node->name);
+		style->errors++;
+	    return;
+	}	
+    }
+    /*
+    * Assign the current list of in-scope namespaces to the
+    * item. This is needed for XPath expressions.
+    */
+    if (node->psvi != NULL) {
+	((xsltStylePreCompPtr) node->psvi)->inScopeNs =
+	    XSLT_CCTXT(style)->inode->inScopeNs;
+    }
+}
+
+#else
+
+/**
+ * xsltStylePreCompute:
+ * @style:  the XSLT stylesheet
  * @inst:  the instruction in the stylesheet
  *
  * Precompute an XSLT stylesheet element
@@ -1895,10 +2058,14 @@
     * URGENT TODO: Normally inst->psvi Should never be reserved here,
     *   BUT: since if we include the same stylesheet from
     *   multiple imports, then the stylesheet will be parsed
-    *   again. We simply must not try to compute the stylesheet again.    
+    *   again. We simply must not try to compute the stylesheet again.
+    * TODO: Get to the point where we don't need to query the
+    *   namespace- and local-name of the node, but can evaluate this
+    *   using cctxt->style->inode->category;
     */
-    if (inst->psvi != NULL) 
-        return;
+    if (inst->psvi != NULL)
+	return;
+
     if (IS_XSLT_ELEM(inst)) {
 	xsltStylePreCompPtr cur;
 
@@ -1965,7 +2132,7 @@
 	} else if (IS_XSLT_NAME(inst, "call-template")) {
 	    xsltCheckInstructionElement(style, inst);
 	    xsltCallTemplateComp(style, inst);
-	} else if (IS_XSLT_NAME(inst, "param")) {
+	} else if (IS_XSLT_NAME(inst, "param")) {	   
 	    if (xsltCheckTopLevelElement(style, inst, 0) == 0)
 	        xsltCheckInstructionElement(style, inst);
 	    xsltParamComp(style, inst);
@@ -2034,19 +2201,8 @@
 	    if (style != NULL) style->warnings++;
 	}
 	
-	
 	cur = (xsltStylePreCompPtr) inst->psvi;
-
-#ifdef XSLT_REFACTORED
 	/*
-	* Assign the current list of in-scope namespaces to the
-	* item. This is needed for XPath expressions.
-	*/
-	if (cur != NULL) {
-	    cur->inScopeNS = XSLT_CCTXT(style)->inode->inScopeNS;	    	    
-	}
-#else
-	/*
 	* A ns-list is build for every XSLT item in the
 	* node-tree. This is needed for XPath expressions.
 	*/
@@ -2060,7 +2216,6 @@
 	    }
 	    cur->nsNr = i;
 	}
-#endif
     } else {
 	inst->psvi =
 	    (void *) xsltPreComputeExtModuleElement(style, inst);
@@ -2073,3 +2228,4 @@
 	    inst->psvi = (void *) xsltExtMarker;
     }
 }
+#endif /* XSLT_REFACTORED */

Modified: packages/libxslt/trunk/libxslt/templates.c
===================================================================
--- packages/libxslt/trunk/libxslt/templates.c	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/libxslt/templates.c	2006-06-08 22:29:07 UTC (rev 565)
@@ -202,6 +202,12 @@
     if (parent->children == NULL)
 	return(NULL);
 
+    /*
+    * This creates a temporary element-node to add the resulting
+    * text content to.
+    * OPTIMIZE TODO: Keep such an element-node in the transformation
+    *  context to avoid creating it every time.
+    */
     insert = xmlNewDocNode(ctxt->output, NULL,
 	                   (const xmlChar *)"fake", NULL);
     if (insert == NULL) {
@@ -211,7 +217,7 @@
     }
     oldInsert = ctxt->insert;
     ctxt->insert = insert;
-
+    /* OPTIMIZE TODO: if parent->children consists only of text-nodes. */
     xsltApplyOneTemplate(ctxt, node, parent->children, NULL, NULL);
 
     ctxt->insert = oldInsert;

Modified: packages/libxslt/trunk/libxslt/transform.c
===================================================================
--- packages/libxslt/trunk/libxslt/transform.c	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/libxslt/transform.c	2006-06-08 22:29:07 UTC (rev 565)
@@ -366,8 +366,7 @@
     if (cur->templTab == NULL) {
 	xsltTransformError(NULL, NULL, (xmlNodePtr) doc,
 		"xsltNewTransformContext: out of memory\n");
-	xmlFree(cur);
-	return(NULL);
+	goto internal_err;
     }
     cur->templNr = 0;
     cur->templMax = 5;
@@ -381,9 +380,7 @@
     if (cur->varsTab == NULL) {
         xmlGenericError(xmlGenericErrorContext,
 		"xsltNewTransformContext: out of memory\n");
-	xmlFree(cur->templTab);
-	xmlFree(cur);
-	return(NULL);
+	goto internal_err;
     }
     cur->varsNr = 0;
     cur->varsMax = 5;
@@ -404,15 +401,16 @@
     if (cur->xpathCtxt == NULL) {
 	xsltTransformError(NULL, NULL, (xmlNodePtr) doc,
 		"xsltNewTransformContext : xmlXPathNewContext failed\n");
-	xmlFree(cur->templTab);
-	xmlFree(cur->varsTab);
-	xmlFree(cur);
-	return(NULL);
+	goto internal_err;
     }
     cur->xpathCtxt->proximityPosition = 0;
     cur->xpathCtxt->contextSize = 0;
-
     /*
+    * Create an XPath cache.
+    */
+    if (xmlXPathContextSetCache(cur->xpathCtxt, 1, -1, 0) == -1)
+	goto internal_err;
+    /*
      * Initialize the extras array
      */
     if (style->extrasNr != 0) {
@@ -422,11 +420,7 @@
 	if (cur->extras == NULL) {
 	    xmlGenericError(xmlGenericErrorContext,
 		    "xsltNewTransformContext: out of memory\n");
-	    xmlFree(cur->xpathCtxt);
-	    xmlFree(cur->varsTab);
-	    xmlFree(cur->templTab);
-	    xmlFree(cur);
-	    return(NULL);
+	    goto internal_err;
 	}
 	cur->extrasNr = style->extrasNr;
 	for (i = 0;i < cur->extrasMax;i++) {
@@ -462,10 +456,7 @@
     if (docu == NULL) {
 	xsltTransformError(cur, NULL, (xmlNodePtr)doc,
 		"xsltNewTransformContext : xsltNewDocument failed\n");
-	xmlFree(cur->templTab);
-	xmlFree(cur->varsTab);
-	xmlFree(cur);
-	return(NULL);
+	goto internal_err;
     }
     docu->main = 1;
     cur->document = docu;
@@ -477,6 +468,11 @@
     cur->xinclude = xsltGetXIncludeDefault();
 
     return(cur);
+
+internal_err:
+    if (cur != NULL)
+	xsltFreeTransformContext(cur);
+    return(NULL);
 }
 
 /**
@@ -709,31 +705,48 @@
 	 ((target->ns != NULL) &&
 	  (xmlHashLookup2(ctxt->style->cdataSection,
 	                  target->name, target->ns->href) != NULL)))) {
+	/* 
+	* OPTIMIZE TODO: xsltCopyText() is also used for attribute content.	
+	*/
 	/*
-	 * nodes which must be output as CDATA due to the stylesheet
-	 */
+	* TODO: Since this doesn't merge adjacent CDATA-section nodes,
+	* we'll get: <![CDATA[x]]><!CDATA[y]]>.
+	*/
 	copy = xmlNewCDataBlock(ctxt->output, cur->content,
 				xmlStrlen(cur->content));
 	ctxt->lasttext = NULL;
-    } else if ((target != NULL) && (target->last != NULL) &&
-	    (target->last->type == XML_TEXT_NODE) &&
-	    (target->last->name == xmlStringText) &&
-	    (cur->name != xmlStringTextNoenc)) {
+    } else if ((target != NULL) &&
+	(target->last != NULL) &&
+	/* both escaped or both non-escaped text-nodes */
+	(((target->last->type == XML_TEXT_NODE) &&
+	(target->last->name == cur->name)) ||
+        /* non-escaped text nodes and CDATA-section nodes */
+	(((target->last->type == XML_CDATA_SECTION_NODE) &&
+	(cur->name == xmlStringTextNoenc)))))
+    {
 	/*
 	 * we are appending to an existing text node
 	 */
 	return(xsltAddTextString(ctxt, target->last, cur->content,
-	                         xmlStrlen(cur->content)));
-    } else if ((interned) && (target != NULL) && (target->doc != NULL) &&
-               (target->doc->dict == ctxt->dict)) {
+	    xmlStrlen(cur->content)));
+    } else if ((interned) && (target != NULL) &&
+	(target->doc != NULL) &&
+	(target->doc->dict == ctxt->dict))
+    {        
+	/*
+	* TODO: DO we want to use this also for "text" output?
+	*/
         copy = xmlNewTextLen(NULL, 0);
 	if (copy == NULL)
-	    return NULL;
+	    return NULL;	
 	if (cur->name == xmlStringTextNoenc)
 	    copy->name = xmlStringTextNoenc;
-	/*
-	 * Must confirm that content is in dict
-	 * (bug 302821)
+	
+	/* OPTIMIZE TODO: get rid of xmlDictOwns() in safe cases;
+	 *  e.g. attribute values don't need the lookup.
+	 *
+	 * Must confirm that content is in dict (bug 302821)
+	 * TODO: Check if bug 302821 still applies here.
 	 */
 	if (xmlDictOwns(ctxt->dict, cur->content))
 	    copy->content = cur->content;
@@ -761,6 +774,11 @@
     if (copy != NULL) {
 	if (target != NULL) {
 	    copy->doc = target->doc;
+	    /*
+	    * MAYBE TODO: Maybe we should reset the ctxt->lasttext here
+	    *  to ensure that the optimized text-merging mechanism
+	    *  won't interfere with normal node-merging in any case.
+	    */
 	    xmlAddChild(target, copy);
 	}
     } else {
@@ -773,35 +791,190 @@
 /**
  * xsltCopyProp:
  * @ctxt:  a XSLT process context
- * @target:  the element where the attribute will be grafted
- * @attr:  the attribute
+ * @targetElem:  the element where the attribute will be grafted
+ * @attr: the attribute to be copied
  *
  * Do a copy of an attribute
  *
  * Returns: a new xmlAttrPtr, or NULL in case of error.
  */
 static xmlAttrPtr
-xsltCopyProp(xsltTransformContextPtr ctxt, xmlNodePtr target,
-	     xmlAttrPtr attr) {
-    xmlAttrPtr ret = NULL;
-    xmlNsPtr ns;
-    xmlChar *val;
+xsltCopyProp(xsltTransformContextPtr ctxt, xmlNodePtr targetElem,
+	     xmlAttrPtr attr)
+{
+    xmlAttrPtr attrCopy;
+    xmlChar *value;
+#ifdef XSLT_REFACTORED 
+    xmlNodePtr txtNode;
+#endif
 
     if (attr == NULL)
 	return(NULL);
-    if (target->type != XML_ELEMENT_NODE)
+
+    if (targetElem->type != XML_ELEMENT_NODE) {
+	/*
+	* TODO: Hmm, it would be better to have the node at hand of the
+	*  instruction which lead to this here.
+	*/
+	xsltTransformError(ctxt, NULL, NULL,
+	    "Result tree construction error: cannot set an attribute node "
+	    "on a non-element node.\n");
 	return(NULL);
+    }    
 
+#ifdef XSLT_REFACTORED
+    /*
+    * Create the attribute node.
+    */
     if (attr->ns != NULL) {
-	ns = xsltGetPlainNamespace(ctxt, attr->parent, attr->ns, target);
+	xmlNsPtr ns = NULL;
+	const xmlChar *prefix = attr->ns->prefix;
+	
+	/*
+	* Process namespace semantics
+	*
+	* RESTRUCTURE TODO: This is the same code as in
+	*  xsltAttributeInternal() (attributes.c), but I currently
+	*  don't want to add yet another ns-lookup function.
+	*/
+	if ((targetElem->ns != NULL) &&
+	    (targetElem->ns->prefix != NULL) &&
+	    xmlStrEqual(targetElem->ns->href, attr->ns->href))
+	{
+	    ns = targetElem->ns;
+	    goto namespace_finished;
+	}
+	if (prefix != NULL) {
+	    /*
+	    * Search by ns-prefix.
+	    */
+	    ns = xmlSearchNs(targetElem->doc, targetElem, prefix);
+	    if ((ns != NULL) &&
+		(xmlStrEqual(ns->href, attr->ns->href)))
+	    {
+		goto namespace_finished;
+	    }
+	}
+	/*
+	* Fallback to a search by ns-name.
+	*/	
+	ns = xmlSearchNsByHref(targetElem->doc, targetElem, attr->ns->href);
+	if ((ns != NULL) && (ns->prefix != NULL)) {
+	    goto namespace_finished;
+	}
+	/*
+	* OK, we need to declare the namespace on the target element.
+	*/
+	if (prefix) {
+	    if (targetElem->nsDef != NULL) {
+		ns = targetElem->nsDef;
+		do {
+		    if ((ns->prefix) && xmlStrEqual(ns->prefix, prefix)) {
+			/*
+			* The prefix aready occupied.
+			*/
+			break;
+		    }
+		    ns = ns->next;
+		} while (ns != NULL);
+		if (ns == NULL) {
+		    ns = xmlNewNs(targetElem, attr->ns->href, prefix);
+		    goto namespace_finished;
+		}
+	    }
+	}
+	/*
+	* Generate a new prefix.
+	*/
+	{
+	    const xmlChar *basepref = prefix;
+	    xmlChar pref[30];
+	    int counter = 0;
+	    
+	    if (prefix != NULL)
+		basepref = prefix;
+	    else
+		basepref = xmlStrdup(BAD_CAST "ns");
+	    
+	    do {
+		snprintf((char *) pref, 30, "%s_%d",
+		    basepref, counter++);
+		ns = xmlSearchNs(targetElem->doc,
+		    (xmlNodePtr) attr, BAD_CAST pref);
+		if (counter > 1000) {
+		    xsltTransformError(ctxt, NULL, (xmlNodePtr) attr,
+			"Namespace fixup error: Failed to compute a "
+			"new unique ns-prefix for the copied attribute "
+			"{%s}%s'.\n", attr->ns->href, attr->name);
+		    ns = NULL;
+		    break;
+		}
+	    } while (ns != NULL);
+	    if (basepref != prefix)
+		xmlFree((xmlChar *)basepref);
+	    ns = xmlNewNs(targetElem, attr->ns->href, BAD_CAST pref);
+	}
+
+namespace_finished:
+
+	if (ns == NULL) {
+	    xsltTransformError(ctxt, NULL, (xmlNodePtr) attr,
+		"Namespace fixup error: Failed to acquire an in-scope "
+		"namespace binding of the copied attribute '{%s}%s'.\n",
+		attr->ns->href, attr->name);
+	    /*
+	    * TODO: Should we just stop here?
+	    */
+	}
+	attrCopy = xmlSetNsProp(targetElem, ns, attr->name, NULL);
     } else {
-	ns = NULL;
+	attrCopy = xmlSetNsProp(targetElem, NULL, attr->name, NULL);
     }
-    val = xmlNodeListGetString(attr->doc, attr->children, 1);
-    ret = xmlSetNsProp(target, ns, attr->name, val);
-    if (val != NULL)
-	xmlFree(val);
-    return(ret);
+    if (attrCopy == NULL)	
+	return(NULL);    
+    /*
+    * NOTE: This was optimized according to bug #342695.
+    * TODO: Can this further be optimized, if source and target
+    *  share the same dict and attr->children is just 1 text node
+    *  which is in the dict? How probable is such a case?
+    */
+    value = xmlNodeListGetString(attr->doc, attr->children, 1);
+    if (value != NULL) {
+	txtNode = xmlNewDocText(targetElem->doc, NULL);
+	if (txtNode == NULL)
+	    return(NULL);
+	if ((targetElem->doc != NULL) &&
+	    (targetElem->doc->dict != NULL))
+	{
+	    txtNode->content =
+		(xmlChar *) xmlDictLookup(targetElem->doc->dict,
+		    BAD_CAST value, -1);
+	    xmlFree(value);	    
+	} else
+	    txtNode->content = value;
+	attrCopy->children = txtNode;
+    }
+    /*
+    * URGENT TODO: Do we need to create an empty text node if the value
+    *  is the empty string?
+    */    
+
+#else /* not XSLT_REFACTORED */
+
+    value = xmlNodeListGetString(attr->doc, attr->children, 1);
+    if (attr->ns != NULL) {
+	xmlNsPtr ns;
+	ns = xsltGetPlainNamespace(ctxt, attr->parent, attr->ns, targetElem);
+	attrCopy = xmlSetNsProp(targetElem, ns, attr->name, value);
+    } else {
+	attrCopy = xmlSetNsProp(targetElem, NULL, attr->name, value);
+    }
+    if (value != NULL)
+	xmlFree(value);
+
+#endif /* not XSLT_REFACTORED */
+
+    return(attrCopy);
 }
 
 /**
@@ -851,6 +1024,11 @@
  *
  * Make a copy of the element node @node
  * and insert it as last child of @insert
+ * Intended *only* for copying literal result elements and
+ * text-nodes.
+ * Called from:
+ *   xsltApplyOneTemplateInt()
+ *   xsltCopy()
  *
  * Returns a pointer to the new node, or NULL in case of error
  */
@@ -933,7 +1111,12 @@
  *
  * Do a copy of a namespace list. If @node is non-NULL the
  * new namespaces are added automatically.
+ * Called by:
+ *   xsltCopyTree()
  *
+ * TODO: What is the exact difference between this function
+ *  and xsltCopyNamespaceList() in "namespaces.c"?
+ *
  * Returns: a new xmlNsPtr, or NULL in case of error.
  */
 static xmlNsPtr
@@ -988,7 +1171,8 @@
  * Make a copy of the full tree under the element node @node
  * and insert it as last child of @insert
  * For literal result element, some of the namespaces may not be copied
- * over according to section 7.1 .
+ * over according to section 7.1.
+ * TODO: Why is this a public function?
  *
  * Returns a pointer to the new tree, or NULL in case of error
  */
@@ -1036,9 +1220,8 @@
         case XML_XINCLUDE_START:
         case XML_XINCLUDE_END:
             return(NULL);
-    }
-    if ((node->name != NULL) && (node->name[0] == ' ') &&
-	(xmlStrEqual(node->name, (const xmlChar *) " fake node libxslt"))) {
+    }    
+    if (XSLT_IS_RES_TREE_FRAG(node)) {
 	if (node->children != NULL)
 	    copy = xsltCopyTreeList(ctxt, node->children, insert, 0);
 	else
@@ -1063,7 +1246,11 @@
 	    (node->type == XML_ATTRIBUTE_NODE)) {
 	    xmlNsPtr *nsList, *cur, ns;
 	    /*
-	     * must add in any new namespaces in scope for the node
+	     * Must add any new namespaces in scope for the node.
+	     * TODO: Since we try to reuse existing in-scope ns-decls by
+	     *  using xmlSearchNsByHref(), this will eventually change
+	     *  the prefix of an original ns-binding; thus it might
+	     *  break QNames in element/attribute content.
 	     */
 	    nsList = xmlGetNsList(node->doc, node);
 	    if (nsList != NULL) {
@@ -1076,9 +1263,15 @@
 		}
 		xmlFree(nsList);
 	    }
-	    if (node->ns != NULL)
-		copy->ns = xsltGetNamespace(ctxt, node, node->ns, copy);
-	    else if ((insert->type == XML_ELEMENT_NODE) && (insert->ns != NULL)) {
+	    if (node->ns != NULL) {
+		/*
+		* This will map  copy->ns to one of the newly created
+		* in-scope ns-decls.
+		*/
+		copy->ns = xsltGetNamespace(ctxt, node, node->ns, copy);		
+	    } else if ((insert->type == XML_ELEMENT_NODE) &&
+		(insert->ns != NULL))
+	    {
 		xmlNsPtr defaultNs;
 
 		defaultNs = xmlSearchNs(insert->doc, insert, NULL);
@@ -1127,8 +1320,9 @@
     xmlNodePtr child;
     int ret = 0;
     
-    if ((ctxt == NULL) || (node == NULL) || (inst == NULL))
-	return(ret);
+    if ((ctxt == NULL) || (node == NULL) || (inst == NULL) ||
+	(inst->children == NULL))
+	return(0);
 
     child = inst->children;
     while (child != NULL) {
@@ -1465,8 +1659,278 @@
     }
 }
 
+#ifdef XSLT_REFACTORED
+/**
+* xsltTransLREUndeclareDefaultNs:
+* @ctxt:  the transformation context
+* @cur:  the literal result element
+* @ns:  the namespace
+* @out:  the output node (or its parent)
+*
+*
+* Find a matching (prefix and ns-name) ns-declaration
+*  for the given @ns in the result tree.
+* If none is found then a new ns-declaration will be
+*  added to @out. If, in this case, the given prefix is already
+*  in use, then a ns-declaration with a modified ns-prefix
+*  be we created.
+*
+* Returns the acquired ns-declaration
+*         or NULL in case of an API or internal error.
+*/
+static int
+xsltTransLREUndeclareResultDefaultNs(xsltTransformContextPtr ctxt,
+				     xmlNodePtr cur,
+				     xmlNodePtr resultElem)
+{
+    xmlNsPtr ns;
+    /*
+    * OPTIMIZE TODO: This all could be optimized by keeping track of
+    *  the ns-decls currently in-scope via a specialized context.
+    */
+    /*
+    * Search on the result element itself.
+    */
+    if (resultElem->nsDef != NULL) {
+	ns = resultElem->nsDef;
+	do {
+	    if (ns->prefix == NULL) {
+		if ((ns->href != NULL) && (ns->href[0] != 0)) {
+		    /*
+		    * Raise a namespace normalization error.
+		    */
+		    xsltTransformError(ctxt, NULL, cur,
+			"Namespace normalization error: Cannot undeclare "
+			"the default namespace, since the default namespace "
+			"'%s' is already declared on the result element.\n",
+			ns->href);
+		    return(1);
+		} else {
+		    /*
+		    * The default namespace was undeclared on the
+		    * result element.
+		    */
+		    return(0);
+		}
+		break;
+	    }
+	    ns = ns->next;
+	} while (ns != NULL);
+    }
 
+    if ((resultElem->parent != NULL) &&
+	(resultElem->parent->type == XML_ELEMENT_NODE))
+    {
+	/*
+	* The parent element is in no namespace, so assume
+	* that there is no default namespace in scope.
+	*/
+	if (resultElem->parent->ns == NULL)
+	    return(0);
+
+	ns = xmlSearchNs(resultElem->doc, resultElem->parent,
+	    NULL);
+	/*
+	* Fine if there's no default ns is scope, or if the
+	* default ns was undeclared.
+	*/
+	if ((ns == NULL) || (ns->href == NULL) || (ns->href[0] == 0))
+	    return(0);
+
+	/*
+	* Undeclare the default namespace.
+	*/
+	ns = xmlNewNs(resultElem, BAD_CAST "", NULL);
+	/* TODO: Check result */	
+	return(0);
+    }
+    return(0);
+}
+
 /**
+* xsltTransLREAcquireResultInScopeNs:
+* @ctxt: the transformation context
+* @cur: the literal result element (in the stylesheet)
+* @literalNs: the namespace (in the stylsheet)
+* @resultElem: the generated result element
+*
+*
+* Find a matching (prefix and ns-name) ns-declaration
+*  for the given @ns in the result tree.
+* If none is found then a new ns-declaration will be
+*  added to @out. If, in this case, the given prefix is already
+*  in use, then a ns-declaration with a modified ns-prefix
+*  be we created.
+*
+* Returns the acquired ns-declaration
+*         or NULL in case of an API or internal error.
+*/
+static xmlNsPtr
+xsltTransLREAcquireResultInScopeNs(xsltTransformContextPtr ctxt,
+				   xmlNodePtr cur,
+				   xmlNsPtr literalNs,
+				   xmlNodePtr resultElem)
+{    
+    xmlNsPtr ns;
+    int prefixOccupied = 0;
+
+    if ((ctxt == NULL) || (cur == NULL) || (resultElem == NULL))
+	return(NULL);
+    
+    /*
+    * OPTIMIZE TODO: This all could be optimized by keeping track of
+    *  the ns-decls currently in-scope via a specialized context.
+    */
+    /*
+    * NOTE: Namespace exclusion and ns-aliasing is performed at
+    * compilation-time in the refactored code; so this need not be done
+    * here.
+    */
+    /*
+    * First: search on the result element itself.
+    */
+    if (resultElem->nsDef != NULL) {
+	ns = resultElem->nsDef;
+	do {
+	    if ((ns->prefix == NULL) == (literalNs->prefix == NULL)) {
+		if (literalNs->prefix == NULL) {
+		    if (xmlStrEqual(ns->href, literalNs->href))
+			return(ns);
+		    prefixOccupied = 1;
+		    break;
+		} else if ((ns->prefix[0] == literalNs->prefix[0]) &&
+		     xmlStrEqual(ns->prefix, literalNs->prefix))
+		{
+		    if (xmlStrEqual(ns->href, literalNs->href))
+			return(ns);
+		    prefixOccupied = 1;
+		    break;
+		}
+	    }
+	    ns = ns->next;
+	} while (ns != NULL);
+    }
+    if (prefixOccupied) {
+	/*
+	* If the ns-prefix is occupied by an other ns-decl on the
+	* result element, then this means:
+	* 1) The desired prefix is shadowed
+	* 2) There's no way around changing the prefix	
+	*
+	* Try a desperate search for an in-scope ns-decl
+	* with a matching ns-name before we use the last option,
+	* which is to recreate the ns-decl with a modified prefix.
+	*/
+	ns = xmlSearchNsByHref(resultElem->doc, resultElem, literalNs->href);
+	if (ns != NULL)
+	    return(ns);
+
+	/*
+	* Fallback to changing the prefix.
+	*/    
+    } else if ((resultElem->parent != NULL) &&
+	(resultElem->parent->type == XML_ELEMENT_NODE)) {
+	/*
+	* Try to find a matching ns-decl in the ancestor-axis.
+	*
+	* Check the common case: The parent element of the current
+	* result element is in the same namespace (with an equal ns-prefix).
+	*/     
+	if ((resultElem->parent->ns != NULL) &&
+	    ((resultElem->parent->ns->prefix == NULL) ==
+	     (literalNs->prefix == NULL)))
+	{
+	    ns = resultElem->parent->ns;
+	    
+	    if (literalNs->prefix == NULL) {
+		if (xmlStrEqual(ns->href, literalNs->href))
+		    return(ns);
+	    } else if ((ns->prefix[0] == literalNs->prefix[0]) &&
+		xmlStrEqual(ns->prefix, literalNs->prefix) &&
+		xmlStrEqual(ns->href, literalNs->href))
+	    {
+		return(ns);
+	    }
+	}
+	/*
+	* Lookup the remaining in-scope namespaces.
+	*/    
+	ns = xmlSearchNs(resultElem->doc, resultElem->parent,
+	    literalNs->prefix);
+	if ((ns != NULL) && xmlStrEqual(ns->href, literalNs->href))
+	    return(ns);
+	ns = NULL;
+	/*
+	* Either no matching ns-prefix was found or the namespace is
+	* shadowed.
+	* Create a new ns-decl on the current result element.
+	*
+	* SPEC TODO: Hmm, we could also try to reuse an in-scope
+	*  namespace with a matching ns-name but a different
+	*  ns-prefix.
+	*  What has higher precedence? 
+	*  1) If keeping the prefix: create a new ns-decl.
+	*  2) If reusal: first lookup ns-names; then fallback
+	*     to creation of a new ns-decl.
+	* REVISIT TODO: this currently uses case 2) since this
+	*  is the way it used to be before refactoring.
+	*/
+	ns = xmlSearchNsByHref(resultElem->doc, resultElem,
+	    literalNs->href);
+	if (ns != NULL)
+	    return(ns);
+	/*
+	* Create the ns-decl on the current result element.
+	*/
+	ns = xmlNewNs(resultElem, literalNs->href, literalNs->prefix);
+	/* TODO: check errors */
+	return(ns);
+    } else if ((resultElem->parent == NULL) ||
+	(resultElem->parent->type != XML_ELEMENT_NODE))
+    {
+	/*
+	* This is the root of the tree.
+	*/
+	ns = xmlNewNs(resultElem, literalNs->href, literalNs->prefix);
+	/* TODO: Check result */
+	return(ns);
+    }
+    /*
+    * Fallback: we need to generate a new prefix and declare the namespace
+    * on the result element.
+    */
+    {
+	xmlChar prefix[30];
+	int counter = 0;
+	
+	/*
+	* Comment copied from xslGetNamespace():
+	*  "For an element node, if we don't find it, or it's the default
+	*  and this element already defines a default (bug 165560), we
+	*  need to create it."
+	*/		
+	do {
+	    snprintf((char *) prefix, 30, "%s_%d",
+		literalNs->prefix, counter++);
+	    ns = xmlSearchNs(resultElem->doc, resultElem, BAD_CAST prefix);
+	    if (counter > 1000) {
+		xsltTransformError(ctxt, NULL, cur,
+		    "Internal error in xsltTransLREAcquireInScopeNs(): "		    
+		    "Failed to compute a unique ns-prefix for the "
+		    "result element");
+		return(NULL);
+	    }
+	} while (ns != NULL);
+	ns = xmlNewNs(resultElem, literalNs->href, BAD_CAST prefix);
+	/* TODO: Check result */
+	return(ns);
+    }
+    return(NULL);    
+}
+
+#endif /* XSLT_REFACTORED */
+
+/**
  * xsltApplyOneTemplate:
  * @ctxt:  a XSLT process context
  * @node:  the node in the source tree.
@@ -1513,6 +1977,9 @@
     xmlNodePtr oldInst = NULL;
     int oldBase;
     xmlDocPtr tmpRVT = NULL;
+#ifdef XSLT_REFACTORED
+    xsltStylePreCompPtr info;
+#endif
 
     int level = 0;
 
@@ -1615,7 +2082,7 @@
         if (insert == NULL) {
 #ifdef WITH_XSLT_DEBUG_PROCESS
             XSLT_TRACE(ctxt,XSLT_TRACE_APPLY_TEMPLATE,xsltGenericDebug(xsltGenericDebugContext,
-                             "xsltApplyOneTemplate: insert == NULL !\n"));
+                             "xsltApplyOneTemplateInt: insert == NULL !\n"));
 #endif
             goto error;
         }
@@ -1624,6 +2091,411 @@
             xslHandleDebugger(cur, node, templ, ctxt);
 #endif
 
+#ifdef XSLT_REFACTORED
+	if (cur->type == XML_ELEMENT_NODE) {
+	    info = (xsltStylePreCompPtr) cur->psvi;
+	    /*
+	    * We expect a compiled representation on:
+	    * 1) XSLT instructions of this XSLT version (1.0)
+	    *    (with a few exceptions)
+	    * 2) Literal result elements
+	    * 3) Extension instructions
+	    * 4) XSLT instructions of future XSLT versions
+	    *    (forwards-compatible mode).
+	    */
+	    if (info == NULL) {
+		/*
+		* Handle the rare cases where we don't expect a compiled
+		* representation on an XSLT element.
+		*/
+		if (IS_XSLT_ELEM_FAST(cur) && IS_XSLT_NAME(cur, "message")) {
+		    xsltMessage(ctxt, node, cur);
+		    goto skip_children;
+		}		    		 
+		/*
+		* Something really went wrong:
+		*/
+		xsltTransformError(ctxt, NULL, cur,
+		    "Internal error in xsltApplyOneTemplateInt(): "
+		    "The element '%s' in the stylesheet has no compiled "
+		    "representation.\n",
+		    cur->name);
+                goto skip_children;
+            }
+
+	    if (info->type == XSLT_FUNC_LITERAL_RESULT_ELEMENT) {
+		xsltStyleItemLRElementInfoPtr lrInfo =
+		    (xsltStyleItemLRElementInfoPtr) info;
+		/*
+		* Literal result elements
+		* --------------------------------------------------------
+		*/
+#ifdef WITH_XSLT_DEBUG_PROCESS
+		XSLT_TRACE(ctxt, XSLT_TRACE_APPLY_TEMPLATE,
+		    xsltGenericDebug(xsltGenericDebugContext,
+		    "xsltApplyOneTemplateInt: copy literal result "
+		    "element '%s'\n", cur->name));
+#endif
+		/*
+		* Copy the raw element-node.
+		* OLD: if ((copy = xsltCopyNode(ctxt, cur, insert)) == NULL)
+		*   goto error;
+		*/		
+		copy = xmlDocCopyNode(cur, insert->doc, 0);
+		if (copy == NULL) {
+		    xsltTransformError(ctxt, NULL, cur,
+			"Internal error in xsltApplyOneTemplateInt(): "
+			"Failed to copy literal result element '%s'.\n",
+			cur->name);
+		    goto error;
+		} else {
+		    /*
+		    * Add the element-node to the result tree.
+		    */
+		    copy->doc = ctxt->output;
+		    xmlAddChild(insert, copy);
+		    /*
+		    * Create effective namespaces declarations.
+		    * OLD: xsltCopyNamespaceList(ctxt, copy, cur->nsDef);
+		    */
+		    if (lrInfo->effectiveNs != NULL) {
+			xsltEffectiveNsPtr effNs = lrInfo->effectiveNs;
+			xmlNsPtr ns, lastns = NULL;
+
+			while (effNs != NULL) {
+			    /*
+			    * Avoid generating redundant namespace
+			    * declarations; thus lookup if there is already
+			    * such a ns-decl in the result.
+			    */			    
+			    ns = xmlSearchNs(copy->doc, copy, effNs->prefix);
+			    if ((ns != NULL) &&
+				(xmlStrEqual(ns->href, effNs->nsName)))
+			    {
+				effNs = effNs->next;
+				continue;			    
+			    }
+			    ns = xmlNewNs(copy, effNs->nsName, effNs->prefix);
+			    if (ns == NULL) {
+				xsltTransformError(ctxt, NULL, cur,
+				    "Internal error in xsltApplyOneTemplateInt(): "
+				    "Failed to copy a namespace declaration.\n");
+				goto error;
+			    }
+								
+			    if (lastns == NULL)
+				copy->nsDef = ns;
+			    else
+				lastns->next =ns;
+			    lastns = ns;
+
+			    effNs = effNs->next;
+			}
+			
+		    }
+		    /*
+		    * NOTE that we don't need to apply ns-alising: this was
+		    *  already done at compile-time.
+		    */
+		    if (cur->ns != NULL) {
+			/*
+			* If there's no such ns-decl in the result tree,
+			* then xsltGetNamespace() will create a ns-decl
+			* on the copied node.
+			*/
+			/*
+			* REVISIT TODO: Changed to use
+			*  xsltTransLREAcquireInScopeNs() instead of
+			*  xsltGetNamespace().
+			*  OLD: copy->ns = xsltGetNamespace(ctxt, cur,
+			*                     cur->ns, copy);
+			*/
+			copy->ns = xsltTransLREAcquireResultInScopeNs(ctxt,
+			    cur, cur->ns, copy);
+		    } else {
+			/*
+			* Undeclare the default namespace if needed.
+			* This can be skipped, if:
+			* 1) If the result element has no ns-decls, in which
+			*    case the result element abviously does not
+			*    declare a default namespace.
+			* 2) AND there's either no parent, or the parent
+			*   is in no namespace; this means there's no
+			*   default namespace is scope to care about.
+			*
+			* REVISIT TODO: This might result in massive
+			*  generation of ns-decls if nodes in a default
+			*  namespaces are mixed with nodes in no namespace.
+			*  
+			*/
+			if (copy->nsDef ||
+			    ((insert != NULL) && (insert->ns != NULL)))
+			    xsltTransLREUndeclareResultDefaultNs(ctxt,
+				cur, copy);
+#if 0
+			defaultNs = xmlSearchNs(insert->doc, insert, NULL);
+			if ((defaultNs != NULL) && (defaultNs->href != NULL))
+			    xmlNewNs(copy, BAD_CAST "", NULL);
+#endif
+		    }
+		}
+		/*
+		* SPEC XSLT 2.0 "Each attribute of the literal result
+		*  element, other than an attribute in the XSLT namespace,
+		*  is processed to produce an attribute for the element in
+		*  the result tree."
+		* TODO: Refactor this, since it still uses ns-aliasing.
+		*/
+		if (cur->properties != NULL) {
+		    xsltAttrListTemplateProcess(ctxt, copy, cur->properties);
+		}
+		/*
+		* OLD-COMMENT: "Add extra namespaces inherited from the
+		*   current template if we are in the first level children
+		*   and this is a "real" template.
+		*
+		* SPEC XSLT 2.0:
+		*  "The following namespaces are designated as excluded
+		*   namespaces:
+		*  - The XSLT namespace URI
+		*      (http://www.w3.org/1999/XSL/Transform)
+		*  - A namespace URI declared as an extension namespace
+		*  - A namespace URI designated by using an
+		*      [xsl:]exclude-result-prefixes
+		*
+		* TODO:
+		*  XSLT 1.0
+		*   1) Supply all in-scope namespaces
+		*   2) Skip excluded namespaces (see above)
+		*   3) Apply namespace aliasing
+		*
+		*  XSLT 2.0 (will generate
+		*            redundant namespaces in some cases):
+		*   1) Supply all in-scope namespaces
+		*   2) Skip excluded namespaces if *not* target-namespace
+		*      of an namespace alias
+		*   3) Apply namespace aliasing
+		*
+		* NOTE: See bug #341325.
+		*/
+#if 0		
+		if ((templ != NULL) && (oldInsert == insert) &&
+		    (ctxt->templ != NULL) &&
+		    (ctxt->templ->inheritedNs != NULL)) {
+		    int i;
+		    xmlNsPtr ns, ret;
+		    
+		    for (i = 0; i < ctxt->templ->inheritedNsNr; i++) {
+			const xmlChar *URI = NULL;
+			xsltStylesheetPtr style;
+
+			ns = ctxt->templ->inheritedNs[i];
+			/*
+			* Apply namespace aliasing.
+			*
+			* TODO: Compute the effective value of namespace
+			*  aliases at compilation-time in order to avoid
+			*  the lookup in the import-tree here.
+			*/
+			style = ctxt->style;
+			while (style != NULL) {
+			    if (style->nsAliases != NULL)
+				URI = (const xmlChar *) 
+				    xmlHashLookup(style->nsAliases, ns->href);
+			    if (URI != NULL)
+				break;
+			    
+			    style = xsltNextImport(style);
+			}
+			if (URI == UNDEFINED_DEFAULT_NS) {
+			    xmlNsPtr defaultNs;
+
+			    defaultNs = xmlSearchNs(cur->doc, cur, NULL);
+			    if (defaultNs == NULL) {
+				/*
+				* TODO: Should not happen; i.e., it is
+				*  an error at compilation-time if there's
+				*  no default namespace in scope if
+				*  "#default" is used.
+				*/
+				continue;
+			    } else
+				URI = defaultNs->href;
+			}
+			
+			if (URI == NULL) {
+			    /*
+			    * There was no matching namespace-alias, so
+			    * just create a matching ns-decl if not
+			    * already in scope.
+			    */
+			    ret = xmlSearchNs(copy->doc, copy, ns->prefix);
+			    if ((ret == NULL) ||
+				(!xmlStrEqual(ret->href, ns->href)))
+				xmlNewNs(copy, ns->href, ns->prefix);
+			} else if (!xmlStrEqual(URI, XSLT_NAMESPACE)) {
+			    ret = xmlSearchNs(copy->doc, copy, ns->prefix);
+			    if ((ret == NULL) ||
+				(!xmlStrEqual(ret->href, URI))) {
+				/*
+				* Here we create a namespace
+				* declaration with the literal namespace
+				* prefix and with the target namespace name.
+				* TODO: We should consider to fix this and
+				*  use the *target* namespace prefix, not the
+				*  literal one (see bug #341325).
+				*/
+				xmlNewNs(copy, URI, ns->prefix);
+			    }
+			}
+		    }
+		    if (copy->ns != NULL) {
+			/*
+			* Fix the node namespace if needed
+			*/
+			copy->ns = xsltGetNamespace(ctxt, copy, copy->ns, copy);
+		    }
+		}
+#endif
+	    } else if (IS_XSLT_ELEM_FAST(cur)) {
+		/*
+		* XSLT instructions
+		* --------------------------------------------------------
+		*/
+		if (info->type == XSLT_FUNC_UNKOWN_FORWARDS_COMPAT) {
+		    /*
+		    * We hit an unknown XSLT element.
+		    * Try to apply one of the fallback cases.
+		    */		
+		    ctxt->insert = insert;
+		    if (!xsltApplyFallbacks(ctxt, node, cur)) {
+			xsltTransformError(ctxt, NULL, cur,
+			    "The is no fallback behaviour defined for "
+			    "the unknown XSLT element '%s'.\n",
+			    cur->name);
+		    }			
+		    ctxt->insert = oldInsert;
+		    goto skip_children;
+		}
+		/*
+		* Execute the XSLT instruction.
+		*/
+		if (info->func != NULL) {
+		    ctxt->insert = insert;
+		    info->func(ctxt, node, cur, (xsltElemPreCompPtr) info);
+		    ctxt->insert = oldInsert;
+		    goto skip_children;
+		}
+		/*
+		* Some XSLT instructions need custom execution.
+		*/		 
+		if (info->type == XSLT_FUNC_VARIABLE) {
+		    if (level != 0) {
+			/*
+			* Build a new subframe and skip all the nodes
+			* at that level.
+			*/
+			ctxt->insert = insert;
+			xsltApplyOneTemplateInt(ctxt, node, cur, NULL, NULL, 0);
+			while (cur->next != NULL)
+			    cur = cur->next;
+			ctxt->insert = oldInsert;
+		    } else {
+			xsltParseStylesheetVariable(ctxt, cur);
+		    }
+		} else if (info->type == XSLT_FUNC_PARAM) {
+		    xsltParseStylesheetParam(ctxt, cur);
+		} else if (info->type == XSLT_FUNC_MESSAGE) {
+		    /*
+		    * TODO: Won't be hit, since we don't compile xsl:message.
+		    */
+		    xsltMessage(ctxt, node, cur);
+		} else {
+		    xsltGenericError(xsltGenericErrorContext,
+			"Internal error in xsltApplyOneTemplateInt(): "
+			"Don't know how to process the XSLT element "
+			"'%s'.\n", cur->name);			
+		}
+		goto skip_children;
+
+	    } else {
+		xsltTransformFunction func;
+		/*
+		* Extension intructions (elements)
+		* --------------------------------------------------------
+		*/				
+		if (cur->psvi == xsltExtMarker) {
+		    /*
+		    * The xsltExtMarker was set during the compilation
+		    * of extension instructions if there was no registered
+		    * handler for this specific extension function at
+		    * compile-time.
+		    * Libxslt will now lookup if a handler is
+		    * registered in the context of this transformation.
+		    */
+		    func = (xsltTransformFunction)
+			xsltExtElementLookup(ctxt, cur->name, cur->ns->href);
+		} else
+		    func = ((xsltElemPreCompPtr) cur->psvi)->func;
+		
+		if (func == NULL) {
+		    /*
+		    * No handler available.
+		    * Try to execute fallback behaviour via xsl:fallback.
+		    */
+#ifdef WITH_XSLT_DEBUG_PROCESS
+		    XSLT_TRACE(ctxt, XSLT_TRACE_APPLY_TEMPLATE,
+			xsltGenericDebug(xsltGenericDebugContext,
+			    "xsltApplyOneTemplate: unknown extension %s\n",
+			    cur->name));
+#endif
+		    ctxt->insert = insert;
+		    if (!xsltApplyFallbacks(ctxt, node, cur)) {
+			xsltTransformError(ctxt, NULL, cur,
+			    "Unknown extension instruction '{%s}%s'.\n",
+			    cur->ns->href, cur->name);
+		    }			
+		    ctxt->insert = oldInsert;		    
+		} else {
+		    /*
+		    * Execute the handler-callback.
+		    */
+#ifdef WITH_XSLT_DEBUG_PROCESS
+		    XSLT_TRACE(ctxt,XSLT_TRACE_APPLY_TEMPLATE,xsltGenericDebug(xsltGenericDebugContext,
+			"xsltApplyOneTemplate: extension construct %s\n",
+			cur->name));
+#endif		    
+		    ctxt->insert = insert;
+		    func(ctxt, node, cur, cur->psvi);
+		    ctxt->insert = oldInsert;
+		}
+		goto skip_children;
+	    }
+
+	} else if (XSLT_IS_TEXT_NODE(cur)) {
+	    /*
+	    * Text
+	    * ------------------------------------------------------------
+	    */
+#ifdef WITH_XSLT_DEBUG_PROCESS
+            if (cur->name == xmlStringTextNoenc) {
+                XSLT_TRACE(ctxt, XSLT_TRACE_APPLY_TEMPLATE,
+		    xsltGenericDebug(xsltGenericDebugContext,
+		    "xsltApplyOneTemplateInt: copy unescaped text '%s'\n",
+		    cur->content));
+            } else {
+                XSLT_TRACE(ctxt, XSLT_TRACE_APPLY_TEMPLATE,
+		    xsltGenericDebug(xsltGenericDebugContext,
+		    "xsltApplyOneTemplateInt: copy text '%s'\n",
+		    cur->content));
+            }
+#endif
+            if (xsltCopyText(ctxt, insert, cur, ctxt->internalized) == NULL)
+		goto error;	    
+	}
+
+#else /* XSLT_REFACTORED */
+
         if (IS_XSLT_ELEM(cur)) {
             /*
              * This is an XSLT node
@@ -1681,6 +2553,7 @@
             goto skip_children;
         } else if ((cur->type == XML_TEXT_NODE) ||
                    (cur->type == XML_CDATA_SECTION_NODE)) {
+
             /*
              * This text comes from the stylesheet
              * For stylesheets, the set of whitespace-preserving
@@ -1774,7 +2647,7 @@
             /*
              * Add extra namespaces inherited from the current template
              * if we are in the first level children and this is a
-	     * "real" template.
+	     * "real" template.	     
              */
             if ((templ != NULL) && (oldInsert == insert) &&
                 (ctxt->templ != NULL) && (ctxt->templ->inheritedNs != NULL)) {
@@ -1795,7 +2668,7 @@
 		      
 		      style = xsltNextImport(style);
 		    }
-
+		    		    
 		    if (URI == UNDEFINED_DEFAULT_NS) {
 		      xmlNsPtr dflt;
 		      dflt = xmlSearchNs(cur->doc, cur, NULL);
@@ -1825,9 +2698,10 @@
 		}
             }
         }
+#endif /* else of XSLT_REFACTORED */
 
         /*
-         * Skip to next node, in document order.
+         * Descend into content in document order.
          */
         if (cur->children != NULL) {
             if (cur->children->type != XML_ENTITY_DECL) {
@@ -1838,10 +2712,13 @@
                 continue;
             }
         }
-      skip_children:
+
+skip_children:
 	/*
-	If xslt:message just processed, might have terminate='yes'
-	If so, break out of while to clean up processing.
+	* If xslt:message was just processed, we might have hit a
+	* terminate='yes'; if so, then break the loop and clean up.
+	* TODO: Do we need to check this also before trying to descend
+	*  into the content?
 	*/
 	if (ctxt->state == XSLT_STATE_STOPPED)
 	    break;
@@ -2462,7 +3339,7 @@
  * @inst:  the xslt copy node
  * @comp:  precomputed information
  *
- * Process the xslt copy node on the source node
+ * Execute the xsl:copy instruction on the source node.
  */
 void
 xsltCopy(xsltTransformContextPtr ctxt, xmlNodePtr node,
@@ -2473,7 +3350,7 @@
     xsltStylePreCompPtr comp = castedComp;
 #endif
     xmlNodePtr copy, oldInsert;
-
+   
     oldInsert = ctxt->insert;
     if (ctxt->insert != NULL) {
 	switch (node->type) {
@@ -2499,8 +3376,12 @@
 	    case XML_HTML_DOCUMENT_NODE:
 		break;
 	    case XML_ELEMENT_NODE:
-		if (xmlStrEqual(node->name, BAD_CAST " fake node libxslt"))
-		    return;
+		/*
+		* NOTE: The "fake" is a doc-node, not an element node.
+		* OLD:
+		*   if (xmlStrEqual(node->name, BAD_CAST " fake node libxslt"))
+		*    return;
+		*/		
 
 #ifdef WITH_XSLT_DEBUG_PROCESS
 		XSLT_TRACE(ctxt,XSLT_TRACE_COPY,xsltGenericDebug(xsltGenericDebugContext,
@@ -2781,6 +3662,10 @@
 	if (comp->use != NULL) {
 	    xsltApplyAttributeSet(ctxt, node, inst, comp->use);
 	} else {
+	    /*
+	    * BUG TODO: use-attribute-sets is not a value template.
+	    *  use-attribute-sets = qnames
+	    */
 	    attributes = xsltEvalAttrValueTemplate(ctxt, inst,
 		       (const xmlChar *)"use-attribute-sets", NULL);
 	    if (attributes != NULL) {
@@ -2908,12 +3793,12 @@
 
 /**
  * xsltCopyOf:
- * @ctxt:  a XSLT process context
- * @node:  the node in the source tree.
- * @inst:  the xslt copy-of node
- * @comp:  precomputed information
+ * @ctxt:  an XSLT transformation context
+ * @node:  the current node in the source tree
+ * @inst:  the element node of the XSLT copy-of instruction 
+ * @comp:  precomputed information of the XSLT copy-of instruction
  *
- * Process the xslt copy-of node on the source node
+ * Process the XSLT copy-of instruction.
  */
 void
 xsltCopyOf(xsltTransformContextPtr ctxt, xmlNodePtr node,
@@ -2938,20 +3823,41 @@
 	return;
     }
 
+     /*
+    * SPEC XSLT 1.0:
+    *  "The xsl:copy-of element can be used to insert a result tree
+    *  fragment into the result tree, without first converting it to
+    *  a string as xsl:value-of does (see [7.6.1 Generating Text with
+    *  xsl:value-of]). The required select attribute contains an
+    *  expression. When the result of evaluating the expression is a
+    *  result tree fragment, the complete fragment is copied into the
+    *  result tree. When the result is a node-set, all the nodes in the
+    *  set are copied in document order into the result tree; copying
+    *  an element node copies the attribute nodes, namespace nodes and
+    *  children of the element node as well as the element node itself;
+    *  a root node is copied by copying its children. When the result
+    *  is neither a node-set nor a result tree fragment, the result is
+    *  converted to a string and then inserted into the result tree,
+    *  as with xsl:value-of.
+    */
+
 #ifdef WITH_XSLT_DEBUG_PROCESS
     XSLT_TRACE(ctxt,XSLT_TRACE_COPY_OF,xsltGenericDebug(xsltGenericDebugContext,
 	 "xsltCopyOf: select %s\n", comp->select));
 #endif
 
+    /*
+    * Set up the XPath evaluation context.
+    */
     oldProximityPosition = ctxt->xpathCtxt->proximityPosition;
     oldContextSize = ctxt->xpathCtxt->contextSize;
     oldNsNr = ctxt->xpathCtxt->nsNr;
     oldNamespaces = ctxt->xpathCtxt->namespaces;
     ctxt->xpathCtxt->node = node;
 #ifdef XSLT_REFACTORED
-    if (comp->inScopeNS != NULL) {
-	ctxt->xpathCtxt->namespaces = comp->inScopeNS->list;
-	ctxt->xpathCtxt->nsNr = comp->inScopeNS->number;
+    if (comp->inScopeNs != NULL) {
+	ctxt->xpathCtxt->namespaces = comp->inScopeNs->list;
+	ctxt->xpathCtxt->nsNr = comp->inScopeNs->number;
     } else {
 	ctxt->xpathCtxt->namespaces = NULL;
 	ctxt->xpathCtxt->nsNr = 0;
@@ -2960,57 +3866,79 @@
     ctxt->xpathCtxt->namespaces = comp->nsList;
     ctxt->xpathCtxt->nsNr = comp->nsNr;
 #endif
+    /*
+    * Evaluate the "select" expression.
+    */
     res = xmlXPathCompiledEval(comp->comp, ctxt->xpathCtxt);
+    /*
+    * Revert the XPath evaluation context to previous state.
+    */
     ctxt->xpathCtxt->proximityPosition = oldProximityPosition;
     ctxt->xpathCtxt->contextSize = oldContextSize;
     ctxt->xpathCtxt->nsNr = oldNsNr;
     ctxt->xpathCtxt->namespaces = oldNamespaces;
+
     if (res != NULL) {
 	if (res->type == XPATH_NODESET) {
+	    /*
+	    * Node-set
+	    * --------
+	    */
 #ifdef WITH_XSLT_DEBUG_PROCESS
 	    XSLT_TRACE(ctxt,XSLT_TRACE_COPY_OF,xsltGenericDebug(xsltGenericDebugContext,
 		 "xsltCopyOf: result is a node set\n"));
 #endif
 	    list = res->nodesetval;
 	    if (list != NULL) {
-		/* the list is already sorted in document order by XPath */
-		/* append everything in this order under ctxt->insert */
+		xmlNodePtr cur;
+		/*
+		* The list is already sorted in document order by XPath.
+		* Append everything in this order under ctxt->insert.
+		*/
 		for (i = 0;i < list->nodeNr;i++) {
-		    if (list->nodeTab[i] == NULL)
+		    cur = list->nodeTab[i];
+		    if (cur == NULL)
 			continue;
-		    if ((list->nodeTab[i]->type == XML_DOCUMENT_NODE) ||
-			(list->nodeTab[i]->type == XML_HTML_DOCUMENT_NODE)) {
-			xsltCopyTreeList(ctxt, list->nodeTab[i]->children,
-				         ctxt->insert, 0);
-		    } else if (list->nodeTab[i]->type == XML_ATTRIBUTE_NODE) {
-			xsltCopyProp(ctxt, ctxt->insert, 
-				     (xmlAttrPtr) list->nodeTab[i]);
+		    if ((cur->type == XML_DOCUMENT_NODE) ||
+			(cur->type == XML_HTML_DOCUMENT_NODE))
+		    {
+			xsltCopyTreeList(ctxt, cur->children, ctxt->insert, 0);
+		    } else if (cur->type == XML_ATTRIBUTE_NODE) {
+			xsltCopyProp(ctxt, ctxt->insert, (xmlAttrPtr) cur);
 		    } else {
-			xsltCopyTree(ctxt, list->nodeTab[i], ctxt->insert, 0);
+			xsltCopyTree(ctxt, cur, ctxt->insert, 0);
 		    }
 		}
 	    }
 	} else if (res->type == XPATH_XSLT_TREE) {
+	    /*
+	    * Result tree fragment
+	    * --------------------
+	    */
 #ifdef WITH_XSLT_DEBUG_PROCESS
 	    XSLT_TRACE(ctxt,XSLT_TRACE_COPY_OF,xsltGenericDebug(xsltGenericDebugContext,
 		 "xsltCopyOf: result is a result tree fragment\n"));
 #endif
+	    /*
+	    * TODO: Is list->nodeTab[0] is an xmlDocPtr?
+	    */
 	    list = res->nodesetval;
 	    if ((list != NULL) && (list->nodeTab != NULL) &&
 		(list->nodeTab[0] != NULL) &&
-		(IS_XSLT_REAL_NODE(list->nodeTab[0]))) {
+		(IS_XSLT_REAL_NODE(list->nodeTab[0])))
+	    {
 		xsltCopyTreeList(ctxt, list->nodeTab[0]->children,
 			         ctxt->insert, 0);
 	    }
 	} else {
-	    /* convert to a string */
+	    /* Convert to a string. */
 	    res = xmlXPathConvertString(res);
 	    if ((res != NULL) && (res->type == XPATH_STRING)) {
 #ifdef WITH_XSLT_DEBUG_PROCESS
 		XSLT_TRACE(ctxt,XSLT_TRACE_COPY_OF,xsltGenericDebug(xsltGenericDebugContext,
 		     "xsltCopyOf: result %s\n", res->stringval));
 #endif
-		/* append content as text node */
+		/* Append content as text node. */
 		xsltCopyTextString(ctxt, ctxt->insert, res->stringval, 0);
 	    }
 	}
@@ -3065,9 +3993,9 @@
     oldNamespaces = ctxt->xpathCtxt->namespaces;
     ctxt->xpathCtxt->node = node;
 #ifdef XSLT_REFACTORED
-    if (comp->inScopeNS != NULL) {
-	ctxt->xpathCtxt->namespaces = comp->inScopeNS->list;
-	ctxt->xpathCtxt->nsNr = comp->inScopeNS->number;
+    if (comp->inScopeNs != NULL) {
+	ctxt->xpathCtxt->namespaces = comp->inScopeNs->list;
+	ctxt->xpathCtxt->nsNr = comp->inScopeNs->number;
     } else {
 	ctxt->xpathCtxt->namespaces = NULL;
 	ctxt->xpathCtxt->nsNr = 0;
@@ -3232,7 +4160,11 @@
 	*   structure. Avoid to "search" for params dynamically
 	*   in the XML tree every time.
 	*/
+#ifdef XSLT_REFACTORED
+	if (IS_XSLT_ELEM_FAST(cur)) {
+#else
 	if (IS_XSLT_ELEM(cur)) {
+#endif
 	    if (IS_XSLT_NAME(cur, "with-param")) {
 		param = xsltParseStylesheetCallerParam(ctxt, cur);
 		if (param != NULL) {
@@ -3345,9 +4277,9 @@
 
 	ctxt->xpathCtxt->node = node;
 #ifdef XSLT_REFACTORED
-	if (comp->inScopeNS != NULL) {
-	    ctxt->xpathCtxt->namespaces = comp->inScopeNS->list;
-	    ctxt->xpathCtxt->nsNr = comp->inScopeNS->number;
+	if (comp->inScopeNs != NULL) {
+	    ctxt->xpathCtxt->namespaces = comp->inScopeNs->list;
+	    ctxt->xpathCtxt->nsNr = comp->inScopeNs->number;
 	} else {
 	    ctxt->xpathCtxt->namespaces = NULL;
 	    ctxt->xpathCtxt->nsNr = 0;
@@ -3374,8 +4306,9 @@
 		if ((list != NULL) && (ctxt->document->keys != NULL)) {
 		    if ((list->nodeNr != 0) &&
 		        (list->nodeTab[0]->doc != NULL) &&
-		        (xmlStrEqual((xmlChar *)list->nodeTab[0]->doc->name,
-			   (const xmlChar *) " fake node libxslt")) &&
+
+		        XSLT_IS_RES_TREE_FRAG(list->nodeTab[0]->doc) &&
+
 			(list->nodeTab[0]->doc->_private == NULL)) {
 			    list->nodeTab[0]->doc->_private = xsltNewDocument(
 			    	ctxt, list->nodeTab[0]->doc);
@@ -3500,7 +4433,11 @@
 #endif
 #endif
         if (ctxt->state == XSLT_STATE_STOPPED) break;
+#ifdef XSLT_REFACTORED
+	if (IS_XSLT_ELEM_FAST(cur)) {
+#else
         if (IS_XSLT_ELEM(cur)) {
+#endif
             if (IS_XSLT_NAME(cur, "with-param")) {
                 param = xsltParseStylesheetCallerParam(ctxt, cur);
 		if (param != NULL) {
@@ -3620,13 +4557,23 @@
 	     "xsl:choose: empty content not allowed\n");
 	goto error;
     }
-    if (((!IS_XSLT_ELEM(replacement)) || (!IS_XSLT_NAME(replacement, "when")))
+#ifdef XSLT_REFACTORED
+    if (((!IS_XSLT_ELEM_FAST(replacement)) ||
+#else
+    if (((!IS_XSLT_ELEM(replacement)) ||
+#endif
+	(!IS_XSLT_NAME(replacement, "when")))
 	    && (!xmlIsBlankNode(replacement))) {
 	xsltTransformError(ctxt, NULL, inst,
 	     "xsl:choose: xsl:when expected first\n");
 	goto error;
     }
-    while ((IS_XSLT_ELEM(replacement) && (IS_XSLT_NAME(replacement, "when")))
+#ifdef XSLT_REFACTORED
+    while ((IS_XSLT_ELEM_FAST(replacement) &&
+#else
+    while ((IS_XSLT_ELEM(replacement) &&
+#endif    
+	(IS_XSLT_NAME(replacement, "when")))
 	    || xmlIsBlankNode(replacement)) {
 #ifdef XSLT_REFACTORED
 	xsltStyleItemWhenPtr wcomp =
@@ -3669,9 +4616,9 @@
 	oldNamespaces = ctxt->xpathCtxt->namespaces;
   	ctxt->xpathCtxt->node = node;
 #ifdef XSLT_REFACTORED
-	if (wcomp->inScopeNS != NULL) {
-	    ctxt->xpathCtxt->namespaces = wcomp->inScopeNS->list;
-	    ctxt->xpathCtxt->nsNr = wcomp->inScopeNS->number;
+	if (wcomp->inScopeNs != NULL) {
+	    ctxt->xpathCtxt->namespaces = wcomp->inScopeNs->list;
+	    ctxt->xpathCtxt->nsNr = wcomp->inScopeNs->number;
 	} else {
 	    ctxt->xpathCtxt->namespaces = NULL;
 	    ctxt->xpathCtxt->nsNr = 0;
@@ -3715,7 +4662,12 @@
 	res = NULL;
 	replacement = replacement->next;
     }
-    if (IS_XSLT_ELEM(replacement) && (IS_XSLT_NAME(replacement, "otherwise"))) {
+#ifdef XSLT_REFACTORED
+    if (IS_XSLT_ELEM_FAST(replacement) &&
+#else
+    if (IS_XSLT_ELEM(replacement) &&
+#endif	
+	(IS_XSLT_NAME(replacement, "otherwise"))) {
 #ifdef WITH_DEBUGGER
         if (xslDebugStatus != XSLT_DEBUG_NONE)
 #ifdef XSLT_REFACTORED
@@ -3791,9 +4743,9 @@
     oldNamespaces = ctxt->xpathCtxt->namespaces;
     ctxt->xpathCtxt->node = node;
 #ifdef XSLT_REFACTORED
-    if (comp->inScopeNS != NULL) {
-	ctxt->xpathCtxt->namespaces = comp->inScopeNS->list;
-	ctxt->xpathCtxt->nsNr = comp->inScopeNS->number;
+    if (comp->inScopeNs != NULL) {
+	ctxt->xpathCtxt->namespaces = comp->inScopeNs->list;
+	ctxt->xpathCtxt->nsNr = comp->inScopeNs->number;
     } else {
 	ctxt->xpathCtxt->namespaces = NULL;
 	ctxt->xpathCtxt->nsNr = 0;
@@ -3886,9 +4838,9 @@
     oldNamespaces = ctxt->xpathCtxt->namespaces;
     ctxt->xpathCtxt->node = node;
 #ifdef XSLT_REFACTORED
-    if (comp->inScopeNS != NULL) {
-	ctxt->xpathCtxt->namespaces = comp->inScopeNS->list;
-	ctxt->xpathCtxt->nsNr = comp->inScopeNS->number;
+    if (comp->inScopeNs != NULL) {
+	ctxt->xpathCtxt->namespaces = comp->inScopeNs->list;
+	ctxt->xpathCtxt->nsNr = comp->inScopeNs->number;
     } else {
 	ctxt->xpathCtxt->namespaces = NULL;
 	ctxt->xpathCtxt->nsNr = 0;
@@ -3933,7 +4885,12 @@
      * handle and skip the xsl:sort
      */
     replacement = inst->children;
-    while (IS_XSLT_ELEM(replacement) && (IS_XSLT_NAME(replacement, "sort"))) {
+#ifdef XSLT_REFACTORED
+    while (IS_XSLT_ELEM_FAST(replacement) &&
+#else
+    while (IS_XSLT_ELEM(replacement) &&
+#endif
+	(IS_XSLT_NAME(replacement, "sort"))) {
 	if (nbsorts >= XSLT_MAX_SORT) {
 	    xsltGenericError(xsltGenericErrorContext,
 		"xsl:for-each: too many sorts\n");
@@ -4139,6 +5096,45 @@
     return;
 }
 
+#ifdef XSLT_REFACTORED_KEYCOMP
+static int
+xsltCountKeys(xsltTransformContextPtr ctxt)
+{
+    xsltStylesheetPtr style;
+    xsltKeyDefPtr keyd;
+
+    if (ctxt == NULL)
+	return(-1);    
+
+    /*
+    * Do we have those nastly templates with a key() in the match pattern?
+    */
+    ctxt->hasTemplKeyPatterns = 0;
+    style = ctxt->style;
+    while (style != NULL) {
+	if (style->keyMatch != NULL) {
+	    ctxt->hasTemplKeyPatterns = 1;
+	    break;
+	}
+	style = xsltNextImport(style);
+    }
+    /*
+    * Count number of key declarations.
+    */
+    ctxt->nbKeys = 0;
+    style = ctxt->style;
+    while (style != NULL) {
+	keyd = style->keys;
+	while (keyd) {
+	    ctxt->nbKeys++;
+	    keyd = keyd->next;
+	}
+	style = xsltNextImport(style);
+    }        
+    return(ctxt->nbKeys);
+}
+#endif /* XSLT_REFACTORED_KEYCOMP */
+
 /**
  * xsltApplyStylesheetInternal:
  * @style:  a parsed XSLT stylesheet
@@ -4333,6 +5329,9 @@
     if (params != NULL)
         xsltEvalUserParams(ctxt, params);
     xsltEvalGlobalVariables(ctxt);
+#ifdef XSLT_REFACTORED_KEYCOMP    
+    xsltCountKeys(ctxt);
+#endif
     ctxt->node = (xmlNodePtr) doc;
     varsPush(ctxt, NULL);
     ctxt->varsBase = ctxt->varsNr - 1;
@@ -4399,6 +5398,10 @@
             }
             if (tmp == root) {
                 ctxt->type = XSLT_OUTPUT_HTML;
+		/*
+		* REVISIT TODO: XML_HTML_DOCUMENT_NODE is set after the
+		*  transformation on the doc, but functions like
+		*/
                 res->type = XML_HTML_DOCUMENT_NODE;
                 if (((doctypePublic != NULL) || (doctypeSystem != NULL))) {
                     res->intSubset = xmlCreateIntSubset(res, doctype,

Modified: packages/libxslt/trunk/libxslt/variables.c
===================================================================
--- packages/libxslt/trunk/libxslt/variables.c	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/libxslt/variables.c	2006-06-08 22:29:07 UTC (rev 565)
@@ -36,16 +36,21 @@
 #define WITH_XSLT_DEBUG_VARIABLE
 #endif
 
+#ifdef XSLT_REFACTORED
+const xmlChar *xsltDocFragFake = (const xmlChar *) " fake node libxslt";
+#endif
+
 /************************************************************************
  *									*
- *			Result Value Tree interfaces			*
+ *  Result Value Tree (Result Tree Fragment) interfaces			*
  *									*
  ************************************************************************/
 /**
  * xsltCreateRVT:
  * @ctxt:  an XSLT transformation context
  *
- * Create a result value tree
+ * Create a Result Value Tree
+ * (the XSLT 1.0 term for this is "Result Tree Fragment") 
  *
  * Returns the result value tree or NULL in case of error
  */
@@ -54,6 +59,10 @@
 {
     xmlDocPtr container;
 
+    /*
+    * Question: Why is this function public?
+    * Answer: It is called by the EXSLT module.
+    */    
     if (ctxt == NULL) return(NULL);
 
     container = xmlNewDoc(NULL);
@@ -66,7 +75,7 @@
                      "reusing transformation dict for RVT\n");
 #endif
 
-    container->name = (char *) xmlStrdup(BAD_CAST " fake node libxslt");
+    XSLT_MARK_RES_TREE_FRAG(container);
     container->doc = container;
     container->parent = NULL;
     return(container);
@@ -75,9 +84,10 @@
 /**
  * xsltRegisterTmpRVT:
  * @ctxt:  an XSLT transformation context
- * @RVT:  a result value tree
+ * @RVT:  a result value tree (Result Tree Fragment)
  *
- * Register the result value tree for destruction at the end of the context
+ * Register the result value tree (XSLT 1.0 term: Result Tree Fragment)
+ * for destruction at the end of the context
  *
  * Returns 0 in case of success and -1 in case of error.
  */
@@ -96,9 +106,10 @@
 /**
  * xsltRegisterPersistRVT:
  * @ctxt:  an XSLT transformation context
- * @RVT:  a result value tree
+ * @RVT:  a result value tree (Result Tree Fragment)
  *
- * Register the result value tree for destruction at the end of the processing
+ * Register the result value tree (XSLT 1.0 term: Result Tree Fragment)
+ * for destruction at the end of the processing
  *
  * Returns 0 in case of success and -1 in case of error.
  */
@@ -118,7 +129,8 @@
  * xsltFreeRVTs:
  * @ctxt:  an XSLT transformation context
  *
- * Free all the registered result value tree of the transformation
+ * Free all the registered result value tree (Result Tree Fragment)
+ * of the transformation
  */
 void
 xsltFreeRVTs(xsltTransformContextPtr ctxt)
@@ -467,9 +479,9 @@
 	if (precomp != NULL) {
 	    ctxt->inst = precomp->inst;
 #ifdef XSLT_REFACTORED
-	    if (precomp->inScopeNS != NULL) {
-		ctxt->xpathCtxt->namespaces = precomp->inScopeNS->list;
-		ctxt->xpathCtxt->nsNr = precomp->inScopeNS->number;
+	    if (precomp->inScopeNs != NULL) {
+		ctxt->xpathCtxt->namespaces = precomp->inScopeNs->list;
+		ctxt->xpathCtxt->nsNr = precomp->inScopeNs->number;
 	    } else {
 		ctxt->xpathCtxt->namespaces = NULL;
 		ctxt->xpathCtxt->nsNr = 0;
@@ -606,6 +618,14 @@
 #else
     precomp = elem->comp;
 #endif
+
+    /*
+    * OPTIMIZE TODO: We should consider if instantiating global vars/params
+    *  on a on-demand basis would be better. The vars/params don't
+    *  need to be evaluated if never called; and in the case of
+    *  global params, if values for such params are provided by the
+    *  user.
+    */
     if (elem->select != NULL) {
 	xmlXPathCompExprPtr comp = NULL;
 
@@ -628,9 +648,9 @@
 	if (precomp != NULL) {
 	    ctxt->inst = precomp->inst;
 #ifdef XSLT_REFACTORED
-	    if (precomp->inScopeNS != NULL) {
-		ctxt->xpathCtxt->namespaces = precomp->inScopeNS->list;
-		ctxt->xpathCtxt->nsNr = precomp->inScopeNS->number;
+	    if (precomp->inScopeNs != NULL) {
+		ctxt->xpathCtxt->namespaces = precomp->inScopeNs->list;
+		ctxt->xpathCtxt->nsNr = precomp->inScopeNs->number;
 	    } else {
 		ctxt->xpathCtxt->namespaces = NULL;
 		ctxt->xpathCtxt->nsNr = 0;
@@ -1389,10 +1409,12 @@
 /**
  * xsltParseStylesheetCallerParam:
  * @ctxt:  the XSLT transformation context
- * @cur:  the "param" element
+ * @cur:  the "xsl:with-param" element
  *
  * parse an XSLT transformation param declaration, compute
  * its value but doesn't record it.
+ * NOTE that this is also called with an *xsl:param* element
+ * from exsltFuncFunctionFunction(). 
  *
  * Returns the new xsltStackElemPtr or NULL
  */
@@ -1417,19 +1439,19 @@
 #endif     
     if (comp == NULL) {
 	xsltTransformError(ctxt, NULL, cur,
-	    "xsl:param : compilation error\n");
+	    "xsl:with-param : compilation error\n");
 	return(NULL);
     }
 
     if (comp->name == NULL) {
 	xsltTransformError(ctxt, NULL, cur,
-	    "xsl:param : missing name attribute\n");
+	    "xsl:with-param : missing name attribute\n");
 	return(NULL);
     }
 
 #ifdef WITH_XSLT_DEBUG_VARIABLE
     XSLT_TRACE(ctxt,XSLT_TRACE_VARIABLES,xsltGenericDebug(xsltGenericDebugContext,
-	    "Handling param %s\n", comp->name));
+	    "Handling xsl:with-param %s\n", comp->name));
 #endif
 
     if (comp->select == NULL) {
@@ -1467,11 +1489,15 @@
 
     if ((cur == NULL) || (style == NULL))
 	return;
-
-    xsltStylePreCompute(style, cur);
+    
 #ifdef XSLT_REFACTORED
+    /*
+    * Note that xsltStylePreCompute() will be called from
+    * xslt.c only.
+    */
     comp = (xsltStyleItemVariablePtr) cur->psvi;
 #else
+    xsltStylePreCompute(style, cur);
     comp = (xsltStylePreCompPtr) cur->psvi;
 #endif
     if (comp == NULL) {
@@ -1486,8 +1512,15 @@
 	return;
     }
 
+    /*
+    * Parse the content (a sequence constructor) of xsl:variable.
+    */
     if (cur->children != NULL) {
+#ifdef XSLT_REFACTORED	
+        xsltParseSequenceConstructor(XSLT_CCTXT(style), cur->children);
+#else
         xsltParseTemplateContent(style, cur);
+#endif
     }
 #ifdef WITH_XSLT_DEBUG_VARIABLE
     xsltGenericDebug(xsltGenericDebugContext,
@@ -1518,11 +1551,15 @@
 
     if ((cur == NULL) || (style == NULL))
 	return;
-
-    xsltStylePreCompute(style, cur);
+    
 #ifdef XSLT_REFACTORED
+    /*
+    * Note that xsltStylePreCompute() will be called from
+    * xslt.c only.
+    */
     comp = (xsltStyleItemParamPtr) cur->psvi;
 #else
+    xsltStylePreCompute(style, cur);
     comp = (xsltStylePreCompPtr) cur->psvi;
 #endif    
     if (comp == NULL) {
@@ -1537,8 +1574,15 @@
 	return;
     }
 
+    /*
+    * Parse the content (a sequence constructor) of xsl:param.
+    */
     if (cur->children != NULL) {
+#ifdef XSLT_REFACTORED	
+        xsltParseSequenceConstructor(XSLT_CCTXT(style), cur->children);
+#else
         xsltParseTemplateContent(style, cur);
+#endif
     }
 
 #ifdef WITH_XSLT_DEBUG_VARIABLE

Modified: packages/libxslt/trunk/libxslt/xslt.c
===================================================================
--- packages/libxslt/trunk/libxslt/xslt.c	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/libxslt/xslt.c	2006-06-08 22:29:07 UTC (rev 565)
@@ -27,6 +27,7 @@
 #include <libxml/xmlerror.h>
 #include <libxml/parserInternals.h>
 #include <libxml/xpathInternals.h>
+#include <libxml/xpath.h>
 #include "xslt.h"
 #include "xsltInternals.h"
 #include "pattern.h"
@@ -51,7 +52,32 @@
 const int xsltLibxsltVersion = LIBXSLT_VERSION;
 const int xsltLibxmlVersion = LIBXML_VERSION;
 
+#ifdef XSLT_REFACTORED
+
+const xmlChar *xsltConstNamespaceNameXSLT= (const xmlChar *) XSLT_NAMESPACE;
+
 /*
+* xsltLiteralResultMarker:
+* Marker for Literal result elements, in order to avoid multiple attempts
+* to recognize such elements in the stylesheet's tree.
+* This marker is set on node->psvi during the initial traversal
+* of a stylesheet's node tree.
+*
+const xmlChar *xsltLiteralResultMarker =
+    (const xmlChar *) "Literal Result Element";
+*/
+
+/*
+* xsltXSLTTextMarker:
+* Marker for xsl:text elements. Used to recognize xsl:text elements
+* for post-processing of the stylesheet's tree, where those
+* elements are removed from the tree.
+*/
+const xmlChar *xsltXSLTTextMarker = (const xmlChar *) "XSLT Text Element";
+
+#endif
+
+/*
  * Harmless but avoiding a problem when compiling against a
  * libxml <= 2.3.11 without LIBXML_DEBUG_ENABLED
  */
@@ -75,11 +101,39 @@
     (((n)->type == XML_TEXT_NODE) && (xsltIsBlank((n)->content)))
 
 /**
+ * xsltParseContentError:
+ *
+ * @style: the stylesheet
+ * @node: the node where the error occured
+ *
+ * Compile-time error function.
+ */
+static void
+xsltParseContentError(xsltStylesheetPtr style,
+		       xmlNodePtr node)
+{
+    if ((style == NULL) || (node == NULL))
+	return;
+
+    if (IS_XSLT_ELEM(node))
+	xsltTransformError(NULL, style, node,
+	    "The XSLT-element '%s' is not allowed at this position.\n",
+	    node->name);
+    else
+	xsltTransformError(NULL, style, node,
+	    "The element '%s' is not allowed at this position.\n",
+	    node->name);
+    style->errors++;
+}
+
+#ifdef XSLT_REFACTORED
+#else
+/**
  * exclPrefixPush:
  * @style: the transformation stylesheet
- * @value:  the excluded prefix to push on the stack
+ * @value:  the excluded namespace name to push on the stack
  *
- * Push an excluded prefix on the stack
+ * Push an excluded namespace name on the stack
  *
  * Returns the new index in the stack or 0 in case of error
  */
@@ -135,6 +189,7 @@
     style->exclPrefixTab[style->exclPrefixNr] = 0;
     return (ret);
 }
+#endif
 
 /************************************************************************
  *									*
@@ -270,7 +325,7 @@
 
 /**
  * xsltDecimalFormatGetByName:
- * @sheet: the XSLT stylesheet
+ * @style: the XSLT stylesheet
  * @name: the decimal-format name to find
  *
  * Find decimal-format by name
@@ -278,21 +333,21 @@
  * Returns the xsltDecimalFormatPtr
  */
 xsltDecimalFormatPtr
-xsltDecimalFormatGetByName(xsltStylesheetPtr sheet, xmlChar *name)
+xsltDecimalFormatGetByName(xsltStylesheetPtr style, xmlChar *name)
 {
     xsltDecimalFormatPtr result = NULL;
 
     if (name == NULL)
-	return sheet->decimalFormat;
+	return style->decimalFormat;
 
-    while (sheet != NULL) {
-	for (result = sheet->decimalFormat->next;
+    while (style != NULL) {
+	for (result = style->decimalFormat->next;
 	     result != NULL;
 	     result = result->next) {
 	    if (xmlStrEqual(name, result->name))
 		return result;
 	}
-	sheet = xsltNextImport(sheet);
+	style = xsltNextImport(style);
     }
     return result;
 }
@@ -331,9 +386,12 @@
     if (template == NULL)
 	return;
     if (template->match) xmlFree(template->match);
-    if (template->name) xmlFree(template->name);
-    if (template->nameURI) xmlFree(template->nameURI);
 /*
+*   NOTE: @name and @nameURI are put into the string dict now.
+*   if (template->name) xmlFree(template->name);
+*   if (template->nameURI) xmlFree(template->nameURI);
+*/
+/*
     if (template->mode) xmlFree(template->mode);
     if (template->modeURI) xmlFree(template->modeURI);
  */
@@ -359,69 +417,310 @@
     }
 }
 
+#ifdef XSLT_REFACTORED
+
+static void
+xsltFreeNsAliasList(xsltNsAliasPtr item)
+{
+    xsltNsAliasPtr tmp;
+    
+    while (item) {
+	tmp = item;
+	item = item->next;
+	xmlFree(tmp);
+    } 
+    return;
+}
+
+#ifdef XSLT_REFACTORED_XSLT_NSCOMP
+static void
+xsltFreeNamespaceMap(xsltNsMapPtr item)
+{
+    xsltNsMapPtr tmp;
+    
+    while (item) {
+	tmp = item;
+	item = item->next;
+	xmlFree(tmp);
+    } 
+    return;
+}
+
+static xsltNsMapPtr
+xsltNewNamespaceMapItem(xsltCompilerCtxtPtr cctxt,
+			xmlDocPtr doc,
+			xmlNsPtr ns,
+			xmlNodePtr elem)
+{
+    xsltNsMapPtr ret;
+
+    if ((cctxt == NULL) || (doc == NULL) || (ns == NULL))
+	return(NULL);
+
+    ret = (xsltNsMapPtr) xmlMalloc(sizeof(xsltNsMap));
+    if (ret == NULL) {
+	xsltTransformError(NULL, cctxt->style, elem,
+	    "Internal error: (xsltNewNamespaceMapItem) "
+	    "memory allocation failed.\n");
+	return(NULL);
+    }
+    memset(ret, 0, sizeof(xsltNsMap));
+    ret->doc = doc;
+    ret->ns = ns;
+    ret->origNsName = ns->href;
+    /*
+    * Store the item at current stylesheet-level.
+    */
+    if (cctxt->psData->nsMap != NULL)
+	ret->next = cctxt->psData->nsMap;
+    cctxt->psData->nsMap = ret;
+
+    return(ret);
+}
+#endif /* XSLT_REFACTORED_XSLT_NSCOMP */
+
 /**
- * xsltNewStylesheet:
+ * xsltCompilerCtxtFree:
  *
- * Create a new XSLT Stylesheet
- *
- * Returns the newly allocated xsltStylesheetPtr or NULL in case of error
+ * Free an XSLT compiler context. 
  */
-xsltStylesheetPtr
-xsltNewStylesheet(void) {
-    xsltStylesheetPtr cur;
-#ifdef XSLT_REFACTORED
-    xsltCompilerCtxtPtr cctxt;
+static void
+xsltCompilationCtxtFree(xsltCompilerCtxtPtr cctxt)
+{    
+    if (cctxt == NULL)
+	return;
+#ifdef WITH_XSLT_DEBUG_PARSING
+    xsltGenericDebug(xsltGenericDebugContext,
+	"Freeing compilation context\n");
+    xsltGenericDebug(xsltGenericDebugContext,
+	"### Max inodes: %d\n", cctxt->maxNodeInfos);
+    xsltGenericDebug(xsltGenericDebugContext,
+	"### Max LREs  : %d\n", cctxt->maxLREs);
 #endif
+    /*
+    * Free node-infos.
+    */
+    if (cctxt->inodeList != NULL) {
+	xsltCompilerNodeInfoPtr tmp, cur = cctxt->inodeList;
+	while (cur != NULL) {
+	    tmp = cur;
+	    cur = cur->next;
+	    xmlFree(tmp);
+	}
+    }
+    if (cctxt->tmpList != NULL)
+	xsltPointerListFree(cctxt->tmpList);
+#ifdef XSLT_REFACTORED_XPATHCOMP
+    if (cctxt->xpathCtxt != NULL)
+	xmlXPathFreeContext(cctxt->xpathCtxt);
+#endif
+    if (cctxt->nsAliases != NULL)
+	xsltFreeNsAliasList(cctxt->nsAliases);
 
-    cur = (xsltStylesheetPtr) xmlMalloc(sizeof(xsltStylesheet));
-    if (cur == NULL) {
-	xsltTransformError(NULL, NULL, NULL,
-		"xsltNewStylesheet : malloc failed\n");
+    xmlFree(cctxt);
+}
+
+/**
+ * xsltCompilerCreate:
+ *
+ * Creates an XSLT compiler context.
+ *
+ * Returns the pointer to the created xsltCompilerCtxt or
+ *         NULL in case of an internal error.
+ */
+static xsltCompilerCtxtPtr
+xsltCompilationCtxtCreate(xsltStylesheetPtr style) {
+    xsltCompilerCtxtPtr ret;
+
+    ret = (xsltCompilerCtxtPtr) xmlMalloc(sizeof(xsltCompilerCtxt));
+    if (ret == NULL) {
+	xsltTransformError(NULL, style, NULL,
+	    "xsltCompilerCreate: allocation of compiler "
+	    "context failed.\n");
 	return(NULL);
     }
-    memset(cur, 0, sizeof(xsltStylesheet));
-#ifdef XSLT_REFACTORED
+    memset(ret, 0, sizeof(xsltCompilerCtxt));
+
+    ret->errSeverity = XSLT_ERROR_SEVERITY_ERROR;
+    ret->tmpList = xsltPointerListCreate(20);
+    if (ret->tmpList == NULL) {
+	goto internal_err;
+    }
+#ifdef XSLT_REFACTORED_XPATHCOMP
     /*
-    * Create the compiler context.
+    * Create the XPath compilation context in order
+    * to speed up precompilation of XPath expressions.
     */
-    cctxt = (xsltCompilerCtxtPtr) xmlMalloc(sizeof(xsltCompilerCtxt));
-    if (cctxt == NULL) {
-	xmlFree(cur);
+    ret->xpathCtxt = xmlXPathNewContext(NULL);
+    if (ret->xpathCtxt == NULL)
+	goto internal_err;
+#endif
+    
+    return(ret);
+
+internal_err:
+    xsltCompilationCtxtFree(ret);
+    return(NULL);
+}
+
+static void
+xsltLREEffectiveNsNodesFree(xsltEffectiveNsPtr first)
+{
+    xsltEffectiveNsPtr tmp;
+
+    while (first != NULL) {
+	tmp = first;
+	first = first->nextInStore;
+	xmlFree(tmp);
+    }
+}
+
+static void
+xsltFreePrincipalStylesheetData(xsltPrincipalStylesheetDataPtr data)
+{
+    if (data == NULL)
+	return;
+
+    if (data->inScopeNamespaces != NULL) {
+	int i;
+	xsltNsListContainerPtr nsi;
+	xsltPointerListPtr list =
+	    (xsltPointerListPtr) data->inScopeNamespaces;
+
+	for (i = 0; i < list->number; i++) {
+	    /*
+	    * REVISIT TODO: Free info of in-scope namespaces.
+	    */
+	    nsi = (xsltNsListContainerPtr) list->items[i];
+	    if (nsi->list != NULL)
+		xmlFree(nsi->list);
+	    xmlFree(nsi);
+	}
+	xsltPointerListFree(list);
+	data->inScopeNamespaces = NULL;
+    }
+
+    if (data->exclResultNamespaces != NULL) {
+	int i;
+	xsltPointerListPtr list = (xsltPointerListPtr)
+	    data->exclResultNamespaces;	
+	
+	for (i = 0; i < list->number; i++)
+	    xsltPointerListFree((xsltPointerListPtr) list->items[i]);
+	
+	xsltPointerListFree(list);
+	data->exclResultNamespaces = NULL;
+    }
+
+    if (data->extElemNamespaces != NULL) {
+	xsltPointerListPtr list = (xsltPointerListPtr)
+	    data->extElemNamespaces;
+	int i;
+
+	for (i = 0; i < list->number; i++)
+	    xsltPointerListFree((xsltPointerListPtr) list->items[i]);
+
+	xsltPointerListFree(list);
+	data->extElemNamespaces = NULL;
+    }
+    if (data->effectiveNs) {
+	xsltLREEffectiveNsNodesFree(data->effectiveNs);
+	data->effectiveNs = NULL;
+    }
+#ifdef XSLT_REFACTORED_XSLT_NSCOMP
+    xsltFreeNamespaceMap(data->nsMap);
+#endif
+    xmlFree(data);
+}
+
+static xsltPrincipalStylesheetDataPtr
+xsltNewPrincipalStylesheetData(void)
+{
+    xsltPrincipalStylesheetDataPtr ret;
+
+    ret = (xsltPrincipalStylesheetDataPtr)
+	xmlMalloc(sizeof(xsltPrincipalStylesheetData));
+    if (ret == NULL) {
 	xsltTransformError(NULL, NULL, NULL,
-		"xsltNewStylesheet : malloc of compilation context failed\n");
+	    "xsltNewPrincipalStylesheetData: memory allocation failed.\n");
 	return(NULL);
     }
-    memset(cctxt, 0, sizeof(xsltCompilerCtxt));
-    cur->compCtxt = (void *) cctxt;
-    cctxt->sheet = cur;
-#endif
+    memset(ret, 0, sizeof(xsltPrincipalStylesheetData));
+    
     /*
-    * TODO: This here seems to be the best place where to create
-    *   the compilation context, right?
+    * Global list of in-scope namespaces.
+    */    
+    ret->inScopeNamespaces = xsltPointerListCreate(-1);
+    if (ret->inScopeNamespaces == NULL)
+	goto internal_err;
+    /*
+    * Global list of excluded result ns-decls.
     */
-    	    
-    cur->omitXmlDeclaration = -1;
-    cur->standalone = -1;
-    cur->decimalFormat = xsltNewDecimalFormat(NULL);
-    cur->indent = -1;
-    cur->errors = 0;
-    cur->warnings = 0;
-    cur->exclPrefixNr = 0;
-    cur->exclPrefixMax = 0;
-    cur->exclPrefixTab = NULL;
-    cur->extInfos = NULL;
-    cur->extrasNr = 0;
-    cur->internalized = 1;
-    cur->literal_result = 0;
-    cur->dict = xmlDictCreate();
+    ret->exclResultNamespaces = xsltPointerListCreate(-1);
+    if (ret->exclResultNamespaces == NULL)
+	goto internal_err;
+    /*
+    * Global list of extension instruction namespace names.
+    */    
+    ret->extElemNamespaces = xsltPointerListCreate(-1);
+    if (ret->extElemNamespaces == NULL)
+	goto internal_err;
+
+    return(ret);
+
+internal_err:
+
+    return(NULL);
+}
+
+#endif
+
+/**
+ * xsltNewStylesheet:
+ *
+ * Create a new XSLT Stylesheet
+ *
+ * Returns the newly allocated xsltStylesheetPtr or NULL in case of error
+ */
+xsltStylesheetPtr
+xsltNewStylesheet(void) {
+    xsltStylesheetPtr ret = NULL;    
+
+    ret = (xsltStylesheetPtr) xmlMalloc(sizeof(xsltStylesheet));
+    if (ret == NULL) {
+	xsltTransformError(NULL, NULL, NULL,
+		"xsltNewStylesheet : malloc failed\n");
+	goto internal_err;
+    }
+    memset(ret, 0, sizeof(xsltStylesheet));
+
+    ret->omitXmlDeclaration = -1;
+    ret->standalone = -1;
+    ret->decimalFormat = xsltNewDecimalFormat(NULL);
+    ret->indent = -1;
+    ret->errors = 0;
+    ret->warnings = 0;
+    ret->exclPrefixNr = 0;
+    ret->exclPrefixMax = 0;
+    ret->exclPrefixTab = NULL;
+    ret->extInfos = NULL;
+    ret->extrasNr = 0;
+    ret->internalized = 1;
+    ret->literal_result = 0;
+    ret->dict = xmlDictCreate();
 #ifdef WITH_XSLT_DEBUG
     xsltGenericDebug(xsltGenericDebugContext,
-                     "creating dictionary for stylesheet\n");
+	"creating dictionary for stylesheet\n");
 #endif
 
     xsltInit();
 
-    return(cur);
+    return(ret);
+
+internal_err:
+    if (ret != NULL)
+	xsltFreeStylesheet(ret);
+    return(NULL);
 }
 
 /**
@@ -495,149 +794,194 @@
 
 /**
  * xsltFreeStylesheetList:
- * @sheet:  an XSLT stylesheet list
+ * @style:  an XSLT stylesheet list
  *
- * Free up the memory allocated by the list @sheet
+ * Free up the memory allocated by the list @style
  */
 static void
-xsltFreeStylesheetList(xsltStylesheetPtr sheet) {
+xsltFreeStylesheetList(xsltStylesheetPtr style) {
     xsltStylesheetPtr next;
 
-    while (sheet != NULL) {
-	next = sheet->next;
-	xsltFreeStylesheet(sheet);
-	sheet = next;
+    while (style != NULL) {
+	next = style->next;
+	xsltFreeStylesheet(style);
+	style = next;
     }
 }
 
-#ifdef XSLT_REFACTORED
 /**
- * xsltFreeInScopeNamespaces:
- * @sheet:  an XSLT stylesheet
+ * xsltCleanupStylesheetTree:
  *
- * Frees the list of in-scope namespace lists.
+ * @doc: the document-node
+ * @node: the element where the stylesheet is rooted at
+ *
+ * Actually @node need not be the document-element, but
+ * currently Libxslt does not support embedeed stylesheets.
+ *
+ * Returns 0 if OK, -1 on API or internal errors.
  */
-static void
-xsltFreeInScopeNamespaces(xsltStylesheetPtr sheet)
-{
-    if (sheet->inScopeNamespaces == NULL)
-	return;
-    else {
-	int i;
-	xsltNsListPtr nsi;
-	xsltPointerListPtr list = sheet->inScopeNamespaces;
+static int
+xsltCleanupStylesheetTree(xmlDocPtr doc, xmlNodePtr rootElem)
+{    
+#if 0 /* TODO: Currently disabled, since probably not needed. */
+    xmlNodePtr cur;
 
-	for (i = 0; i < list->number; i++) {
+    if ((doc == NULL) || (rootElem == NULL) ||
+	(rootElem->type != XML_ELEMENT_NODE) ||
+	(doc != rootElem->doc))
+	return(-1);
+
+    /*
+    * Cleanup was suggested by Aleksey Sanin:
+    * Clear the PSVI field to avoid problems if the
+    * node-tree of the stylesheet is intended to be used for
+    * further processing by the user (e.g. for compiling it
+    * once again - although not recommended).
+    */
+
+    cur = rootElem;
+    while (cur != NULL) {
+	if (cur->type == XML_ELEMENT_NODE) {
 	    /*
-	    * REVISIT TODO: Free info of in-scope namespaces.
+	    * Clear the PSVI field.
 	    */
-	    nsi = (xsltNsListPtr) list->items[i];
-	    if (nsi->list != NULL)
-		xmlFree(nsi->list);
-	    xmlFree(nsi);
+	    cur->psvi = NULL;
+	    if (cur->children) {
+		cur = cur->children;
+		continue;
+	    }
 	}
-	xsltPointerListFree(list);
-	sheet->inScopeNamespaces = NULL;
-    }
-    return;
-}
 
-static void
-xsltCompilerCtxtFree(xsltCompilerCtxtPtr cctxt)
-{    
-    if (cctxt == NULL)
-	return;
-    /*
-    * Free node-infos.
-    */
-    if (cctxt->inodeList != NULL) {
-	xsltCompilerNodeInfoPtr tmp, cur = cctxt->inodeList;
-	while (cur != NULL) {
-	    tmp = cur;
+leave_node:
+	if (cur == rootElem)
+	    break;
+	if (cur->next != NULL)
 	    cur = cur->next;
-	    xmlFree(tmp);
+	else {
+	    cur = cur->parent;
+	    if (cur == NULL)
+		break;
+	    goto leave_node;
 	}
     }
-    xmlFree(cctxt);
+#endif /* #if 0 */
+    return(0);
 }
-#endif
 
 /**
  * xsltFreeStylesheet:
- * @sheet:  an XSLT stylesheet
+ * @style:  an XSLT stylesheet
  *
- * Free up the memory allocated by @sheet
+ * Free up the memory allocated by @style
  */
 void
-xsltFreeStylesheet(xsltStylesheetPtr sheet)
+xsltFreeStylesheet(xsltStylesheetPtr style)
 {
-    if (sheet == NULL)
+    if (style == NULL)
         return;
-
-    xsltFreeKeys(sheet);
-    xsltFreeExts(sheet);
-    xsltFreeTemplateHashes(sheet);
-    xsltFreeDecimalFormatList(sheet);
-    xsltFreeTemplateList(sheet->templates);
-    xsltFreeAttributeSetsHashes(sheet);
-    xsltFreeNamespaceAliasHashes(sheet);
+    
 #ifdef XSLT_REFACTORED
-    if (sheet->inScopeNamespaces != NULL)
-	xsltFreeInScopeNamespaces(sheet);
-#endif
-    xsltFreeStyleDocuments(sheet);
-    xsltFreeStylePreComps(sheet);
-    xsltShutdownExts(sheet);
-    if (sheet->doc != NULL)
-        xmlFreeDoc(sheet->doc);
-    if (sheet->variables != NULL)
-        xsltFreeStackElemList(sheet->variables);
-    if (sheet->cdataSection != NULL)
-        xmlHashFree(sheet->cdataSection, NULL);
-    if (sheet->stripSpaces != NULL)
-        xmlHashFree(sheet->stripSpaces, NULL);
-    if (sheet->nsHash != NULL)
-        xmlHashFree(sheet->nsHash, NULL);
+    /*
+    * Start with a cleanup of the main stylesheet's doc.
+    */
+    if ((style->principal == style) && (style->doc))
+	xsltCleanupStylesheetTree(style->doc,
+	    xmlDocGetRootElement(style->doc));
+#ifdef XSLT_REFACTORED_XSLT_NSCOMP
+    /*
+    * Restore changed ns-decls before freeing the document.
+    */
+    if ((style->doc != NULL) &&
+	XSLT_HAS_INTERNAL_NSMAP(style))
+    {
+	xsltRestoreDocumentNamespaces(XSLT_GET_INTERNAL_NSMAP(style),
+	    style->doc);	
+    }
+#endif /* XSLT_REFACTORED_XSLT_NSCOMP */
+#else
+    /*
+    * Start with a cleanup of the main stylesheet's doc.
+    */
+    if ((style->parent == NULL) && (style->doc))
+	xsltCleanupStylesheetTree(style->doc,
+	    xmlDocGetRootElement(style->doc));
+#endif /* XSLT_REFACTORED */
 
-    if (sheet->exclPrefixTab != NULL)
-        xmlFree(sheet->exclPrefixTab);
-    if (sheet->method != NULL)
-        xmlFree(sheet->method);
-    if (sheet->methodURI != NULL)
-        xmlFree(sheet->methodURI);
-    if (sheet->version != NULL)
-        xmlFree(sheet->version);
-    if (sheet->encoding != NULL)
-        xmlFree(sheet->encoding);
-    if (sheet->doctypePublic != NULL)
-        xmlFree(sheet->doctypePublic);
-    if (sheet->doctypeSystem != NULL)
-        xmlFree(sheet->doctypeSystem);
-    if (sheet->mediaType != NULL)
-        xmlFree(sheet->mediaType);
-    if (sheet->attVTs)
-        xsltFreeAVTList(sheet->attVTs);
+    xsltFreeKeys(style);
+    xsltFreeExts(style);
+    xsltFreeTemplateHashes(style);
+    xsltFreeDecimalFormatList(style);
+    xsltFreeTemplateList(style->templates);
+    xsltFreeAttributeSetsHashes(style);
+    xsltFreeNamespaceAliasHashes(style);
+    xsltFreeStylePreComps(style);
+    /*
+    * Free documents of all included stylsheet modules of this
+    * stylesheet level.
+    */
+    xsltFreeStyleDocuments(style);
+    /*
+    * TODO: Best time to shutdown extension stuff?
+    */
+    xsltShutdownExts(style);
+       
+    if (style->variables != NULL)
+        xsltFreeStackElemList(style->variables);
+    if (style->cdataSection != NULL)
+        xmlHashFree(style->cdataSection, NULL);
+    if (style->stripSpaces != NULL)
+        xmlHashFree(style->stripSpaces, NULL);
+    if (style->nsHash != NULL)
+        xmlHashFree(style->nsHash, NULL);
+    if (style->exclPrefixTab != NULL)
+        xmlFree(style->exclPrefixTab);
+    if (style->method != NULL)
+        xmlFree(style->method);
+    if (style->methodURI != NULL)
+        xmlFree(style->methodURI);
+    if (style->version != NULL)
+        xmlFree(style->version);
+    if (style->encoding != NULL)
+        xmlFree(style->encoding);
+    if (style->doctypePublic != NULL)
+        xmlFree(style->doctypePublic);
+    if (style->doctypeSystem != NULL)
+        xmlFree(style->doctypeSystem);
+    if (style->mediaType != NULL)
+        xmlFree(style->mediaType);
+    if (style->attVTs)
+        xsltFreeAVTList(style->attVTs);
+    if (style->imports != NULL)
+        xsltFreeStylesheetList(style->imports);
 
-    if (sheet->imports != NULL)
-        xsltFreeStylesheetList(sheet->imports);
 #ifdef XSLT_REFACTORED
     /*
-    * TODO: Just a paranoid cleanup, in case the compilation
-    *   context was not freed after the compilation.
+    * If this is the principal stylesheet, then
+    * free its internal data.
     */
-    if (sheet->compCtxt != NULL) {
-	xsltCompilerCtxtFree((xsltCompilerCtxtPtr) sheet->compCtxt);
+    if (style->principal == style) {
+	if (style->principalData) {
+	    xsltFreePrincipalStylesheetData(style->principalData);
+	    style->principalData = NULL;
+	}
+    }    
+#endif
+    /*
+    * Better to free the main document of this stylesheet level
+    * at the end - so here.
+    */
+    if (style->doc != NULL) {	
+        xmlFreeDoc(style->doc);
     }
-#endif
 
 #ifdef WITH_XSLT_DEBUG
     xsltGenericDebug(xsltGenericDebugContext,
                      "freeing dictionary from stylesheet\n");
 #endif
-    xmlDictFree(sheet->dict);
+    xmlDictFree(style->dict);
 
-    memset(sheet, -1, sizeof(xsltStylesheet));
-    xmlFree(sheet);
+    memset(style, -1, sizeof(xsltStylesheet));
+    xmlFree(style);
 }
 
 /************************************************************************
@@ -646,6 +990,11 @@
  *									*
  ************************************************************************/
 
+#ifdef XSLT_REFACTORED
+    /*
+    * This is now performed in an optimized way in xsltParseXSLTTemplate.
+    */
+#else
 /**
  * xsltGetInheritedNsList:
  * @style:  the stylesheet
@@ -676,7 +1025,7 @@
     *  	<xsl:stylesheet ...    
     * </doc>
     * Will have foo="urn:test:foo" in the list.
-    * Is this a bug?
+    * Is this OK?
     */
 
     if ((style == NULL) || (template == NULL) || (node == NULL) ||
@@ -688,6 +1037,7 @@
             while (cur != NULL) {
 		if (xmlStrEqual(cur->href, XSLT_NAMESPACE))
 		    goto skip_ns;
+
 		if ((cur->prefix != NULL) &&
 		    (xsltCheckExtPrefix(style, cur->prefix)))
 		    goto skip_ns;
@@ -751,6 +1101,7 @@
     }
     return (nbns);
 }
+#endif /* else of XSLT_REFACTORED */
 
 /**
  * xsltParseStylesheetOutput:
@@ -842,7 +1193,7 @@
         } else {
 	    xsltTransformError(NULL, style, cur,
                              "invalid value for standalone: %s\n", prop);
-            if (style != NULL) style->warnings++;
+            style->errors++;
         }
         xmlFree(prop);
     }
@@ -856,7 +1207,7 @@
         } else {
 	    xsltTransformError(NULL, style, cur,
                              "invalid value for indent: %s\n", prop);
-            if (style != NULL) style->warnings++;
+            style->errors++;
         }
         xmlFree(prop);
     }
@@ -871,7 +1222,7 @@
 	    xsltTransformError(NULL, style, cur,
                              "invalid value for omit-xml-declaration: %s\n",
                              prop);
-            if (style != NULL) style->warnings++;
+            style->errors++;
         }
         xmlFree(prop);
     }
@@ -894,34 +1245,51 @@
             while ((*end != 0) && (!IS_BLANK(*end)))
                 end++;
             element = xmlStrndup(element, end - element);
-            if (element) {
-		const xmlChar *URI;
+            if (element) {		
 #ifdef WITH_XSLT_DEBUG_PARSING
                 xsltGenericDebug(xsltGenericDebugContext,
                                  "add cdata section output element %s\n",
                                  element);
 #endif
+		if (xmlValidateQName(BAD_CAST element, 0) != 0) {
+		    xsltTransformError(NULL, style, cur,
+			"Attribute 'cdata-section-elements': The value "
+			"'%s' is not a valid QName.\n", element);
+		    xmlFree(element);
+		    style->errors++;
+		} else {
+		    const xmlChar *URI;
 
-		URI = xsltGetQNameURI(cur, &element);
-		if (element == NULL) {
-		    if (style != NULL) style->errors++;
-		} else {
-		    xmlNsPtr ns;
-		    
-		    xmlHashAddEntry2(style->cdataSection, element, URI,
-			             (void *) "cdata");
-		    /*
-		     * if prefix is NULL, we must check whether it's
-		     * necessary to also put in the name of the default
-		     * namespace.
-		     */
-		    if (URI == NULL) {
-		        ns = xmlSearchNs(style->doc, cur, NULL);
-			if (ns != NULL)  
-			    xmlHashAddEntry2(style->cdataSection, element,
-			        ns->href, (void *) "cdata");
+		    URI = xsltGetQNameURI(cur, &element);
+		    if (element == NULL) {
+			/*
+			* TODO: We'll report additionally an error
+			*  via the stylesheet's error handling.			
+			*/
+			xsltTransformError(NULL, style, cur,
+			    "Attribute 'cdata-section-elements': The value "
+			    "'%s' is not a valid QName.\n", element);
+			style->errors++;
+		    } else {
+			xmlNsPtr ns;
+			
+			/*
+			* XSLT-1.0 "Each QName is expanded into an
+			*  expanded-name using the namespace declarations in
+			*  effect on the xsl:output element in which the QName
+			*  occurs; if there is a default namespace, it is used
+			*  for QNames that do not have a prefix"
+			* NOTE: Fix of bug #339570.
+			*/
+			if (URI == NULL) {
+			    ns = xmlSearchNs(style->doc, cur, NULL);
+			    if (ns != NULL)
+				URI = ns->href;
+			}		   
+			xmlHashAddEntry2(style->cdataSection, element, URI,
+			    (void *) "cdata");
+			xmlFree(element);
 		    }
-		    xmlFree(element);
 		}
             }
             element = end;
@@ -935,6 +1303,9 @@
 	    xmlFree(style->mediaType);
 	style->mediaType = prop;
     }
+    if (cur->children != NULL) {
+	xsltParseContentError(style, cur->children);
+    }
 }
 
 /**
@@ -1046,6 +1417,9 @@
 	if (format->patternSeparator != NULL) xmlFree(format->patternSeparator);
 	format->patternSeparator  = prop;
     }
+    if (cur->children != NULL) {
+	xsltParseContentError(style, cur->children);
+    }
 }
 
 /**
@@ -1106,23 +1480,27 @@
 	element = end;
     }
     xmlFree(elements);
+    if (cur->children != NULL) {
+	xsltParseContentError(style, cur->children);
+    }
 }
 
+#ifdef XSLT_REFACTORED
+#else
 /**
  * xsltParseStylesheetExtPrefix:
  * @style:  the XSLT stylesheet
  * @template:  the "extension-element-prefixes" prefix
  *
  * parse an XSLT stylesheet's "extension-element-prefix" attribute value
- * and register the namespaces of extension elements.
+ * and register the namespaces of extension instruction.
  * SPEC "A namespace is designated as an extension namespace by using
  *   an extension-element-prefixes attribute on:
  *   1) an xsl:stylesheet element
- *   2) TODO: an xsl:extension-element-prefixes attribute on a
+ *   2) an xsl:extension-element-prefixes attribute on a
  *      literal result element 
- *   3) TODO: an extension element."
+ *   3) an extension instruction."
  */
-
 static void
 xsltParseStylesheetExtPrefix(xsltStylesheetPtr style, xmlNodePtr cur,
 			     int isXsltElem) {
@@ -1137,7 +1515,7 @@
 	prefixes = xmlGetNsProp(cur,
 	    (const xmlChar *)"extension-element-prefixes", NULL);
     } else {
-	/* For literal result elements and extension elements. */
+	/* For literal result elements and extension instructions. */
 	prefixes = xmlGetNsProp(cur,
 	    (const xmlChar *)"extension-element-prefixes", XSLT_NAMESPACE);
     }
@@ -1178,6 +1556,7 @@
     }
     xmlFree(prefixes);
 }
+#endif /* else of XSLT_REFACTORED */
 
 /**
  * xsltParseStylesheetStripSpace:
@@ -1237,8 +1616,13 @@
 	element = end;
     }
     xmlFree(elements);
+    if (cur->children != NULL) {
+	xsltParseContentError(style, cur->children);
+    }
 }
 
+#ifdef XSLT_REFACTORED
+#else
 /**
  * xsltParseStylesheetExcludePrefix:
  * @style:  the XSLT stylesheet
@@ -1307,55 +1691,584 @@
     xmlFree(prefixes);
     return(nb);
 }
+#endif /* else of XSLT_REFACTORED */
 
 #ifdef XSLT_REFACTORED
 
-static xsltCompilerNodeInfoPtr
+/*
+* xsltTreeEnsureXMLDecl:
+* @doc: the doc
+* 
+* BIG NOTE:
+*  This was copy&pasted from Libxml2's xmlTreeEnsureXMLDecl() in "tree.c".
+* Ensures that there is an XML namespace declaration on the doc.
+* 
+* Returns the XML ns-struct or NULL on API and internal errors.
+*/
+static xmlNsPtr
+xsltTreeEnsureXMLDecl(xmlDocPtr doc)
+{
+    if (doc == NULL)
+	return (NULL);
+    if (doc->oldNs != NULL)
+	return (doc->oldNs);
+    {
+	xmlNsPtr ns;
+	ns = (xmlNsPtr) xmlMalloc(sizeof(xmlNs));
+	if (ns == NULL) {
+	    xmlGenericError(xmlGenericErrorContext,
+		"xsltTreeEnsureXMLDecl: Failed to allocate "
+		"the XML namespace.\n");	
+	    return (NULL);
+	}
+	memset(ns, 0, sizeof(xmlNs));
+	ns->type = XML_LOCAL_NAMESPACE;
+	/*
+	* URGENT TODO: revisit this.
+	*/
+#ifdef LIBXML_NAMESPACE_DICT
+	if (doc->dict)
+	    ns->href = xmlDictLookup(doc->dict, XML_XML_NAMESPACE, -1);
+	else
+	    ns->href = xmlStrdup(XML_XML_NAMESPACE);
+#else
+	ns->href = xmlStrdup(XML_XML_NAMESPACE); 
+#endif
+	ns->prefix = xmlStrdup((const xmlChar *)"xml");
+	doc->oldNs = ns;
+	return (ns);
+    }
+}
+
+/*
+* xsltTreeAcquireStoredNs:
+* @doc: the doc
+* @nsName: the namespace name
+* @prefix: the prefix
+* 
+* BIG NOTE:
+*  This was copy&pasted from Libxml2's xmlDOMWrapStoreNs() in "tree.c".
+* Creates or reuses an xmlNs struct on doc->oldNs with
+* the given prefix and namespace name.
+* 
+* Returns the aquired ns struct or NULL in case of an API
+*         or internal error.
+*/
+static xmlNsPtr
+xsltTreeAcquireStoredNs(xmlDocPtr doc,
+			const xmlChar *nsName,
+			const xmlChar *prefix)
+{
+    xmlNsPtr ns;
+
+    if (doc == NULL)
+	return (NULL);
+    if (doc->oldNs != NULL)
+	ns = doc->oldNs;
+    else
+	ns = xsltTreeEnsureXMLDecl(doc);
+    if (ns == NULL)
+	return (NULL);
+    if (ns->next != NULL) {
+	/* Reuse. */
+	ns = ns->next;
+	while (ns != NULL) {
+	    if ((ns->prefix == NULL) != (prefix == NULL)) {
+		/* NOP */
+	    } else if (prefix == NULL) {
+		if (xmlStrEqual(ns->href, nsName))
+		    return (ns);
+	    } else {
+		if ((ns->prefix[0] == prefix[0]) &&
+		     xmlStrEqual(ns->prefix, prefix) &&
+		     xmlStrEqual(ns->href, nsName))
+		    return (ns);
+		
+	    }
+	    if (ns->next == NULL)
+		break;
+	    ns = ns->next;
+	}
+    }
+    /* Create. */
+    ns->next = xmlNewNs(NULL, nsName, prefix);
+    return (ns->next);
+}
+
+/**
+ * xsltLREBuildEffectiveNs:
+ *
+ * Apply ns-aliasing on the namespace of the given @elem and
+ * its attributes.
+ */
+static int
+xsltLREBuildEffectiveNs(xsltCompilerCtxtPtr cctxt,
+			xmlNodePtr elem)
+{
+    xmlNsPtr ns;
+    xsltNsAliasPtr alias;
+
+    if ((cctxt == NULL) || (elem == NULL))
+	return(-1);
+    if ((cctxt->nsAliases == NULL) || (! cctxt->hasNsAliases))
+	return(0);
+
+    alias = cctxt->nsAliases;    		
+    while (alias != NULL) {
+	if ( /* If both namespaces are NULL... */
+	    ( (elem->ns == NULL) &&
+	    ((alias->literalNs == NULL) ||
+	    (alias->literalNs->href == NULL)) ) ||
+	    /* ... or both namespace are equal */
+	    ( (elem->ns != NULL) &&
+	    (alias->literalNs != NULL) &&
+	    xmlStrEqual(elem->ns->href, alias->literalNs->href) ) )
+	{
+	    if ((alias->targetNs != NULL) &&
+		(alias->targetNs->href != NULL))
+	    {
+		/*
+		* Convert namespace.
+		*/
+		if (elem->doc == alias->docOfTargetNs) {
+		    /*
+		    * This is the nice case: same docs.
+		    * This will eventually assign a ns-decl which
+		    * is shadowed, but this has no negative effect on
+		    * the generation of the result tree.
+		    */
+		    elem->ns = alias->targetNs;
+		} else {
+		    /*
+		    * This target xmlNs originates from a different
+		    * stylesheet tree. Try to locate it in the
+		    * in-scope namespaces.
+		    * OPTIMIZE TODO: Use the compiler-node-info inScopeNs.
+		    */
+		    ns = xmlSearchNs(elem->doc, elem,
+			alias->targetNs->prefix);		    
+		    /*
+		    * If no matching ns-decl found, then assign a
+		    * ns-decl stored in xmlDoc.
+		    */
+		    if ((ns == NULL) ||
+			(! xmlStrEqual(ns->href, alias->targetNs->href)))
+		    {
+			/*
+			* BIG NOTE: The use of xsltTreeAcquireStoredNs()
+			*  is not very efficient, but currently I don't
+			*  see an other way of *safely* changing a node's
+			*  namespace, since the xmlNs struct in
+			*  alias->targetNs might come from an other
+			*  stylesheet tree. So we need to anchor it in the
+			*  current document, without adding it to the tree,
+			*  which would otherwise change the in-scope-ns
+			*  semantic of the tree.
+			*/
+			ns = xsltTreeAcquireStoredNs(elem->doc,
+			    alias->targetNs->href,
+			    alias->targetNs->prefix);
+			
+			if (ns == NULL) {
+			    xsltTransformError(NULL, cctxt->style, elem,
+				"Internal error in "
+				"xsltLREBuildEffectiveNs(): "
+				"failed to acquire a stored "
+				"ns-declaration.\n");
+			    cctxt->style->errors++;
+			    return(-1);
+			    
+			}
+		    }
+		    elem->ns = ns;
+		}		   
+	    } else {
+		/*
+		* Move into or leave in the NULL namespace.
+		*/
+		elem->ns = NULL;
+	    }
+	    break;
+	}
+	alias = alias->next;
+    }
+    /*
+    * Same with attributes of literal result elements.
+    */
+    if (elem->properties != NULL) {
+	xmlAttrPtr attr = elem->properties;
+	
+	while (attr != NULL) {
+	    if (attr->ns == NULL) {
+		attr = attr->next;
+		continue;
+	    }
+	    alias = cctxt->nsAliases;
+	    while (alias != NULL) {
+		if ( /* If both namespaces are NULL... */
+		    ( (elem->ns == NULL) &&
+		    ((alias->literalNs == NULL) ||
+		    (alias->literalNs->href == NULL)) ) ||
+		    /* ... or both namespace are equal */
+		    ( (elem->ns != NULL) &&
+		    (alias->literalNs != NULL) &&
+		    xmlStrEqual(elem->ns->href, alias->literalNs->href) ) )
+		{
+		    if ((alias->targetNs != NULL) &&
+			(alias->targetNs->href != NULL))
+		    {		    
+			if (elem->doc == alias->docOfTargetNs) {
+			    elem->ns = alias->targetNs;
+			} else {
+			    ns = xmlSearchNs(elem->doc, elem,
+				alias->targetNs->prefix);
+			    if ((ns == NULL) ||
+				(! xmlStrEqual(ns->href, alias->targetNs->href)))
+			    {
+				ns = xsltTreeAcquireStoredNs(elem->doc,
+				    alias->targetNs->href,
+				    alias->targetNs->prefix);
+				
+				if (ns == NULL) {
+				    xsltTransformError(NULL, cctxt->style, elem,
+					"Internal error in "
+					"xsltLREBuildEffectiveNs(): "
+					"failed to acquire a stored "
+					"ns-declaration.\n");
+				    cctxt->style->errors++;
+				    return(-1);
+				    
+				}
+			    }
+			    elem->ns = ns;
+			}
+		    } else {
+		    /*
+		    * Move into or leave in the NULL namespace.
+			*/
+			elem->ns = NULL;
+		    }
+		    break;
+		}
+		alias = alias->next;
+	    }
+	    
+	    attr = attr->next;
+	}
+    }
+    return(0);
+}
+
+/**
+ * xsltLREBuildEffectiveNsNodes:
+ *
+ * Computes the effective namespaces nodes for a literal result
+ * element.
+ * @effectiveNs is the set of effective ns-nodes
+ *  on the literal result element, which will be added to the result
+ *  element if not already existing in the result tree.
+ *  This means that excluded namespaces (via exclude-result-prefixes,
+ *  extension-element-prefixes and the XSLT namespace) not added
+ *  to the set.
+ *  Namespace-aliasing was applied on the @effectiveNs.
+ */
+static int
+xsltLREBuildEffectiveNsNodes(xsltCompilerCtxtPtr cctxt,
+			     xsltStyleItemLRElementInfoPtr item,
+			     xmlNodePtr elem,
+			     int isLRE)
+{
+    xmlNsPtr ns, tmpns;
+    xsltEffectiveNsPtr effNs, lastEffNs = NULL;
+    int i, j, holdByElem;
+    xsltPointerListPtr extElemNs = cctxt->inode->extElemNs;
+    xsltPointerListPtr exclResultNs = cctxt->inode->exclResultNs;
+
+    if ((cctxt == NULL) || (cctxt->inode == NULL) || (elem == NULL) ||
+	(item == NULL) || (item->effectiveNs != NULL))
+	return(-1);
+
+    if (item->inScopeNs == NULL)    
+	return(0);
+
+    extElemNs = cctxt->inode->extElemNs;
+    exclResultNs = cctxt->inode->exclResultNs;
+
+    for (i = 0; i < item->inScopeNs->number; i++) {
+	ns = item->inScopeNs->list[i];
+	/*
+	* Skip namespaces designated as excluded namespaces
+	* -------------------------------------------------
+	*
+	* XSLT-20 TODO: In XSLT 2.0 we need to keep namespaces
+	*  which are target namespaces of namespace-aliases
+	*  regardless if designated as excluded.
+	*
+	* Exclude the XSLT namespace.
+	*/
+	if (xmlStrEqual(ns->href, XSLT_NAMESPACE))
+	    goto skip_ns;
+	
+	/*
+	* Exclude excluded result namespaces.
+	*/
+	if (exclResultNs) {
+	    for (j = 0; j < exclResultNs->number; j++)
+		if (xmlStrEqual(ns->href, BAD_CAST exclResultNs->items[j]))
+		    goto skip_ns;
+	}
+	/*
+	* Exclude extension-element namespaces.
+	*/
+	if (extElemNs) {
+	    for (j = 0; j < extElemNs->number; j++)
+		if (xmlStrEqual(ns->href, BAD_CAST extElemNs->items[j]))
+		    goto skip_ns;
+	}
+	/*
+	* OPTIMIZE TODO: This information may not be needed.
+	*/
+	if (isLRE && (elem->nsDef != NULL)) {
+	    holdByElem = 0;
+	    tmpns = elem->nsDef;
+	    do {
+		if (tmpns == ns) {
+		    holdByElem = 1;
+		    break;
+		}
+		tmpns = tmpns->next;
+	    } while (tmpns != NULL);	    
+	} else
+	    holdByElem = 0;
+	/*
+	* Apply namespace aliasing
+	* ------------------------
+	* 
+	* NOTE: The ns-aliasing machanism is non-cascading.
+	*  (checked with Saxon, Xalan and MSXML .NET).
+	* URGENT TODO: is style->nsAliases the effective list of
+	*  ns-aliases, or do we need to lookup the whole
+	*  import-tree?
+	* TODO: Get rid of import-tree lookup.
+	*/
+	if (cctxt->hasNsAliases) {
+	    xsltNsAliasPtr alias = cctxt->nsAliases;
+	    do {
+		/*
+		* TODO: What to do with xmlns="" ?
+		*/
+		if ((alias->literalNs != NULL) &&
+		    (xmlStrEqual(alias->literalNs->href, ns->href)))
+		{
+		    /*
+		    * Recognized as an namespace alias; convert it to
+		    * the target namespace.
+		    */
+		    ns = alias->literalNs;
+		    break;
+		}
+		alias = alias->next;
+	    } while (alias != NULL);		
+	}
+	
+	/*
+	* Add the effective namespace declaration.
+	*/
+	effNs = (xsltEffectiveNsPtr) xmlMalloc(sizeof(xsltEffectiveNs));
+	if (effNs == NULL) {
+	    xsltTransformError(NULL, cctxt->style, elem,
+		"Internal error in xsltLREBuildEffectiveNs(): "
+		"failed to allocate memory.\n");
+	    cctxt->style->errors++;
+	    return(-1);
+	}
+	if (cctxt->psData->effectiveNs == NULL) {
+	    cctxt->psData->effectiveNs = effNs;
+	    effNs->nextInStore = NULL;	 
+	} else {
+	    effNs->nextInStore = cctxt->psData->effectiveNs;
+	    cctxt->psData->effectiveNs = effNs;
+	}
+
+	effNs->next = NULL;
+	effNs->prefix = ns->prefix;
+	effNs->nsName = ns->href;
+	effNs->holdByElem = holdByElem;
+	
+	if (lastEffNs == NULL)
+	    item->effectiveNs = effNs;
+	else
+	    lastEffNs->next = effNs;
+	lastEffNs = effNs;
+	
+skip_ns:
+	{}
+    }
+    return(0);
+}
+
+
+/**
+ * xsltLREInfoCreate:
+ *
+ * @isLRE: indicates if the given @elem is a literal result element
+ *
+ * Creates a new info for a literal result element.
+ */
+static int
+xsltLREInfoCreate(xsltCompilerCtxtPtr cctxt,
+		  xmlNodePtr elem,
+		  int isLRE)
+{
+    xsltStyleItemLRElementInfoPtr item;
+
+    if ((cctxt == NULL) || (cctxt->inode == NULL))
+	return(-1);
+
+    item = (xsltStyleItemLRElementInfoPtr)
+	xmlMalloc(sizeof(xsltStyleItemLRElementInfo));
+    if (item == NULL) {
+	xsltTransformError(NULL, cctxt->style, NULL,
+	    "Internal error in xsltLREInfoCreate(): "
+	    "memory allocation failed.\n");
+	cctxt->style->errors++;
+	return(-1);
+    }
+    memset(item, 0, sizeof(xsltStyleItemLRElementInfo));
+    item->type = XSLT_FUNC_LITERAL_RESULT_ELEMENT;
+    /*
+    * Store it in the stylesheet.
+    */
+    item->next = cctxt->style->preComps;
+    cctxt->style->preComps = (xsltElemPreCompPtr) item;
+    /*
+    * @inScopeNs are used for execution of XPath expressions
+    *  in AVTs.
+    */
+    item->inScopeNs = cctxt->inode->inScopeNs;
+    
+    if (elem)
+	xsltLREBuildEffectiveNsNodes(cctxt, item, elem, isLRE);
+
+    cctxt->inode->litResElemInfo = item;
+    cctxt->inode->nsChanged = 0;
+    cctxt->maxLREs++;
+    return(0);
+}
+
+/*
+* xsltCompilerNodePush:
+*
+* @cctxt: the compilation context
+* @node: the node to be pushed (this can also be the doc-node)
+*
+* Returns the current node info structure or
+*         NULL in case of an internal error.
+*/
+xsltCompilerNodeInfoPtr
 xsltCompilerNodePush(xsltCompilerCtxtPtr cctxt, xmlNodePtr node)
 {    
+    xsltCompilerNodeInfoPtr inode, iprev;
+
     if ((cctxt->inode != NULL) && (cctxt->inode->next != NULL)) {	
-	cctxt->inode = cctxt->inode->next;
+	inode = cctxt->inode->next;
     } else if ((cctxt->inode == NULL) && (cctxt->inodeList != NULL)) {
-	cctxt->inode = cctxt->inodeList;	
+	inode = cctxt->inodeList;	
     } else {
 	/*
 	* Create a new node-info.
 	*/
-	cctxt->inode = (xsltCompilerNodeInfoPtr)
+	inode = (xsltCompilerNodeInfoPtr)
 	    xmlMalloc(sizeof(xsltCompilerNodeInfo));
-	if (cctxt->inode == NULL) {
-	    xsltTransformError(NULL, cctxt->sheet, NULL,
+	if (inode == NULL) {
+	    xsltTransformError(NULL, cctxt->style, NULL,
 		"xsltCompilerNodePush: malloc failed.\n");
 	    return(NULL);
 	}
-	memset(cctxt->inode, 0, sizeof(xsltCompilerNodeInfo));
+	memset(inode, 0, sizeof(xsltCompilerNodeInfo));
 	if (cctxt->inodeList == NULL)
-	    cctxt->inodeList = cctxt->inode;
+	    cctxt->inodeList = inode;
 	else {
-	    cctxt->inodeLast->next = cctxt->inode;
-	    cctxt->inode->prev = cctxt->inodeLast;
+	    cctxt->inodeLast->next = inode;
+	    inode->prev = cctxt->inodeLast;
 	}
-	cctxt->inodeLast = cctxt->inode;
-    }
-    /*
-    * REVISIT TODO: Keep the reset always complete.
-    */
+	cctxt->inodeLast = inode;
+	cctxt->maxNodeInfos++;	
+	if (cctxt->inode == NULL) {
+	    cctxt->inode = inode;
+	    /*
+	    * Create an initial literal result element info for
+	    * the root of the stylesheet.
+	    */
+	    xsltLREInfoCreate(cctxt, NULL, 0);
+	} 
+    }       
     cctxt->depth++;
-    cctxt->inode->depth = cctxt->depth;
-    cctxt->inode->templ = NULL;
-    cctxt->inode->item = NULL;
-    cctxt->inode->node = node;
+    cctxt->inode = inode;
     /*
-    * Inherit the list of in-scope namespaces.
+    * REVISIT TODO: Keep the reset always complete.    
+    * NOTE: Be carefull with the @node, since it might be
+    *  a doc-node.
     */
-    if (cctxt->inode->prev != NULL)
-	cctxt->inode->inScopeNS = cctxt->inode->prev->inScopeNS;
-    else
-	cctxt->inode->inScopeNS = NULL;
+    inode->node = node;
+    inode->depth = cctxt->depth;
+    inode->templ = NULL;
+    inode->category = XSLT_ELEMENT_CATEGORY_XSLT;
+    inode->type = 0;
+    inode->item = NULL;
+    inode->curChildType = 0;
+    inode->extContentHandled = 0;
+    inode->isRoot = 0;
     
-    return(cctxt->inode);
+    if (inode->prev != NULL) {
+	iprev = inode->prev;
+	/*
+	* Inherit the following information:
+	* ---------------------------------
+	*
+	* In-scope namespaces
+	*/
+	inode->inScopeNs = iprev->inScopeNs;
+	/*
+	* Info for literal result elements
+	*/
+	inode->litResElemInfo = iprev->litResElemInfo;
+	inode->nsChanged = iprev->nsChanged;
+	/*
+	* Excluded result namespaces
+	*/
+	inode->exclResultNs = iprev->exclResultNs;
+	/*
+	* Extension instruction namespaces
+	*/
+	inode->extElemNs = iprev->extElemNs;
+	/*
+	* Whitespace preservation
+	*/
+	inode->preserveWhitespace = iprev->preserveWhitespace;
+	/*
+	* Forwards-compatible mode
+	*/
+	inode->forwardsCompat = iprev->forwardsCompat;	
+    } else {
+	inode->inScopeNs = NULL;
+	inode->exclResultNs = NULL;
+	inode->extElemNs = NULL;
+	inode->preserveWhitespace = 0;
+	inode->forwardsCompat = 0;
+    }
+    
+    return(inode);
 }
 
+/*
+* xsltCompilerNodePop:
+*
+* @cctxt: the compilation context
+* @node: the node to be pushed (this can also be the doc-node)
+*
+* Pops the current node info.
+*/
 static void
 xsltCompilerNodePop(xsltCompilerCtxtPtr cctxt, xmlNodePtr node)
 {    
@@ -1363,47 +2276,959 @@
 	xmlGenericError(xmlGenericErrorContext,
 	    "xsltCompilerNodePop: Top-node mismatch.\n");
 	return;
-    }    	
-    if (cctxt->inode->node != node)
+    }
+    /*
+    * NOTE: Be carefull with the @node, since it might be
+    *  a doc-node.
+    */
+    if (cctxt->inode->node != node) {
 	xmlGenericError(xmlGenericErrorContext,
 	"xsltCompilerNodePop: Node mismatch.\n");
-    if (cctxt->inode->depth != cctxt->depth)
+	goto mismatch;
+    }
+    if (cctxt->inode->depth != cctxt->depth) {
 	xmlGenericError(xmlGenericErrorContext,
 	"xsltCompilerNodePop: Depth mismatch.\n");
+	goto mismatch;
+    }
     cctxt->depth--;
     cctxt->inode = cctxt->inode->prev;
+    if (cctxt->inode != NULL)
+	cctxt->inode->curChildType = 0;
+    return;
+
+mismatch:
+    {
+	const xmlChar *nsName = NULL, *name = NULL;
+	const xmlChar *infnsName = NULL, *infname = NULL;
+	
+	if (node) {
+	    if (node->type == XML_ELEMENT_NODE) {
+		name = node->name;
+		if (node->ns != NULL)
+		    nsName = node->ns->href;
+		else
+		    nsName = BAD_CAST "";
+	    } else {
+		name = BAD_CAST "#document";
+		nsName = BAD_CAST "";
+	    }
+	} else
+	    name = BAD_CAST "Not given";
+
+	if (cctxt->inode->node) {
+	    if (node->type == XML_ELEMENT_NODE) {
+		infname = cctxt->inode->node->name;
+		if (cctxt->inode->node->ns != NULL)
+		    infnsName = cctxt->inode->node->ns->href;
+		else
+		    infnsName = BAD_CAST "";
+	    } else {
+		infname = BAD_CAST "#document";
+		infnsName = BAD_CAST "";
+	    }
+	} else
+	    infname = BAD_CAST "Not given";
+
+	
+	xmlGenericError(xmlGenericErrorContext,
+	    "xsltCompilerNodePop: Given   : '%s' URI '%s'\n",
+	    name, nsName);
+	xmlGenericError(xmlGenericErrorContext,
+	    "xsltCompilerNodePop: Expected: '%s' URI '%s'\n",
+	    infname, infnsName);
+    }
 }
 
+/*
+* xsltCompilerBuildInScopeNsList:
+*
+* Create and store the list of in-scope namespaces for the given
+* node in the stylesheet. If there are no changes in the in-scope
+* namespaces then the last ns-info of the ancestor axis will be returned.
+* Compilation-time only.
+*
+* Returns the ns-info or NULL if there are no namespaces in scope.
+*/
+static xsltNsListContainerPtr
+xsltCompilerBuildInScopeNsList(xsltCompilerCtxtPtr cctxt, xmlNodePtr node)
+{
+    xsltNsListContainerPtr nsi = NULL;
+    xmlNsPtr *list = NULL;
+    /*
+    * Create a new ns-list for this position in the node-tree.
+    * xmlGetNsList() will return NULL, if there are no ns-decls in the
+    * tree. Note that the ns-decl for the XML namespace is not added
+    * to the resulting list; the XPath module handles the XML namespace
+    * internally.
+    */
+    list = xmlGetNsList(node->doc, node);
+    if (list == NULL)
+	return(NULL);
+    /*
+    * Create the info-structure.
+    */
+    nsi = (xsltNsListContainerPtr) xmlMalloc(sizeof(xsltNsListContainer));
+    if (nsi == NULL) {	
+	xsltTransformError(NULL, cctxt->style, NULL,
+	    "xsltCompilerBuildInScopeNsList: malloc failed.\n");
+	goto internal_err;
+    }
+    memset(nsi, 0, sizeof(xsltNsListContainer));
+    nsi->list = list;
+    /*
+    * Eval the number of ns-decls; this is used to speed up
+    * XPath-context initialization.
+    */
+    while (list[nsi->number] != NULL)
+	nsi->number++;
+    /*
+    * Store the ns-list in the stylesheet.
+    */
+    if (xsltPointerListAddSize(
+	(xsltPointerListPtr)cctxt->psData->inScopeNamespaces,
+	(void *) nsi, 5) == -1)
+    {	
+	xmlFree(nsi);
+	nsi = NULL;
+	xsltTransformError(NULL, cctxt->style, NULL,
+	    "xsltCompilerBuildInScopeNsList: failed to add ns-info.\n");
+	goto internal_err;
+    }
+    /*
+    * Notify of change in status wrt namespaces.
+    */
+    if (cctxt->inode != NULL)
+	cctxt->inode->nsChanged = 1;
+
+    return(nsi);
+
+internal_err:
+    if (list != NULL)
+	xmlFree(list);    
+    cctxt->style->errors++;
+    return(NULL);
+}
+
+static int
+xsltParseNsPrefixList(xsltCompilerCtxtPtr cctxt,
+		      xsltPointerListPtr list,
+		      xmlNodePtr node,
+		      const xmlChar *value)
+{
+    xmlChar *cur, *end;
+    xmlNsPtr ns;
+    
+    if ((cctxt == NULL) || (value == NULL) || (list == NULL))
+	return(-1);
+
+    list->number = 0;
+
+    cur = (xmlChar *) value;
+    while (*cur != 0) {
+	while (IS_BLANK(*cur)) cur++;
+	if (*cur == 0)
+	    break;
+	end = cur;
+	while ((*end != 0) && (!IS_BLANK(*end))) end++;
+	cur = xmlStrndup(cur, end - cur);
+	if (cur == NULL) {
+	    cur = end;
+	    continue;
+	}		
+	/*
+	* TODO: Export and use xmlSearchNsByPrefixStrict()
+	*   in Libxml2, tree.c, since xmlSearchNs() is in most
+	*   cases not efficient and in some cases not correct.
+	*
+	* XSLT-2 TODO: XSLT 2.0 allows an additional "#all" value.
+	*/
+	if ((cur[0] == '#') &&
+	    xmlStrEqual(cur, (const xmlChar *)"#default"))
+	    ns = xmlSearchNs(cctxt->style->doc, node, NULL);
+	else
+	    ns = xmlSearchNs(cctxt->style->doc, node, cur);	    
+
+	if (ns == NULL) {
+	    /*
+	    * TODO: Better to report the attr-node, otherwise
+	    *  the user won't know which attribute was invalid.
+	    */
+	    xsltTransformError(NULL, cctxt->style, node,
+		"No namespace binding in scope for prefix '%s'.\n", cur);
+	    /*
+	    * XSLT-1.0: "It is an error if there is no namespace
+	    *  bound to the prefix on the element bearing the
+	    *  exclude-result-prefixes or xsl:exclude-result-prefixes
+	    *  attribute."
+	    */
+	    cctxt->style->errors++;
+	} else {
+#ifdef WITH_XSLT_DEBUG_PARSING
+	    xsltGenericDebug(xsltGenericDebugContext,
+		"resolved prefix '%s'\n", cur);
 #endif
+	    /*
+	    * Note that we put the namespace name into the dict.
+	    */
+	    if (xsltPointerListAddSize(list,
+		(void *) xmlDictLookup(cctxt->style->dict,
+		ns->href, -1), 5) == -1)
+	    {
+		xmlFree(cur);
+		goto internal_err;
+	    }
+	}
+	xmlFree(cur);
+		
+	cur = end;
+    }
+    return(0);
 
+internal_err:
+    cctxt->style->errors++;
+    return(-1);
+}
+
 /**
- * xsltPrecomputeStylesheet:
- * @style:  the XSLT stylesheet
- * @cur:  the current child list
+ * xsltCompilerUtilsCreateMergedList:
+ * @dest: the destination list (optional)
+ * @first: the first list
+ * @second: the second list (optional)
  *
- * Clean-up the stylesheet content from unwanted ignorable blank nodes
- * and run the preprocessing of all XSLT constructs.
+ * Appends the content of @second to @first into @destination.
+ * If @destination is NULL a new list will be created.
  *
- * and process xslt:text
- *
- * URGENT TODO: In order to avoid separation of the parsing of the stylesheet's
- *   node-tree, this should either only strip whitespace-only text-nodes,
- *   or it should be merged completely with the stylesheet-parsing
- *   functions (e.g. xsltParseStylesheetTop()).
+ * Returns the merged list of items or NULL if there's nothing to merge.
  */
+static xsltPointerListPtr
+xsltCompilerUtilsCreateMergedList(xsltPointerListPtr first,
+			    xsltPointerListPtr second)
+{
+    xsltPointerListPtr ret;
+    size_t num;
+
+    if (first)
+	num = first->number;
+    else
+	num = 0;
+    if (second)
+	num += second->number;    
+    if (num == 0)
+	return(NULL);
+    ret = xsltPointerListCreate(num);
+    if (ret == NULL)
+	return(NULL);
+    /*
+    * Copy contents.
+    */
+    if ((first != NULL) &&  (first->number != 0)) {
+	memcpy(ret->items, first->items,
+	    first->number * sizeof(void *));
+	if ((second != NULL) && (second->number != 0))
+	    memcpy(ret->items + first->number, second->items,
+		second->number * sizeof(void *));
+    } else if ((second != NULL) && (second->number != 0))
+	memcpy(ret->items, (void *) second->items,
+	    second->number * sizeof(void *));
+    ret->number = num;
+    return(ret);
+}
+
+/*
+* xsltParseExclResultPrefixes:
+*
+* Create and store the list of in-scope namespaces for the given
+* node in the stylesheet. If there are no changes in the in-scope
+* namespaces then the last ns-info of the ancestor axis will be returned.
+* Compilation-time only.
+*
+* Returns the ns-info or NULL if there are no namespaces in scope.
+*/
+static xsltPointerListPtr
+xsltParseExclResultPrefixes(xsltCompilerCtxtPtr cctxt, xmlNodePtr node,
+			    xsltPointerListPtr def,
+			    int instrCategory)
+{    
+    xsltPointerListPtr list = NULL;
+    xmlChar *value = NULL;
+
+    if ((cctxt == NULL) || (node == NULL))
+	return(NULL);
+    
+    if (instrCategory == XSLT_ELEMENT_CATEGORY_XSLT)
+	value = xmlGetNsProp(node, BAD_CAST "exclude-result-prefixes", NULL);
+    else
+	value = xmlGetNsProp(node, BAD_CAST "exclude-result-prefixes",
+	    XSLT_NAMESPACE);
+
+    if (value == NULL)
+	return(def);
+
+    if (xsltParseNsPrefixList(cctxt, cctxt->tmpList, node,
+	BAD_CAST value) != 0)
+	goto exit;
+    if (cctxt->tmpList->number == 0)	
+	goto exit;    
+    /*
+    * Merge the list with the inherited list.
+    */
+    list = xsltCompilerUtilsCreateMergedList(def, cctxt->tmpList);
+    if (list == NULL)
+	goto exit;    
+    /*
+    * Store the list in the stylesheet/compiler context.
+    */
+    if (xsltPointerListAddSize(
+	cctxt->psData->exclResultNamespaces, list, 5) == -1)
+    {
+	xsltPointerListFree(list);
+	list = NULL;
+	goto exit;
+    }
+    /*
+    * Notify of change in status wrt namespaces.
+    */
+    if (cctxt->inode != NULL)
+	cctxt->inode->nsChanged = 1;
+
+exit:
+    if (value != NULL)
+	xmlFree(value);
+    if (list != NULL)
+	return(list);
+    else
+	return(def);
+}
+
+/*
+* xsltParseExtElemPrefixes:
+*
+* Create and store the list of in-scope namespaces for the given
+* node in the stylesheet. If there are no changes in the in-scope
+* namespaces then the last ns-info of the ancestor axis will be returned.
+* Compilation-time only.
+*
+* Returns the ns-info or NULL if there are no namespaces in scope.
+*/
+static xsltPointerListPtr
+xsltParseExtElemPrefixes(xsltCompilerCtxtPtr cctxt, xmlNodePtr node,
+			 xsltPointerListPtr def,
+			 int instrCategory)
+{    
+    xsltPointerListPtr list = NULL;
+    xmlAttrPtr attr;
+    xmlChar *value;
+    int i;
+
+    if ((cctxt == NULL) || (node == NULL))
+	return(NULL);
+
+    if (instrCategory == XSLT_ELEMENT_CATEGORY_XSLT)
+	attr = xmlHasNsProp(node, BAD_CAST "extension-element-prefixes", NULL);
+    else
+	attr = xmlHasNsProp(node, BAD_CAST "extension-element-prefixes",
+	    XSLT_NAMESPACE);
+    if (attr == NULL)	
+	return(def);
+
+    if ((attr->children != NULL) &&	
+	(attr->children->content != NULL))
+	value = attr->children->content;
+    else {
+	xsltTransformError(NULL, cctxt->style, node,
+	    "Attribute 'extension-element-prefixes': Invalid value.\n");
+	cctxt->style->errors++;
+	return(def);
+    }
+
+
+    if (xsltParseNsPrefixList(cctxt, cctxt->tmpList, node,
+	BAD_CAST value) != 0)
+	goto exit;
+
+    if (cctxt->tmpList->number == 0)
+	goto exit;    
+    /*
+    * REVISIT: Register the extension namespaces.
+    */
+    for (i = 0; i < cctxt->tmpList->number; i++)
+	xsltRegisterExtPrefix(cctxt->style, NULL,
+	BAD_CAST cctxt->tmpList->items[i]);
+    /*
+    * Merge the list with the inherited list.
+    */
+    list = xsltCompilerUtilsCreateMergedList(def, cctxt->tmpList);
+    if (list == NULL)
+	goto exit;
+    /*
+    * Store the list in the stylesheet.
+    */
+    if (xsltPointerListAddSize(
+	cctxt->psData->extElemNamespaces, list, 5) == -1)
+    {
+	xsltPointerListFree(list);
+	list = NULL;
+	goto exit;
+    }
+    /*
+    * Notify of change in status wrt namespaces.
+    */
+    if (cctxt->inode != NULL)
+	cctxt->inode->nsChanged = 1;
+
+exit:
+    if (attr && (instrCategory == XSLT_ELEMENT_CATEGORY_LRE)) {
+	/*
+	* Remove the XSLT attribute from the literal result element.
+	*/
+	xmlUnlinkNode((xmlNodePtr) attr);
+	xmlFreeProp(attr);
+    }
+    if (list != NULL)
+	return(list);
+    else
+	return(def);
+}
+
+
+/*
+* xsltParseAttrXSLTVersion:
+*
+* @cctxt: the compilation context
+* @node: the element-node
+* @isXsltElem: whether this is an XSLT element
+*
+* Parses the attribute xsl:version.
+*
+* Returns 1 if there was such an attribute, 0 if not and
+*         -1 if an internal or API error occured.
+*/
+static int
+xsltParseAttrXSLTVersion(xsltCompilerCtxtPtr cctxt, xmlNodePtr node,			 
+			 int instrCategory)
+{
+    xmlChar *value;
+    xmlAttrPtr attr;
+
+    if ((cctxt == NULL) || (node == NULL))
+	return(-1);
+
+    if (instrCategory == XSLT_ELEMENT_CATEGORY_XSLT)
+	attr = xmlHasNsProp(node, BAD_CAST "version", NULL);
+    else
+	attr = xmlHasNsProp(node, BAD_CAST "version", XSLT_NAMESPACE);
+
+    if (attr == NULL)	
+	return(0);
+
+    if ((attr->children != NULL) &&	
+	(attr->children->content != NULL))
+	value = attr->children->content;
+    else {
+	xsltTransformError(NULL, cctxt->style, node,
+	    "Attribute 'version': Invalid value.\n");
+	cctxt->style->errors++;
+	return(1);
+    }
+    
+    if (! xmlStrEqual(value, (const xmlChar *)"1.0")) {
+	cctxt->inode->forwardsCompat = 1;
+	/*
+	* TODO: To what extent do we support the
+	*  forwards-compatible mode?
+	*/
+	/*
+	* Report this only once per compilation episode.
+	*/
+	if (! cctxt->hasForwardsCompat) {
+	    cctxt->hasForwardsCompat = 1;
+	    cctxt->errSeverity = XSLT_ERROR_SEVERITY_WARNING;
+	    xsltTransformError(NULL, cctxt->style, node,
+		"Warning: the attribute xsl:version specifies a value "
+		"different from '1.0'. Switching to forwards-compatible "
+		"mode. Only features of XSLT 1.0 are supported by this "
+		"processor.\n");
+	    cctxt->style->warnings++;
+	    cctxt->errSeverity = XSLT_ERROR_SEVERITY_ERROR;
+	}	
+    } else {
+	cctxt->inode->forwardsCompat = 0;
+    }
+
+    if (attr && (instrCategory == XSLT_ELEMENT_CATEGORY_LRE)) {
+	/*
+	* Remove the XSLT attribute from the literal result element.
+	*/
+	xmlUnlinkNode((xmlNodePtr) attr);
+	xmlFreeProp(attr);
+    }
+    return(1);
+}
+
+#if 0
+static int
+xsltParseRemoveXSLTAttrs(xsltCompilerCtxtPtr cctxt, xmlNodePtr node)
+{
+    if (node->properties == NULL)
+	return(0);
+    else {
+	xmlAttrPtr tmpattr, attr = node->properties;
+	do {	    
+	    if (IS_XSLT_ATTR_FAST(attr)) {
+		tmpattr = attr;
+		attr = attr->next;
+		xmlUnlinkNode((xmlNodePtr) tmpattr);
+		xmlFreeProp(tmpattr);
+	    } else
+		attr = attr->next;
+	} while (attr != NULL);
+    }
+}
+#endif
+
+static int
+xsltParsePreprocessStylesheetTree(xsltCompilerCtxtPtr cctxt, xmlNodePtr node)
+{
+    xmlNodePtr deleteNode, cur, txt, textNode = NULL;
+    xmlDocPtr doc;
+    xsltStylesheetPtr style;
+    int internalize = 0, findSpaceAttr;
+    int xsltStylesheetElemDepth;
+    xmlAttrPtr attr;
+    xmlChar *value;
+    const xmlChar *name, *nsNameXSLT = NULL;
+    int strictWhitespace, inXSLText = 0;
+#ifdef XSLT_REFACTORED_XSLT_NSCOMP
+    xsltNsMapPtr nsMapItem;
+#endif
+
+    if ((cctxt == NULL) || (cctxt->style == NULL) ||
+	(node == NULL) || (node->type != XML_ELEMENT_NODE))
+        return(-1);
+
+    doc = node->doc;
+    if (doc == NULL)
+	goto internal_err;
+
+    style = cctxt->style;
+    if ((style->dict != NULL) && (doc->dict == style->dict))
+	internalize = 1;
+    else
+        style->internalized = 0;
+
+    /*
+    * Init value of xml:space. Since this might be an embedded
+    * stylesheet, this is needed to be performed on the element
+    * where the stylesheet is rooted at, taking xml:space of
+    * ancestors into account.
+    */
+    if (! cctxt->simplified)
+	xsltStylesheetElemDepth = cctxt->depth +1;
+    else
+	xsltStylesheetElemDepth = 0;
+
+    if (xmlNodeGetSpacePreserve(node) != 1)
+	cctxt->inode->preserveWhitespace = 0;
+    else
+	cctxt->inode->preserveWhitespace = 1; 
+    
+    /*
+    * Eval if we should keep the old incorrect behaviour.
+    */
+    strictWhitespace = (cctxt->strict != 0) ? 1 : 0;
+
+    nsNameXSLT = xsltConstNamespaceNameXSLT;
+
+    deleteNode = NULL;
+    cur = node;
+    while (cur != NULL) {
+	if (deleteNode != NULL)	{
+
+#ifdef WITH_XSLT_DEBUG_BLANKS
+	    xsltGenericDebug(xsltGenericDebugContext,
+	     "xsltParsePreprocessStylesheetTree: removing node\n");
+#endif
+	    xmlUnlinkNode(deleteNode);
+	    xmlFreeNode(deleteNode);
+	    deleteNode = NULL;
+	}
+	if (cur->type == XML_ELEMENT_NODE) {
+	    
+	    /*
+	    * Clear the PSVI field.
+	    */
+	    cur->psvi = NULL;
+
+	    xsltCompilerNodePush(cctxt, cur);
+
+	    inXSLText = 0;
+	    textNode = NULL;	    
+	    findSpaceAttr = 1;	    
+	    cctxt->inode->stripWhitespace = 0;
+	    /*
+	    * TODO: I'd love to use a string pointer comparison here :-/
+	    */
+	    if (IS_XSLT_ELEM(cur)) {
+#ifdef XSLT_REFACTORED_XSLT_NSCOMP
+		if (cur->ns->href != nsNameXSLT) {
+		    nsMapItem = xsltNewNamespaceMapItem(cctxt,
+			doc, cur->ns, cur);
+		    if (nsMapItem == NULL)
+			goto internal_err;
+		    cur->ns->href = nsNameXSLT;
+		}
+#endif
+
+		if (cur->name == NULL)
+		    goto process_attributes;
+		/*
+		* Mark the XSLT element for later recognition.
+		* TODO: Using the marker is still too dangerous, since if
+		*   the parsing mechanism leaves out an XSLT element, then
+		*   this might hit the transformation-mechanism, which
+		*   will break if it doesn't expect such a marker.
+		*/
+		/* cur->psvi = (void *) xsltXSLTElemMarker; */
+
+		/*
+		* XSLT 2.0: "Any whitespace text node whose parent is
+		* one of the following elements is removed from the "
+		* tree, regardless of any xml:space attributes:..."
+		* xsl:apply-imports, 
+		* xsl:apply-templates,
+		* xsl:attribute-set,
+		* xsl:call-template, 
+		* xsl:choose,
+		* xsl:stylesheet, xsl:transform.
+		* XSLT 2.0: xsl:analyze-string,
+		*           xsl:character-map,
+		*           xsl:next-match		
+		*
+		* TODO: I'd love to use a string pointer comparison here :-/
+		*/		
+		name = cur->name;
+		switch (*name) {
+		    case 't':
+			if ((name[0] == 't') && (name[1] == 'e') &&
+			    (name[2] == 'x') && (name[3] == 't') &&
+			    (name[4] == 0))
+			{
+			    /*
+			    * Process the xsl:text element.
+			    * ----------------------------
+			    * Mark it for later recognition.
+			    */
+			    cur->psvi = (void *) xsltXSLTTextMarker;
+			    /*
+			    * For stylesheets, the set of
+			    * whitespace-preserving element names
+			    * consists of just xsl:text.
+			    */
+			    findSpaceAttr = 0;
+			    cctxt->inode->preserveWhitespace = 1;
+			    inXSLText = 1;
+			}			    
+			break;
+		    case 'c':
+			if (xmlStrEqual(name, BAD_CAST "choose") ||
+			    xmlStrEqual(name, BAD_CAST "call-template"))
+			    cctxt->inode->stripWhitespace = 1;
+			break;
+		    case 'a':
+			if (xmlStrEqual(name, BAD_CAST "apply-templates") ||
+			    xmlStrEqual(name, BAD_CAST "apply-imports") ||
+			    xmlStrEqual(name, BAD_CAST "attribute-set"))
+
+			    cctxt->inode->stripWhitespace = 1;
+			break;
+		    default:
+			if (xsltStylesheetElemDepth == cctxt->depth) {
+			    /*
+			    * This is a xsl:stylesheet/xsl:transform.
+			    */
+			    cctxt->inode->stripWhitespace = 1;
+			    break;
+			}
+
+			if ((cur->prev != NULL) &&
+			    (cur->prev->type == XML_TEXT_NODE))
+			{
+			    /*
+			    * XSLT 2.0 : "Any whitespace text node whose
+			    *  following-sibling node is an xsl:param or
+			    *  xsl:sort element is removed from the tree,
+			    *  regardless of any xml:space attributes."
+			    */
+			    if (((*name == 'p') || (*name == 's')) &&
+				(xmlStrEqual(name, BAD_CAST "param") ||
+				 xmlStrEqual(name, BAD_CAST "sort")))
+			    {
+				do {
+				    if (IS_BLANK_NODE(cur->prev)) {
+					txt = cur->prev;
+					xmlUnlinkNode(txt);
+					xmlFreeNode(txt);
+				    } else {
+					/*
+					* This will result in a content
+					* error, when hitting the parsing
+					* functions.
+					*/
+					break;
+				    }
+				} while (cur->prev);				    
+			    }
+			}
+			break;
+		}
+	    }
+
+process_attributes:
+	    /*
+	    * Process attributes.
+	    * ------------------
+	    */
+	    if (cur->properties != NULL) {
+		if (cur->children == NULL)
+		    findSpaceAttr = 0;
+		attr = cur->properties;
+		do {
+#ifdef XSLT_REFACTORED_XSLT_NSCOMP
+		    if ((attr->ns) && (attr->ns->href != nsNameXSLT) &&
+			xmlStrEqual(attr->ns->href, nsNameXSLT))
+		    {			
+			nsMapItem = xsltNewNamespaceMapItem(cctxt,
+			    doc, attr->ns, cur);
+			if (nsMapItem == NULL)
+			    goto internal_err;
+			attr->ns->href = nsNameXSLT;
+		    }		    
+#endif
+		    if (internalize) {
+			/*
+			* Internalize the attribute's value; the goal is to
+			* speed up operations and minimize used space by
+			* compiled stylesheets.
+			*/
+			txt = attr->children;
+			/*
+			* NOTE that this assumes only one
+			*  text-node in the attribute's content.
+			*/
+			if ((txt != NULL) && (txt->content != NULL) &&
+			    (!xmlDictOwns(style->dict, txt->content)))
+			{
+			    value = (xmlChar *) xmlDictLookup(style->dict,
+				txt->content, -1);
+			    xmlNodeSetContent(txt, NULL);
+			    txt->content = value;
+			}
+		    }
+		    /*
+		    * Process xml:space attributes.
+		    * ----------------------------
+		    */
+		    if ((findSpaceAttr != 0) &&
+			(attr->ns != NULL) &&
+			(attr->name != NULL) &&
+			(attr->name[0] == 's') &&			
+			(attr->ns->prefix != NULL) &&
+			(attr->ns->prefix[0] == 'x') &&
+			(attr->ns->prefix[1] == 'm') &&
+			(attr->ns->prefix[2] == 'l') &&
+			(attr->ns->prefix[3] == 0))
+		    {
+			value = xmlGetNsProp(cur, BAD_CAST "space",
+			    XML_XML_NAMESPACE);
+			if (value != NULL) {
+			    if (xmlStrEqual(value, BAD_CAST "preserve")) {
+				cctxt->inode->preserveWhitespace = 1;				
+			    } else if (xmlStrEqual(value, BAD_CAST "default")) {
+				cctxt->inode->preserveWhitespace = 0;
+			    } else {
+				/* Invalid value for xml:space. */
+				xsltTransformError(NULL, style, cur,
+				    "Attribute xml:space: Invalid value.\n");
+				cctxt->style->warnings++;
+			    }
+			    findSpaceAttr = 0;
+			    xmlFree(value);
+			}
+			
+		    }
+		    attr = attr->next;
+		} while (attr != NULL);
+	    }
+	    /*
+	    * We'll descend into the children of element nodes only.
+	    */
+	    if (cur->children != NULL) {
+		cur = cur->children;
+		continue;
+	    }
+	} else if ((cur->type == XML_TEXT_NODE) ||
+		(cur->type == XML_CDATA_SECTION_NODE))
+	{
+	    /*
+	    * Merge adjacent text/CDATA-section-nodes
+	    * ---------------------------------------	    
+	    * In order to avoid breaking of existing stylesheets,
+	    * if the old behaviour is wanted (strictWhitespace == 0),
+	    * then we *won't* merge adjacent text-nodes
+	    * (except in xsl:text); this will ensure that whitespace-only
+	    * text nodes are (incorrectly) not stripped in some cases.
+	    * 
+	    * Example:               : <foo>  <!-- bar -->zoo</foo>
+	    * Corrent (strict) result: <foo>  zoo</foo>
+	    * Incorrect (old) result : <foo>zoo</foo>
+	    *    
+	    * NOTE that we *will* merge adjacent text-nodes if
+	    * they are in xsl:text.
+	    * Example, the following:
+	    * <xsl:text>  <!-- bar -->zoo<xsl:text>
+	    * will result in both cases in:
+	    * <xsl:text>  zoo<xsl:text>
+	    */
+	    cur->type = XML_TEXT_NODE;
+	    if ((strictWhitespace != 0) || (inXSLText != 0)) {
+		/*
+		* New behaviour; merge nodes.
+		*/
+		if (textNode == NULL)
+		    textNode = cur;
+		else {
+		    if (cur->content != NULL)
+			xmlNodeAddContent(textNode, cur->content);
+		    deleteNode = cur;
+		}
+		if ((cur->next == NULL) ||
+		    (cur->next->type == XML_ELEMENT_NODE))
+		    goto end_of_text;
+		else
+		    goto next_sibling;
+	    } else {
+		/*
+		* Old behaviour.
+		*/
+		if (textNode == NULL)
+		    textNode = cur;
+		goto end_of_text;
+	    }	    	   
+	} else if ((cur->type == XML_COMMENT_NODE) ||
+	    (cur->type == XML_PI_NODE))
+	{	    
+	    /*
+	    * Remove processing instructions and comments.
+	    */
+	    deleteNode = cur;
+	    if ((cur->next == NULL) ||
+		(cur->next->type == XML_ELEMENT_NODE))
+		goto end_of_text;
+	    else
+		goto next_sibling;
+	} else {
+	    textNode = NULL;
+	    /*
+	    * Invalid node-type for this data-model.
+	    */
+	    xsltTransformError(NULL, style, cur,
+		"Invalid type of node for the XSLT data model.\n");
+	    cctxt->style->errors++;
+	    goto next_sibling;
+	}
+
+end_of_text:
+	if (textNode) {
+	    value = textNode->content;
+	    /*
+	    * At this point all adjacent text/CDATA-section nodes
+	    * have been merged.
+	    *
+	    * Strip whitespace-only text-nodes.
+	    * (cctxt->inode->stripWhitespace)
+	    */
+	    if ((value == NULL) || (*value == 0) ||
+		(((cctxt->inode->stripWhitespace) ||
+		  (! cctxt->inode->preserveWhitespace)) &&
+		 IS_BLANK(*value) &&
+		 xsltIsBlank(value)))
+	    {		
+		if (textNode != cur) {
+		    xmlUnlinkNode(textNode);
+		    xmlFreeNode(textNode);
+		} else
+		    deleteNode = textNode;
+		textNode = NULL;
+		goto next_sibling;
+	    }
+	    /*
+	    * Convert CDATA-section nodes to text-nodes.
+	    * TODO: Can this produce problems?
+	    */
+	    if (textNode->type != XML_TEXT_NODE) {
+		textNode->type = XML_TEXT_NODE;
+		textNode->name = xmlStringText;
+	    }
+	    if (internalize &&
+		(textNode->content != NULL) &&
+		(!xmlDictOwns(style->dict, textNode->content)))
+	    {
+		/*
+		* Internalize the string.
+		*/
+		value = (xmlChar *) xmlDictLookup(style->dict,
+		    textNode->content, -1);
+		xmlNodeSetContent(textNode, NULL);
+		textNode->content = value;
+	    }
+	    textNode = NULL;
+	    /*
+	    * Note that "disable-output-escaping" of the xsl:text
+	    * element will be applied at a later level, when
+	    * XSLT elements are processed.
+	    */
+	}
+
+next_sibling:
+	if (cur->type == XML_ELEMENT_NODE) {
+	    xsltCompilerNodePop(cctxt, cur);
+	}
+	if (cur == node)
+	    break;
+	if (cur->next != NULL) {
+	    cur = cur->next;
+	} else {
+	    cur = cur->parent;
+	    inXSLText = 0;
+	    goto next_sibling;
+	};
+    }
+    if (deleteNode != NULL) {
+#ifdef WITH_XSLT_DEBUG_PARSING
+	xsltGenericDebug(xsltGenericDebugContext,
+	 "xsltParsePreprocessStylesheetTree: removing node\n");
+#endif
+	xmlUnlinkNode(deleteNode);
+	xmlFreeNode(deleteNode);
+    }
+    return(0);
+
+internal_err:
+    return(-1);
+}
+
+#endif /* XSLT_REFACTORED */
+
+#ifdef XSLT_REFACTORED
+#else
 static void
-xsltPrecomputeStylesheet(xsltStylesheetPtr style, xmlNodePtr cur) {
-    xmlNodePtr delete;
+xsltPrecomputeStylesheet(xsltStylesheetPtr style, xmlNodePtr cur)
+{
+    xmlNodePtr deleteNode;
     int internalize = 0;
-#ifdef XSLT_REFACTORED
-    xsltCompilerCtxtPtr cctxt;
-#endif
 
-    if ((style == NULL) || (cur == NULL)
-#ifdef XSLT_REFACTORED
-	||(style->compCtxt == NULL)
-#endif
-	)
+    if ((style == NULL) || (cur == NULL))
         return;
 
     if ((cur->doc != NULL) && (style->dict != NULL) &&
@@ -1411,43 +3236,37 @@
 	internalize = 1;
     else
         style->internalized = 0;
-#ifdef XSLT_REFACTORED
-    cctxt = (xsltCompilerCtxtPtr) style->compCtxt;    
-#endif
     /*
      * This content comes from the stylesheet
      * For stylesheets, the set of whitespace-preserving
      * element names consists of just xsl:text.
      */
-    delete = NULL;
+    deleteNode = NULL;
     while (cur != NULL) {
-	if (delete != NULL) {
+	if (deleteNode != NULL) {
 #ifdef WITH_XSLT_DEBUG_BLANKS
 	    xsltGenericDebug(xsltGenericDebugContext,
 	     "xsltPrecomputeStylesheet: removing ignorable blank node\n");
 #endif
-	    xmlUnlinkNode(delete);
-	    xmlFreeNode(delete);
-	    delete = NULL;
+	    xmlUnlinkNode(deleteNode);
+	    xmlFreeNode(deleteNode);
+	    deleteNode = NULL;
 	}
 	if (cur->type == XML_ELEMENT_NODE) {
-	    int exclPrefixes;	    
-
-#ifdef XSLT_REFACTORED
-	    xsltCompilerNodePush(cctxt, cur);
-#endif
+	    int exclPrefixes;
 	    /*
 	     * Internalize attributes values.
 	     */
 	    if ((internalize) && (cur->properties != NULL)) {
-	        xmlAttrPtr prop = cur->properties;
+	        xmlAttrPtr attr = cur->properties;
 		xmlNodePtr txt;
 
-		while (prop != NULL) {
-		    txt = prop->children;
+		while (attr != NULL) {
+		    txt = attr->children;
 		    if ((txt != NULL) && (txt->type == XML_TEXT_NODE) &&
 		        (txt->content != NULL) &&
-			(!xmlDictOwns(style->dict, txt->content))) {
+			(!xmlDictOwns(style->dict, txt->content)))
+		    {
 			xmlChar *tmp;
 
 			/*
@@ -1462,35 +3281,11 @@
 			    txt->content = tmp;
 			}
 		    }
-		    prop = prop->next;
+		    attr = attr->next;
 		}
 	    }
-	    /*
-	    * TODO: "exclude-result-prefixes"
-	    *   SPEC 1.0:
-	    *   "exclude-result-prefixes" is only allowed on literal
-	    *   result elements and "xsl:exclude-result-prefixes" only
-	    *   on xsl:stylesheet/xsl:transform.
-	    *   SPEC 2.0:
-	    *   "There are a number of standard attributes
-	    *   that may appear on any XSLT element: specifically version,
-	    *   exclude-result-prefixes, extension-element-prefixes,
-	    *   xpath-default-namespace, default-collation, and use-when."
-	    */
 	    if (IS_XSLT_ELEM(cur)) {
 		exclPrefixes = 0;
-#ifdef XSLT_REFACTORED
-		if ((cctxt->depth == 0) && (cur->nsDef != NULL)) {
-		    /*
-		    * In every case, we need the in-scope namespaces of the
-		    * element, where the stylesheet is rooted at.
-		    * Otherwise we need to pre-compute the in-scope namespaces
-		    * only if there's a new ns-decl.
-		    */
-		    cctxt->inode->inScopeNS =
-			xsltCompilerGetInScopeNSInfo(cctxt, cur);
-		}
-#endif		
 		xsltStylePreCompute(style, cur);
 		if (IS_XSLT_NAME(cur, "text")) {
 		    for (;exclPrefixes > 0;exclPrefixes--)
@@ -1498,25 +3293,9 @@
 		    goto skip_children;
 		}
 	    } else {
-#ifdef XSLT_REFACTORED
-		if (cctxt->depth == 0)
-		    cctxt->inode->inScopeNS =
-			xsltCompilerGetInScopeNSInfo(cctxt, cur);
-#endif
 		exclPrefixes = xsltParseStylesheetExcludePrefix(style, cur, 0);
 	    }
-
-	    /*
-	     * Remove excluded prefixes
-	     * TODO BUG:
-	     *   This will incorrectly apply excluded-result-prefixes
-	     *   of the including stylesheet to the included stylesheet.
-	     *   We need to localize the list of excluded-prefixes for
-	     *   every processed stylesheet.
-	     * SPEC 1.0: "a subtree rooted at an xsl:stylesheet element
-	     *   does not include any stylesheets imported or included by
-	     *   children of that xsl:stylesheet element."
-	     */
+	    	     
 	    if ((cur->nsDef != NULL) && (style->exclPrefixNr > 0)) {
 		xmlNsPtr ns = cur->nsDef, prev = NULL, next;
 		xmlNodePtr root = NULL;
@@ -1553,7 +3332,6 @@
 		    }
 		}
 	    }
-
 	    /*
 	     * If we have prefixes locally, recurse and pop them up when
 	     * going back
@@ -1564,11 +3342,10 @@
 		    exclPrefixPop(style);
 		goto skip_children;
 	    }
-
 	} else if (cur->type == XML_TEXT_NODE) {
 	    if (IS_BLANK_NODE(cur)) {
 		if (xmlNodeGetSpacePreserve(cur) != 1) {
-		    delete = cur;
+		    deleteNode = cur;
 		}
 	    } else if ((cur->content != NULL) && (internalize) &&
 	               (!xmlDictOwns(style->dict, cur->content))) {
@@ -1585,7 +3362,7 @@
 	    }
 	} else if ((cur->type != XML_ELEMENT_NODE) &&
 		   (cur->type != XML_CDATA_SECTION_NODE)) {
-	    delete = cur;
+	    deleteNode = cur;
 	    goto skip_children;
 	}
 
@@ -1600,12 +3377,6 @@
 		continue;
 	    }
 	}
-#ifdef XSLT_REFACTORED
-	if (cur->type == XML_ELEMENT_NODE) {
-	    /* Leaving the scope of an element-node. */
-	    xsltCompilerNodePop(cctxt, cur);
-	}
-#endif
 
 skip_children:
 	if (cur->next != NULL) {
@@ -1627,16 +3398,16 @@
 	    }
 	} while (cur != NULL);
     }
-    if (delete != NULL) {
+    if (deleteNode != NULL) {
 #ifdef WITH_XSLT_DEBUG_PARSING
 	xsltGenericDebug(xsltGenericDebugContext,
 	 "xsltPrecomputeStylesheet: removing ignorable blank node\n");
 #endif
-	xmlUnlinkNode(delete);
-	xmlFreeNode(delete);
-	delete = NULL;
+	xmlUnlinkNode(deleteNode);
+	xmlFreeNode(deleteNode);
     }
 }
+#endif /* end of else XSLT_REFACTORED */
 
 /**
  * xsltGatherNamespaces:
@@ -1729,16 +3500,1007 @@
     }
 }
 
+#ifdef XSLT_REFACTORED
+
+static xsltStyleType
+xsltGetXSLTElementTypeByNode(xsltCompilerCtxtPtr cctxt,
+			     xmlNodePtr node)
+{
+    if ((node == NULL) || (node->type != XML_ELEMENT_NODE) ||
+	(node->name == NULL))
+	return(0);
+
+    if (node->name[0] == 'a') {
+	if (IS_XSLT_NAME(node, "apply-templates"))
+	    return(XSLT_FUNC_APPLYTEMPLATES);
+	else if (IS_XSLT_NAME(node, "attribute"))
+	    return(XSLT_FUNC_ATTRIBUTE);
+	else if (IS_XSLT_NAME(node, "apply-imports"))
+	    return(XSLT_FUNC_APPLYIMPORTS);
+	else if (IS_XSLT_NAME(node, "attribute-set"))
+	    return(0);
+
+    } else if (node->name[0] == 'c') {
+	if (IS_XSLT_NAME(node, "choose"))
+	    return(XSLT_FUNC_CHOOSE);
+	else if (IS_XSLT_NAME(node, "copy"))
+	    return(XSLT_FUNC_COPY);
+	else if (IS_XSLT_NAME(node, "copy-of"))
+	    return(XSLT_FUNC_COPYOF);
+	else if (IS_XSLT_NAME(node, "call-template"))
+	    return(XSLT_FUNC_CALLTEMPLATE);
+	else if (IS_XSLT_NAME(node, "comment"))
+	    return(XSLT_FUNC_COMMENT);
+
+    } else if (node->name[0] == 'd') {
+	if (IS_XSLT_NAME(node, "document"))
+	    return(XSLT_FUNC_DOCUMENT);
+	else if (IS_XSLT_NAME(node, "decimal-format"))
+	    return(0);
+
+    } else if (node->name[0] == 'e') {
+	if (IS_XSLT_NAME(node, "element"))
+	    return(XSLT_FUNC_ELEMENT);
+
+    } else if (node->name[0] == 'f') {
+	if (IS_XSLT_NAME(node, "for-each"))
+	    return(XSLT_FUNC_FOREACH);
+	else if (IS_XSLT_NAME(node, "fallback"))
+	    return(XSLT_FUNC_FALLBACK);
+
+    } else if (*(node->name) == 'i') {
+	if (IS_XSLT_NAME(node, "if"))
+	    return(XSLT_FUNC_IF);
+	else if (IS_XSLT_NAME(node, "include"))
+	    return(0);
+	else if (IS_XSLT_NAME(node, "import"))
+	    return(0);
+
+    } else if (*(node->name) == 'k') {
+	if (IS_XSLT_NAME(node, "key"))
+	    return(0);
+
+    } else if (*(node->name) == 'm') {
+	if (IS_XSLT_NAME(node, "message"))
+	    return(XSLT_FUNC_MESSAGE);
+
+    } else if (*(node->name) == 'n') {
+	if (IS_XSLT_NAME(node, "number"))
+	    return(XSLT_FUNC_NUMBER);
+	else if (IS_XSLT_NAME(node, "namespace-alias"))
+	    return(0);
+
+    } else if (*(node->name) == 'o') {
+	if (IS_XSLT_NAME(node, "otherwise"))
+	    return(XSLT_FUNC_OTHERWISE);
+	else if (IS_XSLT_NAME(node, "output"))
+	    return(0);
+
+    } else if (*(node->name) == 'p') {
+	if (IS_XSLT_NAME(node, "param"))
+	    return(XSLT_FUNC_PARAM);
+	else if (IS_XSLT_NAME(node, "processing-instruction"))
+	    return(XSLT_FUNC_PI);
+	else if (IS_XSLT_NAME(node, "preserve-space"))
+	    return(0);
+
+    } else if (*(node->name) == 's') {
+	if (IS_XSLT_NAME(node, "sort"))
+	    return(XSLT_FUNC_SORT);
+	else if (IS_XSLT_NAME(node, "strip-space"))
+	    return(0);
+	else if (IS_XSLT_NAME(node, "stylesheet"))
+	    return(0);
+
+    } else if (node->name[0] == 't') {
+	if (IS_XSLT_NAME(node, "text"))
+	    return(XSLT_FUNC_TEXT);
+	else if (IS_XSLT_NAME(node, "template"))
+	    return(0);
+	else if (IS_XSLT_NAME(node, "transform"))
+	    return(0);
+
+    } else if (*(node->name) == 'v') {
+	if (IS_XSLT_NAME(node, "value-of"))
+	    return(XSLT_FUNC_VALUEOF);
+	else if (IS_XSLT_NAME(node, "variable"))
+	    return(XSLT_FUNC_VARIABLE);
+
+    } else if (*(node->name) == 'w') {
+	if (IS_XSLT_NAME(node, "when"))
+	    return(XSLT_FUNC_WHEN);
+	if (IS_XSLT_NAME(node, "with-param"))
+	    return(XSLT_FUNC_WITHPARAM);
+    }
+    return(0);
+}
+
+int
+xsltParseAnyXSLTElem(xsltCompilerCtxtPtr cctxt, xmlNodePtr elem)
+{
+    if ((cctxt == NULL) || (elem == NULL) ||
+	(elem->type != XML_ELEMENT_NODE))
+	return(-1);
+
+    elem->psvi = NULL;
+
+    if (! (IS_XSLT_ELEM_FAST(elem)))
+	return(-1);
+    /*
+    * Detection of handled content of extension instructions.
+    */
+    if (cctxt->inode->category == XSLT_ELEMENT_CATEGORY_EXTENSION) {
+	cctxt->inode->extContentHandled = 1;
+    }
+    
+    xsltCompilerNodePush(cctxt, elem);
+    /*
+    * URGENT TODO: Find a way to speed up this annoying redundant
+    *  textual node-name and namespace comparison.
+    */
+    if (cctxt->inode->prev->curChildType != 0)
+	cctxt->inode->type = cctxt->inode->prev->curChildType;
+    else
+	cctxt->inode->type = xsltGetXSLTElementTypeByNode(cctxt, elem);    
+    /*
+    * Update the in-scope namespaces if needed.
+    */
+    if (elem->nsDef != NULL)
+	cctxt->inode->inScopeNs =
+	    xsltCompilerBuildInScopeNsList(cctxt, elem);
+    /*
+    * xsltStylePreCompute(): Precompute the XSLT-instruction.
+    *  This will compile the information found on the current
+    *  element's attributes. NOTE that this won't process the
+    *  children of the current element.
+    */
+    xsltStylePreCompute(cctxt->style, elem);
+    /*
+    * Validate the content model of the XSLT-element.
+    */
+    switch (cctxt->inode->type) {	
+	case XSLT_FUNC_APPLYIMPORTS:
+	    /* EMPTY */
+	    goto empty_content;
+	case XSLT_FUNC_APPLYTEMPLATES:
+	    /* <!-- Content: (xsl:sort | xsl:with-param)* --> */
+	    goto apply_templates;	    
+	case XSLT_FUNC_ATTRIBUTE:	    
+	    /* <!-- Content: template --> */
+	    goto sequence_constructor;
+	case XSLT_FUNC_CALLTEMPLATE:
+	    /* <!-- Content: xsl:with-param* --> */
+	    goto call_template;
+	case XSLT_FUNC_CHOOSE:	    
+	    /* <!-- Content: (xsl:when+, xsl:otherwise?) --> */
+	    goto choose;
+	case XSLT_FUNC_COMMENT:
+	    /* <!-- Content: template --> */
+	    goto sequence_constructor;	    
+	case XSLT_FUNC_COPY:
+	    /* <!-- Content: template --> */
+	    goto sequence_constructor;	    
+	case XSLT_FUNC_COPYOF:
+	    /* EMPTY */
+	    goto empty_content;	   
+	case XSLT_FUNC_DOCUMENT: /* Extra one */
+	    /* ?? template ?? */
+	    goto sequence_constructor;
+	case XSLT_FUNC_ELEMENT:
+	    /* <!-- Content: template --> */
+	    goto sequence_constructor;
+	case XSLT_FUNC_FALLBACK:
+	    /* <!-- Content: template --> */
+	    goto sequence_constructor;
+	case XSLT_FUNC_FOREACH:
+	    /* <!-- Content: (xsl:sort*, template) --> */
+	    goto for_each;
+	case XSLT_FUNC_IF:
+	    /* <!-- Content: template --> */
+	    goto sequence_constructor;
+	case XSLT_FUNC_OTHERWISE:
+	    /* <!-- Content: template --> */
+	    goto sequence_constructor;
+	case XSLT_FUNC_MESSAGE:
+	    /* <!-- Content: template --> */
+	    goto sequence_constructor;
+	case XSLT_FUNC_NUMBER:
+	    /* EMPTY */
+	    goto empty_content;
+	case XSLT_FUNC_PARAM:
+	    /*  <!-- Content: template --> */
+	    goto sequence_constructor;
+	case XSLT_FUNC_PI:
+	    /*  <!-- Content: template --> */
+	    goto sequence_constructor;
+	case XSLT_FUNC_SORT:
+	    /* EMPTY */
+	    goto empty_content;
+	case XSLT_FUNC_TEXT:
+	    /* <!-- Content: #PCDATA --> */
+	    goto text;
+	case XSLT_FUNC_VALUEOF:
+	    /* EMPTY */
+	    goto empty_content;
+	case XSLT_FUNC_VARIABLE:
+	    /* <!-- Content: template --> */
+	    goto sequence_constructor;
+	case XSLT_FUNC_WHEN:
+	    /* <!-- Content: template --> */
+	    goto sequence_constructor;
+	case XSLT_FUNC_WITHPARAM:
+	    /* <!-- Content: template --> */
+	    goto sequence_constructor;
+	default:
+#ifdef WITH_XSLT_DEBUG_PARSING
+	    xsltGenericDebug(xsltGenericDebugContext,
+		"xsltParseXSLTNode: Unhandled XSLT element '%s'.\n",
+		elem->name);	    
+#endif
+	    xsltTransformError(NULL, cctxt->style, elem,
+		"xsltParseXSLTNode: Internal error; "
+		"unhandled XSLT element '%s'.\n", elem->name);
+	    cctxt->style->errors++;
+	    goto internal_err;
+    }
+
+apply_templates:
+    /* <!-- Content: (xsl:sort | xsl:with-param)* --> */
+    if (elem->children != NULL) {
+	xmlNodePtr child = elem->children;
+	do {
+	    if (child->type == XML_ELEMENT_NODE) {
+		if (IS_XSLT_ELEM_FAST(child)) {
+		    if (xmlStrEqual(child->name, BAD_CAST "with-param")) {
+			cctxt->inode->curChildType = XSLT_FUNC_WITHPARAM;
+			xsltParseAnyXSLTElem(cctxt, child);
+		    } else if (xmlStrEqual(child->name, BAD_CAST "sort")) {
+			cctxt->inode->curChildType = XSLT_FUNC_SORT;
+			xsltParseAnyXSLTElem(cctxt, child);
+		    } else
+			xsltParseContentError(cctxt->style, child);
+		} else
+		    xsltParseContentError(cctxt->style, child);
+	    }
+	    child = child->next;
+	} while (child != NULL);
+    }    
+    goto exit;
+
+call_template:
+    /* <!-- Content: xsl:with-param* --> */
+    if (elem->children != NULL) {
+	xmlNodePtr child = elem->children;
+	do {
+	    if (child->type == XML_ELEMENT_NODE) {
+		if (IS_XSLT_ELEM_FAST(child)) {
+		    xsltStyleType type;
+
+		    type = xsltGetXSLTElementTypeByNode(cctxt, child);
+		    if (type == XSLT_FUNC_WITHPARAM) {
+			cctxt->inode->curChildType = XSLT_FUNC_WITHPARAM;
+			xsltParseAnyXSLTElem(cctxt, child);
+		    } else {
+			xsltParseContentError(cctxt->style, child);
+		    }
+		} else
+		    xsltParseContentError(cctxt->style, child);
+	    }
+	    child = child->next;
+	} while (child != NULL);
+    }    
+    goto exit;
+
+text:
+    if (elem->children != NULL) {
+	xmlNodePtr child = elem->children;
+	do {
+	    if ((child->type != XML_TEXT_NODE) &&
+		(child->type != XML_CDATA_SECTION_NODE))
+	    {
+		xsltTransformError(NULL, cctxt->style, elem,
+		    "The XSLT 'text' element must have only character "
+		    "data as content.\n");
+	    }
+	    child = child->next;
+	} while (child != NULL);
+    }
+    goto exit;
+
+empty_content:
+    if (elem->children != NULL) {
+	xmlNodePtr child = elem->children;
+	/*
+	* Relaxed behaviour: we will allow whitespace-only text-nodes.
+	*/
+	do {
+	    if (((child->type != XML_TEXT_NODE) &&
+		 (child->type != XML_CDATA_SECTION_NODE)) ||
+		(! IS_BLANK_NODE(child)))
+	    {
+		xsltTransformError(NULL, cctxt->style, elem,
+		    "This XSLT element must have no content.\n");
+		cctxt->style->errors++;
+		break;
+	    }
+	    child = child->next;
+	} while (child != NULL);		
+    }
+    goto exit;
+
+choose:
+    /* <!-- Content: (xsl:when+, xsl:otherwise?) --> */
+    /*
+    * TODO: text-nodes in between are *not* allowed in XSLT 1.0.
+    *   The old behaviour did not check this.
+    * NOTE: In XSLT 2.0 they are stripped beforehand
+    *  if whitespace-only (regardless of xml:space).
+    */
+    if (elem->children != NULL) {
+	xmlNodePtr child = elem->children;
+	int nbWhen = 0, nbOtherwise = 0, err = 0;
+	do {
+	    if (child->type == XML_ELEMENT_NODE) {
+		if (IS_XSLT_ELEM_FAST(child)) {
+		    xsltStyleType type;
+		
+		    type = xsltGetXSLTElementTypeByNode(cctxt, child);
+		    if (type == XSLT_FUNC_WHEN) {
+			nbWhen++;
+			if (nbOtherwise) {
+			    xsltParseContentError(cctxt->style, child);
+			    err = 1;
+			    break;
+			}
+			cctxt->inode->curChildType = XSLT_FUNC_WHEN;
+			xsltParseAnyXSLTElem(cctxt, child);
+		    } else if (type == XSLT_FUNC_OTHERWISE) {
+			if (! nbWhen) {
+			    xsltParseContentError(cctxt->style, child);
+			    err = 1;
+			    break;
+			}			
+			if (nbOtherwise) {
+			    xsltTransformError(NULL, cctxt->style, elem,
+				"The XSLT 'choose' element must not contain "
+				"more than one XSLT 'otherwise' element.\n");
+			    cctxt->style->errors++;
+			    err = 1;
+			    break;
+			}
+			nbOtherwise++;
+			cctxt->inode->curChildType = XSLT_FUNC_OTHERWISE;
+			xsltParseAnyXSLTElem(cctxt, child);
+		    } else
+			xsltParseContentError(cctxt->style, child);
+		} else
+		    xsltParseContentError(cctxt->style, child);
+	    } 
+	    /*
+		else
+		    xsltParseContentError(cctxt, child);
+	    */
+	    child = child->next;
+	} while (child != NULL);
+	if ((! err) && (! nbWhen)) {
+	    xsltTransformError(NULL, cctxt->style, elem,
+		"The XSLT element 'choose' must contain at least one "
+		"XSLT element 'when'.\n");
+		cctxt->style->errors++;
+	}	
+    }    
+    goto exit;
+
+for_each:
+    /* <!-- Content: (xsl:sort*, template) --> */
+    /*
+    * NOTE: Text-nodes before xsl:sort are *not* allowed in XSLT 1.0.
+    *   The old behaviour did not allow this, but it catched this
+    *   only at transformation-time.
+    *   In XSLT 2.0 they are stripped beforehand if whitespace-only
+    *   (regardless of xml:space).
+    */
+    if (elem->children != NULL) {
+	xmlNodePtr child = elem->children;
+	/*
+	* Parse xsl:sort first.
+	*/
+	do {	    
+	    if ((child->type == XML_ELEMENT_NODE) &&
+		IS_XSLT_ELEM_FAST(child))
+	    {		
+		if (xsltGetXSLTElementTypeByNode(cctxt, child) ==
+		    XSLT_FUNC_SORT)
+		{		
+		    cctxt->inode->curChildType = XSLT_FUNC_SORT;
+		    xsltParseAnyXSLTElem(cctxt, child);
+		} else
+		    break;
+	    } else
+		break;
+	    child = child->next;
+	} while (child != NULL);
+	/*
+	* Parse the sequece constructor.
+	*/
+	if (child != NULL)
+	    xsltParseSequenceConstructor(cctxt, child);
+    }    
+    goto exit;
+
+sequence_constructor:
+    if (elem->children != NULL)
+	xsltParseSequenceConstructor(cctxt, elem->children);
+    
+exit:
+    xsltCompilerNodePop(cctxt, elem);
+    return(0);
+
+internal_err:
+    xsltCompilerNodePop(cctxt, elem);
+    return(-1);
+}
+
+static xsltStyleItemUknownPtr
+xsltForwardsCompatUnkownItemCreate(xsltCompilerCtxtPtr cctxt)
+{
+    xsltStyleItemUknownPtr item;
+
+    item = (xsltStyleItemUknownPtr) xmlMalloc(sizeof(xsltStyleItemUknown));
+    if (item == NULL) {
+	xsltTransformError(NULL, cctxt->style, NULL,
+	    "Internal error in xsltForwardsCompatUnkownItemCreate(): "
+	    "Failed to allocate memory.\n");
+	cctxt->style->errors++;
+	return(NULL);
+    }
+    memset(item, 0, sizeof(xsltStyleItemUknown));
+    item->type = XSLT_FUNC_UNKOWN_FORWARDS_COMPAT;
+    /*
+    * Store it in the stylesheet.
+    */
+    item->next = cctxt->style->preComps;
+    cctxt->style->preComps = (xsltElemPreCompPtr) item;
+    return(item);
+}
+
+static int
+xsltParseUnknownXSLTElem(xsltCompilerCtxtPtr cctxt,
+			    xmlNodePtr node)
+{
+    if ((cctxt == NULL) || (node == NULL))
+	return(-1);
+
+    /*
+    * Detection of handled content of extension instructions.
+    */
+    if (cctxt->inode->category == XSLT_ELEMENT_CATEGORY_EXTENSION) {
+	cctxt->inode->extContentHandled = 1;
+    }    
+    if (cctxt->inode->forwardsCompat == 0) {	
+	/*
+	* We are not in forwards-compatible mode, so raise an error.
+	*/
+	xsltTransformError(NULL, cctxt->style, node,
+	    "Unknown XSLT element '%s'.\n", node->name);
+	cctxt->style->errors++;
+	return(0);
+    }
+    /*
+    * Forwards-compatible mode.
+    * ------------------------
+    *    
+    * Parse/compile xsl:fallback elements.
+    *
+    * QUESTION: Do we have to raise an error if there's no xsl:fallback?
+    * ANSWER: No, since in the stylesheet the fallback behaviour might
+    *  also be provided by using the XSLT function "element-available".
+    */
+    if (cctxt->unknownItem == NULL) {
+	/*
+	* Create a singleton for all unknown XSLT instructions.
+	*/
+	cctxt->unknownItem = xsltForwardsCompatUnkownItemCreate(cctxt);
+	if (cctxt->unknownItem == NULL) {
+	    node->psvi = NULL;
+	    return(-1);
+	}
+    }
+    node->psvi = cctxt->unknownItem;
+    if (node->children == NULL)
+	return(0);
+    else {
+	xmlNodePtr child = node->children;
+
+	xsltCompilerNodePush(cctxt, node);
+	/*
+	* Update the in-scope namespaces if needed.
+	*/
+	if (node->nsDef != NULL)
+	    cctxt->inode->inScopeNs =
+		xsltCompilerBuildInScopeNsList(cctxt, node);
+	/*
+	* Parse all xsl:fallback children.
+	*/
+	do {
+	    if ((child->type == XML_ELEMENT_NODE) &&
+		IS_XSLT_ELEM_FAST(child) &&
+		IS_XSLT_NAME(child, "fallback"))
+	    {
+		cctxt->inode->curChildType = XSLT_FUNC_FALLBACK;
+		xsltParseAnyXSLTElem(cctxt, child);
+	    }
+	    child = child->next;
+	} while (child != NULL);
+	
+	xsltCompilerNodePop(cctxt, node);
+    }
+    return(0);
+}
 /**
+ * xsltParseSequenceConstructor:
+ *
+ * @cctxt: the compilation context
+ * @cur: the start-node of the content to be parsed
+ *
+ * Parses a "template" content (or "sequence constructor" in XSLT 2.0 terms).
+ * This will additionally remove xsl:text elements from the tree.
+ */ 
+void
+xsltParseSequenceConstructor(xsltCompilerCtxtPtr cctxt, xmlNodePtr cur)
+{
+    xsltStyleType type;
+    xmlNodePtr deleteNode = NULL;
+
+    if (cctxt == NULL) {
+	xmlGenericError(xmlGenericErrorContext,
+	    "xsltParseSequenceConstructor: Bad arguments\n");
+	cctxt->style->errors++;
+	return;
+    }
+    /*
+    * Detection of handled content of extension instructions.
+    */
+    if (cctxt->inode->category == XSLT_ELEMENT_CATEGORY_EXTENSION) {
+	cctxt->inode->extContentHandled = 1;
+    }
+    if (cur == NULL)
+	return;
+    /*
+    * This is the content reffered to as a "template".
+    * E.g. an xsl:element has such content model:
+    * <xsl:element
+    *   name = { qname }
+    *   namespace = { uri-reference }
+    *   use-attribute-sets = qnames>
+    * <!-- Content: template -->
+    *
+    * NOTE that in XSLT-2 the term "template" was abandoned due to
+    *  confusion with xsl:template and the term "sequence constructor"
+    *  was introduced instead.
+    *
+    * The following XSLT-instructions are allowed to appear:
+    *  xsl:apply-templates, xsl:call-template, xsl:apply-imports,
+    *  xsl:for-each, xsl:value-of, xsl:copy-of, xsl:number,
+    *  xsl:choose, xsl:if, xsl:text, xsl:copy, xsl:variable,
+    *  xsl:message, xsl:fallback,
+    *  xsl:processing-instruction, xsl:comment, xsl:element
+    *  xsl:attribute. 
+    * Additional allowed content:
+    * 1) extension instructions
+    * 2) literal result elements
+    * 3) PCDATA
+    *
+    * NOTE that this content model does *not* allow xsl:param.
+    */    
+    while (cur != NULL) {
+	if (deleteNode != NULL)	{
+#ifdef WITH_XSLT_DEBUG_BLANKS
+	    xsltGenericDebug(xsltGenericDebugContext,
+	     "xsltParseSequenceConstructor: removing xsl:text element\n");
+#endif
+	    xmlUnlinkNode(deleteNode);
+	    xmlFreeNode(deleteNode);
+	    deleteNode = NULL;
+	}
+	if (cur->type == XML_ELEMENT_NODE) {	    
+	    
+	    if (cur->psvi == xsltXSLTTextMarker) {
+		/*
+		* xsl:text elements
+		* --------------------------------------------------------
+		*/
+		xmlNodePtr tmp;
+
+		cur->psvi = NULL;
+		/*
+		* Mark the xsl:text element for later deletion.
+		*/
+		deleteNode = cur;
+		/*
+		* Validate content.
+		*/
+		tmp = cur->children;
+		if (tmp) {
+		    /*
+		    * We don't expect more than one text-node in the
+		    * content, since we already merged adjacent
+		    * text/CDATA-nodes and eliminated PI/comment-nodes.
+		    */
+		    if ((tmp->type == XML_TEXT_NODE) ||
+			(tmp->next == NULL))
+		    {
+			/*
+			* Leave the contained text-node in the tree.
+			*/
+			xmlUnlinkNode(tmp);
+			xmlAddPrevSibling(cur, tmp);
+		    } else {
+			tmp = NULL;
+			xsltTransformError(NULL, cctxt->style, cur,
+			    "Element 'xsl:text': Invalid type "
+			    "of node found in content.\n");
+			cctxt->style->errors++;
+		    } 
+		}
+		if (cur->properties) {
+		    xmlAttrPtr attr;
+		    /*
+		    * TODO: We need to report errors for
+		    *  invalid attrs.
+		    */
+		    attr = cur->properties;
+		    do {
+			if ((attr->ns == NULL) &&
+			    (attr->name != NULL) &&
+			    (attr->name[0] == 'd') &&
+			    xmlStrEqual(attr->name,
+			    BAD_CAST "disable-output-escaping"))
+			{
+			    /*
+			    * Attr "disable-output-escaping".
+			    * XSLT-2: This attribute is deprecated.
+			    */
+			    if ((attr->children != NULL) &&
+				xmlStrEqual(attr->children->content,
+				BAD_CAST "yes"))
+			    {
+				/*
+				* Disable output escaping for this
+				* text node.
+				*/
+				if (tmp)
+				    tmp->name = xmlStringTextNoenc;
+			    } else if ((attr->children == NULL) ||
+				(attr->children->content == NULL) ||
+				(!xmlStrEqual(attr->children->content,
+				BAD_CAST "no")))
+			    {
+				xsltTransformError(NULL, cctxt->style,
+				    cur,
+				    "Attribute 'disable-output-escaping': "
+				    "Invalid value. Expected is "
+				    "'yes' or 'no'.\n");
+				cctxt->style->errors++;
+			    }
+			    break;
+			}
+			attr = attr->next;
+		    } while (attr != NULL);
+		}
+	    } else if (IS_XSLT_ELEM_FAST(cur)) {
+		/*
+		* TODO: Using the XSLT-marker is still not stable yet.
+		*/
+		/* if (cur->psvi == xsltXSLTElemMarker) { */	    
+		/*
+		* XSLT instructions
+		* --------------------------------------------------------
+		*/
+		cur->psvi = NULL;
+		type = xsltGetXSLTElementTypeByNode(cctxt, cur);
+		switch (type) {
+		    case XSLT_FUNC_APPLYIMPORTS:
+		    case XSLT_FUNC_APPLYTEMPLATES:
+		    case XSLT_FUNC_ATTRIBUTE:
+		    case XSLT_FUNC_CALLTEMPLATE:
+		    case XSLT_FUNC_CHOOSE:
+		    case XSLT_FUNC_COMMENT:
+		    case XSLT_FUNC_COPY:
+		    case XSLT_FUNC_COPYOF:
+		    case XSLT_FUNC_DOCUMENT: /* Extra one */
+		    case XSLT_FUNC_ELEMENT:
+		    case XSLT_FUNC_FALLBACK:
+		    case XSLT_FUNC_FOREACH:
+		    case XSLT_FUNC_IF:
+		    case XSLT_FUNC_MESSAGE:
+		    case XSLT_FUNC_NUMBER:
+		    case XSLT_FUNC_PI:
+		    case XSLT_FUNC_TEXT:
+		    case XSLT_FUNC_VALUEOF:
+		    case XSLT_FUNC_VARIABLE:
+			/*
+			* Parse the XSLT element.
+			*/
+			cctxt->inode->curChildType = type;
+			xsltParseAnyXSLTElem(cctxt, cur);
+			break;
+		    default:
+			xsltParseUnknownXSLTElem(cctxt, cur);			
+			cur = cur->next;
+			continue;
+		}
+	    } else {
+		/*
+		* Non-XSLT elements
+		* -----------------
+		*/
+		xsltCompilerNodePush(cctxt, cur);
+		/*
+		* Update the in-scope namespaces if needed.
+		*/
+		if (cur->nsDef != NULL)
+		    cctxt->inode->inScopeNs =
+			xsltCompilerBuildInScopeNsList(cctxt, cur);
+		/*
+		* The current element is either a literal result element
+		* or an extension instruction.
+		*
+		* Process attr "xsl:extension-element-prefixes".
+		* FUTURE TODO: IIRC in XSLT 2.0 this attribute must be
+		* processed by the implementor of the extension function;
+		* i.e., it won't be handled by the XSLT processor.
+		*/
+		/* SPEC 1.0:
+		*   "exclude-result-prefixes" is only allowed on literal
+		*   result elements and "xsl:exclude-result-prefixes"
+		*   on xsl:stylesheet/xsl:transform.
+		* SPEC 2.0:
+		*   "There are a number of standard attributes
+		*   that may appear on any XSLT element: specifically
+		*   version, exclude-result-prefixes,
+		*   extension-element-prefixes, xpath-default-namespace,
+		*   default-collation, and use-when."
+		*
+		* SPEC 2.0:
+		*   For literal result elements:
+		*   "xsl:version, xsl:exclude-result-prefixes,
+		*    xsl:extension-element-prefixes,
+		*    xsl:xpath-default-namespace,
+		*    xsl:default-collation, or xsl:use-when."
+		*/
+		if (cur->properties)
+		    cctxt->inode->extElemNs =
+			xsltParseExtElemPrefixes(cctxt,
+			    cur, cctxt->inode->extElemNs,
+			    XSLT_ELEMENT_CATEGORY_LRE);
+		/*
+		* Eval if we have an extension instruction here.
+		*/
+		if ((cur->ns != NULL) &&
+		    (cctxt->inode->extElemNs != NULL) &&
+		    (xsltCheckExtPrefix(cctxt->style, cur->ns->href) == 1))
+		{
+		    /*
+		    * Extension instructions
+		    * ----------------------------------------------------
+		    * Mark the node information.
+		    */
+		    cctxt->inode->category = XSLT_ELEMENT_CATEGORY_EXTENSION;
+		    cctxt->inode->extContentHandled = 0;
+		    if (cur->psvi != NULL) {
+			cur->psvi = NULL;
+			/*
+			* TODO: Temporary sanity check.
+			*/
+			xsltTransformError(NULL, cctxt->style, cur,
+			    "Internal error in xsltParseSequenceConstructor(): "
+			    "Occupied PSVI field.\n");
+			cctxt->style->errors++;
+			cur = cur->next;
+			continue;
+		    }
+		    cur->psvi = (void *)
+			xsltPreComputeExtModuleElement(cctxt->style, cur);
+		    
+		    if (cur->psvi == NULL) {
+			/*
+			* OLD COMMENT: "Unknown element, maybe registered at the
+			*  context level. Mark it for later recognition."
+			* QUESTION: What does the xsltExtMarker mean?
+			*  ANSWER: It is used in xsltApplyOneTemplateInt() at
+			*   transformation-time to look out for extension
+			*   registered in the transformation context.
+			*/
+			cur->psvi = (void *) xsltExtMarker;
+		    }
+		    /*
+		    * BIG NOTE: Now the ugly part. In previous versions
+		    *  of Libxslt (until 1.1.16), all the content of an
+		    *  extension instruction was processed and compiled without
+		    *  the need of the extension-author to explicitely call
+		    *  such a processing;.We now need to mimic this old
+		    *  behaviour in order to avoid breaking old code
+		    *  on the extension-author's side.
+		    * The mechanism:
+		    *  1) If the author does *not* set the
+		    *    compile-time-flag @extContentHandled, then we'll
+		    *    parse the content assuming that it's a "template"
+		    *    (or "sequence constructor in XSLT 2.0 terms).
+		    *    NOTE: If the extension is registered at
+		    *    transformation-time only, then there's no way of
+		    *    knowing that content shall be valid, and we'll
+		    *    process the content the same way.
+		    *  2) If author *does* set the flag, then we'll assume
+		    *   that the author has handled the parsing him/herself
+		    *   (e.g. called xsltParseSequenceConstructor(), etc.
+		    *   explicitely in his/her code).
+		    */
+		    if ((cur->children != NULL) &&
+			(cctxt->inode->extContentHandled == 0))
+		    {
+			/*
+			* Default parsing of the content using the
+			* sequence-constructor model.
+			*/
+			xsltParseSequenceConstructor(cctxt, cur->children);
+		    }
+		} else {
+		    /*
+		    * Literal result element
+		    * ----------------------------------------------------
+		    * Allowed XSLT attributes:
+		    *  xsl:extension-element-prefixes CDATA #IMPLIED
+		    *  xsl:exclude-result-prefixes CDATA #IMPLIED
+		    *  TODO: xsl:use-attribute-sets %qnames; #IMPLIED
+		    *  xsl:version NMTOKEN #IMPLIED
+		    */
+		    cur->psvi = NULL;
+		    cctxt->inode->category = XSLT_ELEMENT_CATEGORY_LRE;
+		    if (cur->properties != NULL) {
+			/*
+			* Attribute "xsl:exclude-result-prefixes".
+			*/
+			cctxt->inode->exclResultNs =
+			    xsltParseExclResultPrefixes(cctxt, cur,
+				cctxt->inode->exclResultNs,
+				XSLT_ELEMENT_CATEGORY_LRE);
+			/*
+			* Attribute "xsl:version".
+			*/
+			xsltParseAttrXSLTVersion(cctxt, cur,
+			    XSLT_ELEMENT_CATEGORY_LRE);
+			/*
+			* Report invalid XSLT attributes.
+			*/
+			if (cur->properties) {
+			    xmlAttrPtr attr = cur->properties;
+
+			    do {
+				if (IS_XSLT_ATTR_FAST(attr) &&
+				    (! xmlStrEqual(attr->name,
+					BAD_CAST "use-attribute-sets")))
+				{				
+				    xsltTransformError(NULL, cctxt->style, cur,
+					"Unknown XSLT attribute '%s'.\n",
+					attr->name);				
+				     cctxt->style->errors++;
+				}
+				attr = attr->next;
+			    } while (attr != NULL);			    
+			}
+		    }
+		    /*
+		    * Create/reuse info for the literal result element.
+		    */
+		    if (cctxt->inode->nsChanged)
+			xsltLREInfoCreate(cctxt, cur, 1);
+		    cur->psvi = cctxt->inode->litResElemInfo;
+		    /*
+		    * Apply ns-aliasing on the element and on its attributes.
+		    */
+		    if (cctxt->hasNsAliases)
+			xsltLREBuildEffectiveNs(cctxt, cur);
+		    /*
+		    * Compile attribute value templates (AVT).
+		    */
+		    if (cur->properties) {
+			xmlAttrPtr attr = cur->properties;
+			
+			while (attr != NULL) {
+			    xsltCompileAttr(cctxt->style, attr);
+			    attr = attr->next;
+			}
+		    }
+		    /*
+		    * Parse the content, which is defined to be a "template"
+		    * (or "sequence constructor" in XSLT 2.0 terms).
+		    */
+		    if (cur->children != NULL) {
+			xsltParseSequenceConstructor(cctxt, cur->children);
+		    }
+		}
+		/*
+		* Leave the non-XSLT element.
+		*/
+		xsltCompilerNodePop(cctxt, cur);
+	    }
+	}
+	cur = cur->next;
+    }
+    if (deleteNode != NULL) {
+#ifdef WITH_XSLT_DEBUG_BLANKS
+	xsltGenericDebug(xsltGenericDebugContext,
+	    "xsltParseSequenceConstructor: removing xsl:text element\n");
+#endif
+	xmlUnlinkNode(deleteNode);
+	xmlFreeNode(deleteNode);
+	deleteNode = NULL;
+    }
+}
+
+/**
  * xsltParseTemplateContent:
  * @style:  the XSLT stylesheet
+ * @templ:  the node containing the content to be parsed
+ *
+ * Parses and compiles the content-model of an xsl:template element.
+ * Note that this is *not* the "template" (or "sequence constructor"
+ *  in XSLT 2.0) content model. Since it allows addional xsl:param
+ *  elements as immediate children of @templ.
+ *
+ * Called by: 
+ *   exsltFuncFunctionComp() (EXSLT, functions.c)
+ *   So this is intended to be called from extension functions.
+ */
+void
+xsltParseTemplateContent(xsltStylesheetPtr style, xmlNodePtr templ) {
+    if ((style == NULL) || (templ == NULL))
+	return;
+
+    /*
+    * Detection of handled content of extension instructions.
+    */
+    if (XSLT_CCTXT(style)->inode->category == XSLT_ELEMENT_CATEGORY_EXTENSION) {
+	XSLT_CCTXT(style)->inode->extContentHandled = 1;
+    }
+
+    if (templ->children != NULL) {	
+	xmlNodePtr child = templ->children;
+	/*
+	* Process xsl:param elements, which can only occur as the
+	* immediate children of xsl:template (well, and of any
+	* user-defined extension instruction if needed).
+	*/	
+	do {
+	    if ((child->type == XML_ELEMENT_NODE) &&
+		IS_XSLT_ELEM_FAST(child) &&
+		IS_XSLT_NAME(child, "param"))
+	    {
+		XSLT_CCTXT(style)->inode->curChildType = XSLT_FUNC_PARAM;
+		xsltParseAnyXSLTElem(XSLT_CCTXT(style), child);
+	    } else
+		break;
+	    child = child->next;
+	} while (child != NULL);
+	/*
+	* Parse the content and register the pattern.
+	*/
+	xsltParseSequenceConstructor(XSLT_CCTXT(style), child);
+    }
+}
+
+#else /* XSLT_REFACTORED */
+
+/**
+ * xsltParseTemplateContent:
+ * @style:  the XSLT stylesheet
  * @templ:  the container node (can be a document for literal results)
  *
  * parse a template content-model
  * Clean-up the template content from unwanted ignorable blank nodes
  * and process xslt:text
  */
-
 void
 xsltParseTemplateContent(xsltStylesheetPtr style, xmlNodePtr templ) {
     xmlNodePtr cur, delete;
@@ -1761,6 +4523,13 @@
 	}
 	if (IS_XSLT_ELEM(cur)) {
 	    if (IS_XSLT_NAME(cur, "text")) {
+		/*
+		* TODO: Processing of xsl:text should be moved to
+		*   xsltPrecomputeStylesheet(), since otherwise this
+		*   will be performed for every multiply included
+		*   stylesheet; i.e. this here is not skipped with
+		*   the use of the style->nopreproc flag.
+		*/
 		if (cur->children != NULL) {
 		    xmlChar *prop;
 		    xmlNodePtr text = cur->children, next;
@@ -1809,7 +4578,8 @@
 		    if (text == NULL) {
 			text = cur->children;
 			while (text != NULL) {
-			    if ((text->content != NULL) &&
+			    if ((style->internalized) &&
+			        (text->content != NULL) &&
 			        (!xmlDictOwns(style->dict, text->content))) {
 
 				/*
@@ -1837,8 +4607,10 @@
 		delete = cur;
 		goto skip_children;
 	    }
-	} else if ((cur->ns != NULL) && (style->nsDefs != NULL) &&
-	           (xsltCheckExtPrefix(style, cur->ns->prefix))) {
+	}
+	else if ((cur->ns != NULL) && (style->nsDefs != NULL) &&
+	    (xsltCheckExtPrefix(style, cur->ns->prefix)))
+	{
 	    /*
 	     * okay this is an extension element compile it too
 	     */
@@ -1862,7 +4634,6 @@
 		}
 	    }
 	}
-
 	/*
 	 * Skip to next node
 	 */
@@ -1930,6 +4701,8 @@
     }
 }
 
+#endif /* else XSLT_REFACTORED */
+
 /**
  * xsltParseStylesheetKey:
  * @style:  the XSLT stylesheet
@@ -1949,7 +4722,7 @@
     xmlChar *name = NULL;
     xmlChar *nameURI = NULL;
 
-    if (key == NULL)
+    if ((style == NULL) || (key == NULL))
 	return;
 
     /*
@@ -2010,9 +4783,235 @@
 	xmlFree(name);
     if (nameURI != NULL)
 	xmlFree(nameURI);
+
+    if (key->children != NULL) {
+	xsltParseContentError(style, key->children);
+    }
 }
 
+#ifdef XSLT_REFACTORED
 /**
+ * xsltParseXSLTTemplate:
+ * @style:  the XSLT stylesheet
+ * @template:  the "template" element
+ *
+ * parse an XSLT stylesheet template building the associated structures
+ * TODO: Is @style ever expected to be NULL?
+ *
+ * Called from:
+ *   xsltParseXSLTStylesheet()
+ *   xsltParseStylesheetTop()
+ */
+
+static void
+xsltParseXSLTTemplate(xsltCompilerCtxtPtr cctxt, xmlNodePtr templNode) {
+    xsltTemplatePtr templ;
+    xmlChar *prop;    
+    double  priority;    
+
+    if ((cctxt == NULL) || (templNode == NULL))
+	return;
+
+    /*
+     * Create and link the structure
+     */
+    templ = xsltNewTemplate();
+    if (templ == NULL)
+	return;
+
+    xsltCompilerNodePush(cctxt, templNode);
+    if (templNode->nsDef != NULL)
+	cctxt->inode->inScopeNs =
+	    xsltCompilerBuildInScopeNsList(cctxt, templNode);
+
+    templ->next = cctxt->style->templates;
+    cctxt->style->templates = templ;
+    templ->style = cctxt->style;
+   
+
+    /*
+    * Get inherited namespaces.
+    */
+    if (cctxt->inode->inScopeNs != NULL) {
+	int i, j;
+	xmlNsPtr ns;
+	xsltPointerListPtr extElemNs = cctxt->inode->extElemNs;
+	xsltPointerListPtr exclResultNs = cctxt->inode->exclResultNs;
+	xsltNsListContainerPtr inScopeNs = cctxt->inode->inScopeNs;
+
+	for (i = 0; i < inScopeNs->number; i++) {
+	    ns = inScopeNs->list[i];
+	    /*
+	    * Exclude the XSLT namespace.
+	    */
+	    if (xmlStrEqual(ns->href, XSLT_NAMESPACE))
+		goto skip_ns;
+	    /*
+	    * Exclude excluded result namespaces.
+	    */
+	    if (exclResultNs) {
+		for (j = 0; j < exclResultNs->number; j++)
+		    if (xmlStrEqual(ns->href, BAD_CAST exclResultNs->items[j]))
+			goto skip_ns;		
+	    }
+	    /*
+	    * Exclude extension-element namespaces.
+	    */
+	    if (extElemNs) {
+		for (j = 0; j < extElemNs->number; j++)
+		    if (xmlStrEqual(ns->href, BAD_CAST extElemNs->items[j]))
+			goto skip_ns;
+	    }
+	    /*
+	    * Add the xmlNs item.
+	    */
+	    if (templ->inheritedNs == NULL) {
+		templ->inheritedNs = (xmlNsPtr *) xmlMalloc(
+		    inScopeNs->number * sizeof(xmlNsPtr));
+		if (templ->inheritedNs == NULL) {
+		    xmlGenericError(xmlGenericErrorContext,
+			"xsltGetInheritedNsList : out of memory!\n");
+		    cctxt->style->errors++;
+		    goto error;
+		}
+		memset(templ->inheritedNs, 0,
+		    inScopeNs->number * sizeof(xmlNsPtr));
+	    }
+	    templ->inheritedNs[templ->inheritedNsNr++] = ns;
+skip_ns:
+	    {}
+	}	
+#ifdef WITH_XSLT_DEBUG_PARSING
+	if (templ->inheritedNsNr != 0) {
+	    xsltGenericDebug(xsltGenericDebugContext,
+		"xsl:template has %d inherited namespaces\n",
+		templ->inheritedNsNr);
+	}
+#endif
+    }
+
+    /*
+    * Attribute "mode".
+    */
+    prop = xmlGetNsProp(templNode, (const xmlChar *)"mode", NULL);
+    if (prop != NULL) {	
+        const xmlChar *modeURI;
+
+	/*
+	* TODO: We need a standardized function for extraction
+	*  of namespace names and local names from QNames.
+	*/
+	modeURI = xsltGetQNameURI(templNode, &prop);
+	if (prop == NULL) {
+	    cctxt->style->errors++;
+	    goto error;
+	}
+	templ->mode = xmlDictLookup(cctxt->style->dict, prop, -1);
+	xmlFree(prop);
+	prop = NULL;
+	if (xmlValidateNCName(templ->mode, 0)) {
+	    xsltTransformError(NULL, cctxt->style, templNode,
+		"xsl:template: Attribute 'mode': The local part '%s' "
+		"of the value is not a valid NCName.\n", templ->name);
+	    cctxt->style->errors++;
+	    goto error;
+	}
+	if (modeURI != NULL)
+	    templ->modeURI = xmlDictLookup(cctxt->style->dict, modeURI, -1);
+#ifdef WITH_XSLT_DEBUG_PARSING
+	xsltGenericDebug(xsltGenericDebugContext,
+	     "xsltParseXSLTTemplate: mode %s\n", templ->mode);
+#endif
+    }
+    /*
+    * Attribute "match".
+    */
+    prop = xmlGetNsProp(templNode, (const xmlChar *)"match", NULL);
+    if (prop != NULL) {
+	templ->match  = prop;
+	prop = NULL;
+    }
+    /*
+    * Attribute "priority".
+    */
+    prop = xmlGetNsProp(templNode, (const xmlChar *)"priority", NULL);
+    if (prop != NULL) {
+	priority = xmlXPathStringEvalNumber(prop);
+	templ->priority = (float) priority;
+	xmlFree(prop);
+	prop = NULL;
+    }
+    /*
+    * Attribute "name".
+    */
+    prop = xmlGetNsProp(templNode, (const xmlChar *)"name", NULL);
+    if (prop != NULL) {
+        const xmlChar *nameURI;
+	xsltTemplatePtr curTempl;
+	
+	nameURI = xsltGetQNameURI(templNode, &prop);
+	if (prop == NULL) {
+	    cctxt->style->errors++;
+	    goto error;
+	}
+	templ->name = xmlDictLookup(cctxt->style->dict, prop, -1);
+	xmlFree(prop);
+	prop = NULL;
+	if (xmlValidateNCName(templ->name, 0)) {
+	    xsltTransformError(NULL, cctxt->style, templNode,
+		"xsl:template: Attribute 'name': The local part '%s' of "
+		"the value is not a valid NCName.\n", templ->name);
+	    cctxt->style->errors++;
+	    goto error;
+	} 	
+	if (nameURI != NULL)
+	    templ->nameURI = xmlDictLookup(cctxt->style->dict, nameURI, -1);
+	curTempl = templ->next;
+	while (curTempl != NULL) {
+	    if ((nameURI != NULL && xmlStrEqual(curTempl->name, templ->name) &&
+		xmlStrEqual(curTempl->nameURI, nameURI) ) ||
+		(nameURI == NULL && curTempl->nameURI == NULL &&
+		xmlStrEqual(curTempl->name, templ->name)))
+	    {
+		xsltTransformError(NULL, cctxt->style, templNode,
+		    "xsl:template: error duplicate name '%s'\n", templ->name);
+		cctxt->style->errors++;
+		goto error;
+	    }
+	    curTempl = curTempl->next;
+	}
+    }
+    if (templNode->children != NULL) {
+	xsltParseTemplateContent(cctxt->style, templNode);	
+	/*
+	* MAYBE TODO: Custom behaviour: In order to stay compatible with
+	* Xalan and MSXML(.NET), we could allow whitespace
+	* to appear before an xml:param element; this whitespace
+	* will additionally become part of the "template".
+	* NOTE that this is totally deviates from the spec, but
+	* is the de facto behaviour of Xalan and MSXML(.NET).
+	* Personally I wouldn't allow this, since if we have:
+	* <xsl:template ...xml:space="preserve">
+	*   <xsl:param name="foo"/>
+	*   <xsl:param name="bar"/>
+	*   <xsl:param name="zoo"/>
+	* ... the whitespace between every xsl:param would be
+	* added to the result tree.
+	*/		
+    }    
+    
+    templ->elem = templNode;
+    templ->content = templNode->children;
+    xsltAddTemplate(cctxt->style, templ, templ->mode, templ->modeURI);
+
+error:
+    xsltCompilerNodePop(cctxt, templNode);
+    return;
+}
+
+#else /* XSLT_REFACTORED */
+
+/**
  * xsltParseStylesheetTemplate:
  * @style:  the XSLT stylesheet
  * @template:  the "template" element
@@ -2092,16 +5091,7 @@
     if (prop != NULL) {
         const xmlChar *URI;
 	xsltTemplatePtr cur;
-
-	if (ret->name != NULL) {
-	    xmlFree(ret->name);
-	    ret->name = NULL;
-	}
-	if (ret->nameURI != NULL) {
-	    xmlFree(ret->nameURI);
-	    ret->nameURI = NULL;
-	}
-
+	
 	URI = xsltGetQNameURI(template, &prop);
 	if (prop == NULL) {
 	    if (style != NULL) style->errors++;
@@ -2112,20 +5102,22 @@
 	            "xsl:template : error invalid name '%s'\n", prop);
 		if (style != NULL) style->errors++;
 		goto error;
-	    } 
-	    ret->name = prop;
+	    }
+	    ret->name = xmlDictLookup(style->dict, BAD_CAST prop, -1);
+	    xmlFree(prop);
+	    prop = NULL;
 	    if (URI != NULL)
-		ret->nameURI = xmlStrdup(URI);
+		ret->nameURI = xmlDictLookup(style->dict, BAD_CAST URI, -1);
 	    else
 		ret->nameURI = NULL;
 	    cur = ret->next;
 	    while (cur != NULL) {
-	        if ((URI != NULL && xmlStrEqual(cur->name, prop) &&
+	        if ((URI != NULL && xmlStrEqual(cur->name, ret->name) &&
 				xmlStrEqual(cur->nameURI, URI) ) ||
 		    (URI == NULL && cur->nameURI == NULL &&
-				xmlStrEqual(cur->name, prop))) {
+				xmlStrEqual(cur->name, ret->name))) {
 		    xsltTransformError(NULL, style, template,
-		        "xsl:template: error duplicate name '%s'\n", prop);
+		        "xsl:template: error duplicate name '%s'\n", ret->name);
 		    style->errors++;
 		    goto error;
 		}
@@ -2146,87 +5138,615 @@
     return;
 }
 
-#ifdef XSLT_REFACTORED_PARSING
-/*
-* xsltParseStylesheetTreeNew:
-*
-* Parses and compiles an XSLT stylesheet's XML tree.
-*
-* TODO: Adjust error report text.
-*/
+#endif /* else XSLT_REFACTORED */
+
+#ifdef XSLT_REFACTORED
+
+/**
+ * xsltIncludeComp:
+ * @cctxt: the compilation contenxt
+ * @node:  the xsl:include node
+ *
+ * Process the xslt include node on the source node
+ */
+static xsltStyleItemIncludePtr
+xsltCompileXSLTIncludeElem(xsltCompilerCtxtPtr cctxt, xmlNodePtr node) {
+    xsltStyleItemIncludePtr item;
+
+    if ((cctxt == NULL) || (node == NULL))
+	return(NULL);
+
+    node->psvi = NULL;
+    item = (xsltStyleItemIncludePtr) xmlMalloc(sizeof(xsltStyleItemInclude));
+    if (item == NULL) {
+	xsltTransformError(NULL, cctxt->style, node,
+		"xsltIncludeComp : malloc failed\n");
+	cctxt->style->errors++;
+	return(NULL);
+    }
+    memset(item, 0, sizeof(xsltStyleItemInclude));
+
+    node->psvi = item;
+    item->inst = node;
+    item->type = XSLT_FUNC_INCLUDE;
+
+    item->next = cctxt->style->preComps;
+    cctxt->style->preComps = (xsltElemPreCompPtr) item;
+
+    return(item);
+}
+
+/**
+ * xsltParseFindTopLevelElem:
+ */
 static int
-xsltParseStylesheetTreeNew(xsltStylesheetPtr sheet, xmlNodePtr cur)
+xsltParseFindTopLevelElem(xsltCompilerCtxtPtr cctxt,
+			      xmlNodePtr cur,
+			      const xmlChar *name,
+			      const xmlChar *namespaceURI,
+			      int breakOnOtherElem,			      
+			      xmlNodePtr *resultNode)
 {
-    xsltCompilerCtxtPtr cctxt;
-    xmlNodePtr top = cur;
-    int depth = 0, simpleSyntax = 0;
-
-    if ((cur == NULL) || (cur->type != XML_ELEMENT_NODE) ||
-	(sheet == NULL) || (sheet->compCtxt == NULL))
+    if (name == NULL)
 	return(-1);
-    cctxt = (xsltCompilerCtxtPtr) sheet->compCtxt;
 
+    *resultNode = NULL;
+    while (cur != NULL) {
+	if (cur->type == XML_ELEMENT_NODE) {
+	    if ((cur->ns != NULL) && (cur->name != NULL)) {
+		if ((*(cur->name) == *name) &&
+		    xmlStrEqual(cur->name, name) &&
+		    xmlStrEqual(cur->ns->href, namespaceURI))		    
+		{
+		    *resultNode = cur;
+		    return(1);
+		}
+	    }
+	    if (breakOnOtherElem)
+		break;
+	}
+	cur = cur->next;
+    }
+    *resultNode = cur;
+    return(0);
+}
+
+static int
+xsltParseTopLevelXSLTElem(xsltCompilerCtxtPtr cctxt,
+			  xmlNodePtr node,
+			  xsltStyleType type)
+{
+    int ret = 0;
+
     /*
-    * Evalute if we have a simplified syntax.
+    * TODO: The reason why this function exists:
+    *  due to historical reasons some of the
+    *  top-level declarations are processed by functions
+    *  in other files. Since we need still to set
+    *  up the node-info and generate information like
+    *  in-scope namespaces, this is a wrapper around
+    *  those old parsing functions.
     */
-    if ((IS_XSLT_ELEM(cur)) && 
-	((IS_XSLT_NAME(cur, "stylesheet")) ||
-	 (IS_XSLT_NAME(cur, "transform"))))
-    {	
+    xsltCompilerNodePush(cctxt, node);
+    if (node->nsDef != NULL)
+	cctxt->inode->inScopeNs =
+	    xsltCompilerBuildInScopeNsList(cctxt, node);
+    cctxt->inode->type = type;
+
+    switch (type) {
+	case XSLT_FUNC_INCLUDE:
+	    {
+		int oldIsInclude;
+
+		if (xsltCompileXSLTIncludeElem(cctxt, node) == NULL)
+		    goto exit;		
+		/*
+		* Mark this stylesheet tree as being currently included.
+		*/
+		oldIsInclude = cctxt->isInclude;
+		cctxt->isInclude = 1;
+						
+		if (xsltParseStylesheetInclude(cctxt->style, node) != 0) {
+		    cctxt->style->errors++;
+		}
+		cctxt->isInclude = oldIsInclude;
+	    }
+	    break;
+	case XSLT_FUNC_PARAM:
+	    xsltStylePreCompute(cctxt->style, node);
+	    xsltParseGlobalParam(cctxt->style, node);
+	    break;
+	case XSLT_FUNC_VARIABLE:
+	    xsltStylePreCompute(cctxt->style, node);
+	    xsltParseGlobalVariable(cctxt->style, node);
+	    break;
+	case XSLT_FUNC_ATTRSET:
+	    xsltParseStylesheetAttributeSet(cctxt->style, node);
+	    break;
+	default:
+	    xsltTransformError(NULL, cctxt->style, node,
+		"Internal error: (xsltParseTopLevelXSLTElem) "
+		"Cannot handle this top-level declaration.\n");
+	    cctxt->style->errors++;
+	    ret = -1;
+    }
+
+exit:
+    xsltCompilerNodePop(cctxt, node);
+
+    return(ret);
+}
+
+#if 0
+static int
+xsltParseRemoveWhitespace(xmlNodePtr node)
+{
+    if ((node == NULL) || (node->children == NULL))
+	return(0);
+    else {
+	xmlNodePtr delNode = NULL, child = node->children;
+
+	do {
+	    if (delNode) {
+		xmlUnlinkNode(delNode);
+		xmlFreeNode(delNode);
+		delNode = NULL;
+	    }
+	    if (((child->type == XML_TEXT_NODE) ||
+		 (child->type == XML_CDATA_SECTION_NODE)) &&
+		(IS_BLANK_NODE(child)))
+		delNode = child;	    
+	    child = child->next;
+	} while (child != NULL);
+	if (delNode) {
+	    xmlUnlinkNode(delNode);
+	    xmlFreeNode(delNode);
+	    delNode = NULL;
+	}
+    }
+    return(0);
+}
+#endif
+
+static int
+xsltParseXSLTStylesheetElemCore(xsltCompilerCtxtPtr cctxt, xmlNodePtr node)
+{
 #ifdef WITH_XSLT_DEBUG_PARSING
-	xsltGenericDebug(xsltGenericDebugContext,
-		"xsltParseStylesheetProcess : found stylesheet\n");
+    int templates = 0;
 #endif
+    xmlNodePtr cur, start = NULL;
+    xsltStylesheetPtr style;
+
+    if ((cctxt == NULL) || (node == NULL) ||
+	(node->type != XML_ELEMENT_NODE))
+	return(-1);    
+
+    style = cctxt->style;    
+    /*
+    * At this stage all import declarations of all stylesheet modules
+    * with the same stylesheet level have been processed.
+    * Now we can safely parse the rest of the declarations.
+    */
+    if (IS_XSLT_ELEM_FAST(node) && IS_XSLT_NAME(node, "include"))
+    {
+	xsltDocumentPtr include;
 	/*
-	* TODO: Initialize.
+	* URGENT TODO: Make this work with simplified stylesheets!
+	*   I.e., when we won't find an xsl:stylesheet element.
 	*/
-    } else {
-	simpleSyntax = 1;	
 	/*
-	* TODO: Create the initial template.
-	* TODO: Initialize.
+	* This is as include declaration.
 	*/
-    }        
+	include = ((xsltStyleItemIncludePtr) node->psvi)->include;
+	if (include == NULL) {
+	    /* TODO: raise error? */
+	    return(-1);
+	}
+	/*
+	* TODO: Actually an xsl:include should locate an embedded
+	*  stylesheet as well; so the document-element won't always
+	*  be the element where the actual stylesheet is rooted at.
+	*  But such embedded stylesheets are not supported by Libxslt yet.
+	*/
+	node = xmlDocGetRootElement(include->doc);
+	if (node == NULL) {
+	    return(-1);
+	}
+    }    
+    
+    if (node->children == NULL)
+	return(0);
     /*
-    * Reset the compiler context.
+    * Push the xsl:stylesheet/xsl:transform element.
+    */  
+    xsltCompilerNodePush(cctxt, node);
+    cctxt->inode->isRoot = 1;
+    cctxt->inode->nsChanged = 0;
+    /*
+    * Start with the naked dummy info for literal result elements.
     */
-    cctxt->depth = 0;
-    cctxt->inode = NULL;
+    cctxt->inode->litResElemInfo = cctxt->inodeList->litResElemInfo;
+
     /*
-    * Initialize the in-scope namespaces. We need to have
-    * the in-scope ns-decls of the first given node, regardless
-    * if it's a XSLT instruction or a literal result element.
+    * In every case, we need to have
+    * the in-scope namespaces of the element, where the
+    * stylesheet is rooted at, regardless if it's an XSLT
+    * instruction or a literal result instruction (or if
+    * this is an embedded stylesheet).
+    */		
+    cctxt->inode->inScopeNs =
+	xsltCompilerBuildInScopeNsList(cctxt, node);
+
+    /*
+    * Process attributes of xsl:stylesheet/xsl:transform.
+    * --------------------------------------------------
+    * Allowed are:
+    *  id = id
+    *  extension-element-prefixes = tokens
+    *  exclude-result-prefixes = tokens
+    *  version = number (mandatory)    
     */
-    xsltCompilerNodePush(cctxt, cur);
-    xsltCompilerGetInScopeNSInfo(cctxt, cur);
-    goto next_sibling;
-
+    if (xsltParseAttrXSLTVersion(cctxt, node,
+	XSLT_ELEMENT_CATEGORY_XSLT) == 0)
+    {    
+	/*
+	* Attribute "version".
+	* XSLT 1.0: "An xsl:stylesheet element *must* have a version
+	*  attribute, indicating the version of XSLT that the
+	*  stylesheet requires".
+	* The root element of a simplified stylesheet must also have
+	* this attribute.
+	*/
+#ifdef XSLT_REFACTORED_MANDATORY_VERSION
+	if (isXsltElem)
+	    xsltTransformError(NULL, cctxt->style, node,
+		"The attribute 'version' is missing.\n");
+	cctxt->style->errors++;	
+#else
+	/* OLD behaviour. */
+	xsltTransformError(NULL, cctxt->style, node,
+	    "xsl:version is missing: document may not be a stylesheet\n");
+	cctxt->style->warnings++;
+#endif
+    }    
+    /*
+    * The namespaces declared by the attributes
+    *  "extension-element-prefixes" and
+    *  "exclude-result-prefixes" are local to *this*
+    *  stylesheet tree; i.e., they are *not* visible to
+    *  other stylesheet-modules, whether imported or included.
+    * 
+    * Attribute "extension-element-prefixes".
+    */
+    cctxt->inode->extElemNs =
+	xsltParseExtElemPrefixes(cctxt, node, NULL,
+	    XSLT_ELEMENT_CATEGORY_XSLT);
+    /*
+    * Attribute "exclude-result-prefixes".
+    */
+    cctxt->inode->exclResultNs =
+	xsltParseExclResultPrefixes(cctxt, node, NULL,
+	    XSLT_ELEMENT_CATEGORY_XSLT);
+    /*
+    * Create/reuse info for the literal result element.
+    */
+    if (cctxt->inode->nsChanged)
+	xsltLREInfoCreate(cctxt, node, 0);
+    /*
+    * Processed top-level elements:
+    * ----------------------------
+    *  xsl:variable, xsl:param (QName, in-scope ns,
+    *    expression (vars allowed))
+    *  xsl:attribute-set (QName, in-scope ns)
+    *  xsl:strip-space, xsl:preserve-space (XPath NameTests,
+    *    in-scope ns)
+    *    I *think* global scope, merge with includes
+    *  xsl:output (QName, in-scope ns)
+    *  xsl:key (QName, in-scope ns, pattern,
+    *    expression (vars *not* allowed))
+    *  xsl:decimal-format (QName, needs in-scope ns)
+    *  xsl:namespace-alias (in-scope ns)
+    *    global scope, merge with includes
+    *  xsl:template (last, QName, pattern)
+    *
+    * (whitespace-only text-nodes have *not* been removed
+    *  yet; this will be done in xsltParseSequenceConstructor)
+    *
+    * Report misplaced child-nodes first.
+    */
+    cur = node->children;
     while (cur != NULL) {
-	if (cur->type == XML_ELEMENT_NODE) {
-	    
+	if (cur->type == XML_TEXT_NODE) {
+	    xsltTransformError(NULL, style, cur,
+		"Misplaced text node (content: '%s').\n",
+		(cur->content != NULL) ? cur->content : BAD_CAST "");
+	    style->errors++;
+	} else if (cur->type != XML_ELEMENT_NODE) {
+	    xsltTransformError(NULL, style, cur, "Misplaced node.\n");
+	    style->errors++;
 	}
+	cur = cur->next;
+    }
+    /*
+    * Skip xsl:import elements; they have been processed
+    * already.
+    */
+    cur = node->children;
+    while ((cur != NULL) && xsltParseFindTopLevelElem(cctxt, cur,
+	    BAD_CAST "import", XSLT_NAMESPACE, 1, &cur) == 1)
+	cur = cur->next;
+    if (cur == NULL)
+	goto exit;
 
-next_sibling:
-	if (cur->type == XML_ELEMENT_NODE) {
+    start = cur;
+    /*
+    * Process all top-level xsl:param elements.
+    */
+    while ((cur != NULL) &&
+	xsltParseFindTopLevelElem(cctxt, cur,
+	BAD_CAST "param", XSLT_NAMESPACE, 0, &cur) == 1)
+    {
+	xsltParseTopLevelXSLTElem(cctxt, cur, XSLT_FUNC_PARAM);	
+	cur = cur->next;
+    }  
+    /*
+    * Process all top-level xsl:variable elements.
+    */
+    cur = start;
+    while ((cur != NULL) &&
+	xsltParseFindTopLevelElem(cctxt, cur,
+	BAD_CAST "variable", XSLT_NAMESPACE, 0, &cur) == 1)
+    {
+	xsltParseTopLevelXSLTElem(cctxt, cur, XSLT_FUNC_VARIABLE);
+	cur = cur->next;
+    }   
+    /*
+    * Process all the rest of top-level elements.
+    */
+    cur = start;
+    while (cur != NULL) {	
+	/*
+	* Process element nodes.
+	*/
+	if (cur->type == XML_ELEMENT_NODE) {	    
+	    if (cur->ns == NULL) {
+		xsltTransformError(NULL, style, cur,
+		    "Unexpected top-level element in no namespace.\n");
+		style->errors++;
+		cur = cur->next;
+		continue;
+	    }
 	    /*
-	    * Leaving an element.
+	    * Process all XSLT elements.
 	    */
-	    xsltCompilerNodePop(cctxt, cur);
+	    if (IS_XSLT_ELEM_FAST(cur)) {
+		/*
+		* xsl:import is only allowed at the beginning.
+		*/
+		if (IS_XSLT_NAME(cur, "import")) {
+		    xsltTransformError(NULL, style, cur,
+			"Misplaced xsl:import element.\n");
+		    style->errors++;
+		    cur = cur->next;
+		    continue;
+		}
+		/* 
+		* TODO: Change the return type of the parsing functions
+		*  to int.
+		*/
+		if (IS_XSLT_NAME(cur, "template")) {
+#ifdef WITH_XSLT_DEBUG_PARSING
+		    templates++;
+#endif
+		    /*
+		    * TODO: Is the position of xsl:template in the
+		    *  tree significant? If not it would be easier to
+		    *  parse them at a later stage.
+		    */
+		    xsltParseXSLTTemplate(cctxt, cur);
+		} else if (IS_XSLT_NAME(cur, "variable")) {
+		    /* NOP; done already */
+		} else if (IS_XSLT_NAME(cur, "param")) {
+		    /* NOP; done already */
+		} else if (IS_XSLT_NAME(cur, "include")) {		    
+		    if (cur->psvi != NULL)		    
+			xsltParseXSLTStylesheetElemCore(cctxt, cur);
+		    else {
+			xsltTransformError(NULL, style, cur,
+			    "Internal error: "
+			    "(xsltParseXSLTStylesheetElemCore) "
+			    "The xsl:include element was not compiled.\n");
+			style->errors++;
+		    }
+		} else if (IS_XSLT_NAME(cur, "strip-space")) {
+		    /* No node info needed. */
+		    xsltParseStylesheetStripSpace(style, cur);
+		} else if (IS_XSLT_NAME(cur, "preserve-space")) {
+		    /* No node info needed. */
+		    xsltParseStylesheetPreserveSpace(style, cur);
+		} else if (IS_XSLT_NAME(cur, "output")) {
+		    /* No node-info needed. */
+		    xsltParseStylesheetOutput(style, cur);
+		} else if (IS_XSLT_NAME(cur, "key")) {
+		    /* TODO: node-info needed for expressions ? */
+		    xsltParseStylesheetKey(style, cur);
+		} else if (IS_XSLT_NAME(cur, "decimal-format")) {
+		    /* No node-info needed. */		     
+		    xsltParseStylesheetDecimalFormat(style, cur);
+		} else if (IS_XSLT_NAME(cur, "attribute-set")) {		    
+		    xsltParseTopLevelXSLTElem(cctxt, cur,
+			XSLT_FUNC_ATTRSET);		
+		} else if (IS_XSLT_NAME(cur, "namespace-alias")) {
+		    /* NOP; done already */		    
+		} else {
+		    if (cctxt->inode->forwardsCompat) {
+			/*
+			* Forwards-compatible mode:
+			*
+			* XSLT-1: "if it is a top-level element and
+			*  XSLT 1.0 does not allow such elements as top-level
+			*  elements, then the element must be ignored along
+			*  with its content;"
+			*/
+			/*
+			* TODO: I don't think we should generate a warning.
+			*/
+			xsltTransformError(NULL, style, cur,
+			    "Forwards-compatible mode: Ignoring unknown XSLT "
+			    "element '%s'.\n", cur->name);
+			style->warnings++;
+		    } else {
+			xsltTransformError(NULL, style, cur,
+			    "Unknown XSLT element '%s'.\n", cur->name);
+			style->errors++;
+		    }
+		}
+	    } else {
+		xsltTopLevelFunction function;
+
+		/*
+		* Process non-XSLT elements, which are in a
+		*  non-NULL namespace.
+		*/
+		/*
+		* QUESTION: What does xsltExtModuleTopLevelLookup()
+		*  do exactly?
+		*/
+		function = xsltExtModuleTopLevelLookup(cur->name,
+		    cur->ns->href);
+		if (function != NULL)
+		    function(style, cur);
+#ifdef WITH_XSLT_DEBUG_PARSING
+		xsltGenericDebug(xsltGenericDebugContext,
+		    "xsltParseXSLTStylesheetElemCore : User-defined "
+		    "data element '%s'.\n", cur->name);
+#endif
+	    }
 	}
-	if (cur == top)
-	    break;
-	if (cur->next != NULL)
-	    cur = cur->next;
-	else {
-	    cur = cur->parent;
-	    goto next_sibling;
-	}	
+	cur = cur->next;
     }
+
+exit:
+
+#ifdef WITH_XSLT_DEBUG_PARSING
+    xsltGenericDebug(xsltGenericDebugContext,
+	"### END of parsing top-level elements of doc '%s'.\n",
+	node->doc->URL);
+    xsltGenericDebug(xsltGenericDebugContext,
+	"### Templates: %d\n", templates);
+#ifdef XSLT_REFACTORED
+    xsltGenericDebug(xsltGenericDebugContext,
+	"### Max inodes: %d\n", cctxt->maxNodeInfos);
+    xsltGenericDebug(xsltGenericDebugContext,
+	"### Max LREs  : %d\n", cctxt->maxLREs);
+#endif /* XSLT_REFACTORED */
+#endif /* WITH_XSLT_DEBUG_PARSING */
+
+    xsltCompilerNodePop(cctxt, node);
     return(0);
 }
-#endif /* XSLT_REFACTORED_PARSING */
 
 /**
+ * xsltParseXSLTStylesheet:
+ * @cctxt: the compiler context
+ * @node: the xsl:stylesheet/xsl:transform element-node
+ *
+ * Parses the xsl:stylesheet and xsl:transform element. 
+ *
+ * <xsl:stylesheet
+ *  id = id
+ *  extension-element-prefixes = tokens
+ *  exclude-result-prefixes = tokens
+ *  version = number>
+ *  <!-- Content: (xsl:import*, top-level-elements) -->
+ * </xsl:stylesheet>
+ *
+ * BIG TODO: The xsl:include stuff.
+ * 
+ * Called by xsltParseStylesheetTree()
+ *
+ * Returns 0 on success, a positive result on errors and
+ *         -1 on API or internal errors.
+ */
+static int
+xsltParseXSLTStylesheetElem(xsltCompilerCtxtPtr cctxt, xmlNodePtr node)
+{
+    xmlNodePtr cur, start;
+
+    if ((cctxt == NULL) || (node == NULL))
+	return(-1);
+    
+    if (node->children == NULL)
+	goto exit;
+
+    /*
+    * Process top-level elements:
+    *  xsl:import (must be first)
+    *  xsl:include (this is just a pre-processing)
+    */
+    cur = node->children;
+    /*
+    * Process xsl:import elements.
+    * XSLT 1.0: "The xsl:import element children must precede all
+    *  other element children of an xsl:stylesheet element,
+    *  including any xsl:include element children."
+    */    
+    while ((cur != NULL) &&
+	xsltParseFindTopLevelElem(cctxt, cur,
+	    BAD_CAST "import", XSLT_NAMESPACE, 1, &cur) == 1)
+    {
+	if (xsltParseStylesheetImport(cctxt->style, cur) != 0) {
+	    cctxt->style->errors++;
+	}
+	cur = cur->next;
+    }
+    if (cur == NULL)
+	goto exit;
+    start = cur;
+    /*
+    * Pre-process all xsl:include elements.
+    */
+    cur = start;
+    while ((cur != NULL) &&
+	xsltParseFindTopLevelElem(cctxt, cur,
+	    BAD_CAST "include", XSLT_NAMESPACE, 0, &cur) == 1)
+    {
+	xsltParseTopLevelXSLTElem(cctxt, cur, XSLT_FUNC_INCLUDE);
+	cur = cur->next;
+    }
+    /*
+    * Pre-process all xsl:namespace-alias elements.
+    * URGENT TODO: This won't work correctly: the order of included
+    *  aliases and aliases defined here is significant.
+    */
+    cur = start;
+    while ((cur != NULL) &&
+	xsltParseFindTopLevelElem(cctxt, cur,
+	    BAD_CAST "namespace-alias", XSLT_NAMESPACE, 0, &cur) == 1)
+    {
+	xsltNamespaceAlias(cctxt->style, cur);
+	cur = cur->next;
+    }
+
+    if (cctxt->isInclude) {
+	/*
+	* If this stylesheet is intended for inclusion, then
+	* we will process only imports and includes. 
+	*/
+	goto exit;
+    } 
+    /*
+    * Now parse the rest of the top-level elements.
+    */
+    xsltParseXSLTStylesheetElemCore(cctxt, node); 	
+exit:
+
+    return(0);
+}
+
+#else /* XSLT_REFACTORED */
+
+/**
  * xsltParseStylesheetTop:
  * @style:  the XSLT stylesheet
  * @top:  the top level "stylesheet" or "transform" element
@@ -2289,7 +5809,7 @@
 	if (cur->type == XML_TEXT_NODE) {
 	    if (cur->content != NULL) {
 		xsltTransformError(NULL, style, cur,
-		    "misplaced text element: '%s'\n", cur->content);
+		    "misplaced text node: '%s'\n", cur->content);
 	    }
 	    if (style != NULL) style->errors++;
             cur = cur->next;
@@ -2350,6 +5870,10 @@
     } else if (IS_XSLT_NAME(cur, "namespace-alias")) {
 	    xsltNamespaceAlias(style, cur);
 	} else {
+	    /*
+	    * BUG TODO: The version of the *doc* is irrelevant for
+	    *  the forwards-compatible mode.
+	    */
             if ((style != NULL) && (style->doc->version != NULL) &&
 	        (!strncmp((const char *) style->doc->version, "1.0", 3))) {
 	        xsltTransformError(NULL, style, cur,
@@ -2373,17 +5897,178 @@
 #endif
 }
 
+#endif /* else of XSLT_REFACTORED */
+
+#ifdef XSLT_REFACTORED
 /**
+ * xsltParseSimplifiedStylesheetTree:
+ *
+ * @style: the stylesheet (TODO: Change this to the compiler context)
+ * @doc: the document containing the stylesheet.
+ * @node: the node where the stylesheet is rooted at
+ *
+ * Returns 0 in case of success, a positive result if an error occurred
+ *         and -1 on API and internal errors.
+ */
+static int
+xsltParseSimplifiedStylesheetTree(xsltCompilerCtxtPtr cctxt,
+				  xmlDocPtr doc,
+				  xmlNodePtr node)
+{
+    xsltTemplatePtr templ;
+    
+    if ((cctxt == NULL) || (node == NULL))
+	return(-1);
+
+    if (xsltParseAttrXSLTVersion(cctxt, node, 0) == XSLT_ELEMENT_CATEGORY_LRE)
+    {
+	/*
+	* TODO: Adjust report, since this might be an
+	* embedded stylesheet.
+	*/
+	xsltTransformError(NULL, cctxt->style, node,
+	    "The attribute 'xsl:version' is missing; cannot identify "
+	    "this document as an XSLT stylesheet document.\n");
+	cctxt->style->errors++;
+	return(1);
+    }
+    
+#ifdef WITH_XSLT_DEBUG_PARSING
+    xsltGenericDebug(xsltGenericDebugContext,
+	"xsltParseSimplifiedStylesheetTree: document is stylesheet\n");
+#endif        
+    
+    /*
+    * Create and link the template
+    */
+    templ = xsltNewTemplate();
+    if (templ == NULL) {
+	return(-1);
+    }
+    templ->next = cctxt->style->templates;
+    cctxt->style->templates = templ;
+    templ->match = xmlStrdup(BAD_CAST "/");
+
+    /*
+    * Note that we push the document-node in this special case.
+    */
+    xsltCompilerNodePush(cctxt, (xmlNodePtr) doc);
+    /*
+    * In every case, we need to have
+    * the in-scope namespaces of the element, where the
+    * stylesheet is rooted at, regardless if it's an XSLT
+    * instruction or a literal result instruction (or if
+    * this is an embedded stylesheet).
+    */
+    cctxt->inode->inScopeNs =
+	xsltCompilerBuildInScopeNsList(cctxt, node);
+    /*
+    * Parse the content and register the match-pattern.
+    */
+    xsltParseSequenceConstructor(cctxt, node);
+    xsltCompilerNodePop(cctxt, (xmlNodePtr) doc);
+
+    templ->elem = (xmlNodePtr) doc;
+    templ->content = node;
+    xsltAddTemplate(cctxt->style, templ, NULL, NULL);
+    cctxt->style->literal_result = 1;
+    return(0);
+}
+
+#ifdef XSLT_REFACTORED_XSLT_NSCOMP
+int
+xsltRestoreDocumentNamespaces(xsltNsMapPtr ns, xmlDocPtr doc)
+{
+    if (doc == NULL)
+	return(-1);
+    /*
+    * Revert the changes we have applied to the namespace-URIs of
+    * ns-decls.
+    */    
+    while (ns != NULL) {
+	if ((ns->doc == doc) && (ns->ns != NULL)) {
+	    ns->ns->href = ns->origNsName;
+	    ns->origNsName = NULL;
+	    ns->ns = NULL;	    
+	}
+	ns = ns->next;
+    }
+    return(0);
+}
+#endif /* XSLT_REFACTORED_XSLT_NSCOMP */
+
+/**
  * xsltParseStylesheetProcess:
- * @ret:  the XSLT stylesheet
+ * @style:  the XSLT stylesheet (the current stylesheet-level)
  * @doc:  and xmlDoc parsed XML
  *
- * parse an XSLT stylesheet adding the associated structures
+ * Parses an XSLT stylesheet, adding the associated structures.
+ * Called by:
+ *  xsltParseStylesheetImportedDoc() (xslt.c)
+ *  xsltParseStylesheetInclude() (imports.c)
  *
- * Returns the value of the 'ret' parameter if everything
+ * Returns the value of the @style parameter if everything
  * went right, NULL if something went amiss.
  */
+xsltStylesheetPtr
+xsltParseStylesheetProcess(xsltStylesheetPtr style, xmlDocPtr doc)
+{
+    xsltCompilerCtxtPtr cctxt;
+    xmlNodePtr cur;
+    int oldIsSimplifiedStylesheet;
 
+
+    if ((style == NULL) || (doc == NULL))
+	return(NULL);
+
+    cctxt = XSLT_CCTXT(style);
+
+    cur = xmlDocGetRootElement(doc);
+    if (cur == NULL) {
+	xsltTransformError(NULL, style, (xmlNodePtr) doc,
+		"xsltParseStylesheetProcess : empty stylesheet\n");
+	return(NULL);
+    }
+    oldIsSimplifiedStylesheet = cctxt->simplified;
+
+    if ((IS_XSLT_ELEM(cur)) && 
+	((IS_XSLT_NAME(cur, "stylesheet")) ||
+	 (IS_XSLT_NAME(cur, "transform")))) {	
+#ifdef WITH_XSLT_DEBUG_PARSING
+	xsltGenericDebug(xsltGenericDebugContext,
+		"xsltParseStylesheetProcess : found stylesheet\n");
+#endif
+	cctxt->simplified = 0;
+	style->literal_result = 0;
+    } else {
+	cctxt->simplified = 1;
+	style->literal_result = 1;
+    }
+    /*
+    * Pre-process the stylesheet if not already done before.
+    *  This will remove PIs and comments, merge adjacent
+    *  text nodes, internalize strings, etc.
+    */
+    if (! style->nopreproc)
+	xsltParsePreprocessStylesheetTree(cctxt, cur);
+    /*
+    * Parse and compile the stylesheet.
+    */
+    if (style->literal_result == 0) {
+	if (xsltParseXSLTStylesheetElem(cctxt, cur) != 0)
+	    return(NULL);
+    } else {
+	if (xsltParseSimplifiedStylesheetTree(cctxt, doc, cur) != 0)
+	    return(NULL);
+    }    
+
+    cctxt->simplified = oldIsSimplifiedStylesheet;
+
+    return(style);
+}
+
+#else /* XSLT_REFACTORED */
+
 xsltStylesheetPtr
 xsltParseStylesheetProcess(xsltStylesheetPtr ret, xmlDocPtr doc) {
     xmlNodePtr cur;
@@ -2403,7 +6088,8 @@
 	xsltTransformError(NULL, ret, (xmlNodePtr) doc,
 		"xsltParseStylesheetProcess : empty stylesheet\n");
 	return(NULL);
-    }    
+    }
+
     if ((IS_XSLT_ELEM(cur)) && 
 	((IS_XSLT_NAME(cur, "stylesheet")) ||
 	 (IS_XSLT_NAME(cur, "transform")))) {	
@@ -2420,22 +6106,8 @@
 	ret->literal_result = 1;
     }
     if (!ret->nopreproc) {
-#ifdef XSLT_REFACTORED
-	/*
-	* Reset the compiler context.
-	* TODO: This all looks ugly; but note that this will go
-	*   into an other function; it's just temporarily here.
-	*/
-	XSLT_CCTXT(ret)->depth = -1;
-	XSLT_CCTXT(ret)->inode = NULL;
-#endif
 	xsltPrecomputeStylesheet(ret, cur);
-#ifdef XSLT_REFACTORED
-	XSLT_CCTXT(ret)->depth = -1;
-	XSLT_CCTXT(ret)->inode = NULL;
-#endif
     }
-
     if (ret->literal_result == 0) {
 	xsltParseStylesheetTop(ret, cur);
     } else {
@@ -2483,16 +6155,18 @@
 	template->elem = (xmlNodePtr) doc;
 	template->content = doc->children;
 	xsltAddTemplate(ret, template, NULL, NULL);
-	ret->literal_result = 1;
+	ret->literal_result = 1;	
     }
 
     return(ret);
 }
 
+#endif /* else of XSLT_REFACTORED */
+
 /**
  * xsltParseStylesheetImportedDoc:
  * @doc:  an xmlDoc parsed XML
- * @style: pointer to parent stylesheet
+ * @style: pointer to the parent stylesheet (if it exists)
  *
  * parse an XSLT stylesheet building the associated structures
  * except the processing not needed for imported documents.
@@ -2501,44 +6175,167 @@
  */
 
 xsltStylesheetPtr
-xsltParseStylesheetImportedDoc(xmlDocPtr doc, xsltStylesheetPtr style) {
-    xsltStylesheetPtr ret;
+xsltParseStylesheetImportedDoc(xmlDocPtr doc,
+			       xsltStylesheetPtr parentStyle) {
+    xsltStylesheetPtr retStyle;
 
     if (doc == NULL)
 	return(NULL);
 
-    ret = xsltNewStylesheet();
-    if (ret == NULL)
+    retStyle = xsltNewStylesheet();
+    if (retStyle == NULL)
 	return(NULL);
-    
+    /*
+    * Set the importing stylesheet module; also used to detect recursion.
+    */
+    retStyle->parent = parentStyle;
+    /*
+    * Adjust the string dict.
+    */
     if (doc->dict != NULL) {
-        xmlDictFree(ret->dict);
-	ret->dict = doc->dict;
+        xmlDictFree(retStyle->dict);
+	retStyle->dict = doc->dict;
 #ifdef WITH_XSLT_DEBUG
         xsltGenericDebug(xsltGenericDebugContext,
-                         "reusing dictionary from %s for stylesheet\n",
-			 doc->URL);
+	    "reusing dictionary from %s for stylesheet\n",
+	    doc->URL);
 #endif
-	xmlDictReference(ret->dict);
-    }
+	xmlDictReference(retStyle->dict);
+    }    	
     
-    ret->doc = doc;
-    ret->parent = style;	/* needed to prevent loops */
-    xsltGatherNamespaces(ret);
-    if (xsltParseStylesheetProcess(ret, doc) == NULL) {
-	ret->doc = NULL;
-	xsltFreeStylesheet(ret);
-	ret = NULL;
+    /*
+    * TODO: Eliminate xsltGatherNamespaces(); we must not restrict
+    *  the stylesheet to containt distinct namespace prefixes.
+    */
+    xsltGatherNamespaces(retStyle);
+
+#ifdef XSLT_REFACTORED
+    {
+	xsltCompilerCtxtPtr cctxt;
+	xsltStylesheetPtr oldCurSheet;
+	    
+	if (parentStyle == NULL) {
+	    xsltPrincipalStylesheetDataPtr principalData;
+	    /*
+	    * Principal stylesheet
+	    * --------------------
+	    */
+	    retStyle->principal = retStyle;
+	    /*
+	    * Create extra data for the principal stylesheet.
+	    */
+	    principalData = xsltNewPrincipalStylesheetData();
+	    if (principalData == NULL) {
+		xsltFreeStylesheet(retStyle);
+		return(NULL);
+	    }
+	    retStyle->principalData = principalData;
+	    /*
+	    * Create the compilation context
+	    * ------------------------------
+	    * (only once; for the principal stylesheet).
+	    * This is currently the only function where the
+	    * compilation context is created.
+	    */
+	    cctxt = xsltCompilationCtxtCreate(retStyle);
+	    if (cctxt == NULL) {
+		xsltFreeStylesheet(retStyle);
+		return(NULL);
+	    }	    	    
+	    retStyle->compCtxt = (void *) cctxt;
+	    cctxt->style = retStyle;
+	    cctxt->dict = retStyle->dict;
+	    cctxt->psData = principalData;
+	    /*
+	    * Push initial dummy node info.
+	    */
+	    cctxt->depth = -1;
+	    xsltCompilerNodePush(cctxt, (xmlNodePtr) doc);
+	} else {
+	    /*
+	    * Imported stylesheet.
+	    */
+	    retStyle->principal = parentStyle->principal;
+	    cctxt = parentStyle->compCtxt;
+	    retStyle->compCtxt = cctxt;
+	}
+	/*
+	* Save the old and set the current stylesheet structure in the
+	* compilation context.
+	*/
+	oldCurSheet = cctxt->style;
+	cctxt->style = retStyle;
+	
+	retStyle->doc = doc;
+	xsltParseStylesheetProcess(retStyle, doc);
+	
+	cctxt->style = oldCurSheet;
+	if (parentStyle == NULL) {
+	    /*
+	    * Pop the initial dummy node info.
+	    */
+	    xsltCompilerNodePop(cctxt, (xmlNodePtr) doc);
+	} else {
+	    /*
+	    * Clear the compilation context of imported
+	    * stylesheets.
+	    * TODO: really?
+	    */
+	    /* retStyle->compCtxt = NULL; */
+	}
+	/*
+	* Free the stylesheet if there were errors.
+	*/
+	if (retStyle != NULL) {
+	    if (retStyle->errors != 0) {
+#ifdef XSLT_REFACTORED_XSLT_NSCOMP
+		/*
+		* Restore all changes made to namespace URIs of ns-decls.
+		*/
+		if (cctxt->psData->nsMap)		
+		    xsltRestoreDocumentNamespaces(cctxt->psData->nsMap, doc);
+#endif
+		/*
+		* Detach the doc from the stylesheet; otherwise the doc
+		* will be freed in xsltFreeStylesheet().
+		*/
+		retStyle->doc = NULL;
+		/*
+		* Cleanup the doc if its the main stylesheet.
+		*/
+		if (parentStyle == NULL) {
+		    xsltCleanupStylesheetTree(doc, xmlDocGetRootElement(doc));
+		    if (retStyle->compCtxt != NULL) {			
+			xsltCompilationCtxtFree(retStyle->compCtxt);
+			retStyle->compCtxt = NULL;
+		    }
+		}
+
+		xsltFreeStylesheet(retStyle);
+		retStyle = NULL;
+	    }
+	}
     }
-    if (ret != NULL) {
-	if (ret->errors != 0) {
-	    ret->doc = NULL;
-	    xsltFreeStylesheet(ret);
-	    ret = NULL;
+        
+#else /* XSLT_REFACTORED */
+    /*
+    * Old behaviour.
+    */
+    retStyle->doc = doc;
+    xsltParseStylesheetProcess(retStyle, doc);
+    if (retStyle != NULL) {
+	if (retStyle->errors != 0) {
+	    retStyle->doc = NULL;
+	    if (parentStyle == NULL)
+		xsltCleanupStylesheetTree(doc,
+		    xmlDocGetRootElement(doc));
+	    xsltFreeStylesheet(retStyle);
+	    retStyle = NULL;
 	}
     }
-    
-    return(ret);
+#endif /* else of XSLT_REFACTORED */
+        
+    return(retStyle);
 }
 
 /**
@@ -2566,7 +6363,7 @@
     *   xsltParseStylesheetImportedDoc().
     */
     if (ret->compCtxt != NULL) {
-	xsltCompilerCtxtFree(XSLT_CCTXT(ret));
+	xsltCompilationCtxtFree(XSLT_CCTXT(ret));
 	ret->compCtxt = NULL;
     }
 #endif

Modified: packages/libxslt/trunk/libxslt/xsltInternals.h
===================================================================
--- packages/libxslt/trunk/libxslt/xsltInternals.h	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/libxslt/xsltInternals.h	2006-06-08 22:29:07 UTC (rev 565)
@@ -18,6 +18,7 @@
 #include <libxml/xpath.h>
 #include <libxml/xmlerror.h>
 #include <libxml/dict.h>
+#include <libxml/xmlstring.h>
 #include <libxslt/xslt.h>
 #include "xsltexports.h"
 #include "numbersInternals.h"
@@ -26,16 +27,128 @@
 extern "C" {
 #endif
 
+#define XSLT_IS_TEXT_NODE(n) ((n != NULL) && \
+    (((n)->type == XML_TEXT_NODE) || \
+     ((n)->type == XML_CDATA_SECTION_NODE)))
 
+
+#if 0
+
+extern const xmlChar *xsltDocFragFake;
+
+#define XSLT_MARK_RES_TREE_FRAG(n) (n)->psvi = (void *) xsltDocFragFake;
+
+#define XSLT_IS_RES_TREE_FRAG(n) \
+    ((n != NULL) && ((n)->type == XML_DOCUMENT_NODE) && \
+     ((n)->psvi == xsltDocFragFake))
+
+#else
+
+#define XSLT_MARK_RES_TREE_FRAG(n) \
+    (n)->name = (char *) xmlStrdup(BAD_CAST " fake node libxslt");
+
+#define XSLT_IS_RES_TREE_FRAG(n) \
+    ((n != NULL) && ((n)->type == XML_DOCUMENT_NODE) && \
+     ((n)->name != NULL) && ((n)->name[0] == ' ') && \
+    xmlStrEqual(BAD_CAST (n)->name, BAD_CAST " fake node libxslt"))
+
+#endif
+
 /**
+ * XSLT_REFACTORED_KEYCOMP:
+ *
+ * Internal define to enable on-demand xsl:key computation.
+ */
+#define XSLT_REFACTORED_KEYCOMP
+
+/**
  * XSLT_REFACTORED:
  *
- * Internal define to enable the refactored parts of Libxslt
- * mostly related to pre-computation.
+ * Internal define to enable the refactored parts of Libxslt.
  */
 /* #define XSLT_REFACTORED */
+/* ==================================================================== */
 
+#ifdef XSLT_REFACTORED
+/* TODO: REMOVE: #define XSLT_REFACTORED_EXCLRESNS */
+
+/* TODO: REMOVE: #define XSLT_REFACTORED_NSALIAS */
+
 /**
+ * XSLT_REFACTORED_XSLT_NSCOMP
+ *
+ * Internal define to enable the pointer-comparison of
+ * namespaces of XSLT elements. 
+ */
+#define XSLT_REFACTORED_XSLT_NSCOMP
+
+/**
+ * XSLT_REFACTORED_XPATHCOMP
+ *
+ * Internal define to enable the optimization of the
+ * compilation of XPath expressions.
+ */
+#define XSLT_REFACTORED_XPATHCOMP
+
+#ifdef XSLT_REFACTORED_XSLT_NSCOMP
+
+extern const xmlChar *xsltConstNamespaceNameXSLT;
+
+#define IS_XSLT_ELEM_FAST(n) \
+    (((n) != NULL) && ((n)->ns != NULL) && \
+    ((n)->ns->href == xsltConstNamespaceNameXSLT))
+
+#define IS_XSLT_ATTR_FAST(a) \
+    (((a) != NULL) && ((a)->ns != NULL) && \
+    ((a)->ns->href == xsltConstNamespaceNameXSLT))
+
+#define XSLT_HAS_INTERNAL_NSMAP(s) \
+    (((s) != NULL) && ((s)->principal) && \
+     ((s)->principal->principalData) && \
+     ((s)->principal->principalData->nsMap))
+
+#define XSLT_GET_INTERNAL_NSMAP(s) ((s)->principal->principalData->nsMap)
+
+#else /* XSLT_REFACTORED_XSLT_NSCOMP */
+
+#define IS_XSLT_ELEM_FAST(n) \
+    (((n) != NULL) && ((n)->ns != NULL) && \
+     (xmlStrEqual((n)->ns->href, XSLT_NAMESPACE)))
+
+#define IS_XSLT_ATTR_FAST(a) \
+    (((a) != NULL) && ((a)->ns != NULL) && \
+     (xmlStrEqual((a)->ns->href, XSLT_NAMESPACE)))
+
+
+#endif /* XSLT_REFACTORED_XSLT_NSCOMP */
+
+
+/**
+ * XSLT_REFACTORED_MANDATORY_VERSION:
+ *
+ * TODO: Currently disabled to surpress regression test failures, since
+ *  the old behaviour was that a missing version attribute
+ *  produced a only a warning and not an error, which was incerrect.
+ *  So the regression tests need to be fixed if this is enabled.
+ */
+/* #define XSLT_REFACTORED_MANDATORY_VERSION */
+
+/**
+ * xsltPointerList:
+ *
+ * Pointer-list for various purposes.
+ */
+typedef struct _xsltPointerList xsltPointerList;
+typedef xsltPointerList *xsltPointerListPtr;
+struct _xsltPointerList {
+    void **items;
+    int number;
+    int size;
+};
+
+#endif
+
+/**
  * XSLT_REFACTORED_PARSING:
  *
  * Internal define to enable the refactored parts of Libxslt
@@ -110,13 +223,17 @@
     struct _xsltStylesheet *style;/* the containing stylesheet */
     xmlChar *match;	/* the matching string */
     float priority;	/* as given from the stylesheet, not computed */
-    xmlChar *name;	/* the local part of the name QName */
-    xmlChar *nameURI;	/* the URI part of the name QName */
+    const xmlChar *name; /* the local part of the name QName */
+    const xmlChar *nameURI; /* the URI part of the name QName */
     const xmlChar *mode;/* the local part of the mode QName */
     const xmlChar *modeURI;/* the URI part of the mode QName */
     xmlNodePtr content;	/* the template replacement value */
     xmlNodePtr elem;	/* the source element */
 
+    /*
+    * TODO: @inheritedNsNr and @inheritedNs won't be used in the
+    *  refactored code.
+    */
     int inheritedNsNr;  /* number of inherited namespaces */
     xmlNsPtr *inheritedNs;/* inherited non-excluded namespaces */
 
@@ -165,8 +282,44 @@
     void *keys;			/* key tables storage */
     struct _xsltDocument *includes; /* subsidiary includes */
     int preproc;		/* pre-processing already done */
+    int nbKeysComputed;
 };
 
+/**
+ * xsltKeyDef:
+ *
+ * Representation of an xsl:key.
+ */
+typedef struct _xsltKeyDef xsltKeyDef;
+typedef xsltKeyDef *xsltKeyDefPtr;
+struct _xsltKeyDef {
+    struct _xsltKeyDef *next;
+    xmlNodePtr inst;
+    xmlChar *name;
+    xmlChar *nameURI;
+    xmlChar *match;
+    xmlChar *use;
+    xmlXPathCompExprPtr comp;
+    xmlXPathCompExprPtr usecomp;
+    xmlNsPtr *nsList;           /* the namespaces in scope */
+    int nsNr;                   /* the number of namespaces in scope */
+};
+
+/**
+ * xsltKeyTable:
+ *
+ * Holds the computed keys for key definitions of the same QName.
+ * Is owned by an xsltDocument.
+ */
+typedef struct _xsltKeyTable xsltKeyTable;
+typedef xsltKeyTable *xsltKeyTablePtr;
+struct _xsltKeyTable {
+    struct _xsltKeyTable *next;
+    xmlChar *name;
+    xmlChar *nameURI;
+    xmlHashTablePtr keys;
+};
+
 /*
  * The in-memory structure corresponding to an XSLT Stylesheet.
  * NOTE: most of the content is simply linked from the doc tree
@@ -236,7 +389,15 @@
     XSLT_FUNC_VARIABLE,
     XSLT_FUNC_WHEN,
     XSLT_FUNC_EXTENSION,
+#ifdef XSLT_REFACTORED
     XSLT_FUNC_OTHERWISE,
+    XSLT_FUNC_FALLBACK,
+    XSLT_FUNC_MESSAGE,
+    XSLT_FUNC_INCLUDE,
+    XSLT_FUNC_ATTRSET,
+    XSLT_FUNC_LITERAL_RESULT_ELEMENT,
+    XSLT_FUNC_UNKOWN_FORWARDS_COMPAT,
+#endif
 } xsltStyleType;
 
 /**
@@ -258,7 +419,7 @@
 struct _xsltElemPreComp {
     xsltElemPreCompPtr next;		/* next item in the global chained
 					   list hold by xsltStylesheet. */
-    xsltStyleType type;			/* type of the element */
+    xsltStyleType type;		/* type of the element */
     xsltTransformFunction func; 	/* handling function */
     xmlNodePtr inst;			/* the node in the stylesheet's tree
 					   corresponding to this item */
@@ -270,52 +431,45 @@
 /**
  * xsltStylePreComp:
  *
- * The abstract basic structure for items of the
- * AST of the XSLT processor.
- * The AST includes:
+ * The abstract basic structure for items of the XSLT processor.
+ * This includes:
  * 1) compiled forms of XSLT instructions (xsl:if, xsl:attribute, etc.)
  * 2) compiled forms of literal result elements
+ * 3) compiled forms of extension elements
  */
 typedef struct _xsltStylePreComp xsltStylePreComp;
 typedef xsltStylePreComp *xsltStylePreCompPtr;
 
-/*************************
- * Refactored structures *
- *************************/
 #ifdef XSLT_REFACTORED
 
-typedef struct _xsltNsList xsltNsList;
+/*
+* Some pointer-list utility functions.
+*/
+XSLTPUBFUN xsltPointerListPtr XSLTCALL
+		xsltPointerListCreate		(int initialSize);
+XSLTPUBFUN void XSLTCALL
+		xsltPointerListFree		(xsltPointerListPtr list);
+XSLTPUBFUN void XSLTCALL
+		xsltPointerListClear		(xsltPointerListPtr list);
+XSLTPUBFUN int XSLTCALL
+		xsltPointerListAddSize		(xsltPointerListPtr list,						 
+						 void *item,
+						 int initialSize);
 
-typedef xsltNsList *xsltNsListPtr;
-struct _xsltNsList {
+/************************************************************************
+ *									*
+ * Refactored structures                                                *
+ *									*
+ ************************************************************************/
+
+typedef struct _xsltNsListContainer xsltNsListContainer;
+typedef xsltNsListContainer *xsltNsListContainerPtr;
+struct _xsltNsListContainer {
     xmlNsPtr *list;
     int number;
 };
 
-#if 0
-/*
- * TODO: xsltBasicItem is not used yet; maybe never will be used, since
- * xsltElemPreCompPtr is acting as the base type for the compiled
- * items of a stylesheet. It seems not practical to try to change
- * this type to xsltBasicItemPtr, since xsltElemPreCompPtr is
- * used already used too massively (e.g. xsltStylesheet->preComps) and
- * for extension functions.
- */
 /**
- * xsltBasicItem:
- *
- * The basic structure for all items of the AST of the XSLT processor.
- */
-typedef struct _xsltBasicItem xsltBasicItem;
-
-typedef xsltBasicItem *xsltBasicItemPtr;
-struct _xsltBasicItem {
-    xsltBasicASTItemPtr next;
-    xsltStyleType type;
-};
-#endif
-
-/**
  * XSLT_ITEM_COMPATIBILITY_FIELDS:
  * 
  * Fields for API compatibility to the structure
@@ -346,7 +500,7 @@
  *
  * The in-scope namespaces.
  */
-#define XSLT_ITEM_NSINSCOPE_FIELDS xsltNsListPtr inScopeNS;
+#define XSLT_ITEM_NSINSCOPE_FIELDS xsltNsListContainerPtr inScopeNs;
 
 /**
  * XSLT_ITEM_COMMON_FIELDS:
@@ -378,8 +532,8 @@
     xsltTransformFunction func; /* handling function */
     xmlNodePtr inst;		/* the node in the stylesheet's tree
 				   corresponding to this item. */
-    /* Currenlty to navigational fields. */
-    xsltNsListPtr inScopeNS;
+    /* Currently no navigational fields. */
+    xsltNsListContainerPtr inScopeNs;
 };
 
 /**
@@ -868,22 +1022,150 @@
     XSLT_ITEM_COMMON_FIELDS
 };
 
+typedef struct _xsltStyleItemInclude xsltStyleItemInclude;
+typedef xsltStyleItemInclude *xsltStyleItemIncludePtr;
+
+struct _xsltStyleItemInclude {
+    XSLT_ITEM_COMMON_FIELDS
+    xsltDocumentPtr include;
+};
+
+/************************************************************************
+ *									*
+ *  XSLT elements in forwards-compatible mode                           *
+ *									*
+ ************************************************************************/
+
+typedef struct _xsltStyleItemUknown xsltStyleItemUknown;
+typedef xsltStyleItemUknown *xsltStyleItemUknownPtr;
+struct _xsltStyleItemUknown {
+    XSLT_ITEM_COMMON_FIELDS
+};
+
+
+/************************************************************************
+ *									*
+ *  Extension elements                                                  *
+ *									*
+ ************************************************************************/
+
 /*
- * Literal result elements.
- * TODO: Not used yet.
+ * xsltStyleItemExtElement:
+ *
+ * Reflects extension elements.
+ *
+ * NOTE: Due to the fact that the structure xsltElemPreComp is most
+ * probably already heavily in use out there by users, so we cannot
+ * easily change it, we'll create an intermediate structure which will
+ * hold an xsltElemPreCompPtr.
+ * BIG NOTE: The only problem I see here is that the user processes the
+ *  content of the stylesheet tree, possibly he'll lookup the node->psvi
+ *  fields in order to find subsequent extension functions.
+ *  In this case, the user's code will break, since the node->psvi
+ *  field will hold now the xsltStyleItemExtElementPtr and not
+ *  the xsltElemPreCompPtr.
+ *  However the place where the structure is anchored in the node-tree,
+ *  namely node->psvi, has beed already once been moved from node->_private
+ *  to node->psvi, so we have a precedent here, which, I think, should allow
+ *  us to change such semantics without headaches.
  */
-typedef struct _xsltStyleItemLRE xsltStyleItemLRE;
-typedef xsltStyleItemLRE *xsltStyleItemLREPtr;
-struct _xsltStyleItemLRE {
+typedef struct _xsltStyleItemExtElement xsltStyleItemExtElement;
+typedef xsltStyleItemExtElement *xsltStyleItemExtElementPtr;
+struct _xsltStyleItemExtElement {
     XSLT_ITEM_COMMON_FIELDS
+    xsltElemPreCompPtr item;   
 };
 
 /************************************************************************
  *									*
+ *  Literal result elements                                             *
+ *									*
+ ************************************************************************/
+
+typedef struct _xsltEffectiveNs xsltEffectiveNs;
+typedef xsltEffectiveNs *xsltEffectiveNsPtr;
+struct _xsltEffectiveNs {
+    xsltEffectiveNsPtr nextInStore; /* storage next */
+    xsltEffectiveNsPtr next; /* next item in the list */
+    const xmlChar *prefix;
+    const xmlChar *nsName;
+    /* 
+    * Indicates if eclared on the literal result element; dunno if really
+    * needed.
+    */
+    int holdByElem;
+};
+
+/*
+ * Info for literal result elements.
+ * This will be set on the elem->psvi field and will be
+ * shared by literal result elements, which have the same
+ * excluded result namespaces; i.e., this *won't* be created uniquely
+ * for every literal result element.
+ */
+typedef struct _xsltStyleItemLRElementInfo xsltStyleItemLRElementInfo;
+typedef xsltStyleItemLRElementInfo *xsltStyleItemLRElementInfoPtr;
+struct _xsltStyleItemLRElementInfo {
+    XSLT_ITEM_COMMON_FIELDS
+    /*
+    * @effectiveNs is the set of effective ns-nodes
+    *  on the literal result element, which will be added to the result
+    *  element if not already existing in the result tree.
+    *  This means that excluded namespaces (via exclude-result-prefixes,
+    *  extension-element-prefixes and the XSLT namespace) not added
+    *  to the set.
+    *  Namespace-aliasing was applied on the @effectiveNs.
+    */
+    xsltEffectiveNsPtr effectiveNs;
+
+};
+
+#ifdef XSLT_REFACTORED
+
+typedef struct _xsltNsAlias xsltNsAlias;
+typedef xsltNsAlias *xsltNsAliasPtr;
+struct _xsltNsAlias {
+    xsltNsAliasPtr next; /* next in the list */    
+    xmlNsPtr literalNs;
+    xmlNsPtr targetNs;
+    xmlDocPtr docOfTargetNs;
+};
+#endif
+
+#ifdef XSLT_REFACTORED_XSLT_NSCOMP
+
+typedef struct _xsltNsMap xsltNsMap;
+typedef xsltNsMap *xsltNsMapPtr;
+struct _xsltNsMap {
+    xsltNsMapPtr next; /* next in the list */
+    xmlDocPtr doc;
+    xmlNodePtr elem; /* the element holding the ns-decl */
+    xmlNsPtr ns; /* the xmlNs structure holding the XML namespace name */
+    const xmlChar *origNsName; /* the original XML namespace name */
+    const xmlChar *newNsName; /* the mapped XML namespace name */    
+};
+#endif
+
+/************************************************************************
+ *									*
  *  Compile-time structures for *internal* use only                     *
  *									*
  ************************************************************************/
 
+typedef struct _xsltPrincipalStylesheetData xsltPrincipalStylesheetData;
+typedef xsltPrincipalStylesheetData *xsltPrincipalStylesheetDataPtr;
+
+typedef struct _xsltNsList xsltNsList;
+typedef xsltNsList *xsltNsListPtr;
+struct _xsltNsList {
+    xsltNsListPtr next; /* next in the list */
+    xmlNsPtr ns;
+};
+
+#define XSLT_ELEMENT_CATEGORY_XSLT 0
+#define XSLT_ELEMENT_CATEGORY_EXTENSION 1
+#define XSLT_ELEMENT_CATEGORY_LRE 2
+
 /**
  * xsltCompilerNodeInfo:
  *
@@ -896,29 +1178,86 @@
     xsltCompilerNodeInfoPtr prev;
     xmlNodePtr node;
     int depth;
-    xsltNsListPtr inScopeNS; /* The in-scope namespaces for the current
-                                position in the node-tree */
     xsltTemplatePtr templ;   /* The owning template */
+    int category;	     /* XSLT element, LR-element or
+                                extension element */
+    xsltStyleType type;
     xsltElemPreCompPtr item; /* The compiled information */
+    /* The current in-scope namespaces */
+    xsltNsListContainerPtr inScopeNs;
+    /* The current excluded result namespaces */
+    xsltPointerListPtr exclResultNs; 
+    /* The current extension instruction namespaces */
+    xsltPointerListPtr extElemNs;
+    /* The current info for literal result elements. */
+    xsltStyleItemLRElementInfoPtr litResElemInfo;
+    /* 
+    * Set to 1 if in-scope namespaces changed,
+    *  or excluded result namespaces changed,
+    *  or extension element namespaces changed.
+    * This will trigger creation of new infos
+    *  for literal result elements.
+    */
+    int nsChanged;
+    int preserveWhitespace;
+    int stripWhitespace;
+    int isRoot; /* whether this is the stylesheet's root node */
+    int forwardsCompat; /* whether forwards-compatible mode is enabled */
+    /* whether the content of an extension element was processed */
+    int extContentHandled;
+    /* the type of the current child */
+    xsltStyleType curChildType;    
 };
 
-#define XSLT_CCTXT(style) ((xsltCompilerCtxtPtr) style->compCtxt)
+#define XSLT_CCTXT(style) ((xsltCompilerCtxtPtr) style->compCtxt) 
 
+typedef enum {
+    XSLT_ERROR_SEVERITY_ERROR = 0,
+    XSLT_ERROR_SEVERITY_WARNING
+} xsltErrorSeverityType;
+
 typedef struct _xsltCompilerCtxt xsltCompilerCtxt;
 typedef xsltCompilerCtxt *xsltCompilerCtxtPtr;
 struct _xsltCompilerCtxt {
-    void *errorCtxt;             /* user specific error context */
+    void *errorCtxt;            /* user specific error context */
+    /*
+    * used for error/warning reports; e.g. XSLT_ERROR_SEVERITY_WARNING */
+    xsltErrorSeverityType errSeverity;		
     int warnings;		/* TODO: number of warnings found at
                                    compilation */
     int errors;			/* TODO: number of errors found at
                                    compilation */
-    xsltStylesheetPtr sheet;
+    xmlDictPtr dict;
+    xsltStylesheetPtr style;
+    int simplified; /* whether this is a simplified stylesheet */
     /* TODO: structured/unstructured error contexts. */
-    int depth; /* TODO: current depth in the stylesheets node-tree */
+    int depth; /* Current depth of processing */
     
     xsltCompilerNodeInfoPtr inode;
     xsltCompilerNodeInfoPtr inodeList;
     xsltCompilerNodeInfoPtr inodeLast;
+    xsltPointerListPtr tmpList; /* Used for various purposes */
+    /*
+    * The XSLT version as specified by the stylesheet's root element.
+    */
+    int isInclude;
+    int hasForwardsCompat; /* whether forwards-compatible mode was used
+			     in a parsing episode */
+    int maxNodeInfos; /* TEMP TODO: just for the interest */
+    int maxLREs;  /* TEMP TODO: just for the interest */
+    /* 
+    * In order to keep the old behaviour, applying strict rules of
+    * the spec can be turned off. This has effect only on special
+    * mechanisms like whitespace-stripping in the stylesheet.
+    */
+    int strict;
+    xsltPrincipalStylesheetDataPtr psData;
+#ifdef XSLT_REFACTORED_XPATHCOMP
+    xmlXPathContextPtr xpathCtxt;
+#endif
+    xsltStyleItemUknownPtr unknownItem;
+    int hasNsAliases; /* Indicator if there was an xsl:namespace-alias. */
+    xsltNsAliasPtr nsAliases;    
 };   
 
 #else /* XSLT_REFACTORED */
@@ -1002,10 +1341,42 @@
     xmlXPathObjectPtr value;	/* The value if computed */
 };
 
+#ifdef XSLT_REFACTORED
+
+struct _xsltPrincipalStylesheetData {
+    /*
+    * Namespace dictionary for ns-prefixes and ns-names:
+    * TODO: Shared between stylesheets, and XPath mechanisms.
+    *   Not used yet.
+    */
+    xmlDictPtr namespaceDict;
+    /*
+    * Global list of in-scope namespaces.
+    */
+    xsltPointerListPtr inScopeNamespaces;
+    /*
+    * Global list of information for [xsl:]excluded-result-prefixes.
+    */
+    xsltPointerListPtr exclResultNamespaces;
+    /*
+    * Global list of information for [xsl:]extension-element-prefixes.
+    */
+    xsltPointerListPtr extElemNamespaces;
+    xsltEffectiveNsPtr effectiveNs;
+#ifdef XSLT_REFACTORED_XSLT_NSCOMP
+    /*
+    * Namespace name map to get rid of string comparison of namespace names.
+    */
+    xsltNsMapPtr nsMap;
+#endif
+};
+
+    
+#endif
 /*
- * TODO: We need a field to anchor an stylesheet compilation context, since,
- *   due to historical reasons, various compile-time function take only the
- *   stylesheet as argument and not a compilation context.
+ * Note that we added a @compCtxt field to anchor an stylesheet compilation
+ * context, since, due to historical reasons, various compile-time function
+ * take only the stylesheet as argument and not a compilation context.
  */
 struct _xsltStylesheet {
     /*
@@ -1048,6 +1419,7 @@
     
     /*
      * Namespace aliases.
+     * NOTE: Not used in the refactored code.
      */
     xmlHashTablePtr nsAliases;	/* the namespace alias hash tables */
 
@@ -1058,14 +1430,24 @@
 
     /*
      * Namespaces.
+     * TODO: Eliminate this.
      */
-    xmlHashTablePtr nsHash;     /* the set of namespaces in use */
-    void           *nsDefs;     /* the namespaces defined */
+    xmlHashTablePtr nsHash;     /* the set of namespaces in use:
+                                   ATTENTION: This is used for
+                                   execution of XPath expressions; unfortunately
+                                   it restricts the stylesheet to have distinct
+                                   prefixes.
+				   TODO: We need to get rid of this.    
+				 */
+    void           *nsDefs;     /* ATTENTION TODO: This is currently used to store
+				   xsltExtDefPtr (in extensions.c) and
+                                   *not* xmlNsPtr.
+				 */
 
     /*
      * Key definitions.
      */
-    void *keys;				/* key definitions */
+    void *keys;			/* key definitions */
 
     /*
      * Output related stuff.
@@ -1112,7 +1494,7 @@
     xsltDocumentPtr includes;	/* points to last nested include */
 
     /*
-     * dictionnary: shared between stylesheet, context and documents.
+     * dictionary: shared between stylesheet, context and documents.
      */
     xmlDictPtr dict;
     /*
@@ -1121,6 +1503,7 @@
     void *attVTs;
     /*
      * if namespace-alias has an alias for the default stylesheet prefix
+     * NOTE: Not used in the refactored code.
      */
     const xmlChar *defaultAlias;
     /*
@@ -1135,16 +1518,18 @@
      * Literal Result Element as Stylesheet c.f. section 2.3
      */
     int literal_result;
+    /*
+    * The principal stylesheet
+    */
+    xsltStylesheetPtr principal;
 #ifdef XSLT_REFACTORED
     /*
     * Compilation context used during compile-time.
     */
-    void * compCtxt;
-    /*
-    * Namespace lists.
-    */
-    void *inScopeNamespaces;    
-#endif    
+    xsltCompilerCtxtPtr compCtxt; /* TODO: Change this to (void *). */
+
+    xsltPrincipalStylesheetDataPtr principalData;    
+#endif
 };
 
 /*
@@ -1265,6 +1650,8 @@
      * all document text strings are internalized
      */
     int internalized;
+    int nbKeys;
+    int hasTemplKeyPatterns;
 };
 
 /**
@@ -1323,13 +1710,13 @@
 XSLTPUBFUN xsltStylesheetPtr XSLTCALL	
 			xsltParseStylesheetFile	(const xmlChar* filename);
 XSLTPUBFUN void XSLTCALL			
-			xsltFreeStylesheet	(xsltStylesheetPtr sheet);
+			xsltFreeStylesheet	(xsltStylesheetPtr style);
 XSLTPUBFUN int XSLTCALL			
 			xsltIsBlank		(xmlChar *str);
 XSLTPUBFUN void XSLTCALL			
 			xsltFreeStackElemList	(xsltStackElemPtr elem);
 XSLTPUBFUN xsltDecimalFormatPtr XSLTCALL	
-			xsltDecimalFormatGetByName(xsltStylesheetPtr sheet,
+			xsltDecimalFormatGetByName(xsltStylesheetPtr style,
 						 xmlChar *name);
 
 XSLTPUBFUN xsltStylesheetPtr XSLTCALL	
@@ -1389,23 +1776,44 @@
 XSLTPUBFUN void XSLTCALL
 			xsltFreeAVTList		(void *avt);
 
+/*
+ * Extra function for successful xsltCleanupGlobals / xsltInit sequence.
+ */
+
+XSLTPUBFUN void XSLTCALL
+			xsltUninit		(void);
+
 /************************************************************************
  *									*
  *  Compile-time functions for *internal* use only                      *
  *									*
  ************************************************************************/
 
-#ifdef XSLT_REFACTORED
-XSLTPUBFUN xsltNsListPtr XSLTCALL
-			xsltCompilerGetInScopeNSInfo(xsltCompilerCtxtPtr cctxt,
-						     xmlNodePtr node);
+#ifdef XSLT_REFACTORED  
+XSLTPUBFUN void XSLTCALL
+			xsltParseSequenceConstructor(
+						 xsltCompilerCtxtPtr cctxt,
+						 xmlNodePtr start);
+XSLTPUBFUN int XSLTCALL
+			xsltParseAnyXSLTElem	(xsltCompilerCtxtPtr cctxt,
+						 xmlNodePtr elem);
+#ifdef XSLT_REFACTORED_XSLT_NSCOMP
+XSLTPUBFUN int XSLTCALL
+			xsltRestoreDocumentNamespaces(
+						 xsltNsMapPtr ns,
+						 xmlDocPtr doc);
+#endif
 #endif /* XSLT_REFACTORED */
-/*
- * Extra function for successful xsltCleanupGlobals / xsltInit sequence.
- */
 
-XSLTPUBFUN void XSLTCALL
-			xsltUninit		(void);
+/************************************************************************
+ *									*
+ *  Transformation-time functions for *internal* use only               *
+ *									*
+ ************************************************************************/
+XSLTPUBFUN int XSLTCALL
+			xsltInitCtxtKey		(xsltTransformContextPtr ctxt,
+						 xsltDocumentPtr doc,
+						 xsltKeyDefPtr keyd);
 
 #ifdef __cplusplus
 }

Modified: packages/libxslt/trunk/libxslt/xsltconfig.h
===================================================================
--- packages/libxslt/trunk/libxslt/xsltconfig.h	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/libxslt/xsltconfig.h	2006-06-08 22:29:07 UTC (rev 565)
@@ -20,28 +20,28 @@
  *
  * the version string like "1.2.3"
  */
-#define LIBXSLT_DOTTED_VERSION "1.1.16"
+#define LIBXSLT_DOTTED_VERSION "1.1.17"
 
 /**
  * LIBXSLT_VERSION:
  *
  * the version number: 1.2.3 value is 1002003
  */
-#define LIBXSLT_VERSION 10116
+#define LIBXSLT_VERSION 10117
 
 /**
  * LIBXSLT_VERSION_STRING:
  *
  * the version number string, 1.2.3 value is "1002003"
  */
-#define LIBXSLT_VERSION_STRING "10116"
+#define LIBXSLT_VERSION_STRING "10117"
 
 /**
  * LIBXSLT_VERSION_EXTRA:
  *
  * extra version information, used to show a CVS compilation
  */
-#define	LIBXSLT_VERSION_EXTRA "-CVS1050"
+#define	LIBXSLT_VERSION_EXTRA "-CVS1062"
 
 /**
  * WITH_XSLT_DEBUG:

Modified: packages/libxslt/trunk/libxslt/xsltutils.c
===================================================================
--- packages/libxslt/trunk/libxslt/xsltutils.c	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/libxslt/xsltutils.c	2006-06-08 22:29:07 UTC (rev 565)
@@ -303,6 +303,49 @@
 #ifdef XSLT_REFACTORED
 
 /**
+ * xsltPointerListAddSize:
+ * @list: the pointer list structure
+ * @item: the item to be stored
+ * @initialSize: the initial size of the list
+ *
+ * Adds an item to the list.
+ *
+ * Returns the position of the added item in the list or
+ *         -1 in case of an error.
+ */
+int
+xsltPointerListAddSize(xsltPointerListPtr list,		       
+		       void *item,
+		       int initialSize)
+{
+    if (list->items == NULL) {
+	if (initialSize <= 0)
+	    initialSize = 1;
+	list->items = (void **) xmlMalloc(
+	    initialSize * sizeof(void *));
+	if (list->items == NULL) {
+	    xsltGenericError(xsltGenericErrorContext,
+	     "xsltPointerListAddSize: memory allocation failure.\n");
+	    return(-1);
+	}
+	list->number = 0;
+	list->size = initialSize;
+    } else if (list->size <= list->number) {
+	list->size *= 2;
+	list->items = (void **) xmlRealloc(list->items,
+	    list->size * sizeof(void *));
+	if (list->items == NULL) {
+	    xsltGenericError(xsltGenericErrorContext,
+	     "xsltPointerListAddSize: memory re-allocation failure.\n");
+	    list->size = 0;
+	    return(-1);
+	}
+    }
+    list->items[list->number++] = item;
+    return(0);
+}
+
+/**
  * xsltPointerListCreate:
  *
  * Creates an xsltPointerList structure.
@@ -310,7 +353,7 @@
  * Returns a xsltPointerList structure or NULL in case of an error.
  */
 xsltPointerListPtr
-xsltPointerListCreate(void)
+xsltPointerListCreate(int initialSize)
 {
     xsltPointerListPtr ret;
 
@@ -321,6 +364,10 @@
 	return (NULL);
     }
     memset(ret, 0, sizeof(xsltPointerList));
+    if (initialSize > 0) {
+	xsltPointerListAddSize(ret, NULL, initialSize);
+	ret->number = 0;
+    }
     return (ret);
 }
 
@@ -357,76 +404,6 @@
     list->size = 0;
 }
 
-/**
- * xsltPointerListAdd:
- *
- * Adds an item to the list.
- *
- * Returns the position of the added item in the list or
- *         -1 in case of an error.
- */
-int
-xsltPointerListAdd(xsltPointerListPtr list, void *item)
-{
-    if (list->items == NULL) {
-	list->items = (void **) xmlMalloc(
-	    20 * sizeof(void *));
-	if (list->items == NULL) {
-	    xsltGenericError(xsltGenericErrorContext,
-	     "xsltPointerListAdd: memory allocation failure.\n");
-	    return(-1);
-	}
-	list->number = 0;
-	list->size = 20;
-    } else if (list->size <= list->number) {
-	list->size *= 2;
-	list->items = (void **) xmlRealloc(list->items,
-	    list->size * sizeof(void *));
-	if (list->items == NULL) {
-	    xsltGenericError(xsltGenericErrorContext,
-	     "xsltPointerListAdd: memory re-allocation failure.\n");
-	    list->size = 0;
-	    return(-1);
-	}
-    }
-    list->items[list->number++] = item;
-    return(0);
-}
-
-#if 0 /* TODO: Not used yet. Enable if ever needed. */
-static int
-xsltPointerListAddSize(xsltPointerListPtr list,
-		       int initialSize,
-		       void *item)
-{
-    if (list->items == NULL) {
-	if (initialSize <= 0)
-	    initialSize = 1;
-	list->items = (void **) xmlMalloc(
-	    initialSize * sizeof(void *));
-	if (list->items == NULL) {
-	    xsltGenericError(xsltGenericErrorContext,
-	     "xsltPointerListAddSize: memory allocation failure.\n");
-	    return(-1);
-	}
-	list->number = 0;
-	list->size = initialSize;
-    } else if (list->size <= list->number) {
-	list->size *= 2;
-	list->items = (void **) xmlRealloc(list->items,
-	    list->size * sizeof(void *));
-	if (list->items == NULL) {
-	    xsltGenericError(xsltGenericErrorContext,
-	     "xsltPointerListAddSize: memory re-allocation failure.\n");
-	    list->size = 0;
-	    return(-1);
-	}
-    }
-    list->items[list->number++] = item;
-    return(0);
-}
-#endif
-
 #endif /* XSLT_REFACTORED */
 
 /************************************************************************
@@ -650,8 +627,16 @@
     
     if (ctxt != NULL)
 	type = "runtime error";
-    else if (style != NULL)
+    else if (style != NULL) {
+#ifdef XSLT_REFACTORED
+	if (XSLT_CCTXT(style)->errSeverity == XSLT_ERROR_SEVERITY_WARNING)
+	    type = "compilation warning";
+	else
+	    type = "compilation error";
+#else
 	type = "compilation error";
+#endif
+    }
 
     if ((file != NULL) && (line != 0) && (name != NULL))
 	error(errctx, "%s: file %s line %d element %s\n",
@@ -1008,9 +993,9 @@
 	ctxt->node = list->nodeTab[i];
 	ctxt->xpathCtxt->node = ctxt->node;
 #ifdef XSLT_REFACTORED
-	if (comp->inScopeNS != NULL) {
-	    ctxt->xpathCtxt->namespaces = comp->inScopeNS->list;
-	    ctxt->xpathCtxt->nsNr = comp->inScopeNS->number;
+	if (comp->inScopeNs != NULL) {
+	    ctxt->xpathCtxt->namespaces = comp->inScopeNs->list;
+	    ctxt->xpathCtxt->nsNr = comp->inScopeNs->number;
 	} else {
 	    ctxt->xpathCtxt->namespaces = NULL;
 	    ctxt->xpathCtxt->nsNr = 0;
@@ -2078,22 +2063,50 @@
  */
 xmlXPathCompExprPtr
 xsltXPathCompile(xsltStylesheetPtr style, const xmlChar *str) {
-    xmlXPathContextPtr xctxt;
+    xmlXPathContextPtr xpathCtxt;
     xmlXPathCompExprPtr ret;
 
-    if (style != NULL)
-	xctxt = xmlXPathNewContext(style->doc);
-    else
-	xctxt = xmlXPathNewContext(NULL);
-    if (style != NULL)
-	xctxt->dict = style->dict;
-    ret = xmlXPathCtxtCompile(xctxt, str);
-    xmlXPathFreeContext(xctxt);
+    if (style != NULL) {
+#ifdef XSLT_REFACTORED_XPATHCOMP
+	if (XSLT_CCTXT(style)) {
+	    /*
+	    * Proposed by Jerome Pesenti
+	    * --------------------------
+	    * For better efficiency we'll reuse the compilation
+	    * context's XPath context. For the common stylesheet using
+	    * XPath expressions this will reduce compilation time to
+	    * about 50%.
+	    *
+	    * See http://mail.gnome.org/archives/xslt/2006-April/msg00037.html
+	    */
+	    xpathCtxt = XSLT_CCTXT(style)->xpathCtxt;
+	    xpathCtxt->doc = style->doc;
+	} else
+	    xpathCtxt = xmlXPathNewContext(style->doc);	
+#else
+	xpathCtxt = xmlXPathNewContext(style->doc);
+#endif
+	xpathCtxt->dict = style->dict;
+    } else {
+	xpathCtxt = xmlXPathNewContext(NULL);
+    }
     /*
+    * Compile the expression.
+    */
+    ret = xmlXPathCtxtCompile(xpathCtxt, str);
+
+#ifdef XSLT_REFACTORED_XPATHCOMP
+    if ((style == NULL) || (! XSLT_CCTXT(style))) {
+	xmlXPathFreeContext(xpathCtxt);
+    }
+#else
+    xmlXPathFreeContext(xpathCtxt);
+#endif
+    /*
      * TODO: there is a lot of optimizations which should be possible
      *       like variable slot precomputations, function precomputations, etc.
      */
-     
+
     return(ret);
 }
 

Modified: packages/libxslt/trunk/libxslt/xsltutils.h
===================================================================
--- packages/libxslt/trunk/libxslt/xsltutils.h	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/libxslt/xsltutils.h	2006-06-08 22:29:07 UTC (rev 565)
@@ -298,31 +298,6 @@
 XSLTPUBFUN void XSLTCALL		
 		xslDropCall			(void);
 
-#ifdef XSLT_REFACTORED
-/**
- * xsltPointerList:
- *
- * Pointer-list for various purposes.
- */
-typedef struct _xsltPointerList xsltPointerList;
-typedef xsltPointerList *xsltPointerListPtr;
-struct _xsltPointerList {
-    void **items;
-    int number;
-    int size;
-};
-
-XSLTPUBFUN xsltPointerListPtr XSLTCALL
-		xsltPointerListCreate		(void);
-XSLTPUBFUN void XSLTCALL
-		xsltPointerListFree		(xsltPointerListPtr list);
-XSLTPUBFUN void XSLTCALL
-		xsltPointerListClear		(xsltPointerListPtr list);
-XSLTPUBFUN int XSLTCALL
-		xsltPointerListAdd		(xsltPointerListPtr list,
-						 void *item);
-#endif /* XSLT_REFACTOR */
-
 #ifdef __cplusplus
 }
 #endif

Modified: packages/libxslt/trunk/libxslt/xsltwin32config.h
===================================================================
--- packages/libxslt/trunk/libxslt/xsltwin32config.h	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/libxslt/xsltwin32config.h	2006-06-08 22:29:07 UTC (rev 565)
@@ -23,21 +23,21 @@
  *
  * the version string like "1.2.3"
  */
-#define LIBXSLT_DOTTED_VERSION "1.1.16"
+#define LIBXSLT_DOTTED_VERSION "1.1.17"
 
 /**
  * LIBXSLT_VERSION:
  *
  * the version number: 1.2.3 value is 1002003
  */
-#define LIBXSLT_VERSION 10116
+#define LIBXSLT_VERSION 10117
 
 /**
  * LIBXSLT_VERSION_STRING:
  *
  * the version number string, 1.2.3 value is "1002003"
  */
-#define LIBXSLT_VERSION_STRING "10116"
+#define LIBXSLT_VERSION_STRING "10117"
 
 /**
  * LIBXSLT_VERSION_EXTRA:

Modified: packages/libxslt/trunk/libxslt.spec
===================================================================
--- packages/libxslt/trunk/libxslt.spec	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/libxslt.spec	2006-06-08 22:29:07 UTC (rev 565)
@@ -1,14 +1,14 @@
 Summary: Library providing the Gnome XSLT engine
 Name: libxslt
-Version: 1.1.16
+Version: 1.1.17
 Release: 1
 License: MIT
 Group: Development/Libraries
 Source: ftp://xmlsoft.org/XSLT/libxslt-%{version}.tar.gz
 BuildRoot: %{_tmppath}/%{name}-%{version}-root
 URL: http://xmlsoft.org/XSLT/
-Requires: libxml2 >= 2.6.17
-BuildRequires: libxml2-devel >= 2.6.17
+Requires: libxml2 >= 2.6.25
+BuildRequires: libxml2-devel >= 2.6.25
 BuildRequires: python python-devel
 BuildRequires: libxml2-python
 BuildRequires: libgcrypt-devel
@@ -18,7 +18,7 @@
 %description
 This C library allows to transform XML files into other XML files
 (or HTML, text, ...) using the standard XSLT stylesheet transformation
-mechanism. To use it you need to have a version of libxml2 >= 2.6.17
+mechanism. To use it you need to have a version of libxml2 >= 2.6.25
 installed. The xsltproc command is a command line interface to the XSLT engine
 
 %package devel
@@ -27,19 +27,20 @@
 Requires: libxslt = %{version}
 Requires: libxml2-devel >= 2.5.6
 Requires: libgcrypt-devel
+Requires: pkgconfig
 
 %description devel
 This C library allows to transform XML files into other XML files
 (or HTML, text, ...) using the standard XSLT stylesheet transformation
-mechanism. To use it you need to have a version of libxml2 >= 2.6.17
+mechanism. To use it you need to have a version of libxml2 >= 2.6.25
 installed.
 
 %package python
 Summary: Python bindings for the libxslt library
 Group: Development/Libraries
 Requires: libxslt = %{version}
-Requires: libxml2 >= 2.6.17
-Requires: libxml2-python >= 2.6.17
+Requires: libxml2 >= 2.6.25
+Requires: libxml2-python >= 2.6.25
 Requires: %{_libdir}/python%(echo `python -c "import sys; print sys.version[0:3]"`)
 
 %description python
@@ -120,30 +121,5 @@
 %doc python/tests/*.xsl
 
 %changelog
-* Mon May  1 2006 Daniel Veillard <veillard at redhat.com>
-- upstream release 1.1.16 see http://xmlsoft.org/XSLT/news.html
-
-* Sun Nov  2 2003 Daniel Veillard <veillard at redhat.com>
-- cleanup, removal of the deprecated breakpoint library and
-  automated libxml2 dependancy level in the generated spec file.
-
-* Wed Oct 23 2002 Daniel Veillard <veillard at redhat.com>
-- revamped the spec file, cleaned up some rpm building problems
-
-* Wed Sep  4 2002 Daniel Veillard <veillard at redhat.com>
-
-- library paths fixed for x86-64
-
-* Fri Feb  8 2002 Daniel.Veillard <veillard at redhat.com>
-
-- added the python module
-- changed the Licence to MIT
-
-* Sat Nov 10 2001 Daniel.Veillard <daniel at veillard.com>
-
-- cleaned up the specfile
-
-* Mon Jan 22 2001 Daniel.Veillard <daniel at veillard.com>
-
-- created based on libxml2 spec file
-
+* Tue Jun  6 2006 Daniel Veillard <veillard at redhat.com>
+- upstream release 1.1.17 see http://xmlsoft.org/XSLT/news.html

Modified: packages/libxslt/trunk/libxslt.spec.in
===================================================================
--- packages/libxslt/trunk/libxslt.spec.in	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/libxslt.spec.in	2006-06-08 22:29:07 UTC (rev 565)
@@ -27,6 +27,7 @@
 Requires: libxslt = %{version}
 Requires: libxml2-devel >= 2.5.6
 Requires: libgcrypt-devel
+Requires: pkgconfig
 
 %description devel
 This C library allows to transform XML files into other XML files
@@ -122,28 +123,3 @@
 %changelog
 * @RELDATE@ Daniel Veillard <veillard at redhat.com>
 - upstream release @VERSION@ see http://xmlsoft.org/XSLT/news.html
-
-* Sun Nov  2 2003 Daniel Veillard <veillard at redhat.com>
-- cleanup, removal of the deprecated breakpoint library and
-  automated libxml2 dependancy level in the generated spec file.
-
-* Wed Oct 23 2002 Daniel Veillard <veillard at redhat.com>
-- revamped the spec file, cleaned up some rpm building problems
-
-* Wed Sep  4 2002 Daniel Veillard <veillard at redhat.com>
-
-- library paths fixed for x86-64
-
-* Fri Feb  8 2002 Daniel.Veillard <veillard at redhat.com>
-
-- added the python module
-- changed the Licence to MIT
-
-* Sat Nov 10 2001 Daniel.Veillard <daniel at veillard.com>
-
-- cleaned up the specfile
-
-* Mon Jan 22 2001 Daniel.Veillard <daniel at veillard.com>
-
-- created based on libxml2 spec file
-

Modified: packages/libxslt/trunk/python/Makefile.in
===================================================================
--- packages/libxslt/trunk/python/Makefile.in	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/python/Makefile.in	2006-06-08 22:29:07 UTC (rev 565)
@@ -119,6 +119,7 @@
 EXTRA_LIBS = @EXTRA_LIBS@
 F77 = @F77@
 FFLAGS = @FFLAGS@
+GREP = @GREP@
 HTML_DIR = @HTML_DIR@
 INSTALL_DATA = @INSTALL_DATA@
 INSTALL_PROGRAM = @INSTALL_PROGRAM@
@@ -204,12 +205,9 @@
 XSLT_INCLUDEDIR = @XSLT_INCLUDEDIR@
 XSLT_LIBDIR = @XSLT_LIBDIR@
 XSLT_LIBS = @XSLT_LIBS@
-ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_CXX = @ac_ct_CXX@
 ac_ct_F77 = @ac_ct_F77@
-ac_ct_RANLIB = @ac_ct_RANLIB@
-ac_ct_STRIP = @ac_ct_STRIP@
 am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
 am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
 am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@
@@ -226,23 +224,30 @@
 build_os = @build_os@
 build_vendor = @build_vendor@
 datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
 exec_prefix = @exec_prefix@
 host = @host@
 host_alias = @host_alias@
 host_cpu = @host_cpu@
 host_os = @host_os@
 host_vendor = @host_vendor@
+htmldir = @htmldir@
 includedir = @includedir@
 infodir = @infodir@
 install_sh = @install_sh@
 libdir = @libdir@
 libexecdir = @libexecdir@
+localedir = @localedir@
 localstatedir = @localstatedir@
 mandir = @mandir@
 mkdir_p = @mkdir_p@
 oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
 prefix = @prefix@
 program_transform_name = @program_transform_name@
+psdir = @psdir@
 pythondir = @pythondir@
 sbindir = @sbindir@
 sharedstatedir = @sharedstatedir@

Modified: packages/libxslt/trunk/python/tests/Makefile.in
===================================================================
--- packages/libxslt/trunk/python/tests/Makefile.in	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/python/tests/Makefile.in	2006-06-08 22:29:07 UTC (rev 565)
@@ -80,6 +80,7 @@
 EXTRA_LIBS = @EXTRA_LIBS@
 F77 = @F77@
 FFLAGS = @FFLAGS@
+GREP = @GREP@
 HTML_DIR = @HTML_DIR@
 INSTALL_DATA = @INSTALL_DATA@
 INSTALL_PROGRAM = @INSTALL_PROGRAM@
@@ -165,12 +166,9 @@
 XSLT_INCLUDEDIR = @XSLT_INCLUDEDIR@
 XSLT_LIBDIR = @XSLT_LIBDIR@
 XSLT_LIBS = @XSLT_LIBS@
-ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_CXX = @ac_ct_CXX@
 ac_ct_F77 = @ac_ct_F77@
-ac_ct_RANLIB = @ac_ct_RANLIB@
-ac_ct_STRIP = @ac_ct_STRIP@
 am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
 am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
 am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@
@@ -187,23 +185,30 @@
 build_os = @build_os@
 build_vendor = @build_vendor@
 datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
 exec_prefix = @exec_prefix@
 host = @host@
 host_alias = @host_alias@
 host_cpu = @host_cpu@
 host_os = @host_os@
 host_vendor = @host_vendor@
+htmldir = @htmldir@
 includedir = @includedir@
 infodir = @infodir@
 install_sh = @install_sh@
 libdir = @libdir@
 libexecdir = @libexecdir@
+localedir = @localedir@
 localstatedir = @localstatedir@
 mandir = @mandir@
 mkdir_p = @mkdir_p@
 oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
 prefix = @prefix@
 program_transform_name = @program_transform_name@
+psdir = @psdir@
 pythondir = @pythondir@
 sbindir = @sbindir@
 sharedstatedir = @sharedstatedir@

Modified: packages/libxslt/trunk/tests/Makefile.in
===================================================================
--- packages/libxslt/trunk/tests/Makefile.in	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/tests/Makefile.in	2006-06-08 22:29:07 UTC (rev 565)
@@ -89,6 +89,7 @@
 EXTRA_LIBS = @EXTRA_LIBS@
 F77 = @F77@
 FFLAGS = @FFLAGS@
+GREP = @GREP@
 HTML_DIR = @HTML_DIR@
 INSTALL_DATA = @INSTALL_DATA@
 INSTALL_PROGRAM = @INSTALL_PROGRAM@
@@ -174,12 +175,9 @@
 XSLT_INCLUDEDIR = @XSLT_INCLUDEDIR@
 XSLT_LIBDIR = @XSLT_LIBDIR@
 XSLT_LIBS = @XSLT_LIBS@
-ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_CXX = @ac_ct_CXX@
 ac_ct_F77 = @ac_ct_F77@
-ac_ct_RANLIB = @ac_ct_RANLIB@
-ac_ct_STRIP = @ac_ct_STRIP@
 am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
 am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
 am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@
@@ -196,23 +194,30 @@
 build_os = @build_os@
 build_vendor = @build_vendor@
 datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
 exec_prefix = @exec_prefix@
 host = @host@
 host_alias = @host_alias@
 host_cpu = @host_cpu@
 host_os = @host_os@
 host_vendor = @host_vendor@
+htmldir = @htmldir@
 includedir = @includedir@
 infodir = @infodir@
 install_sh = @install_sh@
 libdir = @libdir@
 libexecdir = @libexecdir@
+localedir = @localedir@
 localstatedir = @localstatedir@
 mandir = @mandir@
 mkdir_p = @mkdir_p@
 oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
 prefix = @prefix@
 program_transform_name = @program_transform_name@
+psdir = @psdir@
 pythondir = @pythondir@
 sbindir = @sbindir@
 sharedstatedir = @sharedstatedir@

Modified: packages/libxslt/trunk/tests/REC/Makefile.in
===================================================================
--- packages/libxslt/trunk/tests/REC/Makefile.in	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/tests/REC/Makefile.in	2006-06-08 22:29:07 UTC (rev 565)
@@ -80,6 +80,7 @@
 EXTRA_LIBS = @EXTRA_LIBS@
 F77 = @F77@
 FFLAGS = @FFLAGS@
+GREP = @GREP@
 HTML_DIR = @HTML_DIR@
 INSTALL_DATA = @INSTALL_DATA@
 INSTALL_PROGRAM = @INSTALL_PROGRAM@
@@ -165,12 +166,9 @@
 XSLT_INCLUDEDIR = @XSLT_INCLUDEDIR@
 XSLT_LIBDIR = @XSLT_LIBDIR@
 XSLT_LIBS = @XSLT_LIBS@
-ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_CXX = @ac_ct_CXX@
 ac_ct_F77 = @ac_ct_F77@
-ac_ct_RANLIB = @ac_ct_RANLIB@
-ac_ct_STRIP = @ac_ct_STRIP@
 am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
 am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
 am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@
@@ -187,23 +185,30 @@
 build_os = @build_os@
 build_vendor = @build_vendor@
 datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
 exec_prefix = @exec_prefix@
 host = @host@
 host_alias = @host_alias@
 host_cpu = @host_cpu@
 host_os = @host_os@
 host_vendor = @host_vendor@
+htmldir = @htmldir@
 includedir = @includedir@
 infodir = @infodir@
 install_sh = @install_sh@
 libdir = @libdir@
 libexecdir = @libexecdir@
+localedir = @localedir@
 localstatedir = @localstatedir@
 mandir = @mandir@
 mkdir_p = @mkdir_p@
 oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
 prefix = @prefix@
 program_transform_name = @program_transform_name@
+psdir = @psdir@
 pythondir = @pythondir@
 sbindir = @sbindir@
 sharedstatedir = @sharedstatedir@

Modified: packages/libxslt/trunk/tests/REC1/Makefile.in
===================================================================
--- packages/libxslt/trunk/tests/REC1/Makefile.in	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/tests/REC1/Makefile.in	2006-06-08 22:29:07 UTC (rev 565)
@@ -80,6 +80,7 @@
 EXTRA_LIBS = @EXTRA_LIBS@
 F77 = @F77@
 FFLAGS = @FFLAGS@
+GREP = @GREP@
 HTML_DIR = @HTML_DIR@
 INSTALL_DATA = @INSTALL_DATA@
 INSTALL_PROGRAM = @INSTALL_PROGRAM@
@@ -165,12 +166,9 @@
 XSLT_INCLUDEDIR = @XSLT_INCLUDEDIR@
 XSLT_LIBDIR = @XSLT_LIBDIR@
 XSLT_LIBS = @XSLT_LIBS@
-ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_CXX = @ac_ct_CXX@
 ac_ct_F77 = @ac_ct_F77@
-ac_ct_RANLIB = @ac_ct_RANLIB@
-ac_ct_STRIP = @ac_ct_STRIP@
 am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
 am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
 am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@
@@ -187,23 +185,30 @@
 build_os = @build_os@
 build_vendor = @build_vendor@
 datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
 exec_prefix = @exec_prefix@
 host = @host@
 host_alias = @host_alias@
 host_cpu = @host_cpu@
 host_os = @host_os@
 host_vendor = @host_vendor@
+htmldir = @htmldir@
 includedir = @includedir@
 infodir = @infodir@
 install_sh = @install_sh@
 libdir = @libdir@
 libexecdir = @libexecdir@
+localedir = @localedir@
 localstatedir = @localstatedir@
 mandir = @mandir@
 mkdir_p = @mkdir_p@
 oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
 prefix = @prefix@
 program_transform_name = @program_transform_name@
+psdir = @psdir@
 pythondir = @pythondir@
 sbindir = @sbindir@
 sharedstatedir = @sharedstatedir@

Modified: packages/libxslt/trunk/tests/REC2/Makefile.in
===================================================================
--- packages/libxslt/trunk/tests/REC2/Makefile.in	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/tests/REC2/Makefile.in	2006-06-08 22:29:07 UTC (rev 565)
@@ -80,6 +80,7 @@
 EXTRA_LIBS = @EXTRA_LIBS@
 F77 = @F77@
 FFLAGS = @FFLAGS@
+GREP = @GREP@
 HTML_DIR = @HTML_DIR@
 INSTALL_DATA = @INSTALL_DATA@
 INSTALL_PROGRAM = @INSTALL_PROGRAM@
@@ -165,12 +166,9 @@
 XSLT_INCLUDEDIR = @XSLT_INCLUDEDIR@
 XSLT_LIBDIR = @XSLT_LIBDIR@
 XSLT_LIBS = @XSLT_LIBS@
-ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_CXX = @ac_ct_CXX@
 ac_ct_F77 = @ac_ct_F77@
-ac_ct_RANLIB = @ac_ct_RANLIB@
-ac_ct_STRIP = @ac_ct_STRIP@
 am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
 am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
 am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@
@@ -187,23 +185,30 @@
 build_os = @build_os@
 build_vendor = @build_vendor@
 datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
 exec_prefix = @exec_prefix@
 host = @host@
 host_alias = @host_alias@
 host_cpu = @host_cpu@
 host_os = @host_os@
 host_vendor = @host_vendor@
+htmldir = @htmldir@
 includedir = @includedir@
 infodir = @infodir@
 install_sh = @install_sh@
 libdir = @libdir@
 libexecdir = @libexecdir@
+localedir = @localedir@
 localstatedir = @localstatedir@
 mandir = @mandir@
 mkdir_p = @mkdir_p@
 oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
 prefix = @prefix@
 program_transform_name = @program_transform_name@
+psdir = @psdir@
 pythondir = @pythondir@
 sbindir = @sbindir@
 sharedstatedir = @sharedstatedir@

Modified: packages/libxslt/trunk/tests/XSLTMark/Makefile.in
===================================================================
--- packages/libxslt/trunk/tests/XSLTMark/Makefile.in	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/tests/XSLTMark/Makefile.in	2006-06-08 22:29:07 UTC (rev 565)
@@ -80,6 +80,7 @@
 EXTRA_LIBS = @EXTRA_LIBS@
 F77 = @F77@
 FFLAGS = @FFLAGS@
+GREP = @GREP@
 HTML_DIR = @HTML_DIR@
 INSTALL_DATA = @INSTALL_DATA@
 INSTALL_PROGRAM = @INSTALL_PROGRAM@
@@ -165,12 +166,9 @@
 XSLT_INCLUDEDIR = @XSLT_INCLUDEDIR@
 XSLT_LIBDIR = @XSLT_LIBDIR@
 XSLT_LIBS = @XSLT_LIBS@
-ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_CXX = @ac_ct_CXX@
 ac_ct_F77 = @ac_ct_F77@
-ac_ct_RANLIB = @ac_ct_RANLIB@
-ac_ct_STRIP = @ac_ct_STRIP@
 am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
 am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
 am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@
@@ -187,23 +185,30 @@
 build_os = @build_os@
 build_vendor = @build_vendor@
 datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
 exec_prefix = @exec_prefix@
 host = @host@
 host_alias = @host_alias@
 host_cpu = @host_cpu@
 host_os = @host_os@
 host_vendor = @host_vendor@
+htmldir = @htmldir@
 includedir = @includedir@
 infodir = @infodir@
 install_sh = @install_sh@
 libdir = @libdir@
 libexecdir = @libexecdir@
+localedir = @localedir@
 localstatedir = @localstatedir@
 mandir = @mandir@
 mkdir_p = @mkdir_p@
 oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
 prefix = @prefix@
 program_transform_name = @program_transform_name@
+psdir = @psdir@
 pythondir = @pythondir@
 sbindir = @sbindir@
 sharedstatedir = @sharedstatedir@

Modified: packages/libxslt/trunk/tests/docbook/Makefile.in
===================================================================
--- packages/libxslt/trunk/tests/docbook/Makefile.in	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/tests/docbook/Makefile.in	2006-06-08 22:29:07 UTC (rev 565)
@@ -81,6 +81,7 @@
 EXTRA_LIBS = @EXTRA_LIBS@
 F77 = @F77@
 FFLAGS = @FFLAGS@
+GREP = @GREP@
 HTML_DIR = @HTML_DIR@
 INSTALL_DATA = @INSTALL_DATA@
 INSTALL_PROGRAM = @INSTALL_PROGRAM@
@@ -166,12 +167,9 @@
 XSLT_INCLUDEDIR = @XSLT_INCLUDEDIR@
 XSLT_LIBDIR = @XSLT_LIBDIR@
 XSLT_LIBS = @XSLT_LIBS@
-ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_CXX = @ac_ct_CXX@
 ac_ct_F77 = @ac_ct_F77@
-ac_ct_RANLIB = @ac_ct_RANLIB@
-ac_ct_STRIP = @ac_ct_STRIP@
 am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
 am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
 am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@
@@ -188,23 +186,30 @@
 build_os = @build_os@
 build_vendor = @build_vendor@
 datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
 exec_prefix = @exec_prefix@
 host = @host@
 host_alias = @host_alias@
 host_cpu = @host_cpu@
 host_os = @host_os@
 host_vendor = @host_vendor@
+htmldir = @htmldir@
 includedir = @includedir@
 infodir = @infodir@
 install_sh = @install_sh@
 libdir = @libdir@
 libexecdir = @libexecdir@
+localedir = @localedir@
 localstatedir = @localstatedir@
 mandir = @mandir@
 mkdir_p = @mkdir_p@
 oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
 prefix = @prefix@
 program_transform_name = @program_transform_name@
+psdir = @psdir@
 pythondir = @pythondir@
 sbindir = @sbindir@
 sharedstatedir = @sharedstatedir@

Modified: packages/libxslt/trunk/tests/docs/Makefile.in
===================================================================
--- packages/libxslt/trunk/tests/docs/Makefile.in	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/tests/docs/Makefile.in	2006-06-08 22:29:07 UTC (rev 565)
@@ -84,6 +84,7 @@
 EXTRA_LIBS = @EXTRA_LIBS@
 F77 = @F77@
 FFLAGS = @FFLAGS@
+GREP = @GREP@
 HTML_DIR = @HTML_DIR@
 INSTALL_DATA = @INSTALL_DATA@
 INSTALL_PROGRAM = @INSTALL_PROGRAM@
@@ -169,12 +170,9 @@
 XSLT_INCLUDEDIR = @XSLT_INCLUDEDIR@
 XSLT_LIBDIR = @XSLT_LIBDIR@
 XSLT_LIBS = @XSLT_LIBS@
-ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_CXX = @ac_ct_CXX@
 ac_ct_F77 = @ac_ct_F77@
-ac_ct_RANLIB = @ac_ct_RANLIB@
-ac_ct_STRIP = @ac_ct_STRIP@
 am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
 am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
 am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@
@@ -191,23 +189,30 @@
 build_os = @build_os@
 build_vendor = @build_vendor@
 datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
 exec_prefix = @exec_prefix@
 host = @host@
 host_alias = @host_alias@
 host_cpu = @host_cpu@
 host_os = @host_os@
 host_vendor = @host_vendor@
+htmldir = @htmldir@
 includedir = @includedir@
 infodir = @infodir@
 install_sh = @install_sh@
 libdir = @libdir@
 libexecdir = @libexecdir@
+localedir = @localedir@
 localstatedir = @localstatedir@
 mandir = @mandir@
 mkdir_p = @mkdir_p@
 oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
 prefix = @prefix@
 program_transform_name = @program_transform_name@
+psdir = @psdir@
 pythondir = @pythondir@
 sbindir = @sbindir@
 sharedstatedir = @sharedstatedir@

Modified: packages/libxslt/trunk/tests/documents/Makefile.in
===================================================================
--- packages/libxslt/trunk/tests/documents/Makefile.in	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/tests/documents/Makefile.in	2006-06-08 22:29:07 UTC (rev 565)
@@ -80,6 +80,7 @@
 EXTRA_LIBS = @EXTRA_LIBS@
 F77 = @F77@
 FFLAGS = @FFLAGS@
+GREP = @GREP@
 HTML_DIR = @HTML_DIR@
 INSTALL_DATA = @INSTALL_DATA@
 INSTALL_PROGRAM = @INSTALL_PROGRAM@
@@ -165,12 +166,9 @@
 XSLT_INCLUDEDIR = @XSLT_INCLUDEDIR@
 XSLT_LIBDIR = @XSLT_LIBDIR@
 XSLT_LIBS = @XSLT_LIBS@
-ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_CXX = @ac_ct_CXX@
 ac_ct_F77 = @ac_ct_F77@
-ac_ct_RANLIB = @ac_ct_RANLIB@
-ac_ct_STRIP = @ac_ct_STRIP@
 am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
 am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
 am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@
@@ -187,23 +185,30 @@
 build_os = @build_os@
 build_vendor = @build_vendor@
 datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
 exec_prefix = @exec_prefix@
 host = @host@
 host_alias = @host_alias@
 host_cpu = @host_cpu@
 host_os = @host_os@
 host_vendor = @host_vendor@
+htmldir = @htmldir@
 includedir = @includedir@
 infodir = @infodir@
 install_sh = @install_sh@
 libdir = @libdir@
 libexecdir = @libexecdir@
+localedir = @localedir@
 localstatedir = @localstatedir@
 mandir = @mandir@
 mkdir_p = @mkdir_p@
 oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
 prefix = @prefix@
 program_transform_name = @program_transform_name@
+psdir = @psdir@
 pythondir = @pythondir@
 sbindir = @sbindir@
 sharedstatedir = @sharedstatedir@

Modified: packages/libxslt/trunk/tests/exslt/Makefile.in
===================================================================
--- packages/libxslt/trunk/tests/exslt/Makefile.in	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/tests/exslt/Makefile.in	2006-06-08 22:29:07 UTC (rev 565)
@@ -89,6 +89,7 @@
 EXTRA_LIBS = @EXTRA_LIBS@
 F77 = @F77@
 FFLAGS = @FFLAGS@
+GREP = @GREP@
 HTML_DIR = @HTML_DIR@
 INSTALL_DATA = @INSTALL_DATA@
 INSTALL_PROGRAM = @INSTALL_PROGRAM@
@@ -174,12 +175,9 @@
 XSLT_INCLUDEDIR = @XSLT_INCLUDEDIR@
 XSLT_LIBDIR = @XSLT_LIBDIR@
 XSLT_LIBS = @XSLT_LIBS@
-ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_CXX = @ac_ct_CXX@
 ac_ct_F77 = @ac_ct_F77@
-ac_ct_RANLIB = @ac_ct_RANLIB@
-ac_ct_STRIP = @ac_ct_STRIP@
 am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
 am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
 am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@
@@ -196,23 +194,30 @@
 build_os = @build_os@
 build_vendor = @build_vendor@
 datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
 exec_prefix = @exec_prefix@
 host = @host@
 host_alias = @host_alias@
 host_cpu = @host_cpu@
 host_os = @host_os@
 host_vendor = @host_vendor@
+htmldir = @htmldir@
 includedir = @includedir@
 infodir = @infodir@
 install_sh = @install_sh@
 libdir = @libdir@
 libexecdir = @libexecdir@
+localedir = @localedir@
 localstatedir = @localstatedir@
 mandir = @mandir@
 mkdir_p = @mkdir_p@
 oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
 prefix = @prefix@
 program_transform_name = @program_transform_name@
+psdir = @psdir@
 pythondir = @pythondir@
 sbindir = @sbindir@
 sharedstatedir = @sharedstatedir@

Modified: packages/libxslt/trunk/tests/exslt/common/Makefile.in
===================================================================
--- packages/libxslt/trunk/tests/exslt/common/Makefile.in	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/tests/exslt/common/Makefile.in	2006-06-08 22:29:07 UTC (rev 565)
@@ -80,6 +80,7 @@
 EXTRA_LIBS = @EXTRA_LIBS@
 F77 = @F77@
 FFLAGS = @FFLAGS@
+GREP = @GREP@
 HTML_DIR = @HTML_DIR@
 INSTALL_DATA = @INSTALL_DATA@
 INSTALL_PROGRAM = @INSTALL_PROGRAM@
@@ -165,12 +166,9 @@
 XSLT_INCLUDEDIR = @XSLT_INCLUDEDIR@
 XSLT_LIBDIR = @XSLT_LIBDIR@
 XSLT_LIBS = @XSLT_LIBS@
-ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_CXX = @ac_ct_CXX@
 ac_ct_F77 = @ac_ct_F77@
-ac_ct_RANLIB = @ac_ct_RANLIB@
-ac_ct_STRIP = @ac_ct_STRIP@
 am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
 am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
 am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@
@@ -187,23 +185,30 @@
 build_os = @build_os@
 build_vendor = @build_vendor@
 datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
 exec_prefix = @exec_prefix@
 host = @host@
 host_alias = @host_alias@
 host_cpu = @host_cpu@
 host_os = @host_os@
 host_vendor = @host_vendor@
+htmldir = @htmldir@
 includedir = @includedir@
 infodir = @infodir@
 install_sh = @install_sh@
 libdir = @libdir@
 libexecdir = @libexecdir@
+localedir = @localedir@
 localstatedir = @localstatedir@
 mandir = @mandir@
 mkdir_p = @mkdir_p@
 oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
 prefix = @prefix@
 program_transform_name = @program_transform_name@
+psdir = @psdir@
 pythondir = @pythondir@
 sbindir = @sbindir@
 sharedstatedir = @sharedstatedir@

Modified: packages/libxslt/trunk/tests/exslt/date/Makefile.in
===================================================================
--- packages/libxslt/trunk/tests/exslt/date/Makefile.in	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/tests/exslt/date/Makefile.in	2006-06-08 22:29:07 UTC (rev 565)
@@ -80,6 +80,7 @@
 EXTRA_LIBS = @EXTRA_LIBS@
 F77 = @F77@
 FFLAGS = @FFLAGS@
+GREP = @GREP@
 HTML_DIR = @HTML_DIR@
 INSTALL_DATA = @INSTALL_DATA@
 INSTALL_PROGRAM = @INSTALL_PROGRAM@
@@ -165,12 +166,9 @@
 XSLT_INCLUDEDIR = @XSLT_INCLUDEDIR@
 XSLT_LIBDIR = @XSLT_LIBDIR@
 XSLT_LIBS = @XSLT_LIBS@
-ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_CXX = @ac_ct_CXX@
 ac_ct_F77 = @ac_ct_F77@
-ac_ct_RANLIB = @ac_ct_RANLIB@
-ac_ct_STRIP = @ac_ct_STRIP@
 am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
 am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
 am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@
@@ -187,23 +185,30 @@
 build_os = @build_os@
 build_vendor = @build_vendor@
 datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
 exec_prefix = @exec_prefix@
 host = @host@
 host_alias = @host_alias@
 host_cpu = @host_cpu@
 host_os = @host_os@
 host_vendor = @host_vendor@
+htmldir = @htmldir@
 includedir = @includedir@
 infodir = @infodir@
 install_sh = @install_sh@
 libdir = @libdir@
 libexecdir = @libexecdir@
+localedir = @localedir@
 localstatedir = @localstatedir@
 mandir = @mandir@
 mkdir_p = @mkdir_p@
 oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
 prefix = @prefix@
 program_transform_name = @program_transform_name@
+psdir = @psdir@
 pythondir = @pythondir@
 sbindir = @sbindir@
 sharedstatedir = @sharedstatedir@

Modified: packages/libxslt/trunk/tests/exslt/dynamic/Makefile.in
===================================================================
--- packages/libxslt/trunk/tests/exslt/dynamic/Makefile.in	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/tests/exslt/dynamic/Makefile.in	2006-06-08 22:29:07 UTC (rev 565)
@@ -80,6 +80,7 @@
 EXTRA_LIBS = @EXTRA_LIBS@
 F77 = @F77@
 FFLAGS = @FFLAGS@
+GREP = @GREP@
 HTML_DIR = @HTML_DIR@
 INSTALL_DATA = @INSTALL_DATA@
 INSTALL_PROGRAM = @INSTALL_PROGRAM@
@@ -165,12 +166,9 @@
 XSLT_INCLUDEDIR = @XSLT_INCLUDEDIR@
 XSLT_LIBDIR = @XSLT_LIBDIR@
 XSLT_LIBS = @XSLT_LIBS@
-ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_CXX = @ac_ct_CXX@
 ac_ct_F77 = @ac_ct_F77@
-ac_ct_RANLIB = @ac_ct_RANLIB@
-ac_ct_STRIP = @ac_ct_STRIP@
 am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
 am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
 am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@
@@ -187,23 +185,30 @@
 build_os = @build_os@
 build_vendor = @build_vendor@
 datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
 exec_prefix = @exec_prefix@
 host = @host@
 host_alias = @host_alias@
 host_cpu = @host_cpu@
 host_os = @host_os@
 host_vendor = @host_vendor@
+htmldir = @htmldir@
 includedir = @includedir@
 infodir = @infodir@
 install_sh = @install_sh@
 libdir = @libdir@
 libexecdir = @libexecdir@
+localedir = @localedir@
 localstatedir = @localstatedir@
 mandir = @mandir@
 mkdir_p = @mkdir_p@
 oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
 prefix = @prefix@
 program_transform_name = @program_transform_name@
+psdir = @psdir@
 pythondir = @pythondir@
 sbindir = @sbindir@
 sharedstatedir = @sharedstatedir@

Modified: packages/libxslt/trunk/tests/exslt/functions/Makefile.in
===================================================================
--- packages/libxslt/trunk/tests/exslt/functions/Makefile.in	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/tests/exslt/functions/Makefile.in	2006-06-08 22:29:07 UTC (rev 565)
@@ -80,6 +80,7 @@
 EXTRA_LIBS = @EXTRA_LIBS@
 F77 = @F77@
 FFLAGS = @FFLAGS@
+GREP = @GREP@
 HTML_DIR = @HTML_DIR@
 INSTALL_DATA = @INSTALL_DATA@
 INSTALL_PROGRAM = @INSTALL_PROGRAM@
@@ -165,12 +166,9 @@
 XSLT_INCLUDEDIR = @XSLT_INCLUDEDIR@
 XSLT_LIBDIR = @XSLT_LIBDIR@
 XSLT_LIBS = @XSLT_LIBS@
-ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_CXX = @ac_ct_CXX@
 ac_ct_F77 = @ac_ct_F77@
-ac_ct_RANLIB = @ac_ct_RANLIB@
-ac_ct_STRIP = @ac_ct_STRIP@
 am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
 am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
 am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@
@@ -187,23 +185,30 @@
 build_os = @build_os@
 build_vendor = @build_vendor@
 datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
 exec_prefix = @exec_prefix@
 host = @host@
 host_alias = @host_alias@
 host_cpu = @host_cpu@
 host_os = @host_os@
 host_vendor = @host_vendor@
+htmldir = @htmldir@
 includedir = @includedir@
 infodir = @infodir@
 install_sh = @install_sh@
 libdir = @libdir@
 libexecdir = @libexecdir@
+localedir = @localedir@
 localstatedir = @localstatedir@
 mandir = @mandir@
 mkdir_p = @mkdir_p@
 oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
 prefix = @prefix@
 program_transform_name = @program_transform_name@
+psdir = @psdir@
 pythondir = @pythondir@
 sbindir = @sbindir@
 sharedstatedir = @sharedstatedir@

Modified: packages/libxslt/trunk/tests/exslt/math/Makefile.in
===================================================================
--- packages/libxslt/trunk/tests/exslt/math/Makefile.in	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/tests/exslt/math/Makefile.in	2006-06-08 22:29:07 UTC (rev 565)
@@ -80,6 +80,7 @@
 EXTRA_LIBS = @EXTRA_LIBS@
 F77 = @F77@
 FFLAGS = @FFLAGS@
+GREP = @GREP@
 HTML_DIR = @HTML_DIR@
 INSTALL_DATA = @INSTALL_DATA@
 INSTALL_PROGRAM = @INSTALL_PROGRAM@
@@ -165,12 +166,9 @@
 XSLT_INCLUDEDIR = @XSLT_INCLUDEDIR@
 XSLT_LIBDIR = @XSLT_LIBDIR@
 XSLT_LIBS = @XSLT_LIBS@
-ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_CXX = @ac_ct_CXX@
 ac_ct_F77 = @ac_ct_F77@
-ac_ct_RANLIB = @ac_ct_RANLIB@
-ac_ct_STRIP = @ac_ct_STRIP@
 am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
 am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
 am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@
@@ -187,23 +185,30 @@
 build_os = @build_os@
 build_vendor = @build_vendor@
 datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
 exec_prefix = @exec_prefix@
 host = @host@
 host_alias = @host_alias@
 host_cpu = @host_cpu@
 host_os = @host_os@
 host_vendor = @host_vendor@
+htmldir = @htmldir@
 includedir = @includedir@
 infodir = @infodir@
 install_sh = @install_sh@
 libdir = @libdir@
 libexecdir = @libexecdir@
+localedir = @localedir@
 localstatedir = @localstatedir@
 mandir = @mandir@
 mkdir_p = @mkdir_p@
 oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
 prefix = @prefix@
 program_transform_name = @program_transform_name@
+psdir = @psdir@
 pythondir = @pythondir@
 sbindir = @sbindir@
 sharedstatedir = @sharedstatedir@

Modified: packages/libxslt/trunk/tests/exslt/sets/Makefile.in
===================================================================
--- packages/libxslt/trunk/tests/exslt/sets/Makefile.in	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/tests/exslt/sets/Makefile.in	2006-06-08 22:29:07 UTC (rev 565)
@@ -80,6 +80,7 @@
 EXTRA_LIBS = @EXTRA_LIBS@
 F77 = @F77@
 FFLAGS = @FFLAGS@
+GREP = @GREP@
 HTML_DIR = @HTML_DIR@
 INSTALL_DATA = @INSTALL_DATA@
 INSTALL_PROGRAM = @INSTALL_PROGRAM@
@@ -165,12 +166,9 @@
 XSLT_INCLUDEDIR = @XSLT_INCLUDEDIR@
 XSLT_LIBDIR = @XSLT_LIBDIR@
 XSLT_LIBS = @XSLT_LIBS@
-ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_CXX = @ac_ct_CXX@
 ac_ct_F77 = @ac_ct_F77@
-ac_ct_RANLIB = @ac_ct_RANLIB@
-ac_ct_STRIP = @ac_ct_STRIP@
 am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
 am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
 am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@
@@ -187,23 +185,30 @@
 build_os = @build_os@
 build_vendor = @build_vendor@
 datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
 exec_prefix = @exec_prefix@
 host = @host@
 host_alias = @host_alias@
 host_cpu = @host_cpu@
 host_os = @host_os@
 host_vendor = @host_vendor@
+htmldir = @htmldir@
 includedir = @includedir@
 infodir = @infodir@
 install_sh = @install_sh@
 libdir = @libdir@
 libexecdir = @libexecdir@
+localedir = @localedir@
 localstatedir = @localstatedir@
 mandir = @mandir@
 mkdir_p = @mkdir_p@
 oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
 prefix = @prefix@
 program_transform_name = @program_transform_name@
+psdir = @psdir@
 pythondir = @pythondir@
 sbindir = @sbindir@
 sharedstatedir = @sharedstatedir@

Modified: packages/libxslt/trunk/tests/exslt/strings/Makefile.in
===================================================================
--- packages/libxslt/trunk/tests/exslt/strings/Makefile.in	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/tests/exslt/strings/Makefile.in	2006-06-08 22:29:07 UTC (rev 565)
@@ -80,6 +80,7 @@
 EXTRA_LIBS = @EXTRA_LIBS@
 F77 = @F77@
 FFLAGS = @FFLAGS@
+GREP = @GREP@
 HTML_DIR = @HTML_DIR@
 INSTALL_DATA = @INSTALL_DATA@
 INSTALL_PROGRAM = @INSTALL_PROGRAM@
@@ -165,12 +166,9 @@
 XSLT_INCLUDEDIR = @XSLT_INCLUDEDIR@
 XSLT_LIBDIR = @XSLT_LIBDIR@
 XSLT_LIBS = @XSLT_LIBS@
-ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_CXX = @ac_ct_CXX@
 ac_ct_F77 = @ac_ct_F77@
-ac_ct_RANLIB = @ac_ct_RANLIB@
-ac_ct_STRIP = @ac_ct_STRIP@
 am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
 am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
 am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@
@@ -187,23 +185,30 @@
 build_os = @build_os@
 build_vendor = @build_vendor@
 datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
 exec_prefix = @exec_prefix@
 host = @host@
 host_alias = @host_alias@
 host_cpu = @host_cpu@
 host_os = @host_os@
 host_vendor = @host_vendor@
+htmldir = @htmldir@
 includedir = @includedir@
 infodir = @infodir@
 install_sh = @install_sh@
 libdir = @libdir@
 libexecdir = @libexecdir@
+localedir = @localedir@
 localstatedir = @localstatedir@
 mandir = @mandir@
 mkdir_p = @mkdir_p@
 oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
 prefix = @prefix@
 program_transform_name = @program_transform_name@
+psdir = @psdir@
 pythondir = @pythondir@
 sbindir = @sbindir@
 sharedstatedir = @sharedstatedir@

Modified: packages/libxslt/trunk/tests/extensions/Makefile.in
===================================================================
--- packages/libxslt/trunk/tests/extensions/Makefile.in	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/tests/extensions/Makefile.in	2006-06-08 22:29:07 UTC (rev 565)
@@ -80,6 +80,7 @@
 EXTRA_LIBS = @EXTRA_LIBS@
 F77 = @F77@
 FFLAGS = @FFLAGS@
+GREP = @GREP@
 HTML_DIR = @HTML_DIR@
 INSTALL_DATA = @INSTALL_DATA@
 INSTALL_PROGRAM = @INSTALL_PROGRAM@
@@ -165,12 +166,9 @@
 XSLT_INCLUDEDIR = @XSLT_INCLUDEDIR@
 XSLT_LIBDIR = @XSLT_LIBDIR@
 XSLT_LIBS = @XSLT_LIBS@
-ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_CXX = @ac_ct_CXX@
 ac_ct_F77 = @ac_ct_F77@
-ac_ct_RANLIB = @ac_ct_RANLIB@
-ac_ct_STRIP = @ac_ct_STRIP@
 am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
 am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
 am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@
@@ -187,23 +185,30 @@
 build_os = @build_os@
 build_vendor = @build_vendor@
 datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
 exec_prefix = @exec_prefix@
 host = @host@
 host_alias = @host_alias@
 host_cpu = @host_cpu@
 host_os = @host_os@
 host_vendor = @host_vendor@
+htmldir = @htmldir@
 includedir = @includedir@
 infodir = @infodir@
 install_sh = @install_sh@
 libdir = @libdir@
 libexecdir = @libexecdir@
+localedir = @localedir@
 localstatedir = @localstatedir@
 mandir = @mandir@
 mkdir_p = @mkdir_p@
 oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
 prefix = @prefix@
 program_transform_name = @program_transform_name@
+psdir = @psdir@
 pythondir = @pythondir@
 sbindir = @sbindir@
 sharedstatedir = @sharedstatedir@

Modified: packages/libxslt/trunk/tests/general/Makefile.in
===================================================================
--- packages/libxslt/trunk/tests/general/Makefile.in	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/tests/general/Makefile.in	2006-06-08 22:29:07 UTC (rev 565)
@@ -80,6 +80,7 @@
 EXTRA_LIBS = @EXTRA_LIBS@
 F77 = @F77@
 FFLAGS = @FFLAGS@
+GREP = @GREP@
 HTML_DIR = @HTML_DIR@
 INSTALL_DATA = @INSTALL_DATA@
 INSTALL_PROGRAM = @INSTALL_PROGRAM@
@@ -165,12 +166,9 @@
 XSLT_INCLUDEDIR = @XSLT_INCLUDEDIR@
 XSLT_LIBDIR = @XSLT_LIBDIR@
 XSLT_LIBS = @XSLT_LIBS@
-ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_CXX = @ac_ct_CXX@
 ac_ct_F77 = @ac_ct_F77@
-ac_ct_RANLIB = @ac_ct_RANLIB@
-ac_ct_STRIP = @ac_ct_STRIP@
 am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
 am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
 am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@
@@ -187,23 +185,30 @@
 build_os = @build_os@
 build_vendor = @build_vendor@
 datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
 exec_prefix = @exec_prefix@
 host = @host@
 host_alias = @host_alias@
 host_cpu = @host_cpu@
 host_os = @host_os@
 host_vendor = @host_vendor@
+htmldir = @htmldir@
 includedir = @includedir@
 infodir = @infodir@
 install_sh = @install_sh@
 libdir = @libdir@
 libexecdir = @libexecdir@
+localedir = @localedir@
 localstatedir = @localstatedir@
 mandir = @mandir@
 mkdir_p = @mkdir_p@
 oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
 prefix = @prefix@
 program_transform_name = @program_transform_name@
+psdir = @psdir@
 pythondir = @pythondir@
 sbindir = @sbindir@
 sharedstatedir = @sharedstatedir@

Modified: packages/libxslt/trunk/tests/keys/Makefile.in
===================================================================
--- packages/libxslt/trunk/tests/keys/Makefile.in	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/tests/keys/Makefile.in	2006-06-08 22:29:07 UTC (rev 565)
@@ -80,6 +80,7 @@
 EXTRA_LIBS = @EXTRA_LIBS@
 F77 = @F77@
 FFLAGS = @FFLAGS@
+GREP = @GREP@
 HTML_DIR = @HTML_DIR@
 INSTALL_DATA = @INSTALL_DATA@
 INSTALL_PROGRAM = @INSTALL_PROGRAM@
@@ -165,12 +166,9 @@
 XSLT_INCLUDEDIR = @XSLT_INCLUDEDIR@
 XSLT_LIBDIR = @XSLT_LIBDIR@
 XSLT_LIBS = @XSLT_LIBS@
-ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_CXX = @ac_ct_CXX@
 ac_ct_F77 = @ac_ct_F77@
-ac_ct_RANLIB = @ac_ct_RANLIB@
-ac_ct_STRIP = @ac_ct_STRIP@
 am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
 am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
 am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@
@@ -187,23 +185,30 @@
 build_os = @build_os@
 build_vendor = @build_vendor@
 datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
 exec_prefix = @exec_prefix@
 host = @host@
 host_alias = @host_alias@
 host_cpu = @host_cpu@
 host_os = @host_os@
 host_vendor = @host_vendor@
+htmldir = @htmldir@
 includedir = @includedir@
 infodir = @infodir@
 install_sh = @install_sh@
 libdir = @libdir@
 libexecdir = @libexecdir@
+localedir = @localedir@
 localstatedir = @localstatedir@
 mandir = @mandir@
 mkdir_p = @mkdir_p@
 oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
 prefix = @prefix@
 program_transform_name = @program_transform_name@
+psdir = @psdir@
 pythondir = @pythondir@
 sbindir = @sbindir@
 sharedstatedir = @sharedstatedir@

Modified: packages/libxslt/trunk/tests/multiple/Makefile.in
===================================================================
--- packages/libxslt/trunk/tests/multiple/Makefile.in	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/tests/multiple/Makefile.in	2006-06-08 22:29:07 UTC (rev 565)
@@ -80,6 +80,7 @@
 EXTRA_LIBS = @EXTRA_LIBS@
 F77 = @F77@
 FFLAGS = @FFLAGS@
+GREP = @GREP@
 HTML_DIR = @HTML_DIR@
 INSTALL_DATA = @INSTALL_DATA@
 INSTALL_PROGRAM = @INSTALL_PROGRAM@
@@ -165,12 +166,9 @@
 XSLT_INCLUDEDIR = @XSLT_INCLUDEDIR@
 XSLT_LIBDIR = @XSLT_LIBDIR@
 XSLT_LIBS = @XSLT_LIBS@
-ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_CXX = @ac_ct_CXX@
 ac_ct_F77 = @ac_ct_F77@
-ac_ct_RANLIB = @ac_ct_RANLIB@
-ac_ct_STRIP = @ac_ct_STRIP@
 am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
 am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
 am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@
@@ -187,23 +185,30 @@
 build_os = @build_os@
 build_vendor = @build_vendor@
 datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
 exec_prefix = @exec_prefix@
 host = @host@
 host_alias = @host_alias@
 host_cpu = @host_cpu@
 host_os = @host_os@
 host_vendor = @host_vendor@
+htmldir = @htmldir@
 includedir = @includedir@
 infodir = @infodir@
 install_sh = @install_sh@
 libdir = @libdir@
 libexecdir = @libexecdir@
+localedir = @localedir@
 localstatedir = @localstatedir@
 mandir = @mandir@
 mkdir_p = @mkdir_p@
 oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
 prefix = @prefix@
 program_transform_name = @program_transform_name@
+psdir = @psdir@
 pythondir = @pythondir@
 sbindir = @sbindir@
 sharedstatedir = @sharedstatedir@

Modified: packages/libxslt/trunk/tests/namespaces/Makefile.in
===================================================================
--- packages/libxslt/trunk/tests/namespaces/Makefile.in	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/tests/namespaces/Makefile.in	2006-06-08 22:29:07 UTC (rev 565)
@@ -80,6 +80,7 @@
 EXTRA_LIBS = @EXTRA_LIBS@
 F77 = @F77@
 FFLAGS = @FFLAGS@
+GREP = @GREP@
 HTML_DIR = @HTML_DIR@
 INSTALL_DATA = @INSTALL_DATA@
 INSTALL_PROGRAM = @INSTALL_PROGRAM@
@@ -165,12 +166,9 @@
 XSLT_INCLUDEDIR = @XSLT_INCLUDEDIR@
 XSLT_LIBDIR = @XSLT_LIBDIR@
 XSLT_LIBS = @XSLT_LIBS@
-ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_CXX = @ac_ct_CXX@
 ac_ct_F77 = @ac_ct_F77@
-ac_ct_RANLIB = @ac_ct_RANLIB@
-ac_ct_STRIP = @ac_ct_STRIP@
 am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
 am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
 am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@
@@ -187,23 +185,30 @@
 build_os = @build_os@
 build_vendor = @build_vendor@
 datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
 exec_prefix = @exec_prefix@
 host = @host@
 host_alias = @host_alias@
 host_cpu = @host_cpu@
 host_os = @host_os@
 host_vendor = @host_vendor@
+htmldir = @htmldir@
 includedir = @includedir@
 infodir = @infodir@
 install_sh = @install_sh@
 libdir = @libdir@
 libexecdir = @libexecdir@
+localedir = @localedir@
 localstatedir = @localstatedir@
 mandir = @mandir@
 mkdir_p = @mkdir_p@
 oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
 prefix = @prefix@
 program_transform_name = @program_transform_name@
+psdir = @psdir@
 pythondir = @pythondir@
 sbindir = @sbindir@
 sharedstatedir = @sharedstatedir@

Modified: packages/libxslt/trunk/tests/numbers/Makefile.in
===================================================================
--- packages/libxslt/trunk/tests/numbers/Makefile.in	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/tests/numbers/Makefile.in	2006-06-08 22:29:07 UTC (rev 565)
@@ -80,6 +80,7 @@
 EXTRA_LIBS = @EXTRA_LIBS@
 F77 = @F77@
 FFLAGS = @FFLAGS@
+GREP = @GREP@
 HTML_DIR = @HTML_DIR@
 INSTALL_DATA = @INSTALL_DATA@
 INSTALL_PROGRAM = @INSTALL_PROGRAM@
@@ -165,12 +166,9 @@
 XSLT_INCLUDEDIR = @XSLT_INCLUDEDIR@
 XSLT_LIBDIR = @XSLT_LIBDIR@
 XSLT_LIBS = @XSLT_LIBS@
-ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_CXX = @ac_ct_CXX@
 ac_ct_F77 = @ac_ct_F77@
-ac_ct_RANLIB = @ac_ct_RANLIB@
-ac_ct_STRIP = @ac_ct_STRIP@
 am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
 am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
 am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@
@@ -187,23 +185,30 @@
 build_os = @build_os@
 build_vendor = @build_vendor@
 datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
 exec_prefix = @exec_prefix@
 host = @host@
 host_alias = @host_alias@
 host_cpu = @host_cpu@
 host_os = @host_os@
 host_vendor = @host_vendor@
+htmldir = @htmldir@
 includedir = @includedir@
 infodir = @infodir@
 install_sh = @install_sh@
 libdir = @libdir@
 libexecdir = @libexecdir@
+localedir = @localedir@
 localstatedir = @localstatedir@
 mandir = @mandir@
 mkdir_p = @mkdir_p@
 oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
 prefix = @prefix@
 program_transform_name = @program_transform_name@
+psdir = @psdir@
 pythondir = @pythondir@
 sbindir = @sbindir@
 sharedstatedir = @sharedstatedir@

Modified: packages/libxslt/trunk/tests/plugins/Makefile.in
===================================================================
--- packages/libxslt/trunk/tests/plugins/Makefile.in	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/tests/plugins/Makefile.in	2006-06-08 22:29:07 UTC (rev 565)
@@ -100,6 +100,7 @@
 EXTRA_LIBS = @EXTRA_LIBS@
 F77 = @F77@
 FFLAGS = @FFLAGS@
+GREP = @GREP@
 HTML_DIR = @HTML_DIR@
 INSTALL_DATA = @INSTALL_DATA@
 INSTALL_PROGRAM = @INSTALL_PROGRAM@
@@ -185,12 +186,9 @@
 XSLT_INCLUDEDIR = @XSLT_INCLUDEDIR@
 XSLT_LIBDIR = @XSLT_LIBDIR@
 XSLT_LIBS = @XSLT_LIBS@
-ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_CXX = @ac_ct_CXX@
 ac_ct_F77 = @ac_ct_F77@
-ac_ct_RANLIB = @ac_ct_RANLIB@
-ac_ct_STRIP = @ac_ct_STRIP@
 am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
 am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
 am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@
@@ -207,23 +205,30 @@
 build_os = @build_os@
 build_vendor = @build_vendor@
 datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
 exec_prefix = @exec_prefix@
 host = @host@
 host_alias = @host_alias@
 host_cpu = @host_cpu@
 host_os = @host_os@
 host_vendor = @host_vendor@
+htmldir = @htmldir@
 includedir = @includedir@
 infodir = @infodir@
 install_sh = @install_sh@
 libdir = @libdir@
 libexecdir = @libexecdir@
+localedir = @localedir@
 localstatedir = @localstatedir@
 mandir = @mandir@
 mkdir_p = @mkdir_p@
 oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
 prefix = @prefix@
 program_transform_name = @program_transform_name@
+psdir = @psdir@
 pythondir = @pythondir@
 sbindir = @sbindir@
 sharedstatedir = @sharedstatedir@

Modified: packages/libxslt/trunk/tests/reports/Makefile.in
===================================================================
--- packages/libxslt/trunk/tests/reports/Makefile.in	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/tests/reports/Makefile.in	2006-06-08 22:29:07 UTC (rev 565)
@@ -80,6 +80,7 @@
 EXTRA_LIBS = @EXTRA_LIBS@
 F77 = @F77@
 FFLAGS = @FFLAGS@
+GREP = @GREP@
 HTML_DIR = @HTML_DIR@
 INSTALL_DATA = @INSTALL_DATA@
 INSTALL_PROGRAM = @INSTALL_PROGRAM@
@@ -165,12 +166,9 @@
 XSLT_INCLUDEDIR = @XSLT_INCLUDEDIR@
 XSLT_LIBDIR = @XSLT_LIBDIR@
 XSLT_LIBS = @XSLT_LIBS@
-ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_CXX = @ac_ct_CXX@
 ac_ct_F77 = @ac_ct_F77@
-ac_ct_RANLIB = @ac_ct_RANLIB@
-ac_ct_STRIP = @ac_ct_STRIP@
 am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
 am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
 am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@
@@ -187,23 +185,30 @@
 build_os = @build_os@
 build_vendor = @build_vendor@
 datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
 exec_prefix = @exec_prefix@
 host = @host@
 host_alias = @host_alias@
 host_cpu = @host_cpu@
 host_os = @host_os@
 host_vendor = @host_vendor@
+htmldir = @htmldir@
 includedir = @includedir@
 infodir = @infodir@
 install_sh = @install_sh@
 libdir = @libdir@
 libexecdir = @libexecdir@
+localedir = @localedir@
 localstatedir = @localstatedir@
 mandir = @mandir@
 mkdir_p = @mkdir_p@
 oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
 prefix = @prefix@
 program_transform_name = @program_transform_name@
+psdir = @psdir@
 pythondir = @pythondir@
 sbindir = @sbindir@
 sharedstatedir = @sharedstatedir@

Modified: packages/libxslt/trunk/tests/xinclude/Makefile.in
===================================================================
--- packages/libxslt/trunk/tests/xinclude/Makefile.in	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/tests/xinclude/Makefile.in	2006-06-08 22:29:07 UTC (rev 565)
@@ -80,6 +80,7 @@
 EXTRA_LIBS = @EXTRA_LIBS@
 F77 = @F77@
 FFLAGS = @FFLAGS@
+GREP = @GREP@
 HTML_DIR = @HTML_DIR@
 INSTALL_DATA = @INSTALL_DATA@
 INSTALL_PROGRAM = @INSTALL_PROGRAM@
@@ -165,12 +166,9 @@
 XSLT_INCLUDEDIR = @XSLT_INCLUDEDIR@
 XSLT_LIBDIR = @XSLT_LIBDIR@
 XSLT_LIBS = @XSLT_LIBS@
-ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_CXX = @ac_ct_CXX@
 ac_ct_F77 = @ac_ct_F77@
-ac_ct_RANLIB = @ac_ct_RANLIB@
-ac_ct_STRIP = @ac_ct_STRIP@
 am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
 am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
 am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@
@@ -187,23 +185,30 @@
 build_os = @build_os@
 build_vendor = @build_vendor@
 datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
 exec_prefix = @exec_prefix@
 host = @host@
 host_alias = @host_alias@
 host_cpu = @host_cpu@
 host_os = @host_os@
 host_vendor = @host_vendor@
+htmldir = @htmldir@
 includedir = @includedir@
 infodir = @infodir@
 install_sh = @install_sh@
 libdir = @libdir@
 libexecdir = @libexecdir@
+localedir = @localedir@
 localstatedir = @localstatedir@
 mandir = @mandir@
 mkdir_p = @mkdir_p@
 oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
 prefix = @prefix@
 program_transform_name = @program_transform_name@
+psdir = @psdir@
 pythondir = @pythondir@
 sbindir = @sbindir@
 sharedstatedir = @sharedstatedir@

Modified: packages/libxslt/trunk/tests/xmlspec/Makefile.in
===================================================================
--- packages/libxslt/trunk/tests/xmlspec/Makefile.in	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/tests/xmlspec/Makefile.in	2006-06-08 22:29:07 UTC (rev 565)
@@ -80,6 +80,7 @@
 EXTRA_LIBS = @EXTRA_LIBS@
 F77 = @F77@
 FFLAGS = @FFLAGS@
+GREP = @GREP@
 HTML_DIR = @HTML_DIR@
 INSTALL_DATA = @INSTALL_DATA@
 INSTALL_PROGRAM = @INSTALL_PROGRAM@
@@ -165,12 +166,9 @@
 XSLT_INCLUDEDIR = @XSLT_INCLUDEDIR@
 XSLT_LIBDIR = @XSLT_LIBDIR@
 XSLT_LIBS = @XSLT_LIBS@
-ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_CXX = @ac_ct_CXX@
 ac_ct_F77 = @ac_ct_F77@
-ac_ct_RANLIB = @ac_ct_RANLIB@
-ac_ct_STRIP = @ac_ct_STRIP@
 am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
 am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
 am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@
@@ -187,23 +185,30 @@
 build_os = @build_os@
 build_vendor = @build_vendor@
 datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
 exec_prefix = @exec_prefix@
 host = @host@
 host_alias = @host_alias@
 host_cpu = @host_cpu@
 host_os = @host_os@
 host_vendor = @host_vendor@
+htmldir = @htmldir@
 includedir = @includedir@
 infodir = @infodir@
 install_sh = @install_sh@
 libdir = @libdir@
 libexecdir = @libexecdir@
+localedir = @localedir@
 localstatedir = @localstatedir@
 mandir = @mandir@
 mkdir_p = @mkdir_p@
 oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
 prefix = @prefix@
 program_transform_name = @program_transform_name@
+psdir = @psdir@
 pythondir = @pythondir@
 sbindir = @sbindir@
 sharedstatedir = @sharedstatedir@

Modified: packages/libxslt/trunk/xsltproc/Makefile.in
===================================================================
--- packages/libxslt/trunk/xsltproc/Makefile.in	2006-06-08 22:24:29 UTC (rev 564)
+++ packages/libxslt/trunk/xsltproc/Makefile.in	2006-06-08 22:29:07 UTC (rev 565)
@@ -105,6 +105,7 @@
 EXTRA_LIBS = @EXTRA_LIBS@
 F77 = @F77@
 FFLAGS = @FFLAGS@
+GREP = @GREP@
 HTML_DIR = @HTML_DIR@
 INSTALL_DATA = @INSTALL_DATA@
 INSTALL_PROGRAM = @INSTALL_PROGRAM@
@@ -190,12 +191,9 @@
 XSLT_INCLUDEDIR = @XSLT_INCLUDEDIR@
 XSLT_LIBDIR = @XSLT_LIBDIR@
 XSLT_LIBS = @XSLT_LIBS@
-ac_ct_AR = @ac_ct_AR@
 ac_ct_CC = @ac_ct_CC@
 ac_ct_CXX = @ac_ct_CXX@
 ac_ct_F77 = @ac_ct_F77@
-ac_ct_RANLIB = @ac_ct_RANLIB@
-ac_ct_STRIP = @ac_ct_STRIP@
 am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
 am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
 am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@
@@ -212,23 +210,30 @@
 build_os = @build_os@
 build_vendor = @build_vendor@
 datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
 exec_prefix = @exec_prefix@
 host = @host@
 host_alias = @host_alias@
 host_cpu = @host_cpu@
 host_os = @host_os@
 host_vendor = @host_vendor@
+htmldir = @htmldir@
 includedir = @includedir@
 infodir = @infodir@
 install_sh = @install_sh@
 libdir = @libdir@
 libexecdir = @libexecdir@
+localedir = @localedir@
 localstatedir = @localstatedir@
 mandir = @mandir@
 mkdir_p = @mkdir_p@
 oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
 prefix = @prefix@
 program_transform_name = @program_transform_name@
+psdir = @psdir@
 pythondir = @pythondir@
 sbindir = @sbindir@
 sharedstatedir = @sharedstatedir@




More information about the debian-xml-sgml-commit mailing list